enable_thinking
This commit is contained in:
parent
fc5c1adaaa
commit
c1bf679166
@ -81,6 +81,8 @@ class AgentConfig:
|
||||
messages = []
|
||||
|
||||
preamble_text, system_prompt = get_preamble_text(request.language, request.system_prompt)
|
||||
enable_thinking = request.enable_thinking and "```guideline" in request.system_prompt
|
||||
|
||||
config = cls(
|
||||
bot_id=request.bot_id,
|
||||
api_key=api_key,
|
||||
@ -92,7 +94,7 @@ class AgentConfig:
|
||||
robot_type=request.robot_type,
|
||||
user_identifier=request.user_identifier,
|
||||
session_id=request.session_id,
|
||||
enable_thinking=request.enable_thinking,
|
||||
enable_thinking=enable_thinking,
|
||||
project_dir=project_dir,
|
||||
stream=request.stream,
|
||||
tool_response=request.tool_response,
|
||||
@ -117,6 +119,8 @@ class AgentConfig:
|
||||
messages = []
|
||||
language = request.language or bot_config.get("language", "zh")
|
||||
preamble_text, system_prompt = get_preamble_text(language, bot_config.get("system_prompt"))
|
||||
enable_thinking = request.enable_thinking and "```guideline" in request.system_prompt
|
||||
|
||||
config = cls(
|
||||
bot_id=request.bot_id,
|
||||
api_key=bot_config.get("api_key"),
|
||||
@ -128,7 +132,7 @@ class AgentConfig:
|
||||
robot_type=bot_config.get("robot_type", "general_agent"),
|
||||
user_identifier=request.user_identifier,
|
||||
session_id=request.session_id,
|
||||
enable_thinking=request.enable_thinking,
|
||||
enable_thinking=enable_thinking,
|
||||
project_dir=project_dir,
|
||||
stream=request.stream,
|
||||
tool_response=request.tool_response,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user