Get all tools from all servers
(self)
| 1078 | return self.__initialized |
| 1079 | |
| 1080 | def get_tools(self) -> List[dict[str, dict[str, Any]]]: |
| 1081 | """Get all tools from all servers""" |
| 1082 | with self.__lock: |
| 1083 | tools = [] |
| 1084 | for server in self.servers: |
| 1085 | for tool in server.get_tools(): |
| 1086 | tool_copy = tool.copy() |
| 1087 | tool_copy["server"] = server.name |
| 1088 | tools.append({f"{server.name}.{tool['name']}": tool_copy}) |
| 1089 | return tools |
| 1090 | |
| 1091 | def get_tools_prompt(self, server_name: str = "") -> str: |
| 1092 | """Get a prompt for all tools""" |
no outgoing calls
no test coverage detected