deep_research endpoint is an intelligent code analysis agent that goes beyond simple search to provide comprehensive understanding of your codebase. Think of it as having a senior architect who has thoroughly studied every line of your code and can answer complex questions about architecture, patterns, and implementation strategies.
Key features
- Code understanding: Comprehends code logic, architecture, and design patterns.
- Cross-repository analysis: Can analyze relationships between different parts of your codebase.
- Implementation planning: Helps plan new features based on existing code patterns.
- Best practice recommendations: Suggests improvements based on codebase analysis.
- Architecture insights: Provides high-level understanding of system design.
API/MCP reference
Request format
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| input | string | Yes | Your question or research query. Be specific and detailed for best results. |
| repositories | array | No | List of repository identifiers to scope the search. Format: org/repo |
| session_id | string | No | Unique identifier to maintain context across multiple queries in a conversation. |
Best practices
Recommended query strategies
- Be specific and detailed - “How does user authentication work across our microservices?” provides richer insights than general queries
- Include context about your goals - Mentioning why you need the information helps Deep Research tailor its analysis
- Leverage session_id for complex investigations - Build on previous queries to dive deeper into specific areas
- Specify repositories for focused analysis - When you know which repos are relevant, include them for more targeted results
- Ask ‘why’ and ‘how’ questions - Deep Research excels at explaining design decisions and implementation reasoning
Avoid
- Asking for simple keyword searches, use
get_contextinstead - Asking the agent to modify your code, deep-research analyzes, and suggest code, it will not modify files
- Asking about external services not in your codebase\s
- Don’t use for real-time data - it analyzes code structure, not runtime behavior
Usage patterns
Usage patterns