Guides
Text generation
The DiffusionGemma that answers System One reads also writes text. Any tool that talks to an OpenAI-style chat model can use it by changing the base URL.
Quick start
Use model diffusiongemma-26b at https://api.codiv.ai/v1 with your Codiv key:
from openai import OpenAI
client = OpenAI(base_url="https://api.codiv.ai/v1", api_key="sk-codiv-...")
r = client.chat.completions.create(
model="diffusiongemma-26b",
messages=[{"role": "user", "content": "Summarize: 3 nonstop flights, cheapest $212 on Delta."}],
)
print(r.choices[0].message.content)curl https://api.codiv.ai/v1/chat/completions \
-H "Authorization: Bearer $CODIV_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model": "diffusiongemma-26b",
"messages": [{"role": "user", "content": "Write a haiku about a GPU."}]}'How it differs from other chat models
DiffusionGemma is a diffusion model: it writes each 64-token block of the reply all at once and refines it over several denoising steps, instead of one token at a time. Some OpenAI fields don't apply, so Codiv adjusts requests rather than rejecting them:
temperature,seed,min_p,logit_bias, the penalties andreasoningare ignored.response_format(json_objectorjson_schema) becomes an instruction to reply with JSON only, and the first JSON object in the reply is returned ascontent. A schema is passed to the model as guidance; it is not enforced.max_tokensdefaults to 1024 and is capped at 8192.- Thinking is off by default. Turn it on with
chat_template_kwargs: {"enable_thinking": true}; the thought comes back inmessage.reasoning, never incontent. stream: truestreams server-sent events, ending with a usage chunk.toolsandtool_choiceare supported.
See the Chat completions reference for every field.
Quota and capacity
Text generation has its own free quota of 10M tokens, input and output together, separate from your System One quota. Both are shown on the dashboard.
Generation costs far more GPU time than a System One read, so at most 8 generations run at once. When they are all busy, requests return 529 with a retry-after header; retry with backoff. System One reads are never slowed by generation.
Using it with jev-ultrafast
browser-use/jev-ultrafast pairs Jev with a fast text model. To run it entirely on Codiv, set these in its .env:
TYPESAFE_API_KEY=sk-codiv-...
TEXT_MODEL_API_KEY=sk-codiv-...
TEXT_MODEL_BASE_URL=https://api.codiv.ai/v1
TEXT_MODEL=diffusiongemma-26b
TEXT_MODEL_REASONING=nonejev-ultrafast calls https://api.typesafe.ai/v1/systemone directly instead of reading a base URL, so change that one line in model.py to point at Codiv:
result = post_json("https://api.codiv.ai/v1/systemone", os.environ["TYPESAFE_API_KEY"], body)Try it
The Text playground is a chat box against diffusiongemma-26b, with JSON mode and thinking toggles.