create_agent_identity
Creates a new unique agent identity and persists its profile to Git, generating a memorable adjective+noun name so worker agents can join projects without overwriting existing profiles.
Instructions
Create a new, unique agent identity and persist its profile to Git.
How this differs from register_agent
Always creates a new identity with a fresh unique name (never updates an existing one).
name_hint, if provided, MUST be a valid adjective+noun combination and must be available, otherwise an error is raised. Without a hint, a random adjective+noun name is generated.
CRITICAL: Agent Naming Rules
Agent names MUST be randomly generated adjective+noun combinations
Examples: "GreenCastle", "BlueLake", "RedStone", "PurpleBear"
Names should be unique, easy to remember, and NOT descriptive
INVALID examples: "BackendHarmonizer", "DatabaseMigrator", "UIRefactorer"
Best practice: Omit
name_hintto auto-generate a valid name (RECOMMENDED)
When to use
Spawning a brand new worker agent that should not overwrite an existing profile.
Temporary task-specific identities (e.g., short-lived refactor assistants).
Parameters
return_registration_token : bool, default True
When True (default, current behaviour), the response includes the
freshly-minted registration_token. When False, the token is omitted
from the tool result so transcript-visible MCP sessions can satisfy
a "do not echo secrets into scrollback" contract; the agent is still
bound to the current MCP session via _bind_session_agent, so
follow-up calls in the same session can authenticate without
ever surfacing the token. The token still exists on the server
and can be retrieved or rotated through the normal admin paths.
See issue #154.
Returns
dict { id, name, program, model, task_description, inception_ts, last_active_ts, project_id, registration_token? }
Examples
Auto-generate name (RECOMMENDED):
{"jsonrpc":"2.0","id":"c2","method":"tools/call","params":{"name":"create_agent_identity","arguments":{
"project_key":"/data/projects/backend","program":"claude-code","model":"opus-4.1"
}}}With valid name hint:
{"jsonrpc":"2.0","id":"c1","method":"tools/call","params":{"name":"create_agent_identity","arguments":{
"project_key":"/data/projects/backend","program":"codex-cli","model":"gpt5-codex","name_hint":"GreenCastle",
"task_description":"DB migration spike"
}}}Transcript-safe creation (issue #154) — omit the token from the visible tool result and rely on session binding for follow-ups:
{"jsonrpc":"2.0","id":"c3","method":"tools/call","params":{"name":"create_agent_identity","arguments":{
"project_key":"/data/projects/backend","program":"codex-cli","model":"gpt5",
"return_registration_token":false
}}}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| model | Yes | ||
| format | No | ||
| program | Yes | ||
| name_hint | No | ||
| project_key | Yes | ||
| task_description | No | ||
| attachments_policy | No | auto | |
| return_registration_token | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||