reclaim-code-entropy README

The project's README from github.com/Yevanchen/reclaim-code-entropy. As one markdown file: README.md.

Reclaim Code Entropy

An evidence-first Agent Skill for safely simplifying any codebase.

English | 简体中文

The Problem

Codebases accumulate more than dead symbols. They accumulate duplicate truths, abandoned extension points, compatibility paths with no remaining consumer, lifecycle flags that describe the same transition, and wrappers that only move complexity around.

Static analysis can produce candidates. It cannot prove that a string-dispatched route, public export, migration, persisted format, plugin entrypoint, or asynchronous cleanup path is safe to remove.

The Solution

reclaim-code-entropy makes simplification evidence-driven:

Stage Question
Establish the contract What is public, persisted, generated, dynamic, or compatibility-sensitive?
Survey entropy Where are the extra representations, states, APIs, layers, and policies?
Prove the cut Who consumes it, why was it added, and what capability would disappear?
Simplify one boundary Can the obsolete contract be removed end to end without replacement glue?
Verify behavior What is the smallest check that would fail if the deletion were wrong?

The skill prefers a few proved cuts over a long speculative cleanup list. Finding nothing safe to remove is a valid result.

What It Finds

Modes

Audit mode ranks candidates by confidence, risk, tradeoff, and estimated net reduction. It does not edit the repository.

Apply mode implements the safest proved cut, preserves observable behavior, and runs proportional verification.

Install

Ask Codex:

Install the reclaim-code-entropy skill from https://github.com/Yevanchen/reclaim-code-entropy/tree/main/skills/reclaim-code-entropy

Start a new Codex task after installation.

Option B: Manual install

git clone https://github.com/Yevanchen/reclaim-code-entropy.git
mkdir -p ~/.codex/skills
cp -R reclaim-code-entropy/skills/reclaim-code-entropy ~/.codex/skills/

Use

Audit a repository without changing it:

Use $reclaim-code-entropy to audit this repository and rank the safest simplification candidates.

Apply the strongest safe cut:

Use $reclaim-code-entropy to simplify this repository. Preserve public and persisted behavior, implement one high-confidence cut, and verify it.

Investigate a specific area:

Use $reclaim-code-entropy to check whether these lifecycle flags represent distinct states or duplicated ownership.

Key Insight

Deletion volume is not the goal. The goal is reducing the number of facts, contracts, states, and concepts the team must keep coherent.

A large deletion can be wrong. A small deletion can remove an entire maintenance obligation. The decisive evidence is the consumer graph, ownership model, history, compatibility surface, and verification boundary.

How to Know It Is Working

A useful result is reviewable, reduces concepts without hiding compatibility risk, and may still conclude that no safe cut exists.

Safety Boundaries

The skill does not simplify away authorization, trust-boundary validation, accessibility basics, data-loss prevention, durable-data compatibility, or cleanup required for resource quiescence.

It is not a performance audit unless simplification is the stated goal.

Inspiration

The initial idea came from studying DeepSeek Harness and its emphasis on simplification during agent-driven development. This project generalizes that lesson for repositories in any language or stack. It is independent and not affiliated with DeepSeek.

License

MIT

reclaim-code-entropy (Yevanchen/reclaim-code-entropy)

Searching Database…

Что это?Это Agent Skill, который ведёт AI-кодинг-агента через безопасное упрощение кодовой базы: выслеживание мёртвого кода, дублирующей логики и ненужных абстракций с опорой на доказательства, а не догадки.
Это статический анализатор, который я запускаю сам, или то, что использует AI-агент?Это не отдельный анализатор, который вы запускаете напрямую; это определение навыка, которому следует AI-кодинг-агент (вроде Codex). Агент проводит исследование, доказывая безопасность каждого удаления, прежде чем что-то убрать.
Как установить этот навык?Рекомендуемый способ — попросить Codex установить его через установщик навыков Codex и затем начать новую задачу Codex; есть и вариант ручной установки, описанный в README.
Нужен ли конкретный кодинг-агент, чтобы его использовать?Процесс установки построен вокруг Codex (вы просите Codex установить навык и выполнять с ним задачи), поскольку он упакован как совместимый с Codex Agent Skill.
Всегда ли он находит что-то для удаления?Нет — навык явно считает отсутствие безопасного для удаления валидным исходом; режим Audit только ранжирует кандидатов, не трогая репозиторий, а режим Apply реализует лишь одно самое безопасное доказанное удаление за прогон.
В чём разница между режимами Audit и Apply?Режим Audit ранжирует кандидатов на удаление по уверенности, риску, компромиссу и чистому сокращению кода, ничего не меняя. Режим Apply реализует только одно самое безопасное доказанное удаление, сохраняет наблюдаемое поведение и выполняет соразмерную проверку.
Какого рода проблемы он ищет?Он нацелен на такие вещи, как неиспользуемые API и экспорты, дублирующие представления состояния, спекулятивные абстракции, обёртки, лишь пересылающие вызовы, дублирующую логику lifecycle/cleanup и самописный код, повторяющий возможности платформы.
Чего он ради безопасности не тронет?Он не станет упрощать ни авторизацию, ни валидацию границ доверия, ни основы доступности, ни защиту от потери данных, ни совместимость долговременных данных, ни очистку, необходимую для высвобождения ресурсов.
Зачем это создано и откуда пришла идея?Автор почерпнул вдохновение при изучении DeepSeek Harness и его упора на упрощение в ходе разработки под управлением агентов, а затем обобщил эту идею в навык, применимый к любой кодовой базе на любом языке.
Creator
Yevanchen
Size
<0.1 MB
Stars
205
Updated
CommitAug 21
Age
2mo
Commits · 90 Days