惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

月光博客
月光博客
雷峰网
雷峰网
S
SegmentFault 最新的问题
博客园 - 【当耐特】
博客园_首页
量子位
爱范儿
爱范儿
博客园 - 叶小钗
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Jina AI
Jina AI
V
V2EX
美团技术团队
V
Visual Studio Blog
博客园 - 三生石上(FineUI控件)
IT之家
IT之家
Hugging Face - Blog
Hugging Face - Blog
Apple Machine Learning Research
Apple Machine Learning Research
小众软件
小众软件
博客园 - 聂微东
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
The Cloudflare Blog
宝玉的分享
宝玉的分享
WordPress大学
WordPress大学
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻

Kotlin : A concise multiplatform language developed by JetBrains | The JetBrains Blog

Kotlin 2.4.20 Released - The JetBrains Blog Kotlin Toolchain 0.12: Multiplatform Library Publishing, Wasm Apps, and More - The JetBrains Blog Compose Multiplatform 1.12.0 Released - The JetBrains Blog Signatures, be true: domain errors and functional handling in Kotlin - The JetBrains Blog Klibs.io Grows to 4,200+ KMP Projects With Smarter Discovery and New AI Integrations - The JetBrains Blog Exploring Compose HTML for Server Side Rendering - The JetBrains Blog Programming Language Migration 2025: Why Developers Switch Kodee’s Kotlin Roundup: Birthday Wishes, Shipaton 2026, and the New Kotlin AI Benchmark - The JetBrains Blog Know Kotlin? Ship It Everywhere and Win at Shipaton 2026 - The JetBrains Blog Qodana 2026.2: More Security, Better Coverage, Less Configuration - The JetBrains Blog Secure Your APIs: OAuth2 and JWT for Beginners - The JetBrains Blog Kotlin Turns 15: Celebrate the Kotlin Effect - The JetBrains Blog The History of Kodee, Kotlin’s Mascot - The JetBrains Blog Introducing the Kotlin Benchmark for AI Coding Agents - The JetBrains Blog In Conversation With the Golden Kodee Winners - The JetBrains Blog Kotlin Comes to BlueJ - The JetBrains Blog Kodee’s Kotlin Roundup: Kotlin Turns 15, Kotlin 2.4.0, and the Kotlin Toolchain - The JetBrains Blog Kotlin Notebook Sunset - The JetBrains Blog Kotlin Toolchain 0.11: The Next Step for Amper - The JetBrains Blog Kotlin 2.4.0 Released | The Kotlin Blog Koog 1.0 Is Out: Stable Core, Better Interop, and Multiplatform Observability | The JetBrains AI Blog KotlinConf’26 Keynote Highlights: Advances in Language Design, Tooling, AI-Driven Workflows, and Multiplatform Development | The Kotlin Blog Introducing a Security Support Policy for the Kotlin Standard Library | The Kotlin Blog Official Kotlin Support for Visual Studio Code Is Now Available in Alpha | The Kotlin Blog Built for Productivity: What the Data Finally Shows About Kotlin | The Kotlin Blog A New Default Project Structure for Kotlin Multiplatform | The Kotlin Blog Help Shape the Future of Kotlin in the Age of AI | The Kotlin Blog Compose Multiplatform 1.11.0 Is Now Available | The Kotlin Blog The Road to Name-Based Destructuring | The Kotlin Blog JetBrains 推出的 Kotlin 专业认证现已登陆 LinkedIn Learning | The Kotlin Blog
KotlinLLM is Going Open Source  - The JetBrains Blog
Anastasia Birillo · 2026-07-28 · via Kotlin : A concise multiplatform language developed by JetBrains | The JetBrains Blog

JetBrains Research

Research is crucial for progress and innovation, which is why at JetBrains we are passionate about both scientific and market research

Kotlin Research

Anastasia Birillo Stanislav Sandler

TL;DR

KotlinLLM is now public. It’s a research prototype for delegating runtime logic to an LLM from Kotlin code. Instead of calling an LLM on every request or running a separate agent, you can write an explicit Kotlin call. Its body is generated Kotlin source code, and that code is updated as your application hits new runtime scenarios.

👉 Check it out 

👉 KotlinConf 2026 talk

What is KotlinLLM?

KotlinLLM is an IntelliJ IDEA plugin for Kotlin/JVM projects. It adds a language feature we call Smart macros. A Smart macro is a regular Kotlin function call whose body is generated Kotlin code. The public API has the following two Smart macros:

  • asLlm<F, T>(from, hint) converts an input of type F into a typed value T (data class, enum, list, or primitive). Use it to parse unstructured or semi-structured data into typed Kotlin values at runtime.
  • mockLlm<T>() generates a stateful implementation of an interface T. Its behavior depends on which methods are called on it, so it works as a test double that you don’t have to write by hand.
// One level of abstraction higher: describe intent, let KotlinLLM fill in the logic.
val issuesApiUrl: String = asLlm(repoInput, hint = "GitHub API URL: get all issues, including closed")
val issues: List<Issue> = asLlm(response, hint = "Return all beginner-friendly issues for this repository")

The behavior comes from actual runtime usage rather than being fully specified before the program runs. The call site stays compact and explicit: a clear, keyword-like API over generated code.

The problem it solves

In software engineering, LLMs are during development, i.e. code completion, code generation, and program comprehension. Using an LLM at the runtime of a compiled application is less common, and the existing options have clear trade-offs:

  • Direct runtime delegation (calling the model on every invocation) is slow, non-deterministic, and costly. It also makes the application depend on an LLM service at runtime.
  • External agent workflows keep the generated logic outside the codebase, where it’s harder to review, test, and ship.
  • Most prior work (e.g. byLLM, nightjar, Healer) targets interpreted languages like Python, not a compiled, statically typed language like Kotlin.

KotlinLLM is built around three properties:

  • Explicit – the call site shows that a feature is LLM-backed, so it’s visible in code review.
  • Persistent – generated behavior is saved as an ordinary Kotlin source, not kept only in the runtime session. It can be committed, reviewed, tested, and distributed like any other code.
  • Portable – once generated, the code runs as plain Kotlin without the plugin. For scenarios that are already covered, there’s no further LLM call, so no added latency or cost, and the result is reproducible.

Does it actually work?

We tested the approach on two Kotlin/JVM projects:

  • An adapted Spring Petclinic Kotlin – 18 asLlm call sites, 24/24 application scenarios completed after Smart macro evolution, with a 100% hot-reload success rate and compilation/redefinition adding ~1% of total runtime overhead.
  • A synthetic “GitHub Beginner Issue Radar” – parsing real GitHub issue data across 20 repositories (30k+ issues), reaching ~0.89 recall on ground-truth beginner labels.

These results show that persistent runtime evolution for compiled Kotlin is feasible. The evaluation also documents the current limits.

We’re making it public 

KotlinLLM is open source under the Apache License 2.0. The repository contains:

  • The IntelliJ plugin prototype and the stable Smart macro API.
  • Runnable example projects (GitHub Issue Radar, an adapted Petclinic), including committed generated sources, so you can inspect what the LLM produced and run it as ordinary Kotlin.
  • The KotlinConf2026 talk recording and the theoretical write-up with the full design rationale and evaluation.

Try it and tell us what you think 

KotlinLLM is a research prototype, so feedback is useful at this stage. A few ways to help:

  • Start and explore the repo
  • Try it on your own Kotlin/JVM project. Add the KotlinLLM.kt API file, launch with the Run with KotlinLLM executor, and let the Smart macros evolve. Setup steps are in the README. 
  • Open issues for anything you run into: rough edges, unexpected LLM behavior, missing cases, or behavior you’d expect to be different.
  • Send PRs with use cases. Real scenarios where asLlm/mockLlm work well – or break – are the most useful. New examples, target types, and agent tools are all welcome.

If you find a place where runtime logic delegation fits your code, open an issue. If you build something with it, send a PR.

Subscribe to JetBrains Research blog updates

Discover more