Usage.
The Freuron API covers the full path from training data to a live private endpoint. You import training data, start a fine-tune, inspect and switch the candidate version it produces, and then call private inference with an OpenAI-compatible messages payload. No SDK is required: management endpoints are REST with JSON bodies, and inference works with an existing OpenAI client once you change the base URL and key and nest generation parameters under generation_config. Send a scoped key in the x-api-key header. Training and inference bill per token, per base model.
This page is the public quickstart, and it follows that path in order — import, fine-tune, switch, and inference — for anyone setting up their first model. Training writes a candidate version and nothing goes live until you switch it in, so the version serving traffic is always one you inspected and promoted deliberately. After access is granted, the in-console API section shows copy-ready examples for your models, beyond the calls covered here.
Quickstart
Four calls take a model from raw data to serving traffic, and they run in order. Replace {id} with your model id. The first call brings in a JSON or JSONL file of prompts and completions, the second starts training on that data, and the third promotes the result — but only the third makes anything live, because training writes a candidate version and does not replace the version already serving. Once you have inspected that candidate and switched it in, the fourth call serves it.
- 1. Import: POST /api/models/{id}/import/file with a JSON or JSONL file of prompts and completions.
- 2. Train: POST /api/models/{id}/fine-tune. Training writes a candidate version; it does not replace the live version.
- 3. Switch: inspect the candidate, then POST /api/fine-tune/{id}/switch to promote it.
- 4. Serve: POST /api/v1/inference/chat with an OpenAI-compatible messages payload.
import requests
response = requests.post(
'https://api.freuron.com/api/v1/inference/chat',
headers={'x-api-key': 'YOUR_API_KEY'},
json={
'model': 'support-bot',
'messages': [{'role': 'user', 'content': 'My invoice looks wrong.'}],
'generation_config': {'temperature': 0.4, 'max_tokens': 512},
},
)
print(response.json()['choices'][0]['message']['content'])Authentication
To get a key, request access, then create a model in the console and issue a scoped inference key for that model; keys are issued per model in the console and sent in the x-api-key header. Organization-scoped endpoints sit behind a different boundary and require an authenticated session. When you need to revoke access, disabling developer mode is enough: its keys are cascade-deleted, so disabling it revokes its keys rather than leaving them active and no orphaned credentials remain.
Inference request
Inference is a JSON POST to POST /api/v1/inference/chat in the OpenAI chat-completions shape, so the request names the model and carries the conversation as messages, with generation parameters nested under generation_config rather than sent at the top level. The reply comes back where an OpenAI client already looks for it, at choices[0].message.content, which is why an existing client needs only a new base URL, a new key, and that one nesting change.
Set streaming on the inference endpoint when you need tokens as they arrive; otherwise wait for the complete JSON response.
- model: the deployed model to call.
- messages: role and content pairs, as in OpenAI chat completions.
- generation_config: generation parameters, including temperature, top_p, max_tokens, and stream.
Versions and job status
A fine-tune is a long-running job, and sync-status is how you follow it: poll it for job progress until the candidate is ready, then inspect the candidate before you promote it. The switch is always explicit, and that separation is what keeps the live version stable — a job that is still running has changed nothing that serves traffic, and a failed job leaves the live version unchanged. Rolling back is the same move in reverse, switching to the prior version.
- List versions and inspect a candidate by id before promoting it.
- Switch explicitly with POST /api/fine-tune/{id}/switch.
- Roll back by switching to the prior version.
- A failed job leaves the live version unchanged.
Billing
Training, evaluation, and inference are billed per token, per base model, and not per hour. You pay for tokens processed, not for GPU time sitting reserved: there is no hourly charge for an endpoint, and one scaled to zero between calls is not billing idle hours. Charges draw from your included credit pool first and, once the pool is used, from your prepaid balance, and the usage and transaction history for your organization are visible in the console.
There is no public price list during early access. Pricing is agreed directly when access is set up, and the rates that apply to your account are shown in the console.
- Charges draw from your included credit pool first.
- Once the pool is used, they draw from your prepaid balance.
- Usage and transaction history for your organization are visible in the console.