ViqusViqus
Navigate
Company
Blog
About Us
Contact
System Status
Enter Viqus Hub

LLM Library Redefines Interface with Message Streams and Structured Output

LLM API Streaming response Conversational turns Multi-modal output Agentic Engineering Python library
April 29, 2026
Source: Simon Willison
Viqus Verdict Logo Viqus Verdict Logo 6
API Maturity Upgrade (High Utility)
Media Hype 3/10
Real Impact 6/10

Article Summary

The alpha release of the LLM Python library (0.32a0) significantly overhauls how developers interact with large language models. Previously limited to simple text prompts and responses, the new version treats inputs as explicit sequences of `user`/`assistant` messages, mirroring industry standards like the OpenAI chat completions API. More critically, the updated architecture handles model outputs as streams of typed parts, allowing consumers to differentiate between text content, tool call requests, tool call arguments, and reasoning output within a single stream. This addresses the complexity of multi-modal and tool-using model outputs, providing a much more robust and developer-friendly abstraction layer for integrating diverse frontier AI capabilities.

Key Points

  • The library now accepts input as an explicit sequence of messages (`user`/`assistant` roles), solving compatibility issues with modern chat-based APIs.
  • Outputs are streamed as a sequence of typed parts, enabling developers to programmatically distinguish between text, tool calls, and tool results.
  • New methods like `response.reply()` simplify the continuous conversational flow by allowing direct replies to previous model outputs.

Why It Matters

This release is less of a breakthrough feature and more of a crucial API maturity update. By formalizing the handling of conversation history and complex, multi-part, streaming outputs, the library solidifies itself as a production-ready abstraction layer. For developers building complex AI agents or applications that integrate tool use, this standardization drastically reduces boilerplate code and potential failure points. It directly addresses the 'messiness' of current frontier model APIs, which is a vital piece of infrastructure for the industry.

You might also be interested in