docs: Document the finding risk score API contract - #3151
Draft
justin-prime1 wants to merge 2 commits into
Draft
Conversation
Contributor
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository YAML (base), Organization UI (inherited) Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Intent
Document the shared, lossless public contract for Enterprise finding-risk scores without adding BHCE runtime behavior.
Implementation
Adds optional decimal-string
risk_scorefields, numeric-sort support, a unified-findings CSVRiskScorecolumn, updated examples, and regenerated OpenAPI output. Decimal strings preserve arbitrary-precision integers for JavaScript consumers.Blast Radius / Risk
This changes shared OpenAPI source/generated documentation only. Generated clients may expose a new optional field and CSV consumers observe an appended column; existing fields remain unchanged. BHCE adds no database, analysis, API implementation, or UI behavior.
BHE/BHCE Parity
matched: BHCE owns the shared contract; BHE owns calculation, persistence, projections, numeric sorting, CSV generation, and UI. Runtime calculation remains intentionally Enterprise-only.Reviewability
Review size: 50 reviewable OpenAPI lines. Excluded mechanical/generated material: 27 generated
openapi.jsonlines.Test Changes
No BHCE runtime tests were added because this is contract-only. OpenAPI generation and full repository preparation validate source/generated consistency; runtime behavior is tested in the sister BHE PR. No tests were removed.
Rollback
Revert this PR and regenerate OpenAPI. Existing servers and persisted data are unaffected; regenerate any external clients produced from this prototype contract.
Motivation and Context
The BHE sister persists arbitrary-precision scores; the shared JSON, sort, and CSV contract must describe them without precision loss. No Jira or GitHub issue is associated with this prototype, by author request.
Resolves N/A — prototype authorized without a ticket.
How Has This Been Tested?
Validation / Evidence
At BHCE
5ef3b1750c0bbc08ed8e71e03ca22be217113ca3and BHEef9c5103a740a8d515229ec3c7b421c993bdc934:just prepare-for-codereviewpassed.Explicitly Not Validated
Screenshots (optional):
Runtime evidence from the paired BHE PR:
Types of changes
Checklist: