nexus-mapper

nexus-mapper is a skill for Claude Code, Codex from Haaaiawd/ANWS. It costs 118 tokens per session (3,767 once invoked), scanned A, original, MIT.

A process for examining a code repository and creating a persistent map of its architecture, dependencies, systems, and areas likely to be affected by changes. The map gives future AI sessions a quick way to understand the project.

In plain words
What is it for?
Use it when beginning work on an unfamiliar repository, preparing a major refactor, or creating an AI-readable project knowledge base. It inspects supported source files and Git history when available.
Why use it?
Starting work in an unfamiliar repository often requires repeating the same exploration. A stored map reduces that repeated investigation and supports onboarding or large refactors.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions CLAUDE.md; installed under .agents/ (shared by several agents); mentions AGENTS.md.

Good fit Use it when beginning work on an unfamiliar repository, preparing a major refactor, or creating an AI-readable project knowledge base. It inspects supported source files and Git history when available.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/haaaiawd/anws/nexus-mapper
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add Haaaiawd/ANWS --skill nexus-mapper
Clone the repo
git clone --depth 1 https://github.com/Haaaiawd/ANWS

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for nexus-mapper

README.md
[![agentmods](https://agentmods.dev/badge/skills/haaaiawd/anws/nexus-mapper.svg)](https://agentmods.dev/skills/haaaiawd/anws/nexus-mapper)
Your own site
<a href="https://agentmods.dev/skills/haaaiawd/anws/nexus-mapper"><img src="https://agentmods.dev/badge/skills/haaaiawd/anws/nexus-mapper.svg" alt="Measured on agentmods" height="20"></a>
Per session 118 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,767 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00118 $0.03767
Opus 5 $0.00059 $0.01884
Sonnet 5 $0.00024 $0.00753
Haiku 4.5 $0.00012 $0.00377

Measured 8d ago against content hash ecb04c601595, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

nexus-mapper scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

The scan reads SKILL.md. This mod also ships 3 executable files (scripts/extract_ast.py, scripts/git_detective.py, scripts/query_graph.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

src/anws/templates/.agents/skills/nexus-mapper/SKILL.md · 322 lines

How it starts

The opening of the file, as written. The whole thing — 322 lines — stays where its author put it; the contents beside it link to each section on GitHub.

nexus-mapper — AI 项目探测协议

本 Skill 指导 AI Agent 使用 PROBE 五阶段协议,对任意本地 Git 仓库执行系统性探测,产出 .nexus-map/ 分层知识库。


何时调用 / 何时不调用

场景 调用
用户提供本地 repo 路径,希望 AI 理解其架构
需要生成 .nexus-map/INDEX.md 供后续 AI 会话冷启动
用户说「帮我分析项目」「建立项目知识库」「让 AI 了解这个仓库」
运行环境无 shell 执行能力(纯 API 调用模式,无 run_command 工具)
宿主机无本地 Python 3.10+
目标仓库无任何已知语言源文件(.py/.ts/.java/.go/.rs/.cpp 等均无)
用户只想查询某个特定文件/函数 → 直接用 view_file / grep_search

前提检查

缺失项要显式告知用户;需要降级等时及时提醒用户,经过同意才能继续。

前提 检查方式
目标路径存在 $repo_path 可访问
Python 3.10+ python --version >= 3.10
脚本依赖已安装 python -c "import tree_sitter" 无报错
有 shell 执行能力 Agent 环境支持 run_command 工具调用

git 历史是加分项,不是硬阻塞项。没有 .git 或历史过少时,跳过热点分析,并在输出中明确记录这是一次降级探测。


输入契约

repo_path: 目标仓库的本地绝对路径(必填)

语言支持:自动按文件扩展名 dispatch,语言配置(扩展名映射 + Tree-sitter 查询)存储在 scripts/languages.json。当前已接入 Python/JavaScript/TypeScript/TSX/Bash/Java/Go/Rust/C#/C/C++/Kotlin/Ruby/Swift/Scala/PHP/Lua/Elixir/GDScript/Dart/Haskell/Clojure/SQL/Proto/Solidity/Vue/Svelte/R/Perl 等 30+ 语言。

非标准语言:若仓库含有内置未支持的语言,通过命令行参数动态补充(详见 references/language-customization.md):

  • --add-extension .templ=templ 添加新文件扩展名映射
  • --add-query templ struct "(component_declaration ...)" 添加结构查询
  • --language-config <JSON_FILE> 复杂配置时使用 JSON 文件

输出格式

执行完成后,目标仓库根目录下将产出:

.nexus-map/
├── INDEX.md                    ← AI 冷启动主入口(< 2000 tokens)
├── arch/
│   ├── systems.md              ← 系统边界 + 代码位置
│   ├── dependencies.md         ← Mermaid 依赖图 + 时序图
│   └── test_coverage.md        ← 静态测试面:测试文件、覆盖到的核心模块、证据缺口
├── concepts/
│   ├── concept_model.json      ← Schema V1 机器可读图谱
│   └── domains.md              ← 核心领域概念说明
├── hotspots/
│   └── git_forensics.md        ← Git 热点 + 耦合对分析
└── raw/
    ├── ast_nodes.json          ← Tree-sitter 解析原始数据
    ├── git_stats.json          ← Git 热点与耦合数据
    └── file_tree.txt           ← 过滤后的文件树

Read the full file on GitHub · 322 lines

Files

What ships with it

8 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 322 lines · 118 tokens per session scan A ecb04c601595

Subscribe to this mod's changes

nexus-mapper is a skill published in the GitHub repository Haaaiawd/ANWS (142 stars, last pushed 3mo ago), licensed MIT. It adds 118 tokens to every session and 3,767 once invoked, about $0.0006 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

tldr-compress

Compress natural language memory files (CLAUDE.md, todos, preferences) into TLDR format to save input tokens. Preserves all technical substance, code, URLs, and structure. Compressed version overwrites the original file. Human-readable backup saved as FILE.original.md. Trigger: /tldr-compress FILEPATH or "compress…

0p9b/TLDR · 75 tokens

ai-engineering-toolkit

6 production-ready AI engineering workflows: prompt evaluation (8-dimension scoring), context budget planning, RAG pipeline design, agent security audit (65-point checklist), eval harness building, and product sense coaching.

sickn33/agentic-awesome-skills · 47 tokens

ai-agents-architect

Expert in designing and building autonomous AI agents. Masters tool use, memory systems, planning strategies, and multi-agent orchestration.

sickn33/agentic-awesome-skills · 31 tokens

verification-planning

Verification planning for non-trivial coding work. Use before implementing a feature, bug fix, refactor, cross-system change, or high-confidence behavior change that needs a credible project-specific evidence path.

alvinunreal/oh-my-opencode-slim · 43 tokens

loop-engineering

Loop engineering runtime Grill + Monitor.

alvinunreal/oh-my-opencode-slim · 10 tokens

session-summaries

What the chat right-panel session summary shows, what it costs, and how to make a session summarize well. Load when the user asks about the session summary panel, why a summary looks wrong or empty, or how to turn it on.

kirodotdev/KiroCrew · 53 tokens