directory-layout

Generate and refactor project directory structures using Python.

Updated Jul 6, 2026
One-click install
npx skills add https://github.com/jairferrara/directory-layout-skill --skill directory-layout
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: directory-layout
Source: https://github.com/jairferrara/directory-layout-skill/tree/main
Command: npx skills add https://github.com/jairferrara/directory-layout-skill --skill directory-layout

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill streamlines the creation of optimized directory structures for any type of project, using principled approaches like the Screaming Architecture method, while providing a migration plan for existing projects.

Core Features & Use Cases

  • Layout Generation: Automate the creation of directory structures for new projects based on provided ideas or individual files.
  • Refactoring Assistance: Analyze existing folder contents to recommend refactoring plans based on cohesion scores.
  • Pattern Selection: Automatically selects the most suitable architecture pattern (Layered, Feature-based, etc.) for a project.
  • Custom Patterns: Force a specific pattern or output the minimal flat structure when necessary.

Quick Start

Analyze and refactor the current directory structure to optimize it for a web application.

Frequently Asked Questions about directory-layout

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

FAQPage Schema
How do I refactor an existing directory structure for better code organization?

To refactor an existing directory structure, this Skill analyzes folder contents and recommends a migration plan based on cohesion scores. It infers the project type from file content and applies structured design principles to optimize code organization.

What is the Screaming Architecture method for software design?

Screaming Architecture is a software design approach where the directory structure reflects the project's intent. This Skill uses it to generate folder layouts that communicate business features, ensuring code organization prioritizes purpose over implementation details.

Can I force a specific architecture pattern like feature-based or layered for my project?

Yes, you can force a specific architecture pattern like feature-based or layered for your project layout. The Skill allows custom pattern selection, overriding its automatic inference logic, and can also output a minimal flat structure when necessary.

Does this directory structure generator require Python and OpenCode to run?

Yes, this directory layout generator requires Python for file processing and pattern matching. It also depends on the OpenCode environment for execution to operate within existing codebases and handle files at scale.

How do I generate a directory layout for a new web application project?

To generate a directory layout for a new web application, provide your project idea or individual files. The Skill automatically selects the most suitable architecture pattern, such as layered or feature-based, and creates an optimized folder structure from scratch.

What are the limitations of automated code organization refactoring at scale?

Automated code organization refactoring at scale depends on inferring project types from file content. While it applies design principles and calculates cohesion scores, highly unconventional codebases may require manual review of the generated migration plan to ensure optimal structural results.