Przejdź do treści
Biblioteka skilli
Programowanie · Analiza

code-analysis

/code-analysis

Buduje zrozumienie całej bazy kodu lub podsystemu: co robi, jak jest zbudowana i gdzie koncentruje się ryzyko oraz złożoność, i raportuje to jako mapę do działania.

Repozytorium
skillz ↗
Licencja
MIT
Ostatnia zmiana repozytorium
25.10.2026

Ocena i bezpieczeństwo

100/ 100Klasa: dobry
Format25 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść35 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
1
Skrypty
0
Komentarze HTML
0
Adresy URL w SKILL.md
0
Przestarzałość

Brak sygnałów. Repozytorium zmienione 25.10.2026, bez odwołań do wycofanych modeli i API.

Licencja

MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.

Co robi i kiedy

Buduje zrozumienie całej bazy kodu lub podsystemu: co robi, jak jest zbudowana i gdzie koncentruje się ryzyko oraz złożoność, i raportuje to jako mapę do działania.

Oryginalny opis (EN)

Builds an understanding of a whole codebase or subsystem — what it does, how it is structured, where the risk and complexity concentrate, and reports it as a map someone can act on. Use this whenever the user is new to a repo, inherits unfamiliar code, asks how something works end to end, wants an architecture overview or health assessment, or is deciding whether to refactor, extend, or replace. For reviewing a specific change, use code-review.

Jak działa

  1. 1. Read the outside before the inside
  2. 2. Find the spine
  3. 3. Let the repository tell you where the risk is
  4. 4. Assess structure honestly
  5. 5. Report as a map with a recommendation
  6. Rules
Sekcje z nagłówków SKILL.md, w oryginale · 105 linii, 766 słów
Podgląd SKILL.md
---
name: code-analysis
description: Builds an understanding of a whole codebase or subsystem — what it does, how it is structured, where the risk and complexity concentrate, and reports it as a map someone can act on. Use this whenever the user is new to a repo, inherits unfamiliar code, asks how something works end to end, wants an architecture overview or health assessment, or is deciding whether to refactor, extend, or replace. For reviewing a specific change, use code-review.
license: MIT
---

# Code analysis

The output is a **map**: what exists, how it fits together, and where the danger is. A map is
judged by whether someone can navigate with it, not by how much of the territory it mentions.

Analysis fails by exhaustiveness — describing every module at equal depth produces a document
with the same information density as the source, and no reason to read it. Depth must be
unequal, concentrated where the risk and the change is.

## 1. Read the outside before the inside

Before opening source files, read what the project says about itself and what it demonstrably
does: README, entry points, public API or route definitions, configuration, CI pipeline,
dependency manifest, and the shape of the test suite.

This gives you the intended architecture. The gap between it and the real one is a finding.

**Done when:** you can state what the system does, who calls it, and what it calls.

## 2. Find the spine

Every codebase has a small number of paths that carry most of the value. Trace one all the way
through — a request from entry to response, a job from trigger to side effect.

Follow it end to end before branching. The spine teaches you the project's real conventions,
its layering, and where its abstractions leak, far faster than reading modules in isolation.

**Done when:** you can narrate one complete path through the system, naming each hop.

## 3. Let the repository tell you where the risk is

History is evidence and costs almost nothing to gather. Where change concentrates, risk
concentrates.

```bash
git log --format=%H --since="1 year ago" | wc -l
git log --name-only --format= --since="1 year ago" | sort | uniq -c | sort -rn | head -20
```

Cross-reference the churn list against size and test coverage. The intersection — **large,
frequently changed, poorly tested** — is where incidents come from, and it is the most valuable
paragraph in your report.

Also worth a look: files changed by many different authors (shared, so conventions drift), and
files changed by exactly one author who has left.

**Done when:** you have a ranked list of hotspots grounded in history, not impression.

## 4. Assess structure honestly

- **Layering:** is there one, is it enforced, and where is it violated? A single import that
  crosses layers is a defect; a hundred means the layering is aspirational and should be
  described as such.
- **Coupling:** what would you have to touch to change one behaviour? Concepts defined in more
  than one place are where bugs get half-fixed.
- **Boundaries:** where does the system talk to the outside? Those are the places that fail,
  and the places that constrain change.
- **Dead code:** unreferenced modules, unreachable branches, flags permanently on. Note it;
  deleting it is the cheapest available improvement.
- **Tests:** what do they actually cover? Look at what they assert, not the coverage number. A
  suite that exercises everything and asserts nothing is worse than none, because it is trusted.

**Done when:** each dimension has a stated finding, including "fine, no action".

## 5. Report as a map with a recommendation

```markdown
# <System> — analysis

**What it does:** one paragraph, no jargon
**Shape:** the 4–6 components that matter and how they connect

## The spine
The main path, hop by hop, with file references.

## Hotspots
| Area | Churn | Size | Tests | Why it matters |

## Structural findings
Ranked. Each: what it is, what it costs today, what it will cost later.

## If you change one thing
The single highest-value change, and why it beats the alternatives.

## Not covered
What was out of scope, and what remains unknown.
```

Use `path/to/file.py:120` references throughout. A map without coordinates is an essay.

**The "not covered" section is mandatory.** An analysis that does not state its own limits gets
read as complete, and its silence gets read as approval.

## Rules

- **Depth follows risk.** The hot, untested, load-bearing module deserves ten times the words
  of a stable utility. Equal depth is a failure of analysis, not a sign of thoroughness.
- **Separate observation from judgment.** "Auth logic appears in three modules" is observation.
  "This should be consolidated" is judgment, and the reader is entitled to weigh them apart.
- **Report what you did not read.** Nobody reads a large codebase completely. Which parts you
  skipped changes how much the reader should trust the conclusions.
- **Do not recommend a rewrite casually.** It is almost always the wrong answer, and proposing
  it costs you credibility on the recommendations that would actually help.

Wersje

RepozytoriumWynikLicencja
Ta strona · OKHP3/skillz100MIT
managedcode/dotnet-skills100MIT
alexandrbasis/claudops100MIT
alexandrbasis/claudops100MIT
Dqz00116/skill-lib100MIT
abbaye/wpfhexeditoride85AGPL-3.0

Migawka bazy z 28.10.2026 · wersja paczki 71f6d0712166 (skrót SHA-256 całej paczki)

Pobrania w ostatnich 30 dniach: 0 · ranking

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 100codebase-analysis
    Tworzy ustrukturyzowany raport z analizy bazy kodu: przegląd architektury, krytyczne pliki, wzorce i rekomendacje do wykonania.
  • 100codebase-analysis
    Tworzy ustrukturyzowany raport z analizy bazy kodu: przegląd architektury, krytyczne pliki, wzorce i rekomendacje do wykonania.
  • 100code-reading
    Prowadzi strategiczne czytanie nieznanej bazy kodu przed zmianą: zrozumienie działania, praca ze starym kodem, złożone debugowanie i code review.
  • 100complexity-reduction
    Mierzy złożoność kognitywną i duplikaty kodu przez PMD (Java) lub rust-code-analysis-cli (Rust), a potem zmniejsza je przez wyciąganie kodu bez zmiany zachowania, mierząc po każdym kroku.
  • 86explore
    Buduje dokładny obraz nieznanego kodu, funkcji lub obszaru przed zmianą: gdzie leży, jak się łączy i co robi.
  • 100k-explore
    Wyjaśnia działanie podsystemu, śledzi przepływ w runtime, wskazuje miejsce dla nowego kodu i odtwarza z historii git, dlaczego coś zbudowano, tylko do odczytu.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.