Skip to main content

sonarwise

sonarwise

Pluggable audio perception engine. Hear. Search. Retrieve.

PyPI License Python Open In Colab


sonarwise indexes any audio like meetings, calls, podcasts, factory floors, lectures and makes it searchable by text, speaker, sound events, or audio similarity. Every component is pluggable: swap transcription, embedding, diarization, or storage without changing your code.

Features

  • Transcription : Whisper, Faster Whisper, or bring your own ASR
  • Audio Embeddings : CLAP joint text-audio space for semantic search
  • Speaker Diarization : know who said what (pyannote)
  • Speaker Registry : track speakers across files by voiceprint
  • Audio Event Detection : detect alarms, machinery, glass breaks, and 50+ sound types
  • Live Streaming : real-time transcription with keyword and event callbacks
  • Export : SRT, VTT, JSON, CSV, TXT, meeting notes
  • Pluggable Architecture : every component swappable via base classes
  • CLI : full command-line interface

Install

# Core (no ML dependencies)
pip install sonarwise

# With all features
pip install sonarwise[all]

# Pick what you need
pip install sonarwise[whisper]          # Whisper transcription
pip install sonarwise[faster-whisper]   # Faster Whisper (CTranslate2)
pip install sonarwise[clap]            # CLAP audio embeddings
pip install sonarwise[diarization]     # Speaker diarization
pip install sonarwise[speaker]         # Speaker identification
pip install sonarwise[events]          # Audio event detection
pip install sonarwise[live]            # Live microphone capture

Requires: ffmpeg (sudo apt install ffmpeg or brew install ffmpeg)

Quick Start

from sonarwise import SonarWise

sw = SonarWise(diarization=True, events=True)

# Index audio
sw.index("meeting.wav")
sw.index_folder("./recordings/")

# Search by text
results = sw.query("budget discussion", top_k=5)
for r in results:
    print(f"[{r.speaker_name}] {r.transcript} (score: {r.score})")

# Search by audio similarity
results = sw.query_audio("alarm_clip.wav", top_k=5)

# Search by speaker
results = sw.query("budget", speaker="Ant", top_k=5)

# Search by event
results = sw.query_events(event="machine_fault", top_k=5)

Speaker Intelligence

# Register a speaker
sw.register_speaker("Ant", reference_audio="ant_voice.wav")

# Query by speaker
results = sw.query("budget", speaker="Ant")

# Speaker timeline
timeline = sw.speaker_timeline("meeting.wav")

# Speaker stats
stats = sw.speaker_stats("meeting.wav")

# Find speaker across files
presence = sw.find_speaker_across(speaker="Ant", folders=["./meetings/"])

Live Mode

sw = SonarWise(mode="live", diarization=True, events=True)

@sw.on("transcript")
def on_speech(segment):
    print(f"[{segment.speaker_name}] {segment.transcript}")

@sw.on("keyword", words=["budget", "deadline", "risk"])
def on_keyword(segment):
    send_alert(segment.transcript)

@sw.on("sound_event", events=["alarm", "glass_break"])
def on_danger(event):
    trigger_alert(event)

sw.listen(source="microphone")

Plug Any Model

Every component is swappable:

from sonarwise import SonarWise
from sonarwise.core.transcriber import BaseTranscriber

class MyTranscriber(BaseTranscriber):
    def transcribe(self, audio):
        return my_model.process(audio)

sw = SonarWise(transcriber=MyTranscriber())

Pluggable slots:

Component Base Class Default
Transcriber BaseTranscriber Whisper
Audio Embedder BaseAudioEmbedder CLAP
Vector Store BaseVectorStore SQLite
Chunker BaseChunker Silero VAD
Diarizer BaseDiarizer pyannote
Speaker Embedder BaseSpeakerEmbedder ECAPA-TDNN
Event Classifier BaseEventClassifier PANNs
Stream Listener BaseStreamListener sounddevice

CLI

sonarwise index meeting.wav
sonarwise query "budget discussion"
sonarwise speakers meeting.wav
sonarwise timeline meeting.wav
sonarwise listen --source microphone --on-keyword "budget,risk"
sonarwise export meeting.wav --format srt
sonarwise stats

Export

sw.export("meeting.wav", format="srt", output="subtitles.srt")
sw.export("meeting.wav", format="json", output="segments.json")
sw.export("meeting.wav", format="txt", output="transcript.txt")
sw.export("meeting.wav", format="notes", output="meeting_notes.md")

Ecosystem

sonarwise is part of the VK-Ant AI perception ecosystem:

Library Purpose Tagline
SightRAG Visual perception See. Search. Retrieve.
sonarwise Audio perception Hear. Search. Retrieve.
adaptive-intelligence Reasoning & memory Learn. Remember. Adapt.
llmevalkit Evaluation Evaluate. Score. Improve.

License

Apache 2.0

Author

Built by Venkatkumar Rajan

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sonarwise-0.1.3.tar.gz (45.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sonarwise-0.1.3-py3-none-any.whl (43.2 kB view details)

Uploaded Python 3

File details

Details for the file sonarwise-0.1.3.tar.gz.

File metadata

  • Download URL: sonarwise-0.1.3.tar.gz
  • Upload date:
  • Size: 45.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for sonarwise-0.1.3.tar.gz
Algorithm Hash digest
SHA256 82e57d7cb4e4f5213bd62ca6f1ba9db0de2570c00d19c803383de1cc0ea04e22
MD5 f6dfed83fbe75770d78c7dd8d30e0876
BLAKE2b-256 88156fdaa4264e8259f7d093dfcb97bb1cc533056a5abc3ad62515a767222873

See more details on using hashes here.

File details

Details for the file sonarwise-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: sonarwise-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 43.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for sonarwise-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 475fcdd81b994ca9a5c718f59557bd16cbb2be858e6f5120f7b8d77fb11cbe11
MD5 63f5d95d5d3695611064fe5d8eef9d59
BLAKE2b-256 ac80e2ce16f43b47f46b8eaa7a9a77052a078f22ae8e30231dec3ddde81e3ec5

See more details on using hashes here.

Release history Release notifications | RSS feed

0.1.5

2 files

This release

0.1.3 This release

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page