Coral is a local-first SQL runtime that provides a unified interface for querying APIs, local files, and remote datasets docs/index.mdx10-12 It allows users and AI agents to execute complex SQL queries across diverse platforms—such as GitHub, Slack, and Datadog—without writing bespoke API integration code README.md10-13
By abstracting various backends into standard SQL tables, Coral enables cross-source reasoning (e.g., JOINing a GitHub pull request with a Linear issue) while keeping all data, credentials, and execution local to the user's machine README.md91-101
coral system schema CHANGELOG.md8-16The following diagram bridges the high-level system concepts to the specific Rust crates and communication protocols used in the codebase.
Component and Crate Relationship
Sources: Cargo.toml105-113 docs/project/security.mdx36-40 README.md56-80
Coral is organized as a Rust workspace with several specialized crates Cargo.toml1-3
| Crate | Role | Key Components |
|---|---|---|
coral-app | Management Plane | Orchestrates query execution, manages the SourceManager, handles CatalogDiscovery, and manages OAuth credential flows Cargo.toml108 CHANGELOG.md12-16 |
coral-engine | Data Plane | Compiles coral-spec manifests into DataFusion TableProvider implementations. Supports HTTP, JSONL, Parquet, and MCP tool-calling backends Cargo.toml111 docs/guides/write-a-custom-source.mdx96-97 |
coral-spec | Definition Layer | Pure data transformation crate that parses and validates the YAML DSL for SourceManifest Cargo.toml113 |
coral-api | Contract Layer | Contains the Protobuf definitions for QueryService, SourceService, and the new TraceService for query inspection Cargo.toml107 CHANGELOG.md15 |
coral-cli | User Interface | Handles command parsing (coral sql, coral source) and interactive credential collection, including OAuth flows Cargo.toml109 CHANGELOG.md17 |
coral-mcp | Agent Interface | Implements the Model Context Protocol via the rmcp SDK Cargo.toml112 Cargo.toml77 |
When a query is issued, coral-app loads the necessary source specifications, compiles them into a runtime, and streams Arrow results back to the caller.
Execution Trace Mapping
Sources: README.md56-80 Cargo.toml49 Cargo.toml57 Cargo.toml91 CHANGELOG.md20
Coral is distributed as a single binary docs/getting-started/installation.mdx6-7 Users typically start by discovering bundled sources and adding them via an interactive wizard.
coral onboard command provides an interactive guide for first-time setup README.md130-131coral source discover lists available integrations like GitHub, Slack, and Stripe README.md155-156coral source add --interactive <name> prompts for secrets and stores them locally in the platform's config directory README.md165-168 docs/project/security.mdx19-21For detailed setup instructions, see Getting Started.
Coral is licensed under Apache-2.0 Cargo.toml8 The project maintains a local-first security model where execution is read-only (disabling DDL/DML) and credentials never leave the user's machine docs/project/security.mdx6-44
For details on the roadmap, security disclosures, and how to contribute, see Project Roadmap, Security, and Contributing.
Sources: