Build a dashboard to visualize data
In this final step, we will visualize some of the data we have been modeling in a dashboard using Evidence connected to our model assets.
1. Add the Evidence project
First, we will clone an Evidence project that is already configured to work with the data we have modeled with dbt:
git clone --depth=1 https://github.com/dagster-io/jaffle-dashboard.git dashboard && rm -rf dashboard/.git
There will now be a directory dashboard
within the root of the project.
.
├── pyproject.toml
├── dashboard # Evidence project
├── src
├── tests
├── transform
└── uv.lock
Change into that directory and install the necessary packages with npm
:
cd dashboard && npm install
2. Define the Evidence Component
Next, we will need to install Dagster's Evidence integration:
uv pip install dagster-evidence
Now we can scaffold Evidence with dg
:
dg scaffold defs dagster_evidence.EvidenceProject dashboard
Creating a component at <YOUR PATH>/etl-tutorial/src/etl_tutorial/defs/dashboard.
This will add the directory dashboard
to the etl_tutorial
module:
src
└── etl_tutorial
└── defs
└── dashboard
└── defs.yaml
3. Configure the Evidence defs.yaml
Unlike the other components we used, which generated individual assets for each model in our project, the Evidence component will register a single asset for the entire Evidence deployment. This asset will build all the sources and dashboards within our Evidence project.
However, we can still configure our Evidence component to be dependent on multiple upstream assets by setting the deps
value within the attributes
key of the Evidence component defs.yaml
file:
type: dagster_evidence.EvidenceProject
attributes:
project_path: ../../../../dashboard
asset:
key: dashboard
deps:
- target/main/orders
- target/main/customers
deploy_command: 'echo "Dashboard built at $EVIDENCE_BUILD_PATH"'
4. Execute the Evidence asset
With the Evidence component configured, our assets graph should look like this:
You can now execute the Evidence asset and view the output:
-
Reload your Definitions.
-
Execute the
dashboard
asset (assuming the upstream assets have been materialized). -
After the
dashboard
asset has successfully materialized, on the command line, execute the following to run the Evidence server:cd dashboard/build && python -m http.server
-
Navigate to the dashboard at http://localhost:8000/:
Summary
Here is the final structure of our etl_tutorial
project:
src
└── etl_tutorial
├── __init__.py
├── definitions.py
└── defs
├── __init__.py
├── assets.py
├── dashboard
│ └── defs.yaml
├── resources.py
└── transform
└── defs.yaml
Congratulations! You've just built a fully functional, end-to-end data platform—one that seamlessly handles everything from raw data ingestion to transformation, modeling, and even downstream visualization. This is no small feat! You've laid the foundation for a scalable, maintainable, and observable data ecosystem using modern tools and best practices.
Recommended next steps
- Join our Slack community.
- Continue learning with Dagster University courses.
- Start a free trial of Dagster+ for your own project.