Validate plugin and bundled skills against the open spec (N2 WP4) #89

Merged
weichen merged 2 commits from feature/n2-skills-wp4 into main 2026-10-07 13:58:47 +00:00
Owner

Why: plugin skills were written to the skill root unvalidated and the bundled recipes carried no name — both now go through the library spec validator (Agent-Native#28).

What:

  • internal/skills/validate.go: ValidateForPlugin (plugin context + located field errors) and builtin validation; Seed validates each SKILL.md before write.
  • host_v2.go: invalid plugin skills abort the plugin load (fail-closed, same shape as agents banned keys).
  • Recipes dogfood: name: added to all four bundled skills.
  • Architecture baseline gains backend/plugins→backend/skills (Dev PR carries it); nested pins at Agent-Native#28 / Agent-Squad#32.

Evidence: go test -count=1 ./... green; TestV2InvalidSkillRejected pins the fail-closed path.

Impact: invalid plugin skills now fail the load with a located error instead of landing silently.

Refs: Agent-Native#28, Agent-Squad#32, Agent-System-Documents#42

Why: plugin skills were written to the skill root unvalidated and the bundled recipes carried no name — both now go through the library spec validator (Agent-Native#28). What: - internal/skills/validate.go: ValidateForPlugin (plugin context + located field errors) and builtin validation; Seed validates each SKILL.md before write. - host_v2.go: invalid plugin skills abort the plugin load (fail-closed, same shape as agents banned keys). - Recipes dogfood: name: added to all four bundled skills. - Architecture baseline gains backend/plugins→backend/skills (Dev PR carries it); nested pins at Agent-Native#28 / Agent-Squad#32. Evidence: go test -count=1 ./... green; TestV2InvalidSkillRejected pins the fail-closed path. Impact: invalid plugin skills now fail the load with a located error instead of landing silently. Refs: Agent-Native#28, Agent-Squad#32, Agent-System-Documents#42
weichen added 2 commits 2026-10-07 13:57:53 +00:00
Why: plugin skills were written to the skill root unvalidated and the
bundled recipes carried no name — both now go through the library's
spec validator (name required + kebab-case + equals dir, description
required, known-keys whitelist).
Evidence: go test -count=1 ./... green; TestV2InvalidSkillRejected pins
the fail-closed path with plugin context + field location; Seed
validates each SKILL.md before write (recipes dogfood-compliant);
nested pins carry agent-native#28 (the validator).
Impact: invalid plugin skills now abort the plugin load with a located
error instead of landing silently; the architecture baseline gains
backend/plugins→backend/skills.
Refs: Agent-Native#28, Agent-Squad#32, N2 plan WP4
Point the nested native and squad pins at the skills spec validation
ci / vet-and-test (pull_request) Successful in 41s
df6745e820
Why: internal/skills/validate.go calls ValidateSkillDocument, which
only exists on agent-native main after #28; the pin must move for CI
to build the new code.
Evidence: nested pins at 7425b32b / 9d3faefb (merged mains).
Impact: none beyond the pins.
Refs: Agent-Native#28, Agent-Squad#32
weichen added 1 commit 2026-10-07 13:57:54 +00:00
Point the nested native and squad pins at the skills spec validation
ci / vet-and-test (pull_request) Successful in 41s
df6745e820
Why: internal/skills/validate.go calls ValidateSkillDocument, which
only exists on agent-native main after #28; the pin must move for CI
to build the new code.
Evidence: nested pins at 7425b32b / 9d3faefb (merged mains).
Impact: none beyond the pins.
Refs: Agent-Native#28, Agent-Squad#32
weichen merged commit b44f78b09a into main 2026-10-07 13:58:47 +00:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: weichen/Agent-System-Backend#89