AI-Powered Code Reasoning MCP Server for Claude Code

RETER Engine | MCP Protocol | Multi-Language Support

Codeine
Code Intelligence

MCP server for Claude Code that provides semantic code analysis, refactoring detection, RAG-powered search, and intelligent reasoning. Supports Python, JavaScript, C#, C++, Go, Rust, and HTML.

# Analyze architecture with Codeine
await code_inspection({
  action: "get_architecture",
  format: "mermaid"
})

# Find refactoring opportunities
await recommender({
  recommender_type: "refactoring",
  detector_name: "find_large_classes"
})

# Semantic RAG search
await semantic_search({
  query: "authentication logic"
})
7
Languages
70+
Refactoring Detectors
699
Classes Analyzed
4907
Functions Indexed
Core Capabilities

Intelligent Code
Understanding

🔍

Semantic Code Analysis

Deep understanding of code structure using RETER reasoning engine. Extracts classes, functions, inheritance, call graphs, and dependencies.

code_inspection • describe_class • find_callers
🛠️

Refactoring Detection

70+ detectors based on Martin Fowler's patterns. Find God classes, feature envy, shotgun surgery, circular imports, and more.

recommender • find_large_classes • detect_feature_envy
🧠

RAG Semantic Search

FAISS-powered vector embeddings for natural language code search. Find relevant code by describing what you need.

semantic_search • rag_reindex • find_similar
📊

UML Diagrams

Generate class hierarchies, class diagrams with relationships, sequence diagrams, and dependency graphs in Mermaid format.

diagram • class_hierarchy • sequence • dependencies
💭

Structured Reasoning

Thinking tool for step-by-step analysis. Create requirements, tasks, decisions with traceability. Gantt charts for project planning.

thinking • items • project • traceability
🌐

Multi-Language Support

Analyze Python, JavaScript/TypeScript, C#, C++, Go, Rust, and HTML. Language-specific and cross-language queries.

python • javascript • csharp • cpp • go • rust
Architecture

How Codeine Works

Three-layer architecture combining MCP server, Python reasoning wrapper, and C++ RETER engine for maximum performance.

MCP Server Layer

Claude Code integration with tools, resources, and prompts. Session management and instance coordination.

RETER Python Wrapper

High-level API for reasoning, queries, and code analysis. Manages knowledge graphs and inference rules.

RETER C++ Core

RETE algorithm implementation for fast pattern matching. OWL 2 RL and SWRL rule execution.

ANTLR4 Parsers

Language-specific parsing for Python, JavaScript, C#, C++, Go, Rust, and HTML.

Quick Start

Get Running in Minutes

1. Clone Repository

git clone https://github.com/codeine-ai/codeine

2. Install Dependencies

pip install -e . (or use install.bat on Windows)

3. Configure Claude Code

Add MCP server to claude_desktop_config.json

4. Start Analyzing

Use code_inspection, recommender, and thinking tools

Use Cases

From Analysis
to Action

CODE QUALITY

Refactoring Guidance

Detect code smells, find refactoring opportunities, and get step-by-step guidance based on Martin Fowler's patterns.

Learn More →
ARCHITECTURE

Codebase Understanding

Visualize class hierarchies, dependency graphs, and module structure. Understand complex codebases quickly.

Learn More →
SEARCH

Semantic Code Search

Find code by describing what you need in natural language. RAG-powered search across your entire codebase.

Learn More →

Make your AI assistant
understand your code.

Install Codeine and give Claude Code deep insight into your codebase.