curvat.io Think in curves
Gallery Open Calculator

AI Assistants & Automation

Curvat.io works with people and their assistants. A compatible browser assistant can create graphs, update equations, and return images or share links while you continue using the familiar calculator.

Zero barriers: No Curvat account, subscription, or API key is required.

Try it

  1. Open curvat.io in a browser your assistant can control.
  2. Ask your assistant:
    Example Assistant Prompt
    “Plot x² and 2x+1 in curvat.io, then give me a share link and a PNG.”
  3. Explore the result with Curvat’s usual graphing and calculus controls.

Want a quick example? Open these two curves in the calculator.

What can an assistant do?

What is WebMCP?

WebMCP lets a website give a compatible browser assistant named tools for working with the page. Curvat exposes its graphing tools through this interface.

Support depends on both your browser and your assistant. Opening Curvat does not automatically connect every AI service. If your assistant cannot discover the tools, it may still use normal browser controls or create formula links for you to open.

To learn more about the evolving browser specification and active browser engines, consult the official WebMCP Explainer and Implementation Status.

Do I need an MCP server connection?

Curvat’s current integration runs inside the browser page. There is no standalone Curvat MCP server URL to paste into a conventional desktop MCP client.

Browser automation developers can also use the versioned JavaScript interface described below.

Where do my equations go?

Curvat calculates and renders graphs locally in your browser with zero remote compute servers. Your connected assistant may process equations and tool results under its provider’s own privacy policy.

Formula links containing ?expr= send those expressions to hosting infrastructure in the initial web request before the calculator normalizes them. Canonical share links containing #g= keep the graph data in the URL fragment, which is never sent in the hosting request. Anyone receiving a share link can open its graph.

See Privacy Notice & Student Data Policy for details on the wider site’s data practices.

For developers and agents

Curvat offers three integration paths:

Path How to use it
WebMCP Open the ordinary calculator in a supporting browser; discover and call the registered tools in that page.
Browser JavaScript Use the versioned window.__curvat interface in an active calculator page.
Formula URLs Use repeated expr parameters; optional bounds require all four of xmin, xmax, ymin, and ymax. Encode expression values correctly, including + as %2B.

WebMCP Tool Reference

The page exposes these WebMCP tools:

Tool Name Purpose & Description
get_capabilities Discover API version, available operations, syntax modes, image formats, and limits.
get_state Read graph state, expression IDs, current revision, read-only status, and diagnostics.
validate_graph Check candidate expressions and parameter dependencies without altering the active graph.
apply_graph Replace the active graph atomically using the current expected revision.
update_entry Update a specific discovered expression ID using the current expected revision.
get_share_links Return canonical editable calculator (#g=1d...) and minimal LMS embed links.
export_image Return a high-resolution PNG or SVG image of the coordinate plane.
undo_last_agent_change Restore the assistant recovery checkpoint if subsequent human changes have not invalidated it.
Revision Safety Guidelines:
  • Start by discovering capabilities with get_capabilities and reading current state with get_state.
  • Use IDs returned by get_state, rather than guessing an ID such as entry-2.
  • Mutations require the current expectedRevision. Handle STALE_REVISION by rereading the graph and reconsidering the change—never blindly overwrite newer work.
  • Subsequent human edits (typing, dragging points, moving sliders) immediately invalidate the assistant recovery checkpoint, causing undo_last_agent_change to return NOTHING_TO_UNDO.
  • Read-only presentations (such as ?readonly=true embeds) reject assistant mutations with READ_ONLY. The ordinary calculator is the entry point for editing; the minimal /embed/ renderer is for presentation.

Browser Automation Example

Developers running Puppeteer, Playwright, or in-browser extensions can interact directly with the facade:

const api = window.__curvat;
if (!api) throw new Error('Open the Curvat calculator first.');

// 1. Wait for canvas initialization
const ready = await api.whenReady();
if (!ready.ok) throw new Error(JSON.stringify(ready.diagnostics));

// 2. Validate proposed expressions
const candidate = { expressions: ['x^2', '2x+1'] };
const validation = api.validateGraph(candidate);
if (!validation.ok) throw new Error(JSON.stringify(validation.diagnostics));

// 3. Inspect active state and revision
const state = api.getState();
if (!state.ok) throw new Error(JSON.stringify(state.diagnostics));

// 4. Apply graph with optimistic revision locking
const result = await api.applyGraph(candidate, {
  expectedRevision: state.revision
});
if (!result.ok) throw new Error(JSON.stringify(result.diagnostics));

// 5. Generate shareable link
const links = await api.getShareLinks();
console.log('Share link:', links.data.shareUrl);

Results use a standardized envelope containing ok, apiVersion, revision, status, data, and diagnostics. Always check ok before using results. The JavaScript API uses camelCase method names; WebMCP tools use snake_case names.

Additional technical specifications:

Need help?

Use Help → Feedback & Bug Report in the calculator menu to submit notes or bugs with an optional live canvas screenshot.

When reporting assistant issues, include your browser, assistant provider, and any diagnostic codes. Review screenshots and graph links before sharing if your expressions contain private information.