Tuisko LLM Python
tuisko-llm provides the exact host-side frontend for
unsloth/Qwen3.8-27B-NVFP4 at its pinned revision. It supports:
- checkpoint admission, tokenizer encode/decode, stop IDs, and generation defaults;
- structured chat messages, reasoning history, tool calls, and template controls;
- prompt-prefix accounting and incremental UTF-8-safe token decoding.
It does not initialize CUDA or run inference in process. Use the TuiskoLLM server's OpenAI-compatible HTTP API for generation.
Install
pip install tuisko-llm
Example
from tuisko.llm import ChatMessage, Frontend
frontend = Frontend.open("/path/to/16b6615af3548b88e2d8e382457bc705b00479cf")
messages = [ChatMessage("system", "You are concise."), ChatMessage("user", "Hello")]
prompt = frontend.encode_chat_with_report(messages, enable_thinking=False)
print(prompt.token_ids)
print(prompt.reused_tokens)
ChatMessage also represents prior reasoning, function calls, and tool results. The three chat
methods accept both structured messages and existing (role, content) pairs. Their options expose
thinking controls and OpenAI-compatible tool definitions. Frontend.streaming_decoder() decodes
generated token IDs without splitting UTF-8 text.
Frontend.open() first admits the complete pinned checkpoint inventory. It raises
CheckpointError for snapshot admission failures and FrontendError for tokenizer or template
failures; both derive from TuiskoError.
Metadata
Release files for tuisko-llm 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| tuisko_llm-0.1.0.tar.gz | 85.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| tuisko_llm-0.1.0-cp312-abi3-manylinux_2_34_x86_64.whl | CPython 3.12 | abi3 | Linux glibc 2.34+ x86-64 | Details |
Total release size: 2.6 MB
Release files / tuisko_llm-0.1.0.tar.gz
| Download URL | tuisko_llm-0.1.0.tar.gz |
|---|---|
| Size | 85.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
25585d432748b495134ba77a4d93f15fe6b20d0200e83eae7f88daa8e5d2d014
|
|
BLAKE2b-256 checksum How to use checksums |
1108189291bf1525837d9e489d1728dd7f4871cbc3e8a7d9ec6ad021be03d766
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 23, 2026.
Transparency logRelease files / tuisko_llm-0.1.0-cp312-abi3-manylinux_2_34_x86_64.whl
| Download URL | tuisko_llm-0.1.0-cp312-abi3-manylinux_2_34_x86_64.whl |
|---|---|
| Size | 2.5 MB |
| Tags | CPython 3.12 Linux glibc 2.34+ x86-64 abi3 |
|
SHA-256 checksum How to use checksums |
8714c04e2c10869a049221fe96bb2eb322ce8ab7f5a8158c990d9c2367857b0b
|
|
BLAKE2b-256 checksum How to use checksums |
105b68b69ea331e18a416e41ebfe50ea40b8a5b82e393050c73d50af22abc14c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 23, 2026.
Transparency log