code-intelligence
代码仓库智能问答工具(repo_symbol_answer v1)。Tree-sitter AST 召回 function/class/method/interface/variable 定义 + ripgrep 词法搜索 + reranker 精排 + palette:mid LLM 综合,输出含…
Skill by maxesisn
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/maxesisn-code-intelligence
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: ml
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
- Runs as
- Node.js package
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/code-intelligence
What's inside
- Skill name
code-intelligence- Description
- 代码仓库智能问答工具(repo_symbol_answer v1)。Tree-sitter AST 召回 function/class/method/interface/variable 定义 + ripgrep 词法搜索 + reranker 精排 + palette:mid LLM 综合,输出含 file:line + evidence_type 的引用回答。比手动 grep + 文件阅读自助导航快、有结构化输出。
- License
- MIT
- Instructions
- 84 lines in SKILL.md · view on GitHub
Before installing
- Ships executable scripts
Files (3)
- SKILL.md
- tools.test.ts
- tools.ts
SKILL.md (first lines)
# code-intelligence — `repo_symbol_answer` v1
把"对某个代码仓库的自然语言问题"映射到"带引用的回答 + 结构化 source",跟 kb_answer 是同一抽象的代码仓库版本。
## 接口
```ts
repo_symbol_answer({
question: string, // 自然语言
repo_path: string, // 当前 turn 所在机器上的仓库绝对路径
options?: {
paths?: string[], // 限定 glob (默认 全 repo)
languages?: ('ts'|'js'|'py'|'go')[], // 限定语言(默认全部)
max_sources?: number, // 默认 6, max 12
answer_style?: 'concise'|'default'|'detailed',
}
})
→ {
success: true,
repo_path, question,
answer, confidence: 'high'|'medium'|'low',
sources: [{
file_path, // 仓库根目录相对路径
line_range: [start, end],
excerpt,
evidence_type: 'definition'|'reference'|'call'|'grep', // AST symbol kind 或 lexical
symbol?: string, // 涉及的符号名
score,
}],
diagnostics: { retrieval_counts, used_llm, used_reranker, low_score, latency_ms, ast_parsed_files }
}
| { success: false, error, code: 'REPO_NOT_FOUND'|'REPO_EMPTY'|'INVALID_REPO'|'INTERNAL_ERROR' }
```
## v1 scope
支持:
- 语言:TypeScript / JavaScript / Python / Go(复用 `src/ast/` 已有 grammar wasm)
- AST kind:function / method / class / interface / variable 定义;call expression(reference 弱版本);import
- Lexical fallback:ripgrep on `*.{ts,tsx,js,jsx,py,go}`,覆盖 prose / comment / config / string literals
- 文件枚举:gitignore-aware(`.git`, `node_modules`, `dist`, `build`, `__pycache__` 等 default skip)
- LLM synthesis:palette:mid,evidence type hierarchy(AST definition > AST call > grep)
- Reranker + sigmoid 归一化 + no-hit cutoff
- pickDiverse: score-first when reranker used
不支持(v2+):
- Cross-file 真 reference search(需要 type inference,LSP 才能精确)
- 概念级 embedding 搜索("实现 feature Y 在哪")
- 多语言比 v1 多
- Watcher / 预建 index(v1 on-demand 解析 + 进程内 cache)
## Worker 执行位置
`repo_symbol_answer` 是 `runtime: 'local'` 工具:主体 turn 在主体本机检索,worker turn
在对应 worker 本机检索。`repo_path` 必须是当前 turn 所在机器可见的绝对路径,不能拿
主体路径去查 worker,也不能拿 worker 路径转回主体。
工具里的 palette:mid 综合仍复用当前进程的 `LLMRouter`。worker 的 provider 是
`RemoteLLMProvider`,因此只有 LLM call 会透明转回主体;`stat`、`rg`、tree-sitter 和
源码读取都留在 worker 本机。worker 没有真实 `MemoryManager` 时,可选 reranker 跳过,
不影响 AST + grep 检索和 LLM 综合。
## 名字为什么是 "symbol_answer" 而不是 "answer"
v1 初版实测后明确:retrieval 强烈依赖 query 里**显式出现 ASCII symbol identifier**(function/class/variable/type 名)。三类 query 实测对照:
| query 类型 | 例 | v1 表现 |
|---|---|---|
| **Symbol lookup** | "buildToolContext 在哪定义" / "X 接受什么参数" / "Y 类有哪些方法" | ✅ excellent,AST 直击定义 + 全部引用 |
| **Concept / "怎么决定"** | "sub-agent 怎么决定 backend" | ❌ AST 0 hit(symbol 不在 query 里),LLM 只能从 grep noise 综合,confidence medium 且不完整 |
| **Pattern 广覆盖** | "哪些 skill 是 centralized" | ❌ LLM 只看 top 6 chunk,错过全部 matched files |
所以工具名带 "symbol" 反映真实 capability:**这是 symbol-level 快速通道,不是通用 code QA**。
非 symbol 类查询(concept、pattern、跨文件 trace)应该派 `spawn_subagent` 做 multi-step navigation。
## 跟 sub-agent 边界
- **repo_symbol_answer**:1 个 tool call,5-15s,几千 token。Symbol 必须在 query 里。
- **spawn_subagent**:multi-step navigation + 推理。30s-5min,几万 token。Concept / pattern / 跨文件 trace / 没有显式 symbol 的 query 都走这条。
不确定哪条:先 repo_symbol_answer 试,低 confidence + diagnostics.retrieval_counts.ast_def=0 时升级到 sub-agent。From maxesisn/maxclaw-oss, MIT.
More from maxesisn/maxclaw-oss
- 0.526score
knowledge-base
maxesisn
通用知识库构建 & 查询工具。给定一个包含 PDF/Sphinx-HTML 的原始文档文件夹,批量转成可 grep 的 Markdown、抽符号倒排、生成 LLM 摘要 sidecar 和 manifest 聚合索引。Agent 进入陌生领域时先 `ls ~/.maxclaw/kb/` 看有无相关知识库,再按"L3…
SkillBFreshness: BClaude Code +9 - 0.521score
web-search
maxesisn
搜索互联网获取实时信息,通过自建 search-proxy 聚合 Tavily/Brave/Jina 三家付费 provider(带配额管理 + 失败 fallback 到 SearXNG)。适用于:查询新闻、实时价格、技术文档、不在训练数据中的信息。
SkillBFreshness: BClaude Code +9 - 0.521score
seek-advice
maxesisn
跨家 LLM 顾问 panel——给一个最小化 scenario,并行 dispatch 给 3-5 个不同 vendor 的模型,每个模型同时跑联网+离线两份,对抗单家族 prior 高度相关导致的 anchoring 偏差。用于复杂诊断、重要技术决策、自己推理 ≥2 小时未收敛兜底。
SkillBFreshness: BClaude Code +9 - 0.521score
pinned-notes
maxesisn
显式标记当前对话中需要永久保留的关键事实(必要开支、风险偏好、核心约束等),让它在 session compact/rollover 后仍存活。Agent 主动判断"哪些信息长期重要"调用,跨 session 通过 6 字符短 pin_id 引用。单 session 上限 25 条。
SkillBFreshness: BClaude Code +9 - 0.520score
reflection
maxesisn
自主反思与行动——静默处理能处理的,把该 Max 决策的记上面板
SkillBFreshness: BClaude Code +9 - 0.519score
channel-notes
maxesisn
Channel-scoped working notes — a short Markdown document per channel for decisions, deferred items, open questions, and next steps.
SkillBFreshness: BClaude Code +9 - 0.518score
workdir
maxesisn
声明当前 channel 正在使用的工作目录(可多个),显示在右侧 Workspace 卡并在压缩后可查回。多文件任务时用 set_workdirs 钉下工作目录,避免文件散落 /tmp 或每次重说。仅记录+展示,不改进程 cwd。
SkillBFreshness: BClaude Code +9 - 0.518score
async-runtime
maxesisn
需要未来唤醒、后台等待、跨 channel 通知或长期订阅时的调度选择;覆盖 cron、后台 subagent、notification、channel_subscribe、wake_channel。
SkillBFreshness: BClaude Code +9 - 0.518score
wake-channel
maxesisn
跨 channel agent 通信原语——通过 wake_channel "按门铃"通知另一个 channel 的 agent 有新状态变化
SkillBFreshness: BClaude Code +9 - 0.517score
notifications
maxesisn
持久化事件通知层 + topic-based pub-sub。所有 cron / sub-agent / mail / 价格异动等事件写入 SQLite 并按 channel 订阅 fan-out。channel 通过 channel_subscribe 声明关心哪些 topic;同时所有事件无条件 union…
SkillBFreshness: BClaude Code +9 - 0.515score
browser
maxesisn
浏览器控制能力,通过 CDP 连接系统 Brave,支持导航、截图、快照、点击、输入等操作
SkillBFreshness: BClaude Code +9 - 0.515score
cron
maxesisn
管理定时任务(cron jobs),支持添加、删除、列出、立即执行
SkillBFreshness: BClaude Code +9
Signals
- Stars
- 0
- Forks
- 0
- Open issues
- 0
- Last commit (this folder)
- Aug 9, 2026 (2 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- MIT
- Repository
- github.com/maxesisn/maxclaw-oss
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from maxesisn
- 0.526score
knowledge-base
maxesisn
通用知识库构建 & 查询工具。给定一个包含 PDF/Sphinx-HTML 的原始文档文件夹,批量转成可 grep 的 Markdown、抽符号倒排、生成 LLM 摘要 sidecar 和 manifest 聚合索引。Agent 进入陌生领域时先 `ls ~/.maxclaw/kb/` 看有无相关知识库,再按"L3…
SkillBFreshness: BClaude Code +9 - 0.521score
web-search
maxesisn
搜索互联网获取实时信息,通过自建 search-proxy 聚合 Tavily/Brave/Jina 三家付费 provider(带配额管理 + 失败 fallback 到 SearXNG)。适用于:查询新闻、实时价格、技术文档、不在训练数据中的信息。
SkillBFreshness: BClaude Code +9 - 0.521score
seek-advice
maxesisn
跨家 LLM 顾问 panel——给一个最小化 scenario,并行 dispatch 给 3-5 个不同 vendor 的模型,每个模型同时跑联网+离线两份,对抗单家族 prior 高度相关导致的 anchoring 偏差。用于复杂诊断、重要技术决策、自己推理 ≥2 小时未收敛兜底。
SkillBFreshness: BClaude Code +9 - 0.521score
pinned-notes
maxesisn
显式标记当前对话中需要永久保留的关键事实(必要开支、风险偏好、核心约束等),让它在 session compact/rollover 后仍存活。Agent 主动判断"哪些信息长期重要"调用,跨 session 通过 6 字符短 pin_id 引用。单 session 上限 25 条。
SkillBFreshness: BClaude Code +9 - 0.520score
reflection
maxesisn
自主反思与行动——静默处理能处理的,把该 Max 决策的记上面板
SkillBFreshness: BClaude Code +9 - 0.519score
channel-notes
maxesisn
Channel-scoped working notes — a short Markdown document per channel for decisions, deferred items, open questions, and next steps.
SkillBFreshness: BClaude Code +9
Cite this page
code-intelligence skill. Agent Mart. https://agentmart.dev/skills/maxesisn-code-intelligence (last updated 2026-10-24)