Skip to content

dct search

Search the project's boards by keyword with ranked results, or its meta.yml, dbt model, and config files for matching lines. Each board hit includes the board's title, notes, and source path, plus its match score, why it matched, and the charts whose id or title matched. Run dct search with no text to list every board by path. Board files in markdown are searched too. For a board's charts and queries, run dct describe on its path.

dct search [OPTIONS] [TEXT]

Arguments

Argument Description
TEXT Boards: keywords to match against board metadata. Other kinds: a substring to find in file contents. Omit to list.

Options

Flag Description
--kind TEXT What to search: boards (default), meta, models, config, or all.
--path TEXT Glob over project-relative paths to narrow by, for example charts/finance/**.
--json Output as JSON.
--limit INT Maximum results to return. Default 10, max 200 (values above 200 are clamped to 200).
--project-dir DIRECTORY Project root for resolving board paths and finding project config. [env var: DCT_PROJECT_DIR]

Examples

dct search revenue
dct search "monthly trends" --limit 5
dct search orders --json
dct search --kind meta
dct search order_id --kind models

What's searched

--kind picks what is searched:

Kind Searches
boards Board files, YAML and markdown (the default)
meta Every meta.yml: the folder defaults and themes
models The dbt project's .sql and .yml model files under models/
config dbt_charts.yml and dbt_project.yml
all Every file in the project

For every kind but boards, text is a case-insensitive substring and each hit is a matching line; without text, the result is the list of files.

Each board is indexed on:

  • title: and notes: fields
  • Chart ids and titles
  • Query names and SQL bodies
  • Tags and other metadata

Hits are ranked by relevance.

Finding a chart

Each board hit lists the charts that matched, by id (matched_charts in --json output). A board path plus a chart id addresses one chart:

dct search revenue
dct describe charts/sales.yml --chart revenue_kpi
dct render charts/sales.yml --chart revenue_kpi

When charts on several boards match, each board's hit lists its own.

When to use which search verb

If you want to find… Use
A dashboard about revenue dct search
A column or table in the warehouse dct query against INFORMATION_SCHEMA
A field in the YAML reference dct skills chart, or the YAML reference
A packaged agent skill dct skills