Skip to content

py233/pear-desktop

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5,201 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pear Desktop Personal

🎧 A personal Pear Desktop build tuned for YouTube Music, bilingual lyrics, and practical lyric translation.

This repository is based on ArjixWasTaken/pear-desktop, which itself continues the MIT-licensed pear-devs/pear-desktop project. It is not affiliated with, endorsed by, or maintained by the upstream projects.

✨ Highlights

  • 💾 Local translation cache: translated lyrics are saved locally and reused when the song, target language, provider, model, and source lyrics match. Fewer repeat API calls, less waiting, fewer 429 surprises.
  • 🧠 Whole-song translation flow: LLM providers receive the full lyric context first, then the result is aligned back to each lyric line.
  • 🌍 Google Translate provider: no-login Google Translate support with chunked whole-lyric requests and line-boundary recovery.
  • ☁️ Official NetEase translations first: when the target language is Chinese, NetEase official translated lyrics are preferred before falling back to the selected translation provider.
  • 🔎 Smarter lyric matching: improved search cleanup for music-video titles, Japanese titles, romanized alternates, artist names, and noisy bracketed text.
  • 🛡️ Same-language skip: if the lyrics are already in the target language, translation providers are not called.
  • 🤖 Flexible providers: OpenAI-compatible APIs, Ollama-compatible endpoints, Google Translate, Gemini API, and already-logged-in local Claude Code / Codex / Gemini CLI.
  • 🪄 Simpler Local CLI setup: choose the CLI engine only; command and model selection are handled automatically through the CLI's own login and defaults.
  • 🔤 Readable lyric sizing: small, medium, and large lyric font options.

📥 Downloads

Use the GitHub Releases page for packaged builds.

Windows builds include two .exe files:

  • Pear.Desktop.Personal.Setup.*.exe: offline NSIS installer. No extra .nsis.7z download is required.
  • Pear.Desktop.Personal.*.exe: portable build.

macOS builds provide an Apple Silicon .dmg. Linux builds provide an .AppImage.

Note

This personal build has only been tested by me on macOS 15.6.1. Windows and Linux artifacts are generated by GitHub Actions and still need user testing.

🧩 Translation Providers

NetEase Official Lyrics

When the target language is Chinese, the plugin tries NetEase synced lyrics and official translations first. If no good match is found, it falls back to the selected translation provider.

Google Translate

Good for simpler songs and quick translations without an API key. The provider sends lyrics in larger chunks instead of one request per line, then restores line alignment.

OpenAI-Compatible / Ollama

Use this for OpenAI-style endpoints or local Ollama-compatible servers. Ollama generally works with:

Base URL: http://127.0.0.1:11434/v1
API mode: auto or chat-completions
Model: your Ollama model name

Local CLI

Use this when you are already logged in locally:

  • Claude Code
  • Codex
  • Gemini CLI

Only the engine needs to be selected. The CLI command and model are automatic.

🏠 Cache And Privacy

Translation cache lives in the app's local user data directory. Cache keys include the song, target language, provider, model, lyric line count, and source lyric signature.

Provider settings and API keys live in your local app config. They are not stored in this repository and are not needed by GitHub Actions.

The synced lyrics menu includes a clear-cache action if you want to force a fresh translation.

🛠️ Development

pnpm install
pnpm dev

Production build:

pnpm build

🧾 Why This Exists

The lyric translation work touches providers, menus, rendering, caching, packaging, and platform details. It is too broad to be a comfortable single upstream PR, so this repository keeps the full personal build available. Smaller pieces can still be proposed upstream separately later.

🙏 Upstream And Attribution

This project preserves upstream git history and keeps the original MIT license. See NOTICE.md for attribution details.

⚠️ Disclaimer

This project is not affiliated with, authorized by, endorsed by, or officially connected with Google LLC, YouTube, pear-devs, or ArjixWasTaken. Names and trademarks belong to their respective owners.

The software is provided as-is. Use it at your own risk.

License

MIT. See license.

About

Personal Pear Desktop build with bilingual lyrics translation

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors