From be81f82905ca6eae790d0f60f2e8349ce550ae1f Mon Sep 17 00:00:00 2001 From: Will Johnston Date: Sat, 6 Apr 2024 14:18:32 -0700 Subject: [PATCH] -OpenAI --- app/src/app/page.tsx | 14 ++++++-------- app/src/components/QuestionForm.tsx | 6 ++---- app/src/components/VideoForm.tsx | 6 ++---- services/video-search/src/router.ts | 12 ++---------- 4 files changed, 12 insertions(+), 26 deletions(-) diff --git a/app/src/app/page.tsx b/app/src/app/page.tsx index 6c16de2..15387ab 100644 --- a/app/src/app/page.tsx +++ b/app/src/app/page.tsx @@ -25,7 +25,7 @@ export default function Home() { const [showModal, setShowModal] = useState(false); const [currentQuestion, setCurrentQuestion] = useState(''); const [isSettingsOpen, setIsSettingsOpen] = useState(false); - const [selectedOption, setSelectedOption] = useState('OpenAI'); + const [selectedOption, setSelectedOption] = useState('Google'); const handleSubmit = async (videos: string[]) => { // API call with the videos URLs @@ -77,13 +77,13 @@ export default function Home() {

- Ask me about Redis + Video Q&A with Redis: Ask anything about Redis

{Array.isArray(results) && !haveResults && !isSearching && (

No results found. Try another question.

)} - {!haveOriginal && ( + {!haveOriginal && haveResults && ( <>

Your question has already been asked in a different way, here @@ -102,11 +102,9 @@ export default function Home() { void handleSearch(currentQuestion, false); }}> - {isSearching -? ( + {isSearching ? ( - ) -: ( + ) : ( Generate unique response )} @@ -141,7 +139,7 @@ export default function Home() { - + {/* */} { setShowModal(true); diff --git a/app/src/components/QuestionForm.tsx b/app/src/components/QuestionForm.tsx index d39b2c9..06066eb 100644 --- a/app/src/components/QuestionForm.tsx +++ b/app/src/components/QuestionForm.tsx @@ -27,11 +27,9 @@ export default function QuestionForm({ onSubmit }: QuestionFormProps) {