Skip to content

πŸ™Œ OpenHands: AI-Driven Development

Make agents follow configured temperature (#4099)

Engel Nystf994277d0f17
diff --git a/agenthub/browsing_agent/browsing_agent.py b/agenthub/browsing_agent/browsing_agent.py
index 232b5ddb99..bf1e01336d 100644
--- a/agenthub/browsing_agent/browsing_agent.py
+++ b/agenthub/browsing_agent/browsing_agent.py
@@ -218,7 +218,6 @@ class BrowsingAgent(Agent):
response = self.llm.completion(
messages=self.llm.format_messages_for_llm(messages),
- temperature=0.0,
stop=[')```', ')\n```'],
)
return self.response_parser.parse(response)
diff --git a/agenthub/codeact_swe_agent/codeact_swe_agent.py b/agenthub/codeact_swe_agent/codeact_swe_agent.py
index db3003ff6a..ac3efbe535 100644
--- a/agenthub/codeact_swe_agent/codeact_swe_agent.py
+++ b/agenthub/codeact_swe_agent/codeact_swe_agent.py
@@ -166,7 +166,6 @@ class CodeActSWEAgent(Agent):
'</execute_ipython>',
'</execute_bash>',
],
- temperature=0.0,
)
return self.response_parser.parse(response)
diff --git a/agenthub/micro/agent.py b/agenthub/micro/agent.py
index 3e3a9803f1..cac4ed78da 100644
--- a/agenthub/micro/agent.py
+++ b/agenthub/micro/agent.py
@@ -78,7 +78,6 @@ class MicroAgent(Agent):
message = Message(role='user', content=content)
resp = self.llm.completion(
messages=self.llm.format_messages_for_llm(message),
- temperature=0.0,
)
action_resp = resp['choices'][0]['message']['content']
action = parse_response(action_resp)
diff --git a/config.template.toml b/config.template.toml
index 663c81c467..6e4683138d 100644
--- a/config.template.toml
+++ b/config.template.toml
@@ -112,7 +112,7 @@ api_key = "your-api-key"
#embedding_deployment_name = ""
# Embedding model to use
-embedding_model = ""
+embedding_model = "local"
# Maximum number of characters in an observation's content
#max_message_chars = 10000
@@ -188,7 +188,7 @@ model = "gpt-4o-mini"
#memory_max_threads = 2
# LLM config group to use
-#llm_config = 'llm'
+#llm_config = 'your-llm-config-group'
[agent.RepoExplorerAgent]
# Example: use a cheaper model for RepoExplorerAgent to reduce cost, especially
@@ -232,7 +232,7 @@ llm_config = 'gpt3'
[security]
# Enable confirmation mode
-#confirmation_mode = true
+#confirmation_mode = false
# The security analyzer to use
#security_analyzer = ""