Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

ovos-audio-plugin-browser

An OpenVoiceOS audio backend that plays music, internet radio and podcasts in a browser's <audio> element, over the messagebus.

It was made for Emkay, OpenVoiceOS in the browser (Pyodide), where it is the player behind ovos-audio's classic AudioService. There it takes the place of ovos-audio-plugin-mpv and vlc, which start a program on the device, which a browser cannot do.

How it works

ovos-audio's AudioService (the mycroft.audio.service.* API that OCP uses in legacy mode, and that skills reach through AudioServiceInterface) picks a backend for each URI and tells it to play, pause, seek and so on. This backend does not play anything itself: it hands each command to the page as a bus message, and the page answers with what its player did.

So it never touches a browser API, and the same backend works

  • in Emkay, where OVOS runs in a Web Worker and the page answers (web/media.js),
  • on a normal OVOS device, with a browser connected to its messagebus websocket as the speaker.

Playlists, repeat, ducking while OVOS speaks or listens (ovos.audio.output.started/ended, recognizer_loop:record_begin/end) and the OCP status messages are handled by AudioService and OPM's AudioBackend template, the same as for any other backend.

Install and configure

pip install ovos-audio-plugin-browser
{
  "Audio": {
    "default-backend": "browser",
    "backends": {
      "browser": {"type": "ovos_audio_browser", "active": true, "duck_factor": 0.3}
    }
  },
  "intents": {
    "ovos-ocp-pipeline-plugin": {"legacy": true}
  }
}
  • duck_factor: the music's volume while OVOS speaks or listens, 0..1.
  • Without a backends entry of this type, one called browser is made, so installing the plugin is enough; set default-backend to make it the first choice.
  • "legacy": true makes OCP play through AudioService (and this backend) instead of waiting for ovos-media.

The protocol

To the page, one track at a time:

message data
ovos.audio.browser.play uri, position_ms
ovos.audio.browser.pause
ovos.audio.browser.resume
ovos.audio.browser.stop
ovos.audio.browser.seek position_ms
ovos.audio.browser.volume ducked (bool), factor (0..1)

From the page, whenever something happens, and every few seconds while playing:

message data
ovos.audio.browser.state uri, state (playing, paused, ended, error), position_ms, length_ms (0 for a live stream), error (a plain reason)

On ended the backend goes on with the next track (or starts over with repeat) and at the end of the list AudioService reports mycroft.audio.queue_end. On error it reports the error to OCP the same way.

A page that answers should play the stream in an <audio> element, not through Web Audio: <audio> plays a stream from another site without that site's CORS permission, while a Web Audio graph turns such a stream silent.

Limits

  • https pages cannot play http:// streams. Browsers block this "mixed content". Many internet radio stations have an https address; those that do not fail with a clear reason, and OCP moves on to its next result.
  • Formats are whatever the browser plays: mp3, aac, ogg/opus, and HLS in Safari. YouTube and the like need a stream extractor in OCP, which needs a site's permission to read it from a browser.
  • The backend uses ovos-audio's classic audio service (mycroft.plugin.audioservice), which OPM marks as deprecated in favour of ovos-media. It is what OCP's legacy mode uses today; an ovos-media plugin can follow when Emkay moves.

License

Apache-2.0

Metadata

Release files for ovos-audio-plugin-browser 0.1.0a2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ovos-audio-plugin-browser 0.1.0a2
File Size Uploaded Provenance Actions
ovos_audio_plugin_browser-0.1.0a2.tar.gz 11.6 kB With provenance Details for ovos_audio_plugin_browser-0.1.0a2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for ovos-audio-plugin-browser 0.1.0a2
File Interpreter ABI Platform Actions
ovos_audio_plugin_browser-0.1.0a2-py3-none-any.whl Python 3 none any Details for ovos_audio_plugin_browser-0.1.0a2-py3-none-any.whl

Total release size: 22.6 kB

Release files / ovos_audio_plugin_browser-0.1.0a2.tar.gz

Download URL ovos_audio_plugin_browser-0.1.0a2.tar.gz
Size 11.6 kB
Tags Source
SHA-256 checksum
How to use checksums
04bebb4213221397bc6563c80d3bb59bbf210230147030b3ffcccafd71ad18ee
BLAKE2b-256 checksum
How to use checksums
45c29fd08b7c7eda263813ec76de3e187769d9058a2b04beb6c8b619b02c6d39
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 22, 2026.

Transparency log

Release files / ovos_audio_plugin_browser-0.1.0a2-py3-none-any.whl

Download URL ovos_audio_plugin_browser-0.1.0a2-py3-none-any.whl
Size 11.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
161643101f7ad4c7dfddeaedcb48e3d15e80334ce0e1d3191053e7ac49b31d8c
BLAKE2b-256 checksum
How to use checksums
1e67f948929ebf932796d7c805e3f8b125f0b7bb9b5fd43f003ebca1f82fbf4b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 22, 2026.

Transparency log

Security for ovos-audio-plugin-browser 0.1.0a2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for ovos_audio_plugin_browser-0.1.0a2.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 22, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page