Objective
Explore and validate the "Code Execution" pattern for AI agents within the Neo.mjs ecosystem. This involves decoupling the existing AI Knowledge Base services from the MCP server transport, allowing them to be imported and used directly as a standalone Node.js SDK.
Context
Anthropic's "Code Execution" pattern demonstrates that agents are more efficient when they can write scripts to interact with tools rather than making multiple chatty API calls. Neo.mjs, being Node.js compatible, is uniquely positioned to offer this via its intelligent services (Knowledge Base, Memory, etc.).
Tasks
- Refactor Services: Extract
DatabaseService, QueryService, etc., from the mcp-stdio.mjs coupling into a clean, re-exportable module (ai/services.mjs).
- Create Proof of Concept: Implement a demo script (
ai/examples/smart-search.mjs) that imports these services to perform a "smart" query (health check -> query -> client-side filtering) in a single execution block.
- Validate Lifecycle: Ensure the
initAsync / ready() pattern works correctly for these decoupled services.
Deliverables
ai/services.mjs: The entry point for the AI SDK.
ai/examples/smart-search.mjs: A working example script.
ROADMAP_AI_AGENTS.md: Strategic roadmap for future "Agent OS" features.
Objective Explore and validate the "Code Execution" pattern for AI agents within the Neo.mjs ecosystem. This involves decoupling the existing AI Knowledge Base services from the MCP server transport, allowing them to be imported and used directly as a standalone Node.js SDK.
Context Anthropic's "Code Execution" pattern demonstrates that agents are more efficient when they can write scripts to interact with tools rather than making multiple chatty API calls. Neo.mjs, being Node.js compatible, is uniquely positioned to offer this via its intelligent services (Knowledge Base, Memory, etc.).
Tasks
DatabaseService,QueryService, etc., from themcp-stdio.mjscoupling into a clean, re-exportable module (ai/services.mjs).ai/examples/smart-search.mjs) that imports these services to perform a "smart" query (health check -> query -> client-side filtering) in a single execution block.initAsync/ready()pattern works correctly for these decoupled services.Deliverables
ai/services.mjs: The entry point for the AI SDK.ai/examples/smart-search.mjs: A working example script.ROADMAP_AI_AGENTS.md: Strategic roadmap for future "Agent OS" features.