Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>LibreTranslate sourceNew to Visual Studio Code? Get it now.
LibreTranslate source

LibreTranslate source

Yolomancing

|
53 installs
| (0) | Free
Translation source for `Comment Translate` plugin using local LibreTranslate engine
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

libretranslate source

Licence

This plugin provides a translation source for the comment-translate vscode extension. It relies on a local LibreTranslate install making the translation 100% free ;)

sample

Features

  • Over comments to display translations in the info.
  • Replace selection by translation
  • Insert translation after selection

Requirements

  • LibreTranslate: free and Open Source Machine Translation API, entirely self-hosted. Unlike other APIs, it doesn't rely on proprietary providers such as Google or Azure to perform translations. Instead, its translation engine is powered by the open source Argos Translate library.
  • comment-translate vscode extension: this extension helps developers translate comments, strings, code hints, error messages, and variable names in their code.

Install guide

  1. Install LibreTranslate translation engine locally

First ensure python and pip are working properly:

python --version
python -m pip --version

Tested with Python 3.11.0 & pip 24.0

Install LibreTranslate:

python -m pip install libretranslate

The languages installation can take few minutes

  1. Run LibreTranslate
libretranslate

You can open a web browser to http://localhost:5000 an try the engine and use it directly. The extension will target the local web API, see the official doc

  1. Install comment-translate extension in vscode
  2. Change comment-translate translation source by targeting libretranslatesource In vscode execute:
> Change translate source

libretranslate-source

It'll invoke the service configuration page. Then select libretranslate translate source.

libretranslate-source

Enjoy!

Extension Settings

None for now.

However, please refer to the current configurations of the comment-translate extension.

Incoming features

  • configurable libretranslate's host url
  • configurable text to translate max length
  • prettify translations display

Code references

  • deepl-translate: used as main source of inspiration
  • libretranslate-integration: for the context features
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft