-
Notifications
You must be signed in to change notification settings - Fork 481
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Telegram Bot and Coqui Improvments #144
Closed
Closed
Changes from 10 commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
3087515
Coqui: support prompt-to-voice & >250 char input
zaptrem 841cade
v0.1.110
zaptrem 574ffe0
add coqui telegram bot demo
zaptrem 1988b66
cleanliness
zaptrem 6f593a9
handle linter's incorrect understanding of sum
zaptrem 00705c4
add xtts, fix voice ids, fix /who, add poetry
zaptrem e770386
fix agent memory and character prompting
zaptrem 1754f54
make split_text easier to read
zaptrem 6bb4a1f
use poetry with telegram-bot
zaptrem 863ed2a
typing, formatting, persistence fixes for telegram
zaptrem 404a8c0
make xtts option more descriptive
zaptrem File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
OPENAI_API_KEY= | ||
TELEGRAM_BOT_KEY= | ||
COQUI_API_KEY= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
FROM python:3.11 | ||
|
||
# get portaudio and ffmpeg | ||
RUN apt-get update \ | ||
&& apt-get install libportaudio2 libportaudiocpp0 portaudio19-dev libasound-dev libsndfile1-dev -y | ||
RUN apt-get -y update | ||
RUN apt-get -y upgrade | ||
RUN apt-get install -y ffmpeg | ||
|
||
WORKDIR /code | ||
COPY ./pyproject.toml /code/pyproject.toml | ||
COPY ./poetry.lock /code/poetry.lock | ||
RUN pip install --no-cache-dir --upgrade poetry | ||
RUN poetry config virtualenvs.create false | ||
RUN poetry install --no-dev --no-interaction --no-ansi | ||
COPY main.py /code/main.py | ||
|
||
CMD ["python", "main.py"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# client_backend | ||
|
||
## Docker | ||
|
||
1. Set up the configuration for your telegram bot in `main.py`. | ||
2. Set up an .env file using the template | ||
3. Create a Telegram Bot token and link using The Bot Father: https://t.me/botfather | ||
|
||
``` | ||
cp .env.template .env | ||
``` | ||
|
||
Fill in your API keys into .env | ||
|
||
3. Build the Docker image | ||
|
||
```bash | ||
docker build -t vocode-telegram-bot . | ||
``` | ||
|
||
4. Run the image and forward the port. | ||
|
||
```bash | ||
docker run --env-file=.env -p 3000:3000 -t vocode-telegram-bot | ||
``` | ||
|
||
Now you have a telegram bot running. Visit the link you chose during the Telegram bot creation process | ||
. | ||
## Non-docker setup | ||
|
||
`main.py` is just a simple python script, so you can run it with: | ||
|
||
``` | ||
poetry install | ||
poetry run python main.py | ||
``` |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit, there are some references to client backend/vocode react sdk
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed