data_juicer_agents.adapters.agentscope.tools module#

AgentScope bindings for tool specifications.

data_juicer_agents.adapters.agentscope.tools.build_agentscope_json_schema(spec: ToolSpec) Dict[str, Any][source]#
data_juicer_agents.adapters.agentscope.tools.build_agentscope_tool_function(spec: ToolSpec, *, ctx_factory: Callable[[], ToolContext], runtime_invoke: Callable[[str, Dict[str, Any], Callable[[], Dict[str, Any]]], Dict[str, Any]], arg_preview: Callable[[ToolSpec, Dict[str, Any]], Dict[str, Any]] | None = None)[source]#
data_juicer_agents.adapters.agentscope.tools.compact_payload_for_model(tool_name: str, payload: Dict[str, Any]) Dict[str, Any][source]#

Return a semantically faithful, smaller payload for ReAct memory.

The full payload is still passed through runtime events; this function only controls what is written into AgentScope tool_result memory.

data_juicer_agents.adapters.agentscope.tools.default_arg_preview(_spec: ToolSpec, raw_kwargs: Dict[str, Any]) Dict[str, Any][source]#
data_juicer_agents.adapters.agentscope.tools.invoke_tool_spec(spec: ToolSpec, *, ctx: ToolContext, raw_kwargs: Dict[str, Any]) Dict[str, Any][source]#
data_juicer_agents.adapters.agentscope.tools.tool_result_compaction_enabled() bool[source]#