basal-engine 3.0.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (111) hide show
  1. basal/__init__.py +7 -0
  2. basal/adapter.py +420 -0
  3. basal/adapters.py +8 -0
  4. basal/agree.py +393 -0
  5. basal/attach.py +160 -0
  6. basal/attn512.py +132 -0
  7. basal/auth.py +194 -0
  8. basal/bench.py +367 -0
  9. basal/blockquant.py +227 -0
  10. basal/calibrate.py +2198 -0
  11. basal/chat.py +175 -0
  12. basal/cli.py +70 -0
  13. basal/client.py +8 -0
  14. basal/decision_log.py +189 -0
  15. basal/decision_rules.py +569 -0
  16. basal/decisions.py +158 -0
  17. basal/derive.py +98 -0
  18. basal/disconnect.py +85 -0
  19. basal/engine.py +6023 -0
  20. basal/evidence.py +133 -0
  21. basal/examples/choice.jsonl +8 -0
  22. basal/examples/complex.jsonl +5 -0
  23. basal/examples/labelled_tickets.jsonl +500 -0
  24. basal/examples/local_backend.py +34 -0
  25. basal/examples/noul.jsonl +8 -0
  26. basal/examples/questions.jsonl +20 -0
  27. basal/examples/score.jsonl +8 -0
  28. basal/examples/selfcheck_basal-omni-pico-Q8_0.json +1 -0
  29. basal/examples/selfcheck_basal-omni-pico.json +1 -0
  30. basal/examples/types_demo.py +74 -0
  31. basal/facts.py +497 -0
  32. basal/feedback.py +234 -0
  33. basal/file_identity.py +39 -0
  34. basal/finetune.py +321 -0
  35. basal/fit_decisions.py +944 -0
  36. basal/fla_configs.json +1822 -0
  37. basal/fold.py +206 -0
  38. basal/fonts/OFL-DMSans.txt +93 -0
  39. basal/fonts/OFL-SpaceGrotesk.txt +93 -0
  40. basal/fonts/dm-sans-latin-ext.woff2 +0 -0
  41. basal/fonts/dm-sans-latin.woff2 +0 -0
  42. basal/fonts/space-grotesk-latin-ext.woff2 +0 -0
  43. basal/fonts/space-grotesk-latin.woff2 +0 -0
  44. basal/fp8block.py +100 -0
  45. basal/gdn_graph.py +1792 -0
  46. basal/gemma4.py +726 -0
  47. basal/gemma4_graph.py +931 -0
  48. basal/gguf_export.py +497 -0
  49. basal/identity.py +217 -0
  50. basal/int8block.py +50 -0
  51. basal/interpolate.py +330 -0
  52. basal/jsonl.py +172 -0
  53. basal/lean.py +204 -0
  54. basal/llama_attn.py +252 -0
  55. basal/llama_attn_kernels.py +266 -0
  56. basal/llama_graph.py +587 -0
  57. basal/llama_kernels.py +593 -0
  58. basal/loadtest.py +189 -0
  59. basal/mcp_server.py +432 -0
  60. basal/media.py +138 -0
  61. basal/metrics.py +16 -0
  62. basal/mlx_attn_kernels.py +1057 -0
  63. basal/mlx_forward.py +326 -0
  64. basal/mlx_kernels.py +543 -0
  65. basal/mlx_metal.py +510 -0
  66. basal/navcut.py +283 -0
  67. basal/navigate.py +646 -0
  68. basal/navtree.py +397 -0
  69. basal/nvfp4.py +245 -0
  70. basal/ordercheck.py +165 -0
  71. basal/pdf.py +183 -0
  72. basal/prepared.py +355 -0
  73. basal/presets.py +8 -0
  74. basal/prompt.py +462 -0
  75. basal/rank.py +373 -0
  76. basal/readout.py +121 -0
  77. basal/request.py +327 -0
  78. basal/response_cache.py +105 -0
  79. basal/router.py +1551 -0
  80. basal/router_ui.html +902 -0
  81. basal/router_ui.py +277 -0
  82. basal/run.py +376 -0
  83. basal/selfcheck.py +215 -0
  84. basal/server.py +5279 -0
  85. basal/sets.py +214 -0
  86. basal/signals.py +28 -0
  87. basal/state_disk.py +942 -0
  88. basal/strix.py +505 -0
  89. basal/synth.py +92 -0
  90. basal/tasks.py +848 -0
  91. basal/textio.py +21 -0
  92. basal/think.py +390 -0
  93. basal/tools.py +171 -0
  94. basal/tpu.py +336 -0
  95. basal/tpu_kernels.py +129 -0
  96. basal/trace.py +125 -0
  97. basal/ui.html +861 -0
  98. basal/ui.py +526 -0
  99. basal/varloop.py +813 -0
  100. basal/varloop_graph.py +1377 -0
  101. basal/varloop_kernels.py +907 -0
  102. basal/viz.html +660 -0
  103. basal/viz.py +375 -0
  104. basal/vllm_unified.py +100 -0
  105. basal_engine-3.0.3.dist-info/METADATA +416 -0
  106. basal_engine-3.0.3.dist-info/RECORD +111 -0
  107. basal_engine-3.0.3.dist-info/WHEEL +5 -0
  108. basal_engine-3.0.3.dist-info/entry_points.txt +21 -0
  109. basal_engine-3.0.3.dist-info/licenses/LICENSE +202 -0
  110. basal_engine-3.0.3.dist-info/licenses/NOTICE +34 -0
  111. basal_engine-3.0.3.dist-info/top_level.txt +1 -0
@@ -0,0 +1,416 @@
1
+ Metadata-Version: 2.4
2
+ Name: basal-engine
3
+ Version: 3.0.3
4
+ Summary: Inference engine for basal: fast, calibrated typed decisions (choice / yes-no / score) for Polish and English
5
+ License-Expression: Apache-2.0
6
+ Requires-Python: >=3.10
7
+ Description-Content-Type: text/markdown
8
+ License-File: LICENSE
9
+ License-File: NOTICE
10
+ Requires-Dist: basal-sdk==3.0.3
11
+ Requires-Dist: torch<2.15,>=2.11
12
+ Requires-Dist: transformers==5.17.0
13
+ Requires-Dist: numpy>=1.17
14
+ Requires-Dist: huggingface_hub>=0.34
15
+ Requires-Dist: accelerate>=1.10
16
+ Requires-Dist: safetensors>=0.6
17
+ Requires-Dist: starlette>=0.47
18
+ Requires-Dist: uvicorn[standard]>=0.35
19
+ Requires-Dist: httpx>=0.28
20
+ Provides-Extra: fp8
21
+ Requires-Dist: torchao==0.18.0; extra == "fp8"
22
+ Provides-Extra: nvfp4
23
+ Requires-Dist: torchao==0.18.0; extra == "nvfp4"
24
+ Provides-Extra: vllm
25
+ Requires-Dist: vllm>=0.11; extra == "vllm"
26
+ Provides-Extra: mlx
27
+ Requires-Dist: mlx>=0.32; (sys_platform == "darwin" and platform_machine == "arm64" and python_version >= "3.11") and extra == "mlx"
28
+ Requires-Dist: mlx-lm>=0.32; (sys_platform == "darwin" and platform_machine == "arm64" and python_version >= "3.11") and extra == "mlx"
29
+ Provides-Extra: media
30
+ Requires-Dist: pillow; extra == "media"
31
+ Requires-Dist: soundfile; extra == "media"
32
+ Requires-Dist: scipy; extra == "media"
33
+ Requires-Dist: torchvision; extra == "media"
34
+ Provides-Extra: gguf
35
+ Requires-Dist: llama-cpp-python>=0.3.36; extra == "gguf"
36
+ Provides-Extra: gguf-export
37
+ Requires-Dist: gguf>=0.19; extra == "gguf-export"
38
+ Provides-Extra: mcp
39
+ Requires-Dist: mcp<3,>=2.3; extra == "mcp"
40
+ Provides-Extra: finetune
41
+ Requires-Dist: peft>=0.17; extra == "finetune"
42
+ Provides-Extra: navigate
43
+ Requires-Dist: scikit-learn>=1.3; extra == "navigate"
44
+ Provides-Extra: pdf
45
+ Requires-Dist: pypdf==6.21.2; extra == "pdf"
46
+ Provides-Extra: tpu
47
+ Requires-Dist: jax[tpu]==0.11.1; (python_version >= "3.12" and sys_platform == "linux") and extra == "tpu"
48
+ Provides-Extra: test
49
+ Requires-Dist: pytest; extra == "test"
50
+ Requires-Dist: pytest-xdist; extra == "test"
51
+ Requires-Dist: jsonschema; extra == "test"
52
+ Requires-Dist: mcp<3,>=2.3; extra == "test"
53
+ Requires-Dist: gguf>=0.19; extra == "test"
54
+ Requires-Dist: pypdf==6.21.2; extra == "test"
55
+ Requires-Dist: pillow; extra == "test"
56
+ Requires-Dist: soundfile; extra == "test"
57
+ Requires-Dist: scipy; extra == "test"
58
+ Requires-Dist: mlx>=0.32; (sys_platform == "darwin" and platform_machine == "arm64" and python_version >= "3.11") and extra == "test"
59
+ Requires-Dist: mlx-lm>=0.32; (sys_platform == "darwin" and platform_machine == "arm64" and python_version >= "3.11") and extra == "test"
60
+ Dynamic: license-file
61
+
62
+ # basal 3.0
63
+
64
+ [![Hugging Face](https://img.shields.io/badge/%F0%9F%A4%97%20Hugging%20Face-basal--3.0%20models-yellow)](https://huggingface.co/collections/Remek/basal-30-6b043088e52f449b99649734)
65
+ [![Hugging Face](https://img.shields.io/badge/%F0%9F%A4%97%20Hugging%20Face-basal--omni--2.0%20models-yellow)](https://huggingface.co/collections/Remek/basal-omni-20-6b04308b8a39b1d979c2cee0)
66
+ [![Website](https://img.shields.io/badge/web-basal.si5.pl-0a7d5a)](https://basal.si5.pl/)
67
+ [![basal-1.0 technical report](https://img.shields.io/badge/basal--1.0%20technical%20report-PDF-b31b1b.svg)](docs/basal-1.pdf)
68
+ [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.23022986.svg)](https://doi.org/10.5281/zenodo.23022986)
69
+
70
+ Inference engine and models for **basal-3.0** and **basal-omni-2.0**: small, fast, calibrated *typed-decision* models
71
+ for Polish and English. The basal-omni-1.0 models also take **images and audio** in a request (experimental).
72
+ The basal-omni-2.0 models are nano (Gemma 4 E2B), mini (Gemma 4 E4B) and max (Gemma 4 12B). The basal-3.0 text models,
73
+ built on Bielik v3.0, are basal-3.0-mini (4.5B) and basal-3.0-max (11B). The launch models and their ports:
74
+ [release notes](docs/RELEASE_NOTES_3_0_3.md#launch-models).
75
+
76
+ **What it is.** basal is inspired by *System 1* (fast, intuitive) decision models such as Jev: instead of a chatbot
77
+ that writes an answer, the model reads a **state** (a message, a document, a case file, retrieved passages, an agent
78
+ trace, a web page as JSON) and answers a **typed question** about it by returning a **probability for each allowed
79
+ answer**, in one forward pass, without generating text. The answer can never fall outside the options you gave, and
80
+ the probability says how sure the model is.
81
+
82
+ **What it is for: a dynamic classifier.** You describe the classes *in the request*, in plain language, per call,
83
+ instead of training a classifier for them: routing tickets and documents (up to 255 options), rule and policy
84
+ checks, questions about long documents, RAG decisions, scoring on ordered scales, the next step of an agent, judging
85
+ answers, and triage with a confidence threshold that sends uncertain cases to a person.
86
+
87
+ > The name comes from the *basal ganglia*, the part of the brain that selects one action among competing options.
88
+
89
+ ## Contents
90
+
91
+ - [What is new in basal 3.0](#what-is-new-in-basal-30) · [Upgrading from 2.x](docs/UPGRADING.md) · [Models](#models) · [Results](#results) · [Quick start](#quick-start) · [API](#api)
92
+ - [Images and audio: basal-omni](#images-and-audio-basal-omni-experimental) · [MCP for agents](#mcp-basal-as-a-tool-for-agents) · [Documentation](#documentation)
93
+ - [Limitations](#limitations) · [Previous releases](#previous-releases) · [Citation](#citation) · [Contributors](#contributors) · [License](#license)
94
+
95
+ ## What is new in basal 3.0
96
+
97
+ Released 2 December 2026. See the [basal 3.0.3 release notes](docs/RELEASE_NOTES_3_0_3.md). The [2.x upgrade guide](docs/UPGRADING.md) describes changes in returned answers and the new package names.
98
+ All changes: [WHATS_NEW](docs/WHATS_NEW.md).
99
+
100
+ - **Two packages**: `basal-engine`, the server (**uninstall 2.x's `basal` first**: [why](docs/UPGRADING.md#install-two-packages)),
101
+ and `basal-sdk`, the Python client alone (httpx only, `import basal_sdk`; `basal.client` keeps working with the
102
+ engine). From 3.0.3 both are published to PyPI, the TypeScript client `basal-client` to npm, and a `basal-serve`
103
+ container image to ghcr.io.
104
+ - **New kinds of models**: dual models read a one-question request two-way and a request of several questions over a
105
+ state prefix read both ways once (`--dual-reading`); prefix-bidirectional models are served as they were trained.
106
+ - **Requests and answers**: `GET /v1/capabilities` says what a server takes; `"errors": "per_question"` answers the
107
+ other questions when one is invalid; `"trace": true` says why each question got its answer; images and audio go as
108
+ `multipart/form-data` files; `extract` reads the lines of an invoice or an order (experimental); and
109
+ `--chat-classify on` answers an LLM gateway's "pick 1..n" chat prompt with one calibrated decision.
110
+ - **Serving**: a response cache (`--response-cache-mb`); the state cache on disk, also after a restart
111
+ (`--state-cache-dir`); a stalled engine call fails its requests and `/health` says so (`--stall-s auto`, and
112
+ `--stall-exit on` for a supervisor); concurrent long requests at 1.7x (H100) to 3.6x (RTX PRO 6000) the throughput
113
+ at 8 clients (`--long-lane auto`; `eager` keeps 2.8's rule); a shorter start of the CUDA graph engine; `--mode fp8`
114
+ answers the same at every start; and the rare HTTP 500 with `--mode fast` and the state cache is fixed.
115
+ - **Bielik / Llama pure-Triton engine (opt-in `--llama-graph on`)**: a dedicated pure-Triton CUDA graph forward
116
+ (`basal/llama_graph.py`) with Single-Pass Flat SOAM, native NHD layout, fused RMSNorm/RoPE/SwiGLU, complete last-layer
117
+ readout slicing, lossless per-column merged ModelOpt FP8, and 128×128 Block-FP8 / Block-INT8 (`--fp8-scaling block`,
118
+ `--mode int8`, `--quant-load cpu`) for Bielik / Llama models. The default, `--llama-graph off`,
119
+ answers as before; `--llama-graph on` uses its own engine label (`llamagraph`, `llamagraph.fp8`, `llamagraph.int8`)
120
+ and `CALIBRATION.llamagraph*.json` (falling back to temperatures-only with `"calibration": "unvalidated"` until fitted).
121
+ On an H100, against `--llama-graph off` on the same Bielik weights: **top-1 agreement of 1.000** in bf16 on the
122
+ bundled decisions, a **5× to 17× faster cold start** and **2.1× to 3.1× the throughput**.
123
+ - **Apple Silicon MLX pure-Metal kernels & two-way reading (opt-in `--mlx-forward metal`)**: pure-Metal
124
+ kernels (`basal/mlx_kernels.py`, `basal/mlx_attn_kernels.py`, `basal/mlx_metal.py`) via `mx.fast.metal_kernel`
125
+ adding unconditional merged QKV/GateUp projections, bias-fused `add_rmsnorm` / `swiglu` / `qkv_rope`, zero-copy
126
+ shared-prefix KV attention, Split-KV FP32 readout attention, and full **two-way reading (`basal.json` `"two_way"`)**
127
+ for Bielik/Llama models on Apple Silicon (`CALIBRATION.mlx.metal.json`; default `mlx-lm` and `basal` stay untouched).
128
+ Measured on a 48 GB Apple M4 Pro: **14% to 33% higher batched throughput** and state-cache hits up to **1.68×
129
+ faster**.
130
+ - **Looped models (VarLoop, preview, 3.0.3)**: checkpoints with a `varloop.json` run their middle layers more than once
131
+ per read, with learned gates between the passes, in `--mode fast`, `fp8`, `int8` and `eager`. `--varloop-passes T`
132
+ sets the number of passes, and `--varloop-exit-tau τ` stops after the first pass when it is already confident.
133
+ Other models are served as before.
134
+ - **basal-router**: bounded (`--max-requests`), checks API keys itself (`--api-keys`, `--max-requests-per-key`), and
135
+ sends a growing state to the replica that has its beginning cached (`--prefix-affinity`, `--state-holders`).
136
+ - **Clients** (Python and TypeScript): a timeout per call, retries with jittered backoff, `fail_open`; the
137
+ TypeScript client runs in Cloudflare Workers and browsers.
138
+ - **Calibration from production**: the decision log as calibration input, with an audit sample of requests for review
139
+ (`--log-requests`, `--review-sample`) and `basal-feedback`; `basal-calibrate` refits about 14x faster;
140
+ `basal-fold-temperature` puts a calibrated temperature into a checkpoint for other engines.
141
+ - **Retrieval**: `basal-navigate` reads PDF documents and fits a calibrated cut-off for how many pages to open
142
+ (`basal-navigate calibrate`); MCP tools `navigate` and `read_page` search a tree through the server.
143
+ - Thank you to Miłosz Kucharski for his pull requests, to Paweł Kiszczak, whose pull request the state cache's disk
144
+ tier is based on, and to Dariusz Koryto, whose design the decision log's audit sample follows.
145
+
146
+ 2.x releases (2.5 to 2.8.0): [WHATS_NEW](docs/WHATS_NEW.md#what-is-new-in-basal-280).
147
+
148
+ ## Models
149
+
150
+ **basal-3.0** (text; built on Bielik v3.0; read two-way up to 4,096 prompt tokens, longer prompts causally; served with
151
+ `--llama-graph on`):
152
+
153
+ | model | params | use | Hugging Face |
154
+ |---|---|---|---|
155
+ | **basal-3.0-mini** | 4.5B (Bielik-4.5B-v3.0-Instruct) | text decisions (Werdykt 2.0 0.771); `--mode fast --llama-graph on --template-prefix off` | [`Remek/basal-3.0-mini`](https://huggingface.co/Remek/basal-3.0-mini) · [`-FP8`](https://huggingface.co/Remek/basal-3.0-mini-FP8) · [`-GGUF`](https://huggingface.co/Remek/basal-3.0-mini-GGUF) · [`-one-way-GGUF`](https://huggingface.co/Remek/basal-3.0-mini-one-way-GGUF) · [`-MLX-8bit`](https://huggingface.co/Remek/basal-3.0-mini-MLX-8bit) |
156
+ | **basal-3.0-max** | 11B (Bielik-PL-11B-v3.0-Instruct) | text decisions (Werdykt 2.0 0.816); `--mode fast --llama-graph on` | [`Remek/basal-3.0-max`](https://huggingface.co/Remek/basal-3.0-max) · [`-FP8`](https://huggingface.co/Remek/basal-3.0-max-FP8) · [`-GGUF`](https://huggingface.co/Remek/basal-3.0-max-GGUF) · [`-one-way-GGUF`](https://huggingface.co/Remek/basal-3.0-max-one-way-GGUF) · [`-MLX-8bit`](https://huggingface.co/Remek/basal-3.0-max-MLX-8bit) |
157
+
158
+ **basal-omni-2.0** (text; built on Google Gemma 4; read two-way up to 4,096 prompt tokens; Gemma 4's image and audio
159
+ encoders are included, but these models were trained and evaluated on text only):
160
+
161
+ | model | params | use | Hugging Face |
162
+ |---|---|---|---|
163
+ | **basal-omni-2.0-nano** | 2B (Gemma 4 E2B) | text decisions (Werdykt 2.0 0.756); about 14 GiB of GPU memory (`--mode fast`, H100) | [`Remek/basal-omni-2.0-nano`](https://huggingface.co/Remek/basal-omni-2.0-nano) · [`-GGUF`](https://huggingface.co/Remek/basal-omni-2.0-nano-GGUF) · [`-MLX`](https://huggingface.co/Remek/basal-omni-2.0-nano-MLX) (both experimental, one-way) |
164
+ | **basal-omni-2.0-mini** | 4B (Gemma 4 E4B) | text decisions (Werdykt 2.0 0.822); about 20 GiB of GPU memory (`--mode fast`, H100) | [`Remek/basal-omni-2.0-mini`](https://huggingface.co/Remek/basal-omni-2.0-mini) · [`-GGUF`](https://huggingface.co/Remek/basal-omni-2.0-mini-GGUF) · [`-MLX`](https://huggingface.co/Remek/basal-omni-2.0-mini-MLX) (both experimental, one-way) |
165
+ | **basal-omni-2.0-max** | 12B (Gemma 4 12B) | text decisions (Werdykt 2.0 0.843); about 32 GiB of GPU memory (`--mode fast`, H100); bf16 only | [`Remek/basal-omni-2.0-max`](https://huggingface.co/Remek/basal-omni-2.0-max) |
166
+
167
+ Each repository ships its prompt format (`basal.json`) and calibration files, and every port is checked against its
168
+ bf16 model ([files in detail](docs/INSTALL.md#what-the-model-repositories-contain)): `-FP8` for the basal engine,
169
+ `-GGUF` for Ollama and llama.cpp, `-MLX` for Apple Silicon. llama.cpp and Ollama read one way: a basal-3.0 `-GGUF`
170
+ file reads its two-way model causally, at a cost its card measures, and `-one-way-GGUF` is a separately trained
171
+ one-way model of the same size with its own scores. The basal-omni-2.0 models also read two-way, and their `-GGUF` and
172
+ `-MLX` ports read them one way: their cards mark them experimental and not recommended, and measure the cost. All
173
+ models are fine-tuned from Apache-2.0 base models (Bielik v3 for basal-3.0 and basal-2.0, Gemma 4 for basal-omni; see
174
+ [NOTICE](NOTICE)) and released under Apache-2.0. Choose a size from the basal-3.0 and basal-omni-2.0 tables above;
175
+ each model card gives its results, calibration and speed. For requests with images or audio, use basal-omni-1.0
176
+ (below).
177
+
178
+ ### Previous models
179
+
180
+ **basal-omni** (experimental; text, images and audio; built on Google Gemma 4, pico on Qwen3.5):
181
+
182
+ | model | params | use | Hugging Face |
183
+ |---|---|---|---|
184
+ | **basal-omni-pico** | 0.8B (Qwen3.5-0.8B) | the smallest basal model: text decisions on a CPU or a small GPU (Werdykt 0.660); `--mode fast` on CUDA from basal 2.4 (with flash-linear-attention; 2.3.2-2.3.x: `--mode eager`), `--mode gguf` on the CPU | [`Remek/basal-omni-pico`](https://huggingface.co/Remek/basal-omni-pico) · [`-GGUF`](https://huggingface.co/Remek/basal-omni-pico-GGUF) |
185
+ | **basal-omni-1.0-mini** | 4B (Gemma 4 E4B) | decisions about text, images and audio; about 16 GB of GPU memory | [`Remek/basal-omni-1.0-mini`](https://huggingface.co/Remek/basal-omni-1.0-mini) · [`-FP8`](https://huggingface.co/Remek/basal-omni-1.0-mini-FP8) · [`-GGUF`](https://huggingface.co/Remek/basal-omni-1.0-mini-GGUF) · [`-MLX`](https://huggingface.co/Remek/basal-omni-1.0-mini-MLX) |
186
+ | **basal-omni-2.0-mini (preview)** | 4B (Gemma 4 E4B) | typed decisions about text, read two-way; the preview checkpoint that preceded the final E4B mini; about 21 GB of GPU memory (`--mode fast`, H100) | [`Remek/basal-omni-2.0-mini-preview`](https://huggingface.co/Remek/basal-omni-2.0-mini-preview) · [`-GGUF`](https://huggingface.co/Remek/basal-omni-2.0-mini-preview-GGUF) (experimental, one-way) · [`-MLX`](https://huggingface.co/Remek/basal-omni-2.0-mini-preview-MLX) (experimental, one-way) |
187
+ | **basal-omni-1.0-max** | 12B | the default 12B model (Werdykt 0.823); text, images and audio; about 24 GB of GPU memory | [`Remek/basal-omni-1.0-max`](https://huggingface.co/Remek/basal-omni-1.0-max) · [`-FP8`](https://huggingface.co/Remek/basal-omni-1.0-max-FP8) · [`-GGUF`](https://huggingface.co/Remek/basal-omni-1.0-max-GGUF) · [`-MLX`](https://huggingface.co/Remek/basal-omni-1.0-max-MLX) |
188
+ | **basal-omni-1.1-max** | 12B | *experimental task model*: better on `classify`, `verify`, `compress` and `extract`, slightly behind 1.0-max on general decisions (Werdykt 0.821) | [`Remek/basal-omni-1.1-max`](https://huggingface.co/Remek/basal-omni-1.1-max) · [`-MLX`](https://huggingface.co/Remek/basal-omni-1.1-max-MLX) |
189
+ | **basal-omni-1.0-ultra** | 31B (Gemma 4 31B) | highest Werdykt score of the basal models (0.879); text and images (no audio); 59 GB of bf16 weights | [`Remek/basal-omni-1.0-ultra`](https://huggingface.co/Remek/basal-omni-1.0-ultra) · [`-FP8`](https://huggingface.co/Remek/basal-omni-1.0-ultra-FP8) · [`-GGUF`](https://huggingface.co/Remek/basal-omni-1.0-ultra-GGUF) |
190
+
191
+ **basal-2.0** (Bielik-based text models)
192
+
193
+ | model | params | use | Hugging Face |
194
+ |---|---|---|---|
195
+ | **basal-2.0-mini** | 1.5B | fastest; high-volume routing, laptops and small GPUs; context 8,192 tokens | [`Remek/basal-2.0-mini`](https://huggingface.co/Remek/basal-2.0-mini) · [`-FP8`](https://huggingface.co/Remek/basal-2.0-mini-FP8) · [`-GGUF`](https://huggingface.co/Remek/basal-2.0-mini-GGUF) · [`-MLX-8bit`](https://huggingface.co/Remek/basal-2.0-mini-MLX-8bit) |
196
+ | **basal-2.0** | 4.5B | main model: best balance of accuracy and speed; experimental thinking mode | [`Remek/basal-2.0-4.5B`](https://huggingface.co/Remek/basal-2.0-4.5B) · [`-FP8`](https://huggingface.co/Remek/basal-2.0-4.5B-FP8) · [`-GGUF`](https://huggingface.co/Remek/basal-2.0-4.5B-GGUF) · [`-MLX-8bit`](https://huggingface.co/Remek/basal-2.0-4.5B-MLX-8bit) |
197
+ | **basal-2.0-max** | 11B | most accurate; long documents, judging, hard English decisions | [`Remek/basal-2.0-max`](https://huggingface.co/Remek/basal-2.0-max) · [`-FP8`](https://huggingface.co/Remek/basal-2.0-max-FP8) · [`-GGUF`](https://huggingface.co/Remek/basal-2.0-max-GGUF) · [`-MLX-8bit`](https://huggingface.co/Remek/basal-2.0-max-MLX-8bit) |
198
+
199
+ This engine still serves the 2.x models; the answers that change from 2.x are in
200
+ [UPGRADING](docs/UPGRADING.md#answers-that-change). Their `-FP8` ports need sm89+ (basal-omni-1.0: `--mode vllm`, text only).
201
+
202
+ ## Results
203
+
204
+ The Werdykt 2.0 scores of the basal-3.0 and basal-omni-2.0 launch models are in the [Models](#models) tables, and
205
+ each model card gives its full results. The results below are those of the 2.x models.
206
+
207
+ The published Werdykt macro accuracy is 0.823 for basal-omni-1.0-max, 0.821 for the 1.1-max task specialist and 0.879 for basal-omni-1.0-ultra. The model table links each checkpoint and its evaluation.
208
+
209
+ [Werdykt](https://basal.si5.pl/benchmark/): 10 categories in Polish and English, 5,000 decisions whose items are
210
+ not published, one protocol for every model. Each basal-2.0 model against the basal-1.5 model of the same size:
211
+
212
+ | | mini: 1.5 → 2.0 | 4.5B: 1.5 → 2.0 | max: 1.5 → 2.0 |
213
+ |---|---|---|---|
214
+ | Werdykt macro accuracy | 0.607 → **0.618** | 0.721 → **0.729** | 0.773 → **0.784** |
215
+ | calibration error (ECE, lower is better) | 0.086 → **0.035** | 0.068 → **0.060** | 0.074 → **0.044** |
216
+ | decisions/s at 16 clients, bf16, one H100 | 20.5 → **106.4** | 23.0 → **32.2** | 10.2 → **16.2** |
217
+ | English panel (10 public tasks), points | −2.1 | −3.6 | −1.8 |
218
+
219
+ basal-1.5 (4.5B) and basal-1.5-max are measured on SGLang, their fastest configuration. basal-omni-1.0 scores 0.769
220
+ (mini) and 0.823 (max). Hosted API models and larger open decision systems score above basal-2.0 (the
221
+ [board](https://basal.si5.pl/benchmark/)). Intervals, calibration, other benchmarks, speed: [RESULTS](docs/RESULTS.md).
222
+
223
+ ## Quick start
224
+
225
+ The example runs the BF16 basal-omni-1.0-mini on an NVIDIA GPU.
226
+
227
+ NVIDIA GPU, with [uv](https://docs.astral.sh/uv/) in a fresh environment:
228
+
229
+ ```bash
230
+ uv venv --python 3.12 --allow-existing ~/basal-env && source ~/basal-env/bin/activate
231
+ uv pip install torch==2.11.0 --index-url https://download.pytorch.org/whl/cu128
232
+ uv pip install "basal-engine[fp8]"
233
+ basal-serve --model Remek/basal-omni-1.0-mini --mode fast --port 8000
234
+ ```
235
+
236
+ - **`--template-prefix off` for the 4.5B model** (bf16 and `-FP8`); mini and max run with the default.
237
+ - **Install torch first, from the CUDA 12.8 index**: a plain `pip install basal-engine` may take a torch built for a
238
+ newer CUDA than your driver. DGX Spark and B300: the cu130 build ([docs/HARDWARE.md](docs/HARDWARE.md)).
239
+ - **Upgrading from basal 2.x: `uv pip uninstall basal` first.** The package is now `basal-engine` (the same import and
240
+ commands), and the two share their files. What else to check: [UPGRADING](docs/UPGRADING.md).
241
+ - The first start in `--mode fast` compiles the model (several minutes); `--mode fast-nocompile` starts in seconds.
242
+
243
+ Apple Silicon, with the native arm64 Python (`--python 3.12` can take an x86_64 one under Rosetta) and no torch step:
244
+
245
+ ```bash
246
+ uv python install cpython-3.12-macos-aarch64-none
247
+ uv venv --python cpython-3.12-macos-aarch64-none --allow-existing ~/basal-env && source ~/basal-env/bin/activate
248
+ uv pip install "basal-engine[mlx]"
249
+ basal-serve --model Remek/basal-2.0-4.5B-MLX-8bit --mode mlx --port 8000
250
+ ```
251
+
252
+ `uname -m` prints `arm64` in a terminal that does not run under Rosetta (`x86_64` under Rosetta). An environment made
253
+ earlier under Rosetta keeps its x86_64 packages under `--allow-existing`: if
254
+ `grep -l x86_64 ~/basal-env/lib/python3*/site-packages/*.dist-info/WHEEL` lists any, make it once with `--clear` in
255
+ place of `--allow-existing`.
256
+
257
+ Ask questions with curl. Several questions about one state go into one request and share the state; each answer has a
258
+ probability for every option, the chosen key and the confidence ([response](docs/API.md#response)):
259
+
260
+ ```bash
261
+ curl -s localhost:8000/v1/systemone -H 'content-type: application/json' -d '{
262
+ "state": "Klient: od wczoraj nie mogę zalogować się do bankowości internetowej, system pokazuje błąd hasła.",
263
+ "questions": {
264
+ "dept": {"type": "choice", "instructions": "Do którego działu skierować zgłoszenie?",
265
+ "criteria": {"cards": "Reklamacje kart", "online": "Wsparcie bankowości elektronicznej", "loans": "Kredyty"}},
266
+ "urgent": {"type": "noul", "instructions": "Czy klient nie może korzystać z usługi?"}}}'
267
+ ```
268
+
269
+ The answers look like this (example numbers):
270
+
271
+ ```jsonc
272
+ "answers": {
273
+ "dept": {"type": "choice", "choice": "online", "probabilities": {"cards": 0.03, "online": 0.95, "loans": 0.02},
274
+ "confidence": 0.95},
275
+ "urgent": {"type": "noul", "noul": 0.91, "probabilities": {"true": 0.91, "false": 0.09}, "confidence": 0.91}}
276
+ ```
277
+
278
+ `probabilities` lists every option, so the runner-up and its margin are in every answer; `confidence` is
279
+ `probabilities[choice]`, the probability of the chosen option.
280
+
281
+ Other ways to run: [FP8 checkpoints](docs/INSTALL.md#fp8-checkpoints-basal-engine), [in a container (Docker)](docs/INSTALL.md#nvidia-gpu-in-a-container), [vLLM or SGLang](docs/INSTALL.md#vllm-or-sglang-with-bf16-weights),
282
+ [Ollama and llama.cpp](docs/INSTALL.md#ollama-and-llamacpp-gguf), [LM Studio](docs/INSTALL.md#lm-studio-gguf-as-a-decision-model), [Apple Silicon in detail, CPU](docs/INSTALL.md#apple-silicon-mlx),
283
+ [all seven engines compared](docs/INSTALL.md#engines), the [Python client](docs/INSTALL.md#python-client); a JSONL file, serving flags and
284
+ benchmarking your GPU: [SERVING](docs/SERVING.md).
285
+
286
+ ## API
287
+
288
+ `POST /v1/systemone` with a `state` (text or JSON) and named, typed `questions`; every answer has a calibrated
289
+ probability for each option and a `confidence`. Up to 255 options per question (basal-1.x models: 10); several
290
+ questions over one state are answered in one pass. `POST /v1/decisions` takes OpenAI's Decisions API
291
+ ([docs/API.md](docs/API.md#openais-decisions-api-post-v1decisions)).
292
+
293
+ | type | answer | example |
294
+ |---|---|---|
295
+ | `choice` | distribution over named options (up to 255) | route a ticket, pick the applicable rule, the intent among 150 |
296
+ | `noul` | probability of *yes* (with optional descriptions of both sides) | "was the appeal filed on time?" |
297
+ | `score` | distribution over ordered levels + expected level | urgency 0–3, severity, grade of an answer |
298
+ | `multi` | independent probability per label + the selected set | "which of these issues does the message raise?" |
299
+ | `act` | the action with the lowest expected cost under your cost matrix | approve / reject / send to a person |
300
+ | `tool` | the next tool from OpenAI / MCP tool definitions, or answer directly / ask the user / no suitable tool | the next step of an agent |
301
+
302
+ To send uncertain decisions to a person, use `act` or `tool` with `"max_error": 0.05`: the answer says
303
+ `"deferred": true` below the certified confidence threshold. Every field and question type, using the confidence and
304
+ how to ask: [docs/API.md](docs/API.md). Python client alone (`pip install basal-sdk`, no torch):
305
+ [clients/python](clients/python/README.md); TypeScript client: [clients/typescript](clients/typescript/README.md).
306
+
307
+ ## Images and audio: basal-omni (experimental)
308
+
309
+ The basal-omni models answer the same questions; with `--media on` a request may also carry images and audio (`"media"`):
310
+
311
+ ```bash
312
+ uv venv --python 3.12 --allow-existing ~/basal-env && source ~/basal-env/bin/activate
313
+ uv pip install torch==2.11.0 torchvision==0.26.0 --index-url https://download.pytorch.org/whl/cu128
314
+ uv pip install "basal-engine[media]"
315
+ basal-serve --model Remek/basal-omni-1.0-mini --mode eager --media on --port 8000 # or Remek/basal-omni-1.0-max
316
+ ```
317
+
318
+ They were trained on text decisions only: Gemma 4's encoders read the media zero-shot and the answers use the text
319
+ calibration, so validate them on your own media. Request format and limits:
320
+ [INSTALL](docs/INSTALL.md#images-and-audio-basal-omni-experimental); memory and engine details: [OMNI](docs/OMNI.md).
321
+
322
+ ## MCP: basal as a tool for agents
323
+
324
+ *Experimental.* With the `basal-engine[mcp]` extra, `basal-serve --mcp on` also serves the decisions over the
325
+ [Model Context Protocol](https://modelcontextprotocol.io) at `/mcp` (tools `decide` and `decide_many`); `basal-mcp` is
326
+ a stdio bridge for hosts that start local processes. Protect HTTP and MCP requests with `--api-keys PATH` or bind to
327
+ `127.0.0.1` ([SERVING](docs/SERVING.md#api-access), [MCP](docs/MCP.md)).
328
+
329
+ ```bash
330
+ uv pip install "basal-engine[fp8,mcp]"
331
+ basal-serve --model Remek/basal-2.0-4.5B --mode fast --template-prefix off --host 127.0.0.1 --port 8000 --mcp on
332
+ claude mcp add --transport http basal http://127.0.0.1:8000/mcp # Claude Code; other hosts take the same URL
333
+ ```
334
+
335
+ ## Documentation
336
+
337
+ | | |
338
+ |---|---|
339
+ | [INSTALL](docs/INSTALL.md) · [SERVING](docs/SERVING.md) | engines, model files and every install path; serving modes and flags, a JSONL file, benchmarking your GPU |
340
+ | [API](docs/API.md) · [QUESTION_TYPES](docs/QUESTION_TYPES.md) · [FEATURES](docs/FEATURES.md) | request, response, using the confidence, how to ask; every question type on one page; `multi`, `act`, `tool` and evidence in detail |
341
+ | [CALIBRATION](docs/CALIBRATION.md) · [FINETUNE](docs/FINETUNE.md) | calibrating on your own data; LoRA on your own labelled decisions (`basal-finetune`) |
342
+ | [TASKS](docs/TASKS.md) · [NAVIGATE](docs/NAVIGATE.md) | *experimental*: `classify`, `verify`, `compress`, `extract`; `rank` and `basal-navigate` (retrieval by navigating a document tree) |
343
+ | [BACKEND](docs/BACKEND.md) · [MCP](docs/MCP.md) | basal-serve as the local backend of code that asked a hosted LLM for decisions; the MCP server and bridge |
344
+ | [RESULTS](docs/RESULTS.md) · [THINKING](docs/THINKING.md) | results against basal-1.5: Werdykt, other benchmarks, speed; the experimental thinking mode |
345
+ | [OMNI](docs/OMNI.md) · [HARDWARE](docs/HARDWARE.md) · [OLD_GPUS](docs/OLD_GPUS.md) | basal-omni on the engine; which mode on which GPU; GTX 10xx, RX 480 / 580, Iris Xe with llama.cpp's Vulkan backend |
346
+ | [FORMATS](docs/FORMATS.md) · [FORMAT2](docs/FORMAT2.md) · [SOAM](docs/SOAM.md) | prompt formats, option orders and calibration files; the runtime contract; shared-state packing |
347
+ | [PORTS](docs/PORTS.md) · [GGUF](docs/GGUF.md) · [QUANTIZATION](docs/QUANTIZATION.md) | MLX and GGUF ports; FP8 and other low precision |
348
+ | [WHATS_NEW](docs/WHATS_NEW.md) · [UPGRADING](docs/UPGRADING.md) · [CONTRIBUTING](CONTRIBUTING.md) · [basal-1.0 report](docs/basal-1.pdf) | every release's changes; upgrading from 2.x to 3.0; development commands, checks and release-note fragments; the basal-1.0 technical report |
349
+
350
+ **Community projects:** [basal-lite](https://github.com/lukaszpodgorski-pl/basal-lite) by @lukaszpodgorski-pl serves basal
351
+ models from a stock `vllm serve` through a thin client (community-maintained, not verified by us).
352
+
353
+ ## Limitations
354
+
355
+ - Evaluated on held-out and hidden test sets and on public benchmarks; validate claims about a specific document
356
+ collection on your own data. Decisions with serious consequences for people should be reviewed by a person.
357
+ - On a panel of 10 public English decision tasks all three basal-2.0 models are below basal-1.5 (−2.1 / −3.6 / −1.8
358
+ points for mini / 4.5B / max); basal-2.0-mini is also below basal-1.5-mini on Polish decisions (−1.4 points).
359
+ - The calibration is cautious on unseen tasks: `max_error: 0.01` defers every decision with the shipped files (except
360
+ `choice` with `basal-2.0-max-GGUF`'s `CALIBRATION.ollama.json`, confidence 0.989); use 0.05 or fit thresholds on your
361
+ data. At the 1% target on Werdykt, basal-2.0 (4.5B) and max automate fewer decisions than basal-1.5.
362
+ - A small model's Polish world knowledge is limited, and it does not know rules introduced after its training: supply
363
+ the facts and rules in the state. Compute exact arithmetic and thresholds in code, or use `"facts": "auto"` for
364
+ Polish dates and amounts. basal-2.0-mini has an 8,192-token context; longer states are cut in the middle.
365
+ - Experimental: the thinking mode (less accurate, less calibrated and slower on Werdykt); `act`, `tool`, `multi` over
366
+ many labels and evidence spans; the task types (`automated` needs task thresholds: only basal-omni-1.1-max ships one,
367
+ `classify` at 5%); basal-omni's images and audio, read zero-shot by Gemma 4's encoders with the text calibration.
368
+
369
+ ## Previous releases
370
+
371
+ basal-1.5 and basal-1.0 remain on Hugging Face and are served unchanged by this engine: [previous releases](docs/WHATS_NEW.md#previous-releases-basal-15-and-basal-10).
372
+
373
+ ## Citation
374
+
375
+ ```bibtex
376
+ @software{kinas2026basal20,
377
+ title = {basal-2.0: typed-decision models and inference engine for Polish and English},
378
+ author = {Kinas, Remigiusz},
379
+ year = {2026},
380
+ version = {2.0.0},
381
+ url = {https://github.com/rkinas/basal}
382
+ }
383
+
384
+ @techreport{kinas2026basal,
385
+ title = {basal-1.0: Reliable, Highly Optimized Typed Decisions for Polish},
386
+ author = {Kinas, Remigiusz},
387
+ institution = {ai5},
388
+ year = {2026},
389
+ type = {Technical report},
390
+ doi = {10.5281/zenodo.23022986},
391
+ url = {https://doi.org/10.5281/zenodo.23022986}
392
+ }
393
+
394
+ @software{kinas2026basalomni10,
395
+ title = {basal-omni-1.0: typed-decision models for text, images and audio in Polish and English},
396
+ author = {Kinas, Remigiusz},
397
+ year = {2026},
398
+ version = {1.0},
399
+ url = {https://huggingface.co/collections/Remek/basal-omni-10-6acea28e8b5baed2db475c1f}
400
+ }
401
+ ```
402
+
403
+ ## Contributors
404
+
405
+ Thank you to [Paweł Kiszczak](https://github.com/pawelkiszczak), [Piotr Durlej](https://github.com/pdurlej), [Kuba Sołtys](https://github.com/qooba),
406
+ [Michał Kardyś](https://github.com/kardysm), [@lukaspoloki](https://github.com/lukaspoloki), [Miłosz Kucharski](https://github.com/Butterski),
407
+ [Grzegorz Brzezinka](https://github.com/agentGreg), [@piotrkowski](https://github.com/piotrkowski), [@lukaszpodgorski-pl](https://github.com/lukaszpodgorski-pl),
408
+ [Marcin Brzeżański](https://github.com/marcinbrzezanski), [Grzegorz Stark](https://github.com/gstark0), [Dariusz Koryto](https://github.com/dkoryto) and
409
+ [Rafal Wiktorowicz](https://github.com/onlypositivetravelvibes-dotcom), whose pull requests are in this repository, and to [Kamil](https://github.com/kamilrosa) and [@krzysztofkaminski](https://github.com/krzysztofkaminski) for their measurements.
410
+ What each one contributed, by pull request: [CONTRIBUTING](CONTRIBUTING.md#contributors-by-pull-request). `--mode tpu`
411
+ and `--mode strix` are community-maintained: their numbers in [HARDWARE](docs/HARDWARE.md) are the contributors' own.
412
+
413
+ ## License
414
+
415
+ Apache-2.0. The models are derivatives of Apache-2.0 base models (Bielik v3, SpeakLeash and ACK Cyfronet AGH, for
416
+ basal-2.0; Gemma 4, Google, for basal-omni); see [NOTICE](NOTICE).
@@ -0,0 +1,111 @@
1
+ basal/__init__.py,sha256=FvcZC-c7zw9GUG9f0XswN-odbI0QEGpoSy4vrwFEkUY,423
2
+ basal/adapter.py,sha256=Jc419Xptzj_5HjDqequhu9MWcnwq1NatM98dMoHscVQ,21054
3
+ basal/adapters.py,sha256=6AtFHewQkpWgsHURPYt8t83i6AJsOeR6xwae2Nm20sc,368
4
+ basal/agree.py,sha256=z5CGcMDf02mvS7C0HVruqyPq6YG_EdfUihHYEhckxJk,20360
5
+ basal/attach.py,sha256=UB66C0UKS1VK8VJy9QD-7XwD36CVD3XzCX7TH9fHWVA,9501
6
+ basal/attn512.py,sha256=EFTQiH2N-1o7JaSILvLq_DT0aeDhSM6yP2B8ozXZwXo,7075
7
+ basal/auth.py,sha256=V9dWSrFb0p42wWkDgyGBG8rb_fk4QYTypGz1qmzNVcY,8896
8
+ basal/bench.py,sha256=O3HTvOqYgGf8p4-qL28J6VqxWD7t6TkPvueRIkTBVaE,18821
9
+ basal/blockquant.py,sha256=fhShcKZR7mI_k5s4i8ou2aAqCJfujCAAsitTxgNMPQw,11676
10
+ basal/calibrate.py,sha256=ca4fVzlwSls1mjITwYxTGdyp-I4wfQXHGukf4vd6PQ8,132345
11
+ basal/chat.py,sha256=2t7KWdmxBZZ_IcsV-kBwkSN1HqlicHfxWPtVAWu-Dzs,10549
12
+ basal/cli.py,sha256=LF5hOwLx-UaTjpdqkPynWr7Qeo8u8A55nfyvG3arYGo,3081
13
+ basal/client.py,sha256=1k27XVx8JbFp2UNOMxDFZQa18B5pZ4BTxG9EGifLE-w,356
14
+ basal/decision_log.py,sha256=3Szc5m1qjHlg03_TmiL0FwEstL9LcqfNpvFU_f2PD6c,10952
15
+ basal/decision_rules.py,sha256=5wR2twlSuMSYA02WZ_c2NiqG7bBZedzedUNRfnvvHFE,33174
16
+ basal/decisions.py,sha256=EKHoPJ32iDxjMZAKXPDjgzAeKPV1YxHA02Ocp6zEmO4,8457
17
+ basal/derive.py,sha256=Rt7aA7lMEluJ1M4_9ILij-_GaLxyxZUjDicvW5EQoUg,5641
18
+ basal/disconnect.py,sha256=MEnxnbUrHxqDIuGmP9IXfZ125-CVMbB_1XD1XMA2pvs,4400
19
+ basal/engine.py,sha256=og2Peh0nlbXiHG1INw1HFx1kz2hLryp92u1p4c3Xqoo,367427
20
+ basal/evidence.py,sha256=j--WQdmAcWB5LoqZwYoTJIva5bv-2RbE6W3EFSqPlsI,6592
21
+ basal/facts.py,sha256=QOOtmk0dwwanmbqfklZEEJz945a12oSao1K_OeAr3kc,23890
22
+ basal/feedback.py,sha256=vTzT5bvTFAxfNjtx_nOJ4Xxy1wgUuM2PtvuoNzKUBRk,12125
23
+ basal/file_identity.py,sha256=qH_c-CHcBLQTsCpT5lrt8yrRD8FDOORW7c7DzvOq8Rw,1368
24
+ basal/finetune.py,sha256=Jv0pd5_tV4h2YJfoXuMQTfJc3ksBYs7mHkQTC361tjQ,17036
25
+ basal/fit_decisions.py,sha256=kz2k2d9jFCazDkJd0nSmLVK559rets9VKi5V6--cWRY,49607
26
+ basal/fla_configs.json,sha256=Z8epvBdImlCfyNSiie47OczFsKX8_PweS3AL6WUbbBk,28754
27
+ basal/fold.py,sha256=io9HK3UR2Bo2kLXJODWFdHXjki0rZPpqhnAAd2ugK8E,12307
28
+ basal/fp8block.py,sha256=enYrzb2TG5DStwtJfUUShoenoYcdCpWjMQkQD8wH61E,4937
29
+ basal/gdn_graph.py,sha256=Aq0SZgr5bOIIfkH3TKnX9fT6FjIR0LR2EwCLvKuuFuk,106135
30
+ basal/gemma4.py,sha256=v-XtWD3oyF_koYq5LKa-uFE4GT1CMgCDRxbuQuy53Z0,44613
31
+ basal/gemma4_graph.py,sha256=ZdhboD9i0-yl6E2A1OmCOAZFar9dV-f2MtcGVEw0XBE,53567
32
+ basal/gguf_export.py,sha256=wp6mReL-MhNmEFbON9N32kZr4YTUPYf3HS0OiTHlEf4,30068
33
+ basal/identity.py,sha256=vOpsO9BSM2s8ojE_BUXnvHckMjqfQAi28Rmeqr5hp24,14484
34
+ basal/int8block.py,sha256=I6o3Yav9R5CDoF4qhdhMrHkgb61_TiyvWOjvlvbNGio,2869
35
+ basal/interpolate.py,sha256=l_kJOT-S2iTK6Em_7SgoBjk5t7Sle_MfH5U9k6ExieE,18572
36
+ basal/jsonl.py,sha256=DB-xA4UHWL085YDbntQo3Hn6YW5_Nhtd3DMv7SGHuEE,7923
37
+ basal/lean.py,sha256=d_iagSccUjPdM3ytZhvHDg6cCcaad-SKTYXyHcwaj6Y,11086
38
+ basal/llama_attn.py,sha256=A0lUZc8WOur-1WbrY5E0gxnpirsHNT7mFwPlQcDKkOI,12512
39
+ basal/llama_attn_kernels.py,sha256=s7Kd5cMH7koqdEekXhWMoGk4kvWN4shSure3k4fFzeE,13065
40
+ basal/llama_graph.py,sha256=rs9-3OE2tddfIgPc6WGSpO-ZFd5qiINkJ6X1PXSZX5A,27951
41
+ basal/llama_kernels.py,sha256=csDTiIqRxVCHYV2oTWjJr4baMTC4GtPkQFlYNa2Lsi0,27309
42
+ basal/loadtest.py,sha256=PTLp07a6j77yqe1gMZ7Sup_UqoItjUeudtjfoxIaxDE,10186
43
+ basal/mcp_server.py,sha256=38zskO4lJKXom19xt2oFdEqezv_SkQgIX1oP1m9Ej3s,24083
44
+ basal/media.py,sha256=syUs785fjDppQCMnpAwe7XBTWUuJsCz60lMmDt4wQ4Q,7696
45
+ basal/metrics.py,sha256=zEUAtpHvfHjQIEsu87OlRDMdsrKhVMi07ccCUWMFmIk,923
46
+ basal/mlx_attn_kernels.py,sha256=uZvduKnAybGUigWfUBhveNqzXweML10uz48yJDO1ZtA,39978
47
+ basal/mlx_forward.py,sha256=Lm25CcTj12fqY134K7y200kr7YnfLA5FzZmcggludpQ,17494
48
+ basal/mlx_kernels.py,sha256=80xGoshLr-EwwyCACw_0cU6_M1Gy0JAT4Zm0Nnx_vF8,18523
49
+ basal/mlx_metal.py,sha256=WyeD2TXOVqiGpwhX2bq-874XotI6RlOjeqPxGM6XyUw,26266
50
+ basal/navcut.py,sha256=13vR0rsrIuKVKnQdi_chOtEIYgYN882cbPfK_pbxTT4,15847
51
+ basal/navigate.py,sha256=oK38tRPHONF7l11ghxmDfs2mbKmcZLAuF7wg1O2YRgg,38771
52
+ basal/navtree.py,sha256=eXl8VGCNTjV96RA00tQZyeEk2dG0-W8iS1r6LlHxemY,20301
53
+ basal/nvfp4.py,sha256=NhKbX-hOA4vQXklqGkqfnGw45sWU2ZyKT_fpMTk4Ofw,11987
54
+ basal/ordercheck.py,sha256=SJeJhlZR0wVKufwTIFYEXN4POXR4mC1AR5Z9YimAmTg,7862
55
+ basal/pdf.py,sha256=KjIVuXP1jwNIzNxs6nwn3hb1YMLoXrd1k9qzmzP_5AU,8421
56
+ basal/prepared.py,sha256=DTLtwcMV_BrrikO2W76fJ7CdubXxGlqzDK7HuiIsLV4,19420
57
+ basal/presets.py,sha256=kRI4IS99UcDefBb3ZWAaf1KUWWHgSUmleb3V_J2XEaI,362
58
+ basal/prompt.py,sha256=PtXgZXxZIYAgVJOcTEzF9GaCYtd9HF8XFXDFXPi4zrs,24565
59
+ basal/rank.py,sha256=nxvveLaHvcyX6gdWEQmvHkdSc1hPyWagjnKgX0jixSg,20108
60
+ basal/readout.py,sha256=htfizgMlZVyLKkeZU1fqgcQlFWHhf-wBjUdmqTvzZfA,5738
61
+ basal/request.py,sha256=APV1zspZ3gCWUlW1ptBwx8mF8LzlSzsM0tbGnDo4KxE,16356
62
+ basal/response_cache.py,sha256=X7iS0WD-NjXj2sDJf5Co5XYuv0TVIlBaf_8RCVAVQfM,5819
63
+ basal/router.py,sha256=7o8Cl1jOD8IQy6XuF8xsUBI8aDY6F7MJUGReGDemkrY,94604
64
+ basal/router_ui.html,sha256=4dB9uZTgd9GecAoHkjaHvxhA2DUKT42nstdQ0iXDpx4,62227
65
+ basal/router_ui.py,sha256=z-CFyIEmoYg1GJNjiwP80nAfNnHOUAAcN8jE1Vv448k,15402
66
+ basal/run.py,sha256=G4bf8SADYlt3tV6WONZqadKWvXBIjw9y8s5y8KKIrLU,18712
67
+ basal/selfcheck.py,sha256=OrEsby0Mm-78BZjenp5ScaMnuHA5fSXvtJX2-2dyNnk,12390
68
+ basal/server.py,sha256=uomtjsgQSSXaBe3Nd1u0qwYfqlhaNyWbS4cuFXKFvyE,344025
69
+ basal/sets.py,sha256=LVgEa35xi0qoL28U1vwwVWWh_rH52uC9zbw4TKpUwTI,11841
70
+ basal/signals.py,sha256=mkp_xMSKNQFyjTKsALO174ZJBKVoUmUqyfaNBtoTnNM,1436
71
+ basal/state_disk.py,sha256=fC-1Ccx_bF8eF-AZcg-feRhvJv0bHBEEQyzJgmUYxKA,47409
72
+ basal/strix.py,sha256=Tsa-233XZC49Uam38976Px9jua0aDLb7F2Qh29eEAcU,28670
73
+ basal/synth.py,sha256=pf3X8fZTmlRhuO7KnnlzVTjYw9N3NV7aINST547ewpM,5229
74
+ basal/tasks.py,sha256=8pWFXzDKLwjFZdZm9VAb4Len-R7K3PIHd0sV_kVqb48,45248
75
+ basal/textio.py,sha256=JikgqoD6O_lDz8VWPeyt1kvWcuWYJ21IJb6ttSNjKjY,891
76
+ basal/think.py,sha256=kLEXBE3Knksoo8nF23sGztZELkWSCwbnj2FYjedZnAk,22304
77
+ basal/tools.py,sha256=k1uGABA1_JKXCW27iRzcJPYMP3ueWPafh_xDlFL_egw,9989
78
+ basal/tpu.py,sha256=AnymfYQFnaD0XJP9opy2VSXxE4LcOxEO2p3uUNQsHhY,17445
79
+ basal/tpu_kernels.py,sha256=7ySQ13fV51LSOmbFxLLFDTfvzAZHckBd_BTXwxcK4LE,6691
80
+ basal/trace.py,sha256=cDG6In6YXdubpVlVoy-MRhkvHuP8oz1Ya-PkKE3Fhtg,7838
81
+ basal/ui.html,sha256=QHcRS2bdzAlYyHlQweNwVeSRs9x0FhUZEXZ_ucZRRbU,55732
82
+ basal/ui.py,sha256=UN1AWjffjLjLPTBKiLRc_wXANXVeWkj7X0Nz-xXJkvA,28629
83
+ basal/varloop.py,sha256=L6engylJBJ3Dcd5gSF2X7brjvUpM1O3fcnWf8rhu4hc,41617
84
+ basal/varloop_graph.py,sha256=1cZ2U3ywO4BanGdFKiMIA0_bCM-uqgIfUEodT71rZuE,69994
85
+ basal/varloop_kernels.py,sha256=dfpA6pVQ4_5WVOJKmp5J4sOCtMfaTDcLubKN9rShzjw,42122
86
+ basal/viz.html,sha256=2mYcEjC3xecHr2Bh2ZJwnNptn3w-0LD09Bgix9g3uwM,48016
87
+ basal/viz.py,sha256=qQeKVp7B5BUF-rOC9-weLITdHoW1GFfwHoHK0_2OeyU,19287
88
+ basal/vllm_unified.py,sha256=UfVevns6J6ZwmKdAafely71e7SKpG1rgB4XzhtU3Ggs,5247
89
+ basal/examples/choice.jsonl,sha256=nDaHUMvYfi7qkznSUceW0ZGT3yzvxfHp6WgddxCU_UQ,2742
90
+ basal/examples/complex.jsonl,sha256=IxhT6hEkj9CgkTZWJi-IfCXHcH5mDpxXo85kwxsg3y4,4346
91
+ basal/examples/labelled_tickets.jsonl,sha256=zdXymmLDFv7yOz5i3nIZW1HGGO7JkTbDaHlxDrB-2IE,242990
92
+ basal/examples/local_backend.py,sha256=bpLmUNX2XIfe-in2HmFoXFAFfF3GYUpxsuYpooaGzig,1334
93
+ basal/examples/noul.jsonl,sha256=M9HwNvFF8SHn1HNR3bm2wZ7GDjxNTuDm5Pov5S9FYZQ,2894
94
+ basal/examples/questions.jsonl,sha256=ffRadD3z6iHxF-qYnYGmfv9fDdycEGdJ3YTfGT7ZzRM,5999
95
+ basal/examples/score.jsonl,sha256=UxkA0OHbeiR1uEPB6kpqTuvShDHZLJh4BLG_U5y9lzc,2424
96
+ basal/examples/selfcheck_basal-omni-pico-Q8_0.json,sha256=s5h_0DOGqhEGVCTWQf6Cqk19qH3YumicIlB12wqQrYc,35576
97
+ basal/examples/selfcheck_basal-omni-pico.json,sha256=jmKTSQOi08OsnJU_2nOTMOwyR7ExPjaQLZxS91CmxVo,37681
98
+ basal/examples/types_demo.py,sha256=IloVPQups7ff4WuBImYdNeTzT9giCWqO8yonNLYDFEk,4666
99
+ basal/fonts/OFL-DMSans.txt,sha256=b70ECinCA3p2XfufJWHplltclcbctdzlFgidY9Xxevc,4502
100
+ basal/fonts/OFL-SpaceGrotesk.txt,sha256=GKTeUjhfa5iHgmOdXQzBMm5ajC3pp_AdeyDZrtzGCUM,4401
101
+ basal/fonts/dm-sans-latin-ext.woff2,sha256=pdOP6Z-TAnVoSZm0YscSP6oGPZ5E5ztLJBcj2ISqD0k,18228
102
+ basal/fonts/dm-sans-latin.woff2,sha256=n-pgipR-ZwIMM8rZpv49YMVBGd-4z_h3aKgRehXtdUM,36932
103
+ basal/fonts/space-grotesk-latin-ext.woff2,sha256=lS3dtF0vlvccvzt_UQskN5r8PInqAvz4nTd7RdYsAWY,18940
104
+ basal/fonts/space-grotesk-latin.woff2,sha256=BkCJBHb8EZirTeVx-2WN5EPE2FtmRm7AlTSoc3qxzp0,22288
105
+ basal_engine-3.0.3.dist-info/licenses/LICENSE,sha256=z8d0m5b2O9McPEK1xHG_dWgUBT6EfBDz6wA0F7xSPTA,11358
106
+ basal_engine-3.0.3.dist-info/licenses/NOTICE,sha256=2kHvCyks-KCisY0-7Ut13DrDxk5-byJq-aEgwHaGboE,2623
107
+ basal_engine-3.0.3.dist-info/METADATA,sha256=aU16TwqhfB749LZ7qO-KtXou8okss1FGdQcDcrxdew0,32312
108
+ basal_engine-3.0.3.dist-info/WHEEL,sha256=mOdXR9C3wMVov7cSY8PY-XCzo3SmmWCHvGQr5csJoao,91
109
+ basal_engine-3.0.3.dist-info/entry_points.txt,sha256=le_FThu4kORR4x5QJV0x5471kIWZRK0boM2I9ZseMRQ,742
110
+ basal_engine-3.0.3.dist-info/top_level.txt,sha256=2cZ8cpWBEXaQuZY2FDJaM4Ekh4bJ16rtuPnDXtFQk8g,6
111
+ basal_engine-3.0.3.dist-info/RECORD,,
@@ -0,0 +1,5 @@
1
+ Wheel-Version: 1.0
2
+ Generator: setuptools (84.2.1)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+
@@ -0,0 +1,21 @@
1
+ [console_scripts]
2
+ basal-agree = basal.agree:main
3
+ basal-attach = basal.attach:main
4
+ basal-bench = basal.bench:main
5
+ basal-calibrate = basal.calibrate:main
6
+ basal-export-gguf = basal.gguf_export:main
7
+ basal-feedback = basal.feedback:main
8
+ basal-finetune = basal.finetune:main
9
+ basal-fit-decisions = basal.fit_decisions:main
10
+ basal-fold-temperature = basal.fold:main
11
+ basal-fuse-adapter = basal.adapter:main
12
+ basal-interpolate = basal.interpolate:main
13
+ basal-loadtest = basal.loadtest:main
14
+ basal-mcp = basal.mcp_server:main
15
+ basal-navigate = basal.navigate:main
16
+ basal-prepare = basal.prepared:main
17
+ basal-router = basal.router:main
18
+ basal-run = basal.run:main
19
+ basal-selfcheck = basal.selfcheck:main
20
+ basal-serve = basal.server:main
21
+ basal-viz = basal.viz:main