Mayo commited on
Commit
23ec26f
·
unverified ·
1 Parent(s): b247d09

docs: add openai-compatible

Browse files
Files changed (3) hide show
  1. README.md +28 -10
  2. docs/README.ja.md +20 -2
  3. docs/README.zh-CN.md +20 -2
README.md CHANGED
@@ -8,8 +8,8 @@ Koharu introduces a new workflow for manga translation, utilizing the power of M
8
 
9
  Under the hood, Koharu uses [candle](https://github.com/huggingface/candle) for high-performance inference, and uses [Tauri](https://github.com/tauri-apps/tauri) for the GUI. All components are written in Rust, ensuring safety and speed.
10
 
11
- > [!NOTE]
12
- > Koharu runs ML models **locally** on your machine, ensuring your data privacy. No data is sent to external servers. We guarantee that Koharu does not collect any user data.
13
 
14
  ---
15
 
@@ -117,9 +117,13 @@ The models will be automatically downloaded when you run Koharu for the first ti
117
 
118
  We convert the original models to safetensors format for better performance and compatibility with Rust. The converted models are hosted on [Hugging Face](https://huggingface.co/mayocream).
119
 
120
- ### Large Language Models
121
-
122
- Koharu supports various quantized LLMs in GGUF format via [candle](https://github.com/huggingface/candle), and preselect model based on system locale settings. Supported models and suggested usage:
 
 
 
 
123
 
124
  For translating to English:
125
 
@@ -131,11 +135,25 @@ For translating to Chinese:
131
  - [sakura-galtransl-7b-v3.7](https://huggingface.co/SakuraLLM/Sakura-GalTransl-7B-v3.7): ~6.3 GB and fits on 8 GB VRAM, good balance of quality and speed.
132
  - [sakura-1.5b-qwen2.5-v1.0](https://huggingface.co/shing3232/Sakura-1.5B-Qwen2.5-v1.0-GGUF-IMX): lightweight (≈1.5B, Q5KS); fits on mid-range GPUs (4–6 GB VRAM) or CPU-only setups with moderate RAM, faster than 7B/8B while keeping Qwen-style tokenizer behavior.
133
 
134
- For other languages, you may use:
135
-
136
- - [hunyuan-7b-mt-v1.0](https://huggingface.co/Mungert/Hunyuan-MT-7B-GGUF): ~6.3GB and fits on 8 GB VRAM, decent multi-language translation quality.
137
-
138
- LLMs will be automatically downloaded on demand when you select a model in the settings. Choose the smallest model that meets your quality needs if you are memory-bound; prefer the 7B/8B variants when you have sufficient VRAM/RAM for better translations.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
139
 
140
  ## Installation
141
 
 
8
 
9
  Under the hood, Koharu uses [candle](https://github.com/huggingface/candle) for high-performance inference, and uses [Tauri](https://github.com/tauri-apps/tauri) for the GUI. All components are written in Rust, ensuring safety and speed.
10
 
11
+ > [!NOTE]
12
+ > Koharu runs its vision models and local LLMs **locally** on your machine by default. If you choose a remote LLM provider, Koharu sends translation text only to the provider you configured. Koharu itself does not collect user data.
13
 
14
  ---
15
 
 
117
 
118
  We convert the original models to safetensors format for better performance and compatibility with Rust. The converted models are hosted on [Hugging Face](https://huggingface.co/mayocream).
119
 
120
+ ### Large Language Models
121
+
122
+ Koharu supports both local and remote LLM backends, and preselects a model based on your system locale when possible.
123
+
124
+ #### Local LLMs
125
+
126
+ Koharu supports various quantized LLMs in GGUF format via [candle](https://github.com/huggingface/candle). These models run on your machine and are downloaded on demand when you select them in Settings. Supported models and suggested usage:
127
 
128
  For translating to English:
129
 
 
135
  - [sakura-galtransl-7b-v3.7](https://huggingface.co/SakuraLLM/Sakura-GalTransl-7B-v3.7): ~6.3 GB and fits on 8 GB VRAM, good balance of quality and speed.
136
  - [sakura-1.5b-qwen2.5-v1.0](https://huggingface.co/shing3232/Sakura-1.5B-Qwen2.5-v1.0-GGUF-IMX): lightweight (≈1.5B, Q5KS); fits on mid-range GPUs (4–6 GB VRAM) or CPU-only setups with moderate RAM, faster than 7B/8B while keeping Qwen-style tokenizer behavior.
137
 
138
+ For other languages, you may use:
139
+
140
+ - [hunyuan-7b-mt-v1.0](https://huggingface.co/Mungert/Hunyuan-MT-7B-GGUF): ~6.3GB and fits on 8 GB VRAM, decent multi-language translation quality.
141
+
142
+ LLMs will be automatically downloaded on demand when you select a model in the settings. Choose the smallest model that meets your quality needs if you are memory-bound; prefer the 7B/8B variants when you have sufficient VRAM/RAM for better translations.
143
+
144
+ #### Remote LLMs
145
+
146
+ Koharu can also translate through remote or self-hosted API providers instead of a downloaded local model. Supported remote providers:
147
+
148
+ - OpenAI
149
+ - Gemini
150
+ - Claude
151
+ - DeepSeek
152
+ - OpenAI Compatible, including tools and services such as LM Studio, OpenRouter, or any endpoint that exposes the OpenAI-style `/v1/models` and `/v1/chat/completions` APIs
153
+
154
+ Remote providers are configured in **Settings > API Keys**. For OpenAI Compatible, you also set a custom base URL. API keys are optional for local servers like LM Studio, but typically required for hosted services like OpenRouter.
155
+
156
+ Use remote providers when you want to avoid local model downloads, reduce local VRAM/RAM usage, or connect Koharu to a hosted model. Keep in mind that OCR text selected for translation is sent to the configured provider.
157
 
158
  ## Installation
159
 
docs/README.ja.md CHANGED
@@ -7,7 +7,7 @@ Koharu は、ML の力を活用して翻訳工程を自動化する、新しい
7
  内部では、高性能推論のために [candle](https://github.com/huggingface/candle) を使用し、GUI には [Tauri](https://github.com/tauri-apps/tauri) を採用しています。すべてのコンポーネントが Rust で書かれており、安全性と高速性を両立しています。
8
 
9
  > [!NOTE]
10
- > Koharu は ML モデルを **ローカル(お使いの端末上)** で実行するため、データのプライバシーが保たれます。外部サーバーへデータは送信されません。Koharu はユーザーデータを一切収集しないことを保証します。
11
 
12
  ---
13
 
@@ -116,7 +116,11 @@ Koharu では、性能と Rust との互換性を高めるため、元のモデ
116
 
117
  ### 大規模言語モデル(LLM)
118
 
119
- Koharu は [candle](https://github.com/huggingface/candle) を通じて、GGUF 形式の量子化 LLM を利用できます。また、システムのロケール設定に基づいてモデルを事前選択します。対応モデルと推奨用途は以下の通りです。
 
 
 
 
120
 
121
  英語への翻訳:
122
 
@@ -134,6 +138,20 @@ Koharu は [candle](https://github.com/huggingface/candle) を通じて、GGUF
134
 
135
  LLM は、設定でモデルを選択したタイミングで必要に応じて自動ダウンロードされます。メモリが限られている場合は、品質要件を満たす範囲で最小のモデルを選んでください。十分な VRAM/RAM がある場合は、より良い翻訳のために 7B/8B 系を推奨します。
136
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
137
  ## インストール
138
 
139
  最新のリリースは [releases ページ](https://github.com/mayocream/koharu/releases/latest) からダウンロードできます。
 
7
  内部では、高性能推論のために [candle](https://github.com/huggingface/candle) を使用し、GUI には [Tauri](https://github.com/tauri-apps/tauri) を採用しています。すべてのコンポーネントが Rust で書かれており、安全性と高速性を両立しています。
8
 
9
  > [!NOTE]
10
+ > Koharu は既定で、ビジョンモデルとローカル LLM を **お使いの端末上** で実行します。リモート LLM プロバイダーを選択した場合、翻訳対象のテキストのみが設定したプロバイダーへ送信されます。Koharu 自体がユーザーデータを収集することはありません。
11
 
12
  ---
13
 
 
116
 
117
  ### 大規模言語モデル(LLM)
118
 
119
+ Koharu はローカル LLM とリモート LLM の両方に対応しており、可能な場合はシステムのロケール設定に基づいてモデルを事前選択します。
120
+
121
+ #### ローカル LLM
122
+
123
+ Koharu は [candle](https://github.com/huggingface/candle) を通じて、GGUF 形式の量子化 LLM を利用できます。これらのモデルは端末上で動作し、設定で選択したタイミングで必要に応じて自動ダウンロードされます。対応モデルと推奨用途は以下の通りです。
124
 
125
  英語への翻訳:
126
 
 
138
 
139
  LLM は、設定でモデルを選択したタイミングで必要に応じて自動ダウンロードされます。メモリが限られている場合は、品質要件を満たす範囲で最小のモデルを選んでください。十分な VRAM/RAM がある場合は、より良い翻訳のために 7B/8B 系を推奨します。
140
 
141
+ #### リモート LLM
142
+
143
+ Koharu は、ローカルモデルをダウンロードしなくても、リモートまたはセルフホストの API プロバイダー経由で翻訳できます。対応するリモートプロバイダーは以下の通りです。
144
+
145
+ - OpenAI
146
+ - Gemini
147
+ - Claude
148
+ - DeepSeek
149
+ - OpenAI Compatible: LM Studio、OpenRouter、または OpenAI 形式の `/v1/models` と `/v1/chat/completions` API を提供する任意のエンドポイント
150
+
151
+ リモートプロバイダーは **Settings > API Keys** で設定します。OpenAI Compatible ではカスタムの Base URL も指定します。LM Studio のようなローカルサーバーでは API キーが不要な場合がありますが、OpenRouter のようなホスト型サービスでは通常 API キーが必要です。
152
+
153
+ ローカルモデルのダウンロードを避けたい場合、端末側の VRAM/RAM 使用量を抑えたい場合、またはホスト型モデルへ接続したい場合は、リモートプロバイダーを利用してください。翻訳対象として選択した OCR テキストは、設定したプロバイダーへ送信されます。
154
+
155
  ## インストール
156
 
157
  最新のリリースは [releases ページ](https://github.com/mayocream/koharu/releases/latest) からダウンロードできます。
docs/README.zh-CN.md CHANGED
@@ -7,7 +7,7 @@ Koharu 引入了一种新的漫画翻译工作流,利用机器学习能力自
7
  在底层实现中,Koharu 使用 [candle](https://github.com/huggingface/candle) 进行高性能推理,使用 [Tauri](https://github.com/tauri-apps/tauri) 构建 GUI。所有组件均使用 Rust 编写,兼顾安全性与性能。
8
 
9
  > [!NOTE]
10
- > Koharu 会在你的本地设备上运行 ML 模型,确保数据隐私。不会向外部服务器发送任何数据。我们保证 Koharu 不会收集任何用户数据。
11
 
12
  ---
13
 
@@ -116,7 +116,11 @@ Koharu 在不同任务中使用多个预训练模型:
116
 
117
  ### 大语言模型(LLM)
118
 
119
- Koharu 通过 [candle](https://github.com/huggingface/candle) 支持 GGUF 格式的量化 LLM,并会基于系统语言环境预选模型。支持模型与推荐使用场景如下:
 
 
 
 
120
 
121
  翻译为英文:
122
 
@@ -134,6 +138,20 @@ Koharu 通过 [candle](https://github.com/huggingface/candle) 支持 GGUF 格式
134
 
135
  当你在设置中选择模型时,LLM 会按需自动下载。如果内存受限,建议优先选择满足质量要求的最小模型;若 VRAM/RAM 充足,优先选择 7B/8B 模型以获得更佳翻译效果。
136
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
137
  ## 安装
138
 
139
  你可以在 [releases 页面](https://github.com/mayocream/koharu/releases/latest) 下载 Koharu 的最新版本。
 
7
  在底层实现中,Koharu 使用 [candle](https://github.com/huggingface/candle) 进行高性能推理,使用 [Tauri](https://github.com/tauri-apps/tauri) 构建 GUI。所有组件均使用 Rust 编写,兼顾安全性与性能。
8
 
9
  > [!NOTE]
10
+ > Koharu 默认会在你的本地设备上运行视觉模型和本地 LLM。如果你选择远程 LLM 提供商,只有待翻译的文本会发送到你配置的提供商。Koharu 本身不会收集任何用户数据。
11
 
12
  ---
13
 
 
116
 
117
  ### 大语言模型(LLM)
118
 
119
+ Koharu 同时支持本地和远程 LLM 后端,并会在可能时根据系统语言环境预选模型。
120
+
121
+ #### 本地 LLM
122
+
123
+ Koharu 通过 [candle](https://github.com/huggingface/candle) 支持 GGUF 格式的量化 LLM。这些模型在本机运行,并会在你于设置中选中它们时按需自动下载。支持模型与推荐使用场景如下:
124
 
125
  翻译为英文:
126
 
 
138
 
139
  当你在设置中选择模型时,LLM 会按需自动下载。如果内存受限,建议优先选择满足质量要求的最小模型;若 VRAM/RAM 充足,优先选择 7B/8B 模型以获得更佳翻译效果。
140
 
141
+ #### 远程 LLM
142
+
143
+ Koharu 也可以通过远程或自托管 API 提供商进行翻译,而无需下载本地模型。支持的远程提供商如下:
144
+
145
+ - OpenAI
146
+ - Gemini
147
+ - Claude
148
+ - DeepSeek
149
+ - OpenAI Compatible,包括 LM Studio、OpenRouter,或任何提供 OpenAI 风格 `/v1/models` 和 `/v1/chat/completions` API 的服务
150
+
151
+ 远程提供商在 **Settings > API Keys** 中配置。对于 OpenAI Compatible,你还需要设置自定义 Base URL。像 LM Studio 这样的本地服务通常可以不填 API Key,而 OpenRouter 这类托管服务通常需要 API Key。
152
+
153
+ 如果你希望避免下载本地模型、减少本地 VRAM/RAM 占用,或者希望接入托管模型,可以选择远程提供商。需要注意的是,被选中用于翻译的 OCR 文本会发送到所配置的提供商。
154
+
155
  ## 安装
156
 
157
  你可以在 [releases 页面](https://github.com/mayocream/koharu/releases/latest) 下载 Koharu 的最新版本。