2023-09-09 16:21:38 -06:00
|
|
|
# To customize your server, make a copy of this file to `.env` and edit any
|
|
|
|
# values you want to change. Be sure to remove the `#` at the beginning of each
|
|
|
|
# line you want to modify.
|
2023-04-08 05:02:59 -06:00
|
|
|
|
2023-09-09 16:21:38 -06:00
|
|
|
# All values have reasonable defaults, so you only need to change the ones you
|
|
|
|
# want to override.
|
|
|
|
|
|
|
|
# ------------------------------------------------------------------------------
|
|
|
|
# General settings:
|
|
|
|
|
|
|
|
# The title displayed on the info page.
|
2023-05-15 15:47:30 -06:00
|
|
|
# SERVER_TITLE=Coom Tunnel
|
2023-09-09 16:21:38 -06:00
|
|
|
|
|
|
|
# Model requests allowed per minute per user.
|
2023-04-10 04:39:13 -06:00
|
|
|
# MODEL_RATE_LIMIT=4
|
2023-09-09 16:21:38 -06:00
|
|
|
|
|
|
|
# Max number of output tokens a user can request at once.
|
2023-06-07 18:58:57 -06:00
|
|
|
# MAX_OUTPUT_TOKENS_OPENAI=300
|
2023-09-09 16:21:38 -06:00
|
|
|
# MAX_OUTPUT_TOKENS_ANTHROPIC=400
|
|
|
|
|
|
|
|
# Whether to show the estimated cost of consumed tokens on the info page.
|
|
|
|
# SHOW_TOKEN_COSTS=false
|
|
|
|
|
|
|
|
# Whether to automatically check API keys for validity.
|
|
|
|
# Note: CHECK_KEYS is disabled by default in local development mode, but enabled
|
|
|
|
# by default in production mode.
|
2023-05-15 15:47:30 -06:00
|
|
|
# CHECK_KEYS=true
|
2023-09-09 16:21:38 -06:00
|
|
|
|
|
|
|
# Which model types users are allowed to access.
|
2023-08-29 16:56:54 -06:00
|
|
|
# ALLOWED_MODEL_FAMILIES=claude,turbo,gpt4,gpt4-32k
|
2023-09-09 16:21:38 -06:00
|
|
|
|
|
|
|
# URLs from which requests will be blocked.
|
2023-05-22 15:08:20 -06:00
|
|
|
# BLOCKED_ORIGINS=reddit.com,9gag.com
|
2023-09-09 16:21:38 -06:00
|
|
|
# Message to show when requests are blocked.
|
2023-05-22 15:08:20 -06:00
|
|
|
# BLOCK_MESSAGE="You must be over the age of majority in your country to use this service."
|
2023-09-09 16:21:38 -06:00
|
|
|
# Destination to redirect blocked requests to.
|
2023-05-22 15:08:20 -06:00
|
|
|
# BLOCK_REDIRECT="https://roblox.com/"
|
2023-04-14 19:21:04 -06:00
|
|
|
|
2023-09-09 16:21:38 -06:00
|
|
|
# Whether to reject requests containing disallowed content.
|
|
|
|
# REJECT_DISALLOWED=false
|
|
|
|
# Message to show when requests are rejected.
|
|
|
|
# REJECT_MESSAGE="This content violates /aicg/'s acceptable use policy."
|
|
|
|
|
|
|
|
# Whether prompts should be logged to Google Sheets.
|
|
|
|
# Requires additional setup. See `docs/google-sheets.md` for more information.
|
|
|
|
# PROMPT_LOGGING=false
|
|
|
|
|
|
|
|
# The port to listen on.
|
|
|
|
# PORT=7860
|
|
|
|
|
|
|
|
# Detail level of logging. (trace | debug | info | warn | error)
|
|
|
|
# LOG_LEVEL=info
|
|
|
|
|
|
|
|
# ------------------------------------------------------------------------------
|
|
|
|
# Optional settings for user management, access control, and quota enforcement:
|
|
|
|
# See `docs/user-management.md` for more information and setup instructions.
|
|
|
|
# See `docs/user-quotas.md` to learn how to set up quotas.
|
2023-04-14 19:21:04 -06:00
|
|
|
|
2023-10-02 14:39:30 -06:00
|
|
|
# Which access control method to use. (none | proxy_key | user_token)
|
2023-05-13 22:26:08 -06:00
|
|
|
# GATEKEEPER=none
|
2023-09-09 16:21:38 -06:00
|
|
|
# Which persistence method to use. (memory | firebase_rtdb)
|
2023-05-14 13:30:32 -06:00
|
|
|
# GATEKEEPER_STORE=memory
|
2023-09-09 16:21:38 -06:00
|
|
|
|
|
|
|
# Maximum number of unique IPs a user can connect from. (0 for unlimited)
|
|
|
|
# MAX_IPS_PER_USER=0
|
|
|
|
|
|
|
|
# With user_token gatekeeper, whether to allow users to change their nickname.
|
|
|
|
# ALLOW_NICKNAME_CHANGES=true
|
|
|
|
|
|
|
|
# Default token quotas for each model family. (0 for unlimited)
|
2023-08-28 13:33:14 -06:00
|
|
|
# TOKEN_QUOTA_TURBO=0
|
|
|
|
# TOKEN_QUOTA_GPT4=0
|
2023-09-09 16:21:38 -06:00
|
|
|
# TOKEN_QUOTA_GPT4_32K=0
|
2023-08-28 13:33:14 -06:00
|
|
|
# TOKEN_QUOTA_CLAUDE=0
|
2023-05-13 22:26:08 -06:00
|
|
|
|
2023-09-09 16:21:38 -06:00
|
|
|
# How often to refresh token quotas. (hourly | daily)
|
|
|
|
# Leave unset to never automatically refresh quotas.
|
|
|
|
# QUOTA_REFRESH_PERIOD=daily
|
2023-04-14 19:21:04 -06:00
|
|
|
|
|
|
|
# ------------------------------------------------------------------------------
|
2023-09-09 16:21:38 -06:00
|
|
|
# Secrets and keys:
|
|
|
|
# Do not put any passwords or API keys directly in this file.
|
2023-05-15 15:47:30 -06:00
|
|
|
# For Huggingface, set them via the Secrets section in your Space's config UI.
|
|
|
|
# For Render, create a "secret file" called .env using the Environment tab.
|
2023-04-14 19:21:04 -06:00
|
|
|
|
2023-09-09 16:21:38 -06:00
|
|
|
# You can add multiple API keys by separating them with a comma.
|
2023-09-30 19:40:18 -06:00
|
|
|
# For AWS credentials, separate the access key ID, secret key, and region with a colon.
|
2023-04-14 19:21:04 -06:00
|
|
|
OPENAI_KEY=sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
2023-05-29 21:13:17 -06:00
|
|
|
ANTHROPIC_KEY=sk-ant-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
2023-10-03 19:29:42 -06:00
|
|
|
# See `config.ts` for details on setting up Amazon Bedrock credentials.
|
2023-09-30 19:40:18 -06:00
|
|
|
AWS_CREDENTIALS=myaccesskeyid:mysecretkey:us-east-1,anotheraccesskeyid:anothersecretkey:us-west-2
|
2023-04-14 19:21:04 -06:00
|
|
|
|
2023-09-09 16:21:38 -06:00
|
|
|
# With proxy_key gatekeeper, the password users must provide to access the API.
|
2023-04-14 19:21:04 -06:00
|
|
|
# PROXY_KEY=your-secret-key
|
|
|
|
|
2023-09-09 16:21:38 -06:00
|
|
|
# With user_token gatekeeper, the admin password used to manage users.
|
2023-05-13 22:26:08 -06:00
|
|
|
# ADMIN_KEY=your-very-secret-key
|
|
|
|
|
2023-09-09 16:21:38 -06:00
|
|
|
# With firebase_rtdb gatekeeper storage, the Firebase project credentials.
|
2023-05-13 22:26:08 -06:00
|
|
|
# FIREBASE_KEY=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
|
|
|
# FIREBASE_RTDB_URL=https://xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.firebaseio.com
|
|
|
|
|
2023-09-09 16:21:38 -06:00
|
|
|
# With prompt logging, the Google Sheets credentials.
|
2023-04-14 19:21:04 -06:00
|
|
|
# GOOGLE_SHEETS_SPREADSHEET_ID=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
|
|
|
# GOOGLE_SHEETS_KEY=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|