LLM Setup
Review content is generated by an LLM (under the hood via pr-agent + litellm). Under Settings → LLM, configure one or more "LLM profiles" and use active to switch which one is in effect. Each profile independently stores its provider / model / Base URL / API Key.
Profile fields
| Field | Description |
|---|---|
| Name | Profile identifier (letters / digits / - / _, 1–32 chars), used for switching and logs |
| Provider | LLM provider; determines the auth and routing method (see table below) |
| Model | Model name (for most providers, just the model name — the client adds the litellm prefix automatically) |
| Base URL | API endpoint; most official providers have a default, so leave it empty |
| API Key | Auth key; not needed for local types (local CLI / self-hosted service without auth) |
Provider overview
| Provider | Description | Model example | Key needed | Base URL |
|---|---|---|---|---|
| OpenAI | Official OpenAI API | gpt-4o / gpt-4o-mini | Yes | Default endpoint, leave empty |
| Anthropic | Official Anthropic API | claude-opus-4-8 / claude-sonnet-4-6 | Yes | Default |
| DeepSeek | Official DeepSeek API | deepseek-v4-pro / deepseek-v4-flash | Yes | Default |
| Alibaba Bailian (DashScope) | OpenAI-compatible endpoint, includes Qwen / DeepSeek-on-DashScope | qwen-max / qwen-plus | Yes | Built-in default |
| Volcengine Ark | OpenAI-compatible endpoint, includes Doubao / DeepSeek-on-Ark | ep-xxxxx / doubao-pro-32k | Yes | Built-in default |
| OpenAI-compatible | Any service that follows the OpenAI protocol (vLLM / self-hosted proxy / relay / local Ollama) | Platform-specific | Depends on service | Required |
| Local CLI | Run reviews via a local agentic CLI, without connecting to an API directly (experimental, see below) | claude / codex | No | N/A |
About model prefixes: for each provider you only enter the model name, and the client completes the litellm routing prefix automatically based on the provider; a prefix you added manually is not duplicated.
- Anthropic → prefixes
anthropic/by default- DeepSeek → prefixes
deepseek/by default- OpenAI-compatible / Alibaba Bailian / Volcengine Ark → prefix
openai/by default- OpenAI → uses the built-in model name directly, no prefix
- Local CLI → what you enter is a command name, so prefixes don't apply
Configuration examples
Below is how to fill in each Settings-page field per provider (the Name is just an identifier — pick anything; unless noted otherwise, Model takes only the model name and the client completes the routing prefix automatically).
OpenAI
- Provider:
OpenAI - Model:
gpt-4o-mini - Base URL: leave empty (defaults to
https://api.openai.com) - API Key:
sk-…
Anthropic
- Provider:
Anthropic - Model:
claude-sonnet-4-6 - Base URL: leave empty
- API Key:
sk-ant-…
DeepSeek
- Provider:
DeepSeek - Model:
deepseek-v4-pro - Base URL: leave empty
- API Key:
sk-…
Alibaba Bailian (DashScope)
- Provider:
Alibaba Bailian - Model:
qwen-plus - Base URL: leave empty (built-in default)
- API Key: DashScope key
Volcengine Ark
- Provider:
Volcengine Ark - Model:
doubao-pro-32k(or an inference endpointep-…) - Base URL: leave empty (built-in default)
- API Key: Ark key
OpenAI-compatible (self-hosted / relay / local Ollama)
Choose OpenAI-compatible as the Provider, set the Base URL (required) to the target service's /v1 endpoint, and enter the platform-specific model name in Model. Two common scenarios:
Self-hosted vLLM / relay
- Provider:
OpenAI-compatible - Model:
qwen2.5-72b-instruct - Base URL:
http://10.0.0.5:8000/v1 - API Key: depends on the service (leave empty if no auth)
Local Ollama
- Provider:
OpenAI-compatible - Model:
qwen2.5(runollama pullfirst) - Base URL:
http://localhost:11434/v1 - API Key: leave empty
Ollama ships an OpenAI-compatible endpoint, so this path is all you need — no separate channel required (an old
ollamaprofile is automatically migrated to this form on upgrade).
Configuration for the Local CLI profile is covered in its own section below.
Local CLI mode
An advanced option: instead of connecting directly to any LLM API, invoke — with your authorization — an agentic CLI already installed and logged in on your machine (currently claude / codex are supported), running the review in a local subprocess. That CLI runs under its own login session and billing policy, and the associated quota and compliance are your responsibility.
🧪 Experimental capability: local CLI mode depends on the command-line interface and output format of a third-party CLI, which are outside this project's control. An upstream CLI update may change its arguments, output structure, or login / billing policy, altering this mode's behavior or breaking it entirely; this project makes no guarantee about its stability or continued availability. The Settings page marks such profiles with an "experimental" badge as a reminder. If a review misbehaves, check the version and login state of the CLI you're using first.
Entirely under your authorization: only when you create and enable this profile and fill in a command name in the CLI command field will the client invoke that command line; this behavior is entirely on your explicit authorization and uses your machine's login state.
How to configure
- Install the corresponding CLI on your machine and log in.
- Go to Settings → LLM, create a new profile, and choose "Local CLI" as the Provider.
- Enter the command name in the CLI command field, e.g.
claudeorcodex. - Save and set it as active.
Key behaviors
- Runs under your machine's login state: the review request is handled by the local CLI, using its default model and login session — it does not use the API Key set here or in the environment.
- Actual model: determined by the local CLI's default model / account tier, not by what you enter here (what you enter is a command name, not a model name).
- Proxy passthrough is automatic: once the network proxy is enabled, the CLI's outbound requests go through the proxy automatically, with no extra configuration.
Prerequisite: the corresponding command must be installed on your machine, on the PATH, and logged in, otherwise the review fails because the command is not found; review usage counts against that CLI account's own quota.
Advanced: review concurrency
The app supports running multiple review tasks concurrently (e.g. running /review on several PRs at once, without blocking one another). The concurrency is controlled by the pr_agent.max_concurrency setting, default 2, range 1–8.
Drag the "Review task concurrency" slider in the "AI" section of the Settings page to adjust it (hot-applied, no restart needed); you can also edit ~/.code-meeseeks/config.yaml by hand:
pr_agent:
max_concurrency: 3 # 1–8, default 2Things to weigh before raising it (use these to decide how high to go):
- LLM rate limits / cost: the higher the concurrency, the more requests hit the LLM at once. A paid tier with your own key can usually handle 2–3; free / low tiers easily trip rate limits (HTTP 429), so keep it at
1. - Local CLI mode: each concurrent task spawns its own local CLI subprocess, and whether multiple sessions are supported depends on the CLI itself — validate on a small scale first.
- Local resources: each concurrent task occupies a separate runtime process and a temporary working directory, so higher concurrency consumes more CPU / memory / disk.
Adjustments on the Settings page take effect immediately (lowering it does not interrupt running tasks — it settles naturally as they finish); editing
config.yamlby hand requires an app restart. Setting it to1reverts to serial execution (one at a time).
Advanced: context length
Before a review, the changes (diff, matched rules, PR context, etc.) are assembled into a prompt and sent to the model. When the input exceeds the model's context window, pr-agent trims the input to the context-length limit to fit the model. This limit is controlled by the llm.context_tokens setting, default 128000 (tokens), range 32k–1M.
Drag the "Context length" slider in the "AI" section of the Settings page to adjust it (effective on the next review), offering the usual tiers of 32k / 64k / 128k / 256k / 512k / 1M; you can also edit ~/.code-meeseeks/config.yaml by hand:
llm:
context_tokens: 256000 # 32000–1000000, default 128000- Set it commensurate with the actual context window of the model you use: exceeding the model's capacity causes an upstream error; setting it too small truncates long PRs early and misses part of the changes.
- Does not apply to local CLI mode: a local CLI (e.g. claude) manages its own context, so this setting takes no part in trimming.
