From 2fa6571bee89263ea94a33b1fc95075817855bc3 Mon Sep 17 00:00:00 2001 From: chenxv399 Date: Fri, 10 Jan 2025 01:57:25 +0800 Subject: [PATCH] =?UTF-8?q?chore(env):=20=E6=9B=B4=E6=96=B0=E7=8E=AF?= =?UTF-8?q?=E5=A2=83=E5=8F=98=E9=87=8F=E6=A8=A1=E6=9D=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 增加了多个 AI 服务提供商的 API 密钥和 URL 配置选项 - 调整了现有环境变量的默认值 - 移除了不必要的注释 - 统一了配置项的格式 --- .env.template | 166 ++++++++++++++++++++++++++++++++++++++++---------- 1 file changed, 135 insertions(+), 31 deletions(-) diff --git a/.env.template b/.env.template index 82f44216a..08cb4e08e 100644 --- a/.env.template +++ b/.env.template @@ -1,69 +1,173 @@ # Your openai api key. (required) -OPENAI_API_KEY=sk-xxxx +OPENAI_API_KEY=sk-qTS3PrtdclgVqsxxC6D17a6dDcBf41A9B161B652686b5a05 # Access password, separated by comma. (optional) -CODE=your-password - -# You can start service behind a proxy. (optional) -PROXY_URL=http://localhost:7890 - -# (optional) -# Default: Empty -# Google Gemini Pro API key, set if you want to use Google Gemini Pro API. -GOOGLE_API_KEY= - -# (optional) -# Default: https://generativelanguage.googleapis.com/ -# Google Gemini Pro API url without pathname, set if you want to customize Google Gemini Pro API url. -GOOGLE_URL= +CODE=kEGSsH4uL83qGX76HftII5YF1wQPBD0H # Override openai api request base url. (optional) # Default: https://api.openai.com # Examples: http://your-openai-proxy.com -BASE_URL= +BASE_URL=https://api.v36.cm # Specify OpenAI organization ID.(optional) # Default: Empty -OPENAI_ORG_ID= +# OPENAI_ORG_ID= # (optional) # Default: Empty -# If you do not want users to use GPT-4, set this value to 1. -DISABLE_GPT4= +# Azure deployment address. +# AZURE_URL= + +# (optional) +# Default: Empty +# Azure key. +# AZURE_API_KEY= + +# (optional) +# Default: Empty +# Azure Api version, you can find it here: [Azure 文档](https://learn.microsoft.com/en-us/azure/ai-services/openai/reference#chat-completions). +# AZURE_API_VERSION= + +# (optional) +# Default: Empty +# Google Gemini Pro API key, set if you want to use Google Gemini Pro API. +GOOGLE_API_KEY=AIzaSyBoKioGhps3Pd7eMq9gc4RJODFTRAgEzs4 + +# (optional) +# Default: https://generativelanguage.googleapis.com/ +# Google Gemini Pro API url without pathname, set if you want to customize Google Gemini Pro API url. +GOOGLE_URL=https://gateway.ai.cloudflare.com/v1/a88e81836495f2ae58ca34afc7d12dec/utopiai/google-ai-studio + +# anthropic claude Api Key.(optional) +ANTHROPIC_API_KEY=sk-qTS3PrtdclgVqsxxC6D17a6dDcBf41A9B161B652686b5a05 + +### anthropic claude Api version. (optional) +# ANTHROPIC_API_VERSION= + +### anthropic claude Api url (optional) +ANTHROPIC_URL=https://api.v36.cm + +# (optional) +# Default: Empty +# Baidu Api Key. +# BAIDU_API_KEY= + +# (optional) +# Default: Empty +# Baidu Secret Key. +# BAIDU_SECRET_KEY= + +# (optional) +# Default: Empty +# Baidu Api Url. +# BAIDU_URL= + +# (optional) +# Default: Empty +# ByteDance Api Key. +# BYTEDANCE_API_KEY= + +# (optional) +# Default: Empty +# ByteDance Api Url. +# BYTEDANCE_URL= + +# (optional) +# Default: Empty +# 阿里云(千问)Api Key. +ALIBABA_API_KEY=sk-73081f4f943b44e3a3fd3ba52065d064 + +# (optional) +# Default: Empty +# 阿里云(千问)Api Url. +ALIBABA_URL=https://dashscope.aliyuncs.com/compatible-mode/v1/chat/completions + +# (optional) +# Default: Empty +# 讯飞星火Api Url. +# IFLYTEK_URL= + +# (optional) +# Default: Empty +# 讯飞星火Api Key. +# IFLYTEK_API_KEY= + +# (optional) +# Default: Empty +# 讯飞星火Api Secret. +# IFLYTEK_API_SECRET= + +# (optional) +# Default: Empty +# ChatGLM Api Key. +# CHATGLM_API_KEY= + +# (optional) +# Default: Empty +# ChatGLM Api Url. +# CHATGLM_URL= + +# (optional) +# Default: Empty +# DeepSeek Api Key. +# DEEPSEEK_API_KEY= + +# (optional) +# Default: Empty +# DeepSeek Api Url. +# DEEPSEEK_URL= # (optional) # Default: Empty # If you do not want users to input their own API key, set this value to 1. -HIDE_USER_API_KEY= +HIDE_USER_API_KEY=1 + +# (optional) +# Default: Empty +# If you do not want users to use GPT-4, set this value to 1. +# DISABLE_GPT4= # (optional) # Default: Empty # If you do want users to query balance, set this value to 1. -ENABLE_BALANCE_QUERY= +# ENABLE_BALANCE_QUERY= # (optional) # Default: Empty # If you want to disable parse settings from url, set this value to 1. -DISABLE_FAST_LINK= +DISABLE_FAST_LINK=1 # (optional) # Default: Empty # To control custom models, use + to add a custom model, use - to hide a model, use name=displayName to customize model name, separated by comma. -CUSTOM_MODELS= +CUSTOM_MODELS='-all,+gpt-3.5-turbo,+gpt-3.5-turbo-16k,+gpt-4,+gpt-4-32k,+gpt-4-turbo,+gpt-4-vision-preview,+gpt-4o,+gpt-4o-mini,+dall-e-3,+o1-mini,+o1-preview,+tts-1,+tts-1-hd,+gpt-4o-all,+claude-3-5-haiku-20241022,+claude-3-5-sonnet-20241022,+claude-3-5-sonnet-all,+gemini-1.5-pro-latest,+gemini-1.5-flash-latest,+gemini-2.0-flash-exp,+qwen-max,+qwen-plus,+qwen-turbo,+qwq-32b-preview,+qwen2.5-72b-instruct,+qwen2.5-32b-instruct,+qwen2.5-14b-instruct,+qwen2.5-7b-instruct,+qwen2-72b-instruct,+qwen2-57b-a14b-instruct,+qwen2-7b-instruct' # (optional) # Default: Empty # Change default model -DEFAULT_MODEL= +DEFAULT_MODEL=qwen-plus -# anthropic claude Api Key.(optional) -ANTHROPIC_API_KEY= +# (optional) +# Default: Empty +# To add more models with vision ability, use comma to separate them. +# VISION_MODELS= -### anthropic claude Api version. (optional) -ANTHROPIC_API_VERSION= +# (optional) +# Default: Empty +# Custom default template, used to initialize '设置' -> '用户输入预处理' configuration item +# DEFAULT_INPUT_TEMPLATE= -### anthropic claude Api url (optional) -ANTHROPIC_URL= +# (optional) +# Default: Empty +# Stability API key +# STABILITY_API_KEY= + +# (optional) +# Default: Empty +# Custom Stability API request url +# STABILITY_URL= ### (optional) -WHITE_WEBDAV_ENDPOINTS= \ No newline at end of file +# WHITE_WEBDAV_ENDPOINTS= + +PROXY_URL=https://ai.utopias.site \ No newline at end of file