Baseten
Baseten logoBaseten · Feature trail

AI Model Inference Communication Protocols

4 posts · Apr 2024 – Aug 2025

What this trail covers

Baseten's platform supports various communication protocols for AI model inference, including HTTP for broad compatibility and reliability, WebSockets for real-time bidirectional communication in interactive applications, and gRPC for high-performance, type-safe service-to-service communication. The choice of protocol impacts application architecture, performance, and complexity. This post details a specific implementation of real-time text-to-speech using WebSockets with the XTTS V2 model, demoing the trade-offs between HTTP, WebSockets, and gRPC for AI model inference.

All Baseten trails