Logo vun 用于AI代码生成的MCP上下文服务器

用于AI代码生成的MCP上下文服务器

Communautéit
hrirkslab

A Rust-based Model Context Protocol (MCP) server for AI code generation. Solves the context engineering problem by organizing and serving structured context from a local SQLite database to LLMs and AI tools. Fast, standards-based, and easy to run locally.

Editeurhrirkslab
Repositorycontext-server-rs
SproochRust
Forks
2
Stären
7
Disponibel Tools
0
Transporttypstdio
Kategorien
LizenzMIT
Linken
  • Tools mat KI-Workflows verbannen

    用于AI代码生成的MCP上下文服务器 stellt MCP-Funktioune bereit, déi vu kompatibele KI-Clienten a KI-Agente kënne benotzt ginn.

  • 0 disponibel Tools

    Kuckt Iech déi opruffbar Aktiounen hei drënner un, mat Nimm a Beschreiwungen, wa se vum Server geliwwert ginn.

  • Konfiguratioun fir ze kopéieren

    Benotzt d'Installatiounsbeispiller, fir dëse Server an Ärem bevorzugte MCP-Client ze konfiguréieren.

  • Indicateure fir Open Source

    7 Stären an 2 Forks aus dem verlinkte Repository.

Professional Context Engine

A comprehensive context management system for AI-powered development, featuring both a Rust-based MCP server and a VS Code extension for intelligent context assistance.

🚀 Quick Start

MCP Context Server

bash
# Build and run the MCP server
cargo run --release

# Or simply run (default mode)
context-server-rs

CLI Mode (OpenClaw Integration)

bash
# Query contexts by task
context-server-rs query --task auth --project myapp --format json

# List all business rules
context-server-rs list business_rule --project myapp

# Search for "pagination"
context-server-rs search "pagination" --project myapp

# Get specific context by ID
context-server-rs get "rule-123" --project myapp

See CLI Usage Guide for complete documentation. Perfect for OpenClaw agent integration and programmatic access.

VS Code Extension

bash
# Build the VS Code extension
./scripts/build-extension.sh  # Linux/Mac
# or
.\scripts\build-extension.ps1  # Windows

# Install the extension
code --install-extension vscode-extension/professional-context-engine-1.0.0.vsix

📦 Repository Structure

├── src/                          # Rust MCP server source code
│   ├── api/                      # HTTP API endpoints
│   ├── context/                  # Context management logic
│   ├── db/                       # Database layer
│   ├── models/                   # Data models
│   ├── repositories/             # Data access layer
│   └── services/                 # Business logic services
├── vscode-extension/             # VS Code extension
│   ├── src/                      # TypeScript source code
│   ├── INSTALLATION.md           # Installation guide
│   ├── QUICK_START.md            # Quick setup guide
│   └── README.md                 # Extension documentation
├── docs/                         # Project documentation
├── examples/                     # Usage examples
├── tests/                        # Integration tests
├── scripts/                      # Build and utility scripts
│   ├── build-extension.sh         # Extension build script (Linux/Mac)
│   ├── build-extension.ps1        # Extension build script (Windows)
└── README.md                     # This file

🎯 Features

MCP Context Server

  • Model Context Protocol (MCP) compliant - Works with Claude Desktop, Cursor IDE, and other MCP clients
  • Intelligent context management - Store, query, and analyze project context
  • Real-time synchronization - WebSocket support for live updates
  • Advanced search - Semantic and full-text search capabilities
  • Plugin architecture - Extensible with custom plugins
  • Multi-project support - Manage context across multiple projects

CLI Interface (NEW!)

  • Dual-mode binary - Runs as MCP server or CLI tool automatically
  • OpenClaw integration - Designed for autonomous agent workflows
  • Multiple output formats - JSON (programmatic), Text (terminal), YAML (config)
  • Fast query execution - ~10-500ms per context query from database
  • SOLID architecture - Trait-based design for extensibility
  • Command types - Query (task-based), List (type-based), Search (full-text), Get (ID-based)

See CLI Quick Reference and OpenClaw Integration Guide

VS Code Extension

  • Real-time context suggestions - Hover and code action providers
  • Intelligent file monitoring - Automatic analysis of code changes
  • Context creation - Create context entries from selected code
  • Project insights - Analytics dashboard for context health
  • Team collaboration - Real-time synchronization across team members
  • Custom analysis rules - Configure project-specific context extraction

🔧 Installation & Setup

Prerequisites

  • Rust 1.70+ (for MCP server)
  • Node.js 16+ (for VS Code extension)
  • VS Code 1.74+ (for extension)

MCP Context Server

  1. Clone and build:

    bash
    git clone <repository-url>
    cd professional-context-engine
    cargo build --release
  2. Run the server:

    bash
    cargo run --release
  3. Configure MCP clients (see MCP Integration Guide)

VS Code Extension

  1. Build the extension:

    bash
    # Linux/Mac
    ./scripts/build-extension.sh
    
    # Windows
    .\scripts\build-extension.ps1
  2. Install in VS Code:

    bash
    code --install-extension vscode-extension/professional-context-engine-1.0.0.vsix
  3. Configure the extension:

    • Open VS Code Settings (Ctrl+,)
    • Search for "Context Engine"
    • Set server URL to http://localhost:3000

For detailed setup instructions, see:

🔌 MCP Integration

Claude Desktop

Add to your Claude Desktop configuration:

Windows: %APPDATA%\Claude\claude_desktop_config.json macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

json
{
  "mcpServers": {
    "context-server": {
      "command": "path/to/your/context-server-executable",
      "args": [],
      "env": {}
    }
  }
}

Cursor IDE

Configure in Cursor's MCP settings:

json
{
  "mcpServers": {
    "context-server": {
      "command": "cargo",
      "args": ["run", "--release"],
      "cwd": "/path/to/professional-context-engine"
    }
  }
}

🛠️ Development

Building from Source

bash
# Build MCP server
cargo build --release

# Build VS Code extension
cd vscode-extension
npm install
npm run compile
npx vsce package

Running Tests

bash
# Run Rust tests
cargo test

# Run VS Code extension tests
cd vscode-extension
npm test

Development Workflow

  1. MCP Server Development:

    bash
    # Run in development mode
    cargo run
    
    # Run with debug logging
    RUST_LOG=debug cargo run
  2. VS Code Extension Development:

    bash
    cd vscode-extension
    npm run watch  # Compile in watch mode
    # Then press F5 in VS Code to launch extension host

📚 Documentation

🤝 Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Add tests for new functionality
  5. Ensure all tests pass
  6. Submit a pull request

See CONTRIBUTING.md for detailed guidelines.

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

🆘 Support

  • Issues: Report bugs and request features via [GitHub Issues]
  • Documentation: Check the docs/ directory
  • Examples: See examples/ for usage examples

🎯 Roadmap

  • Enhanced semantic search capabilities
  • Additional IDE integrations (IntelliJ, Vim)
  • Cloud deployment options
  • Advanced analytics and reporting
  • Machine learning-powered context suggestions

Built with ❤️ for developers who love intelligent, context-aware coding assistance.

Installatioun

TypingMind
Viraussetzungen:

Node.js 18+

{
  "mcpServers": {
    "hrirkslab-context-server-rs": {
      "command": "",
      "args": []
    }
  }
}

用于AI代码生成的MCP上下文服务器 MCP mat verschiddene KI-Modeller benotzen

TypingMind verbënnt MCP-Tools um Niveau vum Aarbechtsberäich. Soubal 用于AI代码生成的MCP上下文服务器 verbonnen ass, kënnt Dir et mat verschiddene KI-Modeller an TypingMind benotzen, amplaz et fir all Modell separat anzeriichten. Dës MCP-Integratioun leeft lokal iwwer den TypingMind-MCP-Connector op Ärem Apparat.

Ariichtungsuleedung fir de lokale Connector ze benotzen

Benotzt dës Optioun, wann den MCP-Server Zougrëff op lokal Fichieren, Appen oder privat Ressourcen op Ärem Computer brauch.

1

D'MCP-Astellungen opmaachen

Gitt an TypingMind op „Astellungen“, „Erweidert Astellungen“, dann op „Model Context Protocol“ a wielt „Connector ariichten“.

  1. Maacht TypingMind an Ärem Browser op.
  2. Klickt op d'Astellungssymbol.
  3. Gitt op „Erweidert Astellungen“.
  4. Maacht d'Sektioun „Model Context Protocol“ op.
  5. Klickt op „Connector ariichten“ a wielt „Dësen Apparat“.
Ariichtungsbildschierm vum TypingMind-MCP-Connector mat „Dësen Apparat“ ausgewielt
2

De Connector-Befeel ausféieren

Wielt „Dësen Apparat“, kopéiert de Befeel aus TypingMind a féiert en am Terminal aus. Loosst de Prozess lafen, wärend Dir MCP benotzt.

  1. Kopéiert den Ariichtungsbefeel, deen TypingMind uweist.
  2. Maacht Terminal op macOS oder Windows Terminal op Windows op.
  3. Pescht de Befeel an a féiert en aus.
  4. Bestätegt d'Installatioun vum Package, wann den Terminal Iech freet, ob Dir weiderfuere wëllt.
  5. Loosst den Terminal an de Prozess doranner lafen, wärend Dir MCP-Tools benotzt.
3

用于AI代码生成的MCP上下文服务器 als Server derbäisetzen

Wann de Connector-Status „Prett“ ass, klickt op „Serveren änneren“ a pescht d'MCP-Serverkonfiguratioun an.

  1. Waart, bis de Connector-Status „Prett“ weist.
  2. Klickt op „Serveren änneren“.
  3. Pescht d'MCP-Serverkonfiguratioun vu 用于AI代码生成的MCP上下文服务器 an.
  4. Späichert d'Serverlëscht.
  5. Aktualiséiert, wann Dir kontrolléiere wëllt, ob de Connector nach ëmmer prett ass.
MCP-Astellunge vun TypingMind mat aktivem Server an dem Knäppchen „Serveren änneren“
{
  "mcpServers": {
    "hrirkslab-context-server-rs": {
      "command": "npx",
      "args": [
        "-y",
        "context-server-rs"
      ]
    }
  }
}
4

D'Verbindung mat verschiddene Modeller benotzen

Späichert d'Serverlëscht, maacht „Plugins“ op an aktivéiert d'MCP-Tools vu 用于AI代码生成的MCP上下文服务器. Wielt dann e belibegen ënnerstëtzte KI-Modell an TypingMind a benotzt d'Tools am Chat oder weist se engem KI-Agent zou.

  1. Maacht d'Säit „Plugins“ an TypingMind op.
  2. Aktivéiert d'MCP-Tools vu 用于AI代码生成的MCP上下文服务器.
  3. Start e Chat a wielt de KI-Modell, deen Dir benotze wëllt.
  4. Benotzt d'MCP-Tools am Chat oder weist se engem KI-Agent zou.
  5. Wiesselt bei Bedarf op en anere KI-Modell, ouni MCP nei ze verbannen.
TypingMind-Chat mat aktivéierte MCP-Tools an engem ausgewielte KI-Modell
Hëlleft Dir mir bei dëser Aufgab mat 用于AI代码生成的MCP上下文服务器?
用于AI代码生成的MCP上下文服务器
Jo. Ech hunn et gelies.
Dat hunn ech mat 用于AI代码生成的MCP上下文服务器 fonnt.

Heefeg gestallte Froen

Fir wat gëtt de MCP-Server 用于AI代码生成的MCP上下文服务器 benotzt?

用于AI代码生成的MCP上下文服务器 ass e MCP-Server, deen et kompatibele KI-Clienten erlaabt, sech mat externen Tools a Kontext ze verbannen. An TypingMind kënnt Dir dëse MCP-Server eemol derbäisetzen a seng Tools an Ärem KI-Aarbechtsberäich zur Verfügung stellen.

Kann ech 用于AI代码生成的MCP上下文服务器 MCP mat méi KI-Modeller an TypingMind benotzen?

Jo. TypingMind verbënnt MCP-Tools um Niveau vum Aarbechtsberäich. Sou kënnt Dir 用于AI代码生成的MCP上下文服务器 mat verschiddene KI-Modeller wéi Claude, ChatGPT, Gemini oder anere Modeller benotzen, déi Dir an TypingMind konfiguréiert hutt, ouni de MCP-Server fir all Modell separat anzeriichten.

Firwat 用于AI代码生成的MCP上下文服务器 MCP mat TypingMind benotzen?

TypingMind ass eng vun de beschte Benotzeruewerfläche fir LLM-Chat, well et méi KI-Modeller, Prompts, Plugins, KI-Agenten, API-Schlësselen a MCP-Tools an engem Aarbechtsberäich zesummebréngt. Wann 用于AI代码生成的MCP上下文服务器 verbonnen ass, kënnt Dir seng MCP-Tools mat Äre bevorzugte Modeller benotzen a gläichzäiteg Är Chataarbecht an TypingMind organiséieren.

Wéi verbannen ech 用于AI代码生成的MCP上下文服务器 MCP mat TypingMind?

用于AI代码生成的MCP上下文服务器 leeft iwwer de lokale MCP-Connector vun TypingMind. Dat eegent sech am beschten, wann de MCP-Server Zougrëff op lokal Fichieren, Desktop-Apps, Kommandozeilen-Tools oder privat Ressourcen op Ärem Computer brauch.

Wéi eng Tools stellt 用于AI代码生成的MCP上下文服务器 MCP an TypingMind zur Verfügung?

用于AI代码生成的MCP上下文服务器 stellt MCP-Funktiounen zur Verfügung, déi Dir op der Plugins-Säit vun TypingMind aktivéiere kënnt, fir se am Chat ze benotzen oder KI-Agenten zouzeweisen.

Muss ech meng API-Schlëssele mat TypingMind deelen, fir 用于AI代码生成的MCP上下文服务器 MCP ze benotzen?

Nee. TypingMind setzt op lokal Veraarbechtung a léisst Iech d'Kontroll iwwer Är Modellubidder, API-Schlësselen, Prompts a MCP-Konfiguratioun. Wann 用于AI代码生成的MCP上下文服务器 eng Authentifizéierung verlaangt, setzt déi néideg Headeren, OAuth-Astellungen oder lokal Konfiguratioun fir dee MCP-Server derbäi, wann Dir d'Verbindung erstallt.

Änlech MCP-Serveren

All weisen

Elo Ären eegene KI-Workspace ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇