OpenAssistant Documentation
website·Indexed 30 days ago
https://openassistant-doc.vercel.appDeveloper documentation for OpenAssistant, featuring a React chat component (@openassistant/ui) and a suite of tool plugins including DuckDB, GeoDa, OpenStreetMap, Kepler.gl, and ECharts for data visualization and spatial analysis.
What's inside OpenAssistant
- OpenAssistant provides a suite of tools designed to extend AI assistant capabilities via function calling. These tools allow assistants to handle specialized operations such as custom business logic, data analysis, visualization generation, complex math, and integration with internal/external APIs. Available tool categories include Plot tools, Map tools, Data Analysis tools, DuckDB tools, and OSM tools.
Overview of OpenAssistant
OpenAssistant is an open-source platform designed to act as a bridge between Large Language Models (LLMs) and application functionality. Unlike general-purpose chatbots, it is engineered to execute complex tasks by leveraging application features and external AI plugins, serving as an AI co-pilot for specific app environments.Overview of OpenStreetMap tools for OpenAssistant
The OpenStreetMap tools for OpenAssistant provide a suite of capabilities to interact with OSM-related APIs for geographic data processing and analysis. Available tools include:
geocoding: Converts addresses to latitude/longitude via Nominatim.routing: Calculates routes between two points via Mapbox Directions API.isochrone: Generates polygons showing reachable areas within time/distance limits.roads: Fetches road networks based on boundary and road type via Overpass API.queryUSZipcodes: Queries US zipcodes within specific map bounds.getUsStateGeojson: Retrieves GeoJSON data for US states.getUsCountyGeojson: Retrieves GeoJSON data for US counties.getUsZipcodeGeojson: Retrieves GeoJSON data for US zipcodes.
Overview of OpenAssistant Map Tools
The OpenAssistant map tools provide three primary capabilities for creating and managing geospatial visualizations via AI function calling:
keplergl: Creates interactive maps with support for point, line, arc, and GeoJSON visualizations, including color styling and data classification.leaflet: Creates lightweight maps from GeoJSON data with customizable styling.downloadMapData: Downloads map data (GeoJSON or CSV) from URLs for use with other mapping tools.
Overview of OpenStreetMap tools for OpenAssistant
The OpenStreetMap tools for OpenAssistant provide a suite of geospatial capabilities to invoke OSM-related APIs. Available tools include:
geocoding: Converts addresses into geographic coordinates (latitude and longitude) via Nominatim.routing: Calculates routes between two points using Mapbox's Directions API.isochrone: Generates polygons showing reachable areas within a specific time or distance limit.roads: Fetches road networks based on boundary and road type using the OSM Overpass API.queryUSZipcodes: Queries US zipcodes within given map bounds.getUsStateGeojson: Retrieves GeoJSON data for one or more US states.getUsCountyGeojson: Retrieves GeoJSON data for one or more US counties.getUsZipcodeGeojson: Retrieves GeoJSON data for one or more US zipcodes.
Overview of OpenAssistant plot tools
OpenAssistant provides a suite of visualization tools that allow an AI assistant to create plots from datasets using Vega-Lite and Apache ECharts. Available tools include:
vegaLitePlot: General purpose Vega-Lite plots (bar, line, scatter, etc.).histogram: Histogram plots.scatterplot: Scatter plots.parallelCoordinates: Parallel coordinates plots.boxplot: Box plots.bubblechart: Bubble charts.- Interactive Plots: ECharts-based plots that can synchronize selections with other components like maps or tables.
Overview of GoogleAIAssistant
TheGoogleAIAssistantclass is a Google Gemini Assistant LLM implementation designed for client-side use. It extends theVercelAiClientclass, inheriting its core messaging and processing capabilities.Overview of OpenAssistant mapping tools
OpenAssistant provides a set of tools to enable LLMs to create interactive map visualizations. The available tools include:
keplergl: For high-performance interactive maps supporting points, lines, arcs, and GeoJSON with advanced styling and classification.leaflet: For lightweight maps based on GeoJSON data with customizable styling.downloadMapData: For fetching map data (GeoJSON or CSV) from URLs to be used by other mapping tools.
Overview of OpenAssistant data analysis tools
OpenAssistant provides a suite of specialized tool packages for AI applications to perform complex computations and visualizations that LLMs cannot natively handle. The available tool categories include:
- Plot Tools (
@openassistant/plots): Vega-Lite (all plot types) and eCharts (box plots, bubble charts, histograms, parallel coordinates, scatter plots with regression). - GeoTools (
@openassistant/osm): Geocoding (OSM API), Routing and Isochrones (Mapbox API), and U.S. geographic boundary retrieval. - Map Tools (
@openassistant/map): Interactive visualizations via Kepler.gl and web mapping via Leaflet. - SQL Tools (
@openassistant/duckdb): In-browser DuckDB SQL for local data querying and table operations (merge, filter, sort, group by, aggregate). - Data Analysis Tools (
@openassistant/geoda): Data classification, standardization, spatial operations (buffer, centroid, dissolve), spatial joins, spatial weights, global/local spatial analysis (Moran's I, Geary's C, LISA), and spatial regression (OLS, spatial lag, spatial error model).
- Plot Tools (
GridAdditionalData type definition
TheGridAdditionalDataobject is used within GeoDa spatial operations (defined inpackages/tools/geoda/src/spatial_ops/grid.ts). It contains metadata about a grid dataset, including optional dataset naming and geographic bounding box coordinates.type GridAdditionalData = { datasetName?: string; mapBounds?: { northwest: { latitude: number; longitude: number }; southeast: { latitude: number; longitude: number }; }; [outputDatasetName: string]: unknown; };Enable natural language data querying with the DuckDB plugin
The DuckDB plugin for OpenAssistant allows users to query datasets using natural language. The AI assistant translates plain English questions into SQL, executes them via DuckDB, and returns the results. To implement this, you must provide the assistant with a data context (schema) and a function definition that resolves dataset names to actual data values.Enable natural language data querying with the DuckDB plugin for OpenAssistant
The DuckDB plugin for OpenAssistant allows AI assistants to perform natural language queries against data sources. Users can ask questions in plain English (e.g., "Which city has the highest revenue?") and receive instant answers derived from the connected data.