Configuration Reference¶
This reference is generated from the pydantic schemas in src/lgtmaybe/core/models.py.
ReviewConfig¶
The user-facing configuration model. Fields map directly to .lgtmaybe.yml keys and CLI flags.
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
api_base |
string / null | No | null |
Api Base |
auto_describe |
boolean | No | True |
Auto Describe |
auto_diagram |
boolean | No | True |
Auto Diagram |
categories |
list[complexity / correctness / deprecation / documentation / intent / performance / ponytail / security / spec / tests] |
No | ['security', 'correctness', 'deprecation', 'tests', 'documentation', 'performance', 'complexity', 'intent', 'ponytail', 'spec'] |
Categories |
context_lines |
integer | No | 20 |
Context Lines |
directory_rules |
list[DirectoryRule] | No | [] |
Directory Rules |
exclude_paths |
list[string] | No | [] |
Exclude Paths |
extra_lenses |
list[CustomLens] | No | [] |
Extra Lenses |
fail_on |
critical / high / info / low / medium / null |
No | null |
|
fallback_model |
string / null | No | null |
Fallback Model |
finding_rules |
list[FindingRule] | No | [] |
Finding Rules |
function_context |
boolean | No | True |
Function Context |
high_impact |
boolean | No | True |
High Impact |
ignore_fingerprints |
list[string] | No | [] |
Ignore Fingerprints |
include_paths |
list[string] | No | [] |
Include Paths |
incremental |
boolean / null | No | null |
Incremental |
language |
string / null | No | null |
Language |
learn_feedback |
boolean | No | True |
Learn Feedback |
max_concurrency |
integer / null | No | null |
Max Concurrency |
max_file_diff_lines |
integer | No | 2000 |
Max File Diff Lines |
max_files |
integer | No | 50 |
Max Files |
max_findings_per_lens |
integer | No | 50 |
Max Findings Per Lens |
max_input_tokens |
integer | No | 100000 |
Max Input Tokens |
max_review_seconds |
integer | No | 3600 |
Max Review Seconds |
max_review_tokens |
integer | No | 0 |
Max Review Tokens |
max_tokens |
integer / null | No | null |
Max Tokens |
mid_review_retrieval |
boolean | No | False |
Mid Review Retrieval |
min_confidence |
integer | No | 0 |
Min Confidence |
min_severity |
critical / high / info / low / medium |
No | low |
|
model |
string | Yes | — | Model |
num_ctx |
integer / null | No | null |
Num Ctx |
pr_labels |
boolean | No | False |
Pr Labels |
preset |
fast / full |
No | fast |
|
provider |
anthropic / azure / bedrock / ollama / openai / openai-compatible / openrouter / vertex / zai |
Yes | — | |
reasoning_effort |
string / null | No | null |
Reasoning Effort |
recursive |
boolean | No | True |
Recursive |
reflect |
boolean | No | True |
Reflect |
reflect_model |
string / null | No | null |
Reflect Model |
repair_unparseable |
boolean | No | True |
Repair Unparseable |
resolve_fixed |
boolean | No | True |
Resolve Fixed |
retry_without_schema |
boolean | No | True |
Retry Without Schema |
spec_paths |
list[string] | No | [] |
Spec Paths |
spec_review |
boolean | No | True |
Spec Review |
static_analysis |
StaticAnalysisConfig | No | {'enabled': False, 'tools': ['ruff', 'bandit', 'semgrep', 'mypy', 'gitleaks', 'zizmor', 'ast-grep', 'osv-scanner'], 'min_severity': 'info', 'tool_min_severity': {}, 'tool_mode': {}, 'semgrep_rules': None, 'ast_grep_rules': None} |
|
structured_output |
boolean | No | True |
Structured Output |
summary_template |
string / null | No | null |
Summary Template |
symbol_resolution |
boolean | No | True |
Symbol Resolution |
temperature |
number | No | 0.0 |
Temperature |
timeout |
integer / null | No | null |
Timeout |
triage_model |
string / null | No | null |
Triage Model |
unanchored_min_severity |
critical / high / info / low / medium |
No | high |
Enums¶
Provider¶
LLM backend selected by --provider. Cloud providers (bedrock, vertex, azure) use ambient credentials — azure also needs the resource endpoint (--api-base) and accepts a key as an alternative. openai-compatible points at any server speaking the OpenAI /v1 wire format (DeepSeek, llama.cpp, LM Studio, vLLM) via --api-base; the key is optional so keyless local servers work.
anthropicazurebedrockollamaopenaiopenai-compatibleopenroutervertexzai
Severity¶
Finding severity, ordered low to high. Use min_severity in config to suppress findings below a threshold.
criticalhighinfolowmedium
ReviewFinding¶
The structured output the model must return for each inline comment. All fields are validated by pydantic before anything is posted.
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
anchor |
string / null | No | null |
Anchor |
anchored |
boolean | No | True |
Anchored |
body |
string | Yes | — | Body |
broad |
boolean | No | False |
Broad |
category |
string / null | No | null |
Category |
confidence |
integer / null | No | null |
Confidence |
failure_scenario |
string / null | No | null |
Failure Scenario |
line |
integer | Yes | — | Line |
path |
string | Yes | — | Path |
severity |
critical / high / info / low / medium |
Yes | — | |
side |
string | No | RIGHT |
Side |
suggestion |
string / null | No | null |
Suggestion |
title |
string | Yes | — | Title |
ProviderResult¶
The normalised return value of one LLM completion, including token usage.
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
attempts |
integer | No | 1 |
Attempts |
cache_creation_tokens |
integer | No | 0 |
Cache Creation Tokens |
cache_read_tokens |
integer | No | 0 |
Cache Read Tokens |
cost_usd |
number / null | No | null |
Cost Usd |
input_tokens |
integer | Yes | — | Input Tokens |
model |
string / null | No | null |
Model |
output_ceiling |
integer / null | No | null |
Output Ceiling |
output_tokens |
integer | Yes | — | Output Tokens |
reasoning_tokens |
integer / null | No | null |
Reasoning Tokens |
text |
string | Yes | — | Text |
PRContext¶
Everything the engine needs about a pull request. Fetched via the GitHub REST API — PR code is never checked out.
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
base_sha |
string | Yes | — | Base Sha |
changed_files |
list[string] | Yes | — | Changed Files |
commit_messages |
list[string] | No | [] |
Commit Messages |
description |
string | No | `` | Description |
diff |
string | Yes | — | Diff |
feedback_downvotes |
list[string] | No | [] |
Feedback Downvotes |
file_contents |
object | No | — | File Contents |
head_branch |
string | No | `` | Head Branch |
head_sha |
string | Yes | — | Head Sha |
open_finding_threads |
integer | No | 0 |
Open Finding Threads |
pr_number |
integer | Yes | — | Pr Number |
repo |
string | Yes | — | Repo |
scan_contents |
object | No | — | Scan Contents |
title |
string | No | `` | Title |
Raw JSON schemas¶
The canonical machine-readable schemas. These are the source of truth for provider output validation.
ReviewConfig¶
{
"$defs": {
"CustomLens": {
"additionalProperties": false,
"description": "A user-defined review lens \u2014 a \"skill file\" run alongside the built-ins.\n\nThe engine fans it out as its own focused LLM call (same pipeline as a\nbuilt-in ``ReviewCategory``) and merges its findings with the rest. A lens is\ndeclared in **trusted** config (``.lgtmaybe.yml`` or a file referenced by\n``lens_paths``), never from PR-author content, so its text is safe to put in\nthe system prompt. Supplying a worked example (``example_diff`` +\n``example_finding``) is optional but sharply improves a small model's output.",
"properties": {
"example_diff": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Example Diff"
},
"example_finding": {
"anyOf": [
{
"$ref": "#/$defs/ReviewFinding"
},
{
"type": "null"
}
],
"default": null
},
"id": {
"title": "Id",
"type": "string"
},
"instructions": {
"title": "Instructions",
"type": "string"
},
"title": {
"default": "",
"title": "Title",
"type": "string"
}
},
"required": [
"id",
"instructions"
],
"title": "CustomLens",
"type": "object"
},
"DirectoryRule": {
"additionalProperties": false,
"description": "Extra review instructions and context scoped to part of the repo.\n\nA monorepo is not uniform: ``payments/**`` wants strictness that would be\nnoise in ``tests/**``, and reviewing ``src/**`` well may need a design doc\nthe diff never shows. Each rule names the paths it applies to (fnmatch globs\nagainst the repo-relative path, a ``**/`` prefix also matching at the repo\nroot \u2014 the same matcher the path filters use; an EMPTY list applies the rule\neverywhere, mirroring ``FindingRuleMatch``), free-text ``instructions``, and\n``context_files`` read from the checked-out workspace.\n\nBoth are trusted configuration: on ``pull_request_target`` the workspace is\nthe BASE branch, so neither the instructions nor the context text is ever\nPR-author content.",
"properties": {
"context_files": {
"items": {
"type": "string"
},
"title": "Context Files",
"type": "array"
},
"instructions": {
"default": "",
"title": "Instructions",
"type": "string"
},
"paths": {
"items": {
"type": "string"
},
"title": "Paths",
"type": "array"
}
},
"title": "DirectoryRule",
"type": "object"
},
"FindingRule": {
"additionalProperties": false,
"description": "One declarative post-processing rule, applied in list order.\n\nThe safe alternative to arbitrary user hooks: rules can only filter or\nre-grade findings \u2014 no user code ever executes.",
"properties": {
"action": {
"$ref": "#/$defs/FindingRuleAction"
},
"match": {
"$ref": "#/$defs/FindingRuleMatch",
"default": {
"category": null,
"min_severity": null,
"path": null,
"title_contains": null
}
}
},
"required": [
"action"
],
"title": "FindingRule",
"type": "object"
},
"FindingRuleAction": {
"additionalProperties": false,
"description": "What a matched rule does: drop the finding, or remap its severity.",
"properties": {
"drop": {
"default": false,
"title": "Drop",
"type": "boolean"
},
"set_severity": {
"anyOf": [
{
"$ref": "#/$defs/Severity"
},
{
"type": "null"
}
],
"default": null
}
},
"title": "FindingRuleAction",
"type": "object"
},
"FindingRuleMatch": {
"additionalProperties": false,
"description": "The selector of a finding rule. Every specified field must match (AND).\n\nAn empty match selects every finding. ``path`` is an fnmatch glob against\nthe repo-relative path (a ``**/`` prefix also matches at the repo root,\nlike the path filters); ``category`` is the originating lens id;\n``title_contains`` is a case-insensitive substring; ``min_severity``\nselects findings at or above that severity.",
"properties": {
"category": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Category"
},
"min_severity": {
"anyOf": [
{
"$ref": "#/$defs/Severity"
},
{
"type": "null"
}
],
"default": null
},
"path": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Path"
},
"title_contains": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Title Contains"
}
},
"title": "FindingRuleMatch",
"type": "object"
},
"Provider": {
"description": "The backend selected by the `--provider` flag.",
"enum": [
"openai",
"openrouter",
"anthropic",
"bedrock",
"vertex",
"azure",
"ollama",
"openai-compatible",
"zai"
],
"title": "Provider",
"type": "string"
},
"ReviewCategory": {
"description": "A single review lens. The engine asks for each one in its own LLM call.\n\n``intent`` checks the diff against the PR's stated intent (title, description,\ncommit messages); it only runs when the context carries some stated intent.\n``ponytail`` is the \"lazy senior dev\" lens \u2014 the best code is the code you\nnever wrote \u2014 flagging code that needn't exist at all (YAGNI, reach for the\nstandard library, do it in fewer lines).\n``spec`` checks the diff against a specification the repository commits\n(OpenSpec, GitHub Spec Kit, Kiro); like ``intent`` it only runs when there is\nsomething to check against \u2014 here, a detected spec that matches the PR.",
"enum": [
"security",
"correctness",
"deprecation",
"tests",
"documentation",
"performance",
"complexity",
"intent",
"ponytail",
"spec"
],
"title": "ReviewCategory",
"type": "string"
},
"ReviewFinding": {
"additionalProperties": false,
"description": "A single inline review comment the model wants to post.",
"properties": {
"anchor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Anchor"
},
"anchored": {
"default": true,
"title": "Anchored",
"type": "boolean"
},
"body": {
"title": "Body",
"type": "string"
},
"broad": {
"default": false,
"title": "Broad",
"type": "boolean"
},
"category": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Category"
},
"confidence": {
"anyOf": [
{
"maximum": 10,
"minimum": 0,
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Confidence"
},
"failure_scenario": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Failure Scenario"
},
"line": {
"minimum": 1,
"title": "Line",
"type": "integer"
},
"path": {
"title": "Path",
"type": "string"
},
"severity": {
"$ref": "#/$defs/Severity"
},
"side": {
"default": "RIGHT",
"enum": [
"LEFT",
"RIGHT"
],
"title": "Side",
"type": "string"
},
"suggestion": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Suggestion"
},
"title": {
"title": "Title",
"type": "string"
}
},
"required": [
"path",
"line",
"severity",
"title",
"body"
],
"title": "ReviewFinding",
"type": "object"
},
"ReviewPreset": {
"description": "How many model calls a review spends: the everyday path or the deep audit.\n\n``fast`` (the default) covers all nine built-in categories in FOUR calls,\none per concern: security, correctness (with stated intent folded in), code\nhealth, and artefacts (tests + documentation). The same four run on every\nprovider \u2014 worker count changes the schedule, not the call count.\n``full`` runs each of the nine categories as its own call for release\nbranches and deep audits. An explicit ``categories`` list always wins over\nthe preset.",
"enum": [
"fast",
"full"
],
"title": "ReviewPreset",
"type": "string"
},
"Severity": {
"description": "Finding severity, ordered low \u2192 high for `min_severity` filtering.",
"enum": [
"info",
"low",
"medium",
"high",
"critical"
],
"title": "Severity",
"type": "string"
},
"StaticAnalysisConfig": {
"additionalProperties": false,
"description": "Static-analysis fusion: deterministic tool findings as LLM grounding.\n\nWhen enabled, the installed tools run over the already-fetched changed-file\ntexts (sandboxed subprocess, scrubbed environment, no network, never a\ncheckout) and their findings enter each lens prompt as untrusted HINTS \u2014\n\"confirm, contextualise, or discard\" \u2014 raising recall on the deterministic\nbugs models miss without posting raw linter noise. A tool that isn't\ninstalled is skipped silently, so the feature degrades to nothing on a\nminimal install.",
"properties": {
"ast_grep_rules": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Ast Grep Rules"
},
"enabled": {
"default": false,
"title": "Enabled",
"type": "boolean"
},
"min_severity": {
"$ref": "#/$defs/Severity",
"default": "info"
},
"semgrep_rules": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Semgrep Rules"
},
"tool_min_severity": {
"additionalProperties": {
"$ref": "#/$defs/Severity"
},
"propertyNames": {
"$ref": "#/$defs/StaticAnalysisTool"
},
"title": "Tool Min Severity",
"type": "object"
},
"tool_mode": {
"additionalProperties": {
"$ref": "#/$defs/ToolMode"
},
"propertyNames": {
"$ref": "#/$defs/StaticAnalysisTool"
},
"title": "Tool Mode",
"type": "object"
},
"tools": {
"default": [
"ruff",
"bandit",
"semgrep",
"mypy",
"gitleaks",
"zizmor",
"ast-grep",
"osv-scanner"
],
"items": {
"$ref": "#/$defs/StaticAnalysisTool"
},
"title": "Tools",
"type": "array"
}
},
"title": "StaticAnalysisConfig",
"type": "object"
},
"StaticAnalysisTool": {
"description": "A deterministic linter/SAST tool whose findings feed the review.\n\nThe value is the binary name looked up on PATH, so it may differ from the\nmember name where the binary is hyphenated.",
"enum": [
"ruff",
"bandit",
"semgrep",
"mypy",
"gitleaks",
"zizmor",
"ast-grep",
"osv-scanner"
],
"title": "StaticAnalysisTool",
"type": "string"
},
"ToolMode": {
"description": "How a tool's findings reach the review.\n\n``hint`` is the original fusion behaviour: findings become an untrusted\nHINTS block the model confirms, contextualises, or discards. ``finding``\nskips the model entirely and posts the tool's result as a review comment.\n\nWhich one is right is a property of the tool's precision, not a user\npreference: a secret is present or it isn't, so asking a model to \"confirm\nor discard\" a deterministic regex match only adds cost and doubt. A lint or\na SAST heuristic genuinely benefits from a model judging whether it matters\nhere. Per-tool defaults live in ``engine.static_analysis``; this enum is the\noverride users reach for via ``static_analysis.tool_mode``.",
"enum": [
"hint",
"finding"
],
"title": "ToolMode",
"type": "string"
}
},
"additionalProperties": false,
"description": "How to run one review: provider/model, severity floor, filters, caps.",
"properties": {
"api_base": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Api Base"
},
"auto_describe": {
"default": true,
"title": "Auto Describe",
"type": "boolean"
},
"auto_diagram": {
"default": true,
"title": "Auto Diagram",
"type": "boolean"
},
"categories": {
"default": [
"security",
"correctness",
"deprecation",
"tests",
"documentation",
"performance",
"complexity",
"intent",
"ponytail",
"spec"
],
"items": {
"$ref": "#/$defs/ReviewCategory"
},
"title": "Categories",
"type": "array"
},
"context_lines": {
"default": 20,
"title": "Context Lines",
"type": "integer"
},
"directory_rules": {
"items": {
"$ref": "#/$defs/DirectoryRule"
},
"title": "Directory Rules",
"type": "array"
},
"exclude_paths": {
"items": {
"type": "string"
},
"title": "Exclude Paths",
"type": "array"
},
"extra_lenses": {
"items": {
"$ref": "#/$defs/CustomLens"
},
"title": "Extra Lenses",
"type": "array"
},
"fail_on": {
"anyOf": [
{
"$ref": "#/$defs/Severity"
},
{
"type": "null"
}
],
"default": null
},
"fallback_model": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Fallback Model"
},
"finding_rules": {
"items": {
"$ref": "#/$defs/FindingRule"
},
"title": "Finding Rules",
"type": "array"
},
"function_context": {
"default": true,
"title": "Function Context",
"type": "boolean"
},
"high_impact": {
"default": true,
"title": "High Impact",
"type": "boolean"
},
"ignore_fingerprints": {
"items": {
"type": "string"
},
"title": "Ignore Fingerprints",
"type": "array"
},
"include_paths": {
"items": {
"type": "string"
},
"title": "Include Paths",
"type": "array"
},
"incremental": {
"anyOf": [
{
"type": "boolean"
},
{
"type": "null"
}
],
"default": null,
"title": "Incremental"
},
"language": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Language"
},
"learn_feedback": {
"default": true,
"title": "Learn Feedback",
"type": "boolean"
},
"max_concurrency": {
"anyOf": [
{
"minimum": 1,
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Max Concurrency"
},
"max_file_diff_lines": {
"default": 2000,
"minimum": 0,
"title": "Max File Diff Lines",
"type": "integer"
},
"max_files": {
"default": 50,
"title": "Max Files",
"type": "integer"
},
"max_findings_per_lens": {
"default": 50,
"minimum": 0,
"title": "Max Findings Per Lens",
"type": "integer"
},
"max_input_tokens": {
"default": 100000,
"title": "Max Input Tokens",
"type": "integer"
},
"max_review_seconds": {
"default": 3600,
"minimum": 0,
"title": "Max Review Seconds",
"type": "integer"
},
"max_review_tokens": {
"default": 0,
"minimum": 0,
"title": "Max Review Tokens",
"type": "integer"
},
"max_tokens": {
"anyOf": [
{
"minimum": 0,
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Max Tokens"
},
"mid_review_retrieval": {
"default": false,
"title": "Mid Review Retrieval",
"type": "boolean"
},
"min_confidence": {
"default": 0,
"maximum": 10,
"minimum": 0,
"title": "Min Confidence",
"type": "integer"
},
"min_severity": {
"$ref": "#/$defs/Severity",
"default": "low"
},
"model": {
"title": "Model",
"type": "string"
},
"num_ctx": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Num Ctx"
},
"pr_labels": {
"default": false,
"title": "Pr Labels",
"type": "boolean"
},
"preset": {
"$ref": "#/$defs/ReviewPreset",
"default": "fast"
},
"provider": {
"$ref": "#/$defs/Provider"
},
"reasoning_effort": {
"anyOf": [
{
"enum": [
"none",
"minimal",
"low",
"medium",
"high",
"xhigh",
"default"
],
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Reasoning Effort"
},
"recursive": {
"default": true,
"title": "Recursive",
"type": "boolean"
},
"reflect": {
"default": true,
"title": "Reflect",
"type": "boolean"
},
"reflect_model": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Reflect Model"
},
"repair_unparseable": {
"default": true,
"title": "Repair Unparseable",
"type": "boolean"
},
"resolve_fixed": {
"default": true,
"title": "Resolve Fixed",
"type": "boolean"
},
"retry_without_schema": {
"default": true,
"title": "Retry Without Schema",
"type": "boolean"
},
"spec_paths": {
"items": {
"type": "string"
},
"title": "Spec Paths",
"type": "array"
},
"spec_review": {
"default": true,
"title": "Spec Review",
"type": "boolean"
},
"static_analysis": {
"$ref": "#/$defs/StaticAnalysisConfig",
"default": {
"ast_grep_rules": null,
"enabled": false,
"min_severity": "info",
"semgrep_rules": null,
"tool_min_severity": {},
"tool_mode": {},
"tools": [
"ruff",
"bandit",
"semgrep",
"mypy",
"gitleaks",
"zizmor",
"ast-grep",
"osv-scanner"
]
}
},
"structured_output": {
"default": true,
"title": "Structured Output",
"type": "boolean"
},
"summary_template": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Summary Template"
},
"symbol_resolution": {
"default": true,
"title": "Symbol Resolution",
"type": "boolean"
},
"temperature": {
"default": 0.0,
"title": "Temperature",
"type": "number"
},
"timeout": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Timeout"
},
"triage_model": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Triage Model"
},
"unanchored_min_severity": {
"$ref": "#/$defs/Severity",
"default": "high"
}
},
"required": [
"provider",
"model"
],
"title": "ReviewConfig",
"type": "object"
}
ReviewFinding¶
{
"$defs": {
"Severity": {
"description": "Finding severity, ordered low \u2192 high for `min_severity` filtering.",
"enum": [
"info",
"low",
"medium",
"high",
"critical"
],
"title": "Severity",
"type": "string"
}
},
"additionalProperties": false,
"description": "A single inline review comment the model wants to post.",
"properties": {
"anchor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Anchor"
},
"anchored": {
"default": true,
"title": "Anchored",
"type": "boolean"
},
"body": {
"title": "Body",
"type": "string"
},
"broad": {
"default": false,
"title": "Broad",
"type": "boolean"
},
"category": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Category"
},
"confidence": {
"anyOf": [
{
"maximum": 10,
"minimum": 0,
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Confidence"
},
"failure_scenario": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Failure Scenario"
},
"line": {
"minimum": 1,
"title": "Line",
"type": "integer"
},
"path": {
"title": "Path",
"type": "string"
},
"severity": {
"$ref": "#/$defs/Severity"
},
"side": {
"default": "RIGHT",
"enum": [
"LEFT",
"RIGHT"
],
"title": "Side",
"type": "string"
},
"suggestion": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Suggestion"
},
"title": {
"title": "Title",
"type": "string"
}
},
"required": [
"path",
"line",
"severity",
"title",
"body"
],
"title": "ReviewFinding",
"type": "object"
}
ProviderResult¶
{
"additionalProperties": false,
"description": "The normalised return of one LLM completion, with token usage.",
"properties": {
"attempts": {
"default": 1,
"minimum": 1,
"title": "Attempts",
"type": "integer"
},
"cache_creation_tokens": {
"default": 0,
"title": "Cache Creation Tokens",
"type": "integer"
},
"cache_read_tokens": {
"default": 0,
"title": "Cache Read Tokens",
"type": "integer"
},
"cost_usd": {
"anyOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"default": null,
"title": "Cost Usd"
},
"input_tokens": {
"title": "Input Tokens",
"type": "integer"
},
"model": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Model"
},
"output_ceiling": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Output Ceiling"
},
"output_tokens": {
"title": "Output Tokens",
"type": "integer"
},
"reasoning_tokens": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Reasoning Tokens"
},
"text": {
"title": "Text",
"type": "string"
}
},
"required": [
"text",
"input_tokens",
"output_tokens"
],
"title": "ProviderResult",
"type": "object"
}
PRContext¶
{
"additionalProperties": false,
"description": "Everything the engine needs about a PR \u2014 fetched via API, never checkout.",
"properties": {
"base_sha": {
"title": "Base Sha",
"type": "string"
},
"changed_files": {
"items": {
"type": "string"
},
"title": "Changed Files",
"type": "array"
},
"commit_messages": {
"items": {
"type": "string"
},
"title": "Commit Messages",
"type": "array"
},
"description": {
"default": "",
"title": "Description",
"type": "string"
},
"diff": {
"title": "Diff",
"type": "string"
},
"feedback_downvotes": {
"default": [],
"items": {
"type": "string"
},
"title": "Feedback Downvotes",
"type": "array",
"uniqueItems": true
},
"file_contents": {
"additionalProperties": {
"type": "string"
},
"title": "File Contents",
"type": "object"
},
"head_branch": {
"default": "",
"title": "Head Branch",
"type": "string"
},
"head_sha": {
"title": "Head Sha",
"type": "string"
},
"open_finding_threads": {
"default": 0,
"minimum": 0,
"title": "Open Finding Threads",
"type": "integer"
},
"pr_number": {
"title": "Pr Number",
"type": "integer"
},
"repo": {
"title": "Repo",
"type": "string"
},
"scan_contents": {
"additionalProperties": {
"type": "string"
},
"title": "Scan Contents",
"type": "object"
},
"title": {
"default": "",
"title": "Title",
"type": "string"
}
},
"required": [
"diff",
"changed_files",
"base_sha",
"head_sha",
"repo",
"pr_number"
],
"title": "PRContext",
"type": "object"
}