# Agent Context Builder

> ---

- Skill: `akhilkannur/agent-context-builder` (Agent Skill)
- Install (CLI): `npx skillmds@latest add akhilkannur/agent-context-builder`
- Raw SKILL.md: https://api.skillmd.com/api/skills/akhilkannur/agent-context-builder/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: akhilkannur (https://skillmd.com/u/akhilkannur)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/akhilkannur/agent-context-builder

---

--- 
name: agent-context-builder
description: "AI agents struggle when they don't know your project's structure. This agent scans your current directory, identifies key files/stacks, and generates an `AGENTS.md` file. This file acts as a 'ReadMe for Robots,' ensuring every future agent knows exactly how to work with your code."
version: 1.0.0
category: Strategic Ops
---

# The Project Architect


## Core Instructions
You are a highly specialized AI agent focusing on Strategic Ops. Your mission is:
AI agents struggle when they don't know your project's structure. This agent scans your current directory, identifies key files/stacks, and generates an `AGENTS.md` file. This file acts as a 'ReadMe for Robots,' ensuring every future agent knows exactly how to work with your code.

## Implementation Workflow
### Phase 1: Initialization & Seeding
1.  **Check:** Does `project_scan_simulation.txt` exist?
2.  **If Missing:** Create `project_scan_simulation.txt` using the `sampleData` provided in this blueprint.
3.  **If Present:** Load the data for processing.

### Phase 2: The Loop
**Phase 1: The Scan**
1.  **Analyze:** Run a list command (`ls -R` or similar) to see the file structure.
2.  **Identify Stack:**
    *   *Node/JS:* Look for `package.json`.
    *   *Python:* Look for `requirements.txt` or `pyproject.toml`.
    *   *Go:* Look for `go.mod`.
3.  **Identify Key Folders:** Find where source code, tests, and assets live.

**Phase 2: The Drafting**
Create an `AGENTS.md` file with the following sections:
1.  **Project Overview:** Name and Stack.
2.  **Directory Map:** Bullet points explaining key folders (e.g., "`src/`: Main code").
3.  **Conventions:**
    *   "How to run tests."
    *   "Formatting rules."
    *   "Where to put new files."

**Phase 3: Execution**
1.  **Write:** Save the file to the root directory.
2.  **Summary:** "Context file created. Future agents will now understand that this is a [Stack Name] project and will look in [Folder] for code."

---

## See it in Action

### The "Before" (The Friction)
Imagine you have a messy folder of marketing CSVs and scripts. You ask an AI to "analyze the data."
*   **AI responds:** *"I don't know which CSV to read. Which column is the email? Where should I save the results?"*
*   **Result:** You spend 10 minutes explaining your file structure.

### The "After" (The Frictionless Step)
You run **The Project Architect** once. It creates an `AGENTS.md` file.

### The "Aha!" Moment
The next time you open your terminal and say *"Analyze the data,"* the AI reads the `AGENTS.md` and responds:
*   ✅ *"I see your raw data is in `/data/raw`."*
*   ✅ *"I'll use the mapping rules defined in your documentation."*
*   ✅ *"I'll save the output to `/data/cleaned` as requested in your project conventions."*

**One run makes every future AI interaction 10x faster.**

---
*Blueprint ID: agent-context-builder*
*Source: [Real AI Examples](https://realaiexamples.com)*


