Knowledge Operations
Manage a multi-layered knowledge system for ingesting, organizing, syncing, and retrieving knowledge across multiple stores.
Prefer the live workspace model:
- code work lives in the real cloned repos
- active execution context lives in GitHub, Linear, and repo-local working-context files
- broader human-facing notes can live in a non-repo context/archive folder
- durable cross-machine memory belongs in the knowledge base, not in a shadow repo workspace
When to Activate
- User wants to save information to their knowledge base
- Ingesting documents, conversations, or data into structured storage
- Syncing knowledge across systems (local files, MCP memory, Supabase, Git repos)
- Deduplicating or organizing existing knowledge
- User says "save this to KB", "sync knowledge", "what do I know about X", "ingest this", "update the knowledge base"
- Any knowledge management task beyond simple memory recall
Knowledge Architecture
Layer 1: Active execution truth
- Sources: GitHub issues, PRs, discussions, release notes, Linear issues/projects/docs
- Use for: the current operational state of the work
- Rule: if something affects an active engineering plan, roadmap, rollout, or release, prefer putting it here first
Layer 2: Claude Code Memory (Quick Access)
- Path:
~/.claude/projects/*/memory/
- Format: Markdown files with frontmatter
- Types: user preferences, feedback, project context, reference
- Use for: quick-access context that persists across conversations
- Automatically loaded at session start
Layer 3: MCP Memory Server (Structured Knowledge Graph)
- Access: MCP memory tools (create_entities, create_relations, add_observations, search_nodes)
- Use for: Semantic search across all stored memories, relationship mapping
- Cross-session persistence with queryable graph structure
Layer 4: Knowledge base repo / durable document store
- Use for: curated durable notes, session exports, synthesized research, operator memory, long-form docs
- Rule: this is the preferred durable store for cross-machine context when the content is not repo-owned code
Layer 5: External Data Store (Supabase, PostgreSQL, etc.)
- Use for: Structured data, large document storage, full-text search
- Good for: Documents too large for memory files, data needing SQL queries
Layer 6: Local context/archive folder
- Use for: human-facing notes, archived gameplans, local media organization, temporary non-code docs
- Rule: writable for information storage, but not a shadow code workspace
- Do not use for: active code changes or repo truth that should live upstream
Ingestion Workflow
When new knowledge needs to be captured:
1. Classify
What type of knowledge is it?
- Business decision -> memory file (project type) + MCP memory
- Active roadmap / release / implementation state -> GitHub + Linear first
- Personal preference -> memory file (user/feedback type)
- Reference info -> memory file (reference type) + MCP memory
- Large document -> external data store + summary in memory
- Conversation/session -> knowledge base repo + short summary in memory
2. Deduplicate
Check if this knowledge already exists:
- Search memory files for existing entries
- Query MCP memory with relevant terms
- Check whether the information already exists in GitHub or Linear before creating another local note
- Do not create duplicates. Update existing entries instead.
3. Store
Write to appropriate layer(s):
- Always update Claude Code memory for quick access
- Use MCP memory for semantic searchability and relationship mapping
- Update GitHub / Linear first when the information changes live project truth
- Commit to the knowledge base repo for durable long-form additions
4. Index
Update any relevant indexes or summary files.
Sync Operations
Conversation Sync
Periodically sync conversation history into the knowledge base:
- Sources: Claude session files, Codex sessions, other agent sessions
- Destination: knowledge base repo
- Generate a session index for quick browsing
- Commit and push
Workspace State Sync
Mirror important workspace configuration and scripts to the knowledge base:
- Generate directory maps
- Redact sensitive config before committing
- Track changes over time
- Do not treat the knowledge base or archive folder as the live code workspace
GitHub / Linear Sync
When the information affects active execution:
- update the relevant GitHub issue, PR, discussion, release notes, or roadmap thread
- attach supporting docs to Linear when the work needs durable planning context
- only mirror a local note afterwards if it still adds value
Cross-Source Knowledge Sync
Pull knowledge from multiple sources into one place:
- Claude/ChatGPT/Grok conversation exports
- Browser bookmarks
- GitHub activity events
- Write status summary, commit and push
Memory Patterns
# Short-term: current session context
Use TodoWrite for in-session task tracking
# Medium-term: project memory files
Write to ~/.claude/projects/*/memory/ for cross-session recall
# Long-term: GitHub / Linear / KB
Put active execution truth in GitHub + Linear
Put durable synthesized context in the knowledge base repo
# Semantic layer: MCP knowledge graph
Use mcp__memory__create_entities for permanent structured data
Use mcp__memory__create_relations for relationship mapping
Use mcp__memory__add_observations for new facts about known entities
Use mcp__memory__search_nodes to find existing knowledge
Best Practices
- Keep memory files concise. Archive old data rather than letting files grow unbounded.
- Use frontmatter (YAML) for metadata on all knowledge files.
- Deduplicate before storing. Search first, then create or update.
- Prefer one canonical home per fact set. Avoid parallel copies of the same plan across local notes, repo files, and tracker docs.
- Redact sensitive information (API keys, passwords) before committing to Git.
- Use consistent naming conventions for knowledge files (lowercase-kebab-case).
- Tag entries with topics/categories for easier retrieval.
Quality Gate
Before completing any knowledge operation:
- no duplicate entries created
- sensitive data redacted from any Git-tracked files
- indexes and summaries updated
- appropriate storage layer chosen for the data type
- cross-references added where relevant
1---2name: knowledge-ops3description: 跨多个存储层(本地文件、MCP memory、向量存储、Git 仓库)的知识库管理、摄取、同步和检索。在用户想要保存、组织、同步、去重或跨知识系统搜索时使用。4origin: ECC5metadata:6 source: https://skillmd.com/skills/azusagasaku/knowledge-ops7---89# Knowledge Operations1011Manage a multi-layered knowledge system for ingesting, organizing, syncing, and retrieving knowledge across multiple stores.1213Prefer the live workspace model:14- code work lives in the real cloned repos15- active execution context lives in GitHub, Linear, and repo-local working-context files16- broader human-facing notes can live in a non-repo context/archive folder17- durable cross-machine memory belongs in the knowledge base, not in a shadow repo workspace1819## When to Activate2021- User wants to save information to their knowledge base22- Ingesting documents, conversations, or data into structured storage23- Syncing knowledge across systems (local files, MCP memory, Supabase, Git repos)24- Deduplicating or organizing existing knowledge25- User says "save this to KB", "sync knowledge", "what do I know about X", "ingest this", "update the knowledge base"26- Any knowledge management task beyond simple memory recall2728## Knowledge Architecture2930### Layer 1: Active execution truth31- **Sources:** GitHub issues, PRs, discussions, release notes, Linear issues/projects/docs32- **Use for:** the current operational state of the work33- **Rule:** if something affects an active engineering plan, roadmap, rollout, or release, prefer putting it here first3435### Layer 2: Claude Code Memory (Quick Access)36- **Path:** `~/.claude/projects/*/memory/`37- **Format:** Markdown files with frontmatter38- **Types:** user preferences, feedback, project context, reference39- **Use for:** quick-access context that persists across conversations40- **Automatically loaded at session start**4142### Layer 3: MCP Memory Server (Structured Knowledge Graph)43- **Access:** MCP memory tools (create_entities, create_relations, add_observations, search_nodes)44- **Use for:** Semantic search across all stored memories, relationship mapping45- **Cross-session persistence with queryable graph structure**4647### Layer 4: Knowledge base repo / durable document store48- **Use for:** curated durable notes, session exports, synthesized research, operator memory, long-form docs49- **Rule:** this is the preferred durable store for cross-machine context when the content is not repo-owned code5051### Layer 5: External Data Store (Supabase, PostgreSQL, etc.)52- **Use for:** Structured data, large document storage, full-text search53- **Good for:** Documents too large for memory files, data needing SQL queries5455### Layer 6: Local context/archive folder56- **Use for:** human-facing notes, archived gameplans, local media organization, temporary non-code docs57- **Rule:** writable for information storage, but not a shadow code workspace58- **Do not use for:** active code changes or repo truth that should live upstream5960## Ingestion Workflow6162When new knowledge needs to be captured:6364### 1. Classify65What type of knowledge is it?66- Business decision -> memory file (project type) + MCP memory67- Active roadmap / release / implementation state -> GitHub + Linear first68- Personal preference -> memory file (user/feedback type)69- Reference info -> memory file (reference type) + MCP memory70- Large document -> external data store + summary in memory71- Conversation/session -> knowledge base repo + short summary in memory7273### 2. Deduplicate74Check if this knowledge already exists:75- Search memory files for existing entries76- Query MCP memory with relevant terms77- Check whether the information already exists in GitHub or Linear before creating another local note78- Do not create duplicates. Update existing entries instead.7980### 3. Store81Write to appropriate layer(s):82- Always update Claude Code memory for quick access83- Use MCP memory for semantic searchability and relationship mapping84- Update GitHub / Linear first when the information changes live project truth85- Commit to the knowledge base repo for durable long-form additions8687### 4. Index88Update any relevant indexes or summary files.8990## Sync Operations9192### Conversation Sync93Periodically sync conversation history into the knowledge base:94- Sources: Claude session files, Codex sessions, other agent sessions95- Destination: knowledge base repo96- Generate a session index for quick browsing97- Commit and push9899### Workspace State Sync100Mirror important workspace configuration and scripts to the knowledge base:101- Generate directory maps102- Redact sensitive config before committing103- Track changes over time104- Do not treat the knowledge base or archive folder as the live code workspace105106### GitHub / Linear Sync107When the information affects active execution:108- update the relevant GitHub issue, PR, discussion, release notes, or roadmap thread109- attach supporting docs to Linear when the work needs durable planning context110- only mirror a local note afterwards if it still adds value111112### Cross-Source Knowledge Sync113Pull knowledge from multiple sources into one place:114- Claude/ChatGPT/Grok conversation exports115- Browser bookmarks116- GitHub activity events117- Write status summary, commit and push118119## Memory Patterns120121```122# Short-term: current session context123Use TodoWrite for in-session task tracking124125# Medium-term: project memory files126Write to ~/.claude/projects/*/memory/ for cross-session recall127128# Long-term: GitHub / Linear / KB129Put active execution truth in GitHub + Linear130Put durable synthesized context in the knowledge base repo131132# Semantic layer: MCP knowledge graph133Use mcp__memory__create_entities for permanent structured data134Use mcp__memory__create_relations for relationship mapping135Use mcp__memory__add_observations for new facts about known entities136Use mcp__memory__search_nodes to find existing knowledge137```138139## Best Practices140141- Keep memory files concise. Archive old data rather than letting files grow unbounded.142- Use frontmatter (YAML) for metadata on all knowledge files.143- Deduplicate before storing. Search first, then create or update.144- Prefer one canonical home per fact set. Avoid parallel copies of the same plan across local notes, repo files, and tracker docs.145- Redact sensitive information (API keys, passwords) before committing to Git.146- Use consistent naming conventions for knowledge files (lowercase-kebab-case).147- Tag entries with topics/categories for easier retrieval.148149## Quality Gate150151Before completing any knowledge operation:152- no duplicate entries created153- sensitive data redacted from any Git-tracked files154- indexes and summaries updated155- appropriate storage layer chosen for the data type156- cross-references added where relevant