From cc538171925cb22ce33cd01a760fd865a9187991 Mon Sep 17 00:00:00 2001 From: Stainless Bot Date: Tue, 28 Nov 2023 22:18:27 +0000 Subject: [PATCH] docs(readme): minor updates --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 96865aba78..83392e9585 100644 --- a/README.md +++ b/README.md @@ -94,7 +94,7 @@ stream = client.chat.completions.create( messages=[{"role": "user", "content": "Say this is a test"}], stream=True, ) -for part in stream: +for chunk in stream: if chunk.choices[0].delta.content is not None: print(part.choices[0].delta.content) ``` @@ -111,7 +111,7 @@ stream = await client.chat.completions.create( messages=[{"role": "user", "content": "Say this is a test"}], stream=True, ) -async for part in stream: +async for chunk in stream: if chunk.choices[0].delta.content is not None: print(part.choices[0].delta.content) ```