From b83054ea47624240e63b14de02354e36318dff33 Mon Sep 17 00:00:00 2001 From: billytrend-cohere <144115527+billytrend-cohere@users.noreply.github.com> Date: Fri, 3 Nov 2023 15:41:52 +0000 Subject: [PATCH] Fix ReadMe --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 99fe700..418d380 100644 --- a/README.md +++ b/README.md @@ -59,8 +59,8 @@ const cohere = new CohereClient({ }); for await (const chat of stream) { - if (chat.type === "text-generation") { - console.log(chat.text); + if (chat.eventType === "text-generation") { + process.stdout.write(chat.text); } } })(); @@ -102,4 +102,4 @@ This SDK is in beta, and while we will try to avoid it, there may be breaking ch While we value open-source contributions to this SDK, the code is generated programmatically. Additions made directly would have to be moved over to our generation code, otherwise they would be overwritten upon the next generated release. Feel free to open a PR as a proof of concept, but know that we will not be able to merge it as-is. We suggest opening an issue first to discuss with us! -On the other hand, contributions to the README are always very welcome! \ No newline at end of file +On the other hand, contributions to the README are always very welcome!