Repository navigation
merge(schemas): configure agents by reference, record treatments - #86
Conversation
`analyze --experiment` refuses a treatment A/B that Candler itself ran. A probe on main shows three of five factor shapes break, and the cause is not one reader: the run manifest keeps only factor paths, so every analysis reader rebuilds ownership and levels by its own path rule. The reports record the probe, the concepts as the experiment file defines them, the readers that rebuild them, what a scrapped path-based fix got wrong, and two open questions for a planning session: what the record must keep, and what "treatment" names. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A run manifest records only factor paths, so analysis readers rebuild
ownership from prefixes and three of five factor shapes break. This
roadmap replaces the skill special case with one reference form at the
configuration paths a harness driver can lay out, pins each reference
once, and records each run's treatment as {factor, owns, level} under
run-manifest/2. Twelve leaves over seven depths, expand then contract:
the old form keeps working through named shims until manifest_v2 lands
the one break and its compile migration. Every leaf writes an
architecture report before code and names what it reuses and removes;
the coordinator gates each depth on consolidation across leaves.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The campaign may spend up to $100, against an estimate of about $70. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The inventory names each site in Candler, its plug-in interface and the htn-eval-clean consumer that spells the old treatment form or the path-only factor record, with the leaf that ticks it. It is transient: integration deletes it with every row ticked. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Six end-to-end rows run through the binary and are red on the base for the reason each states: a skill factor under --experiment, a table level, a factor below a held table, a fixed leaf beside a factor, two factors where one prefixes the other, and a study with no skill. They are ignored until the record readers land. The undeclared-leaf refusal holds in guard_comparability, and its twin is red and ignored. Two confirm rows show the existing shapes still work. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Inventory and guards are done. The inventory found files no leaf owned: tests and fixtures in the old form, the contract pages, whose guard reads schemas, traits and codes, and the generated Python models. Conventions now say who changes each. G6 moves to guard_comparability.rs, because compare.rs has no test module, and the readers filters follow. The integration leaf checks the contract pages for drift instead of regenerating them, and leaf worktrees are removed with git worktree remove, since scripts/worktree.py remove waits for origin/main. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
State configuration by reference as the design: add Terms and Configuration by reference, remove the treatment section and its prefix, and move the class table and the harness layout to the reference form. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Describe the run manifest, the verdict (I6 to I8), blocks, comparisons, the importer, evaluators and the error model over the treatment record. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The architecture document now states the design every later leaf
implements. Terms are defined once. A reference {source, path?, tag?,
commit?} at a configuration path a driver can lay out replaces the
skill checkout, and is pinned and extracted once per plan. The run
manifest records each run's treatment as {factor, owns, level} under
run-manifest/2. I7 reads that record. The README names the agent's
configuration as what is under test.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A field-path segment cannot hold `-`, so `skills.htn-creator` was no path. The segment now admits it, a loosening the version note records. A reference is told from a plain value by the path catalogue and the value's kind, never by its keys, so no schemas code refuses one at a path that takes none: such a table flattens, or stays a hook table, and the reader of that path refuses it. The design says so, and gate 1 of the leaf follows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The design named TABLE_VALUED_PATHS and a field-path segment without `-`. The depth 2 leaf renamed the catalogue HELD_WHOLE_PATHS, because two of its rows are not tables, and widened the segment. The design now says both, and manifest_v2's breaking footer records that the old constant left the public API. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A skill name such as htn-creator is a segment of skills.<name>. The segment grammar loosens from [a-z][a-z0-9_]* to [a-z][a-z0-9_-]*; every schema that carries a field path changes by its pattern and description. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A table at skills.<name>, instructions.workspace and instructions.global.<harness> reads as a reference and is one leaf for ownership. The path catalogue gains a per-row marker for it; no key makes a table a reference, and an inline text stays valid. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
RefEntry parses ref:<config path>/<subpath>; ReferencePin is what a cell holds in place of a reference, with no source. Both are read by the depth 3 resolver. The commit also formats the previous one. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
HELD_WHOLE_PATHS and its row types are crate-private; takes_reference is the public question. One predicate now answers both whether a path takes a reference and whether it is held whole, at exactly one segment below skills. The agent_config doc no longer links a private item. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
An experiment file may now hold a reference {source, path?, tag?,
commit?} at skills.<name>, instructions.workspace and
instructions.global.<harness>. The path catalogue, renamed
HELD_WHOLE_PATHS and kept inside the crate, says which paths take one,
and a reference is held whole there, so a factor of references owns one
leaf. A ref:<config path>/<subpath> build entry names a file inside a
reference, and ReferencePin {path, digest, commit?, tag?} is the pin a
resolver will write, with no source. A field-path segment now admits
`-`, so skills.htn-creator is a path; import package names still refuse
it. All of it sits beside the old treatment form.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
leaf_values splits held tables into their leaves, built on leaves_of and value_at_leaf, so the verdict can judge a factor by the leaves it owns. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The resolver runs once for each tuple of reference-factor levels, over one pin store, so a factor-level reference is pinned by reference_pin@1 and named in sources[] like a fixed one, and a ref: build entry reads its extraction. A cell takes its resolution by Cell.levels. JobSpec.resolution becomes resolutions and JobSpec.references, the planner pre-pass and ReferencePins are gone; an old spec is refused. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Each row names the symbol or line on the tip that shows its site migrated or gone; the rows the retired-names sweep proves gone cite the sweep. No row is left for an owner. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
class_verdict reads the arms treatment records: a differing leaf is accepted when a factor that owns it has different levels in the two arms. The reference explanation of locks, image and inputs needs an owned reference that differs and a ref: build entry that reads it. The path prefix machinery (covers, declared_covers, REFERENCE_ROOTS) is gone. This commit and the next one build together: report.rs moves with it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The two-factor gate the retired kt_two_levels_end_to_end left open: two instruction files by two models run through the binary, and each run treatment names its level of both factors. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Its parent holds every row ticked, and the campaign no longer reads it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
level_of, factors_between and check_factors read the record: a factor is its entry, its level the values at its owned leaves, and a class whose runs record different factors or leaves is refused as analysis.treatment_records_disagree. analyze --experiment compares treatment_of(cell) with the stored records. Reference levels order by tag, commit, digest. factor_broader_than_variation is lifted. G1 to G5 and G7 are in the reference form and un-ignored; G10 is new. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The golden corpus guard needs the corpus, so no earlier leaf ran it. Its
oracle keyed the 12 cells by digests of the old form (a typed `treatment`
root), and its import used rules that name no skill, so the cells lost the
skill. The generator now writes the skill as the value `{tag}` at
`skills.<name>`, as the import's `[[reference]]` rule stores it; the guard
imports with that rule added to the mini rules; the declared factor is
`skills.htn-creator`.
Only the cell hexes and the factor label move: the rates by cell, the
status counts and the 6 and 3 comparisons with 3 and 4 blocks are equal.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A reference factor also owns each inputs.<kind> leaf whose list of that kind entries maps one to one onto its levels, by the path rule of the readers flatten. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The live context vectors record the hash of a stored manifest, and the writers leaf changed what an import records in it (the treatment record and its owned leaves). The two recorded hashes and the digests that follow from them are regenerated with gen_live_context.py; `--check` passes. The full workspace run found it, since no scoped run reads it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
An input entry is the leaf inputs.<kind> in the verdict, so a factor that owns it is matched as for a value leaf; an unowned one is still refused as inputs. same_declaration is pub(crate). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A native run's manifest takes its treatment record from the experiment file's treatment_of, and a forced resume keeps the stored record. The resolver runs once per tuple of reference-factor levels over one pin store, so a factor-level reference is pinned before its readers: its own source is in sources[] and a ref: build entry builds from it. A reference shared by several tuples is still extracted once. JobSpec.references and the per-plan pre-pass are gone; a job spec holds one resolution per tuple, and the older spec is refused. The import records one factor per varying leaf. A reference factor also owns the leaves that map one to one onto its levels, input entries included, and no two factors own the same leaf. A reference factor crossed with model levels is planned, run and recorded level by level through the binary. Not covered: candler resolve prints only the first tuple's values, and a leaf an import rule names as resolved is owned by the rule alone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Records what the closing leaf deleted, the golden numbers against the base, the gates, the consumer branch and what is left for the leaves that own it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A comparison is now judged by what each factor owns: every leaf that differs between two arms must lie in the owns of a declared factor whose level differs, a held table is compared leaf by leaf, and an input entry is matched against owns as any value is. The image, inputs and environments are explained only when an owned reference differs and a ref: build entry reads it. Blocks, levels, the factors between two arms and the factor check read the stored record instead of path prefixes; records of one class that disagree are refused with analysis.treatment_records_disagree, and the old prefix code is lifted. analyze --experiment compares the file's treatment with the stored records and reports a level that only one side holds, a tag that only one side names, and a commit that does not match. The guard rows for a skill factor, a table-valued factor, a factor below a held table, a fixed leaf under a factor, two nested factors and a study with no skill now pass through the binary, the imported mini corpus is comparable, and the golden design keeps its signs. Not covered: a run-manifest/1 store is refused with its path but not yet with format.schema_tag_mismatch; a ref: entry found only in a plug-in fragment explains nothing; a reference with no commit is compared by tag alone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The workspace docs build with -D warnings again: the layout module links HarnessDriver::layout through the driver module, and the reference pin step links takes_reference in candler-schemas. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Writers and readers are merged, each after one verifier pass and a coordinator rerun on its tip. Their Removes are corrected for names that were already gone at the base. The integration leaf now ticks the inventory itself, since no leaf did, and owns the one production change left: the store hands the schema tag error of a run-manifest/1 record to analyze typed, so G10 is refused with its code. It also carries the campaign's not-covered list into its report. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A run-manifest/1 store is now refused with format.schema_tag_mismatch, naming the manifest and the way out: the store checks a manifest's schema tag before parsing it, through a new StoreError::SchemaTag arm that answers with the tag error's own code. The transient confirm rows, the inventory and the old form's remains in tests are gone, and the retired-names sweep prints nothing. The golden oracle is keyed by the reference form's cell digests, with the same rates per cell, and the import's live context vectors record the manifest bytes the import writes now. The workspace docs build with -D warnings. Not covered: candler resolve prints only the first tuple's values; a ref: entry found only in a plug-in fragment explains nothing; a reference with no commit is compared by tag; a leaf an import rule names as resolved is owned by the rule alone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The integration leaf is done: the depth 7 gate, its coordinator checks, the not-covered list carried to the PR and the spend through depth 7 are recorded in the campaign README. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A path that takes a reference also takes inline text, and the walk counted any value there as a reference. A factor of inline workspace texts was then a reference factor, so candler resolve ran the resolver, and every preflight check, once per level. Only a table is a reference now, as a member of instructions.global already was. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The harness controls still built their cell with the typed root treatment and a source for it, so building the control manifest refused: its source named no value and lay under no typed root. The tests that still passed the root, which the cell reader ignores, drop it too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
3b2e527 to
693753c
Compare
The planner refused a value at a skill path that was no table through the reference walk, which now yields tables only, so text, a number or a list at skills.<name> was dropped instead of refused. The planner checks such a value itself before walking the references. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A resume of a factor with several reference levels fails as
|
A stored cell answered a fresh cell by comparing their values with each reference pin replaced by one placeholder. In an experiment whose cells differ only by a reference, every stored cell answered every fresh cell, and a resume of that experiment in its own store was refused as candler.internal, naming one stored cell twice. A pin is now compared by its identity: its path and tag, and its commit when no tag names one. The digest, and the commit a tag names, stay re-checked facts (runner.fact_changed, accepted by --force), so a moved tag, or edited content in a source that is no git checkout, is a changed fact and not another cell. A stored cell that answers a fresh cell holding its own pins holds that cell alone across its past experiment. A stored cell still left answering several fresh cells is refused with the new PlanError::StoredCellAnswersMany, code runner.stored_cell_answers_many, side experiment; PlanError is non_exhaustive, so the variant is additive. The runner.stored_cell_unknown row now says what to do, and the architecture states which stored cell a resume replays. The guard resumes the two-text factor the htn-creator-eval report reproduced, and covers eight rows with crafted pins: the probe of tags a and b planned as a and c, its resume, one tag on two commits, the second of those planned alone, a moved commit with and without --force, a moved tag two fresh levels share, untagged commits, and edited content without git. Masking an untagged commit, or preferring a stored cell's own pin only among its own hits, turns it red. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
## Why The configuration-by-reference campaign landed in #86 with every leaf task done, but the roadmap's folder nodes still read planned or in progress, so the campaign looked open. ## Changes - The six folder nodes under `__roadmap__/treatment-record/` now read done. The change was made with `dirtree-rdm update`, and every README passes `dirtree-rdm validate`. ## Not covered - No code or design change. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Why
The skill under test entered an experiment through its own section (
[treatment]), its own setting (request.treatment), its own typed root in every cell, and its own build-context prefix (treatment:). Instruction files, hooks and the next kind of configuration would each have needed the same four exceptions. Worse, a run's manifest kept only a list of factor paths, soanalyzerebuilt which leaves a factor owned from path prefixes, and a factor whose level was a whole table could not be told apart from its parts.What changes
{source, path?, tag?, commit?}is written in[fixed]or as the levels of a factor at the path it configures (skills.<name>,instructions.global.<harness>,instructions.workspace). The resolver pins each distinct reference once per plan, the harness driver says where it lands (HarnessDriver::layout), and the image build, the ground-truth refusal and the staging read that one extraction.isolation.build.contextandisolation.build.requirementstakeref:<config path>/<subpath>.run-manifest/2records, per run,treatment[] {factor, owns, level}.analyzereads levels and ownership from it, so comparability, blocking and the report no longer infer them from paths.[treatment]becomes[[reference]] {path, pointer, resolved?}. An imported reference has a tag and no commit.[treatment],request.treatmentandtreatment:<path>are refused withconfig.treatment_form_retired, and the message shows the reference that replaces them. Arun-manifest/1store is refused withformat.schema_tag_mismatch, naming the manifest and saying to re-import or rerun; nothing is migrated.TreatmentRef,TreatmentSpec,SkillTree,HarnessDriver::skills,treatment_identity@1, the typed roottreatment,request.treatment,RunManifest.factorsandvarying_pathson the reading side, and every per-cell re-archive of a skill tree.Before and after
The import rules change the same way:
[treatment]withpointerandresolvedbecomes[[reference]]withpath = "skills.htn-creator"and the same two keys. A plug-in fragment'streatment:<path>requirement becomesref:skills.<name>/<path>.The hard parts
resolved_skill_versionon an import), so an imported store and its native rerun declare the same factors.run-manifest/1store has to be refused with its code. The store's manifest read turned every parse error into text, and itsFormatarm holds neither the tag error nor the path, so the read now checks theschemafield first (RunManifest::check_schema_tag) and a newStoreError::SchemaTagarm answers with the tag error's own code.Not covered
candler resolveprints the first tuple of reference levels only.ref:entry found only in a plug-in fragment explains nothing when two levels differ.resolvedleaf is owned by the rule alone.skills.*, and scp-stylegit@host:xsources, are not handled; sources are local directories only.Observations
htn-creator@0.2.7to its commit and resolves the layered build image fromref:skills.htn-creator/scripts.🤖 Generated with Claude Code
Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com