Esta página aún no está traducida.

Libraries and SDKs

This page is for developers who want to read, check or follow instructions from their own code. It lists the libraries for each language, what each does, where it is published, and its version and licence.

Every library implements the same first edition of the specification (instruction/1, spec: "1"). The TypeScript library in the instruction.md npm package is the reference: the Python, Go and Rust libraries are ports of it, and each runs the specification's conformance cases and the reference's vectors and must agree byte for byte. A behaviour question is settled by the TypeScript code.

Which library for what

You want to Use
Check, format or render instruction files in a script or CI instruction.md (npm), or the instruction command it installs (The instruction CLI)
Give an agent you run with the Claude Agent SDK or the Codex SDK the instruction it follows, and each new version @instruction.md/agents, its follow() (JavaScript and TypeScript)
Follow one instruction from a long-running agent of your own, with a signature policy InstructionFollower in instruction.md (JavaScript), InstructionFollower in Python (Python), Follower in Go (Go)
Read and check documents in Python, Go or Rust Python, Go, Rust
Verify who published a version Every library: author and delivery signatures (Ed25519 JWS). See Signing and trust
Draw an instruction on a web page instruction.md/render, or one script tag (Embed and preview)
Read and write sealed instructions (beta, not yet independently reviewed) @instruction.md/mcp, a local MCP server (instruction-mcp command reference). The instruction command and its hooks read them (Sealed instructions)
Write instructions in an editor The VS Code extension

Writing to the registry (creating, editing, releasing) is not in any library's API. Use the CLI, the web editor, or the server's tools over MCP (Tool reference).

Every library

These rows are read from each library's manifest when this page is built.

LibraryLanguagePublished onVersionLicenceRuns onWhat it does
instruction.md
npm install instruction.md
JavaScript, TypeScriptnpm0.11.2MITNode.js 20.19+; the reader, resolver and client also in browsers and workersThe reader, checks, resolver and formatter; signature verification; an MCP client; a follower for one instruction and one for a platform; the language tools; the renderer; the instruction command.
@instruction.md/agents
npm install @instruction.md/agents
JavaScript, TypeScriptnpm0.4.3MITNode.js 20.19+follow() for an agent you run with the Claude Agent SDK, the Codex SDK or your own loop; the pi extension; the instruction-agents command.
@instruction.md/mcp
npx -y @instruction.md/mcp
JavaScript (a command)npm, ghcr.io/instruction-md/mcp0.1.1MITNode.js 20.19+An MCP server for sealed instructions: the same tools as the hosted server, with the text opened and sealed on your side.
instruction.md
pip install instruction.md
PythonPyPI0.3.1MIT OR Apache-2.0Python 3.9+ (the follower: 3.10+)The reader, checks, resolver and formatter; signature verification with the sign extra; a follower over MCP with the mcp extra.
github.com/instruction-md/source-code/sdks/goGonot fetchable yet0.1.0BUSL-1.1Go 1.22+The reader, checks, resolver and formatter; signature verification; a Follower and an MCP client on the standard library.
instruction-md
cargo add instruction-md
Rustcrates.io0.6.1MIT OR Apache-2.0Rust 1.96+The reader, checks, resolver and formatter; signature verification (the verify feature, on by default). No I/O: no client or follower.
instruction-md.vscode-instruction-mdVS Code extensiona .vsix file0.2.0MITVS Code 1.100.0+Highlighting, diagnostics with quick fixes, completion, navigation, the preview and the delivered text.

All of them are pre-1.0. A minor version (0.11 to 0.12) may change behaviour or remove something, and a patch version only fixes or adds. Read a library's changelog, where it has one, before a minor upgrade.

What every port does

Each library has the same surface for a document, offline and with no network:

  • read a document into its authored tree, with the reader's diagnostics and their stable codes;
  • check it, the inline checks included;
  • resolve it with its bases and includes into the resolved artifact (instruction-resolved/1) and the text an agent receives (instruction-text/1);
  • format it and digest its bytes (sha256:…);
  • verify an author signature and a delivery signature.

The followers (TypeScript, Python, Go) also read an instruction from an instruction.md MCP server over the 2026-07-28 stateless protocol, apply it, hold a version their policy refuses while keeping the last good one, and report the version applied. The Rust crate does no I/O: your code fetches the text and hands it over.

None of the libraries opens sealed instructions (beta, not yet independently reviewed). Only @instruction.md/mcp and the instruction command do. See Sealed instructions.

Licences and availability

  • instruction.md, @instruction.md/agents, @instruction.md/mcp and the VS Code extension: MIT. You may use, change and ship them in open or closed software; keep the copyright and licence notice. The instruction.md package also carries the specification's data under CC BY 4.0, its conformance cases under Apache-2.0 and eleven Lucide icons under ISC.
  • Python ({python.name}) and Rust ({rust.name}): {python.license}, at your option.
  • Go: {go.license}, source-available, not an open-source licence. Each version changes to Apache 2.0 four years after it is published. Its module path, {go.module}, is in a private repository, so go get can't fetch it yet. To use it today, ask through Support for access or a source archive.
  • The VS Code extension is not on the Marketplace or Open VSX yet; it installs from a .vsix file (VS Code extension).

Questions

Do the libraries need an account?

Reading, checking and resolving a document need none, and send nothing. A follower reads over instruction.md's MCP server, which answers only a caller with a token, even for a public instruction. See Agent credentials and CI tokens.

Which one is the reference?

The TypeScript library in the instruction.md npm package. The other ports are held to its vectors, and a difference is a bug in the port.

Is there a library for creating and releasing instructions?

No. Release from the CLI, from CI (Publish and check from CI), or through the MCP server's tools.

Last checked against the product:

Was this page helpful? Report a problem