M
MercyNews
Home
Back
Browser-Based Voice Composer Converts Humming to Code
Technology

Browser-Based Voice Composer Converts Humming to Code

Hacker News2d ago
3 min read
📋

Key Facts

  • ✓ Uses TensorFlow.js for real-time pitch detection.
  • ✓ Outputs MIDI files and Strudel/TidalCycles code.
  • ✓ Runs entirely client-side using Web Audio API.
  • ✓ Utilizes four algorithms: CREPE, YIN, FFT/HPS, and AMDF.
  • ✓ Built to bridge the gap for users without music theory knowledge.

In This Article

  1. Quick Summary
  2. Core Functionality and Algorithms
  3. Technical Architecture
  4. Integration with Live Coding
  5. Availability and Future Development

Quick Summary#

A new browser-based application called Voice Composer has been released, designed to convert voice input into usable musical data. The tool targets live coding and live DJing communities by allowing users to hum melodies and instantly generate code for pattern-based music systems.

The application utilizes TensorFlow.js and other algorithms for real-time pitch detection. It runs entirely in the browser via the Web Audio API, ensuring that raw audio data never leaves the user's machine. The tool outputs MIDI files, visual piano rolls, and code compatible with Strudel and TidalCycles.

Core Functionality and Algorithms#

The Voice Composer addresses a specific problem for aspiring live coders: the difficulty of translating melodic ideas into code without extensive music theory knowledge. By capturing audio in real-time, the tool converts vocal input into algorithmic patterns immediately.

The application employs four distinct pitch detection methods to handle various audio inputs:

  • CREPE: A deep learning model via TensorFlow.js, noted for high accuracy but higher computational cost.
  • YIN: An autocorrelation-based fundamental frequency estimation method, fast and effective for clean monophonic input.
  • FFT with Harmonic Product Spectrum: Optimized for handling harmonic-rich sounds.
  • AMDF: Average Magnitude Difference Function, a lightweight option for quick processing.

Users can switch between these algorithms based on their specific use case and input quality.

Technical Architecture#

Built using React, the tool operates entirely within the browser. It leverages the Canvas API to provide real-time waveform rendering and visual feedback through a piano roll interface.

The decision to keep all processing client-side ensures privacy and low latency. The creator envisions the tool evolving into a full-featured Digital Audio Workbench (DAW) over time. Currently, it is optimized for desktop use, where it functions most effectively.

Integration with Live Coding#

The primary output targets the live coding environment. By generating Strudel/TidalCycles code, the tool allows immediate integration into existing performance setups. This removes the barrier of manually writing syntax for complex patterns.

The creator built the application over a weekend to solve their own challenge of learning live coding without a musical background. The resulting software makes it "trivial to capture melodic ideas and immediately use them in pattern-based music systems."

Availability and Future Development#

The tool is currently available for testing via a hosted link. The source code has been made available on a public repository, inviting community contributions and feedback.

Future updates aim to expand the application's capabilities, moving closer to the functionality of a standard DAW. This suggests potential support for multi-track recording, effects processing, and broader file format compatibility in subsequent releases.

Continue scrolling for more

AI Transforms Mathematical Research and Proofs
Technology

AI Transforms Mathematical Research and Proofs

Artificial intelligence is shifting from a promise to a reality in mathematics. Machine learning models are now generating original theorems, forcing a reevaluation of research and teaching methods.

Just now
4 min
163
Read Article
Royal Shakespeare Company Announces 'Hamnet' U.S. Tour Cast
Entertainment

Royal Shakespeare Company Announces 'Hamnet' U.S. Tour Cast

The Royal Shakespeare Company and Neal Street Productions have revealed the complete ensemble cast for the American debut of the 'Hamnet' stage play with Kemi-Bo Jacobs taking on the role of Agnes and Rory Alexander portraying William Shakespeare.

6h
3 min
13
Read Article
Slamdance Film Festival 2026 Lineup Announced
Entertainment

Slamdance Film Festival 2026 Lineup Announced

The 32nd Slamdance Film Festival has announced its complete 2026 lineup, featuring 141 films with 50 world premieres. The event runs in Los Angeles.

6h
4 min
14
Read Article
Avatar: Fire and Ash Leads VES Awards Nominations
Entertainment

Avatar: Fire and Ash Leads VES Awards Nominations

Avatar: Fire and Ash dominates the Visual Effects Society awards with 10 nominations. A three-way tie exists for top animation nominations.

6h
4 min
15
Read Article
Meta Confirms Reality Labs Layoffs, Shifts Focus to Wearables
Technology

Meta Confirms Reality Labs Layoffs, Shifts Focus to Wearables

Around 10 percent of Meta's Reality Labs division, which develops its XR products and services, will be laid off beginning on Tuesday.

6h
5 min
23
Read Article
RN Calls for Martine Vassal to Withdraw in Marseille
Politics

RN Calls for Martine Vassal to Withdraw in Marseille

Two months before the municipal elections, the National Rally candidate Franck Allisio calls on Martine Vassal to withdraw. The move follows favorable polls and a push to establish the RN as the true right-wing option in Marseille.

6h
4 min
15
Read Article
Honda reveals a new ‘H Mark’ that will debut on its upcoming EVs and hybrids
Automotive

Honda reveals a new ‘H Mark’ that will debut on its upcoming EVs and hybrids

Honda has a new idea to help its upcoming lineup of electric and hybrid vehicles stand out. The iconic H Mark will look a little different as part of Honda’s efforts to “create new EVs from zero.” Here’s what to expect. more…

6h
3 min
0
Read Article
Multiple Meta-Owned Game Studios Hit With Layoffs
Economics

Multiple Meta-Owned Game Studios Hit With Layoffs

Twisted Pixel and Sanzaru Games have been gutted according to laid off employees The post Multiple Meta-Owned Game Studios Hit With Layoffs appeared first on Kotaku.

6h
3 min
0
Read Article
34 days of uncertainty: Bereaved father writes about loss of IDF lookout soldier Roni Eshel
World_news

34 days of uncertainty: Bereaved father writes about loss of IDF lookout soldier Roni Eshel

Realizing he alone could obtain answers, first-time author Eyal Eshel hunted for clues of his child's fate, while taking the government to task for 'breaking a social contract' The post 34 days of uncertainty: Bereaved father writes about loss of IDF lookout soldier Roni Eshel appeared first on The Times of Israel.

6h
3 min
0
Read Article
Zama Launches Token Sale at $55M FDV via CoinList
Cryptocurrency

Zama Launches Token Sale at $55M FDV via CoinList

Zama is launching its highly anticipated token sale with a $55 million floor fully diluted valuation. The sale will be conducted through CoinList and the project's own auction application.

6h
5 min
0
Read Article
🎉

You're all caught up!

Check back later for more stories

Back to Home