Skip to main content

The fastest inference framework to run AI on CPUs

Project description

Trillim

Trillim is a local AI stack for CPUs. It gives you a CLI, a Python SDK, and a FastAPI server for running Trillim-formatted LLM bundles, plus optional speech-to-text and text-to-speech support.

Trillim supports both BitNet-style ternary bundles and PrismML's Bonsai (1-bit and ternary) bundles through the same managed model store and runtime surfaces.

DarkNet and the quantization tooling bundled with the package do the heavy inference work. The Python package is the orchestration layer around those binaries.

Install

  • Python 3.12 or newer is required.
  • Linux wheels target glibc >= 2.27.
  • uv is the recommended installer.
  • Voice features require the optional voice extra.

Platform guides:

If you install Trillim with uv, prefix CLI commands with uv run.

Quick Start

Install the package:

uv add trillim

Pull a model and chat with it:

uv run trillim pull Trillim/BitNet-TRNQ
uv run trillim chat Trillim/BitNet-TRNQ

Start the local API server:

uv run trillim serve Trillim/BitNet-TRNQ

Use the Python SDK synchronously through Runtime:

from trillim import LLM, Runtime

with Runtime(LLM("Trillim/BitNet-TRNQ")) as runtime:
    with runtime.llm.open_session() as session:
        reply = session.collect("Give me one sentence about local CPU inference.")
        print(reply)

Generate an image from a Bonsai Image bundle:

uv run trillim image Local/Bonsai-Image-4BT-TRNQ "a tiny bonsai on a desk" -o bonsai.png

Common Workflows

Pull and Inspect Bundles

trillim models lists bundles published by the Trillim Hugging Face organization. trillim list lists what you already have locally.

uv run trillim models
uv run trillim list

Quantize a Local Model or Adapter

trillim quantize takes raw local filesystem paths and publishes the output under ~/.trillim/models/Local/.

# Quantize a model bundle
uv run trillim quantize /path/to/model

# Quantize a LoRA adapter against its base model
uv run trillim quantize /path/to/base-model /path/to/adapter

Qwen3-based Bonsai checkpoints quantize into binary or grouped-ternary bundles, but Trillim still manages them under the same Local/...-TRNQ store naming and load flow.

Use an Adapter

chat accepts an optional second positional argument for the adapter store ID:

uv run trillim chat Trillim/BitNet-TRNQ Trillim/BitNet-GenZ-LoRA-TRNQ

Enable Voice Support

Install the extra first:

uv add "trillim[voice]"

Then start the voice-enabled server:

uv run trillim serve Trillim/BitNet-TRNQ --voice

Documentation

Learn

Extend and Serve

Advanced

License

For the short license summary, see What Is Trillim?. Full terms are in LICENSE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

trillim-0.12.1-py3-none-win_arm64.whl (1.9 MB view details)

Uploaded Python 3Windows ARM64

trillim-0.12.1-py3-none-win_amd64.whl (2.0 MB view details)

Uploaded Python 3Windows x86-64

trillim-0.12.1-py3-none-manylinux_2_27_x86_64.manylinux2014_x86_64.whl (7.2 MB view details)

Uploaded Python 3manylinux: glibc 2.27+ x86-64

trillim-0.12.1-py3-none-manylinux_2_27_aarch64.manylinux2014_aarch64.whl (7.3 MB view details)

Uploaded Python 3manylinux: glibc 2.27+ ARM64

trillim-0.12.1-py3-none-macosx_11_0_x86_64.whl (1.6 MB view details)

Uploaded Python 3macOS 11.0+ x86-64

trillim-0.12.1-py3-none-macosx_11_0_arm64.whl (1.6 MB view details)

Uploaded Python 3macOS 11.0+ ARM64

File details

Details for the file trillim-0.12.1-py3-none-win_arm64.whl.

File metadata

  • Download URL: trillim-0.12.1-py3-none-win_arm64.whl
  • Upload date:
  • Size: 1.9 MB
  • Tags: Python 3, Windows ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for trillim-0.12.1-py3-none-win_arm64.whl
Algorithm Hash digest
SHA256 4b32c0d563b3116104a2987c57294027693494626bca56d04c6d9f621e8bb4cd
MD5 2f50cd4fb5e18469ebd8df2306306e84
BLAKE2b-256 0d24744d961e3b5fb0deee5147cbd306b2488c5b6b5e42dcf3dd5c9f57da8626

See more details on using hashes here.

File details

Details for the file trillim-0.12.1-py3-none-win_amd64.whl.

File metadata

  • Download URL: trillim-0.12.1-py3-none-win_amd64.whl
  • Upload date:
  • Size: 2.0 MB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for trillim-0.12.1-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 8a970f6a2f305d650fecc2a8712d2c2ec5e743c1499032c2b1ba154efa2190a5
MD5 a14ce2fba0e9149b1bafa6fffaf450d1
BLAKE2b-256 72082d841a397b4149a1b8c59583de9ab41a8f0ae67ebd15f9e0105555bb6a9a

See more details on using hashes here.

File details

Details for the file trillim-0.12.1-py3-none-manylinux_2_27_x86_64.manylinux2014_x86_64.whl.

File metadata

  • Download URL: trillim-0.12.1-py3-none-manylinux_2_27_x86_64.manylinux2014_x86_64.whl
  • Upload date:
  • Size: 7.2 MB
  • Tags: Python 3, manylinux: glibc 2.27+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for trillim-0.12.1-py3-none-manylinux_2_27_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 864e15d8f527d879e483f4ebe80f79570c33531aa64925b08127350445e4d7e3
MD5 34d5f3dfe3ed53ad4ab7011bb7693bb8
BLAKE2b-256 9dd115d1063c04397c6ce51023c2e973744296011efbbb379e068bf871460828

See more details on using hashes here.

File details

Details for the file trillim-0.12.1-py3-none-manylinux_2_27_aarch64.manylinux2014_aarch64.whl.

File metadata

  • Download URL: trillim-0.12.1-py3-none-manylinux_2_27_aarch64.manylinux2014_aarch64.whl
  • Upload date:
  • Size: 7.3 MB
  • Tags: Python 3, manylinux: glibc 2.27+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for trillim-0.12.1-py3-none-manylinux_2_27_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 1ed3458f67300cfd7e3f8d44b063d2e97d29895badb8e4c3b807ee1fd28d99c3
MD5 8ad552df792a380aaa5253065ac6fe06
BLAKE2b-256 fc306fba91a9d60570e7559f5850bdf712992a5d434fd32ca1063a5589c4bf62

See more details on using hashes here.

File details

Details for the file trillim-0.12.1-py3-none-macosx_11_0_x86_64.whl.

File metadata

  • Download URL: trillim-0.12.1-py3-none-macosx_11_0_x86_64.whl
  • Upload date:
  • Size: 1.6 MB
  • Tags: Python 3, macOS 11.0+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for trillim-0.12.1-py3-none-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 b90057e50a72d539121511376f669f6d7a1dfda8f6c607e6dc191ae6ec3e7559
MD5 979c782e48c33e35a964f4dbc2fcfe37
BLAKE2b-256 8e4c90697b2629de2f5b63174cbef7355df0ba3e5e4e9915181a0f9dfa01fedf

See more details on using hashes here.

File details

Details for the file trillim-0.12.1-py3-none-macosx_11_0_arm64.whl.

File metadata

  • Download URL: trillim-0.12.1-py3-none-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 1.6 MB
  • Tags: Python 3, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for trillim-0.12.1-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 8c6f2a0e135b7433262bd6a242244544b508922d7763bd5d7dc2d70d51d1a0b1
MD5 a5d88c0c095d8350cac17cadb198d900
BLAKE2b-256 9c2c0a5f2ec3438cd1b4cda671e4188cd81e0747765730e4507df060f417c1dd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page