Skip to main content
OpenCompress is fully compatible with the OpenAI SDK. Change base_url and api_key — everything else stays the same.

Python

TypeScript / Node.js

Streaming

Streaming works identically to the OpenAI API. Compression happens before the stream starts — there is no additional latency during token generation.

Switching between models

You can use any supported model by changing the model parameter. No other code changes needed.