This project integrates the Doctor MCP Agent with LiveKit, providing a backend and frontend for real-time communication.
-
Navigate to the backend directory:
cd livekit-backend -
Ensure Python 3.10+ is installed.
-
Install dependencies:
pip install -r requirements.txt
-
Set up environment variables:
- Copy
.env.exampleto.envand fill in your credentials. - Example:
OPENAI_API_KEY=your_openai_api_key LIVEKIT_URL=your_livekit_url LIVEKIT_API_KEY=your_livekit_api_key LIVEKIT_API_SECRET=your_livekit_api_secret SIMLI_API_KEY=your_simli_api_key
- Copy
-
Run the MCP server:
python hospital_agent_mcp.py
- The server runs at http://localhost:8001.
-
Run the LiveKit Agent worker (connects to LiveKit Cloud):
python livekit_agent.py dev
-
Navigate to the frontend directory:
cd livekit-frontend -
Ensure Node.js (>=18) is installed.
Download Node.js -
Install pnpm globally:
npm install -g pnpm
-
Install dependencies:
pnpm install
-
Set up environment variables:
- Copy
.env.exampleto.env.localand fill in your credentials. - Example:
LIVEKIT_URL=your_livekit_url LIVEKIT_API_KEY=your_livekit_api_key LIVEKIT_API_SECRET=your_livekit_api_secret
- Copy
-
Run the development server:
pnpm dev
- The frontend runs at http://localhost:3000.
Both backend and frontend require environment variables. Refer to the provided .env.example files in each directory for required keys.
- Backend: http://localhost:8001
- Frontend: http://localhost:3000