Feat Keywords and the Audit Fields
Every feat file in this workspace carries a keywords array, and the platform computes six audit fields on every read. Together they make the feat catalog self-verifying: a file that drifts from convention shows red checkboxes the moment anyone opens it. This chapter documents the conventions so your new feats conform from birth.
The keyword vocabulary
Keywords are lowercase, dash-separated tokens. A complete combat feat (energy, mana, or stamina) carries at least four, usually six:
| Slot | Tokens | Notes |
|---|---|---|
| Resource (exactly one) | energy / mana / stamina / general | Determined by the file type — never mix |
| Range | melee / ranged / self | How the feat reaches |
| Element / theme | fire, frost, storm, kinetic, corrosion, radiant, shadow, healing, defense, mobility, resource, stat, stealth, summoning, … | Cold→frost, Lightning→storm+shock, Light→radiant |
| Condition | burning / poisoned / bleeding / stunned / prone / restrained / charmed / frightened | Tag every condition the effect applies, cleanses, or keys off |
| Economy (exactly one) | action / free-action / passive / sustained / long-rest / 2-action | (Sustained) variants always carry sustained |
| Tier (exactly one) | tier-1 … tier-4 / legendary | Must match the XP scale below |
| Ranged-attack | ranged-attack | Present iff the name contains shot/throw/bolt (case-insensitive) and it makes an attack roll |
| Efficient | efficient | Present iff resourceCost is 0 |
General feats use the same slots minus the ranged-attack tag.
The XP tier scale
| XP cost | Tier token |
|---|---|
| 1–4 | tier-1 |
| 5–12 | tier-2 |
| 13–24 | tier-3 |
| 25–49 | tier-4 |
| 50+ | legendary |
The token must match the XP; the platform computes the tier from xpCost and flags any mismatch.
The six audit fields (read-only)
These are computed at read time — never write them:
- Tier — derived from XP; compared against your tier token.
- Tier Check — the tier token matches the computed tier, and exactly one tier token is present.
- Efficient Check —
efficientpresent exactly when resourceCost is 0. - Ranged Attack Check —
ranged-attackpresent iff the name contains shot/throw/bolt. - Condition Check — every condition word appearing in the effect text is tagged (cleanse and synergy feats tag what they affect).
- Keywords Complete — at least 4 keywords.
All six render as checkboxes at the bottom of every feat's file view (the layout audit strip). All checks true = the feat conforms. A false checkbox means drift — fix the keywords, never the checkbox.
Prerequisites and upgrade chains
prerequisites and upgradesTo are reference fields — write readable target slugs ("kinetic-shot-i"), and the platform validates the target exists and warns on dangling entries. Upgrade chains live within one feat type; a family's chain reads I→II→…→VI→(legendary). Skip-tier is legal in play (40 XP extra, see the player handbook) but the chain links should still exist as written.
Quick recipe for a new feat
- Pick type → resource keyword fixed.
- Write the effect, then harvest keywords: range, element, every condition touched, economy, tier from XP,
ranged-attackif applicable,efficientif cost 0. - Link prerequisites/upgradesTo as slugs.
- Open the file — six green checkboxes means done.