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 See the difference
Real command output — before and after GoTK
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. >> 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 { === RUN TestAdd
--- PASS: TestAdd (0.00s)
=== RUN TestSubtract
--- PASS: TestSubtract (0.00s)
=== RUN TestMultiply
multiply_test.go:15: expected 42, got 41
--- FAIL: TestMultiply (0.00s)
=== RUN TestDivide
--- PASS: TestDivide (0.00s)
=== RUN TestDivideByZero
divide_test.go:28: expected error for division by zero
--- FAIL: TestDivideByZero (0.01s)
FAIL
FAIL github.com/example/math 0.023s
ok github.com/example/strings 0.015s
ok github.com/example/utils 0.008s
ok github.com/example/config 0.012s
ok github.com/example/models 0.019s --- FAIL: TestMultiply (0.00s)
multiply_test.go:15: expected 42, got 41
--- FAIL: TestDivideByZero (0.01s)
divide_test.go:28: expected error for division by zero
FAIL github.com/example/math 0.023s
ok 4 packages: strings, utils, config, models Sending build context to Docker daemon 15.87kB
Step 1/8 : FROM golang:1.21-alpine AS builder
---> abc123def456
Step 2/8 : WORKDIR /app
---> Running in 1234567890ab
Removing intermediate container 1234567890ab
---> 2345678901bc
Step 3/8 : COPY go.mod go.sum ./
---> Running in 3456789012cd
Removing intermediate container 3456789012cd
Step 4/8 : RUN go mod download
---> Running in 5678901234ef
Removing intermediate container 5678901234ef
Step 5/8 : COPY . .
Step 6/8 : RUN CGO_ENABLED=0 go build -o /app/server
---> Running in 9012345678cd
Removing intermediate container 9012345678cd
Step 7/8 : FROM alpine:3.19
Step 8/8 : COPY --from=builder /app/server /server
---> Running in bbccddee2233
Removing intermediate container bbccddee2233
Successfully built ccddee334455
Successfully tagged myapp:v1.2.3 --- FROM golang:1.21-alpine AS builder ---
WORKDIR /app
COPY go.mod go.sum ./
RUN go mod download
COPY . .
RUN CGO_ENABLED=0 go build -o /app/server
--- FROM alpine:3.19 ---
COPY --from=builder /app/server /server
Successfully tagged myapp:v1.2.3 npm warn deprecated inflight@1.0.6: This module is not supported
npm warn deprecated glob@7.2.3: Glob versions prior to v9 are no longer supported
npm warn deprecated rimraf@3.0.2: Rimraf versions prior to v4 are no longer supported
added 247 packages in 12s
12 packages are looking for funding
run `npm fund` for details
6 vulnerabilities (2 moderate, 4 high)
To address all issues, run:
npm audit fix
Run `npm audit` for details. deprecated: 3 packages (inflight, glob, rimraf)
added 247 packages in 12s
6 vulnerabilities (2 moderate, 4 high) 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 grep -rn git log find ls -la Average reduction: 87.5% across real-world workloads
Get started in 30 seconds
Install
$ go install github.com/antikkorps/GoTK/cmd/gotk@latest Set up your tool
$ gotk install claude Or see integrations for Aider, Cursor, Continue.dev
Use it
$ gotk grep -rn "TODO" . Or pipe: go test ./... | gotk --stats