[go: up one dir, main page]

feat: Always show FP confidence score when available

What does this merge request do and why?

This MR updates the vulnerability details page to always display the FP confidence score when available, regardless of whether it meets the threshold for showing the full FP detection details.

Problem

Previously, the FP confidence score would only display if it was above the minimal threshold (0.6). This meant users couldn't see that FP detection had run on a vulnerability if the score was below the threshold.

Solution

Update the template in vulnerability_details.vue to add an else-if condition that displays just the confidence score when:

  • The feature flag aiExperimentSastFpDetection is enabled
  • A latestFlag with a confidence score exists
  • But the full FP detection details shouldn't be shown (e.g., score is below threshold)

Screenshot

Cypher-with-no-integrity--Gitlab-Org-Gitlab-Test--GitLab-12-13-2025_12_30_PM

Changes

File: ee/app/assets/javascripts/vulnerabilities/components/vulnerability_details.vue

Added an else-if template block that displays:

  • Only the confidence score and progress bar
  • No title ("AI detected false positive")
  • No description section
  • No "Remove False Positive Flag" button

Benefits

  • Users can see that FP detection has run on a vulnerability, even if the confidence score is low
  • Provides transparency into the AI analysis process
  • Helps users understand the detection has been performed and what score was assigned
  • Maintains the visual distinction between high and low confidence scores
  • Relates to MR !207477 (merged) (Implement displaying of false positive detection badges)
Edited by Nate Rosandich

Merge request reports

Loading