-
-
Notifications
You must be signed in to change notification settings - Fork 28
Glossary
In-memory term registry for CortexPrism, providing a centralized dictionary of domain terms with alias resolution and category filtering. Implemented in src/memory/glossary.ts.
Each term has:
| Field | Type | Description |
|---|---|---|
| Name (key) | string |
Canonical term name, stored lowercase |
definition |
string |
Term definition text |
aliases |
string[] |
Alternative names for the same concept |
category |
string |
Grouping category, default "general"
|
defineTerm(name: string, definition: string, category?: string, aliases?: string[]): voidRegisters a term in the in-memory map. The name is normalized to lowercase. Aliases are also lowercased.
defineTerm("RAG", "Retrieval-Augmented Generation — combines LLMs with external data retrieval", "ai-concepts", ["retrieval-augmented-generation"]);lookupTerm(name: string): { name, definition, aliases, category } | nullResolves a term by name or alias, case-insensitive. Returns null if not found.
Resolution order:
- Direct match against canonical name (lowercase)
- Scan all terms for matching alias
Returns the canonical name (original casing), definition, aliases, and category.
listTerms(category?: string): Array<{ name, definition, category }>Lists all terms, optionally filtered by category. Returns simplified objects (no aliases in output).
getCategories(): string[]Returns all unique categories in sorted order.
All terms are stored in a Map<string, { definition, aliases: string[], category }> in memory. Terms persist only for the runtime duration of the process.
| Method | Path | Description |
|---|---|---|
POST |
/api/memory/glossary |
Define a new term |
GET |
/api/memory/glossary/:name |
Look up a term by name |
GET |
/api/memory/glossary |
List terms (query: ?category=) |
GET |
/api/memory/glossary/categories |
List all categories |
DELETE |
/api/memory/glossary/:name |
Remove a term |
curl -X POST http://localhost:3000/api/memory/glossary \
-H "Content-Type: application/json" \
-d '{"name":"A2A","definition":"Agent-to-Agent protocol for AI interop","category":"protocols","aliases":["agent2agent","a2a-protocol"]}'curl http://localhost:3000/api/memory/glossary/agent2agent
# → returns the A2A term (resolved via alias)- Agent context injection: Terms relevant to a conversation can be injected into the system prompt
- Cross-agent shared vocabulary: Ensures consistent terminology across agents
-
User-facing help:
/glossarycommand to look up terms in chat
- A2A Protocol — One of the protocols definable in the glossary
- MCP Gateway — MCP terminology
- Memori Checkpoints — Memory system that can reference glossary terms
CortexPrism — Open-source agentic AI harness · MIT License · Built with Deno 2.x + TypeScript
- Agent Loop
- Metacognition
- Memory System
- Skills System
- Sub-Agents
- Built-in Tools
- Code Intelligence
- Code Sandbox
- Cross-Agent Context Protocol
- Prompt Lab
- PKM Assistant
- Voice Pipeline
- Computer Use
- Browser Tool
- Git & GitHub
- Scheduler & Jobs
- Dashboard
- Observability
- A2A Protocol
- MCP Gateway
- Distributed Nodes
- Memori Checkpoints
- Eval System
- Workflow Engine
- Triggers
- Projects
- TUI
- Glossary
- Update System