Skip to main content
Glama
peter14l

Kotlin Multi-Agent Orchestrator

by peter14l
README.md
# Kotlin Multi-Agent Orchestrator (MCP Server & Skill)

> **Enterprise-grade Multi-Agent System & Model Context Protocol (MCP) Server for building production-ready Kotlin apps across Android (Jetpack Compose), Compose Multiplatform (CMP), Ktor Backend, Spring Boot, Dynamic Design/Architecture Document Blueprints, and Hackathon Fast Prototyping.**

---

## 🌟 Complete Specialized Agent Roster (24 Tools)

### πŸ“‹ Project Specifications, Blueprints & Documentation Agents
| Specialized Agent | MCP Tool Name | Description & Key Responsibilities | How to Call |
| :--- | :--- | :--- | :--- |
| πŸ“‘ **Blueprint & Spec Architect** | `scaffold_kotlin_project_docs` | Generates dynamic, prompt-tailored `PRD.md`, `architecture.md`, `rules.md`, `phases.md`, `design.md`, and `memory.md`. Checks if files already exist before writing to prevent overwriting manual notes. | `scaffold_kotlin_project_docs({ projectName: "MyApp", appDescription: "..." })` |

### πŸš€ Core Architecture & Engineering Agents
| Specialized Agent | MCP Tool Name | Description & Key Responsibilities | How to Call |
| :--- | :--- | :--- | :--- |
| 🧩 **Prompt Architect** | `decompose_kotlin_prompt` | Breaks down vague or complex user prompts into structured feature tickets (P0/P1/P2), Clean Architecture modules, and execution sprints. | `decompose_kotlin_prompt({ prompt: "...", target: "android-compose" })` |
| 🌐 **Dependency Researcher** | `research_kotlin_dependencies` | Queries Maven Central, validates Kotlin 2.x K2 compiler compatibility, and generates standard `gradle/libs.versions.toml` Version Catalogs. | `research_kotlin_dependencies({ target: "android-compose" })` |
| 🎨 **UI / UX Specialist** | `design_kotlin_ui` | Generates modern Jetpack Compose / CMP screens with MVI Unidirectional Data Flow, Material 3 theming, domain layouts, and `@PreviewLightDark` previews. | `design_kotlin_ui({ screenName: "DashboardScreen", targetPlatform: "android-compose" })` |
| βš™οΈ **Backend Specialist** | `scaffold_kotlin_backend` | Scaffolds high-throughput Ktor 3.x / Spring Boot Kotlin backend routes, services, Exposed/Room databases, and Koin DI modules. | `scaffold_kotlin_backend({ domainName: "Wallet", backendType: "ktor" })` |
| 🩺 **Compiler Doctor** | `diagnose_kotlin_errors` | Diagnoses Kotlin compiler errors, Gradle sync/build failures, Compose recomposition issues, and Coroutine race conditions with code diffs. | `diagnose_kotlin_errors({ errorMessage: "Compose Compiler requires Kotlin 1.9..." })` |
| πŸ§ͺ **QA & Test Specialist** | `generate_and_run_tests` | Generates Unit tests with MockK, Flow/State verification with Turbine, and Compose UI tests with `createComposeRule`. | `generate_and_run_tests({ className: "WalletViewModel", testType: "viewmodel" })` |
| πŸ” **Code Quality Auditor** | `audit_kotlin_codebase` | Audits Kotlin source code for memory leaks, `GlobalScope` anti-patterns, and Compose performance bottlenecks. | `audit_kotlin_codebase({ code: "...", fileType: "viewmodel" })` |
| 🌐 **Cross-Bridge Specialist** | `generate_kotlin_api_bridge` | Generates full-stack API contracts: Ktor server routes, KMP client, matching Dart DTOs, and OpenAPI 3.0 specs. | `generate_kotlin_api_bridge({ serviceName: "Order", endpoints: [...] })` |
| πŸ“± **Native Platform Specialist** | `generate_kotlin_platform_config` | Generates `AndroidManifest.xml` permissions, ProGuard/R8 keep rules, release keystore configs, and Compose Desktop packaging. | `generate_kotlin_platform_config({ projectName: "MyApp", permissions: ["CAMERA"] })` |
| πŸš€ **CI/CD & DevOps Engineer** | `generate_kotlin_cicd_pipeline` | Generates production GitHub Actions workflows, Detekt static analysis steps, Dockerfile for Ktor backends, and Gradle Build Caching. | `generate_kotlin_cicd_pipeline({ projectName: "MyApp", target: "android-compose" })` |
| πŸ“Έ **Visual Snapshot Specialist** | `generate_compose_screenshot_tests` | Generates Roborazzi emulator-less JVM screenshot test suites across Light/Dark modes and tablet viewports. | `generate_compose_screenshot_tests({ screenName: "DashboardScreen", composableName: "DashboardContent" })` |
| πŸ€– **On-Device AI Specialist** | `scaffold_kotlin_ai_module` | Scaffolds Google GenAI Kotlin SDK / MediaPipe on-device LLM inference modules with Flow streaming and ViewModel state integration. | `scaffold_kotlin_ai_module({ featureName: "ChatAssistant", provider: "google-genai" })` |
| πŸ” **Security & Crypto Auditor** | `audit_kotlin_security` | Audits Kotlin code for secret leaks, scaffolds AndroidX `EncryptedSharedPreferences` (MasterKey AES256-GCM), and `BiometricPrompt`. | `audit_kotlin_security({ codeSnippet: "...", enableBiometrics: true })` |
| πŸ’Ύ **Database Architect** | `scaffold_kotlin_database` | Scaffolds Android Room 2.7+ (KSP) database with entities, DAOs returning Coroutine Flow streams, and AutoMigration strategies. | `scaffold_kotlin_database({ databaseName: "Crypto", entities: [...] })` |
| 🌍 **Localization (i18n) Specialist** | `generate_kotlin_localization` | Generates Android `strings.xml` resource bundles (values, values-es, values-ar for RTL) and Jetpack Compose `AppStrings` helpers. | `generate_kotlin_localization({ supportedLocales: ["en", "es", "ar"], stringKeys: {...} })` |
| πŸ“Š **Observability & Analytics Specialist** | `scaffold_kotlin_observability` | Scaffolds Sentry/Firebase Crashlytics crash reporting, type-safe analytics event loggers, and OkHttp network latency interceptors. | `scaffold_kotlin_observability({ provider: "sentry", customEventNames: ["token_swapped"] })` |
| πŸ”— **Deep Linking & Push Specialist** | `configure_kotlin_deep_links` | Configures Android App Links intent-filters in `AndroidManifest.xml`, `assetlinks.json`, Jetpack Compose Navigation deep links, and FCM routing. | `configure_kotlin_deep_links({ customScheme: "myapp", domainHost: "app.example.com", routes: [...] })` |
| β™Ώ **Accessibility (a11y) Auditor** | `audit_kotlin_accessibility` | Audits Jetpack Compose code against WCAG 2.1 AA guidelines, checks `Modifier.semantics`, `contentDescription`, and generates `AccessibleInteractiveBox`. | `audit_kotlin_accessibility({ codeSnippet: "Icon(Icons.Default.Add, contentDescription = null, ...)" })` |
| πŸš€ **Master Orchestrator** | `orchestrate_kotlin_project` | Coordinates all specialized agents into an automated, end-to-end project generation pipeline. | `orchestrate_kotlin_project({ projectName: "MyApp", target: "android-compose", prompt: "..." })` |

### ⚑ Hackathon Fast-Prototyping Agents
| Specialized Agent | MCP Tool Name | Description & Key Responsibilities | How to Call |
| :--- | :--- | :--- | :--- |
| 🎭 **Demo Data & Mock Factory** | `generate_kotlin_mock_factory` | Generates deterministic domain mock data factories, fake entities, and simulated Flow repositories for instant UI prototyping. | `generate_kotlin_mock_factory({ domainName: "Product", itemCount: 10 })` |
| πŸ” **Auth & Onboarding Specialist** | `scaffold_kotlin_auth_flow` | Scaffolds Compose HorizontalPager Onboarding tour, Material 3 Login screen with Google auth, and state-preserving AuthViewModel. | `scaffold_kotlin_auth_flow({ appName: "HackathonApp" })` |
| πŸ“ˆ **Charts & Data Storytelling** | `generate_kotlin_charts` | Scaffolds interactive animated Canvas charts (Line, Bar, Area graphs) with gradient fills and tween animations. | `generate_kotlin_charts({ chartTitle: "Revenue Trends", dataPoints: [...] })` |
| πŸ›‘οΈ **Hackathon Demo Resilience** | `scaffold_kotlin_offline_resilience` | Guarantees zero crashes during live stage demos by catching network drops / timeouts and seamlessly serving cached mock data. | `scaffold_kotlin_offline_resilience({ enableDemoMockFallback: true })` |

---

## πŸ“¦ Installation & Setup

```bash
git clone https://github.com/peter14l/kotlin-agent-orchestrator.git
cd kotlin-agent-orchestrator
npm install
npm run build
npm test
```

TDQS

A3.7/5.0

Scored across 24 tools

Disambiguation5/5

Each tool targets a distinct phase or concern of Kotlin developmentβ€”localization, dependencies, UI, backend, security, docs, etc.β€”so an agent can reliably pick the right one. The closest pairs, such as generate_and_run_tests versus generate_compose_screenshot_tests, are still clearly separated by scope.

Naming Consistency5/5

All tool names use snake_case with a leading verb and consistently follow a verb_kotlin_<target> or verb_<domain> pattern. Even with varied verbs like generate, scaffold, audit, design, configure, and diagnose, the naming convention is predictable and uniform.

Tool Count3/5

24 tools is on the heavy side for a single server, exceeding the ideal 3–15 range. However, each tool maps to a distinct Kotlin development task, so the count is defensible even though the server feels broad rather than lean.

Completeness5/5

The server covers the full Kotlin project lifecycle: prompt decomposition, dependency resolution, UI/backend/database/auth scaffolding, API contracts, tests, CI/CD, docs, security, observability, accessibility, and offline resilience. There are no obvious dead ends or critical missing operations for its stated purpose.

Maintenance

ActivityMaintained
ResponsivenessNo issues