941 B
941 B
AGENTS
Extending review logic
The review flow is:
- Generate diff and chunk it in src/ai_reviewer/diff.py.
- Build prompts in src/ai_reviewer/prompt.py.
- Send to the model in src/ai_reviewer/ollama.py.
- Render outputs in src/ai_reviewer/render.py.
Adding new checks
- Add new rules to the prompt template in src/ai_reviewer/prompt.py.
- Keep outputs JSON-only and evidence-based.
- For uncertain findings, set label to VERIFY.
Adding linter integration
- Capture linter output in a new module (for example src/ai_reviewer/lint.py).
- Merge linter findings into the existing Finding list in src/ai_reviewer/render.py.
- Ensure each linter-based finding includes file, location, and a snippet of the relevant diff when possible.
Prompt tuning
- Keep the JSON schema stable so parsing remains deterministic.
- Avoid adding non-deterministic instructions.
- If adding fields, update the parser in src/ai_reviewer/cli.py.