Skip to content

fix(frontend recording): fixing audio capture and lossy encoding#5

Open
Kamal-Eldin wants to merge 14 commits intoOddadmix:mainfrom
Kamal-Eldin:bugfix/FETH-46-fix-export-hf
Open

fix(frontend recording): fixing audio capture and lossy encoding#5
Kamal-Eldin wants to merge 14 commits intoOddadmix:mainfrom
Kamal-Eldin:bugfix/FETH-46-fix-export-hf

Conversation

@Kamal-Eldin
Copy link

Description

This change addresses issue #4. Resolves the current bug of naming blobs with wav extensions but leaving the MediaRecorder for the browser to manage the actual audio encoding of the incoming stream.

Changes

  • Removes the misnamed wav encoding statements.
  • Adds raw stream capture in PCM using audio contexts and buffers Recording.tsx
  • Adds Wav encoding utility to convert PCM data to wav frontend/src/utils.wavEncoder.ts

…roject devcontainer and uv env.

 - sets up the main app docker container.
 - adds the local mysql db container.
 - provides boilerplate shell scripts to run the db and the app containers.
 - sets up the env variables in ./backend/.env

FETH-44
…end code location.

 - adds on screen prints @ config.get_database_url to check db environment variables, set at backend.env
 - adds db_mount, temp and db files to .gitignore

FETH-44
…rvice to ensure the database setup before any usage.

FETH-44
…D_URL constant @frontend.Projects.tsx to use 8100 on localhost.

 - Create Project tested via curl from host system and within app container shell
 - Create Project tested from UI, creates the project despite a fail alert
 - No project opens after creation
 - Provides Makefile target create_project for fast curl executions
 - Adds frontend directory to compose watch targets

FETH-44
… vars to .env at the root for both compose.yaml, passing as args to Dockerfile and to the backend via dotenv.

 FETH-44
…etup instructions to adapt to docker compose and Make

FETH-44
…nd passes it to the front end components via Make target update_urls using sed utility.

 - The sed edit utility is run as a prerequisite to the deploy target.
 - The Make target includes .env.template to maintain .env as the source of configs.

Closes: FETH-44
…ing_rate to 16000 and decode to False on the Audio object in the export_to_huggingface method

 - binds the sound recordings volume to ./recordings

FETH-44
… token and data repo based on developer provided environment variables via config.AppConfig.

FETH-44
…ariables to docker secrets

 - Uses docker.io/mysql:9 image
 - Declares hf_token, aws_access_id and aws_access_secret as docker secrets
 - Deletes mysql db passwords, aws creds and HF tokens from .env file
 - Declares hf_token, aws_access_id and aws_access_secret _FILE env variables to read docker secrets in container

FETH-44
… to read hugging face token from docker secrets

 - changes the SettingsService object to default to AppConfig.get_hf_token if user setting is none.

 FETH-44
…onfigurations to use secret files for sensitive data

 - adds get_db_password method in DatabaseConfig to read password from file
 - adds get_aws_access_secret method in AppConfig to read AWS secret from file
 - exposes MYSQL_PASSWORD secret to curatpor-app and declares MYSQL_PASSWORD_FILE to establish DB connection from app
 - adds devcontainer.json for consistent development environment
 - updates README.md to reflect changes in configuration and setup instructions

Closes: FETH-44
…e support for decoding webm audio files.

 - installs audio deps for huggingface datasets

FETH-46
…d encoding to capture raw PCM audio and encodes to wav format at 48000 sampling rate and sample size 16-bit

 - implements the wavEncoder utility to encode raw PCM to wav

Closes: FETH-46
@Oddadmix
Copy link
Owner

Oddadmix commented Feb 3, 2026

Thanks for the PR, I just saw them now, sorry about that.

Looks like there are 208 file changes, please review and only update the files intended and remove any unneeded file changes.

@Kamal-Eldin
Copy link
Author

Hello @Oddadmix,
As requested, changes are isolated in a separate PR #11.
Kindly take a look first before closing PR #5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants