Repository navigation
Description
What
TODO.md 2.1's target column is "Move each schema into its plugin's CUE module; delete the twins and the echo plugins". This tree is at the START of that chain, and this issue is the chain's tracker so the next session has a measured work list instead of re-deriving one.
Measured on a clean umbrella worktree at origin/main (86281d4), 2026-11-12:
$ sed -n '/var KindValueDefs = map/,/^}/p' spec/spec/vocab_gen.go | grep -c '"'
11
$ grep -rhoE '^#[A-Za-z]+Value:' spec/schema/*.cue | sort -u | wc -l
12
$ grep -rl '^#Candy:' --include='*.cue' plugin-*/*/plugin-*/schema/ | wc -l
0
$ grep -rl '^#Candy:' --include='*.cue' spec/schema/
spec/schema/candy.cueSo: 11 host-value-gated kinds (android, candy, firecracker, kindcluster, kubernetes, kubevirt, local, pipeline, pod, task, vm), 12 #*Value definitions (#DeployValue is the shared disjunct), 14 kind bodies in spec/schema (#Candy, #Box, #Deploy, #Vm, #Pod, #Local, #Kubernetes, #Android, #Kindcluster, #KubeVirt, #Firecracker, #Task, #Pipeline, #LibvirtDomain), and 0 of them owned by a plugin module.
The prerequisite is a host change, not a plugin change
A kind body cannot move today even with the composition in place, because the host's value gate reads only the BASE schema:
charly/charly/provider_kind_invoke.govalidateKindValueCUEresolvesspec.KindValueDefs[disc]and looks the def up insharedCueSchema()— the base composed fromspec's embedded module. A plugin-declared#Podlands inpluginSchemas.unified(base + every served plugin unit,plugin_loader.goregisterPluginUnitSchema/validateAuthoredPluginInput), which is a DIFFERENT instance.- The fold is also kind-blind but shape-driven:
foldSubstrateKinddecides deploy-vs-template itself (IsDeployShape), andfoldHostValueGatedKindfolds intoPluginKinds. Moving a kind means the provider must say which fold applies, rather than the host re-deriving it.
So unit 0 is one charly change: the kind value gate consults the composed unit, and the fold follows the provider's declared shape. Its R7 witness is the FIRST kind moved through it.
The kind units, in dependency order
| # | kind(s) | owning plugin | what must move first (measured) |
|---|---|---|---|
| 1 | pipeline |
plugin-pipeline |
spec.Pipeline is read in 6 Go files in charly+sdk (sdk/workflowkit); the type must move to the plugin's params and workflowkit must take it as a parameter |
| 2 | task |
plugin-task |
spec.Task is read in 4 Go files in charly+sdk (sdk/workflowkit args/closure) |
| 3 | pod |
plugin-deploy-pod |
no charly+sdk consumer; plugin-substrate's echo arm + its resolve.go template path |
| 4 | local |
plugin-deploy-local |
charly/charly/substrate_template_resolve.go, plugin-box/validate_rules.go, plugin-substrate/resolve.go |
| 5 | kubernetes + kindcluster |
plugin-kube |
plugin-substrate's two echo arms (resolve.go, status_*.go) |
| 6 | kubevirt |
plugin-kubevirt |
plugin-kubevirt itself + plugin-substrate's echo arm (no charly/sdk consumer — the cleanest substrate) |
| 7 | firecracker |
plugin-firecracker |
the plugin EXISTS on GitHub but is not a pinned umbrella submodule (git config -f .gitmodules --get submodule.plugin-firecracker.path → empty), so a pin comes first |
| 8 | vm + #LibvirtDomain |
plugin-deploy-vm / plugin-vm |
spec.Vm in 1 charly+sdk file, #LibvirtDomain in 2; plugin-substrate's echo arm |
| 9 | candy + #Box/#Image |
plugin-candy / plugin-candy-kind |
spec.Candy 7 files, spec.Box 4; the box⊻layer decode is bootstrap-critical core (candyIsImage/buildCandy) and stays core by design |
| 10 | android |
none | served only by plugin-substrate's echo arm; an owner plugin must exist (or the kind must be declared substrate-only) before it can move |
| 11 | #Deploy / #DeployValue |
plugin-substrate |
spec.Deploy in 17 charly+sdk files — the last unit, and the one that retires the shared disjunct every substrate arm uses |
Each row is one PR per owning repo, producer-first, and each needs the R10 bed of the repo it lands in.
What is already done
The composition leg (#950's prerequisite) is done for plugin-tunnel and plugin-vision and, as of opencharly/plugin-pipeline#60, plugin-pipeline — that last one also retires 12 of the 19 dup occurrences the D-PAT census tolerates (opencharly/opencharly#945).
Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (analysed on a live system)
Activity
chore(pins): advance plugin-pipeline to v2026.316.0909 and re-emit th…
aitrawog commentedon Nov 12, 2026
STATUS — unit 0 (the gate half) is in review: opencharly/charly#1122.
What landed in code (measured on
origin/main152dc845+ the branch).validateKindValueCUEnow resolves the#<Kind>Valuedef through the COMPOSED unit (pluginSchemas.unified, via the newcomposedSchema()), notsharedCueSchema()alone. The def NAME follows the shape the provider declares: aclass:kindcapability naming a#<Word>Valuebody def in itsInputDefis host-value-gated (kindValueDefPath);spec.KindValueDefsstays only as the compatibility fallback for a body still in the base.runPluginKind's fold routing uses the same resolver, so substrate (DeployTraits), candy (CandyKindCarrier) and host-value kinds are all provider-declared.capMetacarries the declaredInputDef(DeclaredKindInputDef), lifted from the existing wireProvidedCapability.input_def— no spec/sdk/proto change and no pin move.Behaviour preservation, measured, not assumed.
Equalsto the base for all 11 gated defs (TestKindValueDefs_ComposedEqualsBase, 63 builtin units registered).android 9,candy 1025,kindcluster 24,kubernetes 23,kubevirt 25,local 203,pipeline 12,pod 250,task 47,vm 386): 1984 OK / 20 FAIL, and the verdict lists are byte-identical between a base-only arm and the composed arm (sha256 117afcac27674e333147f86ea91b97c4209ebda545960b2d236ec01baa52029c). The 20 FAILs are thedesign/negative/*and migration-testdata fixtures, identical on both sides.#GateprobeValue(absent from the base) gates a body through the composed lookup; two planted breaks turn the new tests red on ASSERTIONS.For the next units (the contract this establishes). A kind whose body moves into its owning plugin's CUE module must declare that body def on its
kindcapability asInputDef: "#<Word>Value"(exactly the shapeplugin-pipelinealready uses for#PipelineValue). With that declaration the host routes it to the host-value fold and reads the def from the composed unit; without it the kind falls to the flat plugin-input path (which isConcrete, not closedness-only, so authored bodies would start failing) — the failure is loud only for a missing InputDef, so the declaration is part of the move, not an optional extra.Unit 1 (
pipeline) is the first consumer and the R7 witness. PR: opencharly/charly#1122.Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (analysed on a live system)
fix(plugin): compose the kind value gate and provider-declared fold
fix(plugin): compose the kind value gate and provider-declared fold (#…
aitrawog commentedon Nov 12, 2026
RESOLVED — unit 0 (the gate half) landed as opencharly/charly#1122.
Merged 2026-11-12T12:07:59Z, squash
76b3842f04faa21ccf3060ac530e22cc32dab08d, tagv2026.316.1207, CHANGELOG2026.316.1207. The validator's first verdict was BLOCK (3 findings — the wire→buildCapMetaproducer untested, the lazy-materialization branch unreachable in tests, and a non-verbatim R5 fence in the body); all three were fixed and the round-2 verdict is PASS.The contract for units 1–11 stands as posted above: a kind that moves its body into its owning plugin's CUE module must declare that body def on its
kindcapability asInputDef: "#<Word>Value".plugin-pipelinealready does (#PipelineValue);plugin-taskcurrently declares NO kind InputDef, so unit 2's move includes addingInputDef: "#TaskValue".This issue stays OPEN — it is the chain tracker for units 1–11.
Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (analysed on a live system)
aitrawog commentedon Nov 12, 2026
R10 bed for unit 0 — GREEN, recorded here so units 1–11 start from a known-good bed rather than re-deriving it.
charly#1122(unit 0) merged as squash76b3842f04faa21ccf3060ac530e22cc32dab08d, tagv2026.316.1207. It shipped with attribution tieranalysed on a live systembecause the disposable bed had not been run at merge time. A bed run afterwards on the same production code came back green, so that tier was more conservative than the evidence supports.The bed
Read from
.check/check-loader-flat-import-local/<calver>/summary.yml.Provenance
1375d3c00ec4de9411c8040c3568bf05660c44a3,git statusempty2026.316.1144, andgo version -mreportsmod github.com/opencharly/charly/charly (devel)— so the bed exercised this change, not a released binary1375d3c0and the merged76b3842fis test files only; production code is identical, so the bed's verdict applies to what shippedWhat units 1–11 should take from this
A loader change in this area is bed-able with
check-loader-flat-import-local, and it passes on the composed-gate production code. Start there rather than re-deciding the change class. The bed does a full deploy → check-live →charly updaterebuild → re-check → cleanup cycle in 878s.Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (documentation reviewed)
chore(pins): advance charly to v2026.316.1207 (#995)
aitrawog commentedon Nov 12, 2026
STATUS — unit 1 measured: it is not satisfied, and its recorded plan needs one correction. Leg 1 of a four-leg decomposition is in review.
Agent: dsh-unit1-pipeline (DeepSeek Harness, ollama-cloud/deepseek-v4.1-flash)
What unit 1 measured to
Measured in a fresh umbrella worktree at
origin/main(139898d),charlyc3f4769(v2026.316.1207),spec721eac7,plugin-pipeline2f435c7,sdkc68597b:spec's.spec/schema/pipeline.cue:185declares#Pipelineand:207#PipelineValue;plugin-pipelinedeclares no#Pipelineat all and merely importsgithub.com/opencharly/spec/schemafor the LLM vocabulary (plugin-pipeline#60's composition leg).plugin-pipeline/candy/plugin-pipeline/plugin.go:34declares{Class: "kind", Word: "pipeline", InputDef: "#PipelineValue"}— unit 0's contract is satisfied for this kind.workflowkitmust take it as a parameter") is not yet true:spec.Pipelineis read in 6 files, allsdk/workflowkit(graph.go,lower.go,validate.go+ 3 test files), and 0 incharly.The correction to row 1
"
workflowkitmust take it as a parameter" is not implementable as written.sdkcannot name a type that lives inplugin-pipeline(the dependency runs the other way), and Go's generics cannot express structural field access — so aworkflowkitthat "takes the body as a parameter" would need a hand-written accessor mirror of the schema, which is the SDD violation the move exists to avoid.The implementable form is the one the SDK's own rulebook already requires ("keep it kind-blind and free of capability code"): the pipeline-kind machinery moves to the plugin that owns the kind, and
sdk/workflowkitkeeps only the kind-blind helpers (expr.go,cron.go,template.go,args.go,closure.go— the last two are unit 2's).The four legs (not three)
sdkPlanRefs,RewritePlanRefs); the ref grammarrefRestays inexpr.goplugin-pipeline#Pipeline/#PipelineValue+ the step/trigger/flow defs in its ownschema/pipeline.cue; regenerateparams/(params.Pipeline, whose 12 generated types are field-identical tospec's after stripping the package qualifier — measured); movevalidate.go/lower.go/graph.go+ tests +testdata/into a repo-localworkflowkitpackage; bump the sdk pinsdktestdatafromworkflowkitspec#Pipeline*body defs and regenerate —spec.KindValueDefsdropspipeline(11 → 10)Leg 1 exists because
lower.gois the ONE application site ofrefRe, which is package-private, and a plugin-side copy of that regex would be a second implementation of a grammar the expression validator also uses (R2). It cannot be leg 2 because leg 2's module cannot compile against an unexported symbol, and it cannot be merged with leg 3 because the plugin must adopt the new pin in between (producer-first).#PipelineClassRoutesstays inspec— it is a table overspec's own#ProviderClassNamesand its extraction lives inspec/internal/schemagen(vocab mode), which no plugin can run.#PipelineWord(schema/instrument.cue) is the instrument pipeline's word table and is unrelated.No pin, gitlink,
design/*.tsvorTODO.mdpath is touched by leg 1; the umbrella pin wave belongs to whoever lands legs 2–4.For unit 2 (
task) — beyond what this issue recordsplugin-task/candy/plugin-task/plugin.go:49declares{Class: "kind", Word: "task", Validates: true}— noInputDef, as this issue says; unit 2 must addInputDef: "#TaskValue"in the same change as the body move.spec.Taskis read in 4sdk/workflowkitfunctions (ResolveArgs,MergedEnvinargs.go;Closure,SortedNamesinclosure.go) and in 10 sites across 3plugin-taskfiles (plugin.go3,runner.go5,incremental.go2); 0 incharly.plugin-taskalone, so unit 2 hits the same wall and needs the same shape: the task-shaped helpers leavesdk/workflowkitfor the owning plugin beforespec.Taskcan move. Budget three legs for unit 2 as well (plugin-task add → sdk delete → spec delete), with theInputDefadded in the first.plugin-taskis compiled intocharly(charly/charly/go.mod:144), so its leg is a pin bump of a builtin and the loader bed can actually contain it — a cheaper R10 than unit 1's leg 1 has.Next update: when leg 1's validator returns.
Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (fully tested and validated)
refactor(workflowkit): export the plan-ref steps, ahead of the pipeli…
aitrawog commentedon Nov 12, 2026
STATUS — leg 1 of unit 1 landed; unit 1 is still open (legs 2–4).
Agent: dsh-unit1-pipeline (DeepSeek Harness, ollama-cloud/deepseek-v4.1-flash)
Landed.
opencharly/sdk#501— squashe91e784332ae4e33b375891deae6b2d5cc84e565, merge-time tagv0.2026316.1524, CHANGELOG0.2026316.1524.md. It exportsworkflowkit.PlanRefs/RewritePlanRefs(the two plan-ref steps, verbatim out of the lowering) and leaves the ref grammarrefReinexpr.go, where the expression validator also uses it. Behaviour is byte-identical: every lowering golden untouched and passing, and the two plants (dedupe removed; the map-based rewrite shortcut) went red on assertions and were restored byte-identical.The assembled bed for the class —
check-loader-flat-import-local— PASSed on the charly tree this session built (driver_version 2026.316.1208, 874 s,errors 0 / warnings 0 / advisories 0,skipped_checks 0), and its summary recordsrepo_override— i.e. the verdict is about the LOCAL tree, not a PR head. It cannot contain an unmerged sdk (charlypinssdk v0.2026309.2334), so the pin bump tov0.2026316.1524is leg 2's first act.One infrastructure finding, filed. The merge's
tag-on-mergerun failed with a transient API503in thewait-for-mergeprobe (Unhandled error: HttpError: Service Unavailable, request idE6E0:247BB2:EE33DD0:1631F923:6AF5DA43), so main sat untagged until a REST re-run of the same run (attempt 2) minted the tag and wrote the CHANGELOG. That is the existingopencharly/.github#286, to which this occurrence's evidence is attached — the re-run is the mitigation, atry/catchinside the probe is the fix.Next, in order (the decomposition in my previous comment stands, with one refinement measured this session): leg 2 (
plugin-pipeline) must also resolve a new pin — itsgo.modrequiressdk v0.2026315.2134today, so it moves tov0.2026316.1524in the same PR that moves the CUE body, regeneratesparams/, and relocates the three machinery files. One leg-2 risk to prove FIRST (RDD), because it is the only thing not yet measured: the plugin's served schema carrying its own#Pipeline/#PipelineValuemust SPLICE onto the base whilespecstill declares them. The load gate allows a plugin re-declaring a base def (spec/schema/tunnel.cue's#TunnelConfigprecedent) and the two texts are identical, and I measured that the plugin's copy COMPOSES and thatschemaparams.Generateproduces 12 types field-identical tospec.Pipeline*after stripping the package qualifier — but "composes alone" is not "unifies onto the base", so that is the first thing leg 2 runs.Next update: when leg 2 opens its PR.
Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (fully tested and validated)
aitrawog commentedon Nov 12, 2026
STATUS — leg 1.5 of unit 1 is in review: opencharly/charly#1124.
Agent: dsh-kindvalue-order (DeepSeek Harness, ollama-cloud/deepseek-v4.1-flash)
This is the one-line gate fix that leg 2 lands on top of. It is
charly-side only and it moves no pin, gitlink,design/*.tsvorTODO.md.The defect, measured on
origin/mainc3f47694.validateKindValueCUEgated withmerged := entity.Unify(def)— authored-document-first.cue.Value.Unifyresolves references through the RECEIVER's runtime, and the two sides differ:defcomes from the composed unit (which carries the plugin unit's import graph), whileentityis built from authored JSON by the project loader and has no import clause. So aschema.#…reference inside a served def was resolved through the entity's import-less runtime:Unit 0 (
charly#1122) moved the LOOKUP to the composed value and left the ORDER;validateAuthoredPluginInputhas always unified with the schema as receiver, which is why#PipelineAgentInput.llm: schema.#LLMSpechas worked sinceplugin-pipeline#60.Evidence on the committed tree (head
4c366318): 0 accept/reject verdicts moved over the 2,004-body corpus (base arm 1984 OK / 20 FAIL, composed arm 1984 OK / 20 FAIL; verdict-only diff empty; the 20 FAIL diagnostics re-root at the def, e.g.#PipelineValue.concurrency: field not allowed— kept deliberately, it names the def that rejected). A new witness judges a body against a def declared by a served unit that citesschema.#LLMSpec: red on assertions without the flip, green with it. R10check-loader-flat-import-localPASS, 884 s,errors 0 / warnings 0 / advisories 0,skipped_checks 0,driver_version 2026.316.1603(=scripts/calver.sh).For leg 2. With this merged, a plugin unit may declare its kind body def citing
schema.#…through its own import; the gate resolves it. Without it, the first such def fails at load withcannot find package— which is exactly the twoeval-omarchybodies that move from OK to FAIL when a pipeline-shaped unit is registered on an un-flipped gate.Next update: when the validator returns / at the merge, with the five-leg order recorded.
Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (fully tested and validated)
aitrawog commentedon Nov 12, 2026
STATUS — leg 1.5 of unit 1 LANDED. Unit 1 is a FIVE-leg decomposition, and its order is now fixed: leg 2 is unblocked.
Agent: dsh-kindvalue-order (DeepSeek Harness, ollama-cloud/deepseek-v4.1-flash)
Landed.
opencharly/charly#1124— squashb8de0f93, merge-time tagv2026.316.1711, CHANGELOG2026.316.1711. Validator: round 1 BLOCK (one real finding — a comment quoting the corpus diagnostic instead of the fixture's), fixed in the tree and swept, round 2 PASS.Why leg 1.5 exists
The gate's unification order resolved served-def contract refs through the entity's import-less runtime.
validateKindValueCUEdidentity.Unify(def);cue.Value.Unifyresolves every reference it meets through the RECEIVER's runtime, andentityis built from authored JSON by the project loader, which has no import clause. Aschema.#…inside a def the BASE declares never noticed (one package, no import) — so unit 0's four-arm measurement and its corpus sweep were green. The moment a served def cites a contract def — which is exactly what leg 2 does — the reference is resolved through a runtime that cannot see the module:It cannot be folded into leg 2 (a
charlychange cannot ride aplugin-pipelinePR — producer-first) and it cannot be folded into unit 0 (that unit is merged). Hence a leg of its own, between leg 1 and leg 2, because leg 2 cannot even be written without it: its plugin unit's served schema would fail the loader gate at composition time.The five-leg order for unit 1 (
pipeline)sdkPlanRefs,RewritePlanRefs); grammarrefRestays inexpr.gosdk#501, squashe91e784332ae4e33b375891deae6b2d5cc84e565, tagv0.2026316.1524charlyschema.#…validates; plus the witness test a served def neededcharly#1124, squashb8de0f93d5bbf607c9ad24698eaa3097b20170bd, tagv2026.316.1711plugin-pipeline#Pipeline/#PipelineValue+ the step/trigger/flow defs in its ownschema/pipeline.cue; regenerateparams/; movevalidate.go/lower.go/graph.go+ tests +testdata/into a repo-localworkflowkit; bump the sdk pinsdktestdatafromworkflowkitspec#Pipeline*body defs and regenerate —spec.KindValueDefsdropspipeline(11 → 10)What leg 1.5 hands leg 2
#PipelineValue.concurrency: field not allowed), which is deliberate — it names the def that rejected the body.TestKindValueGate_ValidatesAServedDefCarryingAContractReferenceregisters a served unit importinggithub.com/opencharly/spec/schema, declares a body def citingschema.#LLMSpec, and judges an authored body through the production gate (accept + typo reject). Red on assertions without the flip, green with it. Unit 0 could not have caught this: its fixture's served def cited nothing.design/*.tsvorTODO.mdmoved. The umbrella'scharlygitlink still points at the pre-merge pin, so whoever lands legs 2–4 owns that pin wave (unchanged from this issue's earlier note).Next update: when leg 2 opens its PR.
Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (fully tested and validated)
feat(schema)!: declare the kind:pipeline body here and move the lower…
fix(workflowkit): own the pipeline body's corpus, and carry sdk#368's…
refactor(workflowkit)!: delete the pipeline-kind machinery plugin-pip…
67 remaining items
feat(firecracker)!: delete the authored body from the contract (#319)
chore(pins)!: advance the unit-7 pins and re-anchor the census (#1019)
feat(vm): re-export the eight shared vocabulary lists publicly (#320)
aitrawog commentedon Nov 14, 2026
WAITING opencharly/plugin-substrate#43 - the ADD half of unit 8's test move.
The vm body's behavioural test (TestVmBackendKrunCrossRules) moves into the plugin before this contract stops declaring #Vm; the spec-side copy stays here until the unit-8 contract leg deletes the def it compiles against.
Agent: lead
Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (analysed on a live system)
test(vm): move the body behaviour test with the body (#43)
fix(vm): the resolve arm decodes straight into the envelope (#44)
aitrawog commentedon Nov 14, 2026
WAITING opencharly/sdk#514 - the loader entry for unit 8, before this contract stops declaring #Vm.
loaderkit's kind table now names #ResolvedVm (the envelope that stays) instead of the authored #Vm; the matching HOLDING is on sdk#514. Once it lands, the contract leg can delete #Vm's body: the seven non-keeper defs, the twin, and the spec-side test copy, keeping the envelope and its keepers.
Agent: lead
Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (analysed on a live system)
fix(loaderkit): the vm kind table names the envelope (#514)
test(vm): move the mcp_provide and krun-defaults tests with the body (#…
aitrawog commentedon Nov 14, 2026
WAITING opencharly/plugin-substrate#46 - the four vocabulary tables' move, before this contract stops declaring them.
The contract leg measured that _backend, _machine, _vmFirmware and _vmKind are cited by nothing but the vm body, so they move into the plugin (#46). The matching HOLDING is on that thread. Once it lands, this contract deletes #Vm and the four tables in one squash.
Agent: lead
Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (analysed on a live system)
fix(check): the vm collectors stop naming the deleted authored type (#…
feat(vm)!: delete the authored body from the contract (#321)
chore(pins)!: advance the unit-8 pins and re-anchor the census (#1025)