websocket-protocol

Documents WebSocket message formats for chat streaming between clients and servers.

2|1|Updated Sep 4, 2025
One-click install
npx skills add https://github.com/nickpeterson92/chat-juicer --skill websocket-protocol
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: websocket-protocol
Source: https://github.com/nickpeterson92/chat-juicer/tree/main/.claude/skills/websocket-protocol
Command: npx skills add https://github.com/nickpeterson92/chat-juicer --skill websocket-protocol

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill clarifies the message formats used for real-time chat streaming over WebSockets, ensuring seamless communication between clients and servers.

Core Features & Use Cases

  • Defines Client-to-Server Messages: Specifies formats for sending chat messages and interruption signals.
  • Defines Server-to-Client Messages: Outlines structures for streaming text, tool execution, and stream completion/interruption.
  • Use Case: Developers integrating a chat interface can use this Skill to understand exactly how to send user input and interpret AI responses, including tool calls and streaming updates.

Quick Start

Send a user message to the websocket endpoint to start a chat stream.

Frequently Asked Questions about websocket-protocol

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What WebSocket message formats are used for real-time chat streaming?

WebSocket real-time chat streaming uses client messages for chat input and interruptions, alongside server messages for stream start, text deltas, tool execution, and stream completion to enable live interactive updates.

How do I structure a WebSocket message to interrupt an AI chat stream?

To interrupt an AI chat stream over WebSockets, the client must send a specific interruption signal message defined by the protocol, which the server processes to halt the ongoing text generation and tool execution.

How does a server send streaming text deltas and tool execution updates over WebSockets?

A server sends streaming text deltas and tool execution updates over WebSockets by emitting structured server-to-client messages, starting the stream, pushing incremental text chunks, reporting tool calls, and signaling stream completion.

Can I use this WebSocket protocol definition for chat applications with live tool integration?

Yes, this WebSocket protocol definition supports chat applications with live tool integration by specifying server-to-client message structures that report tool execution events during the active text streaming process.

What is the difference between client-to-server and server-to-client WebSocket messages in chat streaming?

Client-to-server WebSocket messages handle chat input and interruption signals, while server-to-client messages manage stream start, text deltas, tool execution, and stream completion for interactive real-time responses.