An agent designed for mathematical modeling
Automatically complete mathematical modeling and generate a ready-to-submit paper.
简体中文 | English
⬇️ Download the latest desktop app (recommended)
🎨 Sister project: sci-box — scientific figure & diagram SKILLs
Don't want to set up an environment? Download the desktop app and start right away.
The desktop app bundles Claude Code and the full set of MathModelAgent SKILLS. No Python / Node.js / Redis installation and no manual SKILL setup — install it, add one model API key, and start modeling.
| OS | File |
|---|---|
| macOS (Apple Silicon) | mathmodel-<version>-arm64.dmg |
| macOS (Intel) | mathmodel-<version>-x64.dmg |
| Windows 64-bit | mathmodel-<version>-x64.exe |
The macOS installers are signed with a Developer ID and notarized by Apple.
Warning
The Windows installer is not code-signed yet. Microsoft Defender SmartScreen may warn on first install or launch — choose "More info" → "Run anyway", and only download from the official Releases page.
The app checks for updates automatically (auto-update is live on macOS; Windows will be enabled once a code-signing certificate is in place).
If you'd rather deploy it yourself or contribute, keep reading below.
Turn 3 days of competition into 1 hour
Automatically generate an award-level modeling paper
- 🔍 Automatic problem analysis, mathematical modeling, code writing, error correction, and paper writing
- 💻 Code Interpreter
- 📝 Generate a well-formatted paper
- 🤝 Multi-agents: modeling expert, coding expert, paper expert, etc.
- 🔄 Multi-LLMs: Different models for each agent
- 🤖 Support for all models: litellm
- 💰 Low cost: workflow agentless, no dependency on agent framework
- 🧩 Custom templates: prompt inject for setting requirements for each subtask separately
The scientific plotting and diagram templates now live in their own repository, jihe520/sci-box, and can be installed and used on their own:
| SKILL | Contents |
|---|---|
scibox-figure |
Ready-to-run replication templates for SHAP, ROC, Taylor, raincloud, chord and circular heatmap plots (Python + Matplotlib, exports PNG / PDF / SVG) |
scibox-diagram |
Editable draw.io templates: five-tier technical roadmap, three-column research framework, three-column process flow, horizontal task pipeline |
npx skills add jihe520/sci-box
- Add and complete webui, cli
- Comprehensive tutorials and documentation
- Provide web service
- English support (MCM/ICM)
- LaTeX template integration
- Vision model integration
- Proper citation implementation
- More test cases
- Docker deployment
- Human in loop: User interaction (model selection, @agent rewriting, etc.)
- Feedback: evaluate the result and modify
- Cloud integration for code interpreter (e.g., e2b providers)
- Multi-language: R, Matlab
- Drawing: napki, draw.io, plantuml, svg, mermaid.js
- Add benchmark
- Web search tool
- RAG knowledge base
- A2A hand off: Code expert reflects on errors multiple times, hands off to smarter model agent
mathmodelagent.mp4
Caution
The project is in experimental development stage, with many areas needing improvement and optimization. I (the project author) am busy but will update when time permits. Contributions are welcome.
For case references, check the demo folder. If you have good cases, please submit a PR to this directory
Three deployment options are available, choose the one that suits you best:
- Docker
- Local deployment
- Automated script deployment
If you want to run the CLI version, switch to the master branch. It's easier to deploy, but will not be updated in the future.
- Configure Environment Variables
cp backend/.env.dev.example backend/.env.dev
cp frontend/.env.example frontend/.env.developmentFill in the configuration in:
- backend/.env.dev
- frontend/.env.development
- Start Services
docker-compose up -d- Access
You can now access:
- Frontend interface: http://localhost:5173
- Backend API: http://localhost:8000
Make sure Python, Nodejs, and Redis are installed on your computer
- Configure Environment Variables
Copy /backend/.env.dev.example to /backend/.env.dev (remove the .example suffix)
Configure Environment Variables
It is recommended to use models with strong capabilities and large parameter counts.
Copy /frontend/.env.example to /frontend/.env.development (remove the .example suffix)
- Install Dependencies
Clone the project
git clone https://github.com/jihe520/MathModelAgent.gitStart backend
Start Redis
cd backend
pip install uv # Recommended: use uv to manage python projects
uv sync # Install dependencies
# Start backend
# Activate Python virtual environment
source .venv/bin/activate # MacOS or Linux
venv\Scripts\activate.bat # Windows
# Run this command for MacOS or Linux
ENV=DEV uvicorn app.main:app --host 0.0.0.0 --port 8000 --ws-ping-interval 60 --ws-ping-timeout 120 --reload
# Run this command for Windows
set ENV=DEV ; uvicorn app.main:app --host 0.0.0.0 --port 8000 --ws-ping-interval 60 --ws-ping-timeout 120Start frontend
cd frontend
npm install -g pnpm
pnpm i # Make sure pnpm is installed
pnpm run devResults and outputs are generated in the backend/project/work_dir/xxx/* directory:
- notebook.ipynb: code generated during execution
- res.md: final results in markdown format
Need an automatic deployment script? mmaAutoSetupRun
Need to customize prompt templates? Prompt Inject: prompt
- The project is in experimental development stage (updated when I have time), with frequent changes and some bugs being fixed.
- Everyone is welcome to participate and make the project better.
- PRs and issues are very welcome.
- For requirements, refer to Future Plans.
After cloning the project, install the Todo Tree plugin to view all todo locations in the code.
.cursor/* contains overall architecture, rules, and mcp for easier development.
Free for personal use. For commercial use, please contact me (the author).
Thanks to the following projects:
Thanks to sponsors: danmo-tyc
For questions, join the group





