waymark-mcp
OfficialClick on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@waymark-mcpWho calls verifySignature in src/index.ts?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Waymark Engine 🧭
Sub-millisecond AST structural & lexical BM25 code intelligence for AI coding agents.
Ask your codebase a question in plain English. Get an exact answer — file, symbol, and line span — in milliseconds, without paying 10,000–50,000 tokens of blind context-window re-reading.
Built for AI coding agents: one-shot discovery, zero required background processes (no daemon required; optional resident daemon for warm <10ms lookups), no vector index, and strictly deterministic zero-embedding recall.
Core Principles
Deterministic by Construction: Every query path is zero-randomness. Semantic recall uses pure lexical BM25 (
@paragon-ux/capn-hook) and hard-refuses embedding stores (CAPN_NON_DETERMINISTIC_MODE).Fail-Closed Defense: When structural or literal tiers miss, the Discovery Junction emits a machine-readable recommendation or clean miss. It never guesses.
Two-Verb MCP Interface: Consolidates all discovery and maintenance into
waymark_askandwaymark_memory, slashing tool context overhead to <450 tokens (vs. 3,000+ for flat tool catalogs).Sub-Millisecond Speed: In-memory
PrefixTrieand warm AST call graphs answer queries in<10mswith warm daemon IPC.
Related MCP server: Serena
Architectural Division of Responsibilities
AI Coding Agent
│
┌──────────────┴──────────────┐
│ │
waymark_ask waymark_memory
(Read & Discover) (Write & Consensus)
│ │
┌───────────────┼───────────────┐ │
▼ ▼ ▼ ▼
Tier 1 Tier 2 Tier 3 Tier 4
AST Call Graph Path Router Fuzzy Matcher Lexical BM25
(@paragon/codedb) (PrefixTrie) (algo.go fzf) (capn-hook)
│ │ │ │
└───────────────┼───────────────┘ │
▼ ▼
Discovery Junction Consensus SQLite
(deterministic miss) (5-facet memory)Quickstart
Requires Node.js 22+.
# 1. Install globally or as a project dependency
npm install -g waymark-engine
# 2. Initialize the deterministic lexical store (.waymark/memory)
waymark memory init
# 3. Query the codebase using Verb 1 (waymark ask)
waymark ask "Who calls verifyHop?" # Tier 1 exact structural call graph
waymark ask "verifyHop" --depth 2 --exclude-tests # Bounded BFS excluding test files
waymark ask --symbols User,Service,ApiWorker # Concurrent batch symbol definitions
waymark ask --path src/types.ts # Single-file structured AST outline
waymark ask "verfyHop" # Discovery Junction recommendation
waymark ask "verifyHop" --plain # Token-minimal LLM output (~16-38 tokens)Live REPL Observer & Web Viewer
Launch the interactive REPL with real-time SSE telemetry and browser viewer on port 4141:
waymark repl --live --port 4141Open the access URL printed by the REPL to observe query executions, tier breakdowns, and cache hits in a viewport-locked layout. Run /battery in the REPL to execute prompt evaluations. The URL contains a random session token; keep it private.
The live observer binds to 127.0.0.1, requires explicit telemetry opt-in with WAYMARK_TELEMETRY=1, and checks the session token on the dashboard and telemetry endpoints. It rejects mismatched Host or Origin headers and blocks framing. Persistent query/session logs are disabled by default. Do not expose the local viewer through a public interface.
Semantic Repo Map and Platform Limits
waymark memory bootstrap collects source excerpts as unverified drafts; it does not publish architectural claims or initialize a Capn store. Verify each claim against its cited code, then publish it explicitly with waymark memory chart. Subsystem-scoped discovery and maps are not supported; requests that include --subsystem or subsystem return UNSUPPORTED_SUBSYSTEM.
On Windows, WAYMARK_CODEDB_EXECUTABLE must name a native executable. .cmd and .bat shims are rejected with CODEDB_UNSUPPORTED_SHIM because Waymark never invokes external tools through a shell.
Language Support & Tier Fallbacks
Single-File AST Outlines (
waymark ask --outline --path <file>):In-Process
web-tree-sitter(Exact line + column spans): TypeScript (.ts,.tsx,.mts,.cts), JavaScript (.js,.jsx,.mjs,.cjs), Python (.py), JSON (.json), TOML (.toml), YAML (.yaml,.yml), Bash (.sh,.bash,.zsh), C# (.cs), Scala (.scala), Lua (.lua), Zig (.zig), Elixir (.ex,.exs), Solidity (.sol), Rust (.rs), Go (.go), Java (.java), C (.c,.h), C++ (.cpp,.hpp,.cc,.cxx), Ruby (.rb), Swift (.swift), Kotlin (.kt), and PHP (.php).Native Markdown Parser (
markdown-it): Markdown (.md,.markdown,.mdx) document structure (h1–h6sections, headings, code blocks).Polyglot
codedb outlineFallback: Secondary fail-safe for supported compiled languages (.rs,.go,.java,.c,.cpp,.rb,.swift,.kt,.php) if WASM grammar is unavailable in host environment.Fail-Closed Boundary: Unsupported extensions (e.g.
.dartdue to ABI 15 incompatibility,.sql) and dialect extensions (.jsonc,.json5) fail closed withUNSUPPORTED_LANGUAGE.
Repo-Wide Call Graph & Symbol Search (
waymark ask "<symbol>"):Indexed via
@paragon-ux/codedb-coreacross.ts,.tsx,.js,.jsx,.py,.rs,.go,.java,.rb,.swift,.kt(plus partial.c/.cpp/.php), supplemented by in-processweb-tree-sitterrepo-wide indexing for.mjs,.cjs,.mts,.cts, and.toml.
Language-Agnostic Tiers (Tiers 2, 3, and 4):
Tier 2 (
PrefixTriePath Router), Tier 3 (fzfFuzzy Matcher), and Tier 4 (.waymark/memoryBM25 Consensus Memory & 5-Facet Semantic Repo Map) operate across all repository files regardless of language.
Comprehensive Documentation
For complete technical references, architectural specifications, and benchmark analyses, visit our Zensical Documentation Site:
📖 Getting Started: Installation, CLI flags, background daemon, and the Live REPL Observer.
🏗️ 4-Tier Architecture: Deep dive into AST call graphs, literal paths, Junegunn Choi
fzf, and BM25 consensus.🔌 Model Context Protocol (MCP): Two-Verb interface (<450 tokens), setup for Google Antigravity, Claude Desktop, and Cursor.
💻 CLI & Command Registry: Full canonical command reference,
waymark memoryaction catalog, and exit codes.🧭 Examples: Recorded runs of the
architectural-map,explore-subsystem, andbootstrap-semantic-mapMCP prompts against this repository.📊 Empirical Benchmarks: Steelmanned Aider Repo Map parity benchmark (
gpt-oss-120b) and metrics schema.📦 Library API & Integrity: TypeScript SDK,
verifyHop,anchorForRange, and fail-closed invariant guards.
Local Documentation Server
Build or preview the documentation locally using Zensical:
# Build static site
py -3.11 -m zensical build
# Serve live preview on localhost:8000
py -3.11 -m zensical serveLicense
MIT. See LICENSE for details.
This server cannot be deployed
Maintenance
Related MCP Connectors
Codebase intelligence for agents: 152 structured artifacts across 21 programs, one call.
Code intelligence for coding agents: semantic, AST, graph, and full-text search. 279+ languages.
Code intelligence platform for AI agents. 20 tools for architecture, security & impact analysis.
AI-powered spec-to-task decomposition and execution orchestration for coding agents.
Related MCP Servers
- AlicenseBqualityDmaintenanceA coding agent toolkit that provides IDE-like semantic code retrieval and editing tools, enabling LLMs to efficiently navigate and modify codebases using symbol-level operations instead of basic file reading and string replacements.19MIT
- AlicenseAqualityDmaintenanceA coding agent toolkit that provides IDE-like semantic code retrieval and editing tools, enabling LLMs to efficiently navigate and modify codebases at the symbol level rather than working with entire files.29MIT
- AlicenseNot gradedqualityCmaintenanceProvides semantic code search and retrieval capabilities for AI agents, enabling them to query codebases using natural language with automatic learning, hybrid search, and intelligent chunking of functions and classes.3 npm31ISC
- AlicenseNot gradedqualityCmaintenanceEnables AI coding agents to query a pre-built semantic knowledge graph of code, reducing token usage and tool calls. Supports 16 tools for code exploration, analysis, and context building.16 npm8MIT