Skip to content

feat: exclude files from PR review by extension #249

Description

@nnhattruong30

Feature Request

Use Case

Some files in a PR are not meaningful for code review — e.g. package-lock.json, yarn.lock, *.min.js, *.lock, or generated files. Including them wastes context-window tokens, inflates cost, and can distract the model from real code changes.

Proposed Behavior

  • It can be configured with an exclude list in application.properties
  • A new workflow parameter (e.g. excludedFilePatterns) on the PR Review workflow configuration.
  • Accepts a comma-separated list of glob patterns or file extensions (e.g. *.lock, *.min.js, package-lock.json).
  • Before the diff is passed to the AI, any diff hunks whose file path matches an excluded pattern are stripped out.

Why It Is Valuable

  • Reduces token usage and cost.
  • Improves review quality by keeping the model focused on meaningful changes.
  • No code change required by end users — purely a configuration-time decision.

Current Behavior

The raw diff from getPullRequestDiff() is passed to the AI without any file filtering. There is no configuration hook to exclude files.

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions