context-save
Save a decision record, strategic bet, or learning to the persistent context registry.
Vision to Value Phase
Phase 6: Learning & Adaptation - This skill persists organizational knowledge for future use.
Prerequisites: Decision record, strategic bet, or learning created Outputs used by: All phases (enables organizational memory)
Auto-Initialization
Before saving, ensure the context folder structure exists. If any required folder or file is missing, create it:
-
Check if
context/folder exists - if not, inform user to run/setupfirst OR create the basic structure:context/decisions/index.mdcontext/bets/index.mdcontext/assumptions/registry.mdcontext/portfolio/active-bets.mdcontext/learnings/index.md
-
When creating year folders (
context/decisions/2026/), create them automatically.
Purpose
The context registry provides organizational memory. This skill extracts key information from documents and saves them to the appropriate index, enabling future recall and cross-referencing.
When to Use
Invoke /context-save after:
- Creating a decision record with
/decision-record - Formulating a strategic bet with
/strategic-bet - Completing a retrospective with
/retrospective - Completing an outcome review with
/outcome-review - Completing a decision quality audit with
/decision-quality-audit
Process
1. Identify What to Save
Ask the user what they want to save:
- Decision Record → Extract to
context/decisions/ - Strategic Bet → Extract to
context/bets/andcontext/portfolio/ - Learning → Extract to
context/learnings/ - Assumptions → Extract to
context/assumptions/registry.md
2. Extract Key Information
For Decision Records
Extract and save:
| ID | Title | Date | Owner | Product | Status | Tags |
- Include Product field if specified (for multi-product organizations)
- Generate tags from content (3-5 relevant keywords)
- Link related decisions if mentioned
- Extract assumptions to assumption registry
For Strategic Bets
Extract and save:
| ID | Title | Date | Owner | Product | Status | Key Assumption |
- Include Product field if specified (for multi-product organizations)
- Add to
context/portfolio/active-bets.mdif status is Active - Extract ALL explicit assumptions to
context/assumptions/registry.md - Note upcoming checkpoints
For Learnings
Extract and save:
| ID | Learning | Source | Date | Product | Tags | Confidence |
- Include Product field if applicable (for multi-product organizations)
- Categorize by type (Strategy, Product, GTM, Customer, Process)
- Link to source document
For Assumptions
Extract and save:
| ID | Assumption | Source | Confidence | Validation Method | Status | Outcome |
- Generate assumption ID (A-NNN, sequential)
- Link back to source decision/bet
- Set initial status to "Pending"
3. Update Index Files
- Read the current index file
- Add the new entry to the appropriate table
- Update "Last updated" timestamp
- Update quick filters/categories
- Write the updated index
4. Save Full Record
For decisions and bets, also save the full record:
- Create year folder if needed:
context/[type]/[YYYY]/ - Save full document as
[ID].md
5. Update JSON Index
Also update context/index.json for fast retrieval:
- Read
context/index.json - Add entry to the
entriesarray:{ "id": "DR-2026-001", "title": "API Versioning Strategy", "type": "decision", "path": "context/decisions/2026/DR-2026-001.md", "topics": ["api", "versioning", "compatibility"], "phase": "phase2", "created": "2026-01-25", "lastAccessed": "2026-01-25" } - Update
topicIndex- add ID to each topic array - Update
typeIndex- add ID to the type array (decision, bet, learning) - Update
phaseIndex- add ID to the appropriate phase array - Update
lastUpdatedtimestamp - Write updated JSON
Topic extraction:
- Use tags from the document
- Extract key terms from title
- Include product name if multi-product org
6. Confirm Save
Report what was saved:
Saved to context registry:
- Decision DR-2026-001 added to decisions/index.md
- 3 assumptions extracted to assumptions/registry.md
- Full record saved to decisions/2026/DR-2026-001.md
- JSON index updated (topics: api, versioning, compatibility)
Instructions
- Ask what type of content to save (or detect from recent conversation)
- If the content was just created, extract from it directly
- If content is in a file, read it using @path/to/file.md syntax
- Extract metadata following the formats above
- Read current index files before updating
- Preserve existing entries when adding new ones
- Generate sequential IDs based on existing entries
- Update all affected index files
- Report what was saved and where
ID Generation
- Decisions:
DR-[YYYY]-[NNN](e.g., DR-2026-001) - Bets:
SB-[YYYY]-[NNN](e.g., SB-2026-003) - Assumptions:
A-[NNN](e.g., A-015) - sequential across all assumptions - Learnings:
L-[NNN](e.g., L-042) - sequential across all learnings
Check existing indexes to determine next available number.
Cross-Reference Extraction (v3)
After saving a new entry to the context registry:
- Scan for ID references: Look for patterns matching existing IDs (DR-, SB-, FB-, A-, L-, DOC-) in the entry content
- Create bidirectional links: Update
crossReferencesincontext/index.json - Update topic indexes: Add entry keywords to
topicIndex,productIndex, andphaseIndexas appropriate - Log what was linked: Include cross-reference summary in the save confirmation
See rules/context-graph.md for the full cross-reference specification.