Bring your own model
Connect a service to a workspace model, or enroll your own model worker and call it through the same API.
Status. Workspace worker enrollment and automatic endpoint creation are supported as of 2026-10-19 for enabled workspaces; the defaults, tool declarations and service activation below were checked against the agent on 2026-11-16.
Workspace-served models
| Example model ID | Input |
|---|---|
gemma3-12b | text + image |
gemma3-4b | text + image |
Use GET /v1/models to check access, can_run, operations, input_modalities and streaming support for your workspace. The table is a guide, not a grant of access; a specialist’s supported operation depends on its catalog entry.
curl -s https://weights.fyi/run/v1/models -H "Authorization: Bearer $WEIGHTS_API_KEY"For a coding agent connecting an application, follow the three-call LLM endpoints quickstart: discover the model, ensure its endpoint exists, then make a smoke call. Use the exact model ID with https://weights.fyi/run/v1 and a workspace API key with read and submit scopes.
Enroll your own worker
A worker is a computer of yours that already serves a model through an OpenAI-compatible or Ollama server on its own loopback address. The agent you install beside it dials out to this service and opens no port. Five words recur:
| Word | Meaning |
|---|---|
| Join token | A single-use credential beginning wjt_ that enrolls one worker. It expires at the expires_at its creation answers: 60 minutes later by default, and a deployment can set another lifetime, so read the field. |
| Offer | What the worker says it serves: your workspace-unique model alias, the upstream model behind it, how many calls it takes at once and the longest one call may take. You declare the last two; the agent invents neither. |
| Pool declaration | The catalog entry callers see for the alias: its description, context limit, prices per 1M tokens (each with its reason) and region. |
| Publication | Putting an enrolled offer into that pool, which also creates the workspace endpoint. Until then the offer is held back from routing and no call reaches the worker. |
| Priority | The order in which a pool's workers are tried, 1 first. An offer's own priority wins over the token's default, which starts at 1. |
Owners and admins see the enrollment card where bringing your own model is enabled for the workspace; elsewhere a token request answers 403 byoc_not_enabled_for_workspace. Open Contributions in your workspace panel, enter a model alias under Enroll your own model worker (BYOC) (lowercase letters, digits, dots and dashes, starting with a letter, for example audoku-gemma3-4b; a hosted model's name is refused), and click Create join token. With the publish box ticked, as it is by default, the token carries the panel's pool declaration: 32,768 tokens of context, $0.10 per 1M prompt tokens and $0.10 per 1M output tokens, region eu, and the worker must enroll its offer for that region. A token minted through the API (a manage key; described in /openapi.json) can carry a declaration of its own, or none.
The panel shows the token once, beside a Coding-agent setup prompt for Claude Code, Codex or OpenCode. Pasted into a coding agent on the worker host, it:
- Installs
~/.local/bin/weights, fetches the trusted service certificate, and saves the token to a private0600file, never to source code or a command line. - Finds your local server (
127.0.0.1:8000or127.0.0.1:11434) and maps its upstream model to your alias (<alias>=openai:http://127.0.0.1:11434#<upstream-model>). - Enrolls the worker, keeps the agent running, and verifies the model through
https://weights.fyi/run/v1/chat/completions.
A token can restrict the aliases a worker may offer; an out-of-scope offer is refused without consuming it. A manager can revoke an unused token; a consumed one cannot enroll another worker. After enrollment the agent holds its own private key and connects outbound over mutual TLS 1.3 with a short-lived certificate.
Tools and other extensions
The generated command declares no extensions, so the worker takes the base chat fields only and a call that sends tools answers 400 invalid_request with reason: unsupported_field. If your server honours function tools, add this to the enroll command, with your alias for MODEL:
--chat-field MODEL=tools,tool_choice,parallel_tool_callsEach field is admitted under its own name: tools alone admits neither tool_choice nor parallel_tool_calls. min_tokens, seed, reasoning_effort, chat_template_kwargs, top_k, min_p and the three penalties are declared the same way. Declare only what the server really honours, and verify with a call that sends a tool: a plain smoke call proves the model answers, nothing more.
Keep it running
| Way | Agent command | What it does |
|---|---|---|
| Foreground | run | Serves until the shell closes. |
| As a service | install-service, with --kind systemd or --kind launchd | Writes the unit file and starts nothing. It prints the activation line as next; run that yourself. |
sudo systemctl daemon-reload && sudo systemctl enable --now UNIT_FILE_NAME # Linux
sudo launchctl bootstrap system PLIST_PATH # macOSsupervise is not one of these: it is the mode in which the platform runs its own fleet, driven by this service's control plane. A worker of yours uses enroll, run and install-service only.
Without automatic publication a manager publishes each enrolled offer separately; either way callers need only read and submit. Publication is not a readiness test: send a live request once the worker is connected. Manage connections in LLM endpoints and call POST /v1/chat/completions; a model you enrolled has a declared tariff, so its catalog entry reads measured: null (Prices and billing).
Trained artifacts
Fine-tuning produces workspace-owned ft_… artifacts. Their catalog entries describe training metrics, downloads and supported operations; download weights with GET /v1/jobs/{job_id}/model.safetensors. An artifact does not automatically become a served model: run a compatible worker, enroll it with an authorized model ID, and verify its published endpoint.