Skip to main content

chaincompiler-si — the self-interpreter, and the MCP server the ChainCompiler plugin runs

chaincompiler-si (import si) is the self-interpreter of ChainCompiler, a compiler-compiler for cognition. It runs ChainCompiler's chain dialect, which is Python with ChainCompiler's operations injected as names — forge_ac, forge_cor, forge_sc, construct_language, SkillTree, materialize, walk, build_exchange, tree_to_mcp and the rest — so an agent can drive the whole stack in one program.

  • interpret(source) runs a program in that dialect and returns its value;
  • walk and reachable traverse a materialized skill tree by its breadcrumbs, and read_skill finds a skill by name anywhere in a tree;
  • tree_to_mcp turns a tree into an MCP server launcher, and scaffold_repo stamps a federated node repository from a tree;
  • si.server is the navigator, the MCP server the ChainCompiler plugin registers, with the tools si_walk, si_reachable, si_read_skill, si_search and si_aioses, run by the console command si-server.
  • si.build_server is the build tool, for the maker agent's own sessions, with the tools si_interpret, si_tree_to_mcp and si_scaffold_repo, run by the console command si-build-server.

si_interpret executes arbitrary Python with the permissions of the process running the server. It is an execution surface: run only programs you trust.

Install

pip install chaincompiler-si

It brings chainaios and the chain compilers at the same release, and agent-skilltree and fastmcp from PyPI. To run the server without installing anything into your own Python, run it through uv, the way the ChainCompiler plugin launches it:

uvx --from chaincompiler-si si-server

To work on it, clone the repository and run ./install.sh, which installs all fifteen packages editable.

Use

from si import interpret

print(interpret("1 + 1"))                 # 2
print(interpret("forge_ac") is not None)  # True — ChainCompiler's operations are names in the dialect

Its design

The repository's DESIGN.md §14 (this package) and §16 (the plugin that launches its server).

License

MIT.

Metadata

Release files for chaincompiler-si 0.4.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for chaincompiler-si 0.4.2
File Size Uploaded Provenance Actions
chaincompiler_si-0.4.2.tar.gz 13.2 kB Without provenance Details for chaincompiler_si-0.4.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for chaincompiler-si 0.4.2
File Interpreter ABI Platform Actions
chaincompiler_si-0.4.2-py3-none-any.whl Python 3 none any Details for chaincompiler_si-0.4.2-py3-none-any.whl

Total release size: 26.4 kB

Release files / chaincompiler_si-0.4.2.tar.gz

Download URL chaincompiler_si-0.4.2.tar.gz
Size 13.2 kB
Tags Source
SHA-256 checksum
How to use checksums
8dd12f8e29a4f3b9b6977fc0d78d55dbc8b20bb2856a064eefc1f2ffa31771f9
BLAKE2b-256 checksum
How to use checksums
d2da3bd4636cd0615d6defd2bd233f79b85ba09bb3c1907af01dfca531d85d62
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.15

Release files / chaincompiler_si-0.4.2-py3-none-any.whl

Download URL chaincompiler_si-0.4.2-py3-none-any.whl
Size 13.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f66965766c8e96320212220e49a03259274c697f9aa75235593b79a0726e1286
BLAKE2b-256 checksum
How to use checksums
e3aac9650caf7a07d589a2b0e76560db36561f4216837a8efc7a1f472e63de60
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.15

Security for chaincompiler-si 0.4.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page