Logo: Pdd Entropy Reduction

Pdd Entropy Reduction

Communautéit
wonderslife
pdd-entropy-reduction

PDD Entropy Reduction Agent, dee kontinuéierlech technesch Scholden iwwerwaacht an ofbaut, fir de Verfall vum System ze verhënneren. Gëtt automatesch ausgeléist, wann de Code opgeraumt, d'Dokumentatioun aktualiséiert, technesch Scholden geréiert, d'Architektur ausgeriicht, d'Entropie reduzéiert oder de Systemmüll opgeraumt soll ginn. Haaptzil: d'„Entropiezounam“ an de „Verfall“ vum System bekämpfen, andeems reegelméisseg Agenten ausgefouert ginn, déi Inkonsistenzen an der Dokumentatioun oder Verstéiss géint Architekturvorgaben fannen. Ausléiser: - De Benotzer freet: „Entropie reduzéieren“, „technesch Scholden opraumen“, „Code opraumen“ oder „Systemmüll opraumen“ - De Benotzer freet, d'Konsistenz tëscht Dokumentatioun a Code ze iwwerpréiwen - De Benotzer freet, d'Architekturvorgaben ze iwwerpréiwen - De Benotzer freet en Audit vun technesche Scholden - Geplangten Ausléiser (eemol d'Woch recommandéiert) - Automateschen Ausléiser no engem Code-Commit (optional) - Automateschen Ausléiser no enger PR-Zesummeféierung (optional) 支持中文触发:熵减、清理技术债务、代码清理、文档更新、技术债务管理、架构对齐、垃圾回收、PDD熵减。

Iwwersiicht

Editeurwonderslife
Repositorypdd-skills
Skill-Nummpdd-entropy-reduction
Stären
41
Forks
11
Matgeliwwert Dateien
3
LizenzMIT
Linken
  • Instruktiounen am Markdown-Format

    Eng SKILL.md-Datei, déi de Modell bei Bedarf luet, soudatt nëmmen Token ufalen, wann eng Ufro tatsächlech dozou passt.

  • Funktionéiert mat all LLM

    KI-Skills si reng Markdown, keen ubidderspezifesche Code. Dofir funktionéiert dëse Skill mat GPT, Claude, Gemini, Grok oder engem lokale Modell.

  • 3 matgeliwwert Dateien

    Skripten, Virlagen a Referenzen, déi de Modell beim Schaffe liese kann. D'Dateie kënnen nëmme gelies ginn a ginn ni ausgeféiert.

  • Open Source

    wonderslife huet de Skill op GitHub verëffentlecht. Liest de Quelltext, ier Dir de Skill installéiert.

Installatioun

Installéiert de KI-Skill Pdd Entropy Reduction an TypingMind, fir e mat all LLM ze benotzen, oder setzt en an en anere KI-Agent an, deen SKILL.md liest.

1

An TypingMind installéieren

TypingMind installéiert e Skill direkt aus sengem GitHub-Dossier — dobäi gëtt SKILL.md gelies, d'Ressourcedateie gi gebëndelt an d'Resultat gëtt lokal gespäichert.

  1. Maacht d'App op a gitt op Plugins → Skills.
  2. Wielt „Vu GitHub installéieren“.
  3. Pecht d'URL vum Skill-Dossier, déi hei drënner steet, an a bestätegt d'Installatioun.
    https://github.com/wonderslife/pdd-skills/tree/main/pdd-entropy-reduction
  4. Aktivéiert de Skill an all Chat, an deem Dir e benotze wëllt.
Plugins → Skills → Skill derbäisetzen → Iwwer eng GitHub-URL. Pecht dann d'URL vum Dossier an a klickt op Weider.
2

An engem anere KI-Agent installéieren

All KI-Agent, deen d'Format Agent Skills liest, kann dëse Skill benotzen — kopéiert den Dossier an d'Skill-Verzeechnes vun deem KI-Agent.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/wonderslife/pdd-skills.git /tmp/pdd-skills
mkdir -p .claude/skills
cp -r /tmp/pdd-skills/pdd-entropy-reduction .claude/skills/pdd-entropy-reduction
Start Claude Code nom Kopéieren nei, fir datt den neie Skill erkannt gëtt.

An TypingMind benotzen

Aktivéiert Pdd Entropy Reduction an engem Chat vun TypingMind, an de Modell iwwerhëlt de Rescht. Den Numm an d'Beschreiwung stinn am System-Prompt. Soubal eng Ufro dozou passt, luet de Modell déi komplett Instruktioune selwer — Dir musst de Skill ni manuell opruffen, an et fale keng Token un, bis en tatsächlech benotzt gëtt.

De Modell luet Pdd Entropy Reduction automatesch, soubal eng Ufro dozou passt.

Funktionéiert mat all KI-Modell

KI-Skills si reng Markdown-Instruktiounen amplaz vun ubidderspezifeschem Code. Dofir ass Pdd Entropy Reduction net un de Modell gebonnen, fir deen de Skill geschriwwe gouf. Installéiert en eemol an TypingMind a benotzt e mat GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder engem lokale Modell, deen Dir selwer bedreift — alles mat Ären eegenen API-Schlësselen.

  • Gëtt nëmme gelueden, wann et néideg ass

    De System-Prompt enthält nëmmen den Numm an d'Beschreiwung. D'Instruktioune gi bei der éischter passender Ufro gelueden, soudatt en onbenotzte Skill näischt kascht.

  • De Modell am lafende Chat wiesselen

    Well de Skill aus Instruktiounen amplaz vu Code besteet, funktionéiert en och no engem Modellwiessel — den nächste Modell liest déi selwecht SKILL.md-Datei.

Skill-Instruktiounen

Dëst ass den Inhalt vu SKILL.md, deen de Modell luet. Liest e virun der Installatioun — e Skill besteet aus Instruktiounen, déi Äre Modell befollegt.

PDD Entropy Reduction Agent

Core Philosophy

"Technical debt is like a high-interest loan: it's better to continuously repay the debt in small amounts than to let it accumulate and then painfully resolve it all at once." —— OpenAI Harness Engineering

In the PDD (PRD-Driven Development) methodology, the core objective of the entropy reduction mechanism is to combat system "entropy increase" and "decay" by periodically running agents to discover documentation inconsistencies or architecture constraint violations.

Natural Trend of Entropy Increase

Entropy Increase (Natural Trend):
- Code decay: Duplicate code, overly long functions, inconsistent naming
- Documentation obsolescence: Code and documentation out of sync, outdated comments
- Technical debt accumulation: Unhandled TODOs, unoptimized temporary solutions
- Architecture drift: Violating dependency directions, blurred boundaries
- Test deficiency: Decreasing coverage, outdated tests

Entropy Reduction (Requires Energy Input):
- Refactoring: Eliminate duplication, simplify complexity
- Documentation updates: Synchronize documentation with code
- Technical debt repayment: Handle TODOs, optimize temporary solutions
- Architecture alignment: Fix violations, strengthen boundaries
- Test supplementation: Increase coverage, update tests

Four Professional Sub-Skills

The entropy reduction agent coordinates four professional sub-skills to form a complete entropy reduction closed loop:

┌─────────────────────────────────────────────────────────────┐
│                  pdd-entropy-reduction                       │
│                      (Main Coordinator)                      │
├─────────────────────────────────────────────────────────────┤
│                                                             │
│  ┌─────────────┐  ┌─────────────┐  ┌─────────────┐  ┌─────────────┐│
│  │ pdd-doc-    │  │ expert-arch │  │ expert-     │  │ expert-auto ││
│  │ gardener    │  │ -enforcer   │  │ entropy-    │  │ -refactor   ││
│  │             │  │             │  │ auditor     │  │             ││
│  │ Document    │  │ Architecture│  │ Entropy     │  │ Auto        ││
│  │ Gardener    │  │ Enforcer    │  │ Auditor     │  │ Refactor    ││
│  └─────────────┘  └─────────────┘  └─────────────┘  └─────────────┘│
│                                                             │
└─────────────────────────────────────────────────────────────┘

1. pdd-doc-gardener (Document Gardener)

Responsibility: Periodically scans the docs/ directory in the code repository to identify outdated or deprecated documentation that no longer reflects actual code behavior.

Detection Items:

  • Code and documentation inconsistency
  • Outdated comments (TODOs existing for more than N days)
  • Code referenced in documentation has been deleted
  • API documentation doesn't match implementation

Action: When documentation is found to be out of sync with implementation, automatically initiate a Pull Request for fixes.

2. expert-arch-enforcer (Architecture Constraint Enforcer)

Responsibility: Monitors whether code violates preset invariants and architecture boundaries.

Detection Items:

  • Module dependency direction violations (e.g., Types → Config → Repo → Service → Runtime → UI)
  • Missing boundary data validation
  • File size exceeding limits
  • Naming convention violations

Tool Integration: Utilizes custom Linters or structural tests (like ArchUnit), running periodically in the background to scan for deviations.

3. expert-entropy-auditor (Entropy Increase Auditor)

Responsibility: Discovers gaps between "design intent" and "code implementation".

Detection Items:

  • PRD and code implementation inconsistency
  • Spec documentation and code inconsistency
  • Duplicate code (AI residue)
  • Guessed data structures
  • Scattered utility tools

Function: Like a garbage collector, identifies "AI residue" scattered in the codebase and recommends consolidating them into shared utility packages.

4. expert-auto-refactor (Automated Refactoring)

Responsibility: Transforms collected quality improvement tasks into concrete code operations.

Strategy: Periodically initiates targeted refactoring PRs using a "small loan repayment" approach to prevent technical debt accumulation.

Refactoring Types:

  • Extract common methods
  • Eliminate duplicate code
  • Simplify complex logic
  • Optimize naming

Workflow

Entropy Reduction Execution Process

┌─────────────┐     ┌─────────────┐     ┌─────────────┐     ┌─────────────┐
│   Trigger   │ ──→ │   Scan      │ ──→ │   Analyze   │ ──→ │   Execute   │
│             │     │             │     │             │     │             │
│ • Manual    │     │ • Doc scan  │     │ • Entropy   │     │ • Auto fix  │
│ • Scheduled │     │ • Code scan │     │   score     │     │ • Create PR │
│ • Event     │     │ • Arch scan │     │ • Classify  │     │ • Update    │
│             │     │             │     │ • Prioritize│     │   docs      │
└─────────────┘     └─────────────┘     └─────────────┘     └─────────────┘

Entropy Score System

Entropy score range: 0-100 (100 = most orderly)

Score RangeStatusRecommended Action
90-100ExcellentMaintain current state
70-89GoodSmall improvements
50-69FairPlanned cleanup
30-49WarningPriority handling
0-29CriticalEmergency refactoring

Execution Guide

Step 1: Entropy Detection

Based on user request or trigger condition, select appropriate detection scope:

  1. Full Detection: Scan all entropy increase points
  2. Documentation Detection: Only scan documentation-related issues
  3. Architecture Detection: Only scan architecture constraint violations
  4. Code Detection: Only scan code quality issues

Step 2: Generate Entropy Report

Use references/entropy-report-template.md to generate entropy report, including:

  • Entropy score
  • Issue list (sorted by priority)
  • Fix recommendations
  • Estimated workload

Step 3: Entropy Reduction Execution

Select execution strategy based on issue type:

Issue TypeExecution MethodManual Confirmation
Simple fixes (naming, formatting)Auto fix and commitNo
Medium fixes (documentation updates)Create PRYes
Complex fixes (refactoring)Create Issue + PRYes

Integration with PDD Framework

PDD Forward Process                      PDD Entropy Reduction Process
    │                                     │
    ▼                                     ▼
┌─────────────┐                    ┌─────────────┐
│ PRD Document │                    │ Entropy     │
├─────────────┤                    │ Detection   │
│ Feature     │                    ├─────────────┤
│ Extraction  │                    │ Entropy     │
├─────────────┤                    │ Report      │
│ Spec Design │                    ├─────────────┤
├─────────────┤                    │ Entropy     │
│ Code        │  ←───────────────  │ Reduction   │
│ Implementation│                   │ Execution   │
├─────────────┤                    ├─────────────┤
│ Acceptance  │                    │ Auto Fix    │
│ Testing     │                    ├─────────────┤
└─────────────┘                    │ PR Creation │
                                   └─────────────┘

Golden Principles

Based on Harness Engineering best practices, define the following golden principles:

  1. Use Shared Toolkits, Avoid Handwritten Helper Functions

    • Centralize invariant management
    • Reduce duplicate code
  2. Validate Boundary Data, Don't Guess Data Structures

    • All API entry points must have Schema validation
    • Don't rely on implicit type inference
  3. Keep Code Concise, Prioritize Readability

    • Single file no more than 300 lines
    • Single function no more than 50 lines
  4. Documentation as Code, Keep Synchronized

    • Code changes must synchronize documentation
    • Outdated documentation is considered technical debt
  5. Small Loan Repayment, Continuous Improvement

    • Every commit is an improvement opportunity
    • Don't let technical debt accumulate

Configuration File

Entropy reduction behavior can be configured via entropy-config.yaml:

yaml
# entropy-config.yaml
entropy_reduction:
  # Trigger configuration
  triggers:
    schedule: "0 2 * * *"  # Daily at 2 AM
    on_commit: false       # Trigger on commit
    on_pr_merge: true      # Trigger on PR merge
  
  # Detection configuration
  detection:
    docs:
      enabled: true
      paths: ["docs/", "*.md"]
      max_age_days: 30     # Maximum documentation age in days
    architecture:
      enabled: true
      layers: ["types", "config", "repo", "service", "runtime", "ui"]
    code:
      enabled: true
      max_file_lines: 300
      max_function_lines: 50
    tests:
      enabled: true
      min_coverage: 80
  
  # Execution configuration
  execution:
    auto_fix: true         # Auto fix simple issues
    create_pr: true        # Create PR
    max_pr_per_run: 5      # Maximum PRs per run
  
  # Scoring configuration
  scoring:
    weights:
      docs: 0.25
      architecture: 0.25
      code: 0.25
      tests: 0.25

Output Format

Entropy Report Format

After each entropy reduction execution, generate an entropy report saved to the docs/entropy-reports/ directory:

markdown
# Entropy Reduction Report - YYYY-MM-DD

## Entropy Score: XX/100

## Issue List

### Critical (Must Fix)
- [ ] Issue description

### Warning (Recommended Fix)
- [ ] Issue description

### Info (Optional Fix)
- [ ] Issue description

## Fix Recommendations

### Critical Fixes
1. Fix recommendation details

## Execution Results
- Auto fixed: X items
- Created PR: X items
- Skipped: X items

Usage Examples

Example 1: Full Entropy Reduction

User: Execute full entropy reduction

AI:
1. Trigger all detectors
2. Generate entropy report
3. Execute fixes by priority
4. Report results

Example 2: Documentation Entropy Reduction

User: Check documentation consistency

AI:
1. Trigger pdd-doc-gardener
2. Scan docs/ directory
3. Compare code with documentation
4. Generate fix PR

Example 3: Architecture Entropy Reduction

User: Check architecture constraints

AI:
1. Trigger expert-arch-enforcer
2. Run custom Linter
3. Detect dependency violations
4. Generate fix recommendations

References

Matgeliwwert Dateien

De Modell liest dës Dateie bei Bedarf, wärend de Skill gelueden ass. Si ginn als liesbar Dateie bereetgestallt a ginn ni ausgeféiert.

Heefeg gestallte Froen

Wat mécht de KI-Skill Pdd Entropy Reduction?

PDD Entropy Reduction Agent, dee kontinuéierlech technesch Scholden iwwerwaacht an ofbaut, fir de Verfall vum System ze verhënneren. Gëtt automatesch ausgeléist, wann de Code opgeraumt, d'Dokumentatioun aktualiséiert, technesch Scholden geréiert, d'Architektur ausgeriicht, d'Entropie reduzéiert oder de Systemmüll opgeraumt soll ginn. Haaptzil: d'„Entropiezounam“ an de „Verfall“ vum System bekämpfen, andeems reegelméisseg Agenten ausgefouert ginn, déi Inkonsistenzen an der Dokumentatioun oder Verstéiss géint Architekturvorgaben fannen. Ausléiser: - De Benotzer freet: „Entropie reduzéieren“,...

Firwat Pdd Entropy Reduction op TypingMind benotzen?

Well Dir en eemol installéiert a mat all Modell benotze kënnt. Pdd Entropy Reduction besteet aus einfachem Markdown amplaz vun ubidderspezifeschem Code. Dee selwechte Skill funktionéiert also mat GPT-5, Claude, Gemini, Grok oder engem lokale Modell – an Dir kënnt de Modell matzen am Chat wiesselen, ouni datt de Skill ophält ze funktionéieren. TypingMind benotzt Är eegen API-Schlësselen, sou datt Dir d'Ubidder direkt bezuelt, amplaz en Abonnement pro Benotzerplaz ze bezuelen. Är Skills a Chats bleiwen an Ärem eegene Späicher.

Wéi installéieren ech Pdd Entropy Reduction an TypingMind?

Maacht an TypingMind Plugins → Skills → Vu GitHub installéieren op a setzt https://github.com/wonderslife/pdd-skills/tree/main/pdd-entropy-reduction an. TypingMind liest d'Datei SKILL.md, bëndelt déi zougehéiereg Dateien an installéiert dat Ganzt als Skill, deen Dir pro Chat aktivéiere kënnt.

Wéi eng KI-Modeller kënnen Pdd Entropy Reduction benotzen?

All Modell, deen Dir an TypingMind verbënnt. KI-Skills sinn einfach Markdown-Instruktiounen an net ubidderspezifesche Code. Dofir kënne GPT, Claude, Gemini, Grok a lokal Modeller dëse Skill lueden, wann eng Ufro dozou passt.

Wéi vill KI-Modeller kann ech mat Pdd Entropy Reduction benotzen?

Esou vill wéi Dir wëllt. Soulaang e Modell Skills ënnerstëtzt, kënnt Dir Pdd Entropy Reduction domat benotzen – zum Beispill mat GPT, Claude, Gemini, Grok, DeepSeek, Mistral oder Llama – alles op TypingMind mat Ären eegenen API-Schlësselen.

Ass de KI-Skill Pdd Entropy Reduction gratis?

Jo. wonderslife huet de Skill ënner der Lizenz MIT op GitHub publizéiert. Dir bezuelt nëmmen Ären eegene KI-Ubidder fir d'Token, déi Dir benotzt.

Wat si KI-Skills?

E KI-Skill ass e weiderverwendbare Pak vun Instruktiounen, deen engem KI-Modell bäibréngt, wéi en eng bestëmmt Aufgab erfëllt. E follegt dem oppenen Agent Skills-Format: eng Datei SKILL.md mat engem Numm an enger Beschreiwung, plus all Scripten, Virlagen oder Referenzdateien, déi de Modell eventuell brauch. De Modell liest d'Instruktiounen eréischt, wann Är Ufro zum Skill passt. En installéierte Skill kascht also näischt, bis e benotzt gëtt.

Wéi ënnerscheede sech KI-Skills vu Plugins oder MCP-Serveren?

E Plugin oder MCP-Server gëtt engem Modell nei Tools, déi en opruffe kann – Code, deen iergendwou leeft an e Resultat zeréckgëtt. E KI-Skill gëtt dem Modell dogéint Wëssen an eng Virgoensweis: wéi en eng Aufgab ugeet, wéi eng Schrëtt e maache soll a wéi eng gutt Ausgab ausgesäit. Skills bestinn aus einfachem Markdown, brauche kee Server, keen API-Schlëssel a kee Lafzäitëmfeld a funktionéiere mat all Modell.

Alleguer weisen

Elo Ären eegene KI-Aarbechtsberäich ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇