Merge branch 'mem'
This commit is contained in:
@@ -87,7 +87,7 @@ def create_agent(**kwargs) -> Agent:
|
||||
model_from_config = (config or {}).get("model_select")
|
||||
model_from_kwargs = kwargs.pop("model", None)
|
||||
|
||||
model_name = model_from_kwargs or model_from_config or "gemini-2.5-flash"
|
||||
model_name = model_from_config or model_from_kwargs or "gemini-2.5-flash"
|
||||
model = OpenAIChatCompletionsModel(model_name, openai_client=client)
|
||||
|
||||
# Safety: ensure no stray 'model' remains in kwargs to avoid duplicate kwarg errors
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
Author: ai-business-hql qingli.hql@alibaba-inc.com
|
||||
Date: 2025-06-16 16:50:17
|
||||
LastEditors: ai-business-hql ai.bussiness.hql@gmail.com
|
||||
LastEditTime: 2025-11-25 15:37:50
|
||||
LastEditTime: 2025-12-24 19:03:58
|
||||
FilePath: /comfyui_copilot/backend/service/mcp-client.py
|
||||
Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
'''
|
||||
@@ -255,7 +255,7 @@ IF the user wants to:
|
||||
- Ask questions about the current workflow (e.g., "how does this work?", "explain the workflow").
|
||||
- Keywords: "analyze", "explain", "understand", "how it works", "workflow structure", "分析", "解释", "怎么工作的", "解读".
|
||||
|
||||
**ACTION:**
|
||||
**ACTION:
|
||||
- You MUST call `get_current_workflow` to retrieve the workflow details.
|
||||
- Then, based on the returned workflow data, provide a detailed analysis or explanation to the user.
|
||||
|
||||
@@ -307,11 +307,11 @@ You must adhere to the following constraints to complete the task:
|
||||
agent_input = messages
|
||||
log.info(f"-- Processing {len(messages)} messages")
|
||||
|
||||
# from agents import Agent, Runner, set_trace_processors, set_tracing_disabled, set_default_openai_api
|
||||
# from langsmith.wrappers import OpenAIAgentsTracingProcessor
|
||||
# set_tracing_disabled(False)
|
||||
# set_default_openai_api("chat_completions")
|
||||
# set_trace_processors([OpenAIAgentsTracingProcessor()])
|
||||
from agents import Agent, Runner, set_trace_processors, set_tracing_disabled, set_default_openai_api
|
||||
from langsmith.wrappers import OpenAIAgentsTracingProcessor
|
||||
set_tracing_disabled(False)
|
||||
set_default_openai_api("chat_completions")
|
||||
set_trace_processors([OpenAIAgentsTracingProcessor()])
|
||||
|
||||
result = Runner.run_streamed(
|
||||
agent,
|
||||
|
||||
Reference in New Issue
Block a user