Spaces:
Runtime error
Runtime error
Update agent.py to switch the LLM model from Gemini to OpenAI's GPT-4.1, adjusting the API key accordingly for improved performance and compatibility.
Browse files
agent.py
CHANGED
@@ -10,7 +10,7 @@ import io # Added for StringIO
|
|
10 |
load_dotenv()
|
11 |
|
12 |
# Configure the underlying LLM model for the agent - using a vision-capable model
|
13 |
-
smol_model = LiteLLMModel(model_id="
|
14 |
|
15 |
# Instantiate the CodeAgent with authorized imports
|
16 |
# Removed base64, litellm. Kept PIL for now, though framework might handle image display.
|
|
|
10 |
load_dotenv()
|
11 |
|
12 |
# Configure the underlying LLM model for the agent - using a vision-capable model
|
13 |
+
smol_model = LiteLLMModel(model_id="openai/gpt-4.1", api_key=os.getenv("OPENAI_API_KEY"))
|
14 |
|
15 |
# Instantiate the CodeAgent with authorized imports
|
16 |
# Removed base64, litellm. Kept PIL for now, though framework might handle image display.
|