Deeper reviews take longer and cost more.
otto.yml lets you spend depth where it matters: max on payments and auth, standard on docs, and your workspace default everywhere else.
Set a depth
For the whole repository:otto.yml
otto.yml
How Otto picks the depth
A pull request is reviewed at one depth, chosen from the files it changes:1
Each changed file gets a depth
- The highest
depthamong thepathsrules that match the file. - If no rule with a
depthmatches,reviews.depth. - If
reviews.depthisn’t set, your workspace’s depth.
2
The review runs at the highest of those
standard < deep < max. Ignored files don’t count.Examples
With the config above (reviews.depth: deep, payments and auth at max, docs at standard):
When every changed file is ignored, only
reviews.depth can apply. If it
isn’t set, the review runs at your workspace depth.Lowering the depth for low-risk paths
Astandard rule only lowers the depth when every reviewable file in the PR is covered by rules at standard. Any other file raises the review back to reviews.depth or your workspace depth.
To review a repository at standard by default and go deeper only where it matters, set reviews.depth: standard and raise specific paths:
otto.yml
Rules combine
Every matching rule contributes, so overlapping rules are fine:- A file’s depth is the highest depth among all rules that match it, not the first match.
- A rule without a
depth(for example, one that only addsinstructions) doesn’t affect the depth. - Rule order doesn’t matter for depth.
Precedence
The depth applies to
/otto review and /otto re-review as well as automatic reviews.