Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
79 commits
Select commit Hold shift + click to select a range
c5886cf
reports(api): plan agent configuration as data (M6.5)
LittleCoinCoin Nov 25, 2026
8c7be6a
rdm(api): open the M6.5 agent configuration root
LittleCoinCoin Nov 25, 2026
8343562
reports(api): check the HTN lane's requirements against M6.5
LittleCoinCoin Nov 25, 2026
0d9f78d
reports(api): plan two instruction scopes for M6.5 (v1)
LittleCoinCoin Nov 25, 2026
66c0950
rdm(api): amend M6.5 for the two instruction scopes
LittleCoinCoin Nov 25, 2026
3a245da
reports(api): plan a live, trace-read proof for M6.5 (v2)
LittleCoinCoin Nov 25, 2026
8a32ae8
rdm(api): amend M6.5 for the live trace proof
LittleCoinCoin Nov 25, 2026
ac45262
rdm(api): start M6.5 level 1 and sweep the root gates
LittleCoinCoin Nov 25, 2026
48f287c
feat(schemas): add the context_start trace event
LittleCoinCoin Nov 25, 2026
3ad5717
feat(schemas): type the instructions and hooks of a cell
LittleCoinCoin Nov 25, 2026
10f49ae
reports(api): probe the harness checks for instructions and hooks
LittleCoinCoin Nov 25, 2026
d93e579
reports(api): give the probe's evidence per question
LittleCoinCoin Nov 25, 2026
3e325a5
merge(api): land the M6.5 harness-check probe
LittleCoinCoin Nov 25, 2026
f5eee31
rdm(api): mark the M6.5 probe done
LittleCoinCoin Nov 25, 2026
0ce705e
feat(api): take instructions and hooks as cell values
LittleCoinCoin Nov 25, 2026
514c7db
feat(schemas): show the instructions and hooks of an inspected run
LittleCoinCoin Nov 25, 2026
6e9f4fc
feat(runner): record each run's starting context in the trace
LittleCoinCoin Nov 25, 2026
05c912d
docs(schemas): say what context_start holds
LittleCoinCoin Nov 25, 2026
ea23a16
feat(api): declare instructions, hooks and the harness check
LittleCoinCoin Nov 25, 2026
18b7f65
fix(runner): tag the sidecar image by its sources, keep one stream
LittleCoinCoin Nov 25, 2026
6c50cd3
rdm(api): amend the M6.5 gates for the proof and the surface
LittleCoinCoin Nov 25, 2026
2c24363
feat(schemas): keep the keys of the hooks and global instruction tables
LittleCoinCoin Nov 25, 2026
c53d9c3
fix(runner): drop the dead sidecar and prompt-only branches
LittleCoinCoin Nov 25, 2026
124b1b8
feat(api): read hooks and instructions as the harness writes them
LittleCoinCoin Nov 25, 2026
d72a3fd
merge(api): land the M6.5 trace context
LittleCoinCoin Nov 25, 2026
fca583a
rdm(api): mark the M6.5 trace context done
LittleCoinCoin Nov 25, 2026
16d0bea
feat(api): make every driver state its harness check
LittleCoinCoin Nov 25, 2026
446a223
feat(schemas): hold the free-key fact in one list
LittleCoinCoin Nov 25, 2026
874fdf4
feat(api): drop the harness-id scaffolding and forward the check
LittleCoinCoin Nov 25, 2026
f929c3c
feat(schemas): one document fault for a bad level and a bad file
LittleCoinCoin Nov 25, 2026
3bc7b85
merge(api): land the M6.5 declaration
LittleCoinCoin Nov 25, 2026
9e007aa
reports(api): file the M6.5 level 1 observations
LittleCoinCoin Nov 25, 2026
971c2e5
rdm(api): mark the M6.5 declaration done
LittleCoinCoin Nov 25, 2026
002ba02
rdm(api): name the later M6.5 reports by the next free round
LittleCoinCoin Nov 25, 2026
6266caf
rdm(api): raise the M6.5 cap to $125
LittleCoinCoin Nov 25, 2026
a0cbe0f
rdm(api): order the M6.5 installs by the census channel
LittleCoinCoin Nov 25, 2026
b05b29d
rdm(api): run the M6.5 harness check at job start
LittleCoinCoin Nov 25, 2026
3cebec0
feat(api): install instructions and hooks on Claude Code
LittleCoinCoin Nov 25, 2026
3e86aea
feat(api): record loaded memory files on Claude Code
LittleCoinCoin Nov 25, 2026
b956e0f
feat(api): refuse a cell its harness rejects
LittleCoinCoin Nov 25, 2026
4e800a4
feat(api): mount the workspace instruction file read-only
LittleCoinCoin Nov 25, 2026
3e3fd1b
fix(api): read the hook log without following links
LittleCoinCoin Nov 25, 2026
929d888
fix(api): accept a Claude Code config check only on a doctor report
LittleCoinCoin Nov 25, 2026
69b0841
docs(api): say what a plain Claude Code cell now gets
LittleCoinCoin Nov 25, 2026
e0e98da
fix(api): fail the collection on a census error, fix a stream doc
LittleCoinCoin Nov 25, 2026
4b1b730
merge(api): land the M6.5 Claude Code install
LittleCoinCoin Nov 25, 2026
cda2e98
rdm(api): mark the M6.5 Claude Code install done
LittleCoinCoin Nov 25, 2026
835f08c
merge(api): take the Claude Code install into the preflight check
LittleCoinCoin Nov 25, 2026
de63a12
fix(api): name the hooks type the check reads for its pointer
LittleCoinCoin Nov 25, 2026
9ab068f
fix(api): read a harness check's findings whatever its exit
LittleCoinCoin Nov 25, 2026
6e9971b
refactor(api): share one gateway stream reader, ask the census as a bool
LittleCoinCoin Nov 25, 2026
1f8fce6
fix(api): key the config check on all it reads, and plan each cell once
LittleCoinCoin Nov 25, 2026
324a50b
rdm(api): meet the run context when M6.5 lands second
LittleCoinCoin Nov 25, 2026
c4606cd
fix(api): refuse an input at the instruction file in core planning
LittleCoinCoin Nov 25, 2026
9b60ee0
docs(api): say what mount_inputs assumes of its workspace
LittleCoinCoin Nov 25, 2026
1e1f23e
feat(api): install instructions and plugins on OpenCode
LittleCoinCoin Nov 25, 2026
970a768
test(api): find the strict MCP flags anywhere in the Claude Code command
LittleCoinCoin Nov 25, 2026
775bdcd
fix(api): let the check's own variables win over the run's
LittleCoinCoin Nov 25, 2026
4df5224
merge(api): land the M6.5 harness check
LittleCoinCoin Nov 25, 2026
286707e
rdm(api): mark the M6.5 harness check done
LittleCoinCoin Nov 25, 2026
806aeb8
fix(api): refuse OpenCode check errors, read the census scope by prefix
LittleCoinCoin Nov 25, 2026
04b6456
merge(api): land the M6.5 OpenCode install
LittleCoinCoin Nov 25, 2026
04c2d2f
rdm(api): mark the M6.5 OpenCode install done
LittleCoinCoin Nov 25, 2026
ef1415c
test(api): answer the harness check in the fake Docker
LittleCoinCoin Nov 25, 2026
c13d2a3
test(api): guard that a workspace instruction text reaches the record
LittleCoinCoin Nov 25, 2026
3f19823
merge(api): land the M6.5 harness-check fakes
LittleCoinCoin Nov 25, 2026
dd9c421
fix(api): refuse only OpenCode check warnings, census path from workdir
LittleCoinCoin Nov 25, 2026
ea9ca0c
docs(api): describe the job-start harness check and the hooks
LittleCoinCoin Nov 25, 2026
481e530
merge(api): land the M6.5 level-2 seam fixes
LittleCoinCoin Nov 25, 2026
42dc265
test(api): expect the OpenCode workspace file relative in the census
LittleCoinCoin Nov 25, 2026
5ef2521
reports(api): file what M6.5 level 2 found outside its leaves
LittleCoinCoin Nov 25, 2026
c40449d
test(cli): prove instructions and hooks on both harnesses
LittleCoinCoin Nov 25, 2026
7466547
fix(api): mount the declared inputs in the harness check
LittleCoinCoin Nov 25, 2026
bfdfa01
merge(api): prove instructions and hooks end to end on both harnesses
LittleCoinCoin Nov 25, 2026
2a4bf16
reports(api): confirm instructions and hooks live from the trace
LittleCoinCoin Nov 25, 2026
528cfef
reports(api): close M6.5 level 3 and record the run-context meeting
LittleCoinCoin Nov 25, 2026
b09bd93
reports(api): review M6.5 against its gates
LittleCoinCoin Nov 25, 2026
4089b3f
reports(api): close M6.5 agent configuration
LittleCoinCoin Nov 25, 2026
6c90400
fix(api): fix the CI rustdoc and read-only mount guards
LittleCoinCoin Nov 25, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 29 additions & 12 deletions __design__/architecture.md
Original file line number Diff line number Diff line change
Expand Up @@ -679,7 +679,7 @@ I3, so event times are reproducible even where the harness emits none.

| Phase | Needed | Varies between harnesses |
|---|---|---|
| Prepare | Model, endpoint, skill or plug-in, MCP servers, permissions and instructions written into the workspace | File names and formats; model ids and provider configuration |
| Prepare | Model, endpoint, skill or plug-in, MCP servers, permissions, and instructions written into the home (global) and mounted read-only in the workspace | File names and formats; model ids and provider configuration |
| Confine | An in-harness guard where one exists (Claude Code's PreToolUse hook) | Some have none; the container is then the only boundary |
| Launch | Headless command line, environment overlay, working directory | Flags; budget options |
| Observe | Live events, normalised; the session ids seen | Streamed on stdout, or kept in a local database |
Expand All @@ -692,7 +692,7 @@ I3, so event times are reproducible even where the harness emits none.
### Traits (signatures only)

Every item added for the second harness (`answer`, `fact`, `check_settings`, `gateway`,
`state_paths`, `census_stream`, `session`, `session_tracker`, `classify_end`) has a default body, so a driver
`state_paths`, `census_from_gateway`, `session`, `session_tracker`, `classify_end`) has a default body, so a driver
implements only what its harness has.

- `HarnessDriver`
Expand All @@ -715,8 +715,8 @@ implements only what its harness has.
driver. No default names exist: a driver that names none is refused at run time
- `state_paths() -> StatePath { env, kind: Dir | File, subpath }[]`: the places the harness
keeps state under the agent's home. The core makes each per run and sets its variable
- `census_stream() -> Option<StreamName>`: the raw stream the gateway's census is stored under,
for a harness with no init event. The core reads the gateway census itself
- `census_from_gateway() -> bool`: the harness has no init event, so the core reads the census
from the gateway's record of the first request
- `session(cell, workspace) -> Option<SessionSpec { command, input, close, hooks }>` and
`session_tracker() -> Option<Box<dyn SessionTracker>>`
- `stop() -> StopSpec { pre_stop: Option<Action>, signal, grace }`, with
Expand All @@ -731,8 +731,9 @@ implements only what its harness has.
which the core calls, defaults to `classify_exit` and lets a harness whose exit status covers
several endings read the live reader's last word or the export
- `collect(workspace, observed) -> CollectSpec[]`, with
`CollectSpec = File(glob) | Command(CommandSpec, name) | Exec(CommandSpec, name)`. The core
runs `Exec` after the agent exited, in a throwaway container over the run's mounts and state
`CollectSpec = File(glob) | Command(CommandSpec, name) | Exec(CommandSpec, name) | Home(path, name)`.
`Home` archives a file under the agent's home as the stream `name`, read on the host after the
run. The core runs `Exec` after the agent exited, in a throwaway container over the run's mounts and state
variables (`candler.role=control`, no network, no gateway name), and archives its stdout as
the stream `name`
- `TraceReader`
Expand Down Expand Up @@ -775,6 +776,19 @@ image or resolver is built, and an unknown name is refused (`experiment.unknown_
run as another harness. `comparable.harness.driver` is `None` for live cells. The label
`candler.cc_version` on a base image holds the harness version, whatever the harness.

**The job-start harness check.** A driver may name a command that has its harness read the files
Candler installs for a cell (`config_check(plan)`) and a reader of what it printed
(`read_config_check(output) -> Clean | Rejected { output }`). Before the first run, the core groups
the planned cells by everything that command reads (the harness, the image, the home and
workspace files, the declared inputs, the command with its cwd and overlay, the container
environment and the treatment), runs it once per group in a container without network, and passes the reader standard
output followed by standard error, whatever the exit status. A check that cannot run (the container
does not start, the command is missing, times out or is ended by a signal, or it prints nothing or
too much) is refused as `jobs.config_check_failed`, an environment fault; a rejection is refused as
`experiment.harness_rejected_input`, naming the files and the setting they come from. The check
container mounts the cell's declared inputs as the run does, so the verdict
(`provenance.harness_config_check`) covers every file the harness reads at start.

**The shared fixture suite.** `candler-harness`, under the feature `conformance`, holds one suite
that every driver crate runs over its recorded streams. It checks that gateway names, state paths,
actions and written files are well formed (no secret in argv, every `{env:NAME}` a written file
Expand Down Expand Up @@ -860,7 +874,7 @@ version and by the sha256 of the release archive of each architecture.
`<server>_<tool>`), the deny rows last. A name with no OpenCode action is refused.
- **Census.** No event, command or export lists OpenCode's tools. The tool names in the request the
agent sends to the model are the inventory, so the gateway sidecar records the names of each
request, and the core takes the first request that carries tools (`census_stream`,
request, and the core takes the first request that carries tools (`census_from_gateway`,
`census.source = gateway`). A run whose requests carry no tools records no inventory. The verdict never takes a
gateway inventory for a harness's own.
- **Facts.** `graceful_stop`, `census` and `execution_outside_child`. Not `SessionMode`.
Expand Down Expand Up @@ -902,10 +916,12 @@ through stdin and stdin stays open, so a notification starts a further turn.
has one. A turn that ends with no Stop payload (a turn cap error, an API error) leaves the state
unknown, and the session runs to its cap rather than closing.
- **Hooks.** The driver installs observation hooks outside the workspace (a settings file in the
agent's home, loaded under `--setting-sources project,local`). The hook command appends the Stop
or SessionEnd payload with the container's clock to a log, prints nothing and always exits 0, so
it never blocks or decides (I9). The log is archived as the raw stream `hooks`, so the session
measures can be re-derived (I3). Hooks are never trusted for the turn end.
agent's home, passed with `--settings`; `user` joins `--setting-sources` when a global
instruction text is set). The hook command appends the payload of `InstructionsLoaded`, `Stop`
or `SessionEnd`, with the container's clock, to a log, in a headless run as in a session, prints
nothing and always exits 0, so it never blocks or decides (I9). The log is archived as the raw
stream `hooks`, so the session measures can be re-derived (I3). Hooks are never trusted for the
turn end.
- **Measured, never filtered.** The agent's own stopping is recorded as `measured[]` paths:
`session.idle_s`, `session.turns` (turns that ended), `session.yielded_at_ms` (from the runner's
preparation of the session to the end of the last turn), `session.pending_at_end` (a list of
Expand Down Expand Up @@ -1234,7 +1250,8 @@ never compares an inventory with one of another source. The census names no serv

`Session {id, source{harness, harness_version, reader, reader_version}, model, started_at?,
ended_at?, ended_by, parent_session?, raw_ref}`; `Event {seq, at?, kind, span?, raw_ref, ext}` with
kinds `user_message`, `assistant_message`, `tool_call` (`origin`, `argv?`, `wrapped_calls[]?` for a
kinds `context_start` (`system`, `first_message`: the run's first model request that carries tools, as the
gateway received it; the root session's first event), `user_message`, `assistant_message`, `tool_call` (`origin`, `argv?`, `wrapped_calls[]?` for a
call that bundles several MCP calls), `tool_result` (`is_error`, `denied?`), `notification`, `usage`
(`scope: message | session_total`). `at` comes from the harness when it emits one, else from the
frame time in the raw file, else it is absent.
Expand Down
Loading