Skip to main content

Declarative YAML-based compiler for data visualization dashboards. Write your dashboard once, compile to Streamlit, Plotly, Observable Plot, Apache Superset, Vega-Lite, or Grafana.

Project description

DashML

A declarative language for data visualization dashboards that compiles to multiple platforms.

Write your dashboard spec once in .dashml format, then compile it to Streamlit, Plotly, Observable Plot, Apache Superset, Vega-Lite, or Grafana.

Quick Start

# Generate a Streamlit app
python -m dashml_new.cli build dashboard.dashml --target streamlit --output app_dir
streamlit run app_dir/app.py

# Generate a standalone Plotly HTML dashboard
python -m dashml_new.cli build dashboard.dashml --target plotly --output dashboard.html

# Generate an Observable Plot HTML dashboard
python -m dashml_new.cli build dashboard.dashml --target observable --output dashboard.html

# Generate a Vega-Lite JSON specification
python -m dashml_new.cli build dashboard.dashml --target vegalite --output dashboard.json

# Generate a Grafana dashboard JSON
python -m dashml_new.cli build dashboard.dashml --target grafana --output dashboard.json

# Create a dashboard directly in Apache Superset
python -m dashml_new.cli build dashboard.dashml --target superset \
  --superset-user admin --superset-password admin

Database credentials

For SQL or BigQuery data sources, the generated artifact reads connection parameters from environment variables at runtime — never from baked-in literals. The generator emits .env.example, .gitignore, and SECRETS.md next to the generated app.py. Copy .env.example to .env, fill in the values, and run. The same artifact directory is safe to commit to a public repository.

python -m dashml_new.cli build dashboard.dashml --target plotly --output app_dir
cd app_dir
cp .env.example .env       # edit .env, set DASHML_DB_PASSWORD etc.
python app.py              # reads from env (or .env via python-dotenv)

See SECRETS.md in any generated SQL/BigQuery artifact for the full list of environment variables and recommended deployment patterns (Docker, Kubernetes, systemd, CI/CD, GCP Workload Identity).

Example

version: 0.1
title: "Sales Dashboard"
style: "styles/dracula.dmls"

data:
  type: csv
  path: "data/sales.csv"

charts:
  - id: "sales_by_country"
    type: "bar"
    title: "Sales by Country"
    x: "country"
    y: "sales"
    agg: "sum"
    sort: "y"
    sort_order: "desc"
    limit: 10

Documentation

  • User Guide - Full specification reference, chart types, CLI, themes
  • Architecture - System design, compiler pipeline, type system

Key Concepts

  • Compiler, not runtime - DashML generates standalone code; it never loads or touches your data
  • Credentials never baked - generated SQL/BigQuery artifacts read database credentials from environment variables at runtime; safe to version-control
  • 12 chart types - bar, line, scatter, pie, area, histogram, stacked_bar, grouped_bar, bubble, heatmap, box, geo
  • 3 data sources - CSV, SQL (PostgreSQL/MySQL/SQLite), Google BigQuery
  • 6 backends - Streamlit, Plotly, Observable Plot, Apache Superset, Vega-Lite, Grafana
  • 6 built-in themes - Dracula, Nord, Gruvbox, Monokai, One Dark, Solarized Light

Authors

  • Dawid Olejniczak
  • Szymon Nowaczyk

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dashml_lang-0.1.0.tar.gz (139.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dashml_lang-0.1.0-py3-none-any.whl (142.3 kB view details)

Uploaded Python 3

File details

Details for the file dashml_lang-0.1.0.tar.gz.

File metadata

  • Download URL: dashml_lang-0.1.0.tar.gz
  • Upload date:
  • Size: 139.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for dashml_lang-0.1.0.tar.gz
Algorithm Hash digest
SHA256 7e3c94d8ad7860143486a9fcbe75dd89b4c80fb78f55112007b422b6bf742be7
MD5 1b9964612b3bc4bac88580f48fb7dd40
BLAKE2b-256 5e27defdb5f8db6116698018c6fdc7f767225ce8391f3e3f0c253a94a2a26c64

See more details on using hashes here.

Provenance

The following attestation bundles were made for dashml_lang-0.1.0.tar.gz:

Publisher: release.yml on dashml-dev/dashml

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dashml_lang-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: dashml_lang-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 142.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for dashml_lang-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4687020394837d76c6b506a170f42f5a9e07b8fddd08a212d61d43fec40a15fc
MD5 a50d752bb17f67c28c51c70b463badc5
BLAKE2b-256 d2f2bbb00b288c1e039ab37c79927202b25f4d1516de8b7af8a591e7e93ae984

See more details on using hashes here.

Provenance

The following attestation bundles were made for dashml_lang-0.1.0-py3-none-any.whl:

Publisher: release.yml on dashml-dev/dashml

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page