Koog is a Kotlin and Java framework for building AI agents that use tools, interact with people, and run multi-step workflows. JVM and Kotlin developers use it to deploy agents across platforms such as JVM, Android, iOS, JavaScript, and WebAssembly, with features for persistence, fault recovery, model switching, and monitoring. The catalogue entries provide agents, skills, and instructions for building with Koog.
Borrowing it
Nothing to install: this file belongs to JetBrains/koog. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/JetBrains/koog/develop/AGENTS.mdgit clone --depth 1 https://github.com/JetBrains/koogWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/instructions/jetbrains/koog/agents-md)<a href="https://agentmods.dev/instructions/jetbrains/koog/agents-md"><img src="https://agentmods.dev/badge/instructions/jetbrains/koog/agents-md/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/instructions/jetbrains/koog/agents-md"><img src="https://agentmods.dev/badge/instructions/jetbrains/koog/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.01913 | $0.01913 |
| Opus 5.5 | $0.00765 | $0.00765 |
| Sonnet 5.5 | $0.00383 | $0.00383 |
| Haiku 4.5 | $0.00191 | $0.00191 |
Grade A, and why
koog AGENTS.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 251 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Koog AI Agent Framework
Koog is a Kotlin multiplatform framework for building AI agents with graph-based workflows. It supports JVM and JS targets and integrates with multiple LLM providers (OpenAI, Anthropic, Google, OpenRouter, Ollama) and Model Context Protocol (MCP).
Project Structure
The project follows a modular architecture with a clear separation of concerns:
koog/
├── agents/
│ ├── agents-core/ # Core abstractions (AIAgent, AIAgentStrategy, AIAgentEnvironment)
│ ├── agents-tools/ # Tool infrastructure (Tool<TArgs, TResult>, ToolRegistry, AIAgentTool)
│ ├── agents-features-*/ # Feature implementations (memory, tracing, event handling)
│ ├── agents-mcp/ # Model Context Protocol integration
│ └── agents-test/ # Testing utilities and framework
├── prompt-*/ # LLM interaction layer (executors, models, structured data)
├── embeddings-*/ # Vector embedding support
├── examples/ # Reference implementations and usage patterns
└── build.gradle.kts # Root build configuration
Build & Commands
Development Commands
# Full build including tests
./gradlew build
# Build without tests
./gradlew assemble
# Run all JVM tests
./gradlew jvmTest
# Run all JS tests
./gradlew jsTest
# Test specific module
./gradlew :agents:agents-core:jvmTest
# Run specific test class
./gradlew jvmTest --tests "ai.koog.agents.test.SimpleAgentMockedTest"
# Run specific test method
./gradlew jvmTest --tests "ai.koog.agents.test.SimpleAgentMockedTest.test AIAgent doesn't call tools by default"
# Compile test classes only (for faster iteration)
./gradlew jvmTestClasses jsTestClasses
Development Environment
- JDK: 17+ required for JVM target
- Build System: Gradle with version catalogs for dependency management
- Targets: JVM, JavaScript (Kotlin Multiplatform), WASM
- IDE: IntelliJ IDEA recommended with Kotlin plugin
Code Style
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2mo ago First seen · 251 lines · 1,913 tokens per session scan A f7cc031abe45
koog AGENTS.md is an instructions file published in the GitHub repository JetBrains/koog (4,653 stars, last pushed yesterday), licensed Apache-2.0. It adds 1,913 tokens to every session, about $0.0077 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
koog AGENTS.md compared with instructions from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| koog AGENTS.mdJetBrains/koog | Instructions file | 4.7k | yesterday | Apache-2.0 | A | 1,913 | Codex, OpenCode |
| vscode buildNext.instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 9,719 | GitHub Copilot |
| next.js AGENTS.mdvercel/next.js | Instructions file | 143k | today | MIT | A | 7,461 | Codex, OpenCode |
| langchain AGENTS.mdlangchain-ai/langchain | Instructions file | 149k | today | MIT | A | 4,680 | Codex, OpenCode |
| vscode oss-third-party-notices.instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 5,516 | GitHub Copilot |
| vscode copilot-instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 3,093 | GitHub Copilot |
| deepseek-harness AGENTS.mddeepseek-ai/deepseek-harness | Instructions file | 274k | 2d ago | MIT | A | 4,313 | Codex, OpenCode |