2026-03-28 23:19:13 +08:00
|
|
|
|
# YOYO翻译工具配置文件
|
|
|
|
|
|
# 注意:API密钥使用环境变量,不要直接写入真实密钥
|
|
|
|
|
|
|
|
|
|
|
|
default_provider: "siliconflow"
|
|
|
|
|
|
default_model: "gpt-3.5-turbo"
|
|
|
|
|
|
timeout: 30
|
2026-04-06 05:07:36 +08:00
|
|
|
|
default_source_lang: "auto" # 默认源语言(auto为自动检测)
|
|
|
|
|
|
default_target_lang: "zh-CN" # 默认目标语言(简体中文)
|
2026-03-28 23:19:13 +08:00
|
|
|
|
|
|
|
|
|
|
providers:
|
|
|
|
|
|
siliconflow:
|
|
|
|
|
|
api_host: "https://api.siliconflow.cn/v1"
|
|
|
|
|
|
api_key: "${SILICONFLOW_API_KEY}"
|
2026-04-06 05:07:36 +08:00
|
|
|
|
model: "${SILICONFLOW_MODEL}"
|
2026-03-28 23:19:13 +08:00
|
|
|
|
enabled: true
|
2026-04-06 05:07:36 +08:00
|
|
|
|
|
2026-03-28 23:19:13 +08:00
|
|
|
|
volcano:
|
|
|
|
|
|
api_host: "https://api.volcengine.com/v1"
|
|
|
|
|
|
api_key: "${VOLCANO_API_KEY}"
|
|
|
|
|
|
model: "volcano-chat"
|
|
|
|
|
|
enabled: true
|
2026-04-06 05:07:36 +08:00
|
|
|
|
|
2026-03-28 23:19:13 +08:00
|
|
|
|
national:
|
|
|
|
|
|
api_host: "https://api.nsc.gov.cn/v1"
|
|
|
|
|
|
api_key: "${NATIONAL_API_KEY}"
|
|
|
|
|
|
model: "nsc-base"
|
|
|
|
|
|
enabled: false
|
2026-04-06 05:07:36 +08:00
|
|
|
|
|
2026-03-28 23:19:13 +08:00
|
|
|
|
qwen:
|
|
|
|
|
|
api_host: "https://dashscope.aliyuncs.com/compatible-mode/v1"
|
|
|
|
|
|
api_key: "${QWEN_API_KEY}"
|
|
|
|
|
|
model: "qwen-turbo"
|
|
|
|
|
|
enabled: true
|
2026-04-06 05:07:36 +08:00
|
|
|
|
|
2026-03-28 23:19:13 +08:00
|
|
|
|
openai:
|
|
|
|
|
|
api_host: "https://api.openai.com/v1"
|
|
|
|
|
|
api_key: "${OPENAI_API_KEY}"
|
|
|
|
|
|
model: "gpt-3.5-turbo"
|
|
|
|
|
|
enabled: true
|
|
|
|
|
|
|
|
|
|
|
|
prompts:
|
|
|
|
|
|
technical: "你是一位专业的技术翻译,请准确翻译以下技术文档,保持专业术语的准确性。"
|
|
|
|
|
|
creative: "你是一位富有创造力的翻译家,请用优美流畅的语言翻译以下内容。"
|
|
|
|
|
|
academic: "你是一位学术翻译专家,请用严谨的学术语言翻译以下内容。"
|
2026-03-29 21:10:28 +08:00
|
|
|
|
simple: "请用简单易懂的语言翻译以下内容。"
|
|
|
|
|
|
|
|
|
|
|
|
# 缓存配置
|
|
|
|
|
|
cache:
|
2026-04-06 05:07:36 +08:00
|
|
|
|
enabled: true # 是否启用缓存
|
|
|
|
|
|
max_records: 10000 # 最大缓存记录数
|
|
|
|
|
|
expire_days: 30 # 缓存过期天数
|
|
|
|
|
|
db_path: "~/.config/yoyo/cache.db" # 缓存数据库文件路径
|