# ----------------------------------------------- #
# Make a copy of this file and rename it to .env  #
#                                                 #
#        Also check out our documentation:        #
#   https://askrella.github.io/whatsapp-chatgpt   #
# ----------------------------------------------- #

# Get your key here: https://platform.openai.com/account/api-keys
OPENAI_API_KEY=sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

# HuggingFace API Token https://huggingface.co/settings/tokens
HUGGINGFACE_API_TOKEN=hf_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

# In case you run into ratelimit on a single organization token, you might setting up multiple API keys here
# Example:
# OPENAI_API_KEYS=sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx,sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

# GPT Model (default: gpt-3.5-turbo)
OPENAI_GPT_MODEL=

# Max tokens to use for GPT per request
MAX_MODEL_TOKENS=2000

# GPT Pre Prompt, executed after creating a conversation
# Example: Act very funny and overreact to messages. Do that for every message you get, forever.
PRE_PROMPT=

# Whether or not to use prefixes !gpt and !dalle
PREFIX_ENABLED=true

# Whether or not to use prefixes for self-note conversation
PREFIX_SKIPPED_FOR_ME=true

# Set own prefixes for ChatGPT, DALL-E, reset context, configuration
GPT_PREFIX=!gpt
DALLE_PREFIX=!dalle
RESET_PREFIX=!reset
AI_CONFIG_PREFIX=!config

# Whether or not to allow the bot interacting on groupchats
GROUPCHATS_ENABLED=false

# Prompt Moderation
# If enabled, the bot will check any prompts submitted by users with the OpenAI Moderation API
# If the prompt is classified as any of the categories in the blacklisted categories, the prompt will be rejected
# You can find the available categories here: https://beta.openai.com/docs/api-reference/moderations
PROMPT_MODERATION_ENABLED = true
PROMPT_MODERATION_BLACKLISTED_CATEGORIES = ["hate", "hate/threatening", "self-harm", "sexual", "sexual/minors", "violence", "violence/graphic"]

# Access control, only allow whatsapp-chatgpt to react to specific phone numbers, comma-separated
WHITELISTED_PHONE_NUMBERS=
WHITELISTED_ENABLED=false
# Speech API URL
# You can use host your own Speech API
# https://github.com/askrella/speech-rest-api
SPEECH_API_URL=

# Whisper API

# API Key
WHISPER_API_KEY=

# You can use Whisper API for voice transcription
WHISPER_API_URL=https://transcribe.whisperapi.com

# Defines if the bot should recognize and transcribe your voice messages
TRANSCRIPTION_ENABLED=false

# Defines if the bot should use the local or remote transcription service
# "local" = You need to have "whisper" installed on your machine
# "openai" = It will use Open AI's transcription API with whisper-1 model
# "speech-api" = It will use our Speech API to transcribe your voice messages
# "whisper-api" = It will use whisper's API  to transcribe your voice messages
TRANSCRIPTION_MODE=local

# Define the language of transcription, depends on transcriber it might auto-detect if not given
TRANSCRIPTION_LANGUAGE=

# Defines if the bot should send voice message responses (text-to-speech)
# Be aware that this feature will use the Speech API to convert the GPT response to voice
# It's open source: https://github.com/askrella/speech-rest-api
TTS_ENABLED=false

# Defines if the bot should return the TTS response as a text message too
# If enabled, the bot will send the text response and the voice message
TTS_TRANSCRIPTION_RESPONSE_ENABLED=true

# Defines if the bot should use the Speech API or AWS Polly to convert text to speech
# "speech-api" = It will use our Speech API to transcribe your voice messages
# "aws-polly" = It will use AWS Polly to convert text to speech
TTS_MODE=speech-api

# AWS Config
# You can use AWS Polly to convert text to speech
# You need to have an AWS account and create an IAM user with Polly permissions
# You can find the available voices here: https://docs.aws.amazon.com/polly/latest/dg/voicelist.html
# For the Voice Engine, you can use "standard" or "neural", make sure to use the correct voice for the engine
AWS_ACCESS_KEY_ID=xxxxxxxxxxxxxxxxxxxx
AWS_SECRET_ACCESS_KEY=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
AWS_REGION=eu-central-1
AWS_POLLY_VOICE_ID=Joanna
AWS_POLLY_VOICE_ENGINE=standard

# LangChain Tool Config https://js.langchain.com/docs/modules/agents/tools/
SERPAPI_API_KEY=xxxxxxxxx
