Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
specstoryai avatar

Specstory Organize

  • 270 installs
  • 31 repo stars
  • Updated January 31, 2026
  • specstoryai/agent-skills

specstory-organize is a Claude agent skill that sorts SpecStory AI coding session files from .specstory/history into year/month folders for developers who need dated archives of agent session markdown without manual file

About

specstory-organize is a Claude Code skill from specstoryai/agent-skills (version 1.0.0, Apache-2.0) that organizes SpecStory session history by moving markdown files from .specstory/history into YYYY/MM subdirectories based on timestamps embedded in filenames like 2026-01-22_19-20-56Z-fix-bug.md. The skill scans the history directory, extracts dates from filenames, creates year and month folders, moves files, and reports a per-month breakdown. Developers reach for specstory-organize when hundreds of session files make it hard to find work from a specific period or keep the project directory clean. Invocation paths include the /specstory-organize slash command, natural phrases like organize my history, and direct execution of skills/specstory-organize/scripts/organize.py with an optional --dry-run preview. Files without recognizable date patterns are skipped; already-organized files in subdirectories are not moved again. The Python script is compatible with Python 2.7+ and Python 3.x and uses filename timestamps rather than file modification times.

  • specstory-organize

Specstory Organize by the numbers

  • 270 all-time installs (skills.sh)
  • +1 installs in the week ending Aug 5, 2026 (Skillselion tracking)
  • Ranked #1,440 of 4,347 Backend & APIs skills by installs in the Skillselion catalog
  • Data as of Aug 5, 2026 (Skillselion catalog sync)
npx skills add https://github.com/specstoryai/agent-skills --skill specstory-organize

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs270
repo stars31
Last updatedJanuary 31, 2026
Repositoryspecstoryai/agent-skills

How do you organize SpecStory session history files?

Use specstory-organize for development tasks

Who is it for?

Developers using SpecStory who accumulate large .specstory/history directories and need automated year/month archival sorting.

Skip if: Editing session content, syncing history to cloud storage, or organizing non-SpecStory project files outside .specstory/history.

When should I use this skill?

A user says organize my history, clean up specstory, sort my sessions, or wants /specstory-organize with optional dry-run preview.

What you get

Dated YYYY/MM folder tree under .specstory/history with moved session markdown files and a per-month move summary report.

  • YYYY/MM folder tree
  • organize summary report

By the numbers

  • Version 1.0.0 under Apache-2.0 license from SpecStory, Inc.
  • Organizes files into 2-level YYYY/MM directory paths
  • Includes a Python organize.py script with --dry-run support

Files

SKILL.mdMarkdownGitHub ↗

SpecStory Organize

Organizes your .specstory/history directory by moving session files into YYYY/MM/ subdirectories based on the timestamp in each filename.

How It Works

1. Scans .specstory/history/ for markdown files 2. Extracts the date from filenames (e.g., 2026-01-22_19-20-56Z-fix-bug.md) 3. Creates year/month folders (e.g., 2026/01/) 4. Moves files into the appropriate subdirectory 5. Reports what was moved

Why Organize?

Over time, your history directory can accumulate hundreds of session files. Organizing by date makes it easier to:

  • Find sessions from a specific time period
  • Archive old sessions
  • Keep your project directory clean

Usage

Slash Command

User saysAction
/specstory-organizeOrganize all files (default)
/specstory-organize dry runPreview changes without moving
/specstory-organize --dry-runPreview changes without moving

Direct Script Usage

# From project root
python skills/specstory-organize/scripts/organize.py

# Preview what would be moved (no changes made)
python skills/specstory-organize/scripts/organize.py --dry-run

Output

SpecStory History Organizer
===========================

Found 47 files to organize in .specstory/history/

Moving files:
  2026-01-15_10-30-22Z-refactor-auth.md -> 2026/01/
  2026-01-15_14-22-01Z-fix-tests.md -> 2026/01/
  2026-01-22_19-20-56Z-add-feature.md -> 2026/01/
  2025-12-28_09-15-33Z-cleanup.md -> 2025/12/
  ...

Summary:
--------
Files moved: 47
  2026/01/: 23 files
  2025/12/: 18 files
  2025/11/: 6 files

Your history is now organized!

Dry Run Output

When using --dry-run:

SpecStory History Organizer (DRY RUN)
=====================================

Would organize 47 files in .specstory/history/

Preview:
  2026-01-15_10-30-22Z-refactor-auth.md -> 2026/01/
  2026-01-15_14-22-01Z-fix-tests.md -> 2026/01/
  ...

No files were moved. Run without --dry-run to apply changes.

Present Results to User

After running the organize script:

1. Confirm success - Tell the user how many files were organized 2. Show the breakdown - List how many files went to each month 3. Note any skips - If files couldn't be parsed (no date in filename), mention them

Example Response

Done! I organized 47 session files in your `.specstory/history/` directory:

- **2026/01/**: 23 files
- **2025/12/**: 18 files
- **2025/11/**: 6 files

Your history files are now sorted by year and month, making it much easier
to find sessions from specific time periods.

Notes

  • Files without a recognizable date pattern in the filename are skipped
  • The script uses the filename timestamp, not the file's modification time
  • Already-organized files (in subdirectories) are not moved again
  • Compatible with Python 2.7+ and Python 3.x

Related skills

How it compares

Use specstory-organize for SpecStory history folder sorting; use general filesystem skills when organizing code outside .specstory/history.

FAQ

How does specstory-organize determine folder placement?

specstory-organize extracts dates from session filenames such as 2026-01-22_19-20-56Z-fix-bug.md and moves each file into a YYYY/MM subdirectory like 2026/01/. The script uses the filename timestamp, not the file modification time, and skips files without a recognizable date patt

Can specstory-organize preview changes before moving files?

specstory-organize supports --dry-run on organize.py and phrases like dry run or /specstory-organize --dry-run to list planned moves without changing the filesystem. Running without --dry-run applies the year/month folder organization to all eligible files in .specstory/history.

What triggers specstory-organize activation?

specstory-organize activates when users say organize my history, clean up specstory, sort my sessions, or organize specstory files. The slash command /specstory-organize and direct python skills/specstory-organize/scripts/organize.py invocation are also supported paths.

Backend & APIsbackendintegrations

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.