From 06da7022db4b4d6defa71d1dc1a93f938ba79cbf Mon Sep 17 00:00:00 2001 From: t11s Date: Mon, 10 Jun 2024 19:24:43 -0700 Subject: [PATCH] fix types again? --- src/components/App.tsx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/components/App.tsx b/src/components/App.tsx index 8b856c8..4407bd0 100644 --- a/src/components/App.tsx +++ b/src/components/App.tsx @@ -65,7 +65,7 @@ import { NavigationBar } from "./utils/NavigationBar"; import { CheckCircleIcon } from "@chakra-ui/icons"; import { Box, useDisclosure, Spinner, useToast } from "@chakra-ui/react"; import mixpanel from "mixpanel-browser"; -import { CreateCompletionResponseChoicesInner, OpenAI } from "openai-streams"; +import { ChatCompletionRequestMessageInner, OpenAI } from "openai-streams"; import { Resizable } from "re-resizable"; import { useEffect, useState, useCallback, useRef } from "react"; import { useBeforeunload } from "react-beforeunload"; @@ -392,8 +392,7 @@ function App() { "No choices in response. Decoded response: " + JSON.stringify(decoded) ); - const choice: CreateChatCompletionStreamResponseChoicesInner = - decoded.choices[0]; + const choice: ChatCompletionRequestMessageInner = decoded.choices[0]; if (choice.index === undefined) throw new Error(