← Về thư mục
- register_tool · function · L208-L263 — def register_tool(tool: Tool) -> Tool
- _unregister_tool · function · L266-L272 — def _unregister_tool(name: str) -> None
- get_tool · function · L281-L283 — def get_tool(name: str) -> Tool | None
- get_tool_by_host_method · function · L286-L291 — def get_tool_by_host_method(host_method: str) -> Tool | None
- all_tools · function · L294-L296 — def all_tools() -> list[Tool]
- _catalog_tool · function · L299-L306 — def _catalog_tool(name: str, catalog: Any = None) -> Tool | None
- FencedBlock · class · L319-L333 — class FencedBlock
- parse_fence_delimiter · function · L336-L342 — def parse_fence_delimiter(line: str) -> tuple[str, int, str] | None
- scan_fenced_blocks · function · L345-L412 — def scan_fenced_blocks(text: str) -> list[FencedBlock]
- strip_fenced_blocks · function · L415-L425 — def strip_fenced_blocks(text: str) -> str
- _coerce_call · function · L428-L447 — def _coerce_call(obj: Any) -> tuple[dict | None, str | None]
- _parse_tool_body · function · L450-L475 — def _parse_tool_body( body: str, calls: list[dict], errors: list[str], catalog: Any = None, ) -> None
- parse_tool_calls · function · L478-L508 — def parse_tool_calls( reply: str, catalog: Any = None, ) -> tuple[list[dict], list[str]]
- render_tools_prompt · function · L514-L547 — def render_tools_prompt(catalog: Any = None) -> str
- _safe_json · function · L553-L557 — def _safe_json(value: Any) -> str
- _render_list · function · L560-L568 — def _render_list(key: str, value: Any) -> str
- _render_result_body · function · L571-L609 — def _render_result_body(result: Any) -> str
- _truncate_with_marker · function · L612-L620 — def _truncate_with_marker(text: str, limit: int, marker: str) -> str
- format_tool_result · function · L623-L627 — def format_tool_result(tool: Tool, result: Any) -> str
- tool_validation_error · function · L630-L643 — def tool_validation_error( name: str, arguments: Any, catalog: Any = None, ) -> str | None
- execute_tool_call · function · L646-L701 — def execute_tool_call( dispatcher: Any, call: Any, catalog: Any = None, ) -> tuple[str, bool]
- finalize_tool_batch · function · L714-L734 — def finalize_tool_batch(parts: list[str], n_total: int, errors: list[str]) -> str
- run_tool_calls · function · L737-L762 — def run_tool_calls( dispatcher: Any, calls: list[dict], errors: list[str], catalog: Any = None, *, on_result: Callable[[Any, bool], None] | None = None, ) -> str