FR
Go CLI Tool · Open Source

Cut LLM token usage
by 87%

GoTK filters command output before it reaches your LLM. Fewer tokens, same information, faster responses.

$ go install github.com/antikkorps/GoTK/cmd/gotk@latest
View on GitHub

See the difference

Real command output — before and after GoTK

-95% tokens
Raw — 10 lines
src/server/handler.go:14:func HandleRequest(w http.ResponseWriter, r *http.Request) {
src/server/handler.go:28:  // HandleRequest processes incoming HTTP requests
src/server/handler.go:55:  log.Printf("HandleRequest: method=%s path=%s", r.Method, r.URL.Path)
src/server/middleware.go:9:func AuthMiddleware(next http.Handler) http.Handler {
src/server/middleware.go:33:  // Validate token before HandleRequest
src/client/api.go:22:func (c *Client) SendRequest(ctx context.Context, req *Request) (*Response, error) {
src/client/api.go:71:  return c.SendRequest(ctx, &Request{Method: "GET", Path: path})
src/client/api.go:85:  return c.SendRequest(ctx, &Request{Method: "POST", Path: path, Body: body})
pkg/models/request.go:5:type Request struct {
pkg/models/request.go:12:// NewRequest creates a request with defaults.
Filtered — 9 lines
>> src/server/handler.go
  func HandleRequest(w http.ResponseWriter, r *http.Request) {
  // HandleRequest processes incoming HTTP requests

>> src/client/api.go
  func (c *Client) SendRequest(...) (*Response, error) {

>> pkg/models/request.go
  type Request struct {

Features

Quality-first filtering — remove noise, preserve every error and warning

18+ Command Filters

Specialized filters for grep, git, go, docker, npm, terraform, kubectl, and more.

6 Execution Modes

Direct, pipe, exec, watch, daemon, and context search.

Secret Redaction

API keys, tokens, passwords, and JWTs automatically replaced with [REDACTED].

Stack Trace Compression

Go, Python, and Node.js traces condensed to cause + top frame.

Smart Truncation

Head + tail preservation ensures errors and summaries are never cut.

Pattern Learning

Teach GoTK project-specific noise patterns for custom filtering.

Works with your AI tools

One-line setup for the most popular LLM coding assistants

Claude Code

Native PreToolUse hook

gotk install claude

Aider

Shell proxy

SHELL=gotk aider

Cursor

Terminal profile

SHELL=gotk cursor .

Continue.dev

Context provider

config: shell: gotk -c

Real-world benchmarks

Measured on real command output — verify yourself with gotk bench

pnpm test
98%
grep -rn
95%
git log
90%
find
70%
ls -la
51%

Average reduction: 87.5% across real-world workloads

Get started in 30 seconds

1

Install

$ go install github.com/antikkorps/GoTK/cmd/gotk@latest
2

Set up your tool

$ gotk install claude

Or see integrations for Aider, Cursor, Continue.dev

3

Use it

$ gotk grep -rn "TODO" .

Or pipe: go test ./... | gotk --stats