An open API service indexing awesome lists of open source software.

https://github.com/gift-exe/ecc-mvp-websocket-server

Simple Websocket server for call monitoring, based off the AI emergency handler project to be pitched to ECC Nigeria
https://github.com/gift-exe/ecc-mvp-websocket-server

Last synced: 4 months ago
JSON representation

Simple Websocket server for call monitoring, based off the AI emergency handler project to be pitched to ECC Nigeria

Awesome Lists containing this project

README

          

## Steps to run the server locally
---
#### Step 1: Create Virtual Environment:
`$ python3.10 -m venv ws-env`

#### Step 2: Acitivate Virtual Environment:
`$ source ws-env/bin/activate`

#### Step 3: Install Requirements.txt
`(ws-env) $ pip install -r requirements.txt`

#### Step 4: Run Server (version 2):
`(ws-env) $ uvicorn server_v3:app --reload

## Endpoints
---
### There are three endpoints on this server:
- `/client`: which is meant for callers (end-users) to connect to and send their conversations with the AI agent
- `/monitor`: this is meant for the monitor user(s) to mmonitor the conversations between users, and the AI agent
- `/history`: this endpoint returns the complete conversation of the caller and the AI agent in a call session

## Testing
---
- To test `/client` endpoint you sould run the `test_message.py` script, which sends a message to the ws server.
- To test the `/monitor` endpoint you can run the `index.html` file, to connect to the ws server as a monitor client.
- To test the `/history` endpoint run the `test_get_history.py` script, to get the message converation history from the test caller.