IDinsight / ask-a-question

Trustworthy question-answering AI plugin for chatbots in the social sector with advanced content performance analysis.
https://ask-a-question.com
BSD 3-Clause "New" or "Revised" License
28 stars 4 forks source link

[128] - Internal TTS for AAQ #432

Closed MustafaAkolawala closed 3 weeks ago

MustafaAkolawala commented 2 months ago

Reviewer: @lickem22 Estimate: 30 mins


Ticket

Fixes: JIRA_TICKET_LINK

Description

This pull request integrates Piper Text-to-Speech (TTS) as an internal TTS model for AAQ, supporting both English and Swahili languages.

Goal

The primary aim of this PR is to incorporate an in-house, open-source TTS model alongside the existing external Google Cloud models. This addition enhances AAQ's speech synthesis capabilities and reduces dependency on third-party services.

Changes

Future Tasks (optional)

How has this been tested?

Docker compose Swagger UI pytests

How to test this?

  1. Ensure the CUSTOM_STT_ENDPOINT and CUSTOM_TTS_ENDPOINT environment variables are correctly set in your .core_backend.env file.
  2. Initialize the Docker containers using the command: docker compose -f docker-compose.yml -f docker-compose.dev.yml -f docker-compose.speech.yml -p aaq-stack watch.
  3. Utilize the /voice-search endpoint and inspect the generated URL for the TTS speech file to confirm proper functionality.

Checklist

Fill with x for completed.