Data logic written once, run wherever the data lives.
Experimental. Every package is experimental and none is ready for production use. The six core packages are at version 0.1.0, nothing is published on PyPI yet, and APIs can change between versions.
mainis the release line; work happens ondevelop.
Data work rarely stays in one place. A model starts on a Parquet extract on a laptop, reads reference files from S3 or an SFTP drop, and runs in production against a database. Each place brings its own client library, credentials and API, and the same logic tends to get rewritten for each one.
Mountainash gives that work one shape. mountainash holds the logic as Polars-style plans and compiles them for the engine that holds the data: native Polars, the libraries Narwhals reaches, and SQL engines through Ibis. The other packages supply what those plans need around them: configuration, credentials, storage, file formats and database connections. Each package has one job and composes with the others through its public API.
Develop locally, run in production. Build a model on Polars against a local extract, then point the same function at the full table in a database. Promotion changes the input, and the logic you tested is the logic that runs. Connection details live in configuration, so moving between development, staging and production changes files, not code.
Many sources, one plan. A single plan can join a database table, a CSV read from local disk and plain Python data. mountainash moves each operand to where the work runs and reports every move. Behind it, mountainash-transport reaches local disk, S3-compatible stores, SFTP and HTTP(S) through one API, and mountainash-files reads the formats.
| Package | What it does | Docs |
|---|---|---|
| mountainash | Polars-style expressions and relations that compile to native Polars, to the libraries Narwhals reaches and to SQL engines through Ibis, with schemas, conformance, data contracts and validation on the same plans. | Book |
| mountainash-data | Database connections from configuration across 20 Ibis dialects, tables handed to mountainash, and portable writes back under transactions. | Book |
| mountainash-settings | Typed configuration on Pydantic v2: files, environment variables and secret stores merged in a predictable order, plus connection profiles that render driver arguments. | Book |
| mountainash-auth-client | Credential profiles rendered for HTTP, Boto or Paramiko clients, and OAuth2 and OAuth1 token lifecycles with an application-selected token store. | Book |
| mountainash-transport | One storage API for local disk, S3-compatible stores, SFTP and HTTP(S). The path picks the backend, with location policies, stream transforms and cross-store copy. | Book |
| mountainash-files | CSV, TSV, JSON and NDJSON, Parquet, Excel and XML through one API, on any store mountainash-transport reaches, returning Arrow tables or Python records. | Book |
Built on mountainash, and not yet part of the ecosystem docs.
| Package | What it does | Docs |
|---|---|---|
| mountainash-rules | Metadata-driven business rules. Rules are rows, not code: decision tables with multiple match strategies, ranked by specificity, evaluated in one vectorised pass, with per-rule explainability. | Book |
| mountainash-structuremap | Declarative, bidirectional mapping between hierarchical documents (XML, Pydantic and dataclass models) and typed relational tables. | Coming |
mountainash
(expressions and plans)
/ \
mountainash-data mountainash-files
(databases) (formats)
| |
| mountainash-transport
| (storage)
\ /
mountainash-auth-client
(credentials)
|
mountainash-settings
(configuration)
Each package depends only on the packages beneath it, so you can adopt mountainash-settings alone or add layers as a project needs them. Architecture describes the layers in detail.
| If you are a… | Start with | Then add |
|---|---|---|
| Data analyst | mountainash, mountainash-data | |
| Data engineer | mountainash, mountainash-data, mountainash-settings | mountainash-transport and mountainash-files when inputs are files on local disk, S3, SFTP or HTTP |
| Platform or infrastructure team | mountainash-settings, mountainash-auth-client | mountainash-data, mountainash-transport |
| File ingestion developer | mountainash-transport, mountainash-files | mountainash-auth-client for credentials |
New to the project? Read the mountainash book first: it introduces the expression and relation abstractions everything else uses. Use cases shows the packages working together.
- Write the logic once and compile it per backend. One plan runs on Polars during development and in the database in production.
- Check what a target supports before running. A plan that a backend cannot run fails before it starts.
- Keep configuration and credentials out of code. Typed settings,
secret:references that are safe to commit, and credential profiles rendered for each client. - Each package owns one concern and composes with the others through public APIs.
- Three-valued logic for real-world data. Conditions evaluate to TRUE, FALSE or UNKNOWN, not only true or false.
More in Design philosophy.
Polars · Narwhals · Ibis · Apache Arrow · Frictionless Data · Pydantic
Every package is open source under the Apache License 2.0. The six core packages are at version 0.1.0 and require Python 3.12 or later. None is published on PyPI yet; each book's installation chapter shows how to install from a source checkout.
Maintained by Nathaniel Ramm in Melbourne. Bug reports, feature requests and contributions are welcome as issues on the relevant repository, or get in touch by email or on LinkedIn.