Skip to content

fix(ai-gateway): implement prompt test streaming and fix Compare panel#3650

Merged
gorkem-bwl merged 3 commits intodevelopfrom
fix/ai-gateway-prompt-test-streaming
Apr 1, 2026
Merged

fix(ai-gateway): implement prompt test streaming and fix Compare panel#3650
gorkem-bwl merged 3 commits intodevelopfrom
fix/ai-gateway-prompt-test-streaming

Conversation

@gorkem-bwl
Copy link
Copy Markdown
Contributor

Summary

  • Replace 501 stub in /prompts/test with real SSE streaming via resolve_endpoint_for_key + stream_chat_completion
  • Fix CORS: use relative URL for prompt test fetch
  • Add getOptionValue to Compare panel selects so version/endpoint dropdowns work

Reimplements key fixes from #3578 on a clean branch (that PR is 292 files behind develop).

Test plan

  • Open a prompt editor, select an endpoint, send a test message — should stream a response
  • Open Compare tab, select two versions and an endpoint, send a message — both columns should stream
  • Verify no CORS errors in browser console during prompt testing

## Changes
- Replace 501 stub in /prompts/test with real SSE streaming via
  resolve_endpoint_for_key + stream_chat_completion
- Fix CORS: use relative URL (/api/ai-gateway/prompts/test) instead of
  absolute GATEWAY_API_URL for the prompt test fetch
- Add getOptionValue to Compare panel version and endpoint Select dropdowns
  so they are actually selectable

## Context
Reimplements the key fixes from PR #3578 on a clean branch from develop,
avoiding the 292-file diff from the stale base branch.
@gorkem-bwl gorkem-bwl merged commit cbd93b1 into develop Apr 1, 2026
3 of 4 checks passed
@gorkem-bwl gorkem-bwl deleted the fix/ai-gateway-prompt-test-streaming branch April 1, 2026 16:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant