kotlin-code-authoring
Skill1 starsChanged 56 days agoApache-2.0View on GitHub
Write or modify Kotlin application code while preserving project conventions and readable Kotlin idioms. Use when implementing a feature, bug fix, or refactor in actual Kotlin application source, including Kotlin/Spring modules, even when the user does not name the stack; do not use for Java changes, Gradle build logic, or review-only requests.
We split this skill into the rules it gives an agent
8 rules. About 0 are common, 5 are distinctive, and 3 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈5
Distinctive · estimate
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 8
Write Kotlin that matches the target repository's compiler version, formatter, existing style, and framework conventions.
- Very specific: line 15
Prefer val, explicit null handling, read-only public collection types, and data/sealed types where their semantics fit.
- Very specific: line 18
When behavior changes, create or update a focused test using the detected test stack.
- Distinctive: line 20
Read Spring construction for dependency injection and transactional-boundary decisions.
- Distinctive: line 26
Keep parameters that the called API requires, including multi-parameter lambdas.
- Very specific: line 35
Use Kotlin lambda conventions when deciding whether a nested scope is ambiguous.
- Distinctive: line 41
Run the affected Kotlin module's formatter, lint, and compile/test task when the repository provides them.
- Distinctive: line 43
If the build cannot run (no wrapper, no network, tool missing), do not stop at "not run".
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Kotlin code authoring
Write Kotlin that matches the target repository's compiler version, formatter, existing style, and framework conventions. Inspect nearby Kotlin code and project instructions before choosing an API or style.
Construction baseline
Apply the same Kotlin/Spring principles used by kotlin-spring-review before writing code. It is an installed dependency: read its principles and route only the relevant topics through its KB index. Use those references as construction constraints, not as a request to produce a review.
- Preserve the repository's layer and dependency direction. Do not bypass the designated application/service boundary or leak persistence types across a boundary when local architecture rules prohibit it.
- Prefer
val, explicit null handling, read-only public collection types, anddata/sealedtypes where their semantics fit. Do not introduce!!, unsafe casts, or mutable public state merely to shorten an implementation. - For Spring-managed mandatory dependencies, use constructor injection. Put transaction behavior at the existing application/service boundary; preserve proxy and transaction conventions instead of adding broad annotations speculatively.
- Validate and translate errors at the repository's existing boundary. Do not swallow broad exceptions or invent error contracts.
- When behavior changes, create or update a focused test using the detected test stack. Use
test-authoringfor test-specific guidance.
Read Spring construction for dependency injection and transactional-boundary decisions. When the change adds or alters an entity state transition, or the request mentions repeated or concurrent requests, read state-transition commands before coding.
Lambda parameters
- For a non-nested, single-parameter lambda, use
it. - Name a lambda parameter only when nesting makes the value or receiver ambiguous; name the inner parameter for that block.
- Keep parameters that the called API requires, including multi-parameter lambdas.
orders.filter { it.isActive }
orders.groupBy { it.customerId }
.mapValues { (_, customerOrders) -> customerOrders.map { order -> order.id } }Use Kotlin lambda conventions when deciding whether a nested scope is ambiguous. Do not apply this skill to review-only work; use kotlin-spring-review for findings and severity.
Verify
Before writing the handover, trace the request clause by clause. For each clause name the changed code and the test that exercises it, or mark it unverified with the reason. When a clause says to match something existing ("same format as the existing API"), cite the file you matched; if no precedent exists, say so and state the shape you chose as an assumption. List every public contract you added (endpoint, response field, error code) and justify each new error code against the existing ones, or reuse them. Add a test for any clause still left without one if the test stack can run it.
Run the affected Kotlin module's formatter, lint, and compile/test task when the repository provides them. Do not introduce a formatter or a dependency solely for this rule.
If the build cannot run (no wrapper, no network, tool missing), do not stop at "not run". Before handing over commands, check each one against the build files and stop when every command and new import is accounted for:
- dependency resolution: a
repositoriesblock in the build or settings file; - each task you name: what it needs, e.g.
build/bootJarneeds a main class; - each import in new code and tests: a declared dependency provides it.
Give only commands that pass this check; name each failed check as a blocker. Label unrun claims as unverified.
In this repository65 other files it gives its agents.
- agent-evalSkill
- architecture-review-workflowSkill
- backend-code-review-workflowSkill
- code-authoring-routerSkill
- code-diagram-extractSkill
- codex-agent-runtimeSkill
- design-pattern-applySkill
- diagram-stylerSkill
- document-designerSkill
- e2e-evidence-reportSkill
- e2e-report-rendererSkill
- e2e-runnerSkill
- e2e-scenario-authorSkill
- e2e-test-workflowSkill
- entitySkill
- enumSkill
- explore-dead-codeSkill
- flywaySkill
- git-flowSkill
- harness-proposeSkill
- harness-refineSkill
- java-spring-review-workflowSkill
- knowledge-auditSkill
- korean-dev-writerSkill
- kotlin-spring-reviewSkill
- kotlin-spring-review-workflowSkill
- learnSkill
- mapperSkill
- markdown-publisherSkill
- mermaid-diagramsSkill
- mssql-code-authoringSkill
- nl-sql-querySkill
- notion-domain-contextSkill
- oop-design-reviewSkill
- opensearch-code-authoringSkill
- opensearch-optimizationSkill
- opensearch-query-reviewSkill
- opensearch-review-workflowSkill
- opensearch-schema-reviewSkill
- pdf-qaSkill
- playwright-e2eSkill
- postgres-code-authoringSkill
- postgres-query-reviewSkill
- postgres-review-workflowSkill
- postgres-risk-checkSkill
- postgres-schema-designSkill
- product-requirementsSkill
- product-ui-designSkill
- refactoring-catalogSkill
- repositorySkill
- requestSkill
- responseSkill
- retroSkill
- schema-doc-extractSkill
- security-scan-workflowSkill
- serviceSkill
- skill-updaterSkill
- start-taskSkill
- test-authoringSkill
- test-quality-refactoring-workflowSkill
- The first 60 shown.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

