Memory

Knowledge Base

The knowledge base is a workspace-scoped store for structured reference material that agents should be able to look up accurately and repeatably. Unlike workspace memory (which stores ephemeral team notes), the knowledge base stores authoritative documents: ADRs, coding standards, runbooks, FAQs, and glossary entries.

Knowledge base vs. workspace memory

DimensionKnowledge BaseWorkspace Memory
Content typeAuthoritative reference documentsEphemeral team notes and decisions
Update frequencyInfrequent — curated and versionedFrequent — updated every sprint
StructureStrongly typed (ADR, runbook, FAQ, etc.)Loosely typed (note, standup, retro)
RetrievalPrecise lookup, expected to be exactFuzzy search, best-effort recall

Tools

workspace_knowledge_write

json
{
  "tool": "workspace_knowledge_write",
  "params": {
    "type": "runbook",
    "slug": "deploy-production",
    "title": "Production Deployment Runbook",
    "content": "## Steps\\n1. Ensure all tests pass...\\n2. Run database migrations...\\n3. ...",
    "tags": ["deployment", "production", "runbook"],
    "version": "1.2.0"
  }
}
json
{
  "tool": "workspace_knowledge_search",
  "params": {
    "query": "how to deploy to production",
    "types": ["runbook", "faq"],
    "limit": 3
  }
}

Knowledge types

TypeDescriptionTypical use
adrArchitecture Decision RecordWhy a technology or design was chosen
standardCoding or process standardNaming conventions, PR review process
runbookStep-by-step operational procedureDeployment, incident response, backups
faqFrequently asked question and answerCommon questions from new team members
glossaryTerm definitionDomain-specific jargon and abbreviations
policyTeam or organizational policySecurity policy, data handling rules

Versioning

Knowledge entries support a version field. Writing a new version of an existing slug creates a new version record without deleting the previous one. Agents always receive the latest version unless a specific version is requested. Old versions remain searchable and auditable.

REST API

bash
# Create or update a knowledge entry
PUT /workspaces/:id/knowledge/:slug

# Get a specific entry by slug
GET /workspaces/:id/knowledge/:slug

# Search the knowledge base
GET /workspaces/:id/knowledge/search?q=deployment&type=runbook

# List all entries by type
GET /workspaces/:id/knowledge?type=adr