# Recipes (/docs/editor/recipes)

Complete rules to build in the editor, each with its settings and the file it writes.



Each recipe gives the settings to enter in the editor, then the rule file the editor writes. Start each with **New rule > New rule from scratch** in the [Rules settings](/docs/editor/rules-list). A recipe's file can also be saved as is in your rules folder.

Conditions are written as they read in the editor: *field* **operator** *value*.

## Temporary clip names [#temporary-clip-names]

Report clips still named after a placeholder, such as `TEMP shot 3`.

| Setting     | Value                                                            |
| :---------- | :--------------------------------------------------------------- |
| Id          | `no-temp-clip-names`                                             |
| Name        | Temporary clip names                                             |
| Scope       | Clip                                                             |
| Severity    | Warning                                                          |
| Report when | `clip.name` **matches** `^(TEMP\|TMP)\b`                         |
| Message     | `Clip "{clip.name}" on {clip.track} still has a temporary name.` |

```json title="no-temp-clip-names.rule.json"
{
  "formatVersion": 1,
  "id": "no-temp-clip-names",
  "name": "Temporary clip names",
  "description": "Reports clips whose name starts with TEMP or TMP.",
  "category": "static",
  "scope": "clip",
  "severity": "warning",
  "checks": [
    {
      "condition": { "field": "clip.name", "operator": "matches", "value": "^(TEMP|TMP)\\b" },
      "message": "Clip \"{clip.name}\" on {clip.track} still has a temporary name."
    }
  ]
}
```

## Unwanted file types [#unwanted-file-types]

Report clips whose media is a file type your delivery does not accept. The list is an option, so it can change per project.

| Setting     | Value                                                                      |
| :---------- | :------------------------------------------------------------------------- |
| Id          | `no-unwanted-media-types`                                                  |
| Name        | Unwanted media types                                                       |
| Scope       | Clip                                                                       |
| Severity    | Error                                                                      |
| Option      | `extensions`, List of texts, default `mp3`, `wma`, `gif`                   |
| Report when | `clip.source.extension` **is one of** `options.extensions`                 |
| Message     | `Clip "{clip.name}" on {clip.track} uses a .{clip.source.extension} file.` |

The extension is lower case and without the dot. Clips without media (titles, adjustment layers) have no extension, so they are never reported.

```json title="no-unwanted-media-types.rule.json"
{
  "formatVersion": 1,
  "id": "no-unwanted-media-types",
  "name": "Unwanted media types",
  "description": "Reports clips whose media file type is not accepted.",
  "category": "static",
  "scope": "clip",
  "severity": "error",
  "options": {
    "extensions": { "type": "string[]", "default": ["mp3", "wma", "gif"], "description": "File extensions not accepted, lower case, without the dot." }
  },
  "checks": [
    {
      "condition": { "field": "clip.source.extension", "operator": "in", "value": { "field": "options.extensions" } },
      "message": "Clip \"{clip.name}\" on {clip.track} uses a .{clip.source.extension} file."
    }
  ]
}
```

## Unnamed chapter markers [#unnamed-chapter-markers]

Report chapter markers without a name, which export as empty chapters.

| Setting     | Value                                                                |
| :---------- | :------------------------------------------------------------------- |
| Id          | `no-unnamed-chapters`                                                |
| Name        | Unnamed chapters                                                     |
| Scope       | Marker                                                               |
| Severity    | Warning                                                              |
| Report when | **All** of: `marker.type` **is** `Chapter`, `marker.named` **is** No |
| Message     | `Chapter marker at {marker.startTimecode} has no name.`              |

```json title="no-unnamed-chapters.rule.json"
{
  "formatVersion": 1,
  "id": "no-unnamed-chapters",
  "name": "Unnamed chapters",
  "description": "Reports chapter markers without a name.",
  "category": "static",
  "scope": "marker",
  "severity": "warning",
  "checks": [
    {
      "condition": {
        "all": [
          { "field": "marker.type", "operator": "equals", "value": "Chapter" },
          { "field": "marker.named", "operator": "equals", "value": false }
        ]
      },
      "message": "Chapter marker at {marker.startTimecode} has no name."
    }
  ]
}
```

## Loud audio clips [#loud-audio-clips]

Report audio clips whose volume is raised above a limit. Video clips have no volume, so they are never reported.

| Setting     | Value                                                                                            |
| :---------- | :----------------------------------------------------------------------------------------------- |
| Id          | `max-clip-volume`                                                                                |
| Name        | Loud audio clips                                                                                 |
| Scope       | Clip                                                                                             |
| Severity    | Info                                                                                             |
| Option      | `maxDb`, Number, default `6`                                                                     |
| Report when | **All** of: `clip.disabled` **is** No, `clip.volume` **is greater than** `options.maxDb`         |
| Message     | `Clip "{clip.name}" on {clip.track} is raised to {clip.volume} dB (maximum {options.maxDb} dB).` |
| Data        | `volumeDb` from `clip.volume`                                                                    |

```json title="max-clip-volume.rule.json"
{
  "formatVersion": 1,
  "id": "max-clip-volume",
  "name": "Loud audio clips",
  "description": "Reports audio clips whose volume is raised above a limit.",
  "category": "static",
  "scope": "clip",
  "severity": "info",
  "options": {
    "maxDb": { "type": "number", "default": 6, "description": "Highest allowed clip volume, in dB." }
  },
  "checks": [
    {
      "condition": {
        "all": [
          { "field": "clip.disabled", "operator": "equals", "value": false },
          { "field": "clip.volume", "operator": "greaterThan", "value": { "field": "options.maxDb" } }
        ]
      },
      "message": "Clip \"{clip.name}\" on {clip.track} is raised to {clip.volume} dB (maximum {options.maxDb} dB)."
    }
  ],
  "data": { "volumeDb": "clip.volume" }
}
```

## Too many video tracks [#too-many-video-tracks]

Report a sequence with more video tracks than your template allows. This rule runs once, on the sequence.

| Setting     | Value                                                                                          |
| :---------- | :--------------------------------------------------------------------------------------------- |
| Id          | `max-video-tracks`                                                                             |
| Name        | Too many video tracks                                                                          |
| Category    | Project                                                                                        |
| Scope       | Sequence                                                                                       |
| Severity    | Warning                                                                                        |
| Option      | `max`, Number, default `6`                                                                     |
| Report when | `sequence.videoTrackCount` **is greater than** `options.max`                                   |
| Message     | `The sequence has {sequence.videoTrackCount} video tracks; the template allows {options.max}.` |

```json title="max-video-tracks.rule.json"
{
  "formatVersion": 1,
  "id": "max-video-tracks",
  "name": "Too many video tracks",
  "description": "Reports sequences with more video tracks than allowed.",
  "category": "project",
  "scope": "sequence",
  "severity": "warning",
  "options": {
    "max": { "type": "number", "default": 6, "description": "Highest number of video tracks." }
  },
  "checks": [
    {
      "condition": { "field": "sequence.videoTrackCount", "operator": "greaterThan", "value": { "field": "options.max" } },
      "message": "The sequence has {sequence.videoTrackCount} video tracks; the template allows {options.max}."
    }
  ]
}
```

## Tighten a built-in rule [#tighten-a-built-in-rule]

The built-in [Scale range](/docs/rules/scale-range) rule allows 25 % to 200 %. For a project that must never upscale:

1. Open **Scale range** with its cogwheel.
2. In **Options**, set the default of `max` to `100`.
3. Save. Your copy replaces the built-in rule, marked *Modified built-in rule* ([Revert to built-in](/docs/editor/saving#revert-a-built-in-rule) to undo).

Every built-in rule can be adjusted the same way. The [Built-in rules](/docs/rules) pages list their options.
