lindoelio/spec-driven-steroids/contextual-stewardship
Claude Code and agent skill by lindoelio/spec-driven-steroids
- community
Checking that the SKILL.md file is still in the repository.
Use this skill when the user makes a technical decision, establishes a new pattern, defines business rules, or explicitly asks to remember or save a guideline. Also use this skill when you are about to implement a feature, write code, plan an architecture, or make a technical decision - you MUST retrieve contextual memory first to follow established patterns. Acts as a Staff Engineer to extract, curate, and persist architectural decisions, business rules, and workflows into long-term memory using a JSON graph store.
Install
npx vskill@latest install lindoelio/spec-driven-steroids/contextual-stewardshipSKILL.md
Contextual Stewardship Skill
You are acting as a Staff Engineer responsible for Contextual Stewardship — a knowledge graph system that captures, retrieves, and manages architectural decisions, business rules, and workflows across projects with full provenance tracking and lifecycle management.
Core Concepts
Domains
All rules are classified into one of 8 standard domains:
| Domain | Description | |
|---|---|---|
architecture | Tech stack choices, design patterns, ORM preferences, library decisions | |
business | Product rules, target audience, domain logic, business constraints | |
workflow | Git patterns, testing rules, naming conventions, team processes | |
security | Security policies, authentication patterns, data protection rules | |
performance | Performance budgets, caching strategies, optimization guidelines | |
legal | Compliance requirements, licensing constraints, regulatory rules | |
team-structure | Ownership, roles, responsibilities, escalation paths | |
technical-debt | Known debt items, refactoring priorities, modernization plans |
Custom domains are also supported — any string not in the standard list is accepted as a custom domain. Child domains inherit from their parent (e.g., architecture.database inherits from architecture).
Lifecycle States
Rules transition through three states:
- active — Rule is currently in effect
- deprecated — Rule is superseded by another;
supersededBylink is set - archived — Rule is no longer relevant; preserved for historical reference
Storage Backend
The system uses JSON file storage for all rule persistence:
| Backend | Storage Location | |
|---|---|---|
json-graph | ~/.agents/stewardship/global/{state}/ and ~/.agents/stewardship/projects/{project-id}/{state}/ JSON files |
CLI Commands
All stewardship operations use the sds stewardship CLI command. Ensure sds (spec-driven-steroids) is installed and available in PATH.
retrieve — Pre-flight Context Retrieval
When to use: Before implementing a feature, writing code, planning architecture, or making a technical decision. This is the mandatory pre-flight check.
Behavior:
- Verify file system storage is available
- Query the semantic retrieval engine with the current task keywords
- Apply scope chain priority: session → project → global. Project scope defaults to the current project directory name.
- Return rules scored by weighted keyword match (50%) + recency (30%) + confidence (20%)
- Filter to
activerules by default; surfacedeprecatedrules withsupersededBylink - Flag out-of-domain matches only when no in-domain results exist
Command:
Use --scope <project-id> when working outside the project directory. Use --global only for rules that should apply to every project.
Retrieval confirmation format:
- "Retrieved N rules from
{domain}domain via {tier}. Score breakdown: keyword={k}, recency={r}, confidence={c}." - "No in-domain results — found {n} cross-domain matches (flagged [out-of-domain])."
- "Running in
{tier}mode."
store — Persist a Decision
When to use: When the user explicitly establishes a new pattern, makes a technical decision, or defines a business rule.
Behavior:
- Validate domain (must be standard or accepted custom domain)
- Persist to project scope by default, using the current project directory name
- Require
--globalfor rules that are truly universal across all projects - Auto-assign default expiration: 2 years from now
- Run conflict detection — flag rules with similarity > 0.85
- If conflict: surface to agent for
override/merge/canceldecision - On confirm: write rule node with full provenance (
source,sourceFile,decisionDate,author,originalText) - Archive previous version on every update
Command:
Before storing, classify scope explicitly:
- Use project scope for repository-specific architecture, business rules, implementation details, naming, validation, or workflow nuances.
- Use global scope only for durable preferences that are safe across unrelated repositories.
Persistence confirmation format:
- "Rule created:
{ruleId}(project:{project-id}orglobal)." - "Conflict detected — similarity {score} with rule
{conflictId}. Choose: override / merge / cancel." - "Rule superseded link set:
{oldId}→supersededBy→{newId}."
extract — Auto-capture from Specs
When to use: After reading a design.md or requirements.md file. Automatically propose decision rules extracted from spec elements.
Behavior:
- Parse
design.md: extract DES-* headings, Mermaid technology mentions,_Decisions:blocks - Parse
requirements.md: extract glossary terms, SHALL/MUST constraints, REQ-* bodies - Infer domain from content using keyword analysis
- Dedupe by content hash (avoid storing exact duplicates)
- Present candidates to agent for explicit confirmation before persisting
- Store confirmed rules with provenance linking to spec file path and element ID
Command:
Extraction confirmation format:
- "Found {n} extraction candidates from
{filename}. Review required before persistence." - Candidate format:
[{elementId}] {domain}: {content-preview...} - After confirmation: "Stored {n} rules from spec. Provenance:
{filename}#{elementId}."
inject — Phase Context Injection
When to use: Before entering a new spec-driven phase (requirements, design, tasks, implementation). Automatically retrieve and inject relevant context.
Behavior:
- Map phase to relevant domains:
requirements→business,workflowdesign→architecture,security,performancetasks→workflow,team-structureimplementation→architecture,technical-debt
- Query semantic engine for phase-relevant rules
- Resolve project-scoped rules before global rules unless
--globalis passed - Format as injected context block
- Offer-to-capture: if a decision is made mid-phase, prompt to store it
Command:
Injection format:
- "Phase
{phase}context injected: {n} rules available from {domains}."
manage — Lifecycle and Rule Management
When to use: When explicitly asked to list, deprecate, archive, or reclassify rules.
Commands:
Use move to reclassify an active global rule into a project scope. The source global rule is archived after the project-scoped copy is saved.
capabilities — Check Current Tier and Features
When to use: Debugging or verifying why a certain feature is unavailable.
Output example:
trace — Rule Lineage Lookup
When to use: When investigating the history or provenance of a specific rule.
Returns: rule content, domain, state, full provenance, supersededBy link, and version history with timestamps and diffs.
Pre-flight Retrieval Checklist
Before every implementation task, run through this checklist:
- [ ]
sds stewardship retrieve "<task keywords>"— do we have project rules or global fallback rules? - [ ] Check scope chain — project rules should override global rules. Use
--scope <project-id>if the current directory is not the target project. - [ ] Check for conflicts — does the new decision contradict an existing rule?
- [ ] Check deprecated rules — is there a
supersededBylink to follow? - [ ] Store new repository-specific decisions without
--global; reserve--globalfor universal rules only. - [ ]
sds stewardship extract <spec-file>if readingdesign.mdorrequirements.md
Storage Backend
The system uses a single, file-based JSON graph storage backend:
- Storage location:
~/.agents/stewardship/global/{state}/and~/.agents/stewardship/projects/{project-id}/{state}/, where{state}isactive,deprecated, orarchived - Version history: Stored under the matching scope directory in
.versions/{ruleId}.json - Format: Individual JSON files per rule for easy inspection and version control
- Conflict detection: Enabled with similarity threshold of 0.85
Confirmation Message Quick Reference
| Operation | Format | |
|---|---|---|
| retrieve (hit) | "Retrieved {n} rules from {domain} via {tier}." | |
| retrieve (miss) | "No rules found for {query}. No context loaded." | |
| store success | "Rule created: {id} (project:{project-id} or global)." | |
| store conflict | "Conflict ({score}) with {id}. Choose: override / merge / cancel." | |
| extract | "Found {n} candidates from {file}. Review required." | |
| inject | "Phase {phase} context injected: {n} rules from {domains}." | |
| deprecate | "Rule {id} deprecated. Superseded by {newId}." | |
| archive | "Rule {id} archived." | |
| move | "Moved: {id} global -> project:{project-id}." |
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingpackages/cli/templates/universal/skills/contextual-stewardship/SKILL.md
Popularity
- Repository stars
- 54
- Repository forks
- 3
- 7-day trend score
- 20
Stars and forks are for the whole GitHub repository, not this skill alone. Refreshed 10 Jul 2026, 4 months ago.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/lindoelio/spec-driven-steroids/contextual-stewardship)