Using Omegyu from an assistant
Find the exact source of an example and check an edit locally through MCP, without rendering a page or executing the program.
Connect a local client
Install omegyu on the client machine and make it available on PATH, or use
its absolute path. For Claude Code, this
.mcp.json entry starts the checker with no filesystem access:
{
"mcpServers": {
"omegyu": { "type": "stdio", "command": "omegyu", "args": ["mcp"] }
}
}The default permits source text and embedded std: imports. For a local
project on POSIX, add "--project", "/absolute/path/to/project" to args.
Use the narrowest directory needed: all regular .omg files beneath it
are readable. Symlinks, paths outside the grant, environment and HTTP imports
are unavailable. The tool does not execute the program or persist a cache.
Checking can still use CPU and memory; this is not a multi-tenant service.
The server handles one check at a time, with a 60-second deadline and 1 MiB
limits on request frames and individual imported modules.
Discover the check tool and call it with {"source":"let n : Natural = True\nin n","path":"demo.omg"} (encode the newline as \n in JSON). path names the
source and sets its import directory; it is not a file to read. A bad program
is a tool result with isError: true and structuredContent.ok: false, not a
JSON-RPC error. Each compiler diagnostic includes its code, message and labels
with one-based lines and columns and half-open character offsets. Successful
checks have ok: true and an empty diagnostics array.
Try it on Counter
Follow Agent index in the site footer, or fetch
/llms.txt. Its first link is/agents/index.json. In thepagesarray, select the entry withfileequal toexamples/evm/Counter.omg.htmlis the human page;markdownis the text alternative;sourceis the exact compiler input. Resolve these paths against the site's origin. None requires JavaScript.Fetch
source. Callcheckwith that response body assourceand the entry'sfileaspath. Counter needs only embedded standard modules; it checks without a project grant. Expectok: true.In the fetched text, change
let State =tolet State : Natural =. Check again. Follow the primary label onE0003to the state declaration: the value is a record type, not a natural number. Remove the annotation before continuing. No source file has been modified by either call.
Design decision · 2026-12-01
Two different problems need two interfaces. Finding a language example should cost one static HTTP fetch, not a compiler installation. Checking an edited example needs the actual local compiler, not a web scraper or a hosted service.
Protocol. The MCP version registry identifies 2026-07-28 as current. It uses per-request version and client capabilities, mandatory
server/discover, and typed results. This differs from the widely deployed 2025-11-25 initialization handshake. Support both for local clients, using the same check implementation. Stdio requires newline-delimited JSON-RPC and reserves stdout for protocol messages. Tool results can carry structured data and text; tool failures are distinct from invalid RPCs.Interoperability. The official TypeScript SDK publishes a standalone client with a child-process transport. Use it against the executable, not against a mock. One tool suffices:
checktakes source and returns compiler diagnostics. No execution, shell, deployment, dynamic roots, prompts or server-initiated requests.Documentation. Cloudflare's Markdown for Agents illustrates serving a text alternative with HTTP content negotiation. A static host needs no negotiation: publish stable Markdown URLs and original
.omgfiles beside the canonical HTML pages. Generate links and text from the same checked content as the human reader. A small versioned JSON index supports programmatic selection; /llms.txt is a useful optional Markdown entry point, not an MCP requirement, permissions file, or promise that any particular assistant will consult it.