SuperAPIAI Directory

ctxfw vs autogen

Metrics & specs comparison

ctxfw

ctxfw is a local context firewall and Tree-Sitter AST pruning MCP server for AI coding agents. It strips indirect prompt injection from untrusted MCP tool output before the context enters the LLM, and compresses peripheral dependencies into typed interfaces, thereby reducing token consumption (officially claimed to reduce peripheral context token mass by about 72.4%). The tool runs fully offline, with no cloud proxy, no vector database, and no telemetry, and provides its service via local stdio. Main features include: syntax-aware AST compression (keeping the focus file intact, trimming imported dependencies into typed interface contracts, and generating a compact symbol index), pre-ingestion tool and input sanitization (SARA, mcp_guard, supporting multiple languages and detection of homoglyphs, bidirectional override characters, path traversal, etc.), spec checking and diff gating (SWE-Gate, TraceKit, requiring formal specs to include negative invariants, etc., and recording a local audit chain). It provides a standalone zero-Python executable (v4.2.2) supporting Linux, macOS, and Windows, and can configure Claude Code, Claude Desktop, Cursor, and Windsurf with a single idempotent command. It is suitable for scenarios where AI coding agents read code repositories or call MCP tools, helping to reduce token bloat, prevent prompt injection, and enhance diff reliability. Limitations include: AST skeletonization does not replace LSP's cross-file semantic type resolution; deterministic CPU sanitization may produce false positives; strict diff gating may reject certain types of ignore comments.

Dimensionctxfwautogen
CategoryAI codingAI coding
Pricing开源项目(可免费自部署)GitHub 开源项目 · 61,962 Stars
PlatformsmacOS · Linux—
GitHub stars— 61,962
Up/Down to navigate · Enter to open · ESC to closeBrowse all tools