Summary
There is no CI validation of template.yaml anywhere (grep over .github/workflows/*.yml for template.yaml / template_service / compatibility returns zero hits). The only declaration-vs-file cross-checks that exist — compatibility checks X-003 (skills) and X-004 (mcp_servers) — run against a live agent's workspace at runtime and are advisory/non-blocking, so they cannot fail a build.
That gap is the root cause of #1646: the bundled Cornelius template was a vendored snapshot of Abilityai/cornelius that took template.yaml + CLAUDE.md + .gitignore but not .claude/ or resources/local-brain-search/. It advertised ~24 skills, 9 sub-agents and a FAISS semantic tier the bundle could not serve, and shipped through a release (v0.8.0) with nobody noticing — on the agent that is auto-seeded for every fresh install (trinity-enterprise#107).
#1646 fixes that one instance and regression-tests it. This issue guards the class.
Context
tests/unit/test_1646_cornelius_template_claims.py (from #1646) already encodes the rules, deliberately written as "every declaration resolves to a file" rather than pinning a list. It is scoped to the Cornelius bundle only. The work here is to generalize it across config/agent-templates/*/ and wire it to a workflow.
Worth knowing: skills, sub_agents and capabilities have no functional effect at creation — crud.py:566-609 reads only type, resources, tools, credentials.mcp_servers, runtime, shared_folders. They are display metadata (rendered by InfoPanel.vue from /api/agents/{name}/info, which echoes template.yaml verbatim and unvalidated), which is exactly why drift is invisible until a user clicks something.
Suggested approach
A CI job over every config/agent-templates/*/template.yaml asserting:
Open design question (decide in the issue, not in review)
Should the check also validate capability tokens? Today capabilities: is a free-form string list with no registry, and brain-orb is the only token anything reads (src/frontend/src/router/index.js:82 gates the Brain tab on it). Everything else is a display chip behind a <details>. Making it a validated enum is a bigger question — it would need a token registry and a decision about whether third-party templates may invent tokens — and may belong in its own issue.
Acceptance Criteria
Related
Summary
There is no CI validation of
template.yamlanywhere (grepover.github/workflows/*.ymlfortemplate.yaml/template_service/compatibilityreturns zero hits). The only declaration-vs-file cross-checks that exist — compatibility checksX-003(skills) andX-004(mcp_servers) — run against a live agent's workspace at runtime and are advisory/non-blocking, so they cannot fail a build.That gap is the root cause of #1646: the bundled Cornelius template was a vendored snapshot of
Abilityai/corneliusthat tooktemplate.yaml+CLAUDE.md+.gitignorebut not.claude/orresources/local-brain-search/. It advertised ~24 skills, 9 sub-agents and a FAISS semantic tier the bundle could not serve, and shipped through a release (v0.8.0) with nobody noticing — on the agent that is auto-seeded for every fresh install (trinity-enterprise#107).#1646 fixes that one instance and regression-tests it. This issue guards the class.
Context
tests/unit/test_1646_cornelius_template_claims.py(from #1646) already encodes the rules, deliberately written as "every declaration resolves to a file" rather than pinning a list. It is scoped to the Cornelius bundle only. The work here is to generalize it acrossconfig/agent-templates/*/and wire it to a workflow.Worth knowing:
skills,sub_agentsandcapabilitieshave no functional effect at creation —crud.py:566-609reads onlytype,resources,tools,credentials.mcp_servers,runtime,shared_folders. They are display metadata (rendered byInfoPanel.vuefrom/api/agents/{name}/info, which echoestemplate.yamlverbatim and unvalidated), which is exactly why drift is invisible until a user clicks something.Suggested approach
A CI job over every
config/agent-templates/*/template.yamlasserting:skills:→.claude/skills/<name>/SKILL.mdexists in that bundle (theX-003rule, moved pre-merge)sub_agents:→.claude/agents/<name>.mdexists — no check exists for this today, at runtime or otherwise, andInfoPanel.vue:131-160,383-391renders sub_agents as a clickable delegation prompt, so a phantom entry is a button that resolves to nothingmcp_servers:≡.mcp.json.templatekeys (theX-004rule). Notetrinityis injected into.mcp.jsonby the platform at start and is legitimately absent from the template fileCLAUDE.md@-imports resolve inside the bundle (the vendored file carried@.claude/settings.mdand@knowledge-base-analysis.md; neither shipped, so both resolved to nothing on every fresh install)Open design question (decide in the issue, not in review)
Should the check also validate capability tokens? Today
capabilities:is a free-form string list with no registry, andbrain-orbis the only token anything reads (src/frontend/src/router/index.js:82gates the Brain tab on it). Everything else is a display chip behind a<details>. Making it a validated enum is a bigger question — it would need a token registry and a decision about whether third-party templates may invent tokens — and may belong in its own issue.Acceptance Criteria
config/agent-templates/*/, not just CorneliusRelated
services/compatibility/static_checks.py(c_x003,c_x004— the runtime rules to lift)