@staix/agent-research 0.3.0 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +70 -0
- package/README.md +93 -22
- package/package.json +4 -1
- package/src/cli-output.ts +446 -0
- package/src/cli.ts +208 -66
- package/src/commands-table.ts +213 -93
- package/src/commands.ts +86 -17
- package/src/exp/artifacts.ts +20 -2
- package/src/exp/attempts.ts +26 -9
- package/src/exp/calibrate.ts +125 -0
- package/src/exp/executor.ts +130 -21
- package/src/exp/final.ts +12 -3
- package/src/exp/idea-report.ts +97 -0
- package/src/exp/ideas.ts +90 -6
- package/src/exp/investigate.ts +25 -22
- package/src/exp/metrics.ts +3 -5
- package/src/exp/protocol.ts +28 -3
- package/src/exp/reuse-admission.ts +3 -1
- package/src/exp/reuse-runtime.ts +5 -1
- package/src/exp/screen.ts +83 -0
- package/src/exp/selection.ts +110 -4
- package/src/exp/snapshot.ts +28 -8
- package/src/exp/stages.ts +3 -1
- package/src/harness/transitions.ts +37 -5
- package/src/manifest.ts +13 -5
- package/src/mcp-tools.ts +67 -14
- package/src/memory/archive.ts +8 -3
- package/src/paper/build.ts +39 -25
- package/src/paper/check.ts +46 -15
- package/src/paper/dependencies.ts +47 -0
- package/src/paper/document.ts +19 -0
- package/src/paper/figures.ts +152 -0
- package/src/paper/hygiene.ts +16 -5
- package/src/paper/plan.ts +71 -29
- package/src/paper/point-evidence.ts +27 -12
- package/src/paper/render.ts +113 -0
- package/src/paper/renderer.ts +128 -0
- package/src/paper/review.ts +41 -5
- package/src/plan/definition.ts +6 -1
- package/src/playbook.ts +21 -11
- package/src/provenance.ts +4 -3
- package/src/study-export.ts +7 -4
- package/src/study.ts +9 -4
- package/src/ui/plugin.ts +3 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,76 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
## [0.4.1] - 2026-11-25
|
|
6
|
+
|
|
7
|
+
Version 0.4.0 was tagged but never published to npm or GitHub Releases. Version 0.4.1 is the first published release in the 0.4 line and carries all 0.4.0 features. Its N-1 compatibility statements remain those in the 0.4.0 section below.
|
|
8
|
+
|
|
9
|
+
- The 0.4.0 tag was not published because the release smoke could not install the new runtime dependency from its empty offline cache. The smoke now pre-caches exact-pinned dependencies in isolation, then installs the staged package offline. Main CI stages and smoke-tests the package before tagging.
|
|
10
|
+
|
|
11
|
+
## [0.4.0] - 2026-11-25
|
|
12
|
+
|
|
13
|
+
### N-1 compatibility with 0.3.1
|
|
14
|
+
|
|
15
|
+
- **CLI** Retains all 90 published commands and their usage forms. Adds eight commands for external renders, renderer configuration, selection calibration, idea categories and the idea report. Paper check, build and render accept an optional `--doc`. Reports default to text. Use `--json` for compact machine output. Usage errors exit 2 instead of 1. Operational failures still exit 1, and command-specific help exits 0.
|
|
16
|
+
- **MCP tools** Retains all 85 published tool names and `readOnly` values. Adds eight tools (93 total): `ares_paper_render_record`, `ares_paper_render_show`, `ares_renderer_set`, `ares_renderer_show`, `ares_renderer_check`, `ares_selection_calibrate`, `ares_idea_categories` and `ares_idea_report`. Existing calls keep their request forms.
|
|
17
|
+
- **Study and ledger formats** Reads existing 0.3.1 surveys, experiments and ledgers without migration. The installed-package check verifies read-only access, the original no-input protocol hash, design binding and approved gate, and a 0.4.0-created study v2 that 0.3.1 reads unchanged. New optional fields and derived files require a compatible reader for their full behavior.
|
|
18
|
+
|
|
19
|
+
| 0.4.0 change | What 0.3.1 does |
|
|
20
|
+
| --- | --- |
|
|
21
|
+
| Paper plan v3 (dependencies and figures), paper evidence v3 (figures), selection v2, or a protocol carrying `screen` | Refuses the unsupported version or unknown field. Figure-free builds still write evidence v1 or v2. |
|
|
22
|
+
| A `paper.render` plan step, `[paper] requireRender`, or `[review] readback` | Refuses the unknown step or settings key when loading the corresponding record. |
|
|
23
|
+
| Harness contrast `presentations` or a new review input with `readback` | Refuses the extra field when validating the contrast or a review submission. Stored review replay ignores the read-back field. |
|
|
24
|
+
| Render receipts (v1), machine-local renderer config (v1), calibration receipts (v1), category vocabulary or slides build/render files | Ignores the new files and their capabilities. It has no document selector or renderer, calibration or category commands. It ignores the new render, calibration, screen-refusal and category event kinds. |
|
|
25
|
+
| New fields on idea events | Replays the events and ignores the optional fields. A closed investigation can appear stale because its input hash includes those fields in 0.4.0. |
|
|
26
|
+
| Slides `paper.built` event | Treats it as a manuscript build event. If it is the latest build, 0.3.1 can mark the manuscript build stale. Use 0.4.0 to read mixed-document build history. |
|
|
27
|
+
|
|
28
|
+
- Reviewer read-back (#173, ships in 0.4.0): a review report may carry an optional `readback.claims` list (1 to 8 single-line claims, at most 500 Unicode characters each) saying what the built manuscript claims. `review show` (MCP `ares_review_show`) adds `readback` (the mode), `readbacks` for current-build reports and, when the plan has writing points, `planClaims`. ares never matches or scores them, and they never change readiness. `study.toml` `[review] readback` is `off`, `show` (default) or `require`; `require` refuses a report without the block at `review add`. Reports without the block keep their bytes and event hashes. N-1 (0.3.1): a 0.3.1 `review add` refuses a report carrying `readback` as an unknown field, and a 0.3.1 `study.toml` reader refuses the `readback` key. A 0.3.1 `review show` still replays a ledger holding read-back reports, because stored events are read leniently.
|
|
29
|
+
|
|
30
|
+
- Idea predictions and report (#166): `idea add` accepts optional `category`, `bundle` (1..16) and `predicts` (1..4 declared metrics with `expect` and optional `minDelta`, required for `no-change` on a non-primary metric); inputs without them are stored byte-for-byte as before. `ares idea categories` (MCP `ares_idea_categories`) writes `design/idea-categories.json` and one `idea.categories.set` event; `idea add` then refuses unknown categories. `ares idea report` (MCP `ares_idea_report`, read-only, default window 5) folds the ledger and the investigation pairing into prediction outcomes, unpredicted regressions, per-category recent gain, confounded bundles, a stalled flag and untried categories. It is advisory and writes nothing. `ares manifest` adds `formats.ideaCategories: 1`, `formats.ideaReport: 1` and the event `idea.categories.set`. A 0.3.1 reader replays idea events carrying the new fields and ignores them; it has no `idea categories` or `idea report` command. Because ideas join the investigate input hash, a result closed by 0.4.0 for ideas with these fields reads as stale in 0.3.1.
|
|
31
|
+
|
|
32
|
+
- Evidence-bound slides (#164): Use paper check and paper build with --doc slides to validate paper/slides.md using the same evidence placeholders, citation checks and negative-result requirements as the manuscript. The slides use separate rendered Markdown and evidence files. For external decks, use paper render record and paper render show with --doc slides. The manuscript plan and review workflow apply to the manuscript. Existing manuscript output paths and bytes are preserved.
|
|
33
|
+
|
|
34
|
+
- Paper figures (#168): optional paper plan v3 figures bind local files under paper/ to the build. Declare each image by id, file and kind; plots need current-study card/attempt references or a written waiver, and diagrams need neither. Paper check blocks undeclared or missing assets and unresolved plot evidence. Builds record figure hashes and provenance in paper evidence v3, so changed figures reopen review and make old render receipts stale. Existing plans without figures retain their evidence bytes. Version 0.3.1 refuses plan v3 and evidence v3 with its existing unsupported-version diagnostics.
|
|
35
|
+
|
|
36
|
+
- Selection v2 (#165) adds optional paired-seed guards and a relative cost rule to investigation and reserved final qualification. `selection calibrate` and MCP `ares_selection_calibrate` record an advisory minimum delta from baseline variance or paired A/A deltas. A bound recommendation reports `belowNoise` without changing eligibility. V1 rule and result bytes are preserved. The 0.3.1 selection reader refuses v2 with its unsupported-version diagnostic.
|
|
37
|
+
|
|
38
|
+
- `paper.render` plan step (#163, new feature, ships in 0.4.0): a no-argument step runs this machine's renderer on the current build and records its receipt through the #162 render-record path. It emits the rendered output `{sha256}` for a downstream `plan:<id>` gate. `ares renderer set|show|check` (MCP `ares_renderer_set|show|check`) keep the renderer argv (with `{study}` and `{out}` placeholders) and wall time under the family home, never in `plan.json` or a committed study file. No renderer, a nonzero exit, a timeout or a missing or mismatching receipt fails the step and writes nothing. An unchanged retry is a no-op. `ares manifest` adds `formats.rendererConfig: 1`. Existing plans and studies are unchanged.
|
|
39
|
+
|
|
40
|
+
- CLI reports (#172): human output highlights actionable findings, summarizes checks, and presents filtered views, mutation receipts and confirmation commands. The executor human check reports independent failures and skipped prerequisites. Attempt logs use section headings and strip terminal controls in text mode. Explicit `--json` and MCP results retain their existing forms and exit codes.
|
|
41
|
+
|
|
42
|
+
- Harness contrasts (#169) can declare swapped presentation orders for blinded judgments. Agreement determines the outcome and disagreement is recorded as inconclusive. The round and composition views count order-controlled records. Existing fingerprints are preserved.
|
|
43
|
+
|
|
44
|
+
- CLI help (#172): the overview groups commands by workflow. `ares help <command>` and `ares <command> --help` print the command help on stdout and exit 0. Existing command forms remain available.
|
|
45
|
+
|
|
46
|
+
- CLI output standard v1 (#158): command results default to human-readable text on stdout. Use `--json` for the existing compact JSON bytes and exit status. Help, version, playbook, Markdown output, raw attempt logs and MCP framing keep their existing forms. Usage errors exit 2 (previously 1), with the diagnostic and usage on stderr. Operational errors stay on stderr with exit 1, and existing retry advice has its own stderr line. Check failures and temporary refusals keep their original exit codes and result stream.
|
|
47
|
+
- External render receipts (#162, new feature, ships in 0.4.0): `ares paper render record <dir> --file PATH --receipt PATH` and `paper render show` (MCP `ares_paper_render_record`, `ares_paper_render_show`) record a document rendered outside ares from the current build. The receipt format `renderReceipt: 1` is renderer-agnostic. Recording refuses unless the receipt's evidence and manuscript hashes match the current build and the file's SHA-256 matches a receipt output. The file and receipt are stored under the derived path `paper/build/render/`, so `accept:paper` is unchanged, and one `paper.rendered` event is appended. A rebuild makes an earlier render stale without deleting it. `review show` and archive preview gain a `render` field. The optional `study.toml` key `[paper] requireRender = true` makes review readiness require a current render. `study export` carries the receipt hashes and renderer identity only. `ares manifest` adds `formats.paperRender: 1` and the ledger event `paper.rendered`. Existing studies, events and results are unchanged.
|
|
48
|
+
|
|
49
|
+
- Paper plan v3 experiment dependencies (#167): `paper/plan.json` may declare up to 200 `dependencies` entries of kind `dataset`, `metric`, `baseline`, `model`, `method` or `software`, each with exactly one nonempty `cites` list of included, identifier-verified keys or a written `waiver` of at most 500 UTF-8 bytes. `paper check` then adds blocking `uncited-dependency` (no declared key occurs in manuscript prose, or a cited key is no longer included and identifier-verified) and, for experiment studies with a protocol, `undeclared-metric` (a protocol metric name with no metric dependency of the same trimmed name); `paper plan show` reports dependency coverage `{cited, waived, total}` beside routed coverage. A plan without `dependencies` checks exactly as before, and a waiver alone satisfies a metric dependency. `ares manifest` reports `paperPlan: 3`; 0.3.1 readers refuse v3 plans without rewriting them, and plan-bound evidence stays v2 unless the plan declares figures.
|
|
50
|
+
|
|
51
|
+
- Candidate screen (#170): protocol v1 and v2 accept an optional `screen`. `evaluatorInputs: true` compares the git blob ids of each input mounted only for the evaluator with the blob ids of `git ls-tree -r <commit>`, so a renamed byte copy is refused and no commit file content is read on this host; it needs a sha-1 object-format repository and refuses above 20,000 files per input. `literals` holds 1 to 64 fixed strings of 8 to 200 UTF-8 bytes searched verbatim. `attempt run` screens after the commit is resolved and before any attempt record, budget use or container starts: a hit appends `attempt.screen.refused {commit, hits:[{rule, path, line?}]}` without the matched text and refuses with the recovery step, while a clean screen is summarised in `attempt.started` as `screen:{rules, sha256}`. A protocol without `screen` keeps its hash, seal and flow, and stage protocols screen literals only because they declare no protocol inputs. Only verbatim material is caught. A 0.3.1 reader refuses a protocol carrying `screen` as an unknown field and keeps the new event kind untouched, so screened protocols need 0.4.0 or a compatible reader.
|
|
52
|
+
|
|
53
|
+
## [0.3.1] - 2026-11-10
|
|
54
|
+
|
|
55
|
+
Finish or reconcile running attempts before downgrading to 0.3.0.
|
|
56
|
+
|
|
57
|
+
- Study-scoped executor container names (#149, product fix): a container name now derives from the study id together with the attempt id, so two studies that repeat one attempt identity on the same executor no longer collide and end `unknown` with `container isolation verification failed`. Each stage record stores the name it launched with; a record written before this change carries none and keeps resolving `ares-<attemptId>-<stage>[-<pipelineStage>]` for inspect, reconcile and absence confirmation. Isolation verification still refuses a foreign or leftover container that carries the new name, and the watchdog, cleanup and adoption paths use the recorded name rather than recomputing one. No record version changes and existing attempts stay readable.
|
|
58
|
+
|
|
59
|
+
- Reuse request warning (#150, product fix): eligible requests outside a matching investigation run still run fresh and return additive, non-persisted warnings with code `outside-investigation`, cause and nextStep. CLI/MCP result shapes are otherwise unchanged; no new command or flag is added.
|
|
60
|
+
|
|
61
|
+
- Task snapshot archive (#148): `ares attempt run` now creates the task archive with the shared content-only tar rule (`COPYFILE_DISABLE=1 tar --no-xattrs`, also used for stage logs) and checks every streamed member against the staged task files. An AppleDouble `._*` member or any member that differs from the staged files is refused by name, so a macOS controller no longer ships extended-attribute metadata to a Linux executor. The frozen task tree hash is unchanged and pinned by a test.
|
|
62
|
+
|
|
63
|
+
- Reuse rematerialization r2 preparation (#63 T3): export existing source/fault helpers without changing their implementations, add an arm-neutral fresh/eligible fixture runner and a separate create-once superseding setup receipt. Per-case stage hashes and fault states must equal the original amendment; all frozen inputs, labels, v1/v2 seals and the original Reuse receipt stay unchanged. Phase parent CPU, subprocess unknowns and wall clocks stay distinct. This preparation step contains no measurement; the completed T3 runs are reported separately below. The r2 developer receipt names the original setup seal as superseded before use; invalid r2 receipts refuse instead of falling back. Earlier setup verification may report changed code and never rewrites history.
|
|
64
|
+
|
|
65
|
+
- Reuse admission (#64, product fix): a candidate stage is no longer reused from a source attempt that is not `succeeded`. A `cancelled` or `unknown` attempt that left its sealed stages intact used to produce a verified hit; it now misses as `ineligible-source` and the stage runs fresh. A valid digest alone never makes an interrupted or semantically stale source eligible, so the rule only narrows reuse: no stage is added, no stored byte or format changes, and a hit from a succeeded source is unaffected.
|
|
66
|
+
|
|
67
|
+
- Reuse source rematerialization amendment (#63 T3a): `integration-check` reports the Reuse arm as `integrated-rematerialized-source`. A deterministic, code-bound setup rebuilds each case's source stage outputs from that case's own frozen `source.workload` with the v1 workload arithmetic, at every declared seed, as the producer's own payload bytes, and a separate create-once receipt seals the setup. All ten cases that declare a source are rebuilt: four healthy and six rebuilt healthy and then given their own declared fault, so the fault suites reach the reuse path instead of being refused by the setup. Corruption changes a retained payload after the seal so the sealed manifest hash no longer matches; pruning disposes the rebuilt stages through the retention prune path; an interrupted source is recorded `cancelled` or `unknown` after its candidate stages were sealed. The admission check is a fake-runner test per fault and requires the reuse path itself to refuse all three stages with its own reason and admit none. The seal binds the setup modules including the fault-injection code, the corpus index, all twelve input hashes, the per-case workload and stage hashes, inherited thresholds/denominators and the immutable v1 parent; `freeze-reuse-rematerialization` and `verify-reuse-rematerialization` verify it and refuse drift. Evaluator labels are never read, so no expected file enters the seal. Outcomes stay `null` with zero trial executions, and the setup's own cost is recorded separately in the materialization dimensions while every other clock stays `unknown`.
|
|
68
|
+
|
|
69
|
+
- Supervision snapshot integration (#63 T2b): pin the closed exported snapshot with source-owned evaluated triples and evaluatedSuppressed. Independent producer-generated unit vectors replace hand-authored snapshots; frozen v1/v2 corpora, labels, receipts and baseline bytes stay unchanged. Absence scoring requires exact rule/task/revision coverage, with gaps and retention overflow remaining insufficient. Intent `none` requires all three rules; wrong/false proposal burden remains counted from presence, and zero helpful actions reports 0. No treatment trial or runtime hub/model/network call is added by this reader. Its unsealed fixture envelope requires evaluated and evaluatedSuppressed; earlier incomplete envelopes refuse with a restore-from-producer next step.
|
|
70
|
+
|
|
71
|
+
- Supervision corpus v2 amendment (#63 T2c-B): separate create-once freeze/verify receipt binds the approved v2 protocol/join method, inherited budgets/thresholds/denominators, all input/expected bytes and the immutable v1 parent. Integration-check keeps v1 unsupported and adds twelve format-covered v2 cases with null outcomes and zero runs. The intent join uses action/rule/task/current revision, never producer trigger strings; the 2026-11-10 ruling separates exclusive case outcomes from observed wrong/false proposal burden. Always-wrong proposals consume the false-proposal budget even when missing desired-rule coverage leaves the case insufficient. Absence scoring remains pending source-owned evaluated coverage; no evaluator, treatment, hub or model call is added.
|
|
72
|
+
|
|
73
|
+
- Execution evaluation (#63 T3/T4): preserve immutable paired Diagnose/Reuse and Supervision v2 shadow receipts and publish the evidence-bound disposition report and closeout. Diagnose is insufficient evidence, Reuse is restricted after failed performance gates, and Supervision is at most retained in shadow mode. Lineage remains read-only utility, eligible reuse stays off by default with explicit operator opt-in, and advisory mode remains off without separate authorization. Human timing and live/native/account benefits are not inferred from synthetic observations.
|
|
74
|
+
|
|
5
75
|
## [0.3.0] - 2026-11-10
|
|
6
76
|
|
|
7
77
|
N-1 compatibility for 0.3.0 is against **0.2.1**, the latest published patch of the 0.2 minor line. The installed-package `bun scripts/n1-check.ts` check passed on the prepared 0.3.0 candidate; the existing networked `n1` CI job repeats it and remains required by `ci-ok`.
|
package/README.md
CHANGED
|
@@ -57,7 +57,7 @@ ares lit bib study # writes study/refs/references.bib
|
|
|
57
57
|
ares cite check study draft.md # exit 1 on unknown or unverified [@keys]
|
|
58
58
|
```
|
|
59
59
|
|
|
60
|
-
`ares playbook` prints the full standalone workflow and its rules.
|
|
60
|
+
`ares playbook` prints the full standalone workflow and its rules. Command results default to text. Views omit internal hashes and use relative times. Checks put findings first and list skipped executor prerequisites. Preview commands print the confirmation command for the reviewed inputs. The `lit list` table shows identifier, year, status, verification and title. Include `--json` when you need authors or abstracts. Use `--json` for compact machine output on commands that support it, `--color=auto|always|never` to control color, or `--ascii` for ASCII markers. Results go to stdout and diagnostics go to stderr. Usage errors exit 2. Run `ares --help` for the grouped overview or `ares help <command>` for usage, flags and examples.
|
|
61
61
|
|
|
62
62
|
`lit search --intent lexical|semantic|background` records why a query was issued: exact terms and acronyms, a concept description, or adjacent foundations. Without it the `lit.search` event keeps its earlier shape and reports as `unspecified`. Each candidate a search creates stores that search's id (`firstQuery`, `search-<n>` by order in the ledger); later merges never change it, and candidates from older studies have none. `lit queries` lists every search with its intent, sources, added/merged counts and how many of the candidates it first added are now included, excluded or still new, plus a per-intent summary, the queries with no included yield and the count of unattributed candidates. ares does not write, rank or embed queries. `study export --bundle` keeps query text out and adds the intent to `lit.search` rows and a per-intent summary to `counts.litQueries`.
|
|
63
63
|
|
|
@@ -153,7 +153,7 @@ ares attempt cancel experiment <id> --reason "stop this run"
|
|
|
153
153
|
|
|
154
154
|
Executor hosts need `tar --no-xattrs` support (GNU tar >=1.27 or bsdtar). Unsupported implementations such as BusyBox tar fail with the generic "stage log collection failed" executor error; ares does not fall back to archives containing metadata.
|
|
155
155
|
|
|
156
|
-
Create the executor workdir on that host, owned by its user with mode `0700`. The path is required and absolute; a shared `/tmp` default is not used. `executor check` reports the Docker server version, image availability and non-root uid:gid, and may pull missing images. It stores the alias, never SSH credentials.
|
|
156
|
+
Create the executor workdir on that host, owned by its user with mode `0700`. The path is required and absolute; a shared `/tmp` default is not used. `executor check` reports the Docker server version, image availability and non-root uid:gid, and may pull missing images. Text mode reports independent probes and marks checks with failed prerequisites as skipped. The JSON and MCP paths stop on the first failure. It stores the alias, never SSH credentials.
|
|
157
157
|
|
|
158
158
|
The task contains `task.md`, evaluator entrypoint/data under `evaluator/`, and optional `rubric.md`. Use regular files only, at most 500 files and 64 MiB total; symlinks are refused. A protocol has this shape (the pinned BusyBox image below can run the synthetic shell fixtures):
|
|
159
159
|
|
|
@@ -187,11 +187,16 @@ For v1 protocols with inputs, `executor check` requires and reports Python3 on t
|
|
|
187
187
|
|
|
188
188
|
Before admission and when preparing a stage launch, ares verifies input manifests outside the launch claim/control transaction and refuses mismatches naming the input. Inside the short launch claim it rechecks that current input identities still match the frozen attempt before starting the container. The design seal and protocol identity bind names, hashes and mounts, so locator-only edits preserve approval; content-hash or mount edits require design approval again. Attempts freeze path-free descriptors plus `verifiedInputs`; stage receipts contain mount targets only. Reconciliation resolves locators from the current design only when its input identities match the frozen attempt, otherwise it names the restore step. Input inspection checks stage targets, read-only flags and source isolation rather than requiring the current locator to equal an already-running mount. An evaluator blocked before launch by input verification stays pending; after restoring the input, reconcile re-verifies and launches that stage instead of marking it lost. There is no locator store. Study bundles export input names and verified hashes only. V1 protocols without inputs retain their existing hashes, raw-byte design bindings and execution behavior; earlier readers refuse the optional inputs field rather than silently accepting it. Network remains none, and candidate outputs remain limited to 500 files / 256 MiB (pass adapters rather than full model weights).
|
|
189
189
|
|
|
190
|
+
A protocol may also refuse material held out from the candidate before any attempt starts: `screen: {"evaluatorInputs": true, "literals": ["<fixed string>"]}`. `evaluatorInputs` compares the git blob ids of each input mounted only for the evaluator with the blob ids of `git ls-tree -r <commit>`, so a renamed byte copy is caught without reading any commit file content here; it needs a sha-1 object-format repository and refuses above 20,000 files per input. `literals` holds 1 to 64 fixed strings of 8 to 200 UTF-8 bytes, searched verbatim over the candidate commit's files. `attempt run` screens after the commit is resolved and before any attempt record, budget use or container exists: a hit appends `attempt.screen.refused {commit, hits: [{rule, path, line?}]}` with the rule and path only, never the matched text, and refuses with the remove-the-material-or-change-the-design step; a clean screen appears in `attempt.started` as `screen: {rules, sha256}`. Only verbatim material is caught, so transformed, compressed or paraphrased material passes. Stage protocols declare no protocol inputs and therefore screen `literals` only.
|
|
190
191
|
|
|
191
192
|
Only the evaluator's `/result/metrics.json` supplies metrics: at most 64 KiB, exactly the declared names with finite numeric values, for example `{"score": 7}`. Units and directions come from the protocol. Missing, malformed or undeclared metrics fail at the evaluator stage; candidate-printed scores never become metrics.
|
|
192
193
|
|
|
194
|
+
Task snapshot archives use the shared content-only tar rule (`COPYFILE_DISABLE=1 tar --no-xattrs`) and check streamed members against the staged task files. AppleDouble `._*` or unexpected/mismatched members are refused by name; frozen task tree hashes and receipt formats are unchanged. Offline archive checks do not establish native Docker isolation.
|
|
195
|
+
|
|
193
196
|
Without `--detach`, `attempt run` reconciles until finished. Detached runs and MCP `ares_attempt_run` return while running; call `attempt reconcile` again to advance stages and collect results. States progress from running candidate to running evaluator, then succeeded, failed, cancelled or unknown. A gone container without an exit record becomes unknown (`lost`); reconcile never creates a new attempt. One attempt may be active per study. A host watchdog enforces each stage's wall-clock limit.
|
|
194
197
|
|
|
198
|
+
New stage records store a container name derived from the study and attempt identities; two studies with the same attempt identity no longer share a container name. Inspection, reconciliation, cleanup and watchdogs use the recorded name. Older stage records without it keep their legacy name. Finish or reconcile running attempts before downgrading to 0.3.0, whose reader recomputes the legacy name.
|
|
199
|
+
|
|
195
200
|
The same protocol hash, commit/tree, seed and run return the same attempt. Use `--retry <id>` for a linked new attempt; a different commit or seed is a new attempt, not a reproduction. Every status counts toward study budgets (attempt count, wall hours, GPU hours). `attempt list` returns summaries and whole-study totals for every status regardless of filters or page; default page size 50, maximum 200, with `--offset` for later pages. `attempt show` returns the full record.
|
|
196
201
|
|
|
197
202
|
Raw outputs and logs stay in the private executor attempt directory. The study holds output paths, sha256 and byte counts (regular files only, at most 500 files and 256 MiB total), plus each log stream's path, hash, bytes and truncation flag. Each stdout/stderr copy is capped at 16 MiB; excess log volume does not fail an attempt. `attempt logs` checks the recorded copies and prints tails without changing the study; `--tail` accepts 0..65536 bytes per stream (default 16384), and omitted stage/stream filters return all recorded streams, including completed v2 candidates. Use `--candidate-stage NAME` (MCP `candidateStage`) to select one named current or completed candidate. Combined returned tails are capped at 256 KiB: defaults shrink across many streams, while an oversized explicit tail requires a narrower selection or smaller value. No log content is persisted in the study.
|
|
@@ -234,7 +239,7 @@ ares attempt run experiment --repo ./candidate --commit FULL_SHA --run investiga
|
|
|
234
239
|
ares attempt run experiment --repo ./candidate --commit FULL_SHA --run investigate --reuse eligible --force-fresh --retry SOURCE_ID --detach
|
|
235
240
|
```
|
|
236
241
|
|
|
237
|
-
|
|
242
|
+
Eligible reuse requires the run to match the current selection rule. Outside a matching investigation run, the request still executes fresh and its CLI/MCP result adds `warnings[{code:"outside-investigation", cause, nextStep}]`, naming the cause and advising a matching selection run or dropping `--reuse`; the warning is not persisted. MCP `ares_attempt_run` accepts equivalent `reuse: off|eligible` and `forceFresh` fields. Plan `attempt.run` steps forward the corresponding `reuse` and `force-fresh` arguments admitted by the shared command table. Re-delivery with the same controls returns the existing running or terminal attempt, including force-fresh requests. Changing reuse/force-fresh controls on an existing identity is refused with its recorded controls and an explicit retry hint. Off-mode artifacts are not indexed retroactively. Evaluators, ablation, final and posthoc always execute fresh. Only a `succeeded` source attempt can supply a reuse hit; a cancelled or unknown source is an `ineligible-source` miss even if its stage bytes remain intact. Missing/pruned/corrupt/unsupported sources are reasoned misses with ordinary budget checks. GPU ABI reuse is currently unsupported and falls back to fresh execution.
|
|
238
243
|
|
|
239
244
|
Keys bind the study and frozen selection/reserved-seed population, protocol comparison domain, complete selected stage, full code tree and snapshot digest, exact declared input hashes, seed, producer version/source/runtime and observed executor/platform ABI. A changed code tree therefore misses even if only a downstream stage changed. Unavailable platform facts give a reasoned miss; caller assertions cannot supply them.
|
|
240
245
|
|
|
@@ -263,9 +268,13 @@ ares investigate close experiment --json
|
|
|
263
268
|
|
|
264
269
|
`metric` must be declared in the protocol; its unit and max/min direction come from there. `minSeeds` is 1..the number of declared seeds, and `minDelta` is finite and >=0 in that unit. A new or changed rule adds its raw file hash to the design seal and reopens approval. Identical validated bytes are a no-op, so they cannot erase earlier results by moving the cutoff. Protocol edits that invalidate an existing rule refuse before writing. Studies without selection retain the original design binding and approval.
|
|
265
270
|
|
|
271
|
+
Selection v2 optionally sets `guards: [{metric, maxRegression}]` (up to eight distinct declared nonprimary metrics) and `cost: {metric, free, perUnit}` (one declared `min` metric). A guard compares the direction-adjusted mean change across the paired seeds. Missing measurements make the candidate ineligible. The cost rule caps relative growth against a positive baseline at `free + perUnit * delta`, using the primary paired delta. Lower cost passes this rule. The same gates apply on reserved final seeds. Rules with no optional criteria keep v1 decision semantics.
|
|
272
|
+
|
|
273
|
+
Run `ares selection calibrate experiment --from-run baseline --json` (MCP `ares_selection_calibrate`) after recording the baseline on at least three non-reserved seeds. The default uses the sample standard deviation and assumes independent arms, a conservative assumption when pairing removes shared variation. Use `--null COMMIT` for paired A/A deltas from two commits with the same recorded tree. Both methods default to `--z 2`. Calibration records `runs/<run>/calibration.json` and retains a copy by digest so recalibration does not invalidate older bindings. Add the returned SHA-256 as `calibration: {sha256}` in selection v2 to report `belowNoise` when the sealed `minDelta` falls below the recommendation. The recommendation never changes the rule or restricts eligibility.
|
|
274
|
+
|
|
266
275
|
`investigate show` is read-only. Counting uses the selected run, current protocol hash and `attempt.started` ledger order after the latest recorded `selection.set`. Only the earliest successful attempt per commit/seed counts. Later successes, other-protocol, before-selection, undeclared-seed and missing-start attempts are listed with reasons; failed, cancelled, unknown and excluded records remain in run totals. Labels do not choose the baseline, its commit in the rule does.
|
|
267
276
|
|
|
268
|
-
Each candidate compares its mean primary metric against the baseline on their shared successful seeds. It needs at least `minSeeds` pairs, a direction-adjusted delta strictly above zero and at least `minDelta`. Eligible candidates rank by paired delta, not raw mean, because paired seed sets can differ. An exact best-delta tie yields no winner. Other no-winner reasons are `no-baseline`, `baseline-seeds`, `no-candidate
|
|
277
|
+
Each candidate compares its mean primary metric against the baseline on their shared successful seeds. It needs at least `minSeeds` pairs, a direction-adjusted delta strictly above zero and at least `minDelta`. Eligible candidates rank by paired delta, not raw mean, because paired seed sets can differ. An exact best-delta tie yields no winner. Other no-winner reasons are `no-baseline`, `baseline-seeds`, `no-candidate`, `below-margin` and `constraints` for guard or cost rejection. Means are descriptive, with no significance test.
|
|
269
278
|
|
|
270
279
|
Close refuses while any attempt in the selected run is running, including excluded attempts. It writes `runs/<run>/investigate.json` and `investigate.closed` together. The timestamp-free result includes rule/input hashes, baseline/candidate rows, paired values and means, exclusions, totals and a winner or `null` with its reason. Closing unchanged inputs writes nothing. Show/close starts no attempt, Docker process or hub; the tests use synthetic offline records.
|
|
271
280
|
|
|
@@ -287,6 +296,17 @@ ares idea decide experiment variant-1 pivot --reason "Drop this direction" --att
|
|
|
287
296
|
|
|
288
297
|
Pivot optionally records `--cause` and `--retry-when` (at most 2,000 UTF-8 bytes each); refine refuses these fields. Missing pivot fields export as `not recorded`. Refine adds the uniquely owned commit. Pivot refuses `--commit`, closes further decisions and keeps historical attempts and totals. Evidence is at most 200 existing, non-running, same-study attempt ids from the idea's commits; reasons are at most 2,000 bytes. An untested idea may omit `commit` when added, then omit `--attempts` for a first `refine --commit` or a pivot before testing. Once it has commits, nonempty evidence is required. Investigation rows and winner references carry the owning idea id; journal changes join the result's input hash. Survey studies refuse all selection, idea and investigate commands.
|
|
289
298
|
|
|
299
|
+
An idea may also declare what it expects to move. These fields are optional and older inputs stay valid:
|
|
300
|
+
|
|
301
|
+
```json
|
|
302
|
+
{"id": "aug-mixup", "title": "Synthetic", "hypothesis": "Mixup helps", "commit": "<40-hex>", "category": "data", "bundle": 1,
|
|
303
|
+
"predicts": [{"metric": "accuracy", "expect": "improve", "minDelta": 0.01}, {"metric": "train_seconds", "expect": "no-change"}]}
|
|
304
|
+
```
|
|
305
|
+
|
|
306
|
+
`predicts` holds 1..4 entries, one per declared protocol metric, with `expect` `improve`, `no-change` or `regress` in that metric's direction and an optional finite `minDelta >= 0`. A `no-change` prediction on a metric other than the selection's primary metric requires `minDelta`. `bundle` (1..16) self-declares how many independent changes the commit holds. `idea decide` cannot add or edit predictions. `ares idea categories <dir> --file PATH` writes `design/idea-categories.json` `{v:1, categories:[...]}` (1..32 names) and one `idea.categories.set` event; once it exists, `idea add` refuses an unknown category and names the declared ones. The vocabulary is a planning aid outside the design seal.
|
|
307
|
+
|
|
308
|
+
`ares idea report <dir> [--run RUN] [--window 5]` (MCP `ares_idea_report`) is read-only and advisory: it opens no gate, refuses nothing and schedules nothing. Per idea it reports the investigation's own paired delta for the latest measured commit, prediction timing and outcomes, and unpredicted regressions. A prediction counts only when its idea was added before the first attempt of any of its commits started; later ones are `post-hoc` and never scored. `improve` hits when the delta is positive and at least its `minDelta`, `regress` when negative, `no-change` when the absolute delta is below the selection `minDelta` for the primary metric or the prediction's own `minDelta` otherwise. Per category it counts ideas, measured ideas and hits, with the best primary delta of the last `window` measured ideas and `noRecentGain` when that is <= 0. Ideas with `bundle > 1` are listed under `confounded` and left out of category and search counts. The search is `stalled` when the best eligible primary delta among the last `window` measured ideas is no better than before them (or none is positive), and `untried` lists declared categories without a measured idea. Failed, cancelled and unknown attempts stay in per-idea totals.
|
|
309
|
+
|
|
290
310
|
A conductor can put a no-argument `investigate.close` step after its agent-work hub unit, then bind a local plan gate to that result:
|
|
291
311
|
|
|
292
312
|
```json
|
|
@@ -321,7 +341,7 @@ ares final close experiment
|
|
|
321
341
|
|
|
322
342
|
The final gate binds SHA-256 of the investigate result sha, the ablate result sha or none, and the design binding. Approval requires current closed upstream results. Changed content reopens it; re-close changed upstream inputs and re-approve before final close. Start checks require a reserved seed, the current winner or selection baseline, and final-gate authorization before any Git resolution, record or container. In auto autonomy, final approval is recorded only with a verified candidate start, so failed preparation records no automatic approval.
|
|
323
343
|
|
|
324
|
-
Final is one shot: the first ledger-started attempt for each winner/baseline commit and reserved seed is decisive, whatever its status. Retries stay visible and never replace it. Close refuses running final attempts or missing decisive pairs. It requires the final gate currently approved even for a negative result. Every decisive attempt must succeed and the direction-adjusted paired delta must be positive and at least `minDelta`; otherwise the result is `not_qualified` with a named reason. There is no significance test. Reapproval keeps existing data fixed; old seal/input bindings alone never disqualify it. A changed comparable evaluation identity gives `protocol-changed`; input locator-only and budget-only edits do not change that identity. A winner change after any final attempt, including baseline-only trials, gives `winner-changed` without demanding new-winner pairs and blocks new final starts. Reason priority is winner change, protocol change, first decisive failure status, then below-margin. `runs/final/final.json` and `final.closed` are committed together; unchanged inputs record nothing, unsupported versions are preserved.
|
|
344
|
+
Final is one shot: the first ledger-started attempt for each winner/baseline commit and reserved seed is decisive, whatever its status. Retries stay visible and never replace it. Close refuses running final attempts or missing decisive pairs. It requires the final gate currently approved even for a negative result. Every decisive attempt must succeed and the direction-adjusted paired delta must be positive and at least `minDelta`; otherwise the result is `not_qualified` with a named reason. There is no significance test. Reapproval keeps existing data fixed; old seal/input bindings alone never disqualify it. A changed comparable evaluation identity gives `protocol-changed`; input locator-only and budget-only edits do not change that identity. A winner change after any final attempt, including baseline-only trials, gives `winner-changed` without demanding new-winner pairs and blocks new final starts. Reason priority is winner change, protocol change, first decisive failure status, then below-margin. A v2 rule also applies its guards and cost ceiling to the decisive pairs. `runs/final/final.json` and `final.closed` are committed together; unchanged inputs record nothing, unsupported versions are preserved.
|
|
325
345
|
|
|
326
346
|
After a historical `final.closed` receipt exists, run additional non-reserved seeds/commits with `--run posthoc`. `ares posthoc show experiment` lists all posthoc statuses and metrics labeled `exploratory`. Posthoc work never changes final result bytes, the final input fingerprint or its close receipt, even while an exploratory attempt runs. These are experiment-only commands; survey studies refuse them on CLI and MCP.
|
|
327
347
|
|
|
@@ -331,6 +351,10 @@ Final here means reserved seeds, the frozen Git snapshot and the sealed evaluato
|
|
|
331
351
|
|
|
332
352
|
## Paper and review workflow
|
|
333
353
|
|
|
354
|
+
Use paper check and paper build with --doc slides to validate paper/slides.md using the same evidence placeholders, citation checks and negative-result requirements as the manuscript. The slides use separate rendered Markdown and evidence files. For external decks, use paper render record and paper render show with --doc slides. The manuscript plan and review workflow apply to the manuscript. The derived files are `paper/build/slides.md` and `paper/build/slides.evidence.json`. The slides render and its receipt go under `paper/build/slides.render/`. Slides share the existing `accept:paper` gate. The manifest lists both document names in `paperDocuments`. Slides receipts use `doc: "slides"` on the existing `paper.built` and `paper.rendered` events.
|
|
355
|
+
|
|
356
|
+
Optional paper plan v3 figures bind local files under paper/ to the build. Declare each image by id, file and kind; plots need current-study card/attempt references or a written waiver, and diagrams need neither. Paper check blocks undeclared or missing assets and unresolved plot evidence. Builds record figure hashes and provenance in paper evidence v3, so changed figures reopen review and make old render receipts stale. Each file is capped at 16 MiB, with at most 100 figures. An exact match to recorded artifact bytes is labelled `artifact`; a valid evidence pointer without a byte match is labelled `referenced`. These labels describe the source relationship.
|
|
357
|
+
|
|
334
358
|
A4 renders Markdown from recorded evidence; it does not write a manuscript or run reviewers for you. Write `paper/manuscript.md` (at most 2 MiB) and put measured values in `{{n:REF}}` placeholders, optionally `{{n:REF|.Nf}}` with N from 0 to 6. At most 5,000 numeric and literal placeholders are allowed together. Use `{{lit:TEXT}}` for a reviewer-visible literal such as a year or cohort label. Every literal is listed by the check; it is an explicit exception, not a measured-value match.
|
|
335
359
|
|
|
336
360
|
| Ref | Closed source |
|
|
@@ -347,6 +371,24 @@ ares paper check experiment --json
|
|
|
347
371
|
ares paper build experiment --json
|
|
348
372
|
```
|
|
349
373
|
|
|
374
|
+
The venue-formatted document is rendered outside ares. `paper render record` stores what was rendered from which build; it never runs a renderer or judges whether the rendering is faithful:
|
|
375
|
+
|
|
376
|
+
```sh
|
|
377
|
+
ares paper render record experiment --file paper.pdf --receipt receipt.json --json
|
|
378
|
+
ares paper render show experiment --json
|
|
379
|
+
```
|
|
380
|
+
|
|
381
|
+
The receipt is `renderReceipt` v1, renderer-agnostic: `{v, tool, version, environment, evidenceSha256, manuscriptSha256, template, outputs: [{name, sha256, pages}]}`. Recording refuses before any write unless the receipt's evidence and manuscript hashes equal the current build and the file's SHA-256 equals one receipt output. The file (regular file, at most 64 MiB) and the exact receipt bytes, unknown fields included, are stored under `paper/build/render/` and one `paper.rendered` event records the hashes, size and renderer identity. That path is derived output, so `accept:paper` stays unchanged. An identical file and receipt record nothing. A newer receipt version is refused and left unchanged. A rebuild with a new evidence hash makes the render stale without deleting it. `review show` and archive preview report `render.current`. With `requireRender = true` under `[paper]` in `study.toml`, review readiness needs a current render. `study export` carries the receipt hashes and closed renderer tokens, never the document bytes. MCP uses `ares_paper_render_record` (absolute `file` and `receipt`) and `ares_paper_render_show`.
|
|
382
|
+
|
|
383
|
+
A no-argument `paper.render` plan step runs a renderer and records its receipt through the same path. The renderer command is machine-local, like the executor settings: it is stored under the family home (`$AGENTHUB_HOME/research/renderers/<study-id>.json`), never in `plan.json` or any committed study file, and a `renderer.json` in the study is refused. For agent-tex:
|
|
384
|
+
|
|
385
|
+
```sh
|
|
386
|
+
ares renderer set study --command '["atex","ares","build","{study}","{out}"]' --timeout-s 600
|
|
387
|
+
ares renderer check study
|
|
388
|
+
```
|
|
389
|
+
|
|
390
|
+
`{study}` is the study directory and `{out}` a fresh output directory outside the study, where the renderer writes the document and `receipt.json`. The step requires a current `paper build`, runs the command in the study directory with the configured wall time (default 600 s), then records the render and emits `{sha256}` of the rendered output for a downstream `plan:<id>` gate. No renderer, a nonzero exit, a timeout, or a missing or mismatching receipt fails the step with the reason and writes nothing. A retry with an unchanged build and identical output records nothing. The step starts no agent and no network request of its own; isolation is the renderer's. `renderer check` reads the configuration and looks the program up on PATH without running it. MCP uses `ares_renderer_set`, `ares_renderer_show` and `ares_renderer_check`.
|
|
391
|
+
|
|
350
392
|
In experiment prose, other digits give `bare-number`; matching a free number against an existing metric is never allowed. Digits are allowed in link targets, placeholder/literal payloads and line-start ordered-list markers. Citation keys may contain digits, but bracket prose is checked: only locator terms (`p.`, `pp.`, `sec.`, `§`, `ch.`, `chap.`, `fig.`, `tbl.`, `table`, `eq.`, `l.`, `ll.`, `para.`) followed by integers, ranges or lists are exempt. `[@key, improved accuracy by 12.5%]` still fails. Inline/fenced/indented code numbers are nonblocking but listed as `codeNumbers` (first 500 values with line/column) and `codeNumberCount` (total). Paragraph and list continuations are prose. Unknown or unverified citation keys fail, including citations inside literal escapes; verification means identifier existence plus title/year match, never support for a claim.
|
|
351
393
|
|
|
352
394
|
Citation hygiene findings (both modes) carry `severity: "warning"`, a line/column and the section heading path: `adjacent-duplicate-citation` (a key twice in one bracket group or in two adjacent groups with no prose between), `citation-stack` (a group with more than `maxGroup` keys, default 6), `repeated-bundle` (the same set of 3+ keys in more than `maxBundleRepeats` places, default 2), `bare-identifier` (an arXiv id, DOI or URL in prose outside citations, link targets, code and reference definitions) and `duplicate-heading` (identical sibling headings). Warnings do not fail `paper check` or `paper build`. An optional `study.toml` next to `study.json` sets thresholds and makes listed codes blocking; unknown keys or codes refuse:
|
|
@@ -360,7 +402,7 @@ blocking = ["citation-stack", "bare-identifier"]
|
|
|
360
402
|
|
|
361
403
|
Negative results must be visible: when final.json exists, include `{{n:final.status}}`; when the closed investigation has no winner, include `{{n:investigate.reason}}`. Code examples, link targets, HTML comments and reference-definition metadata cannot satisfy this rule. Include a reason or numeric ref only when that source field exists; null values stay unresolved. The check is read-only and reports positions for every finding; a failing CLI check exits 1. Survey studies check citations without the experiment bare-number rule and refuse experiment placeholders with `unresolved-ref`; they can build citation-only manuscripts.
|
|
362
404
|
|
|
363
|
-
An optional `paper/plan.json` declares section citation scopes. Assign bibliography keys first, then provide a version-1 JSON plan, for example:
|
|
405
|
+
An optional `paper/plan.json` declares section citation scopes and, in version 3, the experiment dependencies the manuscript must cite or waive. Assign bibliography keys first, then provide a version-1 JSON plan, for example:
|
|
364
406
|
|
|
365
407
|
```json
|
|
366
408
|
{"v":1,"sections":[{"id":"introduction","heading":"Introduction","cites":["synthetic2026"]}]}
|
|
@@ -371,7 +413,7 @@ ares paper plan set study --file routing.json
|
|
|
371
413
|
ares paper plan show study --json
|
|
372
414
|
```
|
|
373
415
|
|
|
374
|
-
`--file -` reads bounded JSON from stdin; MCP uses `ares_paper_plan_set` with `plan` and `ares_paper_plan_show`. Plans
|
|
416
|
+
`--file -` reads bounded JSON from stdin; MCP uses `ares_paper_plan_set` with `plan` and `ares_paper_plan_show`. Plans with neither dependencies nor writing points store `v: 1`; a plan containing any point stores `v: 2`, and a plan containing any dependency stores `v: 3`. Authoring input may omit `v`, and empty `points`/`dependencies` arrays are removed so the lower-version bytes stay unchanged. Explicit v1 with points or v1/v2 with a nonempty `dependencies` refuses; unsupported stored versions are preserved and refused. A formatted plan is at most 64 KiB, with at most 64 unique section ids/headings, 300 distinct keys per section and 200 dependencies whose ids are unique. Ids are lowercase alphanumeric hyphenated slugs of at most 64 characters. Keys must currently be included and identifier-verified; unknown fields and stale/excluded references refuse before mutation. Show reports included references routed / total and dependency coverage cited / waived / total. Routing is declared by the caller, never generated or judged semantically by ares.
|
|
375
417
|
|
|
376
418
|
Heading content after ATX/Setext markers must match exactly, including inner whitespace and inline Markdown; multiline Setext content retains its LF/CRLF text. Code/comment headings are ignored. Text before the first planned heading has no scope restriction; ordinary citation verification still applies. Only another matching planned heading changes scope, so an unplanned heading does not silently clear the prior scope. `out-of-scope-citation` is blocking and includes the section id and source position. `unplanned-section` (unplanned level-2 heading) and `unrouted-reference` (once per included reference with no scope) are fixed warnings and do not block build; they are separate from the configurable hygiene codes above.
|
|
377
419
|
|
|
@@ -393,7 +435,18 @@ Every occurrence is checked from its anchor to the next well-formed point anchor
|
|
|
393
435
|
|
|
394
436
|
Optional `evidence` has at most 64 local `card:<paper-id>` or `attempt:<16-hex-id>` references per point, each at most 4,096 UTF-8 bytes. Set/show requires them to resolve; disappearance later is reported by paper check. Attempt lookup reads only the addressed payload and scans at most 4,096 physical run directories; archive an oversized study before retrying. Resolution establishes local record existence only, without a success, claim-support or citation-entailment assertion. Review report `location` may be the exact token `point:<id>` (apart from surrounding whitespace). For current-build reports containing such locations, review show adds `openByPoint` with unresolved finding ids and open/blocking counts; it does not resolve the id against the plan or infer support. Without points, section-scope checks and v1 plan behavior remain unchanged.
|
|
395
437
|
|
|
396
|
-
|
|
438
|
+
A version-3 plan also declares the experiment dependencies a manuscript relies on, so results on a dataset, with a metric, against a baseline, on a base model, method or software cannot stay uncited. Each entry has a unique slug `id`, one `kind` (`dataset`, `metric`, `baseline`, `model`, `method` or `software`), a trimmed nonempty single-line `name`, and exactly one nonempty `cites` list or a written `waiver` of at most 500 UTF-8 bytes. Dependency keys pass the same included, identifier-verified and unique-key rules as section keys, and there are at most 200 entries. For example:
|
|
439
|
+
|
|
440
|
+
```json
|
|
441
|
+
{"v":3,"sections":[{"id":"introduction","heading":"Introduction","cites":["synthetic2026"]}],
|
|
442
|
+
"dependencies":[
|
|
443
|
+
{"id":"ds-main","kind":"dataset","name":"synthetic benchmark","cites":["synthetic2026"]},
|
|
444
|
+
{"id":"m-acc","kind":"metric","name":"accuracy","waiver":"standard definition, stated in Section 4.1"}]}
|
|
445
|
+
```
|
|
446
|
+
|
|
447
|
+
With `dependencies` present, `paper check` adds two blocking findings. `uncited-dependency` fires when none of an entry's keys occurs in manuscript prose, or a cited key is no longer included and identifier-verified; citing one of its keys or replacing `cites` with a `waiver` clears it. `undeclared-metric` fires in a study with a protocol when a protocol metric name has no `metric` dependency of the same trimmed name; a cited or waived metric dependency satisfies it. A plan without `dependencies` checks exactly as before, and dependencies are never inferred from the protocol or the manuscript.
|
|
448
|
+
|
|
449
|
+
Build refuses every blocking finding before writes. It commits `paper/build/manuscript.md` (rendered values), `paper/build/evidence.json` (`paperEvidence: 1` without a plan, v2 with a plan that omits figures, v3 with declared figures) and `paper.built` together. Plan-bound evidence includes the exact raw `paper/plan.json` SHA-256, so changing, adding or removing the plan invalidates the current build/review even if rendered prose is unchanged. Plan absence preserves the prior check report and v1 evidence bytes. The evidence map keeps the input manuscript hash and each active placeholder's syntax, value, rendering, position, source file and raw source hash; literal sources point to the input manuscript. Outputs are bounded to 2 MiB rendered Markdown and 8 MiB evidence. Identical outputs with a matching receipt are a no-op. Changed provenance rebuilds evidence even if rendered text is identical; unknown evidence versions preserve original bytes. The returned `manuscriptSha256` is the rendered output hash; `evidenceSha256` is the review's build identity.
|
|
397
450
|
|
|
398
451
|
Have reviewers inspect the current output, evidence, literals and code-number list. Save each report and add it against the current evidence hash:
|
|
399
452
|
|
|
@@ -423,6 +476,8 @@ A finding may also carry `repair` (`edit`, `paragraph` or `section`; omitted mea
|
|
|
423
476
|
|
|
424
477
|
Survey reviews can also answer `checklist.survey`, six booleans: `taxonomyPrinciple`, `noEnumeration`, `specificGaps`, `citationRelations`, `selectionReported`, `scopeControl`. `ares review checklist` (MCP `ares_review_checklist`) prints the question for each key, so every reviewer answers the same wording. `study.toml` `[review] surveyChecklist` is `off`, `show` or `require` (default `show` for survey studies, `off` for experiments). `show` lists each report's answers in `review show` under `surveyAnswers` and in its `checklists` row, including false answers; `off` returns an empty `surveyAnswers` array and omits the survey block from `checklists`. An unreadable `study.toml` keeps that default and adds one `review-survey-settings` note under `info`, never under `unmet`. `require` refuses a report without the block at `review add`; it requires the block to be present, not true. Answers never become a gate condition, and unknown keys inside `survey` refuse.
|
|
425
478
|
|
|
479
|
+
A report may carry an optional reviewer read-back, `"readback": {"claims": [...]}`: 1 to 8 single-line claims of at most 500 Unicode characters each, saying what the built manuscript claims to show. Reviewers write the read-back from the manuscript before reading the paper plan. `review show` lists `readbacks` (review id, reviewer, model family, claims) for current-build reports and, when the plan has writing points, `planClaims` (point id and claim) so a person reads the two lists together. ares never matches or scores them, and the read-back is not a finding and never changes readiness. `study.toml` `[review] readback` is `off`, `show` (default) or `require`: `off` returns an empty `readbacks` array, `require` refuses a report without the block at `review add`. An unreadable `study.toml` keeps `show` and adds one `review-readback-settings` note under `info`. Reports without the block keep their bytes and event hashes.
|
|
480
|
+
|
|
426
481
|
The global `review` gate needs a clean current check/build, at least two distinct model families for that evidence hash, and no open blocking finding. Checklist answers are shown, including false answers, rather than adding a separate approval condition. Readiness names every unmet condition. Approval is checked in the shared command under the study lock; reject still needs a reason but no readiness. No current command auto-requires the review gate. The gate binds both output hashes and sorted added/resolved event hashes for that build. A changed build, added review or resolution reopens it; old reviews stay in the ledger but do not count toward a new build.
|
|
427
482
|
|
|
428
483
|
A no-argument `paper.build` conductor step emits `{sha256}` of the committed evidence file; a downstream `plan:<id>` gate binds it. That local gate does not replace the global manuscript `review` gate. MCP paper/review operations never start the controller loop. Claim-to-passage evidence and its contradictions await [agent-hub#931](https://github.com/STAIxBWLB/agent-hub/issues/931); readiness currently reports `claims: unavailable (STAIxBWLB/agent-hub#931)` without blocking on it. Claim verdicts stay outside ares. LaTeX/PDF container builds and venue templates are out of scope. Acceptance uses offline synthetic fixtures, not live hub/executor DAG proof.
|
|
@@ -480,7 +535,7 @@ A separate read-only library mapper accepts agent-hub public `GuidanceReadResult
|
|
|
480
535
|
|
|
481
536
|
`controlled-lane` authoring must name source execution refs for its measured stages, but current real imports and end-to-end evaluation are always unavailable. Synthetic comparisons can be compatible only, never matched or host-observed. Unknown usage and sampling remain unknown; model/config/input/environment/toolset/budget drift stays explicit. No raw transcript, environment or assurance claim is imported. Nothing starts a probe, calls a model or mutates a hub. Local contrast/composition/adoption and the read-only Harness rounds panel are available; all dispositions remain experimental and fixture-only. Frozen prior-experience controls are described below. See [the T1 schema and fixture boundary](docs/design/harness-rounds.md) for fields, source strengths, limits and what remains unverified.
|
|
482
537
|
|
|
483
|
-
After importing admitted fixtures, use the current `transitions.fingerprint` from `ares harness show --json` in each form:
|
|
538
|
+
After importing admitted fixtures, use the current `transitions.fingerprint` from `ares harness show study --json` in each form:
|
|
484
539
|
|
|
485
540
|
```sh
|
|
486
541
|
ares harness contrast study round-one --file contrast.json
|
|
@@ -491,7 +546,7 @@ ares harness adopt study round-one --file adoption.json
|
|
|
491
546
|
ares harness adopt study round-one --file adoption.json --confirm CONFIRMATION_FINGERPRINT
|
|
492
547
|
```
|
|
493
548
|
|
|
494
|
-
Contrasts distinguish deterministic-check, blinded-judgment and actor-claim provenance and cite exact admitted probe/output hashes. Per-section keep/drop/revise decisions link current contrasts. A new successor remains unexecuted until its own exact fixture import; preserving identical previously executed bytes reuses that record instead of counting another sample. Adoption must cite the selected arm's admitted execution in checks (an identical-byte successor may reuse its reported existing execution); missing execution refuses before preview. It records a distinct independent deterministic check (unavailable for all current fixtures), first previews, then writes adopted-experimental disposition and closure together under the harness gate. Separate `harness close` records baseline-kept, inconclusive or withdrawn without adoption. Every closure immutably binds the round/evidence hashes, outcome, actor and reason; stale closures remain visible in history. Stale confirmations refuse; changed evidence makes old readiness stale, and definition changes reopen it without rewriting decisions. Correctness remains unavailable and transfer not demonstrated. Baseline preservation and inconclusive are normal closures, not scientific outcomes. The console Harness rounds panel shows the same comparison/edit-to-evidence table with no action or implicit source reads. See [the bounded forms and readiness contract](docs/design/harness-rounds.md#contrast-composition-and-experimental-closure).
|
|
549
|
+
Contrasts distinguish deterministic-check, blinded-judgment and actor-claim provenance and cite exact admitted probe/output hashes. A blinded contrast may declare two presentations with reversed order. Agreement on the same side determines improved or regressed, two ties yield unchanged, and disagreement yields inconclusive. The view reports `orderControl` per contrast and counts per round and composition section. Per-section keep/drop/revise decisions link current contrasts. A new successor remains unexecuted until its own exact fixture import; preserving identical previously executed bytes reuses that record instead of counting another sample. Adoption must cite the selected arm's admitted execution in checks (an identical-byte successor may reuse its reported existing execution); missing execution refuses before preview. It records a distinct independent deterministic check (unavailable for all current fixtures), first previews, then writes adopted-experimental disposition and closure together under the harness gate. Separate `harness close` records baseline-kept, inconclusive or withdrawn without adoption. Every closure immutably binds the round/evidence hashes, outcome, actor and reason; stale closures remain visible in history. Stale confirmations refuse; changed evidence makes old readiness stale, and definition changes reopen it without rewriting decisions. Correctness remains unavailable and transfer not demonstrated. Baseline preservation and inconclusive are normal closures, not scientific outcomes. The console Harness rounds panel shows the same comparison/edit-to-evidence table with no action or implicit source reads. See [the bounded forms and readiness contract](docs/design/harness-rounds.md#contrast-composition-and-experimental-closure).
|
|
495
550
|
|
|
496
551
|
## Reviewed harness lesson candidates
|
|
497
552
|
|
|
@@ -606,11 +661,13 @@ Read local execution references and their recorded relationships with `ares line
|
|
|
606
661
|
|
|
607
662
|
MCP exposes the same reads as `ares_lineage_show({study, root?, cursor?})` and `ares_lineage_compare({study, attempts?, candidates?})`. An MCP root is a local `ExecutionReferenceV1` with `v: 1`, `tool: "ares"`, `projectKey`, `kind`, native `id`, and optional `revision`/`sha256`. Both tools are read-only and closed-world. Reads do not acquire study locks, repair files, read executor output bodies, contact a hub or executor, or start network requests. Source receipts can remain historical or unavailable; an artifact digest is not proof that its bytes are retained. Synthetic fixture checks establish surface parity only, with no measured diagnosis or usability benefit claimed.
|
|
608
663
|
|
|
609
|
-
## Evaluation fixtures and
|
|
664
|
+
## Evaluation fixtures and treatment evidence
|
|
610
665
|
|
|
611
666
|
The repository preregisters synthetic Diagnose, Reuse and Supervision comparisons and preserves the frozen corpus, thresholds and T2a baseline receipts. These developer scripts are separate from product study results. The read-only `bun scripts/execution-eval.ts integration-check` verifies the seal and committed code binding and reports all 36 frozen cases; it launches no treatment arm, writes no receipt and reports zero treatment observations.
|
|
612
667
|
|
|
613
|
-
Diagnose has a read-only adapter to the actual lineage/comparison readers.
|
|
668
|
+
Diagnose has a read-only adapter to the actual lineage/comparison readers. The separate Reuse r2 amendment rematerializes sources from frozen source workloads with setup costs recorded separately; it supersedes the original opaque-byte source setup without changing the v1 corpus or seal. Supervision consumes the producer-owned snapshot pinned to agent-hub#1221 at `a470ebbd5d809e421c6fc82fab8a69434c1b2e08`. The original v1 Supervision inputs remain unsupported; a separately sealed v2 corpus supplies twelve T1-fact inputs and intent labels. Check-only integration and freeze/verify modes launch no treatment trial and create no product result authority. The v2 intent join counts present wrong/false proposals independently of absent-action coverage; the current snapshot cannot establish correct non-triggers.
|
|
669
|
+
|
|
670
|
+
Authorized CPU-only synthetic T3 trials are now recorded in the [measured treatment report](docs/verification/execution-eval-t3-report.md), with fresh controls for Diagnose and Reuse, immutable receipts and full denominators. Diagnose remains insufficient evidence: parity is by construction and human time-to-find is unmeasured. Reuse is restricted rather than adopted because the eligible-compute and no-hit-overhead gates fail. Supervision is at most retained in shadow mode, insufficient for adoption; arms A and C were not executed, and the twelve changed-deliverable misses remain unrelabeled. These are harness-observed fixture results, not native isolation, human benefit or live-board evidence. The [T4 closeout](docs/verification/execution-eval-t4-status.md) records evidence hashes, defaults and remaining live-evidence gaps: lineage remains read-only utility, eligible reuse stays off by default with explicit operator opt-in and no performance/cost claim, and advisory mode remains off without separate authorization. The sealed v1/v2 corpora and r2 receipt remain unchanged.
|
|
614
671
|
|
|
615
672
|
The separate [guidance-improvement preregistration](docs/verification/harness-eval-protocol.md) includes deterministic prerecorded controls through `scripts/harness-eval.ts`. Controls, fixture conformance and metadata decoding do not establish real model behavior, transfer, native isolation or measured cost benefit. Treatment trials and native/account/model proof still need their own authorization and evidence.
|
|
616
673
|
|
|
@@ -731,9 +788,11 @@ Approvals use the existing CLI/MCP gate handler, record the actor and bind the c
|
|
|
731
788
|
| `runs/final/final.json` | one-shot qualification, decisive attempts and all final attempts |
|
|
732
789
|
| `runs/<run>/investigate.json` | deterministic winner/no-winner result, candidate rows and totals |
|
|
733
790
|
| `paper/manuscript.md` | source Markdown with numeric refs and literal escapes |
|
|
734
|
-
| `paper/plan.json` | optional citation scopes
|
|
735
|
-
| `paper/
|
|
736
|
-
| `paper/build/
|
|
791
|
+
| `paper/plan.json` | optional citation scopes, experiment dependencies, writing points and figures |
|
|
792
|
+
| `paper/slides.md` | optional source Markdown with the same evidence syntax |
|
|
793
|
+
| `paper/build/manuscript.md` and `paper/build/slides.md` | rendered documents |
|
|
794
|
+
| `paper/build/evidence.json` and `paper/build/slides.evidence.json` | separate document evidence, including figure hashes for opted-in manuscripts |
|
|
795
|
+
| `paper/build/render/` and `paper/build/slides.render/` | external renders and their receipts |
|
|
737
796
|
| `proposals/skills/<name>.md` | bounded versioned skill proposal, hash-bound to its ledger receipt |
|
|
738
797
|
| `proposals/lessons.json` | receipt-bound reviewed harness lesson candidates |
|
|
739
798
|
| `executor.json` | executor kind, optional SSH alias and required workdir |
|
|
@@ -792,6 +851,8 @@ ares status <dir> [--json]
|
|
|
792
851
|
ares study export <dir> --bundle DIR [--list] [--json]
|
|
793
852
|
ares scope <dir> --file PATH|- [--json]
|
|
794
853
|
ares idea add <dir> --file PATH|- [--json]
|
|
854
|
+
ares idea categories <dir> --file PATH|- [--json]
|
|
855
|
+
ares idea report <dir> [--run RUN] [--window N] [--json]
|
|
795
856
|
ares idea decide <dir> <id> <refine|pivot> --reason TEXT [--attempts ID[,ID...]] [--commit SHA] [--cause TEXT] [--retry-when TEXT] [--json]
|
|
796
857
|
ares investigate show <dir> [--json]
|
|
797
858
|
ares investigate close <dir> [--json]
|
|
@@ -802,6 +863,7 @@ ares posthoc show <dir> [--json]
|
|
|
802
863
|
ares final close <dir> [--json]
|
|
803
864
|
ares final seeds <dir> --file PATH|- [--json]
|
|
804
865
|
ares selection <dir> --file PATH|- [--json]
|
|
866
|
+
ares selection calibrate <dir> --from-run RUN [--null COMMIT] [--z NUMBER] [--json]
|
|
805
867
|
ares protocol <dir> --file PATH|- [--json]
|
|
806
868
|
ares executor set <dir> --kind local|ssh [--host ALIAS] --workdir PATH [--retention-cap-bytes BYTES] [--gpu-devices IDS --gpu-min-free-memory-mb MB --gpu-max-load-ratio RATIO] [--json]
|
|
807
869
|
ares executor inputs hash <dir> <path> [--json]
|
|
@@ -830,10 +892,15 @@ ares review add <dir> --file PATH|- [--json]
|
|
|
830
892
|
ares review resolve <dir> <review-id>/<finding-id> --reason TEXT [--json]
|
|
831
893
|
ares review show <dir> [--json]
|
|
832
894
|
ares review checklist [--json]
|
|
833
|
-
ares paper build <dir> [--json]
|
|
895
|
+
ares paper build <dir> [--doc manuscript|slides] [--json]
|
|
896
|
+
ares paper render record <dir> --file PATH --receipt PATH [--doc manuscript|slides] [--json]
|
|
897
|
+
ares paper render show <dir> [--doc manuscript|slides] [--json]
|
|
898
|
+
ares renderer set <dir> --command JSON [--timeout-s N] [--json]
|
|
899
|
+
ares renderer show <dir> [--json]
|
|
900
|
+
ares renderer check <dir> [--json]
|
|
834
901
|
ares paper plan set <dir> --file PATH|- [--json]
|
|
835
902
|
ares paper plan show <dir> [--json]
|
|
836
|
-
ares paper check <dir> [--json]
|
|
903
|
+
ares paper check <dir> [--doc manuscript|slides] [--json]
|
|
837
904
|
ares cite check <dir> <draft> [--json]
|
|
838
905
|
ares playbook
|
|
839
906
|
ares mcp
|
|
@@ -841,7 +908,7 @@ ares mcp
|
|
|
841
908
|
<!-- /facts:commands -->
|
|
842
909
|
|
|
843
910
|
<!-- facts:mcp-tools -->
|
|
844
|
-
The MCP server publishes
|
|
911
|
+
The MCP server publishes 93 tools: `ares_retention_inspect`, `ares_retention_prune`, `ares_lesson_propose`, `ares_lesson_list`, `ares_lesson_check`, `ares_lesson_decide`, `ares_skill_check`, `ares_harness_close`, `ares_harness_contrast`, `ares_harness_compose`, `ares_harness_adopt`, `ares_harness_stream_set`, `ares_harness_stream_show`, `ares_experience_select`, `ares_experience_freeze`, `ares_experience_check`, `ares_harness_set`, `ares_harness_show`, `ares_harness_import`, `ares_lineage_show`, `ares_lineage_compare`, `ares_autonomy_show`, `ares_autonomy_set`, `ares_watch_set`, `ares_watch_run`, `ares_watch_show`, `ares_console_add`, `ares_console_remove`, `ares_console_list`, `ares_setup`, `ares_manifest`, `ares_archive`, `ares_lessons`, `ares_skill_propose`, `ares_skill_decide`, `ares_skill_list`, `ares_plan_set`, `ares_plan_control`, `ares_plan_show`, `ares_status`, `ares_study_export`, `ares_scope_set`, `ares_gate`, `ares_idea_add`, `ares_idea_decide`, `ares_idea_categories`, `ares_idea_report`, `ares_investigate_show`, `ares_investigate_close`, `ares_ablate_add`, `ares_ablate_show`, `ares_ablate_close`, `ares_posthoc_show`, `ares_final_close`, `ares_final_seeds`, `ares_selection_set`, `ares_selection_calibrate`, `ares_protocol_set`, `ares_executor_set`, `ares_executor_inputs_hash`, `ares_executor_check`, `ares_attempt_run`, `ares_attempt_list`, `ares_attempt_show`, `ares_attempt_cancel`, `ares_attempt_reconcile`, `ares_attempt_logs`, `ares_lit_search`, `ares_lit_queries`, `ares_lit_flow`, `ares_lit_list`, `ares_lit_screen`, `ares_lit_card`, `ares_lit_card_export`, `ares_lit_card_import`, `ares_lit_card_list`, `ares_lit_verify`, `ares_lit_bib`, `ares_review_add`, `ares_review_resolve`, `ares_review_show`, `ares_review_checklist`, `ares_paper_plan_set`, `ares_paper_plan_show`, `ares_paper_build`, `ares_paper_render_record`, `ares_paper_render_show`, `ares_renderer_set`, `ares_renderer_show`, `ares_renderer_check`, `ares_paper_check`, `ares_cite_check`, `ares_playbook`.
|
|
845
912
|
<!-- /facts:mcp-tools -->
|
|
846
913
|
|
|
847
914
|
Reviewed harness lesson tools are `ares_lesson_propose`, `ares_lesson_list`, `ares_lesson_check` and `ares_lesson_decide`; their mutations and explicit source checks share the CLI operations. Listing remains local.
|
|
@@ -850,13 +917,13 @@ Memory tools are `ares_archive`, `ares_lessons`, `ares_skill_propose`, `ares_ski
|
|
|
850
917
|
|
|
851
918
|
Watch tools are `ares_watch_set` (`{study, watch}`), `ares_watch_run` and `ares_watch_show` (`{study}`). `ares_watch_run` always returns the detached admission result `{started:true,configSha256}` after config/scope/year preflight under the study lock. Read the eventual completed result through `ares_watch_show`; `watch.ran` records an all-source failure as `ok:false`. The finite pass stays in the MCP process, which can still answer ping and `tools/list`; another start while locked refuses. CLI `watch run` and the `watch.run` plan step remain synchronous. Registry tools are `ares_console_add` and `ares_console_remove` (`{study}`), and `ares_console_list` (no arguments). These use the same shared operations as the CLI. Registry commands manage local registration only; they do not start a console.
|
|
852
919
|
|
|
853
|
-
MCP uses shared command handlers; `ares_setup` exposes the same registration preview/apply/undo operations. `init`, the controller loop `run`, and the server entrypoint `mcp` are CLI-only. Investigation tools are `ares_selection_set`, `ares_idea_add`, `ares_idea_decide`, `ares_investigate_show` and `ares_investigate_close`. Plan tools are `ares_plan_set`, `ares_plan_show` and `ares_plan_control`; `ares_gate` accepts `plan:<node-id>`. Setting, showing or controlling a plan never starts the controller loop. Start `ares run` in a separate terminal before resuming through MCP. Autonomy tools are `ares_autonomy_show` and `ares_autonomy_set`; `ares_gate` also accepts `accept:<artifact>`. `ares_study_export` writes the same bundle as `study export` and needs an absolute `bundle`. Experiment tools are `ares_protocol_set`, `ares_executor_set`, `ares_executor_check`, `ares_attempt_run`, `ares_attempt_list`, `ares_attempt_show`, `ares_attempt_cancel`, `ares_attempt_reconcile` and `ares_attempt_logs`; `ares_gate` accepts `design`, `final` and `review`. Paper/review tools are `ares_paper_plan_set`, `ares_paper_plan_show`, `ares_paper_check`, `ares_paper_build`, `ares_review_add`, `ares_review_resolve` and `ares_review_show`. Phase tools include `ares_final_seeds`, `ares_ablate_add`, `ares_ablate_show`, `ares_ablate_close`, `ares_final_close` and `ares_posthoc_show`. Attempt run is always detached over MCP, and executor-reaching tools carry `openWorldHint`.
|
|
920
|
+
MCP uses shared command handlers; `ares_setup` exposes the same registration preview/apply/undo operations. `init`, the controller loop `run`, and the server entrypoint `mcp` are CLI-only. Investigation tools are `ares_selection_set`, `ares_selection_calibrate`, `ares_idea_add`, `ares_idea_decide`, `ares_idea_categories`, `ares_idea_report`, `ares_investigate_show` and `ares_investigate_close`. Plan tools are `ares_plan_set`, `ares_plan_show` and `ares_plan_control`; `ares_gate` accepts `plan:<node-id>`. Setting, showing or controlling a plan never starts the controller loop. Start `ares run` in a separate terminal before resuming through MCP. Autonomy tools are `ares_autonomy_show` and `ares_autonomy_set`; `ares_gate` also accepts `accept:<artifact>`. `ares_study_export` writes the same bundle as `study export` and needs an absolute `bundle`. Experiment tools are `ares_protocol_set`, `ares_executor_set`, `ares_executor_check`, `ares_attempt_run`, `ares_attempt_list`, `ares_attempt_show`, `ares_attempt_cancel`, `ares_attempt_reconcile` and `ares_attempt_logs`; `ares_gate` accepts `design`, `final` and `review`. Paper/review tools are `ares_paper_plan_set`, `ares_paper_plan_show`, `ares_paper_check`, `ares_paper_build`, `ares_paper_render_record`, `ares_paper_render_show`, `ares_review_add`, `ares_review_resolve` and `ares_review_show`. Phase tools include `ares_final_seeds`, `ares_ablate_add`, `ares_ablate_show`, `ares_ablate_close`, `ares_final_close` and `ares_posthoc_show`. Attempt run is always detached over MCP, and executor-reaching tools carry `openWorldHint`.
|
|
854
921
|
|
|
855
922
|
## Version and format discovery
|
|
856
923
|
|
|
857
|
-
Experiment interchange advertises `experimentProtocol: 2` and `experimentAttempt: 3`. Legacy v1 protocols and attempts remain readable; fresh v2 pipelines use attempt v2, while v2 requests with eligible reuse or force-fresh use v3 with explicit control and stage receipts. Older readers refuse versions they do not support without rewriting them. The manifest also advertises retention, stage-progress, reuse
|
|
924
|
+
Experiment interchange advertises `experimentProtocol: 2`, `protocolScreen: 1` and `experimentAttempt: 3`. `protocolScreen: 1` covers the optional `screen` field inside protocol v1 and v2; it is a field, not a new protocol version, so a protocol without it keeps its hash and flow. Legacy v1 protocols and attempts remain readable; fresh v2 pipelines use attempt v2, while v2 requests with eligible reuse or force-fresh use v3 with explicit control and stage receipts. Older readers refuse versions they do not support without rewriting them. The manifest also advertises retention, stage-progress, reuse, paper-plan and candidate-screen event kinds in the existing version-1 ledger envelope; those additive events do not migrate a study or rewrite prior receipts.
|
|
858
925
|
|
|
859
|
-
`ares manifest --json` (MCP `ares_manifest`, no arguments) reports the running package version, implemented command names/usages and the schema versions of family-readable records. It needs no study, network or executor. The `formats` map reports the highest supported version for each implemented record family; older supported records are not rewritten. `paperPlan:
|
|
926
|
+
`ares manifest --json` (MCP `ares_manifest`, no arguments) reports the running package version, implemented command names/usages and the schema versions of family-readable records. It needs no study, network or executor. The `formats` map reports the highest supported version for each implemented record family; older supported records are not rewritten. `paperPlan: 3` is the highest supported `paper/plan.json` format: plans that declare dependencies or figures use v3. Point-only plans use v2 and legacy scope-only plans can stay v1. Older readers refuse the versions they do not support without rewriting them. `paperEvidence: 3` binds declared figures. Plan-bound builds without figures keep v2, and plan-free builds keep v1. `paperDocuments` advertises manuscript and slides. The same manifest reports `paperRender: 1`, `rendererConfig: 1`, `experimentSelection: 2`, `selectionCalibration: 1`, `ideaCategories: 1` and `ideaReport: 1`. `study: 2` is the latest supported study format; legacy v1 is also supported. `lessonProposal: 1` covers receipt-bound reviewed harness lesson candidates and `lesson.proposed`/`lesson.decided` events. `harnessStream: 1` and `harnessExperience: 1` cover the immutable stream and body-free context; their ledger events are `experience.stream.set` and `experience.frozen`. `harnessTransition: 1` covers local contrast/composition/experimental closure. `harnessRound: 1` and `harnessFixtureProjection: 1` cover the local round namespace and explicitly synthetic projections; their ledger events are `harness.round.set` and `harness.probe.declared`. `skillProposal: 2` is the latest readable proposal format; legacy v1 remains supported and new writes default to source-inspected v2 with evidence-bound acceptance; v1 bytes and terminal decisions remain unchanged. Proposal Markdown and skill events carry their own `skillProposal` version. Older readers refuse v2 with unsupported-version guidance rather than silently treating it as v1. The `ledgerEvents` list advertises `archive.exported`, `skill.proposed`, `skill.decided`, `lesson.proposed`, `lesson.decided`, `watch.set`, `watch.ran`, `autonomy.set`, `harness.round.set`, `harness.probe.declared`, `harness.contrast.recorded`, `harness.composition.recorded`, `harness.adoption.decided`, `harness.round.closed`, `experience.stream.set` and `experience.frozen` in the version-1 ledger envelope. The manifest also lists `studyRegistry: 1`, `watchConfig: 1` and `studyBundle: 1`; a `study export` bundle manifest carries its version as `bundle: 1` rather than `v`. Unsupported ledger/proposal/registry/watch versions are refused without rewriting their bytes. `mcp.tools` publishes `{name, readOnly}` for installers; grants are fail-closed for mutating or outside-reaching tools.
|
|
860
927
|
|
|
861
928
|
Within a supported schema, readers preserve additive fields on study/attempt records and keep ledger events with unknown kinds. Appending to the ledger leaves prior lines intact; updating an attempt keeps unrecognized fields and stage entries. Unknown stage entries remain readable, including logs and totals, but budget-gated starts refuse with an upgrade instruction because this version cannot account for their resource use. A future schema version or unknown execution status/stage is refused with an upgrade instruction, leaving the original data unchanged. Unknown plan versions or node kinds are refused without changing plan.json. Command input remains strict so unknown options or protocol fields cannot silently change an experiment.
|
|
862
929
|
|
|
@@ -882,14 +949,18 @@ Prepare a release on a clean release branch with `bun run release:prepare <versi
|
|
|
882
949
|
|
|
883
950
|
Documentation stamps must be fresh before tagging. `docs/verified.json` records, for `README.md` and `src/playbook.ts` (the `ares playbook` text), the commit their prose was last checked against and the source paths it describes; edits to the stamped documents themselves are not counted as source drift. `bun run check` warns about a stale document; `bun run release:tag` and the tag workflow run `bun scripts/check-docs.mjs --require-fresh` and refuse. To restamp in the release PR, reread each stale document against the release PR's base commit on `origin/main`, fix the prose, and set its `verifiedAgainst` to that base commit (it survives the squash merge; never stamp a branch commit). Mechanical README facts (install line, command list, MCP tools) are generated: run `bun scripts/readme-facts.ts --write` after changing `package.json`, `src/commands-table.ts` or the MCP tool table.
|
|
884
951
|
|
|
952
|
+
The required networked CI job stages the candidate and smoke-tests it on pull requests and main pushes. The smoke fetches exact-pinned runtime dependencies into an isolated npm cache, then installs the staged tarball offline before checking the CLI, manifest and MCP.
|
|
953
|
+
|
|
885
954
|
The tag workflow first waits up to 30 minutes for the exact commit's main-push `Check` workflow and `ci-ok` aggregate to succeed. A failed, skipped or cancelled result refuses release. It checks fresh documentation stamps, the matching package version, dated CHANGELOG and main ancestry before staging. It reuses CI rather than rerunning the full suite, then installs dependencies, stages a hash-bound tarball and runs clean-prefix CLI, manifest and MCP smoke checks on Ubuntu and macOS. Publication uses the exact validated Linux tarball with provenance. The GitHub release follows with the dated notes, tarball and hash manifest; reruns edit the existing release and replace assets, with three bounded attempts for GitHub 429/5xx errors. When the `SITE_DISPATCH_TOKEN` secret is set, the workflow then sends a `product-release` dispatch to STAIxBWLB/agent-hub-site so the family portal re-syncs; a dispatch failure does not fail the release. npm publication remains one-time; an already published version cannot be republished.
|
|
886
955
|
|
|
887
956
|
Publication runs only when `NPM_PUBLISH_ENABLED` is `true` and a reviewer approves `npm-production`. It uses Node 24 and npm 11.5.1 or newer with [npm OIDC trusted publishing](https://docs.npmjs.com/trusted-publishers), without an npm token. The owner manages trusted-publisher settings, environment approval and branch protection requiring `ci-ok`; the scripts do not change those settings.
|
|
888
957
|
|
|
889
|
-
N-1
|
|
958
|
+
N-1 for the 0.4 line is 0.3.1, the latest published patch of the 0.3 line. The installed-package check retains all 90 CLI command forms and 85 MCP tool names and `readOnly` values (98 commands and 93 tools total). It verifies representative survey and experiment reads without rewriting study or ledger bytes, preserves an existing approved no-input design, and confirms that 0.3.1 reads a newly written study v2 unchanged. The networked `n1` CI job resolves the latest published patch of the previous minor line and feeds the required `ci-ok` check. See the 0.4.0 CHANGELOG entry for newer versions and settings that 0.3.1 refuses or ignores, including how slides build events can make an older reader report a manuscript build as stale.
|
|
890
959
|
|
|
891
960
|
## Development
|
|
892
961
|
|
|
962
|
+
Pull requests run Ubuntu checks by default. The `ci:macos` label adds macOS, and pushes to `main` run both. CI uses Bun 1.4.4.
|
|
963
|
+
|
|
893
964
|
```sh
|
|
894
965
|
bun install --frozen-lockfile
|
|
895
966
|
bun run check # typecheck, boundary check, README facts, doc stamps, tests (no network), package dry-run
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@staix/agent-research",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.1",
|
|
4
4
|
"description": "Research engine for the agent family: literature with verified references, study ledger and gates (ares)",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -11,6 +11,9 @@
|
|
|
11
11
|
"engines": {
|
|
12
12
|
"bun": ">=1.4.2"
|
|
13
13
|
},
|
|
14
|
+
"dependencies": {
|
|
15
|
+
"@staix/cli-output": "0.1.3"
|
|
16
|
+
},
|
|
14
17
|
"devDependencies": {
|
|
15
18
|
"@staix/agent-console": "git+https://github.com/STAIxBWLB/agent-console.git#27e4f89babc7a25df8038918d1181d0af35384e0",
|
|
16
19
|
"@types/bun": "^1.3.0",
|