Giter VIP home page Giter VIP logo

tts's Introduction

tts

Twitch chat text-to-speech overlay for OBS (using lobe-tts)

Setup

Install dependencies

npm ci

Build the overlay

npm run build

Use

Start the server:

npm start

Visit http://localhost:3000 to go through the full OAuth round trip and get your authorized URL for the browser source.

Create a reward in Twitch that requires a message. To determine the reward ID for adding to the query string of the overlay, redeem the reward yourself and enter !tts.echo as the (only) message text. The overlay, if connected and authorized, should respond with the internal ID of the reward. Add this ID as the reward query string parameter for the overlay in OBS.

The command may also be executed directly by the broadcaster and moderators.

Example Twitch message command:

!tts I'm a little teapot, short and stout

Advanced usage

The TTS trigger can be used without chat commands or reward redemptions by sending a direct HTTP POST request:

curl -X POST \
	-H 'Content-Type: application/json' \
	-d '{"text":"hello, world"}' \
	http://localhost:3000/cast

tts's People

Contributors

haliphax avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

tts's Issues

PipeWire

pactl load-module module-native-protocol-unix socket=/tmp/pulseaudio.socket
Failure: No such entity

I don't have /tmp/pulseaudio.socket, on my system with pipewire it is an empty folder

As per the instructions on https://docs.pipewire.org/page_module_protocol_native.html I modified /usr/share/pipewire/pipewire.conf to setup a unix socket which appears at /run/user/1000/pipewire-0

Tried setting default-server = unix:/run/user/1000/pipewire-0 in the dockerfile and re-build etc but I still get the below error:

tts-engine-1  | INFO:root:Speak: test (variant: m3 [random])
tts-engine-1  | Connection failure: Connection refused
tts-engine-1  | pa_context_connect() failed: Connection refused

I tried doing chmod 777 /run/user/1000 -R but still doesn't work, not sure what to do next

first speech synthesis execution is in random language

The first execution of speech synthesis does not respect the language settings. May need to push an inaudible test first before setting the language for use in the overlay.

Currently, you have to cause a TTS event then reload the overlay entirely and cause another for it to "stick".

static only

Should be able to set this up such that the reward redemption can use a static site, able to be centrally hosted on GitHub Pages. The advanced usage (broadcast endpoint) would still require hosting a server application yourself, as this is beyond the capability of Pages.

Build failed

peter@peter-pc:~/.local/src/tts$ sudo docker-compose build
nginx uses an image, skipping
Building engine
Sending build context to Docker daemon 245.8kB
Error response from daemon: dockerfile parse error line 7: unknown instruction: SET
ERROR: Service 'engine' failed to build : Build failed

OS: LMDE 6 (faye) x86_64
Kernel: 6.1.0-13-amd64

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.