GeoLibre Documentation

repository·main·Indexed 21 days ago

https://github.com/opengeos/geolibre

A free and open-source, lightweight, cloud-native GIS platform for visualizing, exploring, and analyzing geospatial data. GeoLibre version 2.4.0 runs across web browsers, desktop, mobile, and Jupyter notebooks. It includes an optional FastAPI backend (GeoLibre Server) for heavy geoprocessing, supporting Whitebox tools, DuckDB-based conversions, Apache Sedona spatial SQL, and AI segmentation via SAM 3.

Tokens
98.3K
Snippets
162
Records
491
Agent score
81%

What's inside GeoLibre

  1. Overview of GeoLibre AI proxy

    main

    The GeoLibre AI proxy is a Cloudflare Worker that provides an OpenAI-compatible /v1/chat/completions endpoint. It allows GeoLibre applications to use various AI providers (OpenAI, Anthropic, Google Gemini, and Workers AI) through Cloudflare AI Gateway's unified API without exposing sensitive provider API keys in the client application.

    Key features include:

    • Unified API: Supports multiple providers with a single request format.
    • Streaming: Supports streaming responses.
    • Security: Requires a server-side GeoLibre instance token to prevent unauthorized usage.
    • Governance: Enforces a model allowlist, request-size caps, output-token caps, and per-client rate limits.
  2. Overview of GeoLibre

    main

    GeoLibre is a free and open-source, lightweight, cloud-native GIS platform designed for visualizing, exploring, and analyzing geospatial data. It is built using a modern web stack including Tauri v2, React, TypeScript, MapLibre GL JS, DuckDB-WASM Spatial, and deck.gl.

    Key characteristics:

    • Cross-platform: Runs in web browsers, as a native desktop app (Windows, macOS, Linux), on mobile (Android), and inside Jupyter notebooks.
    • Privacy-focused: Designed to keep your data local and private.
    • Versatile: Supports Earth and planetary basemaps (Moon, Mars, etc.) with per-project ellipsoids for accurate measurements.
  3. Overview of GeoLibre capabilities

    main

    GeoLibre is a cloud-native, open-source GIS platform designed for visualizing, exploring, and analyzing geospatial data. It runs in web browsers, on desktops (via Tauri), on mobile, and inside Jupyter notebooks.

    Key capabilities include:

    • Map Workspace: MapLibre-based map with navigation, terrain, and field collection tools.
    • Data Management: Support for local and remote vector/raster data with attribute editing and styling.
    • Advanced Formats: Support for XYZ, WMS, WFS, STAC, GeoParquet, PMTiles, COG, 3D Tiles, and more.
    • Analysis: SQL Workspace (DuckDB Spatial, PGlite, Apache Sedona), Vector tools (via Turf.js or GeoPandas), and Raster tools (via rasterio).
    • AI & Automation: Natural-language AI Assistant for SQL and map control, and Whitebox geoprocessing via a Python sidecar.
    • Extensibility: Built-in plugin marketplace and Jupyter integration via the geolibre Python package.
  4. Navigate the GeoLibre interface

    main

    GeoLibre provides a unified workspace for both desktop and browser environments. The interface is organized into a top toolbar, three dockable side panels, a central map, and a status bar.

    Top Toolbar Menus

    • Project: Manage project lifecycle (Create, Open, Save, Share, Print).
    • Add Data: Import layers from files, web services, cloud formats, 3D data, and databases.
    • Processing: Access vector, raster, conversion, Whitebox, and SQL tools, as well as the AI Assistant.
    • Controls: Toggle map controls and component panels (e.g., Measure, Bookmark, Minimap).
    • Plugins: Manage built-in plugins and their on-map positioning.
    • Settings: Configure map preferences, layout, environment variables, and plugin management.
    • Help: Access the command palette, keyboard shortcuts, diagnostics, and updates.

    Dockable Panels

    • Layers panel (left): Manage the layer stack, visibility, opacity, and layer ordering.
    • Style panel (right): Control styling for selected layers (data-driven styling for vectors, image adjustments for rasters).
    • Attribute table (bottom): View attributes for selected vector or DuckDB layers. Can be expanded from the status bar.

    Map and Status Bar

    • The Map: The central workspace using MapLibre GL JS and deck.gl. Use right-click + drag to rotate and Ctrl/Cmd + drag to tilt.
    • Status Bar: Displays live cursor coordinates, zoom, bearing, and pitch. Includes a button to expand the Attribute Table and a Diagnostics button for runtime errors.
  5. Explore Cloud Catalogs and Federal Web Services

    main

    GeoLibre integrates with several hosted data sources through dedicated menus:

    Cloud Catalogs

    • Planetary Computer (Processing menu): Browse/load STAC data (Sentinel, Landsat, etc.) from Microsoft.
    • Earth Engine (Processing menu): Browse/load Google Earth Engine datasets (requires authentication).
    • Overture Maps (Plugins menu): Load themes like buildings, places, and transportation.
    • STAC (Add Data menu): Search any STAC catalog for raster items.

    Federal Web Services (Plugins menu → Web Services)

    • FEMA: National Flood Hazard Layer (NFHL).
    • NASA Earthdata: Satellite and Earth science imagery.
    • EPA EnviroAtlas: Environmental and ecosystem data.
    • USGS: The National Map topographic and geographic layers.
  6. Use Imagery, Time Series, and AI Plugins

    main

    Additional specialized tools are available in the Plugins menu:

    Imagery & Street Level

    • Historical Imagery: Browse historical Esri World Imagery snapshots.
    • Street View: View Google Street View and Mapillary imagery (requires credentials).

    Time Series & Comparison

    • Time Slider: Animate time series data (COG, XYZ/WMTS, WMS-Time, and time-filtered GeoJSON) via a docked timeline.
    • Layer Swipe: Compare two layers side-by-side using a swipe handle.

    AI Analysis

    • GeoAgent: AI-assisted geospatial analysis.
  7. Animate tiled data with the Time Slider

    main

    The GeoLibre Time Slider can be used to animate various tiled data formats.

    Supported Formats:

    • Vector tiles
    • PMTiles
    • MBTiles

    Key Features:

    • Automatic Timestamp Detection: The slider can detect the timestamp field from a live tile sample, removing the need for a local copy of the data to drive animation.
    • Temporal Adapters: The Time Slider can drive a layer's own internal time dimension via a generic temporal adapter. This allows data cubes (like Zarr stores) to join a shared timeline rather than requiring bespoke time controls. These bindings are saved within the project.
  8. Configure Chapter properties and animations

    main

    Each chapter defines a specific moment in your narrative. Key properties include:

    • Content: Title, Description (supports inline HTML), and an optional Image URL.
    • Panel alignment: Controls where the text panel appears: left, center, right, or full.
    • Map animation: Defines how the camera moves to the chapter: flyTo, easeTo, or jumpTo.
    • Hide panel: If enabled, the map transition occurs but the text panel is hidden (useful for visual-only beats).
    • Rotate camera: Slowly spins the view after the camera transition settles.

    Workflow Tips:

    • Use Set to current view to update a chapter's camera position after you have panned, zoomed, or tilted the map.
    • Use the map-pin button to quickly fly the map to a specific chapter while editing.
  9. Perform vector and raster processing

    main

    GeoLibre provides extensive processing capabilities through various menus:

    • Vector Tools: Includes buffer, centroids, dissolve, clip, spatial joins, and data quality tools (validity/topology checks). Runs via Turf.js in the browser, with optional engines like GeoPandas (via Pyodide or a sidecar).
    • Raster Tools: Includes hillshade, slope, reproject, zonal statistics, and raster calculator. Backed by a rasterio Python sidecar, with client-side fallbacks for core tools.
    • Spectral Indices: Toolbox for NDVI, GNDVI, NDWI, etc., using Sentinel-2, Landsat, or custom layouts.
    • Spatial Statistics: Includes Emerging Hot Spot Analysis (building space-time cubes) and a Processing batch runner for chaining tools into pipelines.
    • Conversion: Convert Vector to GeoParquet/FlatGeobuf/PMTiles and Raster to COG. Browser builds use DuckDB-WASM and geolibre-wasm, while desktop builds prefer the Python sidecar.
  10. Safety and privacy of the AI Assistant

    main

    The AI Assistant operates within the following safety and privacy constraints:

    • Data Flow & Undo/Redo: Actions like changing layers, styles, basemaps, or adding/removing elements go through the application's standard one-way data flow. This ensures they are reconciled consistently and can be reverted using undo/redo.
    • Auditability: Every generated SQL query and tool call is recorded in the transcript for review.
    • Read-only SQL: The run_sql tool is restricted to SELECT and WITH queries; it will reject any other command types.
    • Scoped Context: To protect privacy, only layer/table names, attribute field names, and the current view state are sent to the LLM. Your actual feature data is not sent to the model.
    • Data Transmission: When a prompt is sent, the prompt text and the scoped context are transmitted to your chosen LLM provider using your API key. Avoid using the assistant on sensitive data if you are concerned about sharing metadata with your LLM provider.

    !!! note "Code-execution caveat" When the assistant uses JavaScript or Python fallbacks to execute model-generated code, these changes bypass the application store and are not undoable. These code executions are visible in the transcript.

  11. Use CITATION.cff for automated citation management

    main

    The repository includes a CITATION.cff file. You can use this file to automatically generate citations using:

    • GitHub's "Cite this repository" button in the repository sidebar.
    • Reference managers like Zotero.
    • Tools like cffconvert.
  12. GeoLibre Project File Format (.geolibre.json)

    main

    GeoLibre projects are stored as .geolibre.json files. The schema defines how the map view, basemaps, layers, plugins, legends, story maps, and dashboard widgets are structured.

    Key top-level fields include:

    • version: Format version (e.g., 0.1.0).
    • mapView: Contains center, zoom, bearing, pitch, and optional bbox.
    • basemapStyleUrl: A MapLibre style JSON URL.
    • layers: An array of layer definitions.
    • styles: A map of layer IDs to LayerStyle objects.
    • plugins: Configuration for external plugins.
    • legend: Customizations for the Print Layout legend.
    • storymap: Configuration for scroll-driven narratives.
    • widgets: Array of Dashboard panel chart widgets.
    • dashboardColumns: Number of columns in the dashboard grid (1-6, default 2).