Documentation
README
代码关系图 · abyss
不是搜索工具,是代码的调用图 + 时间智能。通过 shell 调用
abyssCLI。
前置
进入项目时,检查并初始化索引:
command -v abyss >/dev/null && [ ! -f .code-abyss/index.db ] && abyss index
核心行为
改文件前:跑 abyss context
即将修改任何代码文件时,先获取该文件的完整上下文(不需要知道函数名):
abyss context <要修改的文件路径> --json
返回:该文件所有函数的外部调用方、依赖的类型和函数、热点评分、耦合文件。
根据返回结果:
- 有 production callers:检查改动是否会破坏调用方,改完逐个同步
- hotspot score > 5000:高风险文件,跑
abyss impact <func> --json深入分析 - impact risk > 7/10:跟用户确认方案后再改
- 有 uncovered paths:提醒用户补测试
- 有 coupled files:检查耦合文件是否需要同步修改
其他场景
| 场景 | 命令 |
|---|---|
| 初识项目架构 | abyss map --json |
| 追查 bug 来源 | abyss history <file> --symbol <func> --json |
| 搜索代码(比 grep 好) | abyss search "关键词" --json |
输出说明
--json 输出结构化 JSON,agent 直接解析。不加 --json 输出人类可读文本。
This is the opening of the README. Read the full README on GitHub.