A single-file HTML dashboard that queries Canner/WrenAI GitHub activity
through @wrenai/wren-core-wasm
— DataFusion-in-WASM running directly in the browser over Parquet files.
No backend, no server-side database.
dashboard/ Single-page demo
index.html The dashboard itself (Chart.js + wren-core-wasm)
mdl.json Pre-compiled MDL (semantic layer)
data/*.parquet GitHub events / issues / PRs / stargazers
test_*.mjs Node smoke tests for the same queries
wren_project/ Source MDL (models, relationships). Compiles to mdl.json.
github/ dlt verified-source code (do not edit by hand).
github_pipeline.py dlt pipeline that rebuilds wrenai_github.duckdb from
the GitHub API.
wrenai_github.duckdb DuckDB file produced by github_pipeline.py.
The dashboard fetches mdl.json and data/*.parquet over HTTP, so opening
index.html directly with file:// will not work. Serve it with any static
HTTP server from the dashboard/ directory:
cd dashboard
python3 -m http.server 8000Then open http://localhost:8000/index.html.
The first load fetches wren-core-wasm (~14 MB gzipped) from unpkg and may
take 10–30 s. Subsequent loads are cached by the browser.
Any static server works — these are all fine alternatives:
npx serve -l 8000 . # Node
ruby -run -e httpd . -p 8000 # Ruby
caddy file-server --listen :8000The test_*.mjs files re-run the dashboard's queries from Node to catch
regressions before opening the browser:
cd dashboard
npm init -y >/dev/null && npm install @wrenai/wren-core-wasm@0.4.0
node test_smoke.mjs
node test_union.mjs
node test_drill.mjs
node test_union_matrix.mjsTo rebuild wrenai_github.duckdb and the parquet files from the live GitHub API:
pip install "dlt[duckdb]>=0.5.1"
# .dlt/secrets.toml — NOT committed; create it yourself:
# [sources.github]
# access_token = "ghp_..."
python github_pipeline.pyThen export the DuckDB tables to dashboard/data/*.parquet so the dashboard
picks them up.
- The dashboard pins
@wrenai/wren-core-wasm@0.4.0. That version crashes onUNION ALL, so the dashboard merges union results in JS — see the comments inindex.html. - Model names are case-sensitive; quote them in raw SQL (
SELECT * FROM "issues"). wren_project/target/is gitignored. Runwren context buildinsidewren_project/to regeneratetarget/mdl.json(the dashboard ships with its own copy atdashboard/mdl.json).