Streaming examples for OpenAI-compatible chat completions with OriginStartAI.
Use this repo when your app needs visible token-by-token progress, lower perceived latency, or a better chat typing experience.
- Create an account: https://originstartai.com?utm_source=github&utm_medium=repo&utm_campaign=github_secondary_repos&utm_content=ai-api-streaming-examples
- Get an API key from the console.
- Copy
.env.exampleto.env. - Set
ORIGINSTARTAI_API_KEY,ORIGINSTARTAI_BASE_URL, andORIGINSTARTAI_MODEL. - Run one of the streaming examples.
New user offer: recharge $5 and get $5 extra API credits.
bash examples/curl/streaming.shpip install openai python-dotenv
python examples/python/streaming.pynpm install
npm run stream