# janitor

> Safely audit, preserve, and quarantine temporary AI agent artifacts and workflow clutter.

janitor is a free AI agent skill on Agensi by Sadik Pranto, in Workflow Automation. It loads into your AI agent through the Agensi MCP server, always in its latest approved version.

- Price: Free
- Creator: [Sadik Pranto](https://www.agensi.io/creators/prantosmss)
- Category: [Workflow Automation](https://www.agensi.io/skills/workflow-automation)
- Uses: 2
- Version: 1.1
- Last updated: 2026-10-19
- Security: scan passed (2026-10-19); every new listing is also reviewed by a person
- Listing: https://www.agensi.io/skills/janitor
- Tags: automation, code-review, git, productivity, documentation

## About this skill

Development workflows involving AI agents often leave behind a trail of temporary directories, scratch files, and evaluation outputs that clutter the repository. This skill audits your workspace to identify workflow artifacts, preserves critical engineering decisions buried in temporary logs, and safely moves approved clutter into a reversible quarantine.

### What it does
- **Workspace auditing** identifies temporary AI-generated folders and scratch files across the project.
- **Artifact classification** tiers findings into safe, suspicious, or protected categories based on safety rules.
- **Knowledge extraction** captures architectural decisions and rationale from temporary files before they are removed.
- **Safety verification** checks for nested repositories, symlinks, and uncommitted git changes to prevent data loss.
- **Reversible quarantine** moves files to a timestamped trash directory instead of permanent deletion.

### How it works
1. **Detect conventions** by locating existing documentation targets like `ADR` logs or `README` files for preservation.
2. **Scan and audit** the project using specific patterns to identify temporary agent artifacts.
3. **Propose cleanup** by presenting a structured report of what will be moved, preserved, or skipped.
4. **Execute quarantine** only after explicit user confirmation, updating `.gitignore` to prevent future noise.

### Frameworks & tools
This skill is framework-agnostic and works with any AI agent capable of file operations. It is optimized for environments with `git` and standard shell utilities like `find` but includes manual fallbacks for restricted environments.

### Why this beats prompting it yourself
Generic cleanup prompts often delete valuable implementation notes or accidentally wipe `node_modules` and `.env` files. This skill uses a strict classification engine and multi-step safety checks (symlink resolution and git status audits) that simple prompts ignore.

### Use cases
- **Post-implementation cleanup** after a multi-step agent task finishes.
- **Benchmark auditing** to remove evaluation workspaces while saving results.
- **Worktree management** to safely identify and remove stale git worktrees.
- **Repository hygiene** for teams using multiple AI tools that generate distinct cache folders.

### Known limitations
Does not support permanent deletion, only quarantine. Requires manual confirmation for directories over 100MB or files exceeding 100KB to ensure safety.

## Requires

- Git

## How to use this skill

1. Connect your AI agent to Agensi once: add the MCP server https://mcp.agensi.io/mcp/auth and sign in with your Agensi account (OAuth, no API key). Steps for Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and other agents: https://www.agensi.io/docs/mcp-setup
2. Ask your agent: "Use the janitor skill from Agensi" and describe your task.
3. Your agent loads the skill from Agensi when it needs it. Nothing is downloaded.

## Frequently asked questions

### How does Janitor differ from simply asking an AI to delete temporary files?

Unlike a generic 'delete' command, Janitor uses a safety-first classification engine that checks git status and symlinks to ensure you don't lose uncommitted work or critical environment files. It focuses on preserving the "why" by extracting architectural decisions from temporary logs before moving them to a reversible quarantine.

### Which AI agents or development environments are compatible with this skill?

Janitor is framework-agnostic and works with any AI agent that has file system permissions. It is specifically optimized for developers using Git-based workflows and standard shell environments.

### What is included in the skill package when I download it?

Your purchase includes the core Janitor skill logic, a set of pre-configured safety rules for artifact classification, and documentation on how to integrate the audit reports into your existing agentic workflows.

### Can I review what the skill plans to move before it executes the quarantine?

Yes, by default Janitor requires a structured report review and explicit user confirmation before executing any file moves. It also includes a safety threshold that flags any directory over 100MB for manual inspection to prevent accidental data loss.

### What happens if the skill accidentally flags a file I want to keep?

Janitor does not perform permanent deletions; it moves identified clutter into a timestamped, reversible quarantine directory. This allows you to easily restore any file if you realize it was needed for a future task.

---

Source: [Agensi](https://www.agensi.io), the marketplace of skills for AI agents. Any MCP-compatible agent (Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and more) connects at https://mcp.agensi.io/mcp/auth and signs in with an Agensi account; setup for every agent: https://www.agensi.io/docs/mcp-setup. Append .md to any skill, guide or docs address on agensi.io for its markdown version.
