Skip to main content
Glama

Fusion 360 MCP

by jaskirat1616
STRUCTURE.txtβ€’9.29 kB
FUSION360-MCP PROJECT STRUCTURE ================================ fusion360-mcp/ β”‚ β”œβ”€β”€ πŸ“„ Core Documentation β”‚ β”œβ”€β”€ README.md # Complete user guide (500+ lines) β”‚ β”œβ”€β”€ QUICKSTART.md # 5-minute setup guide β”‚ β”œβ”€β”€ SETUP_OLLAMA.md # Detailed Ollama setup (NEW!) β”‚ β”œβ”€β”€ ARCHITECTURE.md # Technical documentation β”‚ β”œβ”€β”€ PROJECT_SUMMARY.md # Project completion summary β”‚ └── LICENSE # MIT License β”‚ β”œβ”€β”€ πŸ”§ Configuration Files β”‚ β”œβ”€β”€ config.json # Main config (create from example) β”‚ β”œβ”€β”€ .env.example # Environment variables template β”‚ β”œβ”€β”€ requirements.txt # Python dependencies β”‚ β”œβ”€β”€ setup.py # Package installation β”‚ └── .gitignore # Git exclusions β”‚ β”œβ”€β”€ πŸš€ Quick Start Scripts β”‚ β”œβ”€β”€ start_server.sh # Start server (macOS/Linux) β”‚ β”œβ”€β”€ start_server.bat # Start server (Windows) β”‚ └── run_tests.sh # Run test suite β”‚ β”œβ”€β”€ πŸ–₯️ MCP Server (Core Backend) β”‚ β”œβ”€β”€ mcp_server/ β”‚ β”‚ β”œβ”€β”€ __init__.py β”‚ β”‚ β”œβ”€β”€ server.py # FastAPI application β”‚ β”‚ β”œβ”€β”€ router.py # Request routing logic β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ schema/ # Pydantic Data Models β”‚ β”‚ β”‚ β”œβ”€β”€ __init__.py β”‚ β”‚ β”‚ β”œβ”€β”€ mcp_command.py # Input command schemas β”‚ β”‚ β”‚ β”œβ”€β”€ fusion_action.py # CAD action schemas β”‚ β”‚ β”‚ └── llm_response.py # LLM response schemas β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ llm_clients/ # LLM Implementations β”‚ β”‚ β”‚ β”œβ”€β”€ __init__.py β”‚ β”‚ β”‚ β”œβ”€β”€ ollama_client.py # Local Ollama (REST/CLI) β”‚ β”‚ β”‚ β”œβ”€β”€ openai_client.py # OpenAI GPT-4o β”‚ β”‚ β”‚ β”œβ”€β”€ gemini_client.py # Google Gemini β”‚ β”‚ β”‚ └── claude_client.py # Anthropic Claude β”‚ β”‚ β”‚ β”‚ β”‚ └── utils/ # Utilities β”‚ β”‚ β”œβ”€β”€ __init__.py β”‚ β”‚ β”œβ”€β”€ logger.py # Loguru logging β”‚ β”‚ β”œβ”€β”€ config_loader.py # Config management β”‚ β”‚ └── context_cache.py # Conversation cache β”‚ β”‚ β”‚ └── API Endpoints: β”‚ POST /mcp/command # Execute MCP command β”‚ POST /mcp/execute # Log action execution β”‚ GET /health # Health check β”‚ GET /models # List available models β”‚ GET /history # Conversation history β”‚ β”œβ”€β”€ 🎨 Fusion 360 Add-in β”‚ └── fusion_addin/ β”‚ β”œβ”€β”€ FusionMCP.manifest # Add-in metadata β”‚ β”œβ”€β”€ main.py # Entry point β”‚ β”œβ”€β”€ ui_dialog.py # User interface β”‚ β”œβ”€β”€ fusion_actions.py # Action executor β”‚ └── utils/ β”‚ └── network.py # MCP client β”‚ β”‚ Supported Actions: β”‚ β€’ create_box # Rectangular boxes β”‚ β€’ create_cylinder # Cylinders β”‚ β€’ create_sphere # Spheres (revolve) β”‚ β€’ create_hole # Holes (cut operation) β”‚ β€’ extrude # Profile extrusion β”‚ β€’ fillet # Edge rounding β”‚ β€’ apply_material # Material assignment β”‚ β”œβ”€β”€ 🧠 System Prompt β”‚ └── prompts/ β”‚ └── system_prompt.md # FusionMCP personality β”‚ β”‚ Defines: β”‚ β€’ Core principles (JSON output, safety) β”‚ β€’ Action schemas and templates β”‚ β€’ Clarification protocols β”‚ β€’ Example interactions β”‚ β€’ Multi-model orchestration β”‚ β”œβ”€β”€ πŸ“š Examples β”‚ └── examples/ β”‚ β”œβ”€β”€ example_config.json # Full configuration β”‚ β”œβ”€β”€ example_command.json # Sample MCP command β”‚ β”œβ”€β”€ example_design_context.json # Design state example β”‚ └── test_conversation.json # Test scenarios β”‚ └── πŸ§ͺ Test Suite └── tests/ β”œβ”€β”€ __init__.py β”œβ”€β”€ pytest.ini # Test configuration β”œβ”€β”€ test_mcp_server.py # Server endpoint tests β”œβ”€β”€ test_ollama_client.py # Ollama client tests β”œβ”€β”€ test_schemas.py # Schema validation tests β”œβ”€β”€ test_config_loader.py # Config loader tests └── test_context_cache.py # Cache operation tests INSTALLATION LOCATIONS ====================== Python Server: ~/Desktop/fusion360-mcp/ # Project directory ~/Desktop/fusion360-mcp/venv/ # Virtual environment ~/Desktop/fusion360-mcp/logs/ # Server logs ~/Desktop/fusion360-mcp/context_cache.json # Conversation history Fusion 360 Add-in: macOS: ~/Library/Application Support/Autodesk/Autodesk Fusion 360/API/AddIns/FusionMCP/ Windows: %APPDATA%\Autodesk\Autodesk Fusion 360\API\AddIns\FusionMCP\ DATA FLOW ========= 1. User Input (Fusion 360) └─> Fusion Add-in (ui_dialog.py) └─> Network Client (utils/network.py) └─> HTTP POST to http://localhost:9000/mcp/command 2. MCP Server Processing └─> FastAPI Server (server.py) └─> Router (router.py) └─> LLM Client Selection (ollama/openai/gemini/claude) └─> LLM API Call with System Prompt └─> Response Parsing & Validation 3. Response Generation └─> Structured JSON Action (FusionAction schema) └─> Safety Validation (dimensions, units, feasibility) └─> MCPResponse (with actions_to_execute) └─> HTTP Response to Fusion Add-in 4. CAD Execution └─> Fusion Add-in receives response └─> Action Executor (fusion_actions.py) └─> Fusion 360 API calls └─> Geometry Creation └─> User Feedback SUPPORTED LLM PROVIDERS ======================== 1. Ollama (Local) βœ… Free and offline βœ… Privacy-first (data stays local) βœ… Models: llama3, mistral, codellama, phi βœ… No API key required βš™οΈ Requires: ollama serve 2. OpenAI βœ… GPT-4o, GPT-4o-mini, GPT-4-turbo βœ… Native JSON mode βœ… Best for creative designs βš™οΈ Requires: API key ($$) 3. Google Gemini βœ… Gemini 1.5 Pro, Gemini 1.5 Flash βœ… Excellent geometric reasoning βœ… Cost-effective βš™οΈ Requires: API key ($) 4. Anthropic Claude βœ… Claude 3.5 Sonnet, Claude 3 Opus βœ… Superior reasoning and safety βœ… Long context window βš™οΈ Requires: API key ($$$) QUICK START COMMANDS ===================== 1. Install Ollama: macOS: brew install ollama Linux: curl -fsSL https://ollama.com/install.sh | sh Windows: Download from https://ollama.com 2. Pull Model: ollama pull llama3 3. Start Ollama: ollama serve 4. Setup Python: cd ~/Desktop/fusion360-mcp python3 -m venv venv source venv/bin/activate pip install -r requirements.txt 5. Configure: cp examples/example_config.json config.json # Edit config.json - set "default_model": "ollama:llama3" 6. Start MCP Server: ./start_server.sh # or: python -m mcp_server.server 7. Install Fusion Add-in: cp -r fusion_addin ~/Library/Application\ Support/Autodesk/Autodesk\ Fusion\ 360/API/AddIns/FusionMCP 8. Use in Fusion 360: - Open Fusion 360 - Tools β†’ Add-Ins β†’ FusionMCP β†’ Run - Click "MCP Assistant" - Try: "Create a 20mm cube" FILE STATISTICS =============== Total Files: 46+ Python Files: 22 Documentation: 6 Configuration: 6 Examples: 4 Tests: 6 Scripts: 3 Lines of Code: ~3,000+ (Python) Lines of Docs: ~2,500+ (Markdown) Total Size: ~250KB (code only) KEY FEATURES ============ βœ… Multi-Model Support (4 providers) βœ… Intelligent Fallback Chain βœ… Type-Safe (Pydantic schemas) βœ… Async Architecture (FastAPI) βœ… Context Caching (JSON/SQLite) βœ… Structured Logging (Loguru) βœ… Safety Validation (dimensions, units) βœ… Natural Language Interface βœ… Parametric Design Support βœ… Real-time Execution βœ… Comprehensive Testing βœ… Full Documentation RUNTIME REQUIREMENTS ==================== Python: 3.11+ Fusion 360: 2025 (recommended) Ollama: Latest (for local models) RAM: 4GB minimum (8GB recommended) Disk: ~5GB (with Ollama models) Internet: Optional (only for cloud models) NEXT STEPS ========== 1. βœ… Follow SETUP_OLLAMA.md for detailed setup 2. βœ… Read QUICKSTART.md for 5-minute guide 3. βœ… Check README.md for complete documentation 4. βœ… Try example commands in Fusion 360 5. βœ… Explore examples/ folder for workflows 6. βœ… Run tests: ./run_tests.sh 7. βœ… Star on GitHub and contribute! SUPPORT ======= Documentation: README.md, QUICKSTART.md, SETUP_OLLAMA.md Architecture: ARCHITECTURE.md Issues: GitHub Issues Discussions: GitHub Discussions PROJECT STATUS: βœ… COMPLETE & READY TO USE Version: 1.0.0 License: MIT Built: January 2025

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/jaskirat1616/fusion360-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server