Skip to content

[FE Enhancement] Opening evaluator spans in playground#4217

Merged
bekossy merged 28 commits intorelease/v0.96.10from
improve/evaluator-span-in-playground
Apr 28, 2026
Merged

[FE Enhancement] Opening evaluator spans in playground#4217
bekossy merged 28 commits intorelease/v0.96.10from
improve/evaluator-span-in-playground

Conversation

@ardaerzin
Copy link
Copy Markdown
Contributor

Summary

tba...

Testing

Verified locally

QA follow-up

Demo

Checklist

  • I have included a video or screen recording for UI changes, or marked Demo as N/A
  • Relevant tests pass locally
  • Relevant linting and formatting pass locally
  • I have signed the CLA, or I will sign it when the bot prompts me

Contributor Resources

…p issues

- Parse JSON-encoded envelope fields (`outputs`) when opening evaluator from trace
- Change evaluator `outputs` port type from `object` to `string` to allow auto-detection of JSON vs plain text in editor
- Skip initial empty row when opening evaluator revision, write envelope-shaped row directly
- Intercept paste and Cmd+A+Delete events to prevent editor flash when switching between JSON/text modes
- Add focus-on-mount
@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 22, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
agenta-documentation Ready Ready Preview, Comment Apr 28, 2026 9:32am

Request Review

devin-ai-integration[bot]

This comment was marked as resolved.

@ardaerzin ardaerzin marked this pull request as ready for review April 27, 2026 11:43
@dosubot dosubot Bot added size:L This PR changes 100-499 lines, ignoring generated files. enhancement New feature or request Frontend labels Apr 27, 2026
@dosubot dosubot Bot added size:XL This PR changes 500-999 lines, ignoring generated files. and removed size:L This PR changes 100-499 lines, ignoring generated files. labels Apr 27, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 27, 2026

Railway Preview Environment

Status Destroyed (PR closed)

Updated at 2026-04-28T13:25:50.737Z

…d of navigating away

- Keep trace drawer open when opening spans in playground (no app reference)
- Use workflow revision drawer overlay for ephemeral playground sessions
- Navigate to app playground only for spans with app references (closes trace drawer)
- Force expanded mode for span replay to show full playground with execution panel
- Prevent closing programmatically-opened drawers on unrelated route changes
- Add expanded
…n has empty parameters

- Add `findDescendantParameters` helper to recursively search child spans for non-empty `ag.data.parameters`
- Use descendant parameters as fallback when active span has empty config
- Fixes playground showing empty state for workflow/task/agent/chain spans that wrap LLM calls
- Handles JSON-encoded parameter strings during tree walk
- Update comments to clarify span replay behavior and drawer context usage
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

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

Devin Review found 2 new potential issues.

View 7 additional findings in Devin Review.

Open in Devin Review

@dosubot dosubot Bot added size:XXL This PR changes 1000+ lines, ignoring generated files. and removed size:XL This PR changes 500-999 lines, ignoring generated files. labels Apr 28, 2026
…luator span app context

- Skip paste-triggered JSON mode detection for object/array schema fields (already pinned to JSON)
- Preserves cursor position and existing JSON content when pasting into schema-typed fields
- Set `appId: undefined` for evaluator spans in `openFromTraceAtom` to force workflow drawer
- Aligns evaluator span handling with evaluator-revision branch behavior
- Add comments clarifying schema-typed paste behavior and
Copy link
Copy Markdown
Member

@mmabrouk mmabrouk left a comment

Choose a reason for hiding this comment

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

Thanks @ardaerzin !

We should test this with all evaluators types to make sure it is correct. We should especially test with LLM-as-a-judge with a custom output.

@dosubot dosubot Bot added the lgtm This PR has been approved by a maintainer label Apr 28, 2026
@ardaerzin
Copy link
Copy Markdown
Contributor Author

ardaerzin commented Apr 28, 2026

Thanks @ardaerzin !

We should test this with all evaluators types to make sure it is correct. We should especially test with LLM-as-a-judge with a custom output.

I've tested this locally using a variety, from exact match to llm as judge.

But @bekossy, please make sure that the qa scope includes this

…ring character-by-character edits

- Implement sticky JSON mode detection that persists during single-character edits
- Prevent Lexical editor remount when transiently breaking JSON shape (e.g., deleting closing `}`)
- Re-detect JSON mode on bulk replacements (paste, Cmd+A+Delete) when length delta exceeds 1
- Track previous value and detection state with refs to enable sticky behavior
- Maintain immediate detection on first render to
@bekossy bekossy assigned bekossy and unassigned bekossy Apr 28, 2026
@bekossy bekossy merged commit 3404645 into release/v0.96.10 Apr 28, 2026
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request Frontend lgtm This PR has been approved by a maintainer size:XXL This PR changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants