The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
refactor: hoist strip_images_for_rejecting_model import to module level
kshitijk4poora955e90422f4
diff --git a/agent/turn_api_request.py b/agent/turn_api_request.pyindex e1e872c56ba..b00934cc722 100644--- a/agent/turn_api_request.py+++ b/agent/turn_api_request.py@@ -12,7 +12,7 @@ from dataclasses import dataclassimport loggingfrom typing import Any-from agent.message_sanitization import sanitize_outbound_kwargs+from agent.message_sanitization import sanitize_outbound_kwargs, strip_images_for_rejecting_modelfrom utils import env_var_enabledlogger = logging.getLogger("agent.conversation_loop")@@ -115,7 +115,6 @@ def build_api_request())# A model that rejected image content gets text only; history keeps the images.- from agent.message_sanitization import strip_images_for_rejecting_modelstrip_images_for_rejecting_model(agent, api_messages)if tools_for_api == agent.tools:api_kwargs = agent._build_api_kwargs(api_messages)