Update GROK_API_KEY to XAI_API_KEY

This commit is contained in:
Mark Backman
2026-03-25 23:23:58 -04:00
parent 54a17ab1f3
commit 6d1918f12a
7 changed files with 11 additions and 11 deletions

View File

@@ -80,9 +80,6 @@ GOOGLE_TEST_CREDENTIALS=...
# Gradium # Gradium
GRAPDIUM_API_KEY=... GRAPDIUM_API_KEY=...
# Grok
GROK_API_KEY=...
# Groq # Groq
GROQ_API_KEY=... GROQ_API_KEY=...
@@ -215,3 +212,6 @@ WHATSAPP_TOKEN=...
WHATSAPP_WEBHOOK_VERIFICATION_TOKEN=... WHATSAPP_WEBHOOK_VERIFICATION_TOKEN=...
WHATSAPP_PHONE_NUMBER_ID=... WHATSAPP_PHONE_NUMBER_ID=...
WHATSAPP_APP_SECRET=... WHATSAPP_APP_SECRET=...
# xAI / Grok
XAI_API_KEY=...

View File

@@ -56,7 +56,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments):
stt = DeepgramSTTService(api_key=os.getenv("DEEPGRAM_API_KEY")) stt = DeepgramSTTService(api_key=os.getenv("DEEPGRAM_API_KEY"))
tts = XAIHttpTTSService( tts = XAIHttpTTSService(
api_key=os.getenv("GROK_API_KEY"), api_key=os.getenv("XAI_API_KEY"),
aiohttp_session=session, aiohttp_session=session,
settings=XAIHttpTTSService.Settings( settings=XAIHttpTTSService.Settings(
voice="eve", voice="eve",
@@ -64,7 +64,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments):
) )
llm = GrokLLMService( llm = GrokLLMService(
api_key=os.getenv("GROK_API_KEY"), api_key=os.getenv("XAI_API_KEY"),
settings=GrokLLMService.Settings( settings=GrokLLMService.Settings(
system_instruction="You are a helpful assistant in a voice conversation. Your responses will be spoken aloud, so avoid emojis, bullet points, or other formatting that can't be spoken. Respond to what the user said in a creative, helpful, and brief way.", system_instruction="You are a helpful assistant in a voice conversation. Your responses will be spoken aloud, so avoid emojis, bullet points, or other formatting that can't be spoken. Respond to what the user said in a creative, helpful, and brief way.",
), ),

View File

@@ -65,7 +65,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments):
stt = DeepgramSTTService(api_key=os.getenv("DEEPGRAM_API_KEY")) stt = DeepgramSTTService(api_key=os.getenv("DEEPGRAM_API_KEY"))
tts = XAIHttpTTSService( tts = XAIHttpTTSService(
api_key=os.getenv("GROK_API_KEY"), api_key=os.getenv("XAI_API_KEY"),
aiohttp_session=session, aiohttp_session=session,
settings=XAIHttpTTSService.Settings( settings=XAIHttpTTSService.Settings(
voice="eve", voice="eve",
@@ -73,7 +73,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments):
) )
llm = GrokLLMService( llm = GrokLLMService(
api_key=os.getenv("GROK_API_KEY"), api_key=os.getenv("XAI_API_KEY"),
settings=GrokLLMService.Settings( settings=GrokLLMService.Settings(
system_instruction="You are a helpful assistant in a voice conversation. Your responses will be spoken aloud, so avoid emojis, bullet points, or other formatting that can't be spoken. Respond to what the user said in a creative, helpful, and brief way.", system_instruction="You are a helpful assistant in a voice conversation. Your responses will be spoken aloud, so avoid emojis, bullet points, or other formatting that can't be spoken. Respond to what the user said in a creative, helpful, and brief way.",
), ),

View File

@@ -192,7 +192,7 @@ Remember, your responses should be short - just one or two sentences usually."""
) )
llm = GrokRealtimeLLMService( llm = GrokRealtimeLLMService(
api_key=os.getenv("GROK_API_KEY"), api_key=os.getenv("XAI_API_KEY"),
session_properties=session_properties, session_properties=session_properties,
) )

View File

@@ -179,7 +179,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments):
# Create the Grok Realtime LLM service # Create the Grok Realtime LLM service
llm = GrokRealtimeLLMService( llm = GrokRealtimeLLMService(
api_key=os.getenv("GROK_API_KEY"), api_key=os.getenv("XAI_API_KEY"),
settings=GrokRealtimeLLMService.Settings( settings=GrokRealtimeLLMService.Settings(
system_instruction="""You are a helpful and friendly AI assistant powered by Grok. system_instruction="""You are a helpful and friendly AI assistant powered by Grok.

View File

@@ -50,7 +50,7 @@ transport_params = {
async def run_bot(transport: BaseTransport, runner_args: RunnerArguments): async def run_bot(transport: BaseTransport, runner_args: RunnerArguments):
logger.info(f"Starting bot") logger.info(f"Starting bot")
llm = GrokRealtimeLLMService(api_key=os.getenv("GROK_API_KEY")) llm = GrokRealtimeLLMService(api_key=os.getenv("XAI_API_KEY"))
messages = [ messages = [
{ {

View File

@@ -60,7 +60,7 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments):
) )
llm = GrokLLMService( llm = GrokLLMService(
api_key=os.getenv("GROK_API_KEY"), api_key=os.getenv("XAI_API_KEY"),
settings=GrokLLMService.Settings( settings=GrokLLMService.Settings(
system_instruction="You are a helpful assistant in a voice conversation. Your responses will be spoken aloud, so avoid emojis, bullet points, or other formatting that can't be spoken. Respond to what the user said in a creative, helpful, and brief way.", system_instruction="You are a helpful assistant in a voice conversation. Your responses will be spoken aloud, so avoid emojis, bullet points, or other formatting that can't be spoken. Respond to what the user said in a creative, helpful, and brief way.",
), ),