Przejdź do treści
Biblioteka skilli
Programowanie · Budowanie i kod

code-simplification

/code-simplification

Upraszcza kod dla czytelności bez zmiany zachowania, gdy kod działa, ale jest trudniejszy do czytania, utrzymania lub rozszerzania, niż powinien.

Repozytorium
ai-eng-system ↗
Licencja
MIT
Ostatnia zmiana repozytorium
09.08.2026

Ocena i bezpieczeństwo

90/ 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ść25 / 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 09.08.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

Upraszcza kod dla czytelności bez zmiany zachowania, gdy kod działa, ale jest trudniejszy do czytania, utrzymania lub rozszerzania, niż powinien.

Oryginalny opis (EN)

Simplifies code for clarity without changing behavior. Use when code works but is harder to read, maintain, or extend than it should be.

Jak działa

  1. Overview
  2. When to Use
  3. Core Rules
  4. Simplification Process
  5. Common Rationalizations
  6. Red Flags
  7. Verification
  8. Anti-Rationalization Table
Sekcje z nagłówków SKILL.md, w oryginale · 99 linii, 548 słów
Podgląd SKILL.md
---
name: code-simplification
description: Simplifies code for clarity without changing behavior. Use when code works but is harder to read, maintain, or extend than it should be.
---

# Code Simplification

Adapted from `addyosmani/agent-skills` (MIT), commit `82ceff41ed4d3c644e3dcca8a0514390b2911223`.

## Overview

Simplify code by reducing complexity while preserving exact behavior. The goal is not fewer lines; it is faster comprehension, safer maintenance, and easier review.

## When to Use

- After a feature works but feels heavier than necessary
- During review when readability or duplication issues show up
- When code has deep nesting, unclear names, or scattered logic
- After a rushed implementation that now needs cleanup

## Core Rules

### Preserve Behavior Exactly

Do not change outputs, side effects, ordering, or error behavior. If you are not sure a simplification is behavior-preserving, stop and gather more context first.

### Follow Project Conventions

Simplification should make code more consistent with the repository, not more consistent with personal taste.

### Prefer Clarity Over Cleverness

Avoid dense ternaries, over-generalized abstractions, and compressed logic that requires a second reading.

### Scope to What Changed

Default to simplifying the code you are already touching. Avoid unrelated cleanup unless explicitly asked.

## Simplification Process

### Step 1: Understand Before Changing

Apply Chesterton's Fence.

- What is this code responsible for?
- Why might it have been written this way?
- What tests define its current behavior?

### Step 2: Identify the Simplification

Look for:

- deep nesting
- long functions with mixed responsibilities
- duplicate logic
- generic or misleading names
- wrappers or abstractions that add no value

### Step 3: Apply Small Changes

Make one simplification at a time and verify after each one.

- simplify the control flow
- extract a well-named helper
- inline an unnecessary wrapper
- remove dead code only when you understand it

### Step 4: Re-evaluate the Whole

After the refactor, ask whether a new teammate would understand the new version faster than the old one.

## Common Rationalizations

| Rationalization | Reality |
|---|---|
| "Fewer lines is always simpler" | A dense one-liner can be harder to understand than a clear five-line block. |
| "I will simplify this unrelated code while I am here" | Drive-by refactors create noisy diffs and hidden regression risk. |
| "This abstraction might be useful later" | Speculative abstractions are complexity without current value. |

## Red Flags

- Tests need to change just to preserve the simplification
- Error handling disappears because it looks noisy
- Renames follow personal taste instead of repo conventions
- The simplified version is harder to review than the original

## Verification

- [ ] Existing tests still pass without semantic changes
- [ ] Build succeeds
- [ ] No error handling was weakened
- [ ] Diff stays focused on the targeted simplification

## Anti-Rationalization Table

| Excuse | Counter |
|--------|---------|
| "Fewer lines is always simpler" | A dense one-liner can be harder to understand than a clear five-line block. |
| "I'll simplify this unrelated code while I'm here" | Drive-by refactors create noisy diffs and hidden regression risk. |
| "This abstraction might be useful later" | Speculative abstractions are complexity without current value. |
| "The code works, why touch it" | Working code that is hard to understand is a maintenance liability. |
| "I'll add tests after simplifying" | Simplification without tests risks silently changing behavior. Tests first. |

Wersje

RepozytoriumWynikLicencja
Ta strona · v1truv1us/ai-eng-system90MIT
TerminalSkills/skills100Apache-2.0
FrancoStino/opencode-skills-collection100MIT
sanity-io/sanity100MIT
BlackBeltTechnology/pi-agent-dashboard100MIT
sickn33/agentic-awesome-skills100MIT
muhammadshaharyarnaeem/blackgoat-agentskills100MIT
patrickdappollonio/claude-plugins100MIT
samplexbro/agentsmesh100MIT

Identyczna treść występuje jeszcze w 1 innych folderach na GitHubie. Tu pokazujemy jedną, najlepiej ocenioną kopię.

Migawka bazy z 28.10.2026 · wersja paczki 37db65c84550 (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

  • 100code-simplifier
    Upraszcza kod dla czytelności i utrzymywalności bez zmiany zachowania, gdy krok przepływu pracy lub użytkownik o to prosi.
  • 100code-simplifier
    Upraszcza kod dla czytelności i utrzymywalności bez zmiany zachowania, gdy krok przepływu pracy lub użytkownik o to prosi.
  • 90simplify
    Upraszcza kod dla przejrzystości bez zmiany działania, gdy zachowanie jest już zrozumiałe, i zmniejsza złożoność.
  • 100simplifying-code
    Upraszcza, wygładza i porządkuje kod bez zmiany zachowania: usuwa martwy kod i ślady AI, poprawia czytelność, także w raportach tylko z analizą.
  • 100code-simplifier
    Upraszcza kod dla czytelności, spójności i utrzymywalności z zachowaniem dokładnego działania, redukuje złożoność i porządkuje ostatnie zmiany wzorcami refaktoryzacji.
  • 90simplification-pass
    Usuwa złożoność, która się nie zwraca: martwy kod, zbędne abstrakcje, zduplikowaną logikę i nieużywaną konfigurację, bez zmiany zachowania.

Uwagi i zgłoszenia

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