Parent Epic
#37
Scope
Add a token_estimate field to the central capability metadata schema. This field holds a deterministically computed token estimate per capability (derived from word count of the .md file, no LLM required). The field enables downstream context budget checks during capability composition.
Acceptance Criteria
AC-21 (Ubiquitous): The central schema definition file shall declare an optional field token_estimate of type integer.
AC-22 (Ubiquitous): A CI script shall compute token_estimate for each capability by applying a deterministic word-count-based formula to the capability .md file and shall verify that the value in .meta.yaml matches the computed value within a defined tolerance.
AC-23 (Ubiquitous): All existing .meta.yaml files shall be populated with a computed token_estimate value.
AC-24 (Unwanted): If token_estimate is present but deviates from the computed value beyond the defined tolerance, the CI validation shall report it as an error.
Dependencies
Notes
- Budget ceiling and tiered truncation strategy are out of scope for this Story — they depend on curate pipeline design and are parked until curate is conceptually defined.
- Origin:
adm/pbl/ai4x-context-budget-model.md (partially absorbed; budget/truncation portions remain parked).
Parent Epic
#37
Scope
Add a
token_estimatefield to the central capability metadata schema. This field holds a deterministically computed token estimate per capability (derived from word count of the.mdfile, no LLM required). The field enables downstream context budget checks during capability composition.Acceptance Criteria
AC-21 (Ubiquitous): The central schema definition file shall declare an optional field
token_estimateof typeinteger.AC-22 (Ubiquitous): A CI script shall compute
token_estimatefor each capability by applying a deterministic word-count-based formula to the capability.mdfile and shall verify that the value in.meta.yamlmatches the computed value within a defined tolerance.AC-23 (Ubiquitous): All existing
.meta.yamlfiles shall be populated with a computedtoken_estimatevalue.AC-24 (Unwanted): If
token_estimateis present but deviates from the computed value beyond the defined tolerance, the CI validation shall report it as an error.Dependencies
Notes
adm/pbl/ai4x-context-budget-model.md(partially absorbed; budget/truncation portions remain parked).