Skip to content

SemanticAudioNotes

Go to the application

Overview

A Streamlit web application that records or uploads audio notes, transcribes them using OpenAI’s Whisper model, embeds the text with OpenAI embeddings, stores the notes in Qdrant for semantic search, and allows editing, downloading, and searching of notes.

Main functionalities

  • Record audio directly from the browser.
  • Upload existing MP3 files.
  • Transcribe audio to text via OpenAI Whisper.
  • Edit transcribed notes in a text area.
  • Save notes with embeddings into a Qdrant vector database.
  • Perform semantic search on stored notes using embeddings.
  • Download notes as MP3 or TXT files.

Technologies & skills

  • Python
  • Streamlit
  • audiorecorder (web recording)
  • OpenAI API (Whisper, Embeddings)
  • Qdrant vector database
  • dotenv for environment variables
  • hashlib md5 for audio change detection
  • st_paywall for authentication
  • Custom modules: my_package.tips, api_key_loader_zmiany

Project Report

  • Utilizes Streamlit session state to persist audio and text across interactions.
  • MD5 hashing detects changes in recorded audio to reset transcriptions.
  • Caches OpenAI and Qdrant clients for efficient reuse.
  • Ensures the Qdrant collection exists before inserting notes.
  • Supports both real-time recording and file upload workflows.

Sample photos

<figcaption>Ładowanie pliku</figcaption>
Ładowanie pliku
<figcaption>Transkrypcja</figcaption>
Transkrypcja

Application usage

  • Open the Streamlit app in a browser.
  • Navigate to the “Dodaj notatkę” tab to record a new audio note or to the “Wczytaj nagranie z pliku mp3” tab to upload an existing MP3.
  • Click Transkrybuj to convert the audio into text.
  • Edit the transcribed text if needed, then click Wyślij notatkę do twojej bazy wektorowej QDRANT to store it.
  • Use the “Wyszukaj notatkę w chmurze” tab to perform a semantic search by entering a query; relevant notes and similarity scores will appear.

Where to get API key and addresses?

  1. OpenAI API Key (openai_api_key):
  2. Visit the OpenAI API Keys page.
  3. Log in to your account or create a new one.
  4. Click "Create API key" and copy the key.

  5. QuDant keys and URL:

  6. QDRANT_URL: The address of your QuDant server, e.g., https://your-qdrant-instance.com.
  7. QDRANT_API_KEY: The QuDant API key (if required).
  8. More details can be found in the QuDant documentation.

Example configuration file:

OPENAI_API_KEY=your-openai-api-key
QDRANT_URL=https://your-qdrant-instance.com
QDRANT_API_KEY=your-qdrant-api-key
Replace your-openai-api-key, https://your-qdrant-instance.com and your-qdrant-api-key with your own values.

Go to the application