Commit Graph

23 Commits

Author SHA1 Message Date
9490cd1db4 Merge feature/context-injection into main 2026-02-03 10:07:32 +01:00
1cad7d6cb9 Merge feature/auto-capture into main 2026-02-03 10:06:48 +01:00
53ac83756f Add temporal versioning core and summary generation
- Add node_versions table with migrations for tracking history
- Add version tracking to addNode/updateNode in store
- Add getNodeHistory, getNodeAtTime, diffVersions, restoreVersion
- Add NodeVersion, HistoricalNode, NodeDiff types
- Add summary generation with caching for memory_summary
2026-02-03 10:05:26 +01:00
516b5ec017 Add context injection system (Milestone 3)
- Add src/core/context.ts with context gathering, ranking, and formatting
- Add src/core/config.ts for persistent configuration storage
- Add CLI commands: cortex context, cortex context-hook, cortex config
- Add memory_context MCP tool for Claude Code integration
- Add GET /api/context endpoint
- Include summary.ts from main branch for heartbeat dependency
2026-02-03 10:02:28 +01:00
7a4dc07038 Add auto-capture system (Milestone 2)
- Add capture configuration system with modes: always, manual, decisions, off
- Add Ollama-based conversation summarization and extraction
- Add deduplication via embedding similarity (merge >0.90, link 0.75-0.90)
- Add CLI commands: capture, capture-hook, config
- Add MCP tools: memory_capture, memory_remember, memory_capture_config
- Include summary.ts (previously uncommitted)
2026-02-03 09:59:49 +01:00
761c7a247c Add temporal versioning for node history tracking (Milestone 1)
Enable time-travel queries and history viewing by creating immutable
version records on every node update. Includes database schema changes,
store functions, MCP tools, and CLI commands for viewing history,
comparing versions, and restoring to previous states.
2026-02-03 09:58:16 +01:00
999c748d3d Update .mcp.json to use standalone executable 2026-02-03 09:40:14 +01:00
d484f61b29 Add development plan with 13 milestone specifications
- docs/plan.md: Master roadmap with phases and priorities
- docs/milestones/01-13: Detailed specs for each feature
- Updated CLAUDE.md with plan references and build commands

Milestones cover:
- Phase 1: Temporal versioning, auto-capture, context injection, codebase indexing
- Phase 2: Daily journal, content ingestion, graph visualization, import/export
- Phase 3: Multi-graph, smart retrieval, TUI dashboard, browser extension, shell completions
2026-02-03 09:36:08 +01:00
3d5a979a1b Add standalone executable packaging with esbuild + pkg
- Add npm scripts for building Windows/Linux/macOS executables
- Replace uuid package with crypto.randomUUID() for ESM compatibility
- Use esbuild to pre-bundle code before pkg (fixes MCP SDK subpath exports)
- Update CLI name from 'memory' to 'cortex'
- Update USAGE.md with build instructions and standalone setup
- Add bundle/ and build/ to .gitignore
2026-02-03 09:14:26 +01:00
661325a235 Add AI prompt tool for natural language graph operations
New MCP tool and portal UI for executing natural language instructions
against the memory graph via Ollama (qwen3-coder:30b). Single LLM call
generates a JSON action plan which is executed sequentially.

Supports 8 action types: add_node, update_node, remove_node, add_edge,
remove_edge, bulk_tag, reorganize, query. Actions can reference previous
results via $result[N].field interpolation. Uses /api/chat with few-shot
assistant example, format:json, and temperature:0 for reliable output.
2026-02-03 02:40:01 +01:00
f2f9d729da Add Ollama generation module for AI-powered maintenance
Provides text generation via Ollama (llama3) for heartbeat operations
like auto-dedupe, auto-tag, auto-summarize, auto-split, and auto-archive.
2026-02-03 01:31:17 +01:00
ef268ab0c7 Show metadata sections in node panel and preserve them during merge
- Render metadata.sections as labeled blocks in NodePanel sidebar
- Fix memory_merge to carry forward metadata from merged nodes
2026-02-03 01:09:43 +01:00
af568f81c2 Add query bar, maintenance panel, and heartbeat system
- Query bar with organized/grouped search results in portal
- Maintenance panel UI for triggering and viewing maintenance status
- Heartbeat service with periodic maintenance and dirty-tracking
- Query organizer for grouping search results by tag/kind/parent
- Slide-up animation for query panel
2026-02-03 00:55:08 +01:00
f65653e260 Add 7 living memory tools: split, merge, dedupe, prune, reorganize, bulk_tag, stats 2026-02-02 23:29:44 +01:00
f273ab3dbd Strip embeddings from MCP tool responses
Reduces response size by omitting embedding arrays from serialized output.
2026-02-02 23:16:37 +01:00
d64a80281c Add MCP server for Claude Code memory integration
- Create stdio MCP server wrapping core memory functions (query, show, list, children, add, link)
- Add CLAUDE.md with memory-querying instructions for Claude
- Register MCP server in .mcp.json
- Document MCP setup and tools in USAGE.md
2026-02-02 23:10:38 +01:00
c87f97899d Update USAGE.md with show sections/children details and update --section example 2026-02-02 22:41:30 +01:00
5f7692f5f6 Add structured sections and hierarchical navigation
Add --section flag to add/update commands for structured node content,
render sections and inline children in show, and add memory children command.
2026-02-02 22:29:23 +01:00
f1b59a2d1a Add freshness scoring, auto-decay, and USAGE.md
Add lastAccessedAt timestamp to nodes with schema migration and
backfill. Touch timestamp on read, apply exponential freshness decay
(~69-day half-life) to search scoring alongside BM25 and vector
weights. Add auto-decay that marks untouched nodes as stale after a
configurable threshold, with CLI command and server-side daily interval.
Include comprehensive USAGE.md documenting all CLI commands and REST API.
2026-02-02 22:07:06 +01:00
d1e3adcb3c Fix blank portal: add root element heights, use dagre for graph layout
- Set explicit height on html/body/#root so React Flow container renders
- Replace @dagrejs/dagre (broken CJS dynamic require) with dagre v0.8.5
- Hierarchical top-down layout with dagre, arrow markers on edges
- Move React Flow controls to top-right to avoid floating button overlap
2026-02-02 19:20:53 +01:00
fc075a377b Make portal mobile-friendly with floating buttons and slide-over panels
Replace fixed sidebar with floating action buttons (menu + add node) in
bottom-left corner. Sidebar and node panel now slide in as overlay drawers
with backdrop dismiss, capped width for small screens, and slide animations.
2026-02-02 17:10:32 +01:00
08c26754a8 Add Cortex Portal — web visualization for knowledge graph
Express API server wrapping existing store/graph core with REST endpoints
for nodes, edges, graph, and search. React + Vite portal with React Flow
for interactive graph visualization, Tailwind CSS styling, and full CRUD UI
(sidebar, node panel, add/link modals, search bar, toast notifications).
2026-02-02 17:01:29 +01:00
21107443a7 Initial commit: Cortex — AI project memory & knowledge graph
SQLite-backed knowledge graph with CLI interface. Supports nodes (memory, component, task, decision) connected by typed edges, with hybrid search (BM25 + Ollama embeddings).
2026-02-02 14:53:26 +01:00