| name | impact-lens |
| description | Use when starting or doing any work that touches a project's code or features — to know "what does this code affect (will affect / did affect / was affecting)" BEFORE changing it, and to load the relevant prior completed work so you don't reinvent or contradict it. Reads a per-project derived knowledge catalog (docs/catalog.json) and, once per session per topic, dispatches a subagent that returns a pointer-brief (file:line + verbatim critical constraints, decisions, acceptance-criteria) instead of bloating context. Supports forward queries (feature → affected paths) and reverse queries (path → features/decisions that touched it). Triggers on "what does this affect", "neye etki ediyor / etti / ediyordu", "bu kodu kim kullanıyor", "bu değişiklik neyi kırar", starting a feature, editing a tagged module, "load prior work on X", "impact-lens", "/impact-lens". |
Impact Lens
The point of this skill: before and while you touch code, you must be able to answer three questions — and ask them out loud:
| Soru | Ne demek | Nereden |
|---|
| Etki edecek | Bu değişiklik neyi kıracak/etkileyecek? | catalog affects reverse-lookup + ilgili decision/constraint |
| Etti | Bu kod/feature geçmişte neye dokundu? | catalog forward-lookup + biten PRD/verify |
| Ediyordu | Şu an neyi etkiliyor, hangi feature'a ait? | catalog reverse-lookup (path → features) |
Bilgi zaten projede var ama dağınık. Bu skill onu tek deterministik catalogtan okutur ve doğru anda yüzeye çıkarır — context'i şişirmeden.
Önkoşul
Proje kökünde docs/catalog.json (makine) + docs/CATALOG.md (insan) bulunur. Yoksa veya bayatsa:
python3 scripts/build_catalog.py
catalog.json türetilmiştir (el ile yazılmaz) → bağımsız sapamaz. Generator ayrıştıramadığı dökümanı sessizce atlamaz, untagged listesine yazar ve bağırır (fail-loud).
catalog.json şeması (bilmen gereken)
{
"generated_at": "...", "source_count": N,
"untagged": ["docs/...md", ...],
"features": [{
"slug": "oauth-token-broker",
"topic": ["mcp","auth","oauth"],
"type": ["decision","artifact"],
"status": "shipped", "date": "2026-05-28",
"affects": ["app/mcp/credentials.py","table:mcp_user_credentials"],
"links": { "prd": "...", "verify": "...", "review": "...", "decisions": ["..."], "memory": "..." },
"constraints": [{ "text": "iki token tablosu var; legacy'ye dokunma", "cite": "docs/PRD-...#C-1" }]
}]
}
Akış (zorunlu sıra)
Bir görev geldiğinde veya bir dosyayı editlemeden önce:
- Scope çıkar — görevden/dosyalardan topic(ler) + dokunulan kod yolu/tablo.
- Catalog sorgula (oku/grep
docs/catalog.json):
- forward: feature →
affects (ne etkiler)
- reverse: dosya yolu → onu
affects'inde taşıyan feature'lar + onların decisions/constraints
- Session-gate —
tasks/.loaded-topics.json kontrol: (topic, görev-hash) bu oturumda yüklendi mi?
- Aynı topic + benzer görev → dedup (tekrar okuma).
- Aynı topic + farklı görev → yeni brief çek. Asla bastırma.
- Yüklenmemişse → SUBAGENT ile pointer-brief (Explore/general-purpose):
- Prompt'a catalog'dan ilgili
links + constraints cite'larını koy.
- İste: "Özet DEĞİL. Her kritik kısıtın
dosya:satır + BİREBİR alıntısı, biten AC'ler, ilgili decision'lar, bu işin dokunduğu kod yolları. ≤250 kelime."
- Dönen brief'i oku;
(topic, görev-hash)'i loaded işaretle.
- Impact cevabını yüzeye çıkar — kullanıcıya/kendine: "Bu [paths]'e dokunuyor; geçmişte [features] etkiledi; [decisions] geçerli."
- Verify — yeni işi brief'e karşı doğrula. Körlemesine devam etme. Yeni iş kayıtlı bir
decision/constraint ile çelişiyorsa DUR + flag: ⚠ [decision-slug] ile çelişiyor.
Doğrudan sorgu modu ("sorabilmeli")
Kullanıcı "mcp credential'a ne dokunuyor?" / "bu dosyayı kim kullanıyor?" derse: adım 2'yi tek başına çalıştır, cevabı affects + links ile ver. Brief gerekiyorsa adım 4.
Sınırlar (fail-loud, sıfır-bakım)
- Catalog asla "tamım" demez: cevaba her zaman
untagged sayısını iliştir ("N döküman henüz etiketsiz" — kaçırma riski şeffaf).
- Brief işaretçi döner, özet değil — keskin kısıt (ör. "iki token tablosu") yuvarlanmaz.
- Generator parse edemezse hata verir; sessiz eksik üretmez.
- Faz 1 kapsamı budur. Şunlar henüz YOK (Faz 2): editi bloklayan sert
PreToolUse kapısı, otomatik çelişki taraması, UserPromptSubmit oto-tetik. Şimdilik bu skill manuel/description-tetikli + SessionStart enjeksiyonu ile çalışır.