Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(annotations): show all annotations in annotation summary in project page header #4119

Merged
merged 3 commits into from
Aug 2, 2024

Conversation

Parker-Stafford
Copy link
Contributor

@Parker-Stafford Parker-Stafford commented Aug 2, 2024

  • migrates from spanEvaluationsSummary to spanAnnotationsSummary for project page header - shows all annotations (human and llm)
  • verified that project page header correctly refreshes when
    • there is a net new annotation label added
    • there is a new annotation added to a span using an existing label
    • an annotation is edited
    • an annotation with a label used elsewhere is deleted
    • an annotation with a label that is only used by it is deleted

note the page header refresh is currently broken due to a lack of cache busting on the server ticket #4120 - @anticorrelator to update - above was tested with no server side cache to verify refetch worked properly

Screen.Recording.2024-08-02.at.10.57.05.AM.mov

@dosubot dosubot bot added the size:XXL This PR changes 1000+ lines, ignoring generated files. label Aug 2, 2024
project: node(id: $projectId) {
... on Project {
...ProjectPageHeader_stats
...AnnotationSummaryValueFragment
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

refetch _stats to get a potentially net new annotation name (not using a pre-existing one) refetch ...ValueFragment to get updated information when a new annotation is created with a pre-existing name

) {
deleteSpanAnnotations(input: { annotationIds: [$annotationId] }) {
query {
node(id: $spanId) {
project: node(id: $projectId) {
...ProjectPageHeader_stats
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same as above but in reverse - refetch stats to potentially remove the only instance of an annotation using a particular name

refetch ValueFragment to update the stats associated with a particular annotation name

Comment on lines 18 to 19
const { projectId } = useParams();
const { timeRange } = useLastNTimeRange();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we can't assume this UI is nested under a project. this UI is also visible under experiments. I think we just let the auto-refresh take care of things.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

auto refresh as in the streaming? i can remove these spreads then, i wasn't seeing the annotations bar update though but i had streaming off

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed!

@dosubot dosubot bot added size:L This PR changes 100-499 lines, ignoring generated files. and removed size:XXL This PR changes 1000+ lines, ignoring generated files. labels Aug 2, 2024
@mikeldking mikeldking merged commit 5b7264e into main Aug 2, 2024
12 checks passed
@mikeldking mikeldking deleted the parker/annotation-summary-ui branch August 2, 2024 20:42
@Parker-Stafford Parker-Stafford restored the parker/annotation-summary-ui branch August 5, 2024 21:23
@Parker-Stafford Parker-Stafford deleted the parker/annotation-summary-ui branch October 8, 2024 22:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size:L This PR changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants