Skip to main content

Marivo

Metric-centered analysis runtime for AI agents.

Marivo is a Python library — not a hosted service or a chat UI — that turns a data warehouse into something an AI agent can analyze reliably. It is not a text-to-SQL wrapper: Python declarations are the contract, ibis expressions are the execution language, and typed frames are the boundary between analysis steps.

  • Unified semantics — Datasources, entities, metrics, dimensions, and relationships are declared in Python and addressed by semantic ref (sales.revenue), not raw table or column names.
  • Metric-centered analysis — Sessions start from a trusted metric and chain typed intents (observe, compare, decompose, correlate, forecast), each returning a typed frame.
  • Trustworthy evidence — Every operator records findings, propositions, and assessments, so any conclusion can be traced back to its inputs.
  • Readiness gates — catalog.readiness() blocks incomplete semantic objects from analysis until authoring and access issues are resolved.

Requirements

Python 3.12 or newer.

Installation

pip install marivo

Install the backend extra that matches your datasource:

Backend Install command
DuckDB pip install "marivo[duckdb]"
MySQL pip install "marivo[mysql]"
Postgres pip install "marivo[postgres]"
ClickHouse pip install "marivo[clickhouse]"
Trino pip install "marivo[trino]"
All packaged backends pip install "marivo[all]"

Marivo is deployed by installing the library where the agent runs, checking in the models/ declarations, and providing datasource secrets through environment variables referenced by *_env fields. There is no separate server.

If setup fails, run the read-only doctor first:

marivo doctor
marivo doctor --semantic
marivo doctor --datasource warehouse --connect

The default doctor checks installation, project layout, datasource declarations, backend extras, secret references, and existing .marivo/ state without connecting to databases or writing secrets. Use --semantic for semantic load/readiness diagnostics and --connect only when you intentionally want a live datasource round-trip.

Quick Start

Scaffold a project with the CLI:

marivo --version
marivo init

marivo init creates the project skeleton (marivo.toml, models/, .marivo/) and installs the marivo-semantic and marivo-analysis skills into the shared .agents/skills directory plus Claude Code and Codex compatibility directories, so a coding agent can author the semantic layer with you.

Declare semantics under models/semantic/, then load and analyze:

import marivo.semantic as ms
import marivo.analysis as mv

catalog = ms.load()
report = catalog.readiness()
if report.status == "blocked":
    report.show()                       # resolve blockers before analysis

session = mv.session.get_or_create(name="revenue-check", question="Why did Q4 drop?")
revenue = session.catalog.get("metric.sales.revenue")
region = session.catalog.get("dimension.sales.orders.region")

current = session.observe(revenue, time_scope={"start": "2026-10-01", "end": "2027-01-01"}, grain="month", dimensions=[region])
baseline = session.observe(revenue, time_scope={"start": "2025-10-01", "end": "2026-01-01"}, grain="month", dimensions=[region])

delta = session.compare(current, baseline)
session.decompose(delta, axis=region).show()

In-project help is available at every surface: ms.help() and mv.help() list the surface; ms.help("metric") and mv.help("observe") drill into a symbol.

Documentation

Full guides live in the documentation site (built from site/):

  • Installation — install, marivo init, deploy.
  • Quick Start — author declarations, load a catalog, run a first analysis.
  • Concepts — semantic layer, analysis workflow, readiness, and evidence.

Maintained agent guidance lives in marivo/skills/marivo-semantic and marivo/skills/marivo-analysis.

Development

python3 -m venv .venv
.venv/bin/pip install -e ".[dev,duckdb,trino]"

Repository commands run through the local virtualenv via make:

make lint
make typecheck
make examples-check
make test
make check

Read agent-guide.md before contributing. See CONTRIBUTING.md for the full workflow.

Metadata

Release files for marivo 0.2.8

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for marivo 0.2.8
File Size Uploaded
marivo-0.2.8.tar.gz 827.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for marivo 0.2.8
File Interpreter ABI Platform
marivo-0.2.8-py3-none-any.whl Python 3 none any Details

Total release size: 1.4 MB

Release files / marivo-0.2.8.tar.gz

Download URL marivo-0.2.8.tar.gz
Size 827.8 kB
Tags Source
SHA-256 checksum
How to use checksums
4e5bf89d70ec19ea1db07b2ab5567679c3345ecc078c6633b5c963ed6aec526c
BLAKE2b-256 checksum
How to use checksums
8222b3c468c186010d9eca52d0ae1779a780e4851d7e35dc759862aff274a6d0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 8, 2026.

Transparency log

Release files / marivo-0.2.8-py3-none-any.whl

Download URL marivo-0.2.8-py3-none-any.whl
Size 570.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9e98b472422413086227dd8039bbde37868e37860ced38beba5008787c353b58
BLAKE2b-256 checksum
How to use checksums
5ce1c316e806518fa8c187a49f7aecce11d935cc78aa8bbfd38d286228862a96
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 8, 2026.

Transparency log

Release history Release notifications | RSS feed

0.5.8

2 release files

0.5.7

2 release files

0.5.6

2 release files

0.5.5

2 release files

0.5.4

2 release files

0.5.3

2 release files

0.5.2

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.16

2 release files

0.4.15

2 release files

0.4.14

2 release files

0.4.13

2 release files

0.4.12

2 release files

0.4.11

2 release files

0.4.10

2 release files

0.4.9

2 release files

0.4.8

2 release files

0.4.7

2 release files

0.4.6

2 release files

0.4.5

2 release files

0.4.4

2 release files

0.4.3

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

This release

0.2.8 This release

2 release files

0.2.7

2 release files

0.2.6

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page