The tutor sits beside a Desmos graphing calculator and watches the student's graph as it changes. When they're stuck, it asks one good question about what's on the screen, so the student does the thinking and gets unstuck faster. It runs on a model on your own machine.
On a hard problem, an answer machine is the shortest path to "done," so students use one. Banning it doesn't change that. This tutor is built to make thinking it through yourself the faster path: no stalling on one misread step, no waiting a day for feedback, and no skipping the part where you actually learn.
It doesn't give the answer when a student begs, says they're out of time, or claims the teacher said it was OK. It says no warmly in a few words, then asks a question that moves them one step forward.
Each turn starts from the student's live expressions and recent edits. "Your parabola opens down. What controls that?" beats a generic hint.
Every problem has a hint ladder, from vague to specific. The tutor climbs one rung at a time, and only after the student has made a genuine attempt.
When a student is stuck, the tutor can plot a given, like the stated vertex, as a dashed cue. Code
enforces that it can only touch its own tutor_ expressions, never the student's work.
Language models are unreliable at algebra. Before the tutor says "yes, that point is on your curve," a real math checker evaluates it.
Every session is logged. The teacher view replays the graph and chat step by step, so you can see where a student got stuck and how they got out of it.
By default every model call goes to a model on your own machine or network: llama.cpp, Ollama, vLLM, LM Studio, or anything else that speaks the OpenAI chat API. There are no cloud APIs, no telemetry, and no analytics.
Cloud presets are included for development with fake students only. Point it at an outside provider and demo mode turns on by itself: a warning banner appears and nicknames are auto-generated, so no real names get typed in.
You need Node.js and a local model server that supports tool calling (for example,
llama-server --jinja or Ollama with a Qwen 3 model).
git clone https://github.com/killercatfish/desmos-tutor.git cd desmos-tutor npm install npm run dev
Open http://127.0.0.1:5173 for the student view and /teacher for the replay view.
Set LLM_BASE_URL and LLM_MODEL in .env to point at your model.
To add problems, drop JSON files in problems/. The tutor's teaching policy is plain text in
prompts/tutor_system.md, and you can edit it while the app runs.
Status: untested with a real model. This is v0.1, an early experiment. The app, the graph guard and the math checker are covered by 80 passing tests, but so far the tutor has only been run against a fake model server. Nobody knows yet how well real local models follow the Socratic rules. The teacher view has no login, so the server binds to localhost only.
Contributions are welcome, especially:
npm run simulate -- --verbose against your local model and share the transcript in an
issue. Does it leak answers? Ask one question at a time?prompts/tutor_system.md.problems/, from algebra through calculus.