[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-112742":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":15,"forks30d":15,"starsTrendScore":19,"compositeScore":20,"rankGlobal":9,"rankLanguage":9,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":24,"hasPages":22,"topics":25,"createdAt":9,"pushedAt":32,"updatedAt":33,"readmeContent":34,"aiSummary":35,"trendingCount":15,"starSnapshotCount":15,"syncStatus":16,"lastSyncTime":36,"discoverSource":37},112742,"zotero-interlinear","Muanyan-mjq\u002Fzotero-interlinear","Muanyan-mjq","Immersive bilingual paragraph-by-paragraph reading for Zotero. Original on top, translation right below. Bring your own translation provider.",null,"TypeScript",102,1,51,4,0,2,24,34,11,60.3,"GNU Affero General Public License v3.0",false,"main",true,[26,27,28,29,30,31],"llm","ollama","pdf","translation","zotero","zotero-plugin","2026-11-19 10:04:31","2026-11-23 14:56:09","\u003Cp align=\"center\">\n  \u003Cimg src=\"addon\u002Fcontent\u002Ficons\u002Ficon96.png\" width=\"96\" alt=\"Interlinear\" \u002F>\n\u003C\u002Fp>\n\n# Interlinear\n\nRead foreign-language papers in Zotero 10 with a translation under every paragraph.\n\nInterlinear plugs into the desktop PDF reader's reading mode, fetches a translation for each structured paragraph, and renders it right next to the source — so you can keep reading instead of copying text into a translator.\n\n[中文文档](README-zh-CN.md) · [Changelog](CHANGELOG.md) · [Contributing](CONTRIBUTING.md)\n\n## Features\n\n- **Five built-in translation services.** Free Google Translate works out of the box with no API key (rotating several independent quota pools, with MyMemory and self-hosted LibreTranslate as fallbacks). OpenAI-compatible endpoints, Anthropic Claude, Google Gemini, and Ollama are one settings page away. No companion plugin is required.\n- **Four layouts.** Translation below the source, side-by-side columns, translation only, or source only. A dedicated display-mode button cycles through them; side-by-side keeps the first lines aligned without disturbing Zotero's native highlights.\n- **One toolbar toggle.** The main toolbar button starts a translation run, then shows or hides the result. While a run is in progress, clicking it pauses and hides; clicking again shows the translations and resumes unfinished paragraphs. Each reader keeps its own state.\n- **Translate as you read.** Rest the pointer on a paragraph, press your custom shortcut, Alt-click, or select text — each triggers a single-paragraph translation without starting a full-document run.\n- **Full-document runs that behave.** Progress and cancel from the toolbar, viewport-first ordering that re-sorts as you page, short-paragraph batching, concurrency and rate limits, timeouts, automatic pause after repeated failures, and click-to-retry on any failed paragraph.\n- **Glossary.** Import\u002Fexport CSV or TSV term lists. Terms are injected into LLM prompts and enforced as a post-translation replacement on every service, including Google.\n- **Reading assistant.** A chat sidebar answers questions about the selected paragraph, the current page, or the whole document (LLM services only).\n- **Bilingual PDF export.** The current source-plus-translation view is re-typeset into a searchable PDF and attached to the Zotero item.\n- **Appearance control with live preview.** Six built-in presets (Default, Eye-friendly paper, Academic serif, High contrast, Optimized dark, Minimal) apply in one click and can be undone. Includes a searchable installed-font list with favorites, a font-stack builder with up to six fallbacks, automatic per-language font stacks, a custom HSV color picker (hue\u002Fsaturation\u002Fopacity\u002FRGB\u002FHSL\u002FHEX), separate light\u002Fdark colors, recent and saved colors, text decoration (underline\u002Foverline\u002Fstrikethrough with style\u002Fthickness\u002Foffset), paragraph dividers, ribbon position\u002Fwidth\u002Fstyle, block layout (padding\u002Fradius\u002Fborder\u002Findent\u002Falignment\u002Fmax width\u002Fopacity\u002Fsource dimming), named presets, and JSON import\u002Fexport.\n- **Caching.** Translations are cached per service, language pair, and glossary, with a one-click cleanup in settings.\n- English and Simplified Chinese UI; errors appear as non-blocking notices inside the reader.\n\n## Screenshots\n\nReal Zotero 10 windows with a real translation run; the images live in `docs\u002Fimages\u002Finbox\u002F` exactly\nas captured. Each pair is the same page and scroll position in the light and dark theme. The demo\npaper is *Attention Is All You Need* (Vaswani et al., arXiv:1706.03762); the translations are\nmachine-generated and shown for illustration only. The paper is distributed under its arXiv licence\n(`arXiv non-exclusive distrib 1.0`, not a Creative Commons licence) and appears here solely as\ndocumentation of this plugin's UI.\n\n\u003Ctable>\n  \u003Ctr>\n    \u003Ctd width=\"50%\">\u003Cimg src=\"docs\u002Fimages\u002Finbox\u002Freader-inline-light.png\" alt=\"Inline layout, light theme: each source paragraph followed by its Chinese translation\" width=\"100%\">\u003C\u002Ftd>\n    \u003Ctd width=\"50%\">\u003Cimg src=\"docs\u002Fimages\u002Finbox\u002Freader-inline-dark.png\" alt=\"Inline layout, dark theme\" width=\"100%\">\u003C\u002Ftd>\n  \u003C\u002Ftr>\n  \u003Ctr>\n    \u003Ctd align=\"center\">Inline — light\u003C\u002Ftd>\n    \u003Ctd align=\"center\">Inline — dark\u003C\u002Ftd>\n  \u003C\u002Ftr>\n  \u003Ctr>\n    \u003Ctd width=\"50%\">\u003Cimg src=\"docs\u002Fimages\u002Finbox\u002Freader-side-by-side-light.png\" alt=\"Side-by-side layout, light theme: source left, translation right\" width=\"100%\">\u003C\u002Ftd>\n    \u003Ctd width=\"50%\">\u003Cimg src=\"docs\u002Fimages\u002Finbox\u002Freader-side-by-side-dark.png\" alt=\"Side-by-side layout, dark theme\" width=\"100%\">\u003C\u002Ftd>\n  \u003C\u002Ftr>\n  \u003Ctr>\n    \u003Ctd align=\"center\">Side-by-side — light\u003C\u002Ftd>\n    \u003Ctd align=\"center\">Side-by-side — dark\u003C\u002Ftd>\n  \u003C\u002Ftr>\n  \u003Ctr>\n    \u003Ctd width=\"50%\">\u003Cimg src=\"docs\u002Fimages\u002Finbox\u002Freader-split-light.png\" alt=\"Split view, light theme: two panes with independent scrolling\" width=\"100%\">\u003C\u002Ftd>\n    \u003Ctd width=\"50%\">\u003Cimg src=\"docs\u002Fimages\u002Finbox\u002Freader-split-dark.png\" alt=\"Split view, dark theme\" width=\"100%\">\u003C\u002Ftd>\n  \u003C\u002Ftr>\n  \u003Ctr>\n    \u003Ctd align=\"center\">Split view — light\u003C\u002Ftd>\n    \u003Ctd align=\"center\">Split view — dark\u003C\u002Ftd>\n  \u003C\u002Ftr>\n\u003C\u002Ftable>\n\n## Install\n\n> **Restart Zotero after installing or updating.** The settings pane and the reader toolbar are\n> registered at startup; opening the settings before restarting can show an empty Interlinear pane\n> (the labels are filled in at runtime). One restart is enough.\n\n1. Download the latest `interlinear.xpi` from [Releases](https:\u002F\u002Fgithub.com\u002FMuanyan-mjq\u002Fzotero-interlinear\u002Freleases).\n2. In Zotero: **Tools → Plugins → gear icon → Install Plugin From File…**, then pick the `.xpi`.\n3. Restart Zotero if prompted.\n\nRequires **Zotero 10 or 11 (desktop)**. See [Acknowledgements](#acknowledgements) if you are coming from the original plugin.\n\n## Configuration\n\nOpen **Edit → Settings → Interlinear**. The page uses five tabs; the save bar and tab strip stay visible while you scroll, and modified fields show an unsaved-changes hint:\n\n- **Translation service** — pick a backend and fill in its endpoint, model, and API key; choose source and target languages. Each backend has a **Test connection** button that reports running, success, or the actual failure reason in place.\n- **Display & interaction** — default layout, Alt-click to translate a single paragraph, the single-paragraph shortcut, and optional show\u002Fhide and layout-cycle shortcuts with conflict warnings.\n- **Appearance** — live preview, six built-in presets and named presets, installed-font detection and stack builder, color picker with per-theme values, text decoration, paragraph dividers, ribbon, block layout, interface-follow and export appearance. Advanced groups start collapsed.\n- **Glossary** — import\u002Fexport term files.\n- **Advanced** — translation scope (body\u002Fheadings\u002Fcaptions\u002Flist items\u002Fnotes), skip trailing pages, speed and reliability knobs, auto-translate on open (off \u002F cache only \u002F always), translation cache usage and cleanup, plus version and project links.\n\n> **Privacy and keys.** Translating sends paragraph text to whichever service you configure — that is unavoidable, so do not translate sensitive documents with a service you do not trust. API keys are a separate story: Interlinear encrypts them with Zotero's OS key store (macOS Keychain, Windows DPAPI, Linux libsecret) and keeps only the `oskv1:` ciphertext in Zotero preferences. Keys are never written to logs, cache keys, debug output or exported appearance files, and they are sent in headers rather than URLs. Requests to non-loopback endpoints must use HTTPS unless you explicitly confirm a plain-HTTP host, and credential-bearing requests never follow redirects. Because the encryption key lives in your OS account, a profile copied to another machine or OS user cannot decrypt the stored key — re-enter it there. On Linux without a Secret Service, Interlinear keeps the key for the current session only by default; saving it unencrypted is possible but must be confirmed in the settings page and is then marked as unencrypted. Keys stored as plaintext by 0.6.0 and earlier are encrypted in place on first start, and the plaintext form stays readable until you save the key again.\n\n\n### Free translation services (no API key)\n\nUnder **Services → Google** you can pick a specific service or keep **Auto\nrotate** (default), which tries Google's `it`, `at`, `gtx`, `dict-chrome-ex`\nand `firefox-a` quota pools, then MyMemory and a configured LibreTranslate\ninstance. A throttled pool is skipped within the same batch instead of failing\nthe paragraph. You can also choose the preferred pool, toggle automatic\nfallback, add extra Google gateway hosts (each an independent quota pool, up to\nfour), wire in a fully custom free endpoint via a `{text}`\u002F`{from}`\u002F`{to}` GET\ntemplate plus a JSON result path, and see which service is active or cooling\ndown. \"Test connection\" uses the current form values without saving first.\n\nThe default `translate_a\u002Ft` endpoint carries several paragraphs per request\n(about 6× fewer requests than per-paragraph calls) and is paced to one request\nper second. Free endpoints throttle by IP, so very large runs may still enter a\ncooldown: the run pauses with a countdown and resumes automatically instead of\nmarking every paragraph as failed. Translated paragraphs are cached. For\nconsistently large workloads, use a model backend instead.\n\n> **Privacy:** MyMemory adds submitted text to its public translation memory.\n> Do not use it for sensitive documents.\n\n### Network and proxy\n\nThe default Google endpoint needs a working connection to `translate.googleapis.com`; the MyMemory and LibreTranslate fallbacks need their own endpoints reachable. Interlinear sends every request through Zotero's own HTTP layer (`Zotero.HTTP.request`), so it uses whatever proxy Zotero uses — there is no separate proxy setting in the plugin, and it cannot bypass Zotero's proxy configuration. Whether Zotero itself follows the system proxy depends on Zotero's network preferences and your OS settings (*not independently verified here*).\n\nIf \"Test connection\" fails: check that your system proxy or TUN mode is running, try another translation backend (OpenAI-compatible, Claude, Gemini or a local Ollama), and only then consider a mirror address you trust. Failure messages now say which of these is likely — timeout, DNS, refused\u002Freset connection, HTTP status, rate limiting, redirect, or unparsable response.\n\n## Usage\n\n1. Open a PDF in Zotero and switch to **reading mode**.\n2. Left-click the Interlinear toolbar icon to start a full-document run. Once translations exist, the same button hides them to show the original, and shows them again; if a run is in progress the first click pauses it, and a paused run resumes when translations are shown again. Right-click the icon for retranslate, cancel, export, and settings.\n3. The display-mode button next to it cycles the four layouts. Failed or paused paragraphs show a retry affordance — click it to retry just that paragraph.\n4. While reading, hold Alt and click a paragraph, use your shortcut, or select text to translate just that part. During a full run, these reuse in-flight requests instead of calling the service twice.\n5. Open the reading assistant from the reader sidebar to ask questions about the selection, the current page, or the whole document; export the bilingual view as a PDF attachment from the toolbar menu.\n\n## Known limitations\n\n- Desktop Zotero 10 or 11 only; there is no mobile or Zotero 7 support.\n- The plugin relies on Zotero's internal reading-mode interfaces, which are not a public API — a Zotero upgrade may break it until adapted.\n- Math formulas are not translated; tables are not translated cell-by-cell; figure content is not extracted.\n- Scanned PDFs work only as well as Zotero's own text layer.\n- Export re-typesets the reading view; it does not overlay translations on the publisher's original PDF pages.\n- Default pair is English → Simplified Chinese; other pairs depend on the chosen service and model.\n\n## Roadmap (planned)\n\nPlanned, not implemented, no committed timeline:\n\n- Cell-level table translation.\n- Adapting to reading-mode interface changes in future Zotero releases.\n\n## Development\n\n```bash\nnpm install\nnpm run build        # type-check + package .scaffold\u002Fbuild\u002Finterlinear.xpi\nnpm run lint:check   # ESLint\nnpm run test:unit    # Node unit tests, no Zotero needed\nnpm run test:gui     # capture real preference-window screenshots into docs\u002Fdev\u002Fscreenshots\nnpm run test:e2e     # provider e2e: mock protocols by default\nnpm start            # dev server; set ZOTERO_PLUGIN_ZOTERO_BIN_PATH in .env first\n```\n\nIntegration tests run against a real headless Zotero:\n\n```bash\nZOTERO_PLUGIN_ZOTERO_BIN_PATH=\"\u002Fpath\u002Fto\u002Fzotero\" npm run test:review\n# or the standard scaffold entry:\nZOTERO_PLUGIN_ZOTERO_BIN_PATH=\"\u002Fpath\u002Fto\u002Fzotero\" npm test\n```\n\n`npm run test:e2e` also covers a real local Ollama model and a real Google\nrequest through a local proxy when the matching environment variables are set:\n\n```bash\nINTERLINEAR_TEST_OLLAMA_MODEL=qwen2.5:7b INTERLINEAR_TEST_GOOGLE_PROXY_PORT=7897 \\\nZOTERO_PLUGIN_ZOTERO_BIN_PATH=\"\u002Fpath\u002Fto\u002Fzotero\" npm run test:e2e\n```\n\nOn Windows the path is typically `C:\\Program Files\\Zotero\\zotero.exe`. CI runs lint, builds on Ubuntu\u002FmacOS, and executes the test suite on every push to `main`.\n\n## License\n\n[AGPL-3.0-or-later](LICENSE).\n\n## Acknowledgements\n\nInterlinear is based on [quillamio\u002Fbilingual-reader](https:\u002F\u002Fgithub.com\u002Fquillamio\u002Fbilingual-reader) (AGPL-3.0-or-later); adapted contributions and template sources are recorded in [NOTICE.md](NOTICE.md). If you used the original Bilingual Reader, uninstall it before installing Interlinear — your old settings and translation cache are copied into Interlinear's own namespace on first start, and the original data is left untouched.","Zotero Interlinear 是一款为 Zotero 桌面版 PDF 阅读器设计的双语对照阅读插件，支持段落级原文与译文并排\u002F上下布局显示。核心功能包括多翻译后端集成（Google、MyMemory、LibreTranslate、OpenAI 兼容接口、Claude、Gemini、Ollama）、按需单段翻译、全文自动分段翻译与错误重试、术语表注入、LLM 阅读问答侧边栏，以及双语 PDF 导出。采用 TypeScript 开发，深度适配 Zotero 10 的阅读模式，不依赖额外服务或插件。适用于人文社科研究者、语言学习者及需要高频阅读外文文献的学术用户，在本地离线或可控 API 环境下实现沉浸式双语研读。","2026-11-24 04:43:59","CREATED_QUERY"]