lumma-fev
Run FrontiersMind Lumma-Fev decision models: give a document (the state) and typed questions, and get a probability distribution for every question in one forward pass. No text is generated, so there is nothing to parse.
lumma_fev.load(): run a model locally (cuda, mps or cpu).lumma-fev-serve: a TypeSafe-compatible HTTP API (POST /v1/systemone), so existing TypeSafe clients work by changing their base URL.lumma_fev.Client: a small client for that API.
Models (pass the Hub id or the short size to load() and --model):
| Size | Hub id | Notes |
|---|---|---|
0.1b |
FrontiersMind/Lumma-fev-0.1b | default; runs on a CPU |
0.6b |
FrontiersMind/Lumma-fev-0.6b | |
4b |
FrontiersMind/Lumma-fev-4b | |
9b |
FrontiersMind/Lumma-fev-9b | |
27b |
FrontiersMind/Lumma-fev-27B | about 55 GB of GPU memory in bf16; also accepts images |
Install
pip install lumma-fev # local inference and the client
pip install "lumma-fev[serve]" # plus the API server
pip install "lumma-fev[large]" # plus accelerate, for device_map="auto" (27B on several GPUs)
pip install "lumma-fev[images]" # plus Pillow and torchvision, for image states (27B)
Run locally
import lumma_fev
model = lumma_fev.load() # FrontiersMind/lumma-fev-0.1b; load("FrontiersMind/<repo>", revision=...) for others
answers = model.decide(
state="I was charged twice for my March invoice. Please refund one of them.",
questions={
"billing": {"type": "noul", "instructions": "Is this about billing?"},
"team": {"type": "choice", "instructions": "Which team should handle this?",
"criteria": {"billing": "Payments and refunds", "shipping": "Delivery problems", "technical": "Bugs and outages"}},
"urgency": {"type": "score", "instructions": "How urgent is this?",
"criteria": ["can wait", "this week", "today"]},
},
)
# {"billing": {"noul": 0.97}, "team": {"choice": "billing", "confidence": ..., "probabilities": {...}},
# "urgency": {"score": ..., "confidence": ..., "legend": [...], "probabilities": {...}}}
load(model, revision=None, device=None, dtype=None, device_map=None) picks cuda, then mps, then cpu, and uses bf16
on accelerators and fp32 on cpu (27B always defaults to bf16, the dtype it is stored in). The sizes up to 9B also load
with transformers alone: AutoModel.from_pretrained("FrontiersMind/lumma-fev-0.1b", trust_remote_code=True).
Lumma-fev-27B
model = lumma_fev.load("27b") # one GPU with about 55 GB free (an 80 GB card)
model = lumma_fev.load("27b", device_map="auto") # or spread over several GPUs (pip install "lumma-fev[large]")
model.decide("My integration keeps failing. Please help.",
{"team": {"type": "choice", "instructions": "Which team should handle this request?",
"criteria": {"billing": "Charges and refunds", "support": "Technical integration errors",
"sales": "Questions about buying a product"}}})
# {"team": {"type": "choice", "choice": "support", "confidence": 0.99..., "probabilities": {...}}}
model.decide("What is shown?", {"red": {"type": "noul", "instructions": "Is the product red?"}},
images=["photo.png"]) # paths, PIL images or data: URLs (pip install "lumma-fev[images]")
27B uses a different checkpoint format from the smaller sizes (a Qwen3.5 backbone plus a readout over answer codes);
load() detects it from the repo's decision_config.json, and the call and the answers are the same. Its prompt
follows the AutoJev reference code bundled in the repo, so probabilities match
it. A question plus the state must fit in 8,192 tokens (nothing is truncated: longer input raises ValueError), and
score questions need at least two levels. 27B was trained on noul and choice questions only, so check score answers on
your own data. For speed, install the optional flash-linear-attention and causal-conv1d kernels; without them
transformers falls back to slower PyTorch code.
Serve an API
lumma-fev-serve --model FrontiersMind/lumma-fev-0.1b --host 0.0.0.0 --port 8000
lumma-fev-serve --model 27b --host 0.0.0.0 --port 8000 # add --device-map auto for several GPUs
| Flag | Default | |
|---|---|---|
--model |
FrontiersMind/lumma-fev-0.1b |
Hub id or local folder |
--revision |
latest | branch, tag or commit |
--name |
repo name | model name reported by the API |
--host, --port |
127.0.0.1, 8000 |
use 0.0.0.0 to accept other machines |
--device, --dtype |
auto | cuda/mps/cpu, bf16/fp16/fp32 |
--device-map |
none | auto to spread a large model over several GPUs (needs lumma-fev[large]) |
--api-key |
$LUMMA_FEV_API_KEY |
when set, requests need Authorization: Bearer <key> |
--cors |
off | allow browser pages on any origin |
Endpoints: POST /v1/systemone, GET /v1/models, GET /health. Requests run one at a time. With 27B, a request
may also carry "images": [...], up to four base64 PNG, JPEG or WebP data: URLs.
curl -s localhost:8000/v1/systemone -H 'content-type: application/json' -d '{
"state": "I was charged twice. Please fix this ASAP.",
"questions": {"billing": {"type": "noul", "instructions": "Is this ticket about billing?"}}
}'
# {"model": "lumma-fev-latest", "answers": {"billing": {"noul": 0.98}}, "usage": {"input_tokens": 31, "output_tokens": 9}}
Call it from Python
from lumma_fev import Client
with Client("http://127.0.0.1:8000", api_key=None) as client:
print(client.decide("I was charged twice.", {"billing": {"type": "noul", "instructions": "Is this about billing?"}}))
print(client.models())
client.system_one(...) returns the full response (model, answers, usage); errors raise lumma_fev.LummaFevError
with the HTTP status and detail.
The TypeSafe SDK works against the same server:
from typesafe_sdk import Noul, TypeSafeClient
with TypeSafeClient(api_key="local", base_url="http://127.0.0.1:8000") as ts:
result = ts.system_one(state="I was charged twice.", questions={"billing": Noul(instructions="Is this about billing?")})
print(result.nouls["billing"].noul)
The SDK always sends an API key; any value works when the server has no --api-key.
Questions and answers
| Type | Criteria | Answer |
|---|---|---|
noul |
optional {"true": ..., "false": ...} |
noul: probability of yes |
choice |
{name: description or null}, 1–255 options |
choice, confidence, probabilities by name |
score |
ordered list of 1–255 levels (2–255 for 27B) | score (expected level), confidence, legend, probabilities by level |
state and instructions can be text or any JSON value. Each question reads the state and its own instructions and
options only, so questions never influence each other. Up to 9B, long states are truncated to the model's context (see
the model card); 27B rejects input over 8,192 tokens instead.
License
Apache-2.0. See LICENSE and NOTICE.
Metadata
Release files for lumma-fev 0.2.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 | Provenance | Actions |
|---|---|---|---|---|
| lumma_fev-0.2.0.tar.gz | 16.6 kB | Without provenance | Details for lumma_fev-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| lumma_fev-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for lumma_fev-0.2.0-py3-none-any.whl |
Total release size: 36.9 kB
Release files / lumma_fev-0.2.0.tar.gz
| Download URL | lumma_fev-0.2.0.tar.gz |
|---|---|
| Size | 16.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
60a9b79cd91d7e3fbdaf18c9a16573e1273dd9959eb2c1639e9c6a95401e8c87
|
|
BLAKE2b-256 checksum How to use checksums |
f77914ba3c2ce9d329315fa3cba909889ab9a13d24e28f1e231c3e40df648c13
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.7
|
Release files / lumma_fev-0.2.0-py3-none-any.whl
| Download URL | lumma_fev-0.2.0-py3-none-any.whl |
|---|---|
| Size | 20.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ac8e5f9380b3ea3591ae7b2eb075b2ca28d2d362038267548636e91352b19a91
|
|
BLAKE2b-256 checksum How to use checksums |
eb846e3730bb2e2fc546fb47827623746909dadc7ee11888224b8788492b65f5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.7
|
Security for lumma-fev 0.2.0
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.