Crate mcpls_core

Crate mcpls_core 

Source
Expand description

§mcpls-core

Core library for MCP (Model Context Protocol) to LSP (Language Server Protocol) translation.

This crate provides the fundamental building blocks for bridging AI agents with language servers, enabling semantic code intelligence through MCP tools.

§Architecture

The library is organized into several modules:

  • lsp - LSP client implementation for communicating with language servers
  • mcp - MCP tool definitions and handlers
  • bridge - Translation layer between MCP and LSP protocols
  • config - Configuration types and loading
  • error - Error types for the library

§Example

use mcpls_core::{serve, ServerConfig};

#[tokio::main]
async fn main() -> Result<(), mcpls_core::Error> {
    let config = ServerConfig::load()?;
    serve(config).await
}

Re-exports§

pub use config::ServerConfig;
pub use error::Error;

Modules§

bridge
Translation layer between MCP and LSP protocols.
config
Configuration types and loading.
error
Error types for mcpls-core.
lsp
LSP client implementation.
mcp
MCP tool definitions and handlers.

Functions§

serve
Start the MCPLS server with the given configuration.