Skip to main content

Use Flint for free

  1. Open OpenCode’s model picker.
  2. Select the free tier, then choose Flint-40B.
  3. Start a chat and use Flint.
Free-tier access is subject to available capacity and rate limits. If capacity is unavailable or you reach a limit, wait and try again later.
To connect OpenCode through your OpenRouter account, follow the OpenRouter login example.

Run locally

For local inference, complete the rec setup, then run this from your project directory:
This provides rec’s automatic, one-command setup: the launcher supplies the local server, authentication, and model configuration. Use the Ollama or Unsloth launcher below, or configure a llama.cpp connection.

Connect local runtimes

Ollama

Prepare Flint using the Ollama guide, then run from your project directory:
Select flint:40b-a2b-qat-int4 in the launcher. Use a build that includes this command. Ollama’s OpenCode integration recommends at least 64K context; configure that only when the Flint runtime and device can support it.

Unsloth

Load the compatible Flint model in Unsloth, then run:
Confirm the selected model is Flint. See Unsloth’s launcher.

llama.cpp: custom configuration

Start the server using the Mac or NVIDIA guide. Use these connection details with OpenCode’s configuration guide: Run the tool-cycle check after connecting. These settings are for manually configured local endpoints. Keep rec’s bundled defaults when using its launcher. No manual configuration is needed to select Flint-40B from the free tier. The 64K output budget is a recommended client policy, not a claim that every endpoint supports 64K output. Lower it to the provider’s supported output limit when necessary. The context limit must be larger than the output budget and leave room for your prompt, tools, and conversation.

When to change the configuration

  • The endpoint rejects top_k: confirm its supported extension or server-side configuration. Omit top_k from requests if unsupported; keep the supported temperature and top-p values.
  • The endpoint rejects the token budget: lower the configured output budget and adjust the compaction buffer accordingly.
  • The endpoint or local context changes: update the harness’s context limit to match. A configured number does not increase server capacity or establish long-context quality.
  • Responses end during reasoning: inspect the finish reason and raise the output budget only within the endpoint’s supported limits.
  • Tool calls fail: verify the model’s chat template and serving parser, then try the minimal tool loop outside OpenCode.
Run the tool-cycle check after configuring your endpoint.

Other harnesses

See the dedicated Pi, OpenHands, and experimental Codex CLI guides, or compare the options in coding harnesses. Confirm that your client preserves tool-call IDs, sends tool results with the correct role, and supports the reasoning format your endpoint returns. See generation settings for model-level behavior. OpenCode’s configuration guide explains configuration precedence.