Get a tool by name. Retrieves the tool with the specified name from the registry. Args: name: The name of the tool to retrieve. Returns: The Tool instance if found, or None if no tool with that name exists. Example: >>>
(self, name: str)
| 66 | self._tools.pop(name, None) |
| 67 | |
| 68 | def get(self, name: str) -> Tool | None: |
| 69 | """ |
| 70 | Get a tool by name. |
| 71 | |
| 72 | Retrieves the tool with the specified name from the registry. |
| 73 | |
| 74 | Args: |
| 75 | name: The name of the tool to retrieve. |
| 76 | |
| 77 | Returns: |
| 78 | The Tool instance if found, or None if no tool with that name exists. |
| 79 | |
| 80 | Example: |
| 81 | >>> tool = registry.get("read_file") |
| 82 | >>> if tool: |
| 83 | ... print(f"Found tool: {tool.description}") |
| 84 | """ |
| 85 | return self._tools.get(name) |
| 86 | |
| 87 | def has(self, name: str) -> bool: |
| 88 | """ |
no outgoing calls