tools.tools.toolkits.citydsk_toolkit¶
CitySDK Toolkit for accessing city-related data from various sources.
This toolkit provides tools for interacting with the CitySDK APIs, including the Linked Data API for SPARQL queries and the Tourism API for points of interest information. These tools help agents find and process structured city information.
Examples
toolkit = CitySDKToolkit() tools = toolkit.get_tools()
- tools.tools.toolkits.citydsk_toolkit.None¶
Attributes¶
Classes¶
Input schema for the CitySDK Linked Data SPARQL query tool. |
|
Toolkit for accessing CitySDK APIs for city-related data. |
|
Input schema for querying Points of Interest from the CitySDK Tourism API. |
Functions¶
|
Fetches Points of Interest data from the CitySDK Tourism API. |
|
Executes a SPARQL query against the CitySDK Linked Data endpoint. |
Module Contents¶
- class tools.tools.toolkits.citydsk_toolkit.CitySDKLinkedDataQueryInput(/, **data: Any)¶
Bases:
pydantic.BaseModel
Input schema for the CitySDK Linked Data SPARQL query tool.
- Parameters:
query – SPARQL query to execute against the CitySDK Linked Data endpoint
- class tools.tools.toolkits.citydsk_toolkit.CitySDKToolkit(/, **data: Any)¶
Bases:
langchain_core.tools.base.BaseToolkit
Toolkit for accessing CitySDK APIs for city-related data.
This toolkit provides tools for working with different CitySDK APIs, including SPARQL queries for linked data and tourism POI information.
- class tools.tools.toolkits.citydsk_toolkit.CitySDKTourismPOIInput(/, **data: Any)¶
Bases:
pydantic.BaseModel
Input schema for querying Points of Interest from the CitySDK Tourism API.
- Parameters:
bbox – Bounding box coordinates to filter POIs geographically
city – City name to filter POIs by location
- tools.tools.toolkits.citydsk_toolkit.get_tourism_pois(bbox: str | None = None, city: str | None = None) dict ¶
Fetches Points of Interest data from the CitySDK Tourism API.
- Parameters:
bbox – Optional bounding box to filter POIs geographically
city – Optional city name to filter POIs
- Returns:
JSON response containing the POI data
- Return type:
- Raises:
HTTPError – If the request fails or returns an error status code
- tools.tools.toolkits.citydsk_toolkit.run_citysdk_linkeddata_query(query: str) dict ¶
Executes a SPARQL query against the CitySDK Linked Data endpoint.
- Parameters:
query – A valid SPARQL query string
- Returns:
JSON response containing the query results
- Return type:
- Raises:
HTTPError – If the request fails or returns an error status code
- tools.tools.toolkits.citydsk_toolkit.citysdk_linked_data_tool¶
- tools.tools.toolkits.citydsk_toolkit.citysdk_tourism_poi_tool¶