MCPcopy Index your code
hub / github.com/ai-poet/amadeus-system-new

github.com/ai-poet/amadeus-system-new @v0.1.5

Chat with this repo
repository ↗ · DeepWiki ↗ · release v0.1.5 ↗ · + Follow
1,345 symbols 3,082 edges 77 files 21 documented · 2%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Amadeus System New Alpha

English | 中文

A brand new experimental version of Amadeus, EL PSY CONGROO~

Note: This version has been refactored and is different from the initial version. The documentation has been updated, please check the documentation.

🤝 Contributing

Welcome to join the development of Amadeus System! We look forward to your contributions:

  • 🌟 Submit Issues to report bugs or suggest new features
  • 📝 Improve documentation content
  • 🔧 Fix known issues
  • ✨ Develop new features
  • 🎨 Improve user interface

Any form of contribution is very welcome. Let's make Amadeus System better together!

PRs Welcome

Demo Videos

BiliBili BiliBili

Documentation

For detailed documentation, please visit: Amadeus System Documentation Center

Deployment Methods

Download Local Client

The project provides precompiled desktop clients that support Windows systems:

  1. Visit the GitHub Releases page
  2. Install and run the client
  3. Try it directly or configure necessary parameters

Default Client Installation Path

C:\Users\YourUsername\AppData\Local\Programs\Amadeus

Built-in Service Configuration File Path for Client

C:\Users\YourUsername\AppData\Local\Programs\Amadeus\resources\service\.env You can modify the WebRTC server address used by the client

The local client provides the same functionality as the Zeabur online version, but without server deployment, suitable for personal use.

One-Click Deployment with Zeabur (Recommended)

Deploy to Zeabur

Deployment Steps

  1. Click the "Deploy to Zeabur" button above
  2. If you don't have a Zeabur account yet, you need to register first. You need to spend $5 to activate the Developer plan, you can use WildCard virtual credit card to activate, or directly use Alipay to top up balance for payment.
  3. Click the button above for one-click deployment to AWS Hong Kong region, wait for deployment to complete, then fill in environment variables as shown below, and finally click Networking to generate a domain name, you can access your application through the domain provided by Zeabur

Environment Variable Configuration

Environment Variable Description
VITE_APP_DEFAULT_USERNAME Username for frontend login system, allowing Amadeus to recognize your identity
WEBRTC_API_URL WebRTC server API address, the Zeabur template has built-in public WebRTC server, you can also build your own according to the documentation

Notes: - Ensure your project meets Zeabur's deployment requirements - If you need a custom domain, you can set it up in Zeabur's control panel - It's recommended to check Zeabur's official documentation for more deployment-related information

Deploy with Docker Compose

If you want to deploy on your own server, you can use Docker Compose for deployment.

Prerequisites

  1. Ensure your server has Docker and Docker Compose installed
  2. Prepare all required environment variables (refer to the environment variable configuration above)

Docker Compose Configuration

Create a docker-compose.yml file with the following content:

version: '3'
services:
  container:
    image: ghcr.io/ai-poet/amadeus-system-new-alpha
    ports:
      - "3002:3002"  # Service port
    environment:
      - VITE_APP_DEFAULT_USERNAME=${VITE_APP_DEFAULT_USERNAME}
      - WEBRTC_API_URL=${WEBRTC_API_URL}
    restart: unless-stopped
    networks:
      - amadeus-network
    volumes:
      - ./logs:/app/service/logs  # Log persistence storage
networks:
  amadeus-network:
    driver: bridge

Deployment Steps

  1. Create a .env file and fill in the required environment variables
  2. Run in the directory where docker-compose.yml is located:
docker-compose up -d
  1. The service will start in the background, you can view logs with the following command:
docker-compose logs -f

Self-hosted WebRTC Service Deployment

The Zeabur template provides a public WebRTC service, but public services may be unstable, so it's recommended to deploy WebRTC service privately.

Docker-based WebRTC Deployment

After cloning the repository, go to the service/webrtc folder in the code repository and use Dockerfile to build the WebRTC service image:

cd service/webrtc
docker build -t amadeus-webrtc-service .

Run the WebRTC service container:

docker run -d --name amadeus-webrtc \
  -p 8001:8001 \
  -e LLM_API_KEY=YourOpenAI_API_Key \
  -e WHISPER_API_KEY=YourWhisper_API_Key \
  -e SILICONFLOW_API_KEY=YourSiliconFlow_API_Key \
  -e SILICONFLOW_VOICE=YourSiliconFlow_Voice_ID \
  -e LLM_BASE_URL=YourLLM_API_Base_URL \
  -e WHISPER_BASE_URL=YourWhisper_API_Base_URL \
  -e WHISPER_MODEL=YourWhisper_Model_Version \
  -e AI_MODEL=YourLLM_Model_Version \
  -e MEM0_API_KEY=YourMEM0_Memory_Service_API_Key \
  -e TIME_LIMIT=YourWebRTC_Stream_Max_Time_Limit_Seconds \
  -e CONCURRENCY_LIMIT=YourMax_Concurrent_Connections \
  amadeus-webrtc-service

After deployment, you can access your own WebRTC service through http://YourServerIP:8001.

WebRTC Service Environment Variables

The following are the environment variables for the built-in AI services of the WebRTC service, which can be used to build public services:

Environment Variable Description Default Value
LLM_API_KEY OpenAI or compatible API key for large language model service None
WHISPER_API_KEY Whisper API key for speech recognition service None
SILICONFLOW_API_KEY SiliconFlow API key for text-to-speech service None
SILICONFLOW_VOICE Your custom voice ID in SiliconFlow None
LLM_BASE_URL Base URL for large language model API None
WHISPER_BASE_URL Base URL for Whisper API None
WHISPER_MODEL Whisper model version to use None
AI_MODEL Large language model version to use None
MEM0_API_KEY MEM0 memory service API key None
TIME_LIMIT Maximum time limit for WebRTC stream (seconds) 600
CONCURRENCY_LIMIT Maximum concurrent connections 10

Port Configuration Requirements

When deploying WebRTC service, ensure the following ports are open on your server:

  • 80: HTTP communication
  • 443: HTTPS communication
  • 3478: STUN/TURN service (TCP)
  • 5349: STUN/TURN service (TLS)
  • 49152-65535: Media stream port range (UDP)

Note

If using cloud service providers (such as AWS, Alibaba Cloud, etc.), please ensure these ports are opened in security group/firewall settings.

TURN Server Deployment

In production environments, to handle audio/video penetration issues in complex network environments, TURN servers usually need to be deployed. You can:

  • Deploy Coturn yourself
  • Refer to FastRTC deployment documentation for AWS automated deployment
Automated TURN Server Deployment on AWS

FastRTC provides an automation script that can deploy TURN servers on AWS:

  1. Clone the FastRTC deployment repository
  2. Configure AWS CLI and create EC2 key pairs
  3. Modify parameter files, fill in TURN username and password
  4. Run CloudFormation script for automated deployment

For detailed steps, please refer to FastRTC's self-hosted deployment guide.

After deployment is complete, you can fill in the TURN server information in the WebRTC service code:

{
  "iceServers": [
    {
      "urls": "turn:YourTURNServerIP:3478",
      "username": "YourSetUsername",
      "credential": "YourSetPassword"
    }
  ]
}

Tip

After correctly configuring the TURN server, even in complex network environments (such as symmetric NAT, behind corporate firewalls), the stability of audio and video communication can be guaranteed.

Extension points exported contracts — how you extend this code

ChatMessage (Interface)
* 聊天信息接口定义 * @interface ChatMessage * @property {string} role - 消息角色:用户或助手 * @property {string} content - 消息内容 * @pr
src/pages/Home/index.tsx
ImportMetaEnv (Interface)
(no doc)
src/env.d.ts
ChatMessage (Interface)
(no doc)
src/types/chat.ts
LoginOverlayProps (Interface)
(no doc)
src/components/LoginOverlay/index.tsx
Live2dModel (Interface)
(no doc)
src/constants/live2d.ts
WebRTCState (Interface)
(no doc)
src/hooks/useWebRTC.ts
ImportMeta (Interface)
(no doc)
src/env.d.ts
StartDialogProps (Interface)
(no doc)
src/components/StartDialog/index.tsx

Core symbols most depended-on inside this repo

cn
called by 38
src/lib/utils.ts
handleAiConfigChange
called by 27
src/components/ConfigPanel/useConfigPanel.ts
get_user_config
called by 11
service/webrtc/routes.py
connect
called by 6
src/hooks/useWebRTC.ts
get_user_ai_model
called by 5
service/webrtc/server.py
run_async
called by 5
service/webrtc/utils/async_utils.py
lerp
called by 5
src/components/Live2dModel/AnimationControl.ts
handleLive2dConfigChange
called by 5
src/components/ConfigPanel/useConfigPanel.ts

Shape

Method 586
Function 571
Class 153
Interface 24
Route 9
Enum 2

Languages

TypeScript96%
Python4%

Modules by API surface

public/utils/live2d/index.min.js728 symbols
public/utils/live2d/pixi.min.js179 symbols
public/utils/live2d/live2dcubismcore.min.js96 symbols
public/utils/live2d/live2d.min.js82 symbols
public/utils/crypto/crypto-js.min.js26 symbols
service/webrtc/routes.py25 symbols
src/hooks/useWebRTC.ts22 symbols
public/vad.worklet.bundle.min.js16 symbols
electron/main.mjs14 symbols
service/webrtc/server.py13 symbols
src/components/ConfigPanel/useConfigPanel.ts11 symbols
src/lib/utils.ts10 symbols

For agents

$ claude mcp add amadeus-system-new \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page