Skip to content

Report YAML Reference

Field-level specification for Report YAML definitions (reports/report_*.yaml).

  • Location: reports/report_*.yaml
  • report_id must match the filename stem (e.g. report_executive_summary.yaml requires report_id: report_executive_summary)
  • Compiles to per-report data models, a union view, and a registry table
  • Validator: python3 scripts/reportcheck.py
  • Compiler: python3 scripts/reportcompile.py
FieldTypeRequiredDescription
report_idstringYesMust match filename stem
versionstringYesVersion string (e.g. "1")
titlei18n mappingYesReport title (en/de/fr required)
descriptioni18n mappingYesReport description (en/de/fr required)
audiencelist of stringsNoTarget audience roles (e.g. [cfo, coo])
pagemappingNoSee Page
sectionslistYesNon-empty list of sections. Section id values must be unique. See Sections

All i18n fields are mappings with keys en, de, fr (all three required).

FieldTypeRequiredDefaultValid Values
orientationstringNoportraitportrait, landscape
sizestringNoA4A4, A3, letter

Every section has these common fields:

FieldTypeRequiredDescription
idstringYesUnique section identifier within the report
typestringYesSee Section Types
titlei18n mappingNoSection title. Must be i18n if present
TypeRequired FieldsDescription
kpi_griditemsGrid of KPI cards. Optional columns (integer, default 4)
calloutitemsHighlighted metric cards. Optional columns (integer)
severity_barqueryStacked bar showing severity distribution
tablequeryData table with optional column definitions
textcontentStatic text block (i18n mapping, en/de/fr required)
footertextFooter text block (i18n mapping, en/de/fr required)
chart_barqueryBar chart from query results
chart_trendqueryTrend/line chart from query results
FieldTypeRequiredDescription
labeli18n mappingYesDisplay label (en/de/fr required)
querystringYesSQL query returning a single value column
formatstringNoSee Valid Formats. Default: number

Query Field (for severity_bar, table, chart_bar, chart_trend)

Section titled “Query Field (for severity_bar, table, chart_bar, chart_trend)”

A SQL string. Supports template helpers:

TemplateResolves toExample
{{ gold('entity') }}{{ ref('gold_entity') }}{{ gold('shipments') }}
{{ silver('entity') }}{{ ref('silver_entity') }}{{ silver('cases') }}
{{ ref('model') }}Pass-through dbt ref{{ ref('probe_findings') }}
{{ tenant_id }}{{ var("tenant_id") }}Used in WHERE clauses

Must return columns: high, medium, low, total (all integers).

Optional. When provided, controls column display.

FieldTypeRequiredDescription
fieldstringYesColumn name from query result
labeli18n mappingYesDisplay header (en/de/fr required)
widthinteger (1-12)NoGrid width
alignstringNoleft, center, or right
formatstringNoSee Valid Formats

number, chf, chf_compact, percent, date, text

report_id: report_executive_summary
version: "1"
title:
en: "Executive Summary"
de: "Zusammenfassung"
fr: "Resume executif"
description:
en: "High-level overview of analytical findings and financial exposure."
de: "Ueberblick ueber analytische Befunde und finanzielle Exposition."
fr: "Vue d'ensemble des resultats analytiques et de l'exposition financiere."
audience: [cfo, coo]
page:
orientation: portrait
size: A4
sections:
- id: kpi_grid
type: kpi_grid
title:
en: "Key Metrics"
de: "Kennzahlen"
fr: "Indicateurs cles"
columns: 4
items:
- label: { en: "Total Cases", de: "Faelle gesamt", fr: "Cas totaux" }
query: "SELECT count(*) as value FROM {{ gold('cases') }}"
format: number
- label: { en: "Total Billing", de: "Umsatz gesamt", fr: "Facturation totale" }
query: "SELECT coalesce(sum(amount), 0) as value FROM {{ gold('billing_events') }}"
format: chf_compact
- label: { en: "Findings", de: "Befunde", fr: "Resultats" }
query: "SELECT count(*) as value FROM {{ ref('probe_findings') }}"
format: number
- label: { en: "Confirmed Theses", de: "Bestaetigte Hypothesen", fr: "Theses confirmees" }
query: "SELECT count(*) as value FROM {{ ref('hypothesis_verdicts') }} WHERE status = 'confirmed'"
format: number
- id: severity_distribution
type: severity_bar
title:
en: "Finding Severity Distribution"
de: "Befund-Schweregrad-Verteilung"
fr: "Distribution de gravite des resultats"
query: >
SELECT
count(*) FILTER (WHERE severity = 'high') as high,
count(*) FILTER (WHERE severity = 'medium') as medium,
count(*) FILTER (WHERE severity = 'low') as low,
count(*) as total
FROM {{ ref('probe_findings') }}
- id: top_findings
type: table
title:
en: "Top Findings by Risk"
de: "Top-Befunde nach Risiko"
fr: "Principaux resultats par risque"
query: >
SELECT probe_id, severity, money_at_risk
FROM {{ ref('probe_findings') }}
ORDER BY money_at_risk DESC
LIMIT 10
columns:
- field: probe_id
label: { en: "Signal", de: "Signal", fr: "Sonde" }
width: 4
- field: severity
label: { en: "Severity", de: "Schweregrad", fr: "Gravite" }
width: 2
- field: money_at_risk
label: { en: "CHF at Risk", de: "CHF Exposition", fr: "CHF a risque" }
format: chf
align: right
width: 3
- id: footer
type: footer
text:
en: "All findings are algorithmically derived and should be reviewed by domain experts."
de: "Alle Befunde sind algorithmisch abgeleitet und sollten von Fachexperten geprueft werden."
fr: "Tous les resultats sont derives algorithmiquement et doivent etre examines par des experts."
jazzisnow jinflow is a jazzisnow product
v0.45.1 · built 2026-04-17 08:14 UTC