How keganhollern/aika works
Main Components
a. Core Components:
• Discord Integration Layer
• AI Processing Layer
• Voice Processing System
• Storage System
• Action Handlers
b. External Services:
• Discord API
• OpenAI Services (ChatGPT, DALL-E, Whisper)
• ElevenLabs TTS
• S3 Storage
• Third-party APIs (YouTube, DuckDuckGo, MyAnimeList, Waifu.pics)
[External Services Layer]
• ↕
[Integration Layer]
• ↕
[Core Processing Layer]
• ↕
[Storage Layer]
Component Details
a. Discord Integration Layer:
• Separate components for text chat and voice chat handling
• Discordai and discordchat subsystems
• Chatbot component as the main entry point
b. AI Processing Layer:
• Separate components for different AI functions:
• Text processing (ChatGPT)
• Image generation (DALL-E)
• Vision processing
• Voice transcription (Whisper)
c. Voice Processing System:
• Components for:
• Voice reception
• Transcoding
• Text-to-Speech
• Audio mixing
• YouTube playback
d. Action Handlers:
• Related actions:
• Web actions (anime, search, tenor, waifu)
• YouTube actions (download, search, player)
• Discord actions
• Math actions
• OpenAI actions
Data Flow Representation
• Event-based communication (curved lines)
Important Details
• Configuration management
• System message handling
• Token management
• Guild-specific settings
• Error handling paths
• Storage interactions (S3 and disk)
Deployment Context
A small section showing:
• Docker container boundary
• Required environment variables
• External dependency connections
• Any abbreviations used
• Special symbols