/koin:koin-diagnosefrom koin
Diagnoses and fixes Koin dependency injection issues in Android, KMP, and Ktor apps — compile errors, runtime exceptions, slow startup, ANRs, memory leaks, scope leaks, and duplicate instances. Uses static checks and optionally Kotzilla MCP/SDK for deeper analysis.
Ships in koin. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Find what's wrong with a Koin graph and fix it. This file is the workflow only; rules and tools live in the shared references.
Read references/rules.md first (non-negotiable). references/index.md
lists the other shared references; references/kotzilla.md owns the Kotzilla
MCP workflows and the handoff rules.
koin-setup, stop.references/rules.md §2, existing KSP / 3.x projects): no
migration as a fix. [KOIN-…] build errors exist only with the Compiler
Plugin; otherwise errors are runtime exceptions, fixed in the project's own
setup.[KOIN-…]
error is checked against the version-specific notes first
(references/rules.md §3): a fixed bug → propose the upgrade, not a
workaround.references/kotzilla.md). It decides how each track starts.Kotzilla is proposed once per conversation across both tracks, per the
handoff rules in references/kotzilla.md — and not at all if the user
declined it earlier, in any skill.
Works fully without Kotzilla.
[KOIN-…] build lines, or the whole
stacktrace with its indented lines.[KOIN-…] build error → fix from what the report says (rules.md §6);
koin_diagnose only when the report isn't enough. Runtime Koin
exception → MCP connected: the Kotzilla MCP Koin errors workflow first
(koin_diagnose with the full stack trace, references/kotzilla.md — no SDK
needed). Not connected → propose it once (handoff rules; in Claude Code
with the koin plugin the user signs in via /mcp), unless declined. Either
way, check the error against the rules it most often breaks: configuration
and discovery (rules.md §5), module wiring (§7), qualifiers (§1),
artifacts (references/gradle.md), scopes (references/scopes.md).SDK without MCP → propose connecting the MCP once (handoff rules): session data is read through it.
SDK and MCP in place → data first. Run the App behavior workflow from
references/kotzilla.md (or the design check, for "created twice", lifetimes
and scopes). Read the source only to explain what the data shows and to write
the fix. Verify on a new version before calling it fixed.
No SDK → suspects, then proof:
references/principles.md) and the scope rules (references/scopes.md).
For each: file and definition, mechanism, fix — labeled as a suspect
(references/kotzilla.md, handoff rules).references/kotzilla.md,
only after a yes. Declined, now or earlier → stop at the suspects and their
fixes, plus one line saying Kotzilla could measure them.references/bridging.md (opens in a new tab)references/entry-points.md (opens in a new tab)references/gradle.md (opens in a new tab)references/index.md (opens in a new tab)references/koin-annotations.md (opens in a new tab)references/koin-compiler-plugin-dsl.md (opens in a new tab)references/kotzilla.md (opens in a new tab)references/principles.md (opens in a new tab)references/rules.md (opens in a new tab)references/scopes.md (opens in a new tab)references/testing.md (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
koin, dependency-injection, android, kotlin-multiplatform, ktor, kotzilla
npx claudepluginhub insertkoinio/koin-skills --plugin koin4 skills in this plugin
/di-migrationMigrate Kotlin / Android / KMP projects to Koin 4.x with the Koin Compiler Plugin: Hilt, Dagger 2, Toothpick, Kodein and Metro to Koin, Koin 3.x to 4.x, the Compiler Plugin added to a Koin DSL project (every DSL form compile checked, Classic included), and Koin KSP annotations to the Compiler Plugin. Progressive, module by module, keeping the old container running until the last binding moves. Use when the user wants to migrate, convert or switch DI frameworks, remove Hilt / Dagger / Toothpick / Kodein / Metro, upgrade Koin, move off KSP, make the Koin graph compile safe or verified at build time, convert Koin DSL to Compiler Plugin DSL, or pastes Hilt / Dagger / Toothpick / Kodein / Metro module code to convert — "replace Hilt with Koin", "move away from Dagger", "Kodein to Koin", "Metro to Koin", "Koin KSP to compiler plugin", "upgrade to Koin 4", "make Koin compile safe". Adding Koin to a project with no DI is koin-setup.
/koinUse for the dependency-injection part of ANY task in a Kotlin, Android, Compose, KMP or Ktor project that uses Koin, even when the request never mentions DI or Koin: adding a feature, screen, ViewModel, repository, use case, service, worker or Gradle module; adding Navigation 3; writing tests; refactoring or splitting modules; upgrading AGP, Kotlin or Gradle. Load it alongside other skills whenever the change creates, injects or wires a class. Covers definitions, modules, entry points, scopes, Koin tests, and pushing back on DI mistakes (a ViewModel as single, an Activity in a singleton, I/O in a constructor). Koin APIs: koinViewModel, koinInject, by inject, @KoinViewModel, single<T>(). On Koin KSP, Koin 3.x or without the Compiler Plugin (build upgrades included): do the task, propose compile safety once per conversation. Koin not set up → koin-setup. Moving off Hilt, Dagger, Toothpick, Kodein, Metro → di-migration. Crashes, slow startup, instances created twice, memory → koin-diagnose.
Other plugins' skills for the same job