Houtini-lm
Houtini LM - LM Studio MCP Server with Expert Prompt Library and Custom Prompting - Offload tasks to LM Studio from Claude Desktop.
README
Houtini LM - LM Studio MCP Server with Expert Prompt Library and Custom Prompting
Your unlimited AI companion: This MCP server connects Claude to LM Studio for code analysis, generation, and creativity
Transform your development workflow with our expert-level prompt library for code analysis, professional documentation generation, and creative project scaffolding - all running locally without API costs. For developers, vibe coders and creators alike.
What This Does
Houtini LM saves your Claude context window by offloading detailed analysis tasks to LM Studio locally or on your company network whilst Claude focuses on strategy and complex problem-solving. Think of it as your intelligent coding assistant that never runs out of tokens.
Perfect for:
- 🔍 Code analysis - Deep insights into quality, security, and architecture
- 📝 Documentation generation - Professional docs from code analysis
- 🏗️ Project scaffolding - Complete applications, themes, and components
- 🎮 Creative projects - Games, CSS art, and interactive experiences
- 🛡️ Security audits - OWASP compliance and vulnerability detection
Quick Start Prompt Guide
Once installed, simply use natural language prompts with Claude:
Use houtini-lm to analyse the code quality in C:/my-project/src/UserAuth.js
Generate comprehensive unit tests using houtini-lm for my React component at C:/components/Dashboard.jsx
Use houtini-lm to create a WordPress plugin called "Event Manager" with custom post types and admin interface
Audit the security of my WordPress theme using houtini-lm at C:/themes/my-theme
Create a CSS art generator project using houtini-lm with space theme and neon colours
Use houtini-lm to convert my JavaScript file to TypeScript with strict mode enabled
Generate responsive HTML components using houtini-lm for a pricing card with dark mode support
Prerequisites
Essential Requirements:
-
LM Studio - Download from lmstudio.ai
- Must be running at
ws://127.0.0.1:1234 - Model loaded and ready (13B+ parameters recommended)
- Must be running at
-
Desktop Commander MCP - Essential for file operations
- Repository: DesktopCommanderMCP
- Required for reading files and writing generated code
-
Node.js 24.6.0 or later - For MCP server functionality
- Download from nodejs.org
-
Claude Desktop - For the best experience
- Download from claude.ai/download
Installation
1. Install Dependencies
# Clone the repository
git clone https://github.com/houtini-ai/lm.git
cd lm
# Install Node.js dependencies
npm install
2. Configure Claude Desktop
Add to your Claude Desktop configuration file:
Windows: %APPDATA%/Claude/claude_desktop_config.json
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"houtini-lm": {
"command": "node",
"args": ["path/to/houtini-lm/index.js"],
"env": {
"LLM_MCP_ALLOWED_DIRS": "C:/your-projects,C:/dev,C:/websites"
}
}
}
}
3. Start LM Studio
- Launch LM Studio
- Load a model (13B+ parameters recommended for best results)
- Start the server at
ws://127.0.0.1:1234 - Verify the model is ready and responding
4. Verify Installation
Restart Claude Desktop, then test with:
Use houtini-lm health check to verify everything is working
Available Functions
🔍 Analysis Functions (17 functions)
analyze_single_file- Deep code analysis and quality assessmentcount_files- Project structure with beautiful markdown treesfind_unused_files- Dead code detection with risk assessmentsecurity_audit- OWASP compliance and vulnerability scanninganalyze_dependencies- Circular dependencies and unused imports- And 12 more specialized analysis tools...
🛠️ Generation Functions (10 functions)
generate_unit_tests- Comprehensive test suites with framework patternsgenerate_documentation- Professional docs from code analysisconvert_to_typescript- JavaScript to TypeScript with type safetygenerate_wordpress_plugin- Complete WordPress plugin creationgenerate_responsive_component- Accessible HTML/CSS components- And 5 more generation tools...
🎮 Creative Functions (3 functions)
css_art_generator- Pure CSS art and animationsarcade_game- Complete playable HTML5 gamescreate_text_adventure- Interactive fiction with branching stories
⚙️ System Functions (5 functions)
health_check- Verify LM Studio connectionlist_functions- Discover all available functionsresolve_path- Path analysis and suggestions- And 2 more system utilities...
Context Window Management
Houtini LM implements intelligent context window management to maximize the efficiency of your local LM models while ensuring reliable processing of large files and complex analysis tasks.
Dynamic Context Allocation
Adaptive Context Utilization: Unlike systems with hardcoded token limits, Houtini LM dynamically detects your model's context window and allocates 95% of available tokens for optimal performance:
// Context detection from your loaded model
const contextLength = await model.getContextLength(); // e.g., 16,384 tokens
// Dynamic allocation - 95% utilization
const responseTokens = Math.floor(contextLength * 0.95); // 15,565 tokens available
Benefits:
- ✅ Maximum efficiency - No wasted context space
- ✅ Model-agnostic - Works with any context size (4K, 16K, 32K+)
- ✅ Future-proof - Automatically adapts to larger models
Three-Stage Prompt System
Houtini LM uses a sophisticated prompt architecture that separates concerns for optimal token management:
Stage 1: System Context - Expert persona and analysis methodology
Stage 2: Data Payload - Your code, files, or project content
Stage 3: Output Instructions - Structured response requirements
┌─────────────────────┐
│ System Context │ ← Expert role, methodologies
├─────────────────────┤
│ Data Payload │ ← Your files/code (chunked if needed)
├─────────────────────┤
│ Output Instructions │ ← Response format, requirements
└─────────────────────┘
Intelligent Processing:
- Small files → Single-stage execution for speed
- Large files → Automatic chunking with coherent aggregation
- Multi-file projects → Optimized batch processing
Automatic Chunking Capability
When files exceed available context space, Houtini LM automatically chunks content while maintaining analysis quality:
Smart Chunking Features:
- 🔍 Natural boundaries - Splits at logical sections, not arbitrary points
- 🔄 Context preservation - Maintains analysis continuity across chunks
- 📊 Intelligent aggregation - Combines chunk results into coherent reports
- ⚡ Performance optimization - Parallel processing where possible
Example Chunking Process:
Large File (50KB) → Context Analysis → Exceeds Limit
↓
Split into 3 logical chunks → Process each chunk → Aggregate results
↓
Single comprehensive analysis report
Timeout Configuration
Houtini LM uses 120-second timeouts (2 minutes) to accommodate thorough analysis on lower-powered systems:
Why Extended Timeouts:
- 🔍 Complex analysis - Security audits, architecture analysis, and comprehensive code reviews take time
- 💻 System compatibility - Works reliably on older hardware and resource-constrained environments
- 🧠 Model processing - Larger local models (13B-33B parameters) require more inference time
- 📊 Quality over speed - Comprehensive reports are worth the wait
Timeout Guidelines:
- Simple analysis (100 lines): 15-30 seconds
- Medium files (500 lines): 30-60 seconds
- Large files (1000+ lines): 60-120 seconds
- Multi-file projects: 90-180 seconds
Performance Tips:
- Use faster models (13B vs 33B) for quicker responses
- Enable GPU acceleration in LM Studio for better performance
- Consider using
analysisDepth="basic"for faster results when appropriate
Memory Efficiency
Intelligent Caching: Results are cached to prevent redundant processing
Resource Management: Automatic cleanup of large contexts after processing
Streaming Responses: Progressive output delivery for better user experience
This architecture ensures Houtini LM can handle everything from small utility functions to entire enterprise codebases while maintaining consistent quality and performance across different hardware configurations.
Documentation
Complete guides available:
- Analysis Functions Guide - All 17 analysis tools
- Generation Functions Guide - All 10 creation tools
- Creative Functions Guide - Games and art tools
- System Functions Guide - Utilities and diagnostics
- Complete User Guide - Comprehensive usage manual
Recommended Setup
For Professional Development:
- CPU: 8-core or better (for local LLM processing)
- RAM: 32GB (24GB for model, 8GB for development)
- Storage: SSD with 100GB+ free space
- Model: Qwen2.5-Coder-14B-Instruct or similar
Performance Tips:
- Use 13B+ parameter models for professional-quality results
- Configure
LLM_MCP_ALLOWED_DIRSto include your project directories - Install Desktop Commander MCP for complete file operation support
- Keep LM Studio running and model loaded for instant responses
Version History
Version 1.0.0 (Current)
- ✅ Complete function library (35+ functions)
- ✅ Professional documentation system
- ✅ WordPress-specific tools and auditing
- ✅ Creative project generators
- ✅ Comprehensive security analysis
- ✅ TypeScript conversion and test generation
- ✅ Cross-file integration analysis
License
MIT License - Use this project freely for personal and commercial projects. See LICENSE for details.
Contributing
We welcome contributions! Please see our Contributing Guidelines for details on:
- Code standards and patterns
- Testing requirements
- Documentation updates
- Issue reporting
Support
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Documentation: Complete guides in the
docs/directory
Ready to supercharge your development workflow? Install Houtini LM and start building amazing things with unlimited local AI assistance.
Built for developers who think clearly but can't afford to think expensively.
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.