English · 简体中文
MathAgent is a multi-agent system built for the Intern-S1 mathematical agent design and reasoning challenge. It stores propositions, inferences, candidate routes, and verification evidence in a shared state. During long reasoning runs, this lets it trace invalidated premises, reuse conclusions that still hold, and choose its next action based on independent checks.
Launch Showcase Web · Three causality-inspired mechanisms · Architecture · Validation and documentation
Run these steps from the repository root. You need uv, Python 3.11 or 3.12, Node.js 24, and npm. The first dependency install requires internet access.
-
Set
INTERN_API_KEYin an untracked.envfile at the repository root. -
Run the launcher. It installs locked dependencies, builds the Vue frontend, and starts a local Flask server.
uv run --no-project python scripts/start_showcase.py web
-
Open 127.0.0.1:8090/dashboard and submit a problem such as
Solve x² − 1 = 0 and check the candidate roots.Submitting creates a Job and calls Intern.
Add --mode fake to try the interface without model credentials. Use --port <port> if the default port is in use. Press Ctrl+C to stop the service. Run data defaults to artifacts/showcase-live/ in live mode and artifacts/showcase-local/ in fake mode.
Workbench preview and Notebook launcher
This screenshot shows simulated data from a browser test. During a live run, the workbench displays public execution events, saved outputs from individual roles, and the final answer. The Showcase rehearsal record describes the demo and replay coverage.
uv run --no-project python scripts/start_showcase.py notebookJupyterLab opens a working copy of the example notebook on local port 8888. Select Run → Run All Cells to create a Job through the local Showcase HTTP API and read its execution events and answer. The Notebook launcher works without Node.js and supports --mode fake. Working copies and run data are stored in artifacts/showcase-notebook/.
MathAgent connects reasoning actions, state changes, and verifiable progress. Chapters 2–4 of the v0.6 technical report describe the design. The implementation contracts below specify the code paths, prerequisites, and validation scope.
| Mechanism | Technical design |
|---|---|
| Dependency tracing and local rollback | The proposition–inference graph records versions, provenance, and verification evidence. An inference requires all of its premises (AND). A proposition can remain valid with any independent valid support (OR). When the last valid support is withdrawn, invalidation propagates along the dependencies. A Checkpoint provides a state from which the run can resume. See the proof graph contract. |
| Verification-guided search | Population persists candidate routes and their lineage. Rater, Pareto ranking, and APRS schedule work based on verified progress, differences between routes, and known resource costs. Routes share a budget for model calls, tools, and time. The scheduler counts repeated results only once toward overall progress. See the serial APRS contract and concurrent scheduling contract. |
| Strategy intervention from a shared Checkpoint | The system forks baseline and intervention branches from the same Checkpoint. It changes one registered reasoning action while holding the problem, model, tools, and budget fixed, then compares verified progress and cost. The current contract applies to supported serial steps at an explicit pause. The comparison informs repair strategy within those conditions. See the intervention contract. |
The diagram shows the main search loop and the intervention loop from the technical report. Advanced mechanisms depend on the mode and service configuration. In live mode, Showcase calls the Intern service.
- Solver orchestration. The Python STAR Solver Harness coordinates Explore, Planner, Reasoner, Verifier, Meta, and Researcher. It manages role handoffs, Checkpoints, the shared budget, and persistent evidence. LangGraph runs workbench graphs and manages checkpoints. The Harness owns the STAR role loop. DeepAgents is available as an optional
AgentAdapter. See the framework boundary. - Tiered verification. The Verifier records independent review and evidence grades. A bounded deterministic tool check can reach L1. A supported Lean goal can reach L2 after kernel checking and a dependency audit. L3 also requires an independent review of how the formal specification corresponds to the original problem. Whole-solution model review is recorded as
LLM_REVIEWED. See the verification contract. - Workbench and traceability. The Vue workbench shows progress via the Flask Job API and server-sent events (SSE). It reads answers, public summaries, and available evidence from persisted records. The CLI uses the same API, and paired experiments have a review interface. See the role output validation record.
Manual startup, Vite hot reload, and CLI
Install the development dependencies and start a local backend from the repository root.
uv sync --locked --all-groups
uv run python showcase_server.py --host 127.0.0.1 --port 8090 --mode fake --data-dir artifacts/showcase-localStart Vite in another terminal and open 127.0.0.1:5174/dashboard-assets/. Vite proxies /api to local port 8090.
Set-Location showcase/frontend/chat-frontend
npm ci --no-audit --no-fund
npm run dev -- --host 127.0.0.1After running npm run build, visit the Flask /dashboard route to view the production build. From the repository root, check the service and create a local session with these commands.
uv run python showcase_cli.py health
uv run python showcase_cli.py session createAfter configuring credentials, start the backend with --mode live --data-dir artifacts/showcase-live to use Intern. The CLI probe command creates a Job and calls the model. See the Demo and CLI guide.
Enable image input or configure the Faithful service
- Image input. Set
$env:SHOWCASE_VISION_ENABLED = '1'in PowerShell before starting the live Web launcher. The workbench accepts text, one PNG, or both. The PNG limit is 128 KiB. Image interpretation shares the Job budget with solving. See the multimodal intake contract. - Faithful service. Copy the example configuration, then check the Docker image required by isolated tools, the budget, and the model context policy. Use your configured file path in these commands. The readiness check runs separately from Job submission.
uv run python showcase_server.py --mode live --faithful-config examples/faithful-service.json --check-runtime
uv run --no-project python scripts/start_showcase.py web --faithful-config examples/faithful-service.json --data-dir artifacts/faithful-localYou can enable adaptive_solving in supported configurations. Complete candidates go to independent whole-solution review. A specific mathematical objection can trigger one local repair before the solver returns to planning. See the high-budget configuration example and the adaptive solving contract.
The official evaluation uses user_agent.ReasoningAgent. BASELINE.json records the official baseline file hashes and evaluation results. Showcase runs through separate entry points. Interpret the report's ablation results within their respective datasets, denominators, and budgets. The repository validation records document the scope of the evidence for each capability.
| Topic | Reference |
|---|---|
| Current version, implementation status, and evidence | Documentation index |
| Dependency use in live runs, Lean attempts, and validation scope | Mechanism validation |
| Live model readiness, paired experiments, and release history | Readiness record · v0.2 release evidence |
| Fast, full offline, release, and frontend checks | Engineering checks |
| Merge criteria for the official evaluation path and Showcase | Release boundary |
Local validation commands
uv run python scripts/check_fast.py
uv run python scripts/check.py --offline
uv run python scripts/check_showcase_release.pyFrom showcase/frontend/chat-frontend/, run npm ci --no-audit --no-fund, npm audit --audit-level=high, and npm run check. For coverage and scope, see the engineering checks.

