dbt Docs on GitHub Pages: Prepare the Lineage Index Before Hosting

A model appearing in documentation does not establish its column’s origin. Trace the renamed displaylabel back through label, and identify whether the current index actually contains lineage data.

The authored three-node graph exposes the expected rename path while keeping missing, stale, and lineage-unavailable index states separate. It produces source-review text, not a native dbt index.

dbt Docs on GitHub Pages: Prepare the Lineage Index Before Hosting
dbt Docs on GitHub Pages: Prepare the Lineage Index Before Hosting
Open the full example ↗

Give the index a small question to answer

Use this practice project before investigating a large production graph. It has one declared source and two models:

Resource columns and operation
Source supplies id, label
Model stg_supplies Select id and label from the declared source
Model display_supplies Select id and rename label to display_label through a reference to stg_supplies

The expected column path is supplies.label → stg_supplies.label → display_supplies.display_label. Use this as the expected path when preparing the SQL, source declarations, resource identifiers, connection settings, and data; it is not a compiled-project result.

Keep resource identity beside each column name. Searching for another column named display_label would miss the upstream label. A model dependency graph alone also cannot establish this particular column's origin. dbt distinguishes renamed or passed-through columns from transformed columns in its column lineage documentation. For this fixture, inspect the renamed column itself and compare the reported origin with the declared source path.

Choose the version before choosing the commands

The current local v2 documentation describes compact indexes and a static export. Record the installed version and adapter before borrowing its instructions. An existing v1 workflow needs its own version-specific artifact and command contract; do not treat v2 Parquet indexes as a substitute for that workflow. The documentation viewing guide explains the local v2 export separately from the legacy path.

For local v2 column lineage, the official pages call for strict static analysis, but their examples use different index-generation flags. The viewing guide shows compile with --write-index; the column lineage page shows compile with --generate-info-schema. Both examples use --static-analysis strict before a subsequent docs generate --no-compile. Confirm the supported flags and resulting index contract against the actual installed CLI. Do not combine both flags into an invented command.

Keep four evidence fields separate: compilation result, index creation result, documentation export result, and model execution or test result. A successful documentation export does not establish that warehouse models ran, that materialized rows match the fixture, or that tests passed. Those fields remain unverified until their own native evidence exists.

Test absence and freshness explicitly

Start with the documented standard export as a comparison case, then prepare the strict-analysis index using the confirmed version-specific command. The docs command reference states that column lineage is hidden when its data is unavailable. Describe that first case as “lineage unavailable in this export,” rather than “no upstream columns.”

Use these acceptance cases for the later native test:

Case What the reviewer should establish
Strict index for the practice revision The actual indexed origin matches the expected rename path
Standard export without lineage data Unavailable lineage is distinguished from an inspected, empty result
Index absent before --no-compile Export is held; missing input is recorded
Index retained from an older source revision Freshness remains unresolved until the revision is reconciled

The command reference says --no-compile uses the index already on disk and errors if it is absent. It does not make an old index current. Bind the source commit, installed version, command, generation time, and actual index inventory in your record. If you later change the source declaration or rename expression, reopen the lineage check instead of carrying forward an earlier approval.

Inventory the site you intend to host

For the local v2 path, the export includes an HTML entry point, application assets, and index files. Record actual filenames and paths after generation; copying only index.html leaves the bundle incomplete. The viewing guide also describes browser-side DuckDB-WASM loading from a CDN. Static hosting therefore does not, by itself, establish offline operation. dbt's export guide supports self-hosting the complete site.

Try the worked example

Inspect the strict/current fixture to trace label through the renamed output. Switch to Standard to see lineage unavailable, not empty. Change the source revision to S2 while leaving index S1 to hold freshness. Missing index is a separate export input failure. An exported site does not prove models ran or tests passed.

This inspects authored lineage records and entered revision labels, not a dbt compile, Parquet index, warehouse result, or GitHub Pages deployment.

Recreate this example

Build one complete self-contained HTML page for this task: trace the supplied renamed-column lineage and classify entered index availability/freshness.

Use these exact original practice data and worked expectations: Trace supplies.label through stg_supplies.label to display_supplies.display_label. The original source revision is S1. Inspect strict-current, standard-no-lineage, missing, and stale index states; unavailable lineage does not establish that no dependency exists.

Implement the following useful local interactions: Source revision and index revision fields; strict/standard/missing buttons and Inspect. Trace the original graph only when lineage is available and revisions match. Stale index cannot become current. Display complete export inventory reminder; do not invent native flags or run/warehouse results. Preserve the supplied source text and distinguish an uncomputed state, a successful local result, and an invalid or incomplete input. Update output only from the current input snapshot. An input edit must retire stale feedback until the reader runs the relevant action again. Do not silently invent missing values or replace a failing case with a success.

Design the page as a compact source-and-result developer workbench with readable code, labeled inputs, and a separate explanation area. Put a compact task heading, actual sample data, the main result, and usable controls early enough to be useful on a narrow screen. Use readable text of at least 16px, generous paragraph spacing, strong contrast, native labels, accessible buttons, and visible keyboard focus. Stack long records at 360px and wrap code without page-level horizontal overflow.

Use type=button and explicit querySelector-based click handlers rather than relying on form submission. If Enter is useful, handle it only on the relevant input and ignore isComposing. Keep effects within this open page; no remote dependencies, network calls, persistence, fake downloads, or automated sending. This inspects authored lineage records and entered revision labels, not a dbt compile, Parquet index, warehouse result, or GitHub Pages deployment. Place worked explanations beside their data and identify teacher or synthetic examples clearly. Output only the complete HTML document, with inline styles and script and LF line endings.

Review the original lineage and index-state inspector in NOS

Compare the expected path with the actual native index before hosting the complete export bundle. Review the label-to-display_label path beside the index revision in NOS, and revise eligible static index-preparation notes in visual editing mode if a stale index obscures the rename.

Keep reading