mirror of https://github.com/aliasrobotics/cai.git
Merge branch 'docs_new' of https://gitlab.com/aliasrobotics/alias_research/cai into docs_new
This commit is contained in:
commit
904ea8171d
|
|
@ -51,7 +51,7 @@ nav:
|
|||
# - voice/tracing.md
|
||||
- API Reference:
|
||||
- Agents:
|
||||
- ref/index.md
|
||||
#- ref/index.md
|
||||
- ref/agent.md
|
||||
- ref/run.md
|
||||
- ref/tool.md
|
||||
|
|
@ -70,8 +70,8 @@ nav:
|
|||
- ref/models/interface.md
|
||||
- ref/models/openai_chatcompletions.md
|
||||
- ref/models/openai_responses.md
|
||||
- ref/mcp/server.md
|
||||
- ref/mcp/util.md
|
||||
# - ref/mcp/server.md
|
||||
# - ref/mcp/util.md
|
||||
# - Tracing:
|
||||
# - ref/tracing/index.md
|
||||
# - ref/tracing/create.md
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ if TYPE_CHECKING:
|
|||
|
||||
|
||||
class AgentsException(Exception):
|
||||
"""Base class for all exceptions in the Agents SDK."""
|
||||
"""Base class for all exceptions in the CAI Agents."""
|
||||
|
||||
|
||||
class MaxTurnsExceeded(AgentsException):
|
||||
|
|
@ -29,7 +29,7 @@ class ModelBehaviorError(AgentsException):
|
|||
|
||||
|
||||
class UserError(AgentsException):
|
||||
"""Exception raised when the user makes an error using the SDK."""
|
||||
"""Exception raised when the user makes an error using CAI."""
|
||||
|
||||
message: str
|
||||
|
||||
|
|
|
|||
|
|
@ -30,16 +30,16 @@ if TYPE_CHECKING:
|
|||
from .agent import Agent
|
||||
|
||||
TResponse = Response
|
||||
"""A type alias for the Response type from the OpenAI SDK."""
|
||||
"""A type alias for the Response type."""
|
||||
|
||||
TResponseInputItem = ResponseInputItemParam
|
||||
"""A type alias for the ResponseInputItemParam type from the OpenAI SDK."""
|
||||
"""A type alias for the ResponseInputItemParam type."""
|
||||
|
||||
TResponseOutputItem = ResponseOutputItem
|
||||
"""A type alias for the ResponseOutputItem type from the OpenAI SDK."""
|
||||
"""A type alias for the ResponseOutputItem type."""
|
||||
|
||||
TResponseStreamEvent = ResponseStreamEvent
|
||||
"""A type alias for the ResponseStreamEvent type from the OpenAI SDK."""
|
||||
"""A type alias for the ResponseStreamEvent type."""
|
||||
|
||||
T = TypeVar("T", bound=Union[TResponseOutputItem, TResponseInputItem])
|
||||
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ if TYPE_CHECKING:
|
|||
|
||||
|
||||
class MCPUtil:
|
||||
"""Set of utilities for interop between MCP and Agents SDK tools."""
|
||||
"""Set of utilities for interop between MCP and CAI tools."""
|
||||
|
||||
@classmethod
|
||||
async def get_all_function_tools(cls, servers: list["MCPServer"]) -> list[Tool]:
|
||||
|
|
@ -48,7 +48,7 @@ class MCPUtil:
|
|||
|
||||
@classmethod
|
||||
def to_function_tool(cls, tool: "MCPTool", server: "MCPServer") -> FunctionTool:
|
||||
"""Convert an MCP tool to an Agents SDK function tool."""
|
||||
"""Convert an MCP tool to an CAI function tool."""
|
||||
invoke_func = functools.partial(cls.invoke_mcp_tool, server, tool)
|
||||
return FunctionTool(
|
||||
name=tool.name,
|
||||
|
|
|
|||
Loading…
Reference in New Issue