Repository navigation
refactor(framework): replace skill test sections with scoped rules #985
Copy link
Copy link
Open
Description
Problem
Dedicated Test sections scatter constraints that already belong to an action's process or the skill's shared rules. The skill generator also requires a test table per action, encouraging this duplication.
Skills should read as a logical sequence of actions, supported by rules at the appropriate scope. Some existing test entries carry useful verification or stopping conditions; preserve those requirements during the migration.
Scope
- Remove dedicated
Test/Testssections from all shipped skill definitions, including routers and actions. - Use one skill-level
Rulessection for constraints that apply to the whole skill and all its actions.- Consolidate existing
Transversal rulesinto it, without adding a parallel section.
- Consolidate existing
- Allow an optional action-level
Rulessection for constraints that apply to the entire action, only when the action owns them.- Keep shared constraints at their owning source rather than repeating them in every action.
- Keep ordered execution, concrete verification steps, and branching or stopping behavior in the process.
- Review each removed test entry: merge duplicates, relocate invariants to their owning rules, and turn necessary checks into executable process steps.
- Update the skill generator's authoring contract, planning and writing actions, templates, and review guidance to produce this structure.
- Replace R11's test-section requirement and R13's mandatory test table with the rules-scope contract.
- Update affected documentation, validation fixtures, snapshots, and checks that depend on the old structure.
Acceptance criteria
- All shipped skill routers and actions use the new structure without dedicated
Test/Testssections. - Skill-level rules apply across all actions; action-level rules apply only within their owning action.
- No shared rule is duplicated across action files, and no parallel
Rules/Transversal rulessections remain. - Every meaningful invariant, verification step, failure condition, and stopping condition from the removed sections has an appropriate home.
- Processes remain a logical sequence of actions; the migration is not a mechanical renaming of test tables to rules.
- Creating and modifying a skill through the generator produces the new structure.
- Repository checks pass with affected fixtures and snapshots updated.
Prior art in this repo
- Skill authoring contract: R11 defines action sections; R13 requires observable test tables; R9 and R17 establish rule ownership.
- Action template and router template: the current generated structure.
- Skill planning and skill writing: per-action tests are planned and copied into generated actions.
- Commit action: an example of useful verification conditions to preserve.
- Related PR #981: readability, conflict checking, and references by purpose.
Out of scope
- Removing developer test suites, acceptance criteria in product or implementation artifacts, or the actual testing and QA capabilities of skills.
- Changing action outcomes or weakening required verification and approval gates.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Type
Fields
Priority
None yet
Projects
- StatusShow more project fieldsIdeation
Activity
alexsoyes commentedon Oct 9, 2026
J'aurais jamais dû créer
## Testshistoriquement c'était pour vérifier que la skill se triggerait bien, mais on a abandonné le truc (ROI pas si impactant), et c'est resté.Ici je suis en mode blast radius, on les vire partout, on les remplace par des rules propre (voir #950)
On va gagner des tokens et de la cohérence, less is more.
P.S. : OUI Baptiste on peut prévoir un backward compat sur une ligne pour faire la migration sur le
generate-skill.Sinon, pour le reste, je préconise une méga PR qui va tous les virer de chez nous (le framework), en nous assurons ne pas perdre d'info.