Skip to content

Extension for text-generation-webui, added a lot more translators.

License

Notifications You must be signed in to change notification settings

Touch-Night/more_translators

Repository files navigation

中文 / EN


猫翻插件

供text-generation-webui使用的插件,为其提供多种翻译器支持。

安装

  1. 根据你使用的操作系统双击对应的批处理文件cmd_xxx.bat
  2. 输入pip install --upgrade translators,然后按Enter键来安装这个插件的依赖。
3. 把这个代码仓库下载到你text-generation-webui的插件文件夹。你可以通过以下方式之一来完成:
①. 手动下载zip压缩包   3.1. 点击 <>Code
  3.2. 然后点击 []Download ZIP以下载zip压缩包
  3.3. 之后把more_translators-main.zip解压到你的extensions文件夹,并将其重命名为more_translators。之后,你的文件结构应该像这样:
    text-generation-webui  
     ├─extensions  
     │  ├─more_translators  
     │  │  │  script.py  
    ... ...
    
②. 使用Git   3.1. 确保你已经正确安装Git,并且确保你的Git代理设置能让你的Git连接到Github
  3.2. 在步骤一打开的命令行窗口中,输入cd extensions并按下Enter
  3.3. 随后输入git clone https://github.com/Touch-Night/more_translators.git并按下Enter键。之后,你的文件结构应该像这样:
    text-generation-webui  
     ├─extensions  
     │  ├─more_translators  
     │  │  │  script.py  
    ... ...
    
4. 这样,插件就安装好了。你可以在你的text-generation-webui的`Session`一栏中启用它。 Session

使用说明

  • 如果你正确地启动了这个插件,那么你将可以在ChatDefaultNotebook下看到新增了如下面板: image
  • 这个插件在☑ 启用翻译勾选上时才会起作用。
  • 它在to-from模式下,会使用你选择的翻译器将你的输入从用户语言翻译成LLM的语言之后再提交给模型,并把模型生成的结果从LLM的语言翻译成用户语言之后再输出给你。
  • 而在to模式下,它就只会翻译你的输入,不翻译模型输出;在from模式下,只翻译模型输出,不翻译你的输入。
  • 设置项插件语言是指这个插件界面的显示语言,不对输入输出造成影响。内容由文件i18n.csv控制。
  • 如果你发现某个翻译器不起作用,可以在translators模块的仓库的Issues一栏中查找该问题是否已被报告,并在没有人报告翻译器问题时提交Issue

More_translators extension

Extension for text-generation-webui, added a lot more translators.

Install

  1. Double click cmd_xxx.bat.
  2. Type pip install --upgrade translators and then press Enter to install dependency for this extension.
3. Download this repo to your webui extension folder. You can do that by either:
①. Download zip mannually   3.1. Click <>Code
  3.2. Then click []Download ZIP to download this repository
  3.3. And then extract more_translators-main.zip to your extensions folder, rename more_translators-main folder to more_translators. After that, your file structure should be like:
    text-generation-webui  
     ├─extensions  
     │  ├─more_translators  
     │  │  │  script.py  
    ... ...
    
②. Git   3.1. Make sure you have installed Git, and have set the proxy correctly if your connection to GitHub is blocked by local government
  3.2. In the terminal opened in step 1, type cd extensions and then press Enter
  3.3. Type git clone https://github.com/Touch-Night/more_translators.git and then press Enter. After that, your file structure should be like:
    text-generation-webui  
     ├─extensions  
     │  ├─more_translators  
     │  │  │  script.py  
    ... ...
    
4. Installation is completed, you can enable it in the `Session` section of your webui. Session

Tips

  • If you applied this extension correctly, you should see this block is added in Chat, Default and Notebook tabs: image
  • More_translators will take effect only when ☑ Activate is checked.
  • In to-from mode, it will translate both your input from User's language to LLM's language using the Translator selected, and LLM's output from LLM's language to User's language.
  • In to mode, it will only translate your input, and in from mode, it will only translate LLM's output.
  • Plugin's language refers to the language of this plugin's UI, all the contents is in i18n.csv.
  • If you found a Translator is not working, you can search for similar issue in translators's Issues page, and submit new issue if there's no similar issues.

About

Extension for text-generation-webui, added a lot more translators.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages