Skip to content

Latest commit

 

History

119 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tests Coverage

Documentation

Example Project

Dictum is a Business Intelligence framework written in Python. It includes a general-purpose metrics engine and allows your organization to have a shared, version-controlled and well-documented understanding of what the important metrics are and how they are computed from the source data.

The main features are:

  • 🧑‍🔧 A structured way to describe your metrics. Metrics are defined in simple, readable YAML files. 👉 Learn how to get started with your own project
  • 🪄 Interactive analytics in Jupyter. Slice and dice your metrics quickly and easily. Get the data as a Pandas DataFrame. 👉 Learn how to query Dictum
  • 🤩 Dataviz powered by Altair. Quickly build visualizations based on your metric data. 👉 Demo Jupyter notebook
  • 😎 SQL-like expression language. Write metric expressions in the familiar SQL syntax.
  • 🦥 Reusable expressions. Define metrics using other previously-defined metrics.
  • 🐇 Automatic multi-hop joins. You define foreign keys for tables, Dictum writes boring boilerplate SQL for you.
  • 🤖 Python API. Build data applications powered by your Dictum project.

🚂 Supported backends:

Example Metric definition:

# metrics/revenue.yml
name: Revenue
description: |
  Sum of all order amounts excluding
  bonus currency spending.
table: orders
expr: sum(amount - coalesce(bonus_spent, 0))
format:
  kind: currency
  currency: USD

Example Table Definition:

# tables/orders.yml
source:
  schema: marts
  table: orders

related:
  user: user_id -> users.id
  product: project_id -> products.id

Installation

Install from PyPi:

pip install dictum

Basic usage

Learn how to query the example project

About

Describe business metrics with YAML, query and visualize in Jupyter with zero SQL

Topics

Resources

Stars

21 stars

Watchers

2 watching

Forks

Releases

Used by

Contributors

Languages