It runs inside the Claude Code process. The side panel is only what the author's README names. Read the repo before you install, or run claude plugin validate on the plugin folder.
Version
0.13.0
License
MIT
Repo stars
9
Last change
2026-10-03
What it can reach
Draws in the session
Reaches the network or an outside service
Sees tool calls
Calls another program on this machine
Needs Claude Code 2.1.287 or newer, and Node.js 18 or newer. Restart, then /fanyi settings. A line above the prompt shows when translation is on. /fanyi toggles it. A prompt that is not already English is translated to English before Claude reads it, and the row shows what you typed with the English under it. A prompt that is already English is sent as typed. Prompts that start with / or ! are never translated. Each text block of a reply gets a translation under it, and a block already in your language gets no box. Subagent replies are not translated. The reply's translation is display only, and the prompt Claude reads is the English. A question dialog and a tool row's title are drawn with a translation. An option's label stays English. Text you type as an answer is translated to English before Claude reads it. The API engine needs a key for an OpenAI-compatible Chat Completions host, and the text to translate goes to that host. The Apple engine keeps it on the Mac. The host defaults to https://opencode.ai/zen/go/v1 and the model defaults to deepseek-v4.1-flash. Every API request sends a User-Agent of claude-code-fanyi and the version, and an x-opencode-session header set to the session id. OpenCode Go requires both. The README reports that leaving reasoning off, which is the default, cuts time to first token on DeepSeek from 6 to 15 seconds to about 1.5 seconds. The API key is kept in the macOS Keychain, or in a file only you can read. An empty key removes it. The README does not name that file. The settings are api_key, base_url, model, and disable_thinking. The Apple on-device engine needs macOS 15 or newer and the Xcode command line tools. Its helper is compiled on the Mac the first time it is needed, and that path sends nothing off the Mac. On this Mac language detection makes no API call. Ask the model uses the API. If Claude Code asks you to approve the translator tool, allow it. Translation adds about 1.5 to 5 seconds on the API, or under a second on the Apple engine, before a prompt in your language is sent. Finished translations are kept in the plugin's own store, about 3 MB of the newest. The README does not name a file for the store.
translate-view translates each prompt before sending it and draws the reply's translation in a side pane, sending the text to a Chat Completions service you set. parrot-translate by default rewrites each prompt into English and draws the translation under the reply, and its default provider is Microsoft's Edge translate service. This one shows what you typed with the English under it, and the reply's translation under the English. The default API host is OpenCode Go. The README says the mod itself makes no network requests and that the API traffic goes through the plugin's translator server. That server is this plugin, so the API path is the network access. The Apple engine is the local program, and it is not the default. The mod refuses its own translator tools when Claude calls them. That refusal is on the translator's own request, so this page does not list a hold. The English prompt is what gets sent.
Demo
Screenshot of the author's GitHub page.
What it hooks into
session.startWhen a session starts
command.runWhen you run its slash command/fanyi
ui.renderDraws into the sessionAbovePromptPaneAssistantMessageUserMessageAskUserQuestionToolUseToolResult
prompt.submitWhen you send a prompt
session.appendWhen an entry is written to the transcript
tool.callAround a tool call, where it can hold oneAskUserQuestion
Read from the on() calls in its hook modules. Open its source under Files to check what each one does.