lovable-codebase-audit-cleanup

lovable-codebase-audit-cleanup is a skill for Claude Code, Codex from silvioventre/lovable-skills. It costs 165 tokens per session (3,056 once invoked), scanned A, original, MIT.

A two-stage review process for Lovable projects, which are web projects made with the Lovable development platform, to identify unnecessary code and then remove only approved items.

In plain words
What is it for?
Use it to audit dead or duplicated code, unused packages, outdated dependencies, and maintenance risks, then apply explicitly approved cleanup batches.
Why use it?
It separates inspection from editing, preventing unapproved cleanup and making the proposed changes traceable.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to audit dead or duplicated code, unused packages, outdated dependencies, and maintenance risks, then apply explicitly approved cleanup batches.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/silvioventre/lovable-skills/lovable-codebase-audit-cleanup
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add silvioventre/lovable-skills --skill lovable-codebase-audit-cleanup
Clone the repo
git clone --depth 1 https://github.com/silvioventre/lovable-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for lovable-codebase-audit-cleanup

README.md
[![agentmods](https://agentmods.dev/badge/skills/silvioventre/lovable-skills/lovable-codebase-audit-cleanup/github.svg)](https://agentmods.dev/skills/silvioventre/lovable-skills/lovable-codebase-audit-cleanup)
Your own site
<a href="https://agentmods.dev/skills/silvioventre/lovable-skills/lovable-codebase-audit-cleanup"><img src="https://agentmods.dev/badge/skills/silvioventre/lovable-skills/lovable-codebase-audit-cleanup/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for lovable-codebase-audit-cleanup

Your own site · 80×15
<a href="https://agentmods.dev/skills/silvioventre/lovable-skills/lovable-codebase-audit-cleanup"><img src="https://agentmods.dev/badge/skills/silvioventre/lovable-skills/lovable-codebase-audit-cleanup.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 165 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,056 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00165 $0.03056
Opus 5 $0.00082 $0.01528
Sonnet 5 $0.00033 $0.00611
Haiku 4.5 $0.00016 $0.00306

Measured 10d ago against content hash 34a9e17ce7ed, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

lovable-codebase-audit-cleanup scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/code-quality/lovable-codebase-audit-cleanup/SKILL.md · 211 lines

How it starts

The opening of the file, as written. The whole thing — 211 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Lovable Codebase Audit & Cleanup

This skill governs two distinct, sequential phases of codebase rationalization. They must never be merged into a single pass. Determine which phase applies before doing anything else.

Phase routing

  1. No prior audit exists, or the user asks to inspect/find/review issues → run Phase 1: Audit.
  2. An audit report already exists and the user references an approved batch or finding IDs to implement → run Phase 2: Cleanup.
  3. The user asks to "clean up" without a prior audit → do not skip to editing. Run Phase 1 first, present the findings and the batch roadmap, and wait for explicit batch approval before touching any code.

Never combine phases in one response. Never modify code while still in Phase 1.


Phase 1: Audit (read-only)

Use Plan mode (or the project's equivalent read-only/chat mode). Perform a comprehensive, read-only audit of the entire existing codebase to identify dead code, unused code, obsolete dependencies, duplicated implementations, and maintainability risks.

Do not modify, delete, rename, move, or refactor any file during this phase.

Objective

Rationalize the codebase to make it as professional, maintainable, predictable, and technically robust as possible. Identify code that:

  • Is no longer referenced or executed, or is unreachable.
  • Is obsolete or superseded by a newer implementation.
  • Duplicates existing functionality.
  • Adds unnecessary complexity or creates maintenance risk.
  • Could produce technical issues in future releases.
  • Increases bundle size, build time, runtime overhead, or cognitive load without providing value.
  • Is inconsistent with the architecture and conventions currently used by the project.

Audit scope

Inspect the complete repository, including:

  • Application routes and route registrations.
  • Pages, layouts, components, hooks, utilities, services, providers, contexts, stores, reducers, actions, schemas, types, interfaces, constants, configuration files, tests, scripts, styles, assets, and public files.
  • Frontend and backend code, if both are present.
  • Supabase or Lovable Cloud integrations: migrations, Edge Functions, database clients, queries, RPC calls, storage usage, authentication logic, generated types.
  • Package dependencies and dev dependencies.
  • Build configuration, TypeScript configuration, linting configuration, environment-variable usage, import aliases, deployment configuration.
  • Feature flags, role-based flows, experimental features, legacy implementations, commented-out code, temporary workarounds, stale TODOs.
  • CSS classes, design tokens, stylesheets, images, icons, fonts, and other assets that may no longer be used.
  • Tests, mocks, fixtures, and test utilities that no longer correspond to active functionality.

Read the full file on GitHub · 211 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 211 lines · 165 tokens per session scan A 34a9e17ce7ed

Subscribe to this mod's changes

lovable-codebase-audit-cleanup is a skill published in the GitHub repository silvioventre/lovable-skills (2 stars, last pushed 15d ago), licensed MIT. It adds 165 tokens to every session and 3,056 once invoked, about $0.0008 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.