Installation and Usage
Clone the repository and start the software stack using the recommended docker compose.
IMPORTANT: Make sure to also clone the ric-messages
git submodule located in src
folder.
Running
Docker Compose
- Install Docker and Docker Compose for your operating system
- Inside the repository run
docker compose up
- Specify the file parameter
-f
withcompose.cpu.yaml
if there is no Nvidia GPU present on your system. - This will first build or pull the required docker images and then download the model defined in the
.env
file and startllama-swap
and the text to speech ROS2 node that provides the/tts
service. - Do note that the ROS2 node makes use of
rmw_zenoh
for ROS2 communication.
- Specify the file parameter
- Send ROS2 messages to
/tts
service usinglanguage
(eitheren
orde
by default) andtext
to turn into speech. Thellama-swap
container will then load up the language specific model and turn the provided text into speech. Check thellama-swap.config.yaml
file in the root of the repository to configurellama-swap
as desired or add more languages. (Do note that this also requires adjusting the ROS2 node) - Stop the server either by aborting using CTRL-C or
docker compose stop
if started detached-d
.
Manual
Follow the relevant documentation on llama-swap
for how to compile and run the llama-server
with it and the ROS2 documentation on how to build packages and run nodes.
Make sure to install PyTorch and SNAC in your compile and runtime environment as they are not automatically installed by ROS2's dependency manager.
Note: The recommended way to build the ROS2 node as of writing is using colcon
.