Flame MCP Server
OfficialThis server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
Flame MCP Server
MCP (Model Context Protocol) server for the Flame QSAR predictive modeling framework. Enables LLM agents to programmatically build, manage, and use QSAR models through a standardized tool interface.
Architecture
┌───────────┐ ┌──────────────┐ ┌──────────────────┐ ┌──────────────┐
│ LLM Agent │────▶│ MCP Client │────▶│ flame-mcp │────▶│ Flame API │
│ │ │ (WebSocket) │ │ (MCP Server) │ │ (Django REST)│
└───────────┘ └──────────────┘ └──────────────────┘ └──────────────┘
Port 8004 Port 8000The server acts as a thin MCP proxy to a running Flame REST API instance. It receives MCP JSON-RPC requests over WebSocket (or HTTP POST) and translates them into HTTP calls to the Flame API.
Related MCP server: tooluniverse
Prerequisites
Conda/Mamba — Miniforge3 recommended
Git — to clone the Flame repositories
Flame repositories (same parent directory):
Installation
1. Install Conda/Mamba (if not already installed)
curl -L -o /tmp/miniforge.sh \
https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-Linux-x86_64.sh
bash /tmp/miniforge.sh -b -p $HOME/miniforge3
export PATH="$HOME/miniforge3/bin:$PATH"2. Create the Flame conda environment
mamba create -n flame -y -c conda-forge python=3.10 \
rdkit scikit-learn pandas numpy matplotlib \
django=3.2 djangorestframework=3.14 django-cors-headers=3.14 \
xgboost lightgbm imbalanced-learn3. Install the Flame platform and dependencies
# Activate the environment
mamba activate flame
# Install flame core (from the sibling flame/ directory)
pip install -e ../flame/
# Install additional Flame dependencies
pip install psycopg2-binary djangorestframework-yaml \
standardiser@https://github.com/phi-grib/standardiser/archive/master.zip \
nonconformist@https://github.com/josecarlosgomezt/nonconformist/archive/master.zip
# Configure the Flame repository path
flame -c config -d $HOME/flame_repo4. Start the Flame API (Django) server
The Flame API must be running before starting the MCP server.
mamba activate flame
cd ../flame_API/flame_api
# First-time setup: run migrations
python manage.py migrate
# Start on port 8001 (or any free port)
python manage.py runserver 127.0.0.1:8001Note: The default port
8000may conflict with other MCP servers (e.g., CompTox). Use a different port and configureFLAME_MCP_FLAME_API_BASE_URLaccordingly.
5. Start the Flame MCP server
# Option A: Using the start script
cp .env.example .env
# Edit .env — set FLAME_MCP_FLAME_API_BASE_URL=http://127.0.0.1:8001/api/v1
./start_mcp.sh
# Option B: Manual start
python3 -m venv .venv
source .venv/bin/activate
pip install -e .
FLAME_MCP_FLAME_API_BASE_URL=http://127.0.0.1:8001/api/v1 \
uvicorn flame_mcp.transport.websocket:app --host 127.0.0.1 --port 80046. Verify the full stack
# MCP server liveness
curl http://127.0.0.1:8004/healthz
# {"status":"ok","service":"flame-mcp"}
# End-to-end readiness (checks Flame API connectivity)
curl http://127.0.0.1:8004/readyz
# {"status":"ready","flame_api":"reachable","detail":"I am alive"}Available Tools (63)
Model Management (20 tools)
Tool | Description |
| List all models in the repository |
| Get model summary information |
| Create a new model endpoint |
| Remove a model entirely |
| Publish dev version as a new numbered version |
| Get info about a specific model version |
| Delete a specific version |
| Get modeling parameters (algorithm, descriptors) |
| Get OECD-QMRF documentation |
| Update documentation fields |
| Update model labels/annotations |
| Get quality/validation metrics |
| Download training series SDF |
| Start model export (.tgz) |
| Check if export completed |
| Rebuild all versions |
| Check refresh status |
| Check build operation status |
| Convert parameters to YAML |
| Apply YAML delta to parameters |
Prediction (6 tools)
Tool | Description |
| Predict properties for a SMILES |
| Predict for multiple SMILES |
| Predict using SDFile |
| List stored predictions |
| Get prediction results (poll) |
| Delete a prediction |
Profiling (7 tools)
Tool | Description |
| Run multiple models on a SMILES |
| Profile multiple compounds |
| Profile using SDFile |
| List stored profiles |
| Get profile result for a model |
| Get heatmap summary |
| Delete a profile |
Chemical Space (9 tools)
Tool | Description |
| List chemical spaces |
| Get space information |
| Create a new space |
| Delete a space |
| Publish a space version |
| Get space version info |
| Delete a space version |
| Get space parameters |
| Build a space from compounds |
Search (5 tools)
Tool | Description |
| Search by SMILES similarity |
| Search by SMARTS substructure |
| Search using SDFile |
| Get search results (poll) |
| Get results for ToxHub |
Build (1 tool)
Tool | Description |
| Train a model from SDFile |
Collections (3 tools)
Tool | Description |
| List endpoint collections |
| Create/update a collection |
| Delete a collection |
Baskets (3 tools)
Tool | Description |
| List compound baskets |
| Get a basket item |
| Create/update a basket item |
Verification (5 tools)
Tool | Description |
| Get verification info |
| Create verification entry |
| Delete verification |
| Generate a report |
| Sign a report |
Configuration (2 tools)
Tool | Description |
| Get Flame config |
| Set repository path |
Health (2 tools)
Tool | Description |
| Check Flame API liveness |
| Check Flame API readiness |
Configuration
Configuration is via environment variables or .env file. See .env.example for all options.
Key settings:
FLAME_MCP_FLAME_API_BASE_URL— Flame API URL (default:http://127.0.0.1:8000/api/v1)FLAME_MCP_MCP_PORT— MCP server port (default:8004)FLAME_MCP_ALLOWED_ORIGINS/FLAME_MCP_ALLOWED_HOSTS— extra browser origins /Hostvalues to accept (JSON arrays; loopback is always accepted)
Security
The server has no authentication and proxies to a Flame API that can delete and overwrite models. Run it on 127.0.0.1 only (the default), or behind an authenticating reverse proxy.
Requests carrying a browser
Originheader are rejected (HTTP 403) unless the origin is a loopback address or listed inFLAME_MCP_ALLOWED_ORIGINS; theHostheader is checked against loopback names plusFLAME_MCP_ALLOWED_HOSTS. This prevents web pages and DNS-rebinding attacks from driving the server through the user's browser. No wildcard CORS policy is set.Model, space, prediction, profile, collection and other object names are validated (
[A-Za-z0-9][A-Za-z0-9_.-]{0,127}, no..) and percent-encoded before being placed in Flame API paths, so a crafted name cannot reach a different endpoint.Tools carry MCP
readOnlyHint/destructiveHintannotations so clients can ask for confirmation before deleting, rebuilding or overwriting.
Endpoints
Endpoint | Protocol | Description |
| HTTP POST | MCP JSON-RPC over HTTP (one JSON response per request) |
| HTTP GET | Discovery probe (server info, protocol versions) |
| WebSocket | MCP JSON-RPC over WebSocket |
| HTTP GET | Liveness probe |
| HTTP GET | Readiness probe (checks the Flame API) |
IDE Integration
Add to your Agent's MCP configuration file:
HTTP (e.g. config.yaml):
mcp_servers:
flame:
url: http://127.0.0.1:8004/mcp
timeout: 900WebSocket clients:
{
"flame": {
"url": "ws://127.0.0.1:8004/mcp/ws"
}
}Once configured, the client can use all 63 Flame tools. Example end-to-end workflow:
1. create_model("my_model") → Create a new endpoint
2. build_model("my_model", sdf) → Train with an SDF file
3. predict_smiles("my_model", 0, smi) → Predict a SMILES
4. get_prediction_result(pred_id) → Retrieve resultsAgent skills
The reusable workflows live in skills/. They are separate from the MCP server implementation and can be used by an agent only when installed/discovered; an MCP connection alone does not install them.
Skill | Scope |
Inventory, documentation, validation and model suitability (read-only) | |
Version-pinned predictions, result retrieval and interpretation | |
Curated training and development-version validation (writes require authorization) | |
Approved publication, read-back and archive verification (writes require authorization) | |
Similarity and profiling for exploration, not a safety conclusion |
The Agent can load them from this checkout without copying by adding the absolute path to this repository's skills/ directory to its skills.external_dirs setting. Installed local skills of the same name take precedence. The safer-chemical-substitution skill remains a separate assessment workflow: it may use flame-prediction for a defensible evidence gap if installed, but predictions are not required and never override measured or regulatory evidence.
Development
# Install with dev dependencies
python3 -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"
# Run tests
pytest tests/ -v
# Start in development mode
uvicorn flame_mcp.transport.websocket:app --host 127.0.0.1 --port 8004 --reloadTroubleshooting
Problem | Solution |
| Flame API (Django) is not running or wrong URL configured |
| Install: |
| Install: |
Port conflict on 8000 | Use a different port for Django and set |
Build fails silently | Check Django server terminal output for Python tracebacks |
Session not found (IDE) | Restart the MCP server — WebSocket session expired |
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
AI-callable tools for API mocking, testing, monitoring, security, and automation.
Discover, inspect and run 63,000+ agent tools from one balance. Pay per call, no subscriptions.
Chemistry, pharma and biotech tools for AI assistants: NMR, MS, IR and UV analysis, ADMET and ICH M7, stability (ICH Q1), HPLC methods, DoE, docking, retrosynthesis, biologics. Deterministic results you can check. Built in Leipzig, Germany.
Access Pollinations models and API capabilities through agent tools.
Related MCP Servers
- FlicenseBqualityDmaintenanceProvides computational chemistry tools for LLMs, enabling molecular operations like SMILES processing and geometry manipulation via a modular agent and tool system.9-
- AlicenseNot gradedqualityAmaintenanceEnables AI scientists to access over 1000 machine learning models, datasets, APIs, and scientific packages for data analysis, knowledge retrieval, and experimental design from any large language model.13,321 PyPI1,812Apache 2.0
- AlicenseCqualityFmaintenanceEnables LLM agents to draw and edit ChemDraw reaction schemes, parse ELN exports and LCMS/NMR data, and generate publication-ready CDXML files through grounded chemistry tools.353MIT
- AlicenseAqualityBmaintenanceEnables querying scientific entity data — compound records and properties, bioactivity and mechanisms, protein entries and ID mappings, PDB structures, and PubMed metadata — directly from official PubChem, ChEMBL, UniProt, RCSB PDB, and PubMed APIs through 12 tools. Requires no API keys, so agents can retrieve live chemical, protein, structural, and citation records without credentials or quotas.312,052 PyPIMIT