# 代码库AI无效？先建知识图谱

- 来源：Rohan Paul (@rohanpaul_ai)
- 发布时间：2026-07-24 07:20
- AIHOT 分数：42
- AIHOT 链接：https://aihot.virxact.com/items/cmry508ni00f3rozr9blv37gv
- 原文链接：https://x.com/rohanpaul_ai/status/2080432858590797936

## AI 摘要

针对“AI在代码库上无效”的常见抱怨，关键在于跳过上下文获取。一个团队先构建知识图谱覆盖整个仓库的模块、依赖、数据流和领域术语，再让AI智能体按“定义范围→写技术规范→规划→实现→测试→更新图谱”的循环工作。两名工程师用此方法在3.5个月内重建了FedEx供应商的交付平台（原估8个月），90天合并122个PR，AI生成90%代码，计算成本仅$200/月。

## 正文

"AI doesn't work on our codebase."

I hear this weekly. Same problem： they skipped context acquisition.

They pointed an agent at a repo， handed it a ticket， and got code that compiles but misunderstands the architecture.

One team built the context layer first. Two engineers rebuilt a FedEx supplier's delivery platform in 3.5 months when the original estimate was eight.

Week one， they wrote zero code. They scanned the entire repo into a knowledge graph covering modules， dependencies， data flows， and domain terms. Agents read that map before touching anything.

Every ticket ran this loop：
1. Define scope and constraints
2. Write a technical spec
3. Plan the implementation
4. Agent implements， engineer reviews
5. Test against the spec
6. Update the knowledge graph

Nothing merged unless the engineer could verify it， explain it， and debug it without the agent.

The team merged 122 PRs in 90 days with AI generating 90% of the code at $200/month in compute.

Map your repo into a knowledge graph and run this loop before you hand the agent open-ended tasks.

I recommend you to follow @mardehaym.

He runs @LimestoneHQ and posts production AI breakdowns like this.

### 引用推文

> Mark Ajzenstadt：http://x.com/i/article/2079482473818333184
