$ account SimonSchubert
Kai is an open-source, cross-platform AI assistant application built with Kotlin Multiplatform and Compose Multiplatform. It provides a rich chat interface that integrates dozens of LLM providers (OpenAI, Anthropic, Gemini, Groq, DeepSeek, etc.) and supports on-device inference via LiteRT. The app goes beyond simple chat by offering persistent memory, tool calling (40+ tools including web search, email, SMS, shell commands, calendar, and MCP servers), a Linux sandbox for code execution (Android), scheduled heartbeat agents, skills/plugins, and dynamic AI-generated UI. It targets Android, iOS, desktop (Windows/Mac/Linux), and web (WASM). Architecturally, Kai follows a modular MVVM pattern with platform-specific implementations for features like sandbox, SMS, notifications, and clipboard. The shared code in `commonMain` contains the core logic: data repositories, tool execution, inference orchestration, markdown and math rendering, and a custom dynamic UI system (KaiUi) that renders AI-generated interactive elements inline. Persistence uses SQLDelight for conversations and a JSON-backed settings system for all other state. Dependencies are injected via Koin, and networking uses Ktor with kotlinx.serialization. The codebase is actively maintained (frequent commits, comprehensive CI/CD pipelines, 124 open issues suggesting active user engagement) and technically current with the Kotlin ecosystem. While the feature surface is large and introduces some platform complexity (many expect/actual stubs), the core abstractions are clean and test coverage is solid. Notable reusable components include a generic JSON settings list with corruption recovery, an animated gradient border modifier, and a complete dynamic UI node system that could be extracted for other AI-driven interfaces.