https://medium.com/@Tarek360/annotation-processor-to-avoid-boilerplate-af0b8820297d
This Android project sample demonstrates how to generate a class by an annotation processor written in Kotlin.
The generated code is in Java but the annotation processor written in Kotlin.