agora.observe.commands
/agora <verb> <args> directive parser.
Human observers type commands in any room. The sync loop routes m.room.message
events to parse_command(), which returns a ParsedCommand or
None (for non-agora messages). The orchestrator registers a handler that
maps verbs to side effects (notes, redirects, pause/resume/abort, review votes).
The grammar is forgiving:
/agora note <text>— attach a free-form note to the target room./agora pause//agora resume— toggle the orchestrator’s run gate./agora abort [reason]— cancel the current project./agora redirect <agent_name> <new instructions>— update agent instructions./agora review <answer_id>— fallback for clients that can’t render polls./agora help— the renderer responds with a usage block.
Functions
|
|
|
Return a |
|
Return |
Classes
A parsed |
- class agora.observe.commands.ParsedCommand[source]
Bases:
objectA parsed
/agora <verb> <args>directive.argsis the whitespace split (kept for free-text verbs likenote);argvis the shlex tokenization (for verbs with quoted arguments).raw/senderpreserve provenance for the audit log.- __init__(verb, args, raw, sender, argv=())
- agora.observe.commands.parse_command(body, sender='')[source]
Return a
ParsedCommandifbodystarts with/agora, else None.Malformed commands (unknown verbs, missing required args) still return a
ParsedCommandwithverb=help-style fallback — the caller emits usage.