Prompt LibraryEngineering
LLM Streaming Response Chunk Processor Prompt
Process a streaming response into structured deltas.
The prompt
Given the streaming chunk sequence below, reconstruct the full output and emit structured deltas:
- Text deltas as they arrive.
- When a tool-call JSON completes, emit it as a parsed object.
- Detect and flag a partial tool-call at the end of the stream.
Return the reconstructed text, the list of completed tool calls, and any partial call.
Chunks (in order):
{{chunks}}Replace the {{fields}} with your own context and tighten the rules to match your domain.
More Engineering prompts
LLM Structured Output Contract & Validator Prompt
Pair a strict output schema with the exact validation code to enforce it.
Streaming-Safe LLM Output Format Prompt
Structure output so it stays useful when streamed token by token.
Messy-to-Structured Output Normalizer Prompt
Turn inconsistent text into a clean JSON schema.




