map-codebase

Extract Python project structure into a compact JSON file using AST.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/ste-bah/archon --skill map-codebase-ste-bah
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: map-codebase
Source: https://github.com/ste-bah/archon/tree/main/.claude/skills/map-codebase
Command: npx skills add https://github.com/ste-bah/archon --skill map-codebase-ste-bah

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill extracts and caches Python project structure using the AST to regenerate the compact summary injected at SessionStart, reducing manual inspection and setup overhead.

Core Features & Use Cases

  • AST-based extraction of Python project structure to produce a stable, queryable representation.
  • Regenerates the compact session-start summary after refactors or major changes in the codebase.
  • Read-only extraction ensuring the source code remains unmodified while updating memory-friendly metadata.

Quick Start

Run the Python AST-based extractor on your project to produce a compact structure JSON and refresh the SessionStart summary.

Frequently Asked Questions about map-codebase

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I extract and cache Python project structure using AST?

You can extract Python project structure using an AST-based extractor that generates a compact JSON file at .persistent-memory/project-structure.json, providing a queryable representation of your codebase without modifying source code.

What is the best way to refresh a Python codebase structure summary after refactoring?

Refreshing a Python codebase structure summary after refactoring is done by re-running the AST-based extractor, which verifies freshness against HEAD and regenerates the compact session-start summary to reflect your changes.

Can I use AST extraction to analyze Python projects of varying sizes?

AST extraction applies to Python codebases of varying sizes, performing read-only extraction to produce a stable, memory-friendly metadata file that captures the project structure for session injection.

Does extracting Python project structure modify my source code files?

Extracting Python project structure is a read-only process that ensures source code remains completely unmodified while updating the memory-friendly metadata stored in the project-structure JSON file.

How does AST-based project structure caching work for Python codebases?

AST-based project structure caching works by parsing the Python codebase to extract structural information, storing it as a compact JSON file, and verifying its freshness against HEAD to keep the session-start summary current.