Skip to main content

ACP Backend Configuration

What is ACP?

ACP (Agent Client Protocol) is a protocol for communicating with agent backends. Zotero Agents communicates with locally running agent processes (such as Codex, Claude Code, OpenCode, etc.) through the ACP protocol to enable conversations and skill execution.

The ACP backend is the recommended configuration method — as long as you have any ACP-compatible agent tool installed on your machine, you can use it directly with zero additional configuration.

New to Agent?

If you're new to agent tools and unsure which one to choose or how to install, check out this guide:

Agent Getting Started Guide

Why ACP First?

  • Zero configuration burden: No need to deploy additional services; use the agent tools already on your machine
  • Automatic process management: The plugin specifies the launch command in the configuration and automatically manages the agent process lifecycle
  • Multi-agent support: Configure multiple different agent backends simultaneously and switch between them as needed
  • Configuration isolation: Some agents (such as OpenCode and Codex) support isolating configuration directories and session persistence directories through environment variables

Configuration Steps

  1. Ensure you have at least one ACP-compatible agent CLI tool installed on your machine
  2. Open Tools → Backend Manager
  3. Switch to the ACP tab
  4. Select your agent tool from the Add from Preset dropdown, or click Add ACP to configure manually
  5. Fill in the following fields:
    • Display Name: A friendly name (e.g., "My OpenCode")
    • Command: Command to start the ACP backend (presets auto-fill, but you can also modify manually)
    • Arguments: Additional arguments for the command (optional)
    • Environment Variables: Additional environment variables (optional, used for configuration isolation, etc.)
  6. Click Save in the bottom-right corner

Connection Verification

After saving, the plugin automatically detects the backend's capabilities:

  • Checks if the command exists
  • Connects and initializes
  • Retrieves available models and modes
  • Computes a configuration fingerprint to detect subsequent changes

If detection fails, verify that the agent CLI is installed correctly and the command format is correct.

Supported Agent Presets

The plugin provides several built-in presets. After clicking Add from Preset, select an agent on the left; the right side shows launch options and a read-only configuration preview.

When Use npx is enabled, the preset switches to the npx <package> launch form and the profile display name gains the (npm) suffix. When Isolated environment is enabled, the profile display name gains the (Isolated) suffix and the plugin injects the documented isolation environment variables or session-directory arguments for that backend.

ACP Preset Dialog

PresetDefault commandDescription
OpenCodeopencode acpOpenCode ACP backend; injects OPENCODE_CONFIG_CONTENT to deny permission questions and supports configuration-directory isolation through OPENCODE_CONFIG_DIR
Codexnpx -y @agentclientprotocol/codex-acp@latestCodex ACP adapter for OpenAI Codex
Claude Codenpx -y @agentclientprotocol/claude-agent-acp@latestACP adapter for Claude Code
Gemini CLIgemini --experimental-acpGemini CLI ACP mode
Hermeshermes acpHermes Agent ACP backend
Qwen Codeqwen --acp --experimental-skillsQwen Code ACP mode
GitHub Copilotcopilot --acp --stdioGitHub Copilot CLI ACP mode
Qoder CLIqodercli --acpQoder CLI ACP mode; supports documented configuration-directory isolation through QODER_CONFIG_DIR
Cursor Agent ACPcursor-agent-acpCursor Agent ACP adapter; supports documented session-directory isolation through --session-dir
DeepAgentsdeepagents-acpDeepAgents ACP adapter
Auggieauggie --acpAuggie ACP mode
Kilokilo acpKilo Code ACP mode; injects KILO_CONFIG_CONTENT to deny permission questions, and core XDG path isolation has been observed for config, data/session/auth/log, and cache state
Clinecline --acpCline ACP mode
CodeBuddycodebuddy --acpCodeBuddy ACP mode
Grokgrok agent stdioGrok agent stdio mode

Only OpenCode, Codex, Claude Code, Gemini CLI, Qwen Code, and Hermes Agent have been tested. Availability of other ACP backends depends on their backend implementations, and this plugin makes no guarantee. If you encounter problems, adjust command arguments and environment variables yourself, using the ACP protocol and each backend's official documentation as authoritative references.

You can still manually modify any field after selecting a preset.

Free Model Options

Several engines offer free model access — ideal for getting started without any payment:

EngineFree OptionHow It Works
Kilo CodeAuto Free modeKilo Code's built-in Auto Free mode automatically routes each request to a suitable free model. Enable it in Kilo Code settings — no API key required
OpenCode ZenBuilt-in free modelsThe OpenCode Zen edition includes built-in free model access without requiring an API subscription
OpenCode + OpenRouterOpenRouter free modelsConfigure OpenCode to use OpenRouter and select free-tier models (e.g., Gemini 2.5 Flash, DeepSeek V3). Requires a free OpenRouter account

Free Tier Limitations

Free models are sufficient for casual use, but be aware of the following constraints:

LimitationWhat to Expect
Rate LimitingRequests may be throttled — typically 5–20 requests per minute depending on provider load. Batch processing slows down significantly
ConcurrencyUsually limited to a single concurrent request. Running multiple workflows simultaneously may queue or fail
Model AvailabilityFree model pools can be exhausted during peak hours. You may see "model unavailable" or "capacity exceeded" errors
Model RotationProviders may silently swap free models (upgrade or downgrade) without notice. Output quality may vary between runs
No SLA / ReliabilityFree tiers offer no uptime guarantee. Services may be temporarily unavailable or discontinued

If you need reliable batch processing or production use, consider a paid plan such as OpenCode Go ($10/month) or a Coding Plan (Bailian, Zhipu, etc.). The per-paper cost is negligible compared to the time saved.

Environment Variable Configuration Recommendations

Some agents support configuration isolation and session persistence through environment variables or command arguments. Presets with Isolated environment enabled inject the documented values automatically; for manual profiles, add the relevant values yourself:

The OpenCode and Kilo presets also always inject an inline permission configuration: OPENCODE_CONFIG_CONTENT and KILO_CONFIG_CONTENT, respectively, both set to {"permission":{"question":"deny"}}. You can edit or remove these values after adding the preset.

SettingAgentPurpose
OPENCODE_CONFIG_DIROpenCodeSpecify an independent configuration directory
CODEX_HOMECodexSpecify an independent home/configuration directory
CLAUDE_CONFIG_DIRClaude CodeSpecify an independent configuration directory
GEMINI_CLI_HOMEGemini CLISpecify an independent configuration directory
HERMES_HOMEHermes AgentSpecify an independent home/configuration directory
QODER_CONFIG_DIRQoder CLISpecify an independent configuration directory
--session-dir <path>Cursor Agent ACPSpecify an independent session persistence directory
XDG_CONFIG_HOME, XDG_DATA_HOME, XDG_CACHE_HOMEKiloSpecify independent XDG roots for configuration, data/session/auth/log, and cache state. This covers the observed core state paths, but does not prove every Kilo subcommand or plugin avoids global directories.

Request Types

The ACP backend supports two request types:

  • acp.prompt.v1 — Conversational interaction (ACP Chat)
  • acp.skill.run.v1 — Skill execution (ACP Skills)

The same ACP backend can be used for both conversations and skill runs simultaneously.

Session Management

  • Each backend can have multiple sessions (conversations), which are persistently stored in the plugin database
  • Different ACP backends can run simultaneously without interfering with each other
  • Sessions can be managed in ACP Chat

Next Steps

After configuration is complete, you can: