imMamdouhaboammar/anti-slop-engineering / skills/repo-memory-and-invariant-steward
repo-memory-and-invariant-steward
VerifiedMaintains the repository's architectural memory and enforces invariant preservation across sessions. Use when syncing historical decision records into a living compact Invariant Ledger, checking PRs/branches for architectural drift, verifying Gate 0 invariant constraints, or validating formal Reassessment Triggers — even if they don't explicitly say "invariant steward". Do NOT use for routine cosmetic edits or non-consequential scripts.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 12.4 KB |
| agents/openai.yaml | config | 338 B |
| evals/scenarios.json | config | 5.8 KB |
| examples/decision-record-with-invariants.json | config | 1.9 KB |
| examples/drift-violation-sample.diff | other | 558 B |
| examples/invariant-ledger-example.json | config | 4.3 KB |
| examples/reassessment-trigger-example.json | config | 997 B |
| playbooks/README.md | markdown | 2.0 KB |
| playbooks/drift-triage-playbook.md | markdown | 2.5 KB |
| playbooks/references/memory-anti-patterns.md | markdown | 2.3 KB |
| playbooks/steward-playbook.md | markdown | 2.1 KB |
| references/drift-detection-engine.md | markdown | 1.5 KB |
| references/gate0-memory-integration.md | markdown | 1.3 KB |
| references/invariant-ledger-contract.md | markdown | 1.8 KB |
| references/reassessment-protocol.md | markdown | 1.6 KB |
| usecases/drift-audit.md | markdown | 826 B |
| usecases/reassess.md | markdown | 1008 B |
| usecases/sync.md | markdown | 894 B |
references/invariant-ledger-contract.md
View on GitHub# Invariant Ledger Contract & Schema Specification
> Defines the schema, fields, hash provenance, and TOON compaction format for the repository Invariant Ledger.
## Canonical JSON Schema
The living Invariant Ledger (`.anti-slop/invariant-ledger.json`) adheres to the following structure:
```json
{
"schema_version": "1.0.0",
"generated_at": "ISO-8601 Timestamp",
"invariants_count": 4,
"ledger_hash": "SHA-256 string",
"invariants": [
{
"id": "INV-<DOMAIN>-<NUMBER_OR_NAME>",
"category": "concurrency_and_scale | security_and_auth | api_contract | telemetry_and_slo | data_lineage | rollout_and_compatibility | hardware_and_perf | testing_and_simulation | architecture",
"assertion": "Explicit non-negotiable invariant statement",
"rationale": "Why this invariant exists and what catastrophic failure it prevents",
"enforcement_scope": {
"paths": ["glob/pattern/**"],
"patterns": ["required_token"],
"forbidden_patterns": ["banned_token"]
},
"authority": {
"record_type": "source_record_type",
"record_file": "path/to/source-record.json",
"record_sha256": "SHA-256 of source record",
"author": "Architect Name"
},
"status": "active | superseded | deprecated | waived",
"superseded_by": "Optional INV-ID that replaced this entry",
"reassessment_threshold": "Conditions required to unlock or evolve this rule"
}
]
}
```
## TOON Compact Representation (`.anti-slop/invariant-ledger.toon`)
Designed for token-thrifty ingestion by AI agents during Gate 0:
```toon
invariant_ledger[count=N,hash=<12_char_sha>]:
entry[id=INV-ID,cat=<category>,status=active,paths=<comma_separated_globs>]:
assert: <assertion>
forbid: <forbidden_patterns>
```
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack." | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read. | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report. | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt. | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |