Create MCP Server for codebase_search to Enable Semantic Code Search for External AI Agents pls #8211
b9348
started this conversation in
Feature Requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
i dont know english, all text create by llm
Body
Summary
I would like to request the development of an MCP (Model Context Protocol) server that exposes Roo-Code's powerful
codebase_search
functionality. This would allow other AI agents and tools (such as Claude CLI, Gemini CLI, and other MCP-compatible systems) to leverage Roo-Code's semantic search capabilities for code exploration and understanding.Background
Roo-Code currently includes an excellent semantic search tool called
codebase_search
1 that uses vector embeddings to find relevant code based on meaning rather than exact text matches 2 . This tool is particularly effective for understanding how features are implemented across multiple files and discovering API usage patterns 3 .Proposed Solution
Create a standalone MCP server that:
Exposes the core search functionality: Wrap the existing
CodeIndexManager
and search logic 4 into an MCP-compatible interfaceProvides semantic search tools: Offer tools similar to the current
codebase_search
implementation with parameters for:query
: Natural language search querypath
: Optional directory filteringMaintains the same quality: Preserve the current search result format including file paths, similarity scores, line numbers, and code chunks 5
Benefits
Technical Considerations
The MCP server would need to:
Use Cases
This would enable semantic code search in:
Would the maintainers be interested in developing such an MCP server, or would you be open to community contributions for this feature?
Notes
The request focuses on extracting the core semantic search functionality from Roo-Code's
codebase_search
tool and making it available as a standalone MCP server. This would allow the powerful semantic search capabilities currently exclusive to Roo-Code users to be leveraged by other AI development tools in the ecosystem. The technical implementation would likely involve refactoring the existingCodeIndexManager
and search logic into a server that can be consumed by any MCP-compatible client.Wiki pages you might want to explore:
Citations
File: src/core/tools/codebaseSearchTool.ts (L1-25)
File: src/core/tools/codebaseSearchTool.ts (L72-85)
File: src/core/tools/codebaseSearchTool.ts (L97-119)
File: src/core/prompts/tools/codebase-search.ts (L4-5)
File: src/core/prompts/sections/capabilities.ts (L24-25)
Beta Was this translation helpful? Give feedback.
All reactions