---
title: Structure Modular SKILL.md Directories | SkillMarket
description: Design clean, portable SKILL.md package folders separating core workflow instructions, executable scripts/, on-demand references/, and static assets/.
canonical: "https://skillmarket.ai/j/structure-modular-skill-directory-with-scripts"
modified: 2026-11-14
author: skillmarket.ai editorial team
source: "https://skillmarket.ai"
category: Authoring & Publishing SKILL.md Packages
category_url: "https://skillmarket.ai/j#group-skill-authoring-packaging"
---

# Organize modular SKILL.md folders with scripts/, references/, and assets/ following open specs

> Follow the standard Agent Skills directory layout so your package installs cleanly across Claude Code, Codex, Cursor, and CI harnesses.

## Prepared starting prompt

Show benchmarked directory patterns for packaging SKILL.md alongside uv single-file Python scripts, reference schemas, and boilerplate assets.

### Quick scenarios
- **agentskills.io spec compliance:** Verify folder layout against the standard SKILL.md / scripts / references / assets spec.
- **Self-contained uv PEP-723 scripts:** Bundle zero-setup Python scripts with inline PEP 723 dependency metadata.
- **Relative path portability:** Avoid hardcoded ~/.claude paths so skills run identically across Linux CI and macOS.

- [Join Early Access Waitlist](https://skillmarket.ai/#waitlist-8efd41)

## Directory blueprint of top-ranked portable skill packages

1. **Separate SKILL.md, scripts/, references/, and assets/** — Keep orchestration in SKILL.md, deterministic CLIs in scripts/, deep docs in references/, and output templates in assets/.
2. **Use PEP 723 inline dependencies for Python helpers** — Header blocks declaring dependencies let 'uv run scripts/check.py' execute cleanly without polluting the user's project virtualenv.
3. **Make every bundled script emit LLM-friendly --help and errors** — When a script fails, print actionable stderr hints ('Missing --schema; pass path to .json') rather than raw 40-line tracebacks.
4. **Use relative paths anchored to the skill directory** — Never hardcode '/Users/alice/.claude/skills/...'; reference './scripts/validate.py' relative to the loaded skill root.

## How it works in practice

### Package layout comparison

Audit portability of 'openapi-linter-skill' across macOS Claude Code, Linux Docker CI, and Cursor.

### Portability verification

v1 (global pip install + hardcoded ~/.claude path): failed in Linux CI and broke project venv. v2 (standard SKILL.md + uv PEP-723 scripts/ + relative paths): 100% zero-config pass across all 3 harnesses.

Self-contained scripts and relative paths turn fragile laptop hacks into zero-setup packages your whole org can install in seconds.

## Frequently Asked Questions

### Should agents read the source code of scripts/ or just execute them?

Instruct the agent in SKILL.md to execute 'scripts/tool.py --help' as a black-box CLI rather than wasting context tokens reading 300 lines of Python.

### What files do NOT belong inside a published skill directory?

Leave out README-duplicating changelogs, node_modules, __pycache__, .DS_Store, sample secrets, and gigantic binary fixtures.

### Does SkillMarket validate Agentskills spec conformance automatically?

Yes—every indexed package receives a spec-compliance score checking frontmatter fields, folder conventions, and broken relative paths.

## Related tasks in this category

- [Write SKILL.md YAML frontmatter descriptions that trigger reliably without hijacking unrelated chats](https://skillmarket.ai/j/author-high-trigger-accuracy-skill-descriptions.md)
- [Transform dusty Confluence and Notion engineering runbooks into executable SKILL.md packages](https://skillmarket.ai/j/convert-internal-runbooks-into-agent-skills.md)
- [Enforce strict JSON Schema and Pydantic validation inside skills feeding downstream pipelines](https://skillmarket.ai/j/standardize-structured-json-outputs-in-skills.md)
- [Apply semantic versioning, compatibility tags, and benchmarked changelogs to published skills](https://skillmarket.ai/j/version-and-changelog-published-agent-skills.md)
- [Adapt SKILL.md packages cleanly across Claude Code, OpenAI Codex CLI, Cursor, and Windsurf](https://skillmarket.ai/j/port-claude-code-skills-to-cursor-and-codex.md)
- [Author crisp negative boundaries in SKILL.md to stop unasked-for refactors, commits, and scope creep](https://skillmarket.ai/j/write-negative-constraints-to-prevent-overreach.md)

---

*Published by **Wondel.ai sp. z o.o.** · [skillmarket.ai](https://skillmarket.ai) · [About](https://skillmarket.ai/about) · [Editorial Guidelines](https://skillmarket.ai/editorial) · [Contact](https://skillmarket.ai/contact) · [Wondel.ai Products](https://wondel.ai/products)*