Zero-Latency Go Crash Isolation. Instant Gemini AI Diagnosis.
Intercepts Go HTTP server panics non-blockingly using defer + recover. Automatically isolates the enclosing *ast.FuncDecl code block, queries Gemini AI for root causes, and files GitHub issues with drop-in patches.
See How Triage Isolates Crashes in Real Time
Select a real Go panic scenario below and see how the engine extracts the enclosing AST node, sends it to Gemini AI, and generates actionable fixes.
func ProcessTransaction(w http.ResponseWriter, r *http.Request) {
var req *PaymentPayload
// Attempting to access struct field without initialization:
if req.Amount <= 0 { // <--- PANIC TRIGGER [LINE 28]
http.Error(w, "invalid amount", http.StatusBadRequest)
return
}
executeTransfer(req)
}ProcessTransaction instead of all 450 lines in the source file. This saves 94% in LLM token cost while preserving complete semantic context.How Triage Delivers Sub-Millisecond Panic Isolation
Designed from the ground up for high-throughput production Go microservices without background database pre-indexing.
Panic Interception
Standard Go defer + recover() hooks intercept HTTP panics. Captures debug.Stack() and immediately releases the client response.
Async Bounded Queue
Telemetry is dispatched to an asynchronous 4-worker pool backed by a 1,000-job buffer. Zero impact on server throughput.
On-Demand AST Slicing
The engine retrieves the exact commit file and parses the AST to isolate only the enclosing *ast.FuncDecl code node.
Gemini AI Diagnostics
AST code snippet + sanitized panic metadata are sent to Gemini AI for deterministic root-cause analysis and patch generation.
GitHub Issue & Studio
Persists to PostgreSQL, streams live to Studio Dashboard, and optionally files a GitHub issue with formatted stack traces and diffs.
Multi-Layered AST Resolution
Triage avoids heavy full-codebase pre-indexing by resolving AST nodes on demand using a layered caching architecture.
Hot AST cache storing parsed FuncDecl trees in engine memory.
Pre-indexed ast_nodes table lookup by repository and commit SHA.
Fetches raw source via GitHub Contents API and parses on the fly.
Engineered for High-Reliability Go Systems
Everything you need to intercept, symbolicate, diagnose, and resolve Go panics without adding latency or managing heavyweight agent sidecars.
AST Node Isolation
Extracts only the surrounding *ast.FuncDecl code block enclosing the panicking line using Go’s standard go/parser. Eliminates 94% of irrelevant source code.
Non-Blocking Async Dispatch
Middleware captures panics with defer + recover and dispatches telemetry across a bounded 4-goroutine worker pool. Zero latency added to HTTP client responses.
Gemini AI Diagnostics
Leverages Google Gemini AI with deterministic structured JSON schemas to deliver precise root-cause analysis and drop-in Git patches using your configured model.
Automated GitHub Issue Filing
Seamlessly creates GitHub issues in your repository containing formatted AST code blocks, raw stack traces, Gemini diagnostic summaries, and triage labels.
Single-Container Self-Hosting
Deploy the full platform with 1 single Docker container (triage/engine:latest). The engine serves REST APIs, telemetry receivers, and the Studio Dashboard UI.
Zero-Trust Secret Scrubbing
Sanitizes HTTP headers, query parameters, Authorization tokens, cookies, and database connection strings before sending panic telemetry payloads.
Integrate with Any Go Router in Under 60 Seconds
Triage works as standard Go http.Handler middleware. Drop it into your existing HTTP routers without refactoring.
package main
import (
"net/http"
triage "github.com/algotyrnt/triage/sdk/go"
)
func main() {
mux := http.NewServeMux()
mux.HandleFunc("/api/process", func(w http.ResponseWriter, r *http.Request) {
w.Write([]byte("Process completed successfully"))
})
// Wrap your mux with triage panic isolation middleware
handler := triage.Middleware(
"tr_live_key_9042",
triage.WithRepo("myorg/myrepo"),
triage.WithGatewayURL("https://triage.yourcompany.com/api/v1/telemetry"),
)(mux)
http.ListenAndServe(":8080", handler)
}GitHub repository for on-demand AST fetching.
Custom engine endpoint for self-hosted instances.
Explicit Git commit SHA override for AST matching.
Engineered for Extreme Efficiency
Triage isolates crashes with negligible server overhead while reducing LLM diagnostic token consumption by over 93%.
Average HTTP handler latency overhead per request
Tokens sent per incident with AST FuncDecl isolation
Peak resident set size for 10,000 requests/sec
Everything You Need to Know
Common architectural and operational questions regarding Triage panic isolation.