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 MCP server the ChainCompiler plugin registers, with the tools si_interpret, si_walk, si_reachable, si_read_skill, si_tree_to_mcp and si_search, run by the console command si-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.3.4

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.3.4
File Size Uploaded Provenance Actions
chaincompiler_si-0.3.4.tar.gz 10.4 kB Without provenance Details for chaincompiler_si-0.3.4.tar.gz

Built distribution (wheel)

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

Total release size: 21.3 kB

Release files / chaincompiler_si-0.3.4.tar.gz

Download URL chaincompiler_si-0.3.4.tar.gz
Size 10.4 kB
Tags Source
SHA-256 checksum
How to use checksums
9b1fd02c6f0a40629775376672688bda0f88b2bdf7d1042de2ad0436cba76af6
BLAKE2b-256 checksum
How to use checksums
26fb20cc3fdc8f57b36ed16aedb329e844c438d305da5eeb584129d5110cfcbe
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.13

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

Download URL chaincompiler_si-0.3.4-py3-none-any.whl
Size 11.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ac52c37923debe81d01c5823226a9e696e66cabd3f6cffe20f1c0197dd8bea97
BLAKE2b-256 checksum
How to use checksums
01d91a7c4c4caaadd211c977a82de611899e274c72720c44225595ca4bd972be
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.13

Security for chaincompiler-si 0.3.4

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