How aurda012/cursor10x works
Project Type and Purpose
• Cursor10x (now DevContext) is an AI-development context system—a CLI/plug-in style MCP (Model Context Protocol) server that provides persistent, project-centric memory, task management, and coding‐rules enforcement for AI assistants (e.g., Claude).
• It is not a traditional full-stack app but rather a developer tool that sits alongside your codebase, communicates with an LLM, and stores context in a database.
File‐Structure Analysis
• Top‐level files:
• .gitignore, README.md, .cursorrules (global rule definitions)
• Configuration directory:
• .cursor/mcp.json – defines which MCP servers (tools) to run and their environment variables (Turso DB URL & token).
• .cursor/rules/*.mdc – Markdown-based rule files that enforce coding and workflow standards.
• Tasks directory:
• tasks/tasks.json – defines the project’s task workflow.
Key Architectural Insights from README
• Four core components:
1. MCP Server (Node.js CLI tool registered via .cursor/mcp.json)
2. Memory Database (Turso)
3. Memory Subsystems (STM, LTM, Episodic, Semantic)
4. Vector Embedding Service (semantic indexing & search)
• Additional modules:
• Cursor Rules enforcement (.mdc files + .cursorrules)
• Task Management (tasks JSON + workflow toolchain)
a. Main Components:
• Developer Workspace (local code + .cursor config + tasks files)
• MCP Server (cursor10x-mcp CLI process)
• External LLM (e.g., Claude)
• Memory Database (Turso DB)
• Vector Embedding Service (could be OpenAI embeddings or internal)
• Memory Subsystems (STM, LTM, Episodic, Semantic modules within MCP Server)
• Cursor Rules Engine
• Task Manager
b. Interactions & Data Flow:
1. Developer or LLM issues a request (e.g., “Recall authentication decision”).
2. The MCP Server receives the request via MCP protocol.
3. The Cursor Rules Engine consults .mdc rules to validate or transform the request.
4. For memory operations: MCP Server routes read/write to the Memory Subsystems.
5. STM/LTM/Episodic modules read/write metadata and messages to Turso DB via standard queries.
6. Semantic Memory module calls the Vector Embedding Service to embed text/code, then stores/retrieves vectors in the DB.
7. The Task Manager loads tasks from tasks/tasks.json, persists progress in DB, and surfaces next tasks.
8. MCP Server collates context from all subsystems and returns results to the LLM or developer CLI.
c. Architectural Patterns & Principles:
• Modular “memory subsystem” pattern: each memory type is a plug-in.
• Separation of concerns: rules engine, embedding service, database access, and CLI interface are distinct modules.
• Single source of truth: all persistent data lives in Turso DB.
• Configuration-driven: .cursor/mcp.json and .mdc files drive behavior without code changes.
d. Technologies & Frameworks:
• Node.js (MCP server CLI via npx cursor10x-mcp)
• Turso (distributed SQLite-compatible DB)
• JSON (config and tasks definitions)
• Markdown Configuration (for rules)
• MCP protocol (tool registration)
• Vector embeddings (external service or library)