https://github.com/ericzon/my-echo-bot
https://github.com/ericzon/my-echo-bot
Last synced: 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/ericzon/my-echo-bot
- Owner: ericzon
- Created: 2025-01-13T17:09:03.000Z (about 1 year ago)
- Default Branch: master
- Last Pushed: 2025-02-03T08:58:27.000Z (about 1 year ago)
- Last Synced: 2025-02-03T09:38:00.909Z (about 1 year ago)
- Language: Python
- Size: 306 KB
- Stars: 0
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Echo-bot
========
My aim with this project is just to give a simple base to help tackling the real problem. It's based in the example from Microsoft bot framework.
## Setup
In this case I'm using python 3.12.3. I suggest to use poetry or similar but is up to you. Main dependencies are reflected in pyproject.toml.
Once you've installed all the dependencies, you can start the application with:
```
poetry run python .\main.py
```
## Env variables
```
PORT=3000
# Bot: Fill these values from Azure Bot settings
BOT_ID=
BOT_PASSWORD=
BOT_SECRET=
# Fill these values from Azure Speech service settings
SPEECH_SVC_KEY=
SPEECH_REGION=
SPEECH_ENDPOINT=
```
## Public folder
Once you have started the application, it will expose the chatbot client in http://localhost:/ or http://localhost:/index_speech.html
It includes 2 versions of client, the basic one and another version using Azure Speech for STT (Speech to text).
## Export .ENV to Azure WebAPP
### Generate the current settings.json
az webapp config appsettings list --name acc-poc-web-app-svc-test-01 --resource-group z-ago-airesearchsb01-ew-01 > settings.json
### Run the script
/bin/bash export_settings_json.sh
### Set the new environment variables to WebAPP
From local, run this command:
```
az webapp config appsettings set --name acc-poc-web-app-svc-test-01 --resource-group z-ago-airesearchsb01-ew-01 --settings @settings.json
```
## Deploy
From local, run this command:
```
az webapp up --sku B1 --logs --resource-group z-ago-airesearchsb01-ew-01 --plan ASP-acc-poc-web-app-svc-test-01-8e42 --location westeurope --runtime PYTHON:3.12 --name acc-poc-web-app-svc-test-01 --verbose
```