Validator for LangChain content-block protocol event streams.
Checks that an event stream emitted by a chat model (via stream_v2,
or by the compat bridge's chunks_to_events / message_to_events)
conforms to the protocol lifecycle rules:
message-start opens and message-finish closes the stream.content-block-start → optional content-block-deltas →
content-block-finish before the next block begins.uint values
starting at 0.text, reasoning, tool_call_chunk,
server_tool_call_chunk), accumulated delta content matches the
final payload delivered on content-block-finish.The validator accepts any iterable of protocol event dicts. It raises
AssertionError on the first violation with a descriptive message.