Cadence-driven work moderation and recomposition system that discovers unfinished, fragmented, and drifting work across the codebase and collaboration surfaces, then recomposes it into coherent,...
Cadence-Driven Work Moderation & Recomposition
Treat unfinished work as structured information, not noise to be ignored.
Modulization is a sophisticated agent that runs on a regular cadence (daily, weekly, or per-release) to discover scattered, incomplete, and drifting work across your project, then recomposes it into coherent modules ā units of work that can be scheduled, spec'd, and delivered together.
Invoke modulization when you need to:
Trigger phrases:
A Module is a coherent, self-contained unit of unfinished or future work that:
Unlike flat task lists, modules group related breadcrumbs into actionable units.
Squeeze-in is intentional insertion of modular work into existing delivery arcs:
This avoids surprise scope creep while ensuring nothing is forgotten.
Every discovered module is classified into one of four paths:
| Classification | Meaning | Action |
|---|---|---|
| Integrate Now | Aligned with active milestone, low cost, high leverage | Add to current work |
| Schedule Explicitly | Important but disruptive | Assign to future milestone |
| Ice (Intentional Pause) | Valid idea, wrong time | Document and defer |
| Archive/Close | Obsolete or superseded | Close with context preserved |
Nothing remains floating.
Modulization gathers signals from multiple sources:
Scan for:
- TODO / FIXME / NOTE / HACK / XXX comments
- Dead or partially used code paths
- Experimental flags or feature toggles
- Unreferenced modules or tests
- Inline comments that no longer match reality
- Incomplete implementations (stub functions, panic!("not implemented"))
Collect from:
- Stale PRs (open > 14 days, draft, closed without merge)
- Issues without recent activity (> 30 days)
- Linked but unresolved conversations
- PR review comments requesting follow-up work
- Abandoned branches (no commits > 30 days)
- Draft issues in projects
Reference:
- ROADMAP.md milestones and due dates
- Spec-kitty worktrees (.worktrees/)
- Spec-driven artifacts (spec.md, plan.md, tasks.md)
- CODEOWNERS and area ownership
- Constitution principles
Trace:
- Origin of work (issue ā PR ā discussion ā commit)
- Why it stalled (dependency, scope creep, priority shift)
- Similar work elsewhere in the project
- Previous decisions and discussions
For each discovered signal:
Group related signals into modules:
For each module, apply decision heuristics:
IF aligned_with_active_milestone AND low_marginal_cost THEN
ā Integrate Now
IF important AND disruptive THEN
ā Schedule Explicitly (assign milestone)
IF valid_but_wrong_time OR blocked_by_external THEN
ā Ice (document rationale)
IF obsolete OR superseded THEN
ā Archive (preserve context)
Produce actionable outputs:
Modulization does not write final specs ā it prepares spec-ready inputs.
For each module, it can emit:
module_id: MOD-2024-001
title: "Complete i18n infrastructure"
problem: |
Internationalization work was started but left incomplete.
Multiple TODOs and a draft PR exist.
context: |
- PR #147 (draft): Basic locale detection
- 12 TODOs in src/i18n/
- Issue #89: RTL support request
constraints:
- Must maintain backwards compatibility
- Performance budget: <10ms overhead
suggested_artifacts:
- PRD: User-facing i18n capabilities
- ADR: Locale detection strategy
- Design: Translation file format
This feeds directly into /spec-kitty.specify for full spec generation.
# Modulization Report
Generated: 2026-01-08
Cadence: Weekly
Scope: Full repository
## Summary
- Signals Collected: 47
- Modules Formed: 8
- Integrate Now: 2
- Schedule Explicitly: 4
- Ice: 1
- Archive: 1
## Modules
### MOD-001: Incomplete Safety Validation Patterns
**Classification:** Integrate Now
**Milestone:** v1.1.0-beta
**Confidence:** 0.87
**Description:**
Safety validation patterns have TODOs for edge cases and a stale PR
with additional patterns that was never merged.
**Signals:**
- [TODO] src/safety/patterns.rs:142 - Handle nested quotes
- [TODO] src/safety/validator.rs:89 - Add timeout patterns
- [PR #156] Draft: Additional safety patterns (stale 23 days)
- [Issue #134] Safety bypass with unicode (open)
**Scope:**
- Files: 4
- Lines: ~200
- Complexity: Medium
- Risk if ignored: High (security)
**Recommendation:**
Integrate into current sprint. Aligns with v1.1.0-beta safety focus.
Create spec seed for structured implementation.
**Spec Seed:** [Link to generated seed]
---
Modulization is designed to run as a scheduled GitHub Action:
# .github/workflows/modulization.yml
name: Modulization Cadence
on:
schedule:
- cron: '0 9 * * 1' # Weekly on Monday 9 AM UTC
workflow_dispatch: # Manual trigger
inputs:
scope:
description: 'Scan scope'
type: choice
options:
- full
- codebase-only
- github-only
default: full
jobs:
modulization:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run Modulization
uses: anthropic/claude-code-action@v1
with:
skill: modulization
scope: ${{ inputs.scope || 'full' }}
- name: Upload Report
uses: actions/upload-artifact@v4
with:
name: modulization-report
path: .modulization/reports/
Modulization behavior can be configured via .modulization/config.yaml:
# .modulization/config.yaml
version: 1
cadence:
schedule: weekly # daily, weekly, biweekly, monthly
day: monday
timezone: UTC
signals:
codebase:
enabled: true
patterns:
- "TODO"
- "FIXME"
- "HACK"
- "XXX"
- "NOTE"
exclude_paths:
- "vendor/"
- "node_modules/"
- ".git/"
github:
enabled: true
stale_pr_days: 14
stale_issue_days: 30
include_draft_prs: true
include_closed_unmerged: true
process:
enabled: true
roadmap_path: "ROADMAP.md"
worktrees_path: ".worktrees/"
classification:
# Custom rules for classification
auto_integrate:
- label: "good first issue"
max_scope: small
- label: "quick-fix"
auto_ice:
- label: "wontfix"
- label: "deferred"
auto_archive:
- label: "duplicate"
- label: "invalid"
output:
report_path: ".modulization/reports/"
spec_seeds_path: ".modulization/spec-seeds/"
create_github_issues: false # Auto-create issues for modules
comment_on_stale: true # Add comments explaining classification
integration:
spec_kitty: true # Generate spec-kitty compatible seeds
roadmap_sync: true # Suggest ROADMAP.md updates
/spec-kitty.specifyUser: Run weekly modulization
Agent: Starting modulization scan...
š Collecting Signals
āāā Codebase: 23 TODOs, 4 FIXMEs, 2 incomplete implementations
āāā GitHub: 5 stale PRs, 8 dormant issues, 2 draft PRs
āāā Process: 4 worktrees with pending work
āāā Historical: Traced 15 items to original discussions
š§© Composing Modules
āāā MOD-001: Safety validation gaps (7 signals)
āāā MOD-002: i18n infrastructure (5 signals)
āāā MOD-003: CLI help improvements (4 signals)
āāā MOD-004: Backend retry logic (3 signals)
āāā MOD-005: Documentation sync (6 signals)
āāā MOD-006: Deprecated API cleanup (4 signals)
š Classification
āāā Integrate Now: MOD-001 (aligns with v1.1.0-beta security focus)
āāā Schedule: MOD-002 ā v1.2.0, MOD-003 ā v1.1.0, MOD-004 ā v1.1.0
āāā Ice: MOD-006 (breaking change, defer to v2.0.0)
āāā Archive: None this cycle
š Outputs Generated
āāā Report: .modulization/reports/2026-01-08-weekly.md
āāā Spec Seeds: 4 seeds for scheduled modules
āāā GitHub: Comments added to 5 stale PRs
āāā Roadmap: 2 suggested milestone additions
Would you like me to:
1. Review any specific module in detail?
2. Generate full specs for scheduled modules?
3. Create GitHub issues for tracking?
continuity_ledger ā State preservation across sessionscreate_handoff ā Work transfer documentationquality-engineer-manager ā Release validation orchestrationbeta-test-cycles ā Systematic testing improvement