Skip to content

Commit

Permalink
1.4.0 (#152)
Browse files Browse the repository at this point in the history
  • Loading branch information
NeonDaniel authored Oct 27, 2023
2 parents 5bd1b1b + d9798e4 commit a28797e
Show file tree
Hide file tree
Showing 16 changed files with 431 additions and 214 deletions.
163 changes: 148 additions & 15 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,39 +1,172 @@
# Changelog

## [1.3.2a5](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.2a5) (2023-04-20)
## [1.3.3a21](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a21) (2023-10-27)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.2a4...1.3.2a5)
[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a20...1.3.3a21)

**Merged pull requests:**

- Remove extra pull\_master automation [\#126](https://github.com/NeonGeckoCom/neon_audio/pull/126) ([NeonDaniel](https://github.com/NeonDaniel))
- Handle playback thread init bug affecting Docker instances [\#151](https://github.com/NeonGeckoCom/neon_audio/pull/151) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.2a4](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.2a4) (2023-04-20)
## [1.3.3a20](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a20) (2023-10-27)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.2a3...1.3.2a4)
[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a19...1.3.3a20)

**Merged pull requests:**

- Add missing release action [\#124](https://github.com/NeonGeckoCom/neon_audio/pull/124) ([NeonDaniel](https://github.com/NeonDaniel))
- Downgrade OCP for ovos-core/NeonCore compat. [\#150](https://github.com/NeonGeckoCom/neon_audio/pull/150) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.2a3](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.2a3) (2023-04-20)
## [1.3.3a19](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a19) (2023-10-27)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.2a2...1.3.2a3)
[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a18...1.3.3a19)

**Merged pull requests:**

- Update OCP plugin to stable version [\#123](https://github.com/NeonGeckoCom/neon_audio/pull/123) ([NeonDaniel](https://github.com/NeonDaniel))
- Update OCP to latest alpha to resolve dependency error [\#149](https://github.com/NeonGeckoCom/neon_audio/pull/149) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.2a2](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.2a2) (2023-04-19)
## [1.3.3a18](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a18) (2023-10-27)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.1...1.3.2a2)
[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a17...1.3.3a18)

**Merged pull requests:**

- Fix alpha release automation change [\#122](https://github.com/NeonGeckoCom/neon_audio/pull/122) ([NeonDaniel](https://github.com/NeonDaniel))
- Add prerelease automation and update dependencies [\#121](https://github.com/NeonGeckoCom/neon_audio/pull/121) ([NeonDaniel](https://github.com/NeonDaniel))
- Update dependencies and remove patches [\#120](https://github.com/NeonGeckoCom/neon_audio/pull/120) ([NeonDaniel](https://github.com/NeonDaniel))
- Update OCP dependency [\#118](https://github.com/NeonGeckoCom/neon_audio/pull/118) ([NeonDaniel](https://github.com/NeonDaniel))
- Fix typo in thread state check [\#148](https://github.com/NeonGeckoCom/neon_audio/pull/148) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a17](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a17) (2023-10-26)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a16...1.3.3a17)

**Merged pull requests:**

- Update dependencies to prep for stable release [\#147](https://github.com/NeonGeckoCom/neon_audio/pull/147) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a16](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a16) (2023-10-26)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a15...1.3.3a16)

**Merged pull requests:**

- Update dependencies to test for stable releases [\#146](https://github.com/NeonGeckoCom/neon_audio/pull/146) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a15](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a15) (2023-10-13)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a14...1.3.3a15)

**Merged pull requests:**

- Update dependencies for module compat. [\#145](https://github.com/NeonGeckoCom/neon_audio/pull/145) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a14](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a14) (2023-10-11)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a13...1.3.3a14)

**Merged pull requests:**

- ovos-audio compatibility updates [\#144](https://github.com/NeonGeckoCom/neon_audio/pull/144) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a13](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a13) (2023-10-10)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a12...1.3.3a13)

**Merged pull requests:**

- Update timing context for non-Neon skills [\#143](https://github.com/NeonGeckoCom/neon_audio/pull/143) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a12](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a12) (2023-10-10)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a11...1.3.3a12)

**Merged pull requests:**

- Pin upper limit to ovos-plugin-manager to work around breaking change [\#142](https://github.com/NeonGeckoCom/neon_audio/pull/142) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a11](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a11) (2023-10-04)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a10...1.3.3a11)

**Merged pull requests:**

- Timing metrics and ovos-audio compat [\#141](https://github.com/NeonGeckoCom/neon_audio/pull/141) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a10](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a10) (2023-08-16)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a9...1.3.3a10)

**Merged pull requests:**

- Improved language support and plugin compatibility [\#139](https://github.com/NeonGeckoCom/neon_audio/pull/139) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a9](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a9) (2023-07-26)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a8...1.3.3a9)

**Merged pull requests:**

- Update Dockerfile for Kubernetes [\#137](https://github.com/NeonGeckoCom/neon_audio/pull/137) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a8](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a8) (2023-07-18)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a7...1.3.3a8)

**Merged pull requests:**

- Mark old CLI entrypoint as deprecated [\#136](https://github.com/NeonGeckoCom/neon_audio/pull/136) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a7](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a7) (2023-07-12)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a6...1.3.3a7)

**Merged pull requests:**

- Pin ovos-audio dependency to resolve ident handling issue [\#135](https://github.com/NeonGeckoCom/neon_audio/pull/135) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a6](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a6) (2023-06-27)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a5...1.3.3a6)

**Merged pull requests:**

- Update Docker to use OVOS\_CONFIG envvars [\#134](https://github.com/NeonGeckoCom/neon_audio/pull/134) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a5](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a5) (2023-06-03)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a4...1.3.3a5)

**Merged pull requests:**

- Implement tests for CLI module [\#133](https://github.com/NeonGeckoCom/neon_audio/pull/133) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a4](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a4) (2023-05-25)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a3...1.3.3a4)

**Merged pull requests:**

- Fix missed refactoring in CLI entrypoints [\#132](https://github.com/NeonGeckoCom/neon_audio/pull/132) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a3](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a3) (2023-05-18)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a2...1.3.3a3)

**Merged pull requests:**

- Optimize module init [\#131](https://github.com/NeonGeckoCom/neon_audio/pull/131) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a2](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a2) (2023-05-17)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.3a1...1.3.3a2)

**Merged pull requests:**

- Add malloc debugging support [\#130](https://github.com/NeonGeckoCom/neon_audio/pull/130) ([NeonDaniel](https://github.com/NeonDaniel))

## [1.3.3a1](https://github.com/NeonGeckoCom/neon_audio/tree/1.3.3a1) (2023-05-17)

[Full Changelog](https://github.com/NeonGeckoCom/neon_audio/compare/1.3.2...1.3.3a1)

**Merged pull requests:**

- Refactor for ovos-audio compat. [\#129](https://github.com/NeonGeckoCom/neon_audio/pull/129) ([NeonDaniel](https://github.com/NeonDaniel))



Expand Down
8 changes: 5 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ FROM python:3.8-slim as base
LABEL vendor=neon.ai \
ai.neon.name="neon-audio"

ENV NEON_CONFIG_PATH /config
ENV OVOS_CONFIG_BASE_FOLDER neon
ENV OVOS_CONFIG_FILENAME neon.yaml
ENV XDG_CONFIG_HOME /config

RUN apt-get update && \
apt-get install -y \
Expand All @@ -16,8 +18,8 @@ RUN curl https://forslund.github.io/mycroft-desktop-repo/mycroft-desktop.gpg.ke
echo "deb http://forslund.github.io/mycroft-desktop-repo bionic main" \
> /etc/apt/sources.list.d/mycroft-mimic.list

RUN apt-get update && \
apt-get install -y \
RUN apt update && \
apt install -y \
alsa-utils \
libasound2-plugins \
pulseaudio-utils \
Expand Down
12 changes: 0 additions & 12 deletions docker_overlay/etc/OpenVoiceOS/ovos.conf

This file was deleted.

5 changes: 5 additions & 0 deletions docker_overlay/etc/neon/neon.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ play_ogg_cmdline: "play %1"
tts:
module: coqui
fallback_module: ovos-tts-plugin-mimic
g2p:
module: dummy
Audio:
backends:
OCP:
Expand All @@ -27,3 +29,6 @@ MQ:
signal:
use_signal_files: false
max_wait_seconds: 300
language:
detection_module: libretranslate_detection_plug
translation_module: libretranslate_plug
32 changes: 23 additions & 9 deletions neon_audio/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,40 +27,54 @@
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

from neon_utils.messagebus_utils import get_messagebus
from neon_utils.configuration_utils import init_config_dir
from neon_utils.log_utils import init_log
from neon_utils.process_utils import start_malloc, snapshot_malloc, print_malloc
from neon_utils.signal_utils import init_signal_bus, \
init_signal_handlers, check_for_signal
from ovos_utils import wait_for_exit_signal
from ovos_utils.log import LOG
from ovos_config.locale import setup_locale
from ovos_utils.process_utils import reset_sigint_handler, PIDLock as Lock

from mycroft.lock import Lock
from neon_audio.service import NeonPlaybackService


def main(*args, **kwargs):
if kwargs.get("config"):
LOG.warning("Found `config` kwarg, but expect `audio_config`")
kwargs["audio_config"] = kwargs.pop("config")

init_config_dir()
if kwargs.get("audio_config"):
LOG.warning("Passed configuration should be written to disk before"
"module launch")
init_log(log_name="audio")
malloc_running = start_malloc(stack_depth=4)
bus = get_messagebus()
kwargs["bus"] = bus
from neon_utils.signal_utils import init_signal_bus, \
init_signal_handlers, check_for_signal

init_signal_bus(bus)
init_signal_handlers()

from neon_audio.service import NeonPlaybackService
from mycroft.util import reset_sigint_handler, wait_for_exit_signal

reset_sigint_handler()
check_for_signal("isSpeaking")
Lock("audio")
setup_locale()
service = NeonPlaybackService(*args, **kwargs)
service.start()
wait_for_exit_signal()
if malloc_running:
try:
print_malloc(snapshot_malloc())
except Exception as e:
LOG.error(e)
service.shutdown()


def deprecated_entrypoint():
from ovos_utils.log import log_deprecation
log_deprecation("Use `neon-audio run` in place of "
"`neon_audio_client`", "2.0.0")
main()


if __name__ == '__main__':
main()
29 changes: 15 additions & 14 deletions neon_audio/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,43 +30,44 @@

from click_default_group import DefaultGroup
from neon_utils.packaging_utils import get_package_version_spec

from neon_utils.configuration_utils import init_config_dir
from ovos_config.config import Configuration


@click.group("neon-audio", cls=DefaultGroup,
no_args_is_help=True, invoke_without_command=True,
help="Neon Core Commands\n\n"
help="Neon Audio Commands\n\n"
"See also: neon COMMAND --help")
@click.option("--version", "-v", is_flag=True, required=False,
help="Print the current version")
def neon_audio_cli(version: bool = False):
if version:
click.echo(f"neon_speech version "
f"{get_package_version_spec('neon_speech')}")
click.echo(f"neon_audio version "
f"{get_package_version_spec('neon_audio')}")


@neon_audio_cli.command(help="Start Neon Audio module")
@click.option("--module", "-m", default=None,
help="STT Plugin to configure")
help="TTS Plugin to configure")
@click.option("--package", "-p", default=None,
help="TTS package spec to install")
@click.option("--force-install", "-f", default=False, is_flag=True,
help="Force pip installation of configured module")
def run(module, package, force_install):
init_config_dir()
from neon_audio.__main__ import main
audio_config = Configuration()
if force_install or module or package:
install_plugin(module, package, force_install)
if module and module != audio_config["tts"]["module"]:
click.echo("Updating runtime config with module and package")
package = package or audio_config["tts"].get("package_spec")
audio_config["tts"]["module"] = module
audio_config["tts"]["package_spec"] = package
click.echo(f'Loading TTS Module: {audio_config["tts"]["module"]}')
click.echo(f'TTS Config={audio_config["tts"]}')
if module:
audio_config = Configuration()
if module != audio_config["tts"]["module"]:
from neon_audio.utils import patch_config
click.echo("Updating config with module and package")
package = package or audio_config["tts"].get("package_spec")
patch_config({"tts": {"module": module,
"package_spec": package}})
click.echo("Starting Audio Client")
main(audio_config=audio_config)
main()
click.echo("Audio Client Shutdown")


Expand Down
Loading

0 comments on commit a28797e

Please sign in to comment.