Spectre 0.2.7 adds declarative runtime Skills and deterministic Routing projections. State remains writer v5, Run remains writer v2, and canonical Instance checkpoints remain schema 4. No existing durable checkpoint migration is required.
What changes
- Compiled Skills may declare
requires_operation/2and usecall_operation/2. The operation must already exist in the host Agent's closed registry. - Canonical Skill prompt components now include a versioned per-Skill budget. Existing canonical Definition fixtures remain readable; a compiled legacy Skill without the field receives the current conservative budget in the unified view.
- Definition and Stack closures advertise both Audit and Routing projection generators by default.
- Trusted hosts may build a
Spectre.Skill.Definitionfrom portable data and manage it withSpectre.Skill.Runtime.
Upgrade steps
- Pin
spectreto tag0.2.7and compile with warnings as errors. - Run the full State, Run, Instance, Definition, and Stack conformance suite retained from 0.2.6.
- If a compiled Skill uses
call_operation, register the referenced operation on every host Agent and grant it in the effective Authority Envelope. - Grant only the lifecycle capabilities the host actually needs: mount, replace, and disable are separate stable capability strings.
- Reserve kernel prompt tokens and set a per-Skill ceiling before accepting any runtime-authored Skill.
- Treat every mutation as revision CAS and retain the returned runtime value.
- Execute returned
Spectre.Operation.Requestvalues only through the normal trusted host boundary, then release their continuation explicitly.
Fail-closed differences
Runtime Skill construction rejects unknown fields, executable templates, uncapped fragments, callback references, duplicate exact routes, undeclared operations, and overlapping positive/negative applicability examples. Mount also rejects failed anti-hijack examples, authority gaps, registry gaps, declared conflicts, or prompt overflow. Equal-specificity routing ambiguity returns an error.
The canonical load path repeats the security-sensitive checks: prompt budgets are rederived from restored fragments, effective fragment governance fields must match Spectre's assignments, and JSON operation references must resolve to an existing host registry ID. Forbidden tags never contribute routing specificity, and non-scalar prompt placeholders return a structured error. In-memory Canonical and prebuilt Skill Definition structs are revalidated too; malformed route, requirement, prompt, or Routing-projection collections cannot bypass the load boundary or raise protocol exceptions.
Negative anti-hijack examples fail whether they select one route or are
ambiguous across several routes. Inputs that cannot be normalized by
Spectre.Input return {:invalid_skill_input, shape} from Skill routing and
response boundaries.
Disabling no longer implies that owned in-flight work is rebound to a newer Skill. A live generation drains until its exact continuations are released. Replacement likewise retains an old Definition only for continuations already pinned to it.
What does not change
- A model cannot publish, activate, mount, replace, or disable a Skill by itself.
- Runtime Skills do not register executors or run operations directly.
- Agent/Subject identity, Activation fencing, Definition lifecycle, Skill state branches, and checkpoint writers are unchanged.
- Generated callbacks, goal-driven Work, autonomous Forge behavior, empirical reflection, and governance are not part of 0.2.7.
See Runtime Skills and Routing Projections for the complete host flow and Preparing for Spectre 0.3 for the remaining gate ledger.