EchoChamber is a web-based system that analyzes room acoustics using audio recordings and generates a unique "fingerprint" of the space. It focuses on capturing how sound behaves in real environments and storing that information in a structured, usable format.
The application records a short audio sample from a room and processes it to extract acoustic characteristics such as:
- Reverberation time (RT60) across frequencies
- Early reflections
- Phase coherence and randomness
- Group delay metrics
These features are combined into a fingerprint that represents the acoustic identity of a room.
The user records audio (typically a sweep signal). This recording is sent to the backend as a .wav file along with metadata like room name and capture duration.
The backend:
- Extracts the raw WAV buffer
- Parses the signal
- Applies DSP techniques like inverse sweep and reflection detection
From the processed signal, the system computes:
- RT60 values for multiple frequency bands
- Phase-related metrics
- Early reflections
A hash is generated to uniquely identify the fingerprint.
The data is stored using Prisma in a structured format:
| Entity | Description |
|---|---|
Space |
Represents the room |
Measurement |
Recording session |
Fingerprint |
Computed acoustic data |
Reflections |
Early reflection points |
All related records are created inside a transaction to maintain consistency.
The system uses cookie-based authentication with JWT:
token(httpOnly) — actual authenticationechochamber_session— session hint for UI
Protected routes like /analyze require a valid token.
- TypeScript
- Fetch API (with credentials)
- Browser Audio APIs
- Node.js
- Express
- Prisma ORM
- JWT Authentication
- Custom signal processing utilities
- WAV parsing
- Fingerprint generation
Create a .env file in the backend directory:
JWT_SECRET=your_secret_key
JWT_EXPIRES_IN=1h
DATABASE_URL=your_database_url
NODE_ENV=development# Install dependencies
npm install
# Start backend
npm run dev
# Start frontend
npm run dev- Login sets cookies:
tokenandechochamber_session - Requests include cookies via:
credentials: "include"- Backend reads and verifies the token from cookies
- Invalid or expired tokens are cleared automatically
- Audio processing can take time depending on file size
- Avoid aborting requests during processing — this can interrupt DB transactions
- JWT expiry should be set correctly (
"1h"instead of3600)
- Move processing to background jobs
- Add retry handling for failed captures
- Visualize acoustic fingerprints
- Compare fingerprints across rooms
Built to explore:
- Audio signal processing
- Backend architecture
- Real-world problem solving
Distributed under the MIT License.