@sksoftofficial/tinygent
v1.0.8
Published
Tiny Codex-backed multi agent CLI with reusable sessions, identity files, and user-defined tools
Maintainers
Readme
tinygent
Reusable AI agent sessions from the command line.

tinygent is a tiny Node.js npm CLI for running Codex-backed AI agent workflows with reusable sessions, identity files, user-defined tools, and script-friendly command-line automation.
- Website: https://skbilisim.com/en/projects/tinygent
- npm: https://www.npmjs.com/package/@sksoftofficial/tinygent
Usage
Onboard
tinygent onboardOptional agent id:
tinygent onboard --agent mainOptional message rotation limit:
tinygent onboard --agent main --message-rotation-limit 25Optional session retention limit. This keeps the newest session log files and deletes older ones automatically after a message creates or rotates a session. Press Enter during onboarding to use the default of 10.
tinygent onboard --agent main --session-retention-limit 10Login
Replace Codex credentials for an agent without changing identity, tools, session config, or session state:
tinygent login --agent mainSend a message
tinygent message "hi"With explicit model:
tinygent message --agent main --model gpt-5.5 "hi"Override reasoning level for this message. Defaults to low; supported levels are none, minimal, low, medium, high, and xhigh.
tinygent message --reasoning none "hi"From file:
tinygent message --file ./prompt.txtForce a fresh session:
tinygent message "start fresh" --new-sessionUse a custom session id:
tinygent message --session-id editorial-thread-1 "continue this thread"Identity
Print the current identity.md for an agent:
tinygent identityFor a specific agent:
tinygent identity --agent mainOverwrite identity.md with the contents of a file:
tinygent identity --agent main ./identity.mdTools
Tools from tools.js are loaded automatically during tinygent message. If the model requests a tool call, tinygent executes it, appends the tool result to the session, and continues until the final answer.
Tinygent also includes two built-in media tools:
imageanalyzes one or more image paths, URLs, or data URLs with a vision model.image_generategenerates or edits images with OpenAI image models, defaulting toopenai/gpt-image-2, and saves results under~/.tinygent/<agent>/media/.
image_generate uses the agent's Codex credentials from tinygent onboard or tinygent login.
Print the current tools.js for an agent:
tinygent toolsFor a specific agent:
tinygent tools --agent mainMerge tools from a file into the agent's existing user tools. Built-in tools remain available during tinygent message:
tinygent tools --agent main ./tools.jsReplace the complete tool set instead of merging, including built-ins:
tinygent tools --agent main --override ./tools.jsClear session state
tinygent clearFor a specific agent:
tinygent clear --agent mainList agents
tinygent agentsStatus and usage
Report Codex subscription usage:
tinygent statusFor a specific agent:
tinygent status --agent mainExample:
Usage: 5h 47% left 1h 24m · Week 81% left 5d 2hRefresh credentials
tinygent refreshIf the refresh token is no longer valid, run tinygent login --agent main to sign in again without rerunning onboarding.
Workspace layout
Per agent workspace:
~/.tinygent/<agent>/
codex-credentials.json
identity.md
tools.js
session-config.json
current_session.txt
custom-session-mappings.json
sessions/