You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As an API consumer, I need Node OpenAI-compatible forwarding to preserve streaming and response fields exactly, so Core governance does not break provider semantics.
Problem
Forwarding/SSE behavior is not tracked as a dedicated parity contract. Field loss, malformed SSE, tool-call corruption, usage loss, or inconsistent error mapping can make the governed edge unusable.
Current state
verdict-node contains forwarding and SSE handling, but no open issue covers end-to-end field-preservation parity.
Target state
Node preserves request/response fields, tool calls, usage, finish reasons, metadata, and SSE ordering while applying Core envelope checks before forwarding.
Design
Define canonical request/response/SSE fixtures for chat, tools, usage, errors, and streaming.
Treat SSE as an ordered event stream; preserve event type, data, IDs, terminal event, and disconnect semantics.
Validate envelope before opening the upstream stream.
Map transport/provider failures to stable typed errors without leaking credentials or upstream secrets.
Add abort, timeout, backpressure, and malformed-event behavior.
Repositories/files
verdict-node/src/middleware/forwarder.ts
verdict-node/src/middleware/**
verdict-node/tests/**
shared contract fixtures
Dependencies
verdict-node#NOD-002 (or its created GitHub issue)
verdict-core#220, #221
Acceptance criteria
Non-stream responses preserve all supported JSON fields byte/semantic-equivalently.
User story
As an API consumer, I need Node OpenAI-compatible forwarding to preserve streaming and response fields exactly, so Core governance does not break provider semantics.
Problem
Forwarding/SSE behavior is not tracked as a dedicated parity contract. Field loss, malformed SSE, tool-call corruption, usage loss, or inconsistent error mapping can make the governed edge unusable.
Current state
verdict-nodecontains forwarding and SSE handling, but no open issue covers end-to-end field-preservation parity.Target state
Node preserves request/response fields, tool calls, usage, finish reasons, metadata, and SSE ordering while applying Core envelope checks before forwarding.
Design
Repositories/files
verdict-node/src/middleware/forwarder.tsverdict-node/src/middleware/**verdict-node/tests/**Dependencies
verdict-node#NOD-002(or its created GitHub issue)verdict-core#220,#221Acceptance criteria
Testing
Run unit, fixture parity, property/fuzz tests for event ordering, and an upstream fake-server integration suite. Attach build/test evidence.
Security/NFR
No credential/header leakage. Bounded buffering. No unbounded reads. Preserve latency within an agreed regression threshold documented in CI.
Definition of done
Implementation, fixtures, tests, docs, and CI gate merged.