# AI use cases for Simplify Codebase (tt-a1i/simplify-codebase)

Repo: [tt-a1i/simplify-codebase](https://github.com/tt-a1i/simplify-codebase) | Use cases: 4 | Page: https://dedupedai.com/use-cases/tt-a1i-simplify-codebase/

An Agent Skill that helps coding agents find and remove accidental complexity in an existing codebase while keeping still-valid behavior, boundaries and compatibility intact.

This file holds every use case of this repo. Each one starts with a "## " heading and ends with its URL.

- Audit a whole repo for safe simplification candidates: https://dedupedai.com/use-cases/tt-a1i-simplify-codebase/audit-repo-for-safe-simplifications/
- Decide if readiness flags are duplicate state: https://dedupedai.com/use-cases/tt-a1i-simplify-codebase/investigate-readiness-flags-duplication/
- Review and merge simplification findings from a PR: https://dedupedai.com/use-cases/tt-a1i-simplify-codebase/review-simplification-pr-findings/
- Generate an interactive Cleanup Map from an audit: https://dedupedai.com/use-cases/tt-a1i-simplify-codebase/render-cleanup-map-visual-report/

## How to audit a whole repo for safe simplification candidates with Simplify Codebase

Repo: [tt-a1i/simplify-codebase](https://github.com/tt-a1i/simplify-codebase) | Difficulty: Intermediate | Time: 15 minutes | Basis: From the README

Get a ranked list of simplification candidates with proof records, counterexamples and blind spots, with no file changes.

**Who it is for:** A maintainer of a large existing codebase who suspects duplicated state, orphaned abstractions or dead compatibility paths and wants a read-only review first.

**The problem:** Static checks flag unused-looking code but cannot prove that deleting it is safe, so teams either skip cleanup or delete things that still have consumers.

**The outcome:** A read-only Survey report that covers the repo, lists ranked candidates with evidence for each, and names the open questions and the next evidence needed.

### Steps

1. Clone the skill into your Codex user skills folder with `git clone https://github.com/tt-a1i/simplify-codebase.git ~/.codex/skills/simplify-codebase` (inferred, check the README)
2. Start a new task so the skill directory reloads.
3. Open the target repository and ask the agent to use $Simplify Codebase to audit it, list the safest high-value candidates, and not modify any files.
4. Read each proof record and check the named production, test, dynamic and external consumers.
5. Keep the candidates whose deletion boundary and minimal verification you can confirm.

### Prompt to paste into your agent

```text
Use $simplify-codebase on the repository at <path to repo>. Run a broad read-only Survey and do not modify any files. Expected output: ranked proof records with coverage, counterexamples, open questions and the next evidence needed. Verify that every candidate names its consumers and its deletion boundary.
```

### Caveat

The skill cannot replace product decisions, so any candidate that touches a reachable capability, supported interface or persisted format still needs your explicit approval.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/tt-a1i-simplify-codebase/audit-repo-for-safe-simplifications/

## How to decide if readiness flags are duplicate state with Simplify Codebase

Repo: [tt-a1i/simplify-codebase](https://github.com/tt-a1i/simplify-codebase) | Difficulty: Intermediate | Time: 30 minutes | Basis: From the README

Check whether several readiness flags express distinct lifecycle guarantees or just repeat the same state.

**Who it is for:** An engineer who finds several overlapping readiness or status flags in one subsystem and wants to know whether they can be merged.

**The problem:** Overlapping flags make the lifecycle hard to reason about, but merging them without tracing every reader and writer can break startup or shutdown behavior.

**The outcome:** A focused Survey answer that says whether each flag guards a different guarantee, with the consumers and lifecycle owners that justify the answer.

### Steps

1. Make sure the skill is installed and a new task has loaded it.
2. Point the agent at the subsystem that holds the flags and name the flags in your request.
3. Ask the agent to trace every writer and reader of each flag, including dynamic and external consumers.
4. Review the verdict: keep separate, merge, or unable to judge.
5. Only after a merge verdict, ask for a Change run with a stated deletion boundary.

### Prompt to paste into your agent

```text
Use $simplify-codebase in Focused Survey mode on <subsystem path> to decide whether the readiness flags <flag names> express different lifecycle guarantees or repeated state. Do not modify files. Expected output: one verdict per flag with its consumers and lifecycle owner. Verify that each verdict cites the readers and writers it traced.
```

### Caveat

The skill recommends keeping code whenever a real consumer or boundary is not yet clear, so an unclear result is a valid outcome, not a failure.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/tt-a1i-simplify-codebase/investigate-readiness-flags-duplication/

## How to review and merge simplification findings from a PR with Simplify Codebase

Repo: [tt-a1i/simplify-codebase](https://github.com/tt-a1i/simplify-codebase) | Difficulty: Intermediate | Time: 30 minutes | Basis: From the README

Check simplification suggestions from a pull request or another agent, keeping the evidence and dropping the rest.

**Who it is for:** A reviewer who receives simplification suggestions from a pull request, another branch or another agent and needs to verify them before acting.

**The problem:** Suggestions often come with a count of deletions but without proof of consumers, so accepting them by volume can remove code that still matters.

**The outcome:** A consolidated list of findings where each kept item has evidence, and weak items are rejected with a stated reason.

### Steps

1. Collect the simplification suggestions from the pull request or the other agent's notes.
2. Ask the agent to use $Simplify Codebase to review and consolidate them, keeping the evidence and not the candidate count.
3. Check that each kept finding names its consumers and deletion boundary.
4. Reject any finding that lacks evidence, and note the reason.

### Prompt to paste into your agent

```text
Use $simplify-codebase to review and consolidate the simplification suggestions in <PR link or notes file>. Keep only findings with evidence and reject the rest with a reason. Expected output: a consolidated list with proof records and rejected items. Verify that every kept finding names its consumers and deletion boundary.
```

### Caveat

The skill judges findings against the repo as it is now, so suggestions based on a stale branch may need to be rechecked against the current code.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/tt-a1i-simplify-codebase/review-simplification-pr-findings/

## How to generate an interactive Cleanup Map from an audit with Simplify Codebase

Repo: [tt-a1i/simplify-codebase](https://github.com/tt-a1i/simplify-codebase) | Difficulty: Advanced | Time: 30 minutes | Basis: From the README

Turn a confirmed audit into a desktop HTML map with linked findings and evidence drawers.

**Who it is for:** A team lead who wants to show a simplification audit visually, where the topology spans several components, states or consumers.

**The problem:** A long text audit is hard to scan when a change touches many components, and a plain diagram can wrongly imply runtime impact.

**The outcome:** A validated interactive HTML Cleanup Map with Finding deep links, placed alongside the text report, which stays the authoritative result.

### Steps

1. Confirm that Node.js 18 or newer is installed.
2. Finish the text audit first, since the text report stays the authoritative result.
3. Ask the agent to use $Simplify Codebase to generate a Cleanup Map for the audit, and confirm when it asks.
4. Open the generated HTML in a desktop browser and follow the Finding links.
5. Check that the map shows only confirmed components and relationships.

### Prompt to paste into your agent

```text
Use $simplify-codebase to audit <repo path> and generate a Cleanup Map with Finding deep links after I confirm. Do not present reachable relationships as runtime impact. Expected output: a validated interactive HTML file alongside the text proof records. Verify that every node on the map matches a confirmed finding in the text report.
```

### Caveat

The map is only a companion to the text report, and the skill skips it when the topology is not yet proven or when the diagram adds no explanatory value.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/tt-a1i-simplify-codebase/render-cleanup-map-visual-report/
