Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add docs for configs for semantic models #3997

Closed
FishtownBuildBot opened this issue Aug 31, 2023 · 2 comments · Fixed by #4144
Closed

Add docs for configs for semantic models #3997

FishtownBuildBot opened this issue Aug 31, 2023 · 2 comments · Fixed by #4144
Assignees
Labels
content Improvements or additions to content dbt Core The changes proposed in this issue relate to dbt Core dbt-core v1.7 Docs impact for the v1.7 release (Oct 2023) improvement Use this when an area of the docs needs improvement as it's currently unclear

Comments

@FishtownBuildBot
Copy link

FishtownBuildBot commented Aug 31, 2023

Related PR: dbt-labs/dbt-core#8502

Page to update

https://docs.getdbt.com/docs/build/semantic-models#semantic-models-components

What to update

Semantic models now support configs in the schema file or at the project level

models/semantic.yml

semantic_models:
  - name: orders
    config:
      enabled: true | false
      group: some_group
      meta: {"some_key": "some_value"}

dbt_project.yml

semantic-models:
  my_project_name:
    +enabled: true | false
    +group: some_group
    +meta: {"some_key": "some_value"}
@emmyoop emmyoop added content Improvements or additions to content dbt Core The changes proposed in this issue relate to dbt Core improvement Use this when an area of the docs needs improvement as it's currently unclear labels Aug 31, 2023
@emmyoop emmyoop changed the title Docs Changes Needed from dbt-core PR #8502 Add docs for configs for semantic models Aug 31, 2023
@jtcohen6 jtcohen6 added dbt-core v1.7 Docs impact for the v1.7 release (Oct 2023) idea Proposes an idea for new content labels Sep 11, 2023
@jtcohen6 jtcohen6 added this to the dbt Core v1.7 Documentation milestone Sep 11, 2023
@graciegoheen
Copy link
Collaborator

We may also want to update the docs for:

@matthewshaver matthewshaver self-assigned this Sep 27, 2023
matthewshaver added a commit that referenced this issue Oct 10, 2023
## What are you changing in this pull request and why?

Semantic model configs for dbt project.yml

Closes: #3997

## Checklist

Uncomment if you're publishing docs for a prerelease version of dbt
(delete if not applicable):
- [x] Add versioning components, as described in [Versioning
Docs](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#versioning-entire-pages)

- [x] Review the [Content style
guide](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/content-style-guide.md)
and [About
versioning](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#adding-a-new-version)
so my content adheres to these guidelines.
- [x] Add a checklist item for anything that needs to happen before this
PR is merged, such as "needs technical review" or "change base branch."
matthewshaver added a commit that referenced this issue Nov 8, 2023
related to: #3997
related to: #4281

## What are you changing in this pull request and why?
- Fix version blocks for other resource types
- Match the style for other resource types for
`models/semantic_models.yml`
- Fix code example in `dbt_project.yml` to refer to `semantic-models`
(since `semantic_models` won't work)
- Simplify the definition by removing an explicit listing of applicable
resource types
- rather than adding the missing ones (like seeds and semantic models)

## Other
- Opened an issue to standardize the order of code examples for
`dbt_project.yml` vs. `properties.yml`:
[#4417](#4417)
- Opened an issue to figure out: do analyses _really_ have a `group`
config?1
[#4416](#4416)
- Opened an issue to standardize on `<group_name>` instead of `finance`
in generic syntax examples
[#4418](#4418)

## 🎩

### Previews
-
[1.6](https://docs-getdbt-com-git-dbeatty-semantic-models-gro-95bd63-dbt-labs.vercel.app/reference/resource-configs/group?version=1.6)
-
[1.7](https://docs-getdbt-com-git-dbeatty-semantic-models-gro-95bd63-dbt-labs.vercel.app/reference/resource-configs/group?version=1.7)

### v1.7

<img width="500" alt="image"
src="https://github.com/dbt-labs/docs.getdbt.com/assets/44704949/73ad131a-2ec2-4e90-b04a-d9ccd41cb18f">

## Checklist
- [x] I have tested that the code examples work
- [x] I have tested that the changes look correct in the Vercel preview
- [x] Review the [Content style
guide](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/content-style-guide.md)
and [About
versioning](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#adding-a-new-version)
so my content adheres to these guidelines.
matthewshaver added a commit that referenced this issue Nov 8, 2023
related to: #3997
related to: #4281

## What are you changing in this pull request and why?
- Add an example for config in `dbt_project.yml`
- Match the style for other resource types for
`models/semantic_models.yml`
- Simplify the definition by removing the explicit listing of applicable
resource types
- rather than bring it up-to-date by adding sources, metrics, and
exposures

## 🎩 

### Previews
-
[1.6](https://docs-getdbt-com-git-dbeatty-semantic-models-ena-f0b17e-dbt-labs.vercel.app/reference/resource-configs/enabled?version=1.6)
-
[1.7](https://docs-getdbt-com-git-dbeatty-semantic-models-ena-f0b17e-dbt-labs.vercel.app/reference/resource-configs/enabled?version=1.7)

### v1.7

<img width="500" alt="image"
src="https://github.com/dbt-labs/docs.getdbt.com/assets/44704949/c63a2128-77c6-48ec-b498-76e1e5f6d02b">

## Checklist
- [x] I have tested that the code examples work
- [x] I have tested that the changes look correct in the Vercel preview
- [x] Review the [Content style
guide](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/content-style-guide.md)
and [About
versioning](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#adding-a-new-version)
so my content adheres to these guidelines.
@dbeatty10
Copy link
Contributor

In case anyone uses this issue description for its code examples, I just now fixed the code examples that I originally wrote incorrectly.

dbeatty10 added a commit that referenced this issue Nov 16, 2023
related to: #3997

## What are you changing in this pull request and why?
- Add "Semantic models" tab for `config`
- Add a "Definition" header (like other similar pages, like
[`group`](https://docs.getdbt.com/reference/resource-configs/group),
[`enabled`](https://docs.getdbt.com/reference/resource-configs/enabled),
etc.)

## Other
- Added semantic models & metrics to
[#3957](#3957)

## 🎩 

### Previews
-
[1.6](https://docs-getdbt-com-git-dbeatty-semantic-models-config-dbt-labs.vercel.app/reference/resource-properties/config?version=1.6)
-
[1.7](https://docs-getdbt-com-git-dbeatty-semantic-models-config-dbt-labs.vercel.app/reference/resource-properties/config?version=1.7)

### v1.6

<img width="500" alt="image"
src="https://github.com/dbt-labs/docs.getdbt.com/assets/44704949/3bee360e-7709-4dde-9d5f-a81ce5095e96">

### v1.7

<img width="500" alt="image"
src="https://github.com/dbt-labs/docs.getdbt.com/assets/44704949/231c4b4b-e344-4757-ad93-50ec2d228e22">


## Checklist
- [x] I have tested that the code examples work
- [x] I have tested that the changes look correct in the Vercel preview
- [x] Review the [Content style
guide](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/content-style-guide.md)
and [About
versioning](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#adding-a-new-version)
so my content adheres to these guidelines.

---------

Co-authored-by: mirnawong1 <89008547+mirnawong1@users.noreply.github.com>
@runleonarun runleonarun removed the idea Proposes an idea for new content label Mar 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
content Improvements or additions to content dbt Core The changes proposed in this issue relate to dbt Core dbt-core v1.7 Docs impact for the v1.7 release (Oct 2023) improvement Use this when an area of the docs needs improvement as it's currently unclear
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants