Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
MORT_HOMENoPath to a Mort compiler checkout. Without MORT_HOME, mort-mcp uses a `mortc` on your PATH; in that case checking, running and std lookup all work, but `mort_docs` and `mort_examples` need the checkout.

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

Write, type-check and run programs in Mort, a statically typed systems language that compiles to C (github.com/0xmortuex/Mort). You have not seen Mort in training - look things up before guessing: mort_docs for language rules (search the spec), mort_std for a std module's exact signatures. Loop: write code -> mort_check (fast, no C compiler) -> fix diagnostics -> mort_run. Programs start at fn main() -> int; statements end with ;; std modules are imported with import std.strings; and called as strings.trim(...). String literals are *u8, not slices: pass one to a []const u8 parameter as slice("text" as *const u8, 4). mort_examples has known-good programs.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}

Tools

Functions exposed to the LLM to take actions

NameDescription
mort_versionA

Report the Mort compiler version, language version and where it was found.

mort_checkA

Type-check Mort code without building it (fast; needs no C compiler).

Pass source (a whole program as text) and/or files (paths to .mx files compiled together as one program). Returns OK or the compiler's diagnostics with file:line:column and the offending source line.

mort_runA

Compile Mort code to a native binary and run it, capturing its output.

Needs a C compiler (cc/gcc/clang, or pip install ziglang). stdin is fed to the program, args are its command-line arguments, and it is killed after timeout_s. Reports compile errors the same way mort_check does.

mort_emit_cA

Show the C that Mort generates for a program (useful to see what a construct compiles to, or to debug codegen). freestanding=True emits bare-metal C (no libc, no main) as used for the MORT OS kernel.

mort_formatB

Format Mort source with the official formatter (mortc fmt) and return the formatted text.

mort_stdA

Look up the standard library.

With no module: list every std module. With a module (e.g. "strings" or "std.vec"): its public functions, structs and enums with exact signatures and doc comments, read from the installed compiler's source.

mort_docsA

Search the Mort language specification and reference docs.

Returns the best-matching sections, e.g. query="resource struct cleanup", "integer overflow", "slices", "error propagation ?". Requires MORT_HOME (a Mort checkout) since pip installs don't ship the docs.

mort_examplesA

List the compiler's bundled example programs, or show one by name. Examples are known-good Mort - a fast way to learn idioms. Needs MORT_HOME.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A3.9/5.0

Scored across 8 tools

Disambiguation5/5

Each tool has a clearly distinct purpose: compiling+running (mort_run) vs type-checking only (mort_check), codegen inspection (mort_emit_c), formatting, std API lookup, doc search, examples, and version. The only mild adjacency is mort_std vs mort_docs, but descriptions sharply separate API-signature lookup from prose spec search.

Naming Consistency4/5

All tools share a consistent mort_ prefix with short, predictable suffixes. A few suffixes are bare nouns (std, docs, examples, version) while others are verbs (run, check, format, emit_c), but the pattern stays readable and recognizable.

Tool Count5/5

Eight tools is well-scoped for a language toolchain MCP, with no redundant or filler tools. Each earns its place in a typical compile/inspect/learn workflow.

Completeness4/5

Covers the core lifecycle: check, run, emit C, format, plus discovery via std/docs/examples and version. Minor gaps exist (e.g. no project scaffolding, test runner, or LSP-style completion), but agents can work around these.

Maintenance

ActivityMaintained
ResponsivenessOutdated data