Spaces:
Running on Zero
Download docs/integrations/DATA_PROVIDER_INTEGRATION_GUIDE.md from deveshc23/drift-quant: direct link, hf CLI and curl.
- Browser
- Download file 1.8 kB
-
https://huggingface.co/spaces/deveshc23/drift-quant/resolve/main/docs/integrations/DATA_PROVIDER_INTEGRATION_GUIDE.md
- Command line
-
hf download hf://spaces/deveshc23/drift-quant/docs/integrations/DATA_PROVIDER_INTEGRATION_GUIDE.md
-
curl -L -o DATA_PROVIDER_INTEGRATION_GUIDE.md https://huggingface.co/spaces/deveshc23/drift-quant/resolve/main/docs/integrations/DATA_PROVIDER_INTEGRATION_GUIDE.md
A newer version of the Gradio SDK is available: 6.31.0
Data Provider Integration Guide
Current status
No external data adapter is implemented or tested. Milestone 2 will first add a deterministic local fixture provider.
Provider contract
Each adapter returns canonical instruments and timestamped observations with:
- source/provider identity and source symbol;
- UTC event time and data-availability time;
- asset class, venue, currency, and adjustment/corporate-action metadata;
- request parameters, retrieval time, content/data-set digest, and quality outcome;
- explicit handling of pagination, throttling, retryability, and provider errors.
The adapter may not expose vendor SDK objects beyond its own module. Consumer packages receive normalized domain records.
Candidate data sources
Alpaca’s market-data documentation describes authenticated HTTP and WebSocket access, US stocks/ETFs, plan-dependent real-time coverage and history availability. Polygon’s stocks overview documents US stock REST, WebSocket, and flat-file access and says timestamps are UTC Unix timestamps.
Before implementation, confirm exact current plan, exchange entitlement, historical depth, corporate-action/reference coverage, cache/retention rights, redistribution restrictions, SDK support, and rate limits from current official terms.
Test strategy
Use recorded, license-permitted fixtures for unit tests; do not place vendor data in the repository without a rights review. Test normalization, invalid/missing/duplicate data, timezone conversion, pagination, retries, 429 responses, timeouts, and data lineage. Credential-gated connectivity tests are opt-in and must never print response headers containing secrets.