Expand description
The agent-facing surface, as data, and the generators that render it.
choir --help, docs/using/cli.md, the README’s cheat-sheet, the
three templates/ snippets, the root AGENTS.md and the node’s
llms.txt all describe one surface. Hand-maintained, they drift —
and they had already started to: the API table carried a throughput
figure that three later measurements had superseded.
So the surface is described once, here, and everything else is
rendered from it. crate::surface is the source; a staleness test
re-renders and compares, so a committed artifact cannot silently fall
behind the table.
§What is generated and what is not
Only the signatures — command names, arguments, endpoints,
purposes. The conventions around them stay hand-written, because
templates/ is a product deliverable whose value is judgement
(“name no reviewers; the node draws them”) rather than syntax, and
generating prose would flatten exactly the part worth shipping. In
the templates the generated region is bounded by
GEN_START/GEN_END markers and the prose lives outside them.
No dependency is added for any of this: rendering markdown from a
const table is a few format! calls.
Structs§
- Command
- One
choirsubcommand. - Endpoint
- One HTTP endpoint on the node.
- McpTool
- The MCP-specific part of one HTTP endpoint.
Enums§
- McpArguments
- How an MCP tool’s arguments become one HTTP request.
Constants§
- API_
VERSION - Version of the machine-readable API description (D17).
- AUTH_
OPTIONS - Explicit global options for authenticated node access.
- COMMANDS
- Every
choirsubcommand, in help order. - DAY_ONE
- The commands a first contribution needs, in reading order.
- DEPRECATIONS
- Wire names this API still accepts and no longer documents, with what replaced them.
- ENDPOINTS
- Every endpoint the node serves, in the order
docs/using/cli.mdlists them. - GEN_END
- Closing marker of a generated region.
- GEN_
START - Opening marker of a generated region in an otherwise authored file.
- GROUPS
- The help sections, in reading order: what you do first, then the loop you live in, then the things you reach for when something is wrong.
- SH_
GEN_ END - Closing marker of a generated region in a shell file.
- SH_
GEN_ START - The same pair for a shell file, where an HTML comment is a syntax error rather than a comment.
- SKILL_
DIR - Directory name the agent skill installs under; the skill frontmatter’s
name:must equal it, because skill loaders resolve by directory.
Functions§
- agents_
md AGENTS.md: the generated choir reference for coding agents.- api_
table - The endpoint table
docs/using/cli.mdcarries. - artifacts
- Every artifact rendered from this table, as
(path, full contents), relative to the repositoryroot. - cli_
doc_ surface - The generated API and CLI reference in
docs/using/cli.md. - cli_
reference - The command reference in
docs/using/cli.md: every command, its full argument spec, and what it is for. - command_
bullets - The command list the agent templates carry, as a markdown bullet list.
- command_
help - The help for one command: its full spec and its whole summary.
- command_
help_ in command_help, styled for a terminal.- contribute_
html - The three commands a newcomer runs, as an HTML fragment the node serves on its contribute page.
- endpoint
- Finds an HTTP endpoint by method and path.
- llms_
txt llms.txt, served by the node: the same surface, compact, no markdown tables — a plain list survives a small context window better.- mcp_
endpoint - Finds the HTTP endpoint backing an MCP tool.
- mcp_
tools - MCP tools in deterministic endpoint-table order.
- python_
client - The generated half of
templates/python/choir.py: one method per tool, rendered from the schema document and nothing else (D17). - readme_
cheatsheet - The README’s cheat-sheet: the day-one commands and nothing else.
- schema_
json - The machine-readable API description (D17), as pretty JSON.
- shell_
functions - The generated half of
templates/shell/choir.sh: one function per agent-facing command (D17). - skill_
md - The installable agent skill.
- splice
- Replaces the region between
GEN_STARTandGEN_ENDindoc. - splice_
between splicewith explicit markers, for a file whose comment syntax is not HTML.- usage
- The
choirusage block, as a bare invocation prints it. - usage_
in usage, styled for a terminal.