Views
No views yet
AutoModelForImageTextToText.1import torch
2from transformers import AutoModelForImageTextToText, AutoTokenizer
3
4REPO = "CrowtherLabs/atom-proton-1.0"
5
6model = AutoModelForImageTextToText.from_pretrained(
7 REPO,
8 dtype=torch.bfloat16,
9 device_map="auto",
10)
11model.eval()
12
13tokenizer = AutoTokenizer.from_pretrained(REPO)AutoModelForCausalLM instead only if you intend to drop the vision tower and
serve the text-only decoder.quantization_config to fit a smaller one.transformers does not ship. Without
it you will see The fast path is not available ... Falling back to torch implementation and noticeably slower inference. Install
flash-linear-attention and
causal-conv1d to enable it.xhigh reasoning effort, which is the setting it was
adapted under. The chat template resolves effort as follows:| value | effect on the system prefix |
|---|---|
| omitted | defaults to xhigh |
xhigh | full deliberation instruction |
high | alias for xhigh, identical output |
medium | no instruction line at all |
low | brief-thinking instruction |
1messages = [
2 {"role": "system", "content": "You are Atom, one of Crowther's specialised AI models."},
3 {"role": "user", "content": "Summarise the attached procurement policy in five points."},
4]
5
6text = tokenizer.apply_chat_template(
7 messages,
8 tokenize=False,
9 add_generation_prompt=True,
10 reasoning_effort="xhigh", # must match the setting used in adaptation
11)
12
13inputs = tokenizer(text, return_tensors="pt").to(model.device)
14outputs = model.generate(**inputs, max_new_tokens=1024, do_sample=False)
15decoded = tokenizer.decode(outputs[0][inputs.input_ids.shape[1]:], skip_special_tokens=True)add_generation_prompt=True ends the prompt with <|im_start|>assistant\n<think>\n,
so generation begins inside the thinking block. The model emits its reasoning,
closes it with </think>, then writes the answer. Separate them on the closing
tag:reasoning, _, answer = decoded.partition("</think>")enable_thinking=False in
apply_chat_template suppresses reasoning, but the model was adapted exclusively
on thinking-enabled examples, so behaviour at that setting was not exercised.qwen3_5 architecture checkpoint, so any runtime with
support for that architecture can serve them:vllm serve CrowtherLabs/atom-proton-1.0 --dtype bfloat16chat_template_kwargs: {"reasoning_effort": "xhigh"}. Serving configuration was
not exercised during adaptation, so verify the rendered prompt before relying on
it in production.