High-availability satellite imagery retrieval across multiple STAC catalogs.
Project description
SuperSTAC
SuperSTAC is a Python library (with planned Rust backend) for high-availability satellite imagery retrieval.
Instead of relying on a single STAC endpoint (e.g., Sentinel from Element84), SuperSTAC can query multiple catalogs and automatically fall back to alternatives when a source is missing data or unavailable.
⚠️ Note: This is an early work-in-progress. The initial release is to start iterating in public. Expect breaking changes.
Features (planned)
- Query multiple STAC catalogs through a single unified API.
- Automatic fallback when a catalog has no data or is down.
- Configurable authentication for protected catalogs.
- Resolution & band matching across heterogeneous catalogs.
- CLI and Python API for flexible workflows.
- Optional LLM-assisted natural language queries.
- Rust backend (planned)
Installation
pip install superstac
Configuration
SuperSTAC loads its catalog configuration from a YAML file, typically referenced via the environment variable SUPERSTAC_CATALOG_CONFIG.
Example .superstac.yml:
catalogs:
Element84 Sentinel:
url: https://earth-search.aws.element84.com/v0
Planet:
url: https://api.planet.com/stac/v1
auth:
type: basic
username: youruser
password: yourpass
Microsoft PC:
url: https://planetarycomputer.microsoft.com/api/stac/v1
auth:
type: bearer
token: "YOUR_MICROSOFT_PC_TOKEN"
See superstac/.superstac.yml for an example config file.
Usage (very early draft)
from superstac import get_catalog_registry, federated_search_async
cr = get_catalog_registry()
cr.load_catalogs_from_config()
print("\nRunning asynchronous federated_search_async...")
start_async = time.perf_counter()
results_async = asyncio.run(
federated_search_async(
registry=cr,
collections=["sentinel-2-l2a"],
bbox=[6.0, 49.0, 7.0, 50.0],
datetime="2024-01-01/2024-01-31",
query={"eo:cloud_cover": {"lt": 20}},
sortby=[{"field": "properties.datetime", "direction": "desc"}],
)
)
end_async = time.perf_counter()
print(
f"Asynchronous search found {len(results_async)} items in {end_async - start_async:.2f} seconds."
)
for x in results_async:
print(x.self_href)
Also see main.py.
Development Status / Roadmap
Planned enhancements:
- Authentication configuration & documentation
- Retry logic
- Result modifiers
- Catalog refresh & health checks
- Latency tracking and fallback ranking
- Band matching across heterogeneous catalogs
- CLI tool
- Example notebooks (illegal mining detection, disaster response, LLM-assisted search)
License
MIT License. See LICENSE.
Feedback, issues, and contributions are welcome! This package is at a very early stage, so opening issues for missing features or edge cases will directly shape the roadmap.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file superstac-0.1.0a2.tar.gz.
File metadata
- Download URL: superstac-0.1.0a2.tar.gz
- Upload date:
- Size: 12.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fd73a8f1abbc708d2bb77b483e65582a656223834542f2c9e3e20ce241c2a07a
|
|
| MD5 |
dfb111bf83975972ef48ce53c5f1c86d
|
|
| BLAKE2b-256 |
62cc19871822d3cc795620458c85238a6f35da68b677e89a1ab2f0783c26920d
|
File details
Details for the file superstac-0.1.0a2-py3-none-any.whl.
File metadata
- Download URL: superstac-0.1.0a2-py3-none-any.whl
- Upload date:
- Size: 13.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e78fd18ca287212bdd0a357ee07562ab88c1648f665904eeb846daf8275b00d6
|
|
| MD5 |
cc18265deacc4c3940a94d813dad38e0
|
|
| BLAKE2b-256 |
9249d75db92e6bf50273800cf2ff5ac321dc8cf6ce2fc07c7983cc2e7a01a53d
|