SkillAgentSearch skills...

cortex-ast

A powerful Model Context Protocol (MCP) server and Omni-AST engine. It empowers AI agents to seamlessly parse complex codebases, execute secure cross-project operations, and dynamically fetch token-optimized rules.

Install / Use

claude mcp add cortex-works -- npx -y github:cortex-works/cortex-ast

If the server publishes to npm under a different name, use that package instead — check the repo README.

About this skill
🔌

MCP Server

Model Context Protocol server

Quality Score

78/100

Supported Platforms

Claude Code
Claude Desktop
Cursor
Zed

Our assessment of cortex-ast

cortex-ast scores 78/100 on our quality scale, 796th of 947 AI & Machine Learning skills we index.

Its MCP Server is 6.7 KB long, well organised into 29 sections with 7 code examples: a thorough specification that gives an agent plenty to work with.

It has 10 GitHub stars, so there is little community track record yet; judge it on its content.

Substance
29/30
Structure
20/20
Description
15/15
Adoption
4/20
Freshness
11/15

Maintenance, license and trust

  • The repository was last updated about 9 months ago. That is recent enough to be usable, but agent tooling moves fast, so check the instructions against your agent's current version.
  • It is released under the MIT license, a permissive license that allows use, modification and commercial use with attribution.
  • Its trust signals score 91/100, with 1 caution from licensing, adoption, age or documentation. These come from repository metadata, not a code audit — read the skill file before letting an agent act on it.

Safety scan

No issues found

Our scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands. An AI review of the same text found nothing harmful.

AI review by kimi-k2.7-code on 2026-11-14. Automated pattern scan on 2026-11-14. It catches known dangerous patterns, not every risk — read a skill before letting an agent act on it.

cortex-ast compared with similar skills

All 4 of these similar skills score higher than cortex-ast; compare them before choosing.

SkillScoreStarsUpdatedFormat
cortex-ast (this skill)by cortex-works78109mo agoMCP Server
claude-memby thedotmack100117.6ktodayCLAUDE.md
Agent-Reachby Panniantong100112.3k8d agoCLAUDE.md
Understand-Anythingby Egonex-AI10092.8k1d agoCLAUDE.md
rufloby ruvnet10081.9ktodayCLAUDE.md

Frequently asked questions

How do I install cortex-ast?
Run claude mcp add cortex-works -- npx -y github:cortex-works/cortex-ast. The install tabs above show the steps for each supported agent.
Which AI agents does cortex-ast work with?
It is written for Claude Code, Claude Desktop, Cursor and Zed, as a MCP Server file. Other agents that read the same format can often use it too.
Is cortex-ast safe to use?
Our scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands. An AI review of the same text found nothing harmful. It is MIT-licensed and scores 91/100 on trust signals. Skills are instructions an agent will follow, so read the file before installing it and do not approve commands you do not understand.
Is cortex-ast still maintained?
The repository was last updated about 9 months ago. That is recent enough to be usable, but agent tooling moves fast, so check the instructions against your agent's current version.

CortexAST 🧠⚡

The AI-Native Code Intelligence Backend for LLM Agents Pure Rust · MCP Server · Semantic Code Navigation · AST Time Machine · Self-Evolving Wasm Parsers

Rust License: MIT Version


What is CortexAST?

👁️ CortexAST is the "eyes" — read-only code intelligence. For write/execute capabilities, see the companion cortex-act project (the "hands").

CortexAST is a production-grade MCP (Model Context Protocol) server that gives AI coding agents (Claude, Gemini, GPT-4o, etc.) the ability to:

  • Navigate codebases semantically — find symbols, blast-radius analysis, cross-file propagation checklists
  • Evolve itself — download and hot-reload WebAssembly language parsers at runtime (Go, PHP, Ruby, Java, …)
  • Time-travel your codebase — Chronos snapshot system for pre/post-refactor AST-level comparison
  • Search local memory — hybrid semantic + keyword search over your codebase history

✋ To edit files, run commands, or patch configs, use cortex-act instead.


Feature Modules

1. 🔭 cortex_code_explorer

Codebase explorer. Use INSTEAD of ls/tree/find/cat. Two modes: map_overview (fast symbol map, near-zero tokens — run first on any repo) and deep_slice (token-budgeted XML with function bodies, vector-ranked by query). Use map_overview to orient; deep_slice to get code for editing.

2. 🎯 cortex_symbol_analyzer

AST symbol analysis. Use INSTEAD of grep/rg. Actions: read_source (extract exact source of a symbol from a file — do this before editing), find_usages (all call/type/field sites), find_implementations (structs implementing a trait), blast_radius (callers + callees — run before rename/delete), propagation_checklist (exhaustive update checklist for shared types).

3. ⏳ cortex_chronos

AST snapshot tool for safe refactors. Workflow: save_checkpoint (before edit) → edit → compare_checkpoint (verify). Use instead of git diff — AST-level, ignores formatting noise. Actions: save_checkpoint, list_checkpoints, compare_checkpoint, delete_checkpoint.

4. 🛠️ run_diagnostics

Run compiler diagnostics (cargo check / tsc / gcc). Call after any code edit to catch errors before proceeding. Returns file, line, code, message — structured for targeted fixes.

5. 🧠 cortex_memory_retriever

Search past agent decisions in global memory (semantic + keyword hybrid). Requires CortexSync. Call BEFORE any research or exploration — the answer may already be cached. Returns ranked entries: intent, decision, tags, files_touched.

6. 📋 cortex_get_rules

Fetch codebase AI rules for the current context. Requires CortexSync. Returns merged rules filtered by file_path (frontend/backend/db context). Call before starting any task in a new project.

7. ✨ cortex_remember

Save task outcome to permanent global memory. Requires CortexSync. Call at END of every task. intent+decision must be ≤200 chars each. For long artifacts write a file first and pass path via heavy_artifacts.

8. 🌍 cortex_list_network

List all AI-tracked codebases (Requires CortexSync network). Use to discover target_project IDs for cross-project operations.

9. 🌐 cortex_manage_ast_languages

Manage Wasm grammar parsers for non-core languages. Core (always active): rust, typescript, python. Call status to see active/available languages. Call add with languages[] to download and hot-reload parsers from GitHub tree-sitter releases. Available: go, php, cpp, c, c_sharp, java, ruby, dart.


Ecosystem Requirement: CortexSync 🧠

For full functionality, CortexSync (the "Brain") must be running in the background.

| Tool | Dependent on CortexSync? | Why? | |---|---|---| | cortex_remember | Yes | Persists task outcomes to the global journal. | | cortex_memory_retriever| Yes | Performs semantic vector search over past decisions. | | cortex_get_rules | Yes | Fetches centralized rules from the synchronized rule engine. | | cortex_list_network | Yes | Reads the global network map of codebases. | | cortex_code_explorer | No | Local AST analysis. | | cortex_symbol_analyzer | No | Local AST analysis. |

If cortex-sync is offline, these tools will strictly return a graceful warning without interrupting the agent's workflow.



Quick Start

Prerequisites

  • Rust 1.80+
  • Ollama or LM Studio running locally (optional, for Auto-Healer)

Build & Run

git clone https://github.com/DevsHero/CortexAST
cd CortexAST
cargo build --release

# Run as MCP server (stdio)
./target/release/cortexast

MCP Config (~/.cursor/mcp.json or Claude Desktop)

{
  "mcpServers": {
    "cortexast": {
      "command": "/path/to/cortexast",
      "args": []
    }
  }
}


Usage Examples

Semantic Explorer — Bird's-eye view of a project

{
  "name": "cortex_code_explorer",
  "arguments": {
    "action": "map_overview",
    "target_dir": "."
  }
}

Symbol Search — Find all usages across the repo

{
  "name": "cortex_symbol_analyzer",
  "arguments": {
    "action": "find_usages",
    "symbol_name": "AuthService",
    "target_dir": "."
  }
}

Time Travel — Compare AST after refactor

{
  "name": "cortex_chronos",
  "arguments": {
    "action": "compare_checkpoint",
    "symbol_name": "login",
    "tag_a": "pre-refactor",
    "tag_b": "__live__"
  }
}

Self-Evolving Wasm Language Support

| Always Available | Downloadable on Demand | |---|---| | Rust, TypeScript/JS, Python | Go, PHP, Ruby, Java, C, C++, C#, Dart |

# Agent calls this automatically when it detects a new language:
cortex_manage_ast_languages { "action": "add", "languages": ["go", "dart"] }

Development

# Run all unit tests
cargo test

# Check (no link)
cargo check

---

## Architecture

CortexAST (binary) └── src/ ├── server.rs # MCP stdio server — all tool schemas + handlers ├── inspector.rs # LanguageConfig, LanguageDriver, Symbol, run_query ├── grammar_manager.rs # Wasm download + hot-reload (GitHub releases) ├── vector_store.rs # model2vec embeddings + cache invalidation ├── chronos.rs # AST snapshot time machine (Chronos) ├── memory.rs # global_memory.jsonl journal client └── project_map.rs # Network map for multi-repo roaming



## License

MIT — See [LICENSE](./LICENSE)

---

*Built with ❤️ in Rust · Semantic precision for the AI age*

Related Skills

View on GitHub
GitHub Stars10
CategoryAI
Updated8mo ago
Forks4

Languages

Rust

Trust signals

91/100

From repository metadata: license, adoption, age and documentation. Not a code audit — see the Safety scan above for what the skill file itself contains.

1 low1 info