Skip to main content

Module external

Module external 

Source
Expand description

External executors: another coding agent makes the attempt; speccoder keeps everything around it.

An ACP agent (agent = "copilot", …, or kind = "acp" with argv) is driven over the Agent Client Protocol (crate::acp): each permission request it sends, and every file and command it runs through speccoder, is decided by speccoder’s policy and approvals. What it does without asking stays outside speccoder. A kind = "command" program gets the prompt on stdin and is judged from its diff alone.

Either way speccoder keeps the isolated worktree, frozen and spec-derived acceptance tests written before the attempt, the integrity audit of the diff (protected files, deleted or weakened tests), the checks and the verdict, retries with the verifier’s digest, the gaming monitor, ticking and committing.

Structs§

AcpOutcome
What an ACP attempt came to: the native-shaped outcome, and the agent’s own sign-in methods when it needs signing in.
Executor
[executor] in speccoder.toml.
Outcome
What an external attempt produced, in the shape of a native attempt’s output.

Enums§

Kind
Which agent.

Functions§

agent_attempt
The report’s account of an ACP attempt, from its output.
for_agent
The executor for id (a preset), for one run (run --agent).
interpret
Reads a command’s final message from its stdout: BLOCKED: is an honest stop, FAILED: a failure, anything else the agent’s summary.
judged
An agent’s final message after a turn it finished.
parse
Reads [executor]; None (or kind = "native") is speccoder’s own loop.
prompt
What the external agent is told: the same context a native attempt gets, the rules speccoder will check afterwards, and how to stop honestly.
prompt_in
prompt for a project whose format is worded w.
run
Runs one kind = "command" attempt with argv in worktree.
run_acp
Runs one ACP attempt: the agent in worktree, its calls decided by governor.
tally
The permission tally of an attempt’s log: what the agent asked, what was allowed, what waited for a person, what was refused.