Skip to content

Commit

Permalink
fix(): fix api_key
Browse files Browse the repository at this point in the history
  • Loading branch information
sunshinexcode committed Aug 6, 2024
1 parent a3e846f commit af9aae7
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
3 changes: 2 additions & 1 deletion agents/addon/extension/litellm_python/litellm.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def __init__(self,
def default_config(cls):
return cls(
api_key="",
base_url="https://api.openai.com/v1",
base_url="",
max_tokens=512,
model="gpt-4o-mini",
prompt="You are a voice assistant who talks in a conversational way and can chat with me like my friends. I will speak to you in English or Chinese, and you will answer in the corrected and improved version of my text with the language I use. Don’t talk like a robot, instead I would like you to talk like a real human with emotions. I will use your answer for text-to-speech, so don’t return me any meaningless characters. I want you to be helpful, when I’m asking you for advice, give me precise, practical and useful advice instead of being vague. When giving me a list of options, express the options in a narrative way instead of bullet points.",
Expand All @@ -51,6 +51,7 @@ def __init__(self, config: LiteLLMConfig):

def get_chat_completions_stream(self, messages: List[Dict[str, str]]):
kwargs = {
"api_key": self.config.api_key,
"base_url": self.config.base_url,
"custom_llm_provider": self.config.provider,
"frequency_penalty": self.config.frequency_penalty,
Expand Down
1 change: 1 addition & 0 deletions agents/property.json.example
Original file line number Diff line number Diff line change
Expand Up @@ -1211,6 +1211,7 @@
"max_memory_length": 10,
"max_tokens": 512,
"model": "gpt-3.5-turbo",
"presence_penalty": 0.9,
"prompt": "",
"provider": "openai",
"temperature": 0.1,
Expand Down
3 changes: 3 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ services:
AZURE_TTS_REGION: ${AZURE_TTS_REGION}
COSY_TTS_KEY: ${COSY_TTS_KEY}
ELEVENLABS_TTS_KEY: ${ELEVENLABS_TTS_KEY}
LITELLM_API_KEY: ${LITELLM_API_KEY}
LITELLM_MODEL: ${LITELLM_MODEL}
LITELLM_PROVIDER: ${LITELLM_PROVIDER}
OPENAI_API_KEY: ${OPENAI_API_KEY}
OPENAI_BASE_URL: ${OPENAI_BASE_URL}
OPENAI_MODEL: ${OPENAI_MODEL}
Expand Down

0 comments on commit af9aae7

Please sign in to comment.