Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add mark3labs/kit --skill kit-sdkgit clone --depth 1 https://github.com/mark3labs/kitWrote 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/skills/mark3labs/kit/kit-sdk)<a href="https://agentmods.dev/skills/mark3labs/kit/kit-sdk"><img src="https://agentmods.dev/badge/skills/mark3labs/kit/kit-sdk/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/skills/mark3labs/kit/kit-sdk"><img src="https://agentmods.dev/badge/skills/mark3labs/kit/kit-sdk.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.00078 | $0.02622 |
| Opus 5.5 | $0.00031 | $0.01049 |
| Sonnet 5.5 | $0.00016 | $0.00524 |
| Haiku 4.5 | $0.00008 | $0.00262 |
Grade A, and why
kit-sdk 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 today.
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 — 151 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Kit SDK Development Guide
The Kit SDK (pkg/kit) lets you embed Kit's full agent capabilities — LLM interactions, tool execution, session management, streaming, hooks — into any Go application. Unlike extensions (which are interpreted scripts running inside Kit's TUI), SDK programs are standalone compiled Go binaries.
This file is the entry point. It gives the installation, a quick start, the core lifecycle, and the rules you must never miss. Detailed material lives in the references/ directory (see Reference files below). Read only the reference files that apply to your task.
Installation
go get github.com/mark3labs/kit
Import path (alias recommended):
import kit "github.com/mark3labs/kit/pkg/kit"
Quick Start
package main
import (
"context"
"fmt"
"log"
kit "github.com/mark3labs/kit/pkg/kit"
)
func main() {
ctx := context.Background()
host, err := kit.New(ctx, nil) // nil = normal config-file discovery and field resolution
if err != nil {
log.Fatal(err)
}
defer func() { _ = host.Close() }()
response, err := host.Prompt(ctx, "What is 2+2?")
if err != nil {
log.Fatal(err)
}
fmt.Println(response)
}
Core Lifecycle
- Create:
kit.New(ctx, opts)— loads config, initializes MCP servers, creates LLM provider, sets up agent - Interact:
host.Prompt(ctx, msg)— send messages, agent uses tools as needed - Close:
host.Close()— cleans up MCP connections, model resources, session file handle
Always defer Close():
defer func() { _ = host.Close() }()
API Map
| Area | Entry points | Reference |
|---|---|---|
| Configure the instance | kit.Options{Model, SystemPrompt, MaxSteps, Tools, ExtraTools, NoSession, ...}, kit.NewIsolatedAgent / kit.Isolated() for hermetic embeds |
references/options.md |
| Talk to the agent | Prompt, PromptResult, PromptResultWithFiles, PromptWithOptions, Steer, FollowUp, PromptResultWithMessages |
references/prompt-methods.md |
| Observe (read-only) | host.OnToolCall(...), host.OnMessageUpdate(...), host.Subscribe(...) |
references/events.md |
| Intercept (read-write) | host.OnBeforeToolCall(priority, fn), OnAfterToolResult, OnBeforeTurn, OnPrepareStep, OnContextPrepare, OnBeforeCompact |
references/hooks.md |
| Add capabilities | kit.NewTool(name, desc, fn), kit.TextResult, built-in tool constructors and bundles |
references/tools.md |
| Persist conversations | SessionPath, Continue, NoSession, instance and package-level session methods |
references/sessions.md |
| Decision API | kit.Decide, host.Decide, GetDecisionModels, typed question builders |
references/decisions.md |
| Models and MCP | host.SetModel, model registry, custom provider backends (kit.RegisterProvider, Options.Providers), AddMCPServer, in-process servers, MCP OAuth |
references/models-and-mcp.md |
| Manage the context window | EstimateContextTokens, Compact, AutoCompact, host.Subagent |
references/context-compaction-subagents.md |
What ships with it
13 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- references/common-patterns.md 3.6 KB
- references/configuration.md 1.1 KB
- references/context-compaction-subagents.md 5.1 KB
- references/decisions.md 7.8 KB
- references/events.md 8.0 KB
- references/extension-api-auth-skills.md 7.3 KB
- references/hooks.md 5.6 KB
- references/models-and-mcp.md 12 KB
- references/options.md 31 KB
- references/prompt-methods.md 2.1 KB
- references/sessions.md 9.6 KB
- references/tools.md 6.0 KB
- references/types.md 4.5 KB
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.
- today Changed · +1 lines fdfc4345f2cb
- 14d ago Changed 3a8c5c5debe4
- 28d ago Changed a92587eea807
- 29d ago Changed 0fd54e4d7a44
- 1mo ago Changed · -1,281 lines scan D → A 8f48c517ee39
- 1mo ago Changed ae5247a32375
- 1mo ago Changed f3831ffaf2e6
- 1mo ago First seen · 1,431 lines · 78 tokens per session scan D 2058f1c6875f
kit-sdk is a skill published in the GitHub repository mark3labs/kit (144 stars, last pushed today), licensed MIT. It adds 78 tokens to every session and 2,622 once invoked, about $0.0003 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.
Other skills, from other repositories
golang-testing
Go testing best practices including table-driven tests, test helpers, benchmarking, race detection, coverage analysis, and integration testing patterns. Use when writing or improving Go tests.
golang-patterns
Go-specific design patterns and best practices including functional options, small interfaces, dependency injection, concurrency patterns, error handling, and package organization. Use when working with Go code to apply idiomatic Go patterns.
ax-go-agent-optimize
Use when writing Go code with github.com/ax-llm/ax/packages/go for agent optimization, verified agent-playbook evolution, evaluators, judges, optimizer artifacts, BootstrapFewShot, and GEPA.
golang-testing
Production-ready Golang tests — table-driven tests, testify suites and mocks, parallel tests, fuzzing, fixtures, goroutine leak detection with goleak, snapshot testing, code coverage, integration tests, idiomatic test naming. Use when writing or reviewing Go tests, choosing a testing approach, setting up Go test CI…
golang-uber-fx
Golang application framework using uber-go/fx — fx.New, fx.Provide, fx.Invoke, fx.Module, fx.Lifecycle hooks, fx.Annotate (name/group/As), fx.Decorate, fx.Supply, fx.Replace, fx.WithLogger, and signal-aware Run(). Apply when using or adopting uber-go/fx, when the codebase imports go.uber.org/fx, or when wiring…
golang-samber-oops
Structured error handling in Golang with samber/oops — error builders, stack traces, error codes, error context, error wrapping, error attributes, user-facing vs developer messages, panic recovery, and logger integration. Apply when using or adopting samber/oops, or when the codebase already imports…