tools functions

This commit is contained in:
Steve Androulakis
2025-01-01 15:30:39 -08:00
parent dbc9ea7688
commit 33af355363
3 changed files with 45 additions and 18 deletions

13
tools/__init__.py Normal file
View File

@@ -0,0 +1,13 @@
from .search_flights import search_flights
def get_handler(tool_name: str):
"""
Return a function reference for the given tool.
You can add more tools here, e.g. "BookHotel", etc.
"""
if tool_name == "SearchFlights":
return search_flights
# Or raise if not recognized
raise ValueError(f"No handler found for tool '{tool_name}'")