feat(CountBasedMetadata): add notes to example signal panels - #247
Open
saiflayouni wants to merge 2 commits into
Open
feat(CountBasedMetadata): add notes to example signal panels#247saiflayouni wants to merge 2 commits into
saiflayouni wants to merge 2 commits into
Conversation
Add a `note` field to `CountConfig` and render it in both the donut and progress-bar branches, replacing the previous hardcoded string for `response_coverage`. For `example_density` and `example_validity`, the notes explain why the diagnostic path count can differ from the summary metric total: the engine emits one diagnostic path per unique location, while the metadata counts individual example objects — so a location with multiple examples appears once in diagnostics but is counted multiple times in the total. Refs jentic#235 Signed-off-by: saiflayouni <saiflayouni77@gmail.com>
The previous note implied expected_examples and present_examples overlap, which is wrong: expected_examples is the superset (all elements that *can* hold an example); present_examples is the subset that *do*. Reword to reflect the element-vs-subset relationship confirmed in issue jentic#235. Refs jentic#235 Signed-off-by: saiflayouni <saiflayouni77@gmail.com>
Contributor
Author
|
Thanks for the detailed explanation in #235, @char0n! The The I saw #245 is open for the broader tooltip/help-text work — happy to help there too once #42 lands definitions. |
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.
Summary
Closes #235
The HTML report shows
present_examplesandtotal_examplesdiagnostics pointing to the same locations, and thetotal_examplesmetadata count (e.g. 37) differs from the number of paths shown in the diagnostics (e.g. 27). This is correct engine behavior — diagnostics mark unique locations, while the metadata counts individual example objects — but was opaque to users.notefield toCountConfiginCountBasedMetadata.tsxresponse_coverage) and the progress-bar branch (all other count signals), replacing the previous hardcoded stringexample_density: explains thatexpected_examplesandpresent_examplesdiagnostics list overlapping location sets (they converge when all expected locations already have examples)example_validity: explains that the total-examples count in the summary can exceed the diagnostic location count when a single location holds multiple examplesTest plan
@jentic/api-scorecard-formatter-htmlunit tests pass (npm test -w @jentic/api-scorecard-formatter-html)signals.test.tsxSSR tests forexample_densityandexample_validitystill pass (noundefined/NaN, expected numerator/denominator values)response_coveragenote text is unchanged (moved from hardcoded JSX toCOUNT_SIGNAL_CONFIG)