@@ -16,18 +16,23 @@ Automatically generate an award-level modeling paper
1616
1717<p align =" center " >
1818 <img src="./docs/index.png">
19+ <img src="./docs/chat.png">
1920 <img src="./docs/coder.png">
2021 <img src="./docs/writer.png">
2122</p >
2223
2324## ✨ Features
2425
2526- 🔍 Automatic problem analysis, mathematical modeling, code writing, error correction, and paper writing
26- - 💻 Local code interpreter
27+ - 💻 Code Interpreter
28+ - Local Interpreter: Based on Jupyter, code saved as notebook for easy editing
29+ - Cloud Code Interpreter: [ E2B] ( https://e2b.dev/ ) and [ daytona] ( https://app.daytona.io/ )
2730- 📝 Generate a well-formatted paper
28- - 🤝 Multi-agents: ~~ modeling expert~~ , coding expert (reflection module, local code interpreter), paper expert
31+ - 🤝 Multi-agents: modeling expert, coding expert, paper expert, etc.
2932- 🔄 Multi-LLMs: Different models for each agent
30- - 💰 Low cost agentless (about 1 RMB per task)
33+ - 🤖 Support for all models: [ litellm] ( https://docs.litellm.ai/docs/providers )
34+ - 💰 Low cost: workflow agentless, no dependency on agent framework
35+ - 🧩 Custom templates: prompt inject for setting requirements for each subtask separately
3136
3237## 🚀 Future Plans
3338
@@ -37,52 +42,78 @@ Automatically generate an award-level modeling paper
3742- [ ] English support (MCM/ICM)
3843- [ ] LaTeX template integration
3944- [ ] Vision model integration
40- - [ ] Proper citation implementation
41- - [ ] More test cases
42- - [ ] Docker deployment
43- - [ ] User interaction (model selection, rewriting, etc.)
44- - [ ] Cloud integration for code interpreter (e.g., e2b providers)
45+ - [x] Proper citation implementation
46+ - [x] More test cases
47+ - [x] Docker deployment
48+ - [ ] Human in loop: User interaction (model selection, @agent rewriting, etc.)
49+ - [ ] Feedback: evaluate the result and modify
50+ - [x] Cloud integration for code interpreter (e.g., e2b providers)
4551- [ ] Multi-language: R, Matlab
46- - [ ] Drawing: napki, draw.io
52+ - [ ] Drawing: napki, draw.io, plantuml, svg, mermaid.js
53+ - [ ] Add benchmark
54+ - [ ] Web search tool
55+ - [ ] RAG knowledge base
56+ - [ ] A2A hand off: Code expert reflects on errors multiple times, hands off to smarter model agent
4757
4858## Video Demo
4959
50- <video src =" https://github.com/user-attachments/assets/10b3145a-feb7-4894-aaca-30d44bb35b9e " ></video >
60+ <video src =" https://github.com/user-attachments/assets/954cb607-8e7e-45c6-8b15-f85e204a0c5d " ></video >
61+
62+ > [ !CAUTION]
63+ > 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.
64+ > Contributions are welcome.
65+
66+ For case references, check the [ demo] ( ./demo/ ) folder.
67+ ** If you have good cases, please submit a PR to this directory**
5168
5269## 📖 Usage Guide
5370
54- > ** Notice:** Please make sure Python, Nodejs, and ** Redis** are installed on your computer.
55- >
71+ Three deployment options are available, choose the one that suits you best:
72+ 1 . Docker
73+ 2 . Local deployment
74+ 3 . Automated script deployment
75+
5676> If you want to run the CLI version, switch to the [ master] ( https://github.com/jihe520/MathModelAgent/tree/master ) branch. It's easier to deploy, but will not be updated in the future.
5777
58- 1 . Configure Model
78+ ### 🐳 Option 1: Docker Deployment (Recommended: Simplest)
5979
60- Copy ` /backend/.env.dev.example ` to ` /backend/.env.dev ` (remove the ` .example ` suffix), and fill in the model configuration and APIKEY
61- [ Deepseek Developer Platform] ( https://platform.deepseek.com/ )
80+ 1 . Configure Environment Variables
6281
6382``` bash
64- ENV=dev
65- # Compatible with OpenAI format, refer to official docs
66- DEEPSEEK_API_KEY=
67- DEEPSEEK_MODEL=
68- DEEPSEEK_BASE_URL=
69- # Max Q&A turns
70- MAX_CHAT_TURNS=60
71- # Reflection retries
72- MAX_RETRIES=5
73- # https://e2b.dev/
74- E2B_API_KEY=
75-
76- LOG_LEVEL=DEBUG
77- DEBUG=true
78- # Make sure Redis is installed
79- REDIS_URL=redis://localhost:6379/0
80- REDIS_MAX_CONNECTIONS=20
81- CORS_ALLOW_ORIGINS=http://localhost:5173,http://localhost:3000
83+ cp backend/.env.dev.example backend/.env.dev
84+ cp frontend/.env.example frontend/.env.development
8285```
8386
87+ Fill in the configuration in:
88+ - backend/.env.dev
89+ - frontend/.env.development
90+
91+ 2 . Start Services
92+
93+ ``` bash
94+ docker-compose up -d
95+ ```
96+
97+ 3 . Access
98+
99+ You can now access:
100+ - Frontend interface: http://localhost:5173
101+ - Backend API: http://localhost:8000
102+
103+ ### 💻 Option 2: Local Deployment
104+
105+ > Make sure Python, Nodejs, and ** Redis** are installed on your computer
106+
107+ 1 . Configure Environment Variables
108+
109+ Copy ` /backend/.env.dev.example ` to ` /backend/.env.dev ` (remove the ` .example ` suffix)
110+
111+ ** Configure Environment Variables**
112+
84113It is recommended to use models with strong capabilities and large parameter counts.
85114
115+ Copy ` /frontend/.env.example ` to ` /frontend/.env.development ` (remove the ` .example ` suffix)
116+
861172 . Install Dependencies
87118
88119Clone the project
@@ -93,31 +124,48 @@ git clone https://github.com/jihe520/MathModelAgent.git
93124
94125Start backend
95126
127+ * Start Redis*
128+
96129``` bash
97130cd backend
98131pip install uv # Recommended: use uv to manage python projects
99132uv sync # Install dependencies
100133# Start backend
101- ENV=DEV uvicorn app.main:app --host 0.0.0.0 --port 8000 --ws-ping-interval 60 --ws-ping-timeout 120
134+ # Activate Python virtual environment
135+ source .venv/bin/activate # MacOS or Linux
136+ venv\S cripts\a ctivate.bat # Windows
137+ # Run this command for MacOS or Linux
138+ ENV=DEV uvicorn app.main:app --host 0.0.0.0 --port 8000 --ws-ping-interval 60 --ws-ping-timeout 120 --reload
139+ # Run this command for Windows
140+ set ENV=DEV ; uvicorn app.main:app --host 0.0.0.0 --port 8000 --ws-ping-interval 60 --ws-ping-timeout 120
102141```
103142
104143Start frontend
105144
106145``` bash
107146cd frontend
147+ npm install -g pnpm
108148pnpm i # Make sure pnpm is installed
109149pnpm run dev
110150```
111151
152+ [ Tutorial] ( ./docs/md/tutorial.md )
153+
112154Results and outputs are generated in the ` backend/project/work_dir/xxx/* ` directory:
113155- notebook.ipynb: code generated during execution
114- - res.md: final results in markdown format, can be converted to Word (try pandoc)
156+ - res.md: final results in markdown format
157+
158+ ### 🚀 Option 3: Automated Script Deployment (Community Contribution)
159+ Need an automatic deployment script?
160+ [ mmaAutoSetupRun] ( https://github.com/Fitia-UCAS/mmaAutoSetupRun )
161+
162+ Need to customize prompt templates?
163+ Prompt Inject: [ prompt] ( ./backend/app/config/md_template.toml )
115164
116165## 🤝 Contribution & Development
117166
118167[ DeepWiki] ( https://deepwiki.com/jihe520/MathModelAgent )
119168
120-
121169- The project is in ** experimental development stage** (updated when I have time), with frequent changes and some bugs being fixed.
122170- Everyone is welcome to participate and make the project better.
123171- PRs and issues are very welcome.
@@ -131,6 +179,8 @@ After cloning the project, install the **Todo Tree** plugin to view all todo loc
131179
132180Free for personal use. For commercial use, please contact me (the author).
133181
182+ [ License] ( ./docs/md/License.md )
183+
134184## 🙏 Reference
135185
136186Thanks to the following projects:
@@ -142,10 +192,19 @@ Thanks to the following projects:
142192
143193## Others
144194
145- Thanks to sponsors
195+ ### 💖 Sponsor
196+
197+ [ Buy Me a Coffee] ( ./docs/sponser.md )
198+
199+ Thanks to sponsors:
146200[ danmo-tyc] ( https://github.com/danmo-tyc )
147201
148- For questions, join the group
202+ ### 👥 GROUP
203+
204+ For questions, join the group
205+
149206[ QQ Group: 699970403] ( http://qm.qq.com/cgi-bin/qm/qr?_wv=1027&k=rFKquDTSxKcWpEhRgpJD-dPhTtqLwJ9r&authKey=xYKvCFG5My4uYZTbIIoV5MIPQedW7hYzf0%2Fbs4EUZ100UegQWcQ8xEEgTczHsyU6&noverify=0&group_code=699970403 )
150207
151- <img src =" ./docs/qq.jpg " height =" 400px " >
208+ <div align =" center " >
209+ <img src="./docs/qq.jpg" height="400px">
210+ </div >
0 commit comments