All projectsAI APPLICATION
Gemini Chatbot
Ask questions with text, images, or recorded speech.
The Problem
A text-only chat requires users to type a question and describe any visual information themselves. The chatbot lets users add an image or record speech within the same conversation.
The Approach
The React interface supports typed messages, image uploads, and audio recording. Recorded audio is transcribed through Google Cloud Speech-to-Text and then sent through the text conversation flow. Images use a separate upload-and-response path, and the conversation displays the resulting responses.
01Speech Feeds the Existing Chat Flow
The audio handler converts a recording into a transcript and passes that text to the same send-message function used for typed input. This lets users speak their questions while reusing the existing text-chat flow.
02A Separate Image Upload Path
An image upload is sent to the backend, and the returned image and result are inserted into the conversation. This supports visual questions alongside ordinary text messages.
03One Conversation Interface
React manages message history and input controls while asynchronous request handlers update the conversation. This keeps different input types within one interaction pattern.
Implemented Scope
I built text, image, and recorded-speech input into one React chat interface and added speech-synthesis code. The app connects Gemini with Google Cloud Speech-to-Text so users can ask questions in the format that suits them.
Back to projects