AI-powered conversational tooling for exploring Argo oceanographic data. This project combines MCP (Model Context Protocol) tools for querying the Argovis API with a lightweight RAG stack over local documentation to help users ask natural-language questions.
- MCP Server: FastMCP server with tools for nearest_floats, time_series, profile_summary, salinity_equator, etc.
- RAG Pipeline: Chroma vector store with Google Gemini embeddings for documentation
- Streamlit Dashboard: Multi-page web interface
- 📥 Ingest: Index docs and ingest NetCDF files to Parquet/DuckDB/Chroma
- 🧭 Explore: Find floats, equatorial salinity, time series
- 📊 Visualize: Depth-time plots, profile comparisons
- 💬 Chat: Agent with MCP tools for comprehensive answers
- Data Pipeline: NetCDF → Parquet → DuckDB → Chroma indexing
- Interactive Visualizations: Plotly-based depth-time plots and profile comparisons
- Sample data ingestion and testing
- Performance optimizations
- Python 3.13+
- uv package manager
- Google AI API key
- Clone and install dependencies:
git clone <repository>
cd argofloat
uv sync- Configure environment:
cp .env.example .env
# Edit .env with your GOOGLE_API_KEY- Run system test:
uv run python test_system.py- Start the dashboard:
uv run streamlit run streamlit_app.pyNetCDF Files → xarray → DataFrame → Parquet (partitioned) → DuckDB Views → Chroma (profiles)
- argo_ingest.py: NetCDF parsing, Parquet storage, DuckDB views, Chroma indexing
- argo_data_query.py: Query interface with caching
- argo_mcp/server.py: MCP tools for Argovis API
- argo_rag/: Documentation RAG pipeline
- pages/: Streamlit dashboard pages
1_📥_Ingest.py: Data ingestion interface2_🧭_Explore.py: Data exploration tools3_📊_Visualize.py: Data visualization4_💬_Chat.py: AI chat interface with RAG + MCP tools5_📚_Chroma_DB.py: Chroma DB visualizer for vector database exploration
search_docs: Semantic search over ARGO documentationnearest_floats: Find ARGO floats near a locationtime_series: Get time series data for variablesprofile_summary: Statistics for specific profilessalinity_equator: Salinity profiles near equator
- Place NetCDF files in
./data/netcdf/ - Go to Ingest page → Enter directory path → Click "Ingest NetCDF"
- "Find ARGO floats near 0°N, 0°E"
- "Show salinity time series for platform 5905107"
- "Compare temperature profiles between these two floats"
- "What are BGC parameters in the Arabian Sea?"
Go to the Chroma DB Visualizer page to:
-
Explore your vectorized ARGO documentation
-
View document statistics and distributions
-
Search through indexed content
-
Analyze metadata patterns
-
Monitor collection health
-
Depth-time plots (Hovmöller diagrams)
-
Profile comparisons with QC masking
-
Interactive time series
GOOGLE_API_KEY: Required for Gemini embeddings and chatARGOVIS_API_KEY: Optional (defaults to "guest")ARGOVIS_API_ROOT: Optional (defaults to Argovis API URL)
uv run python test_system.pyuv add package_name# Index docs to Chroma
uv run python -c "from argo_rag.indexer import create_vectorstore; create_vectorstore('./docs')"Datasets:
- Argo Global Data Repository (FTP): ftp.ifremer.fr/ifremer/argo
- Indian Argo Project: https://incois.gov.in/OON/index.jsp
Organization: Ministry of Earth Sciences (MoES), INCOIS
- MCP server for Argo tooling (Argovis-backed)
- File: argo_mcp/server.py
- Tools (selection):
- salinity_equator: salinity profiles near equator for a given month/year
- compare_bgc: recent BGC variable statistics over a named region
- nearest_floats: nearest float platforms to a lat/lon
- search_docs: semantic search over local RAG index (Argovis docs)
- time_series: aggregated variable per profile over time
- section_extraction: along-track transects with depth interpolation
- climatology_lookup: RG09 monthly climatology comparison
- profile_summary: stats for variables in a single profile
- Lightweight RAG over local docs
- Index builder: indexer.py
- Retriever: retriever.py and
ArgoRetriever - Seed docs: docs/ (for example, docs/argovis.md, docs/mcp.md)
- Entry point script
- main.py (simple starter)
- Streamlit dashboard
- streamlit_app.py (interactive web interface)
- Project config and lockfiles
- pyproject.toml (do not edit)
- uv.lock
- Python: 3.13 (see .python-version)
- Package manager: uv
Commands:
- Install deps:
uv sync - Run a script:
uv run python <script.py> - Add a dependency:
uv add <package> - Run this project:
uv run python main.py
Important: DO NOT EDIT pyproject.toml. Use uv for all dependency operations.
- ARGOVIS_API_KEY (optional; defaults to “guest”)
- ARGOVIS_API_ROOT (optional; defaults to https://argovis-api.colorado.edu)
- GOOGLE_API_KEY (required for Google Generative AI embeddings in RAG)
Export on Linux/macOS:
export ARGOVIS_API_KEY="your_key"
export GOOGLE_API_KEY="your_google_api_key"- Install
uv sync- Build a local vector store from docs (Chroma persisted to ./chroma_db)
uv run python indexer.py- This loads docs/, splits text, embeds with Gemini (
langchain-google-genai), and persists into Chroma.
- Run the MCP server (inspector/dev)
uv run mcp dev argo_mcp/server.py- Use the MCP Inspector to invoke tools like
salinity_equator,nearest_floats, orsearch_docs. - The server will use
ArgoRetrieverwhen available to servesearch_docs.
- Minimal run
uv run python main.py- Launch the Streamlit dashboard
uv run streamlit run streamlit_app.py- This starts the interactive web dashboard for data visualization and exploration.
- MCP server: argo_mcp/server.py
- Uses
mcp.server.fastmcp.FastMCPand exposes tools/resources for Argovis and local RAG. - Respects
ARGOVIS_API_KEYandARGOVIS_API_ROOT. - Performs safe HTTP requests via
httpxwith structured error handling. - Example routes used:
/argo,/argo/meta,/argo/vocabulary.
- Uses
- RAG
- Indexer: indexer.py creates Chroma embeddings with
GoogleGenerativeAIEmbeddings. - Retriever:
ArgoRetrieverprovidessimilarity_searchandsimilarity_search_with_score.
- Indexer: indexer.py creates Chroma embeddings with
Docs you can query:
- Argovis API intro: docs/argovis.md
- MCP SDK notes: docs/mcp.md
- Interactive web interface: streamlit_app.py
- Built with Streamlit for user-friendly data exploration
- Chat Assistant: AI-powered chatbot using LangChain and Gemini for natural language queries
- Planned features: maps, charts, profile comparisons, and data export
- Run with:
uv run streamlit run streamlit_app.py
- List available vocabulary categories:
- Resource:
resource://argovis/vocabulary
- Resource:
- Fetch a specific vocabulary category:
- Resource:
resource://argovis/vocabulary/{category}
- Resource:
- Find salinity near the equator for a month:
- Tool:
salinity_equator(year, month, lat_band=5.0, limit=50)
- Tool:
- Search local docs:
- Tool:
search_docs(query="...")(requires the Chroma index)
- Tool:
See the tool definitions in argo_mcp/server.py.
- Ingestion/ETL
- Parse Argo NetCDF → Parquet/SQL schemas (PostgreSQL), with metadata summaries for RAG.
- Vector DB
- Enrich vector index with platform/profile summaries; support FAISS/Chroma backends.
- LLM + RAG + MCP
- Natural-language → SQL mapping for structured queries.
- Grounded answers with citations and profile links.
- Frontend
- Streamlit/Dash dashboards: maps (Leaflet/Plotly), depth–time sections, profile comparisons.
- Export views and subsets to ASCII/NetCDF.
- Chat experience
- Intent classification, guided refinement (already used in tools via elicitation), and multi-turn drilling.
- PoC focus
- Indian Ocean subset first; extend to BGC/gliders/buoys/satellite products.
- Use
uv add <package>to add dependencies. - Prefer small, focused PRs.
- Keep simple script logic in main.py; grow modules under
argo_*packages.
- No doc search results:
- Ensure you ran
uv run python indexer.pyand setGOOGLE_API_KEY.
- Ensure you ran
- Argovis requests failing:
- Set a valid
ARGOVIS_API_KEYand check network access.
- Set a valid
- ChromaDB connection issues:
- The visualizer tries multiple connection methods automatically
- If "already exists with different settings" error occurs, use "Force reset database"
- Check directory permissions:
ls -la chroma_db/ - Kill conflicting processes:
pkill -f chromadb
- MCP inspector cannot find tools:
- Verify
uv run mcp dev argo_mcp/server.pyand check console logs.
- Verify