Skip to content

Deepen task metadata behind a Task Registry #45

@derek-palmer

Description

@derek-palmer

Problem Statement

Task metadata is scattered across prompt files, CLI refresh lists, MCP tool discovery, Python installer slugs, Node installer slugs, README tables, prompt guide rows, skill folders, lock metadata, and tests. Adding arch-review exposed this shallow module shape: task identity and task policy have no single interface, so each new task requires broad synchronized edits.

Solution

Add a Task Registry as the source of truth for public task identity and policy. The registry should deepen task metadata behind one interface consumed by CLI, MCP, installers, and tests. Prompt files remain authoritative for prompt content.

Decisions

  • Add hand-authored src/codeforerunner/tasks.json as static registry source.
  • Add src/codeforerunner/tasks.py as typed interface over the JSON.
  • Bundle tasks.json in package data.
  • Registry owns policy: task name, prompt file stem, scan exemption, refresh inclusion/order, skill slug, default output path, short description.
  • Prompt files own task instructions and output contract.
  • forerunner doc <task> rejects unregistered tasks even if a prompt file exists.
  • MCP lists and calls only registered tasks.
  • Refresh order comes from registry via refresh_order; arch-review stays excluded.
  • Scan exemption comes from registry; scan and init-agent-onboarding are exempt.
  • Installable task skill slugs come from registry. Canonical codeforerunner skill remains separate.
  • Distribution paths are derived from skill_slug: skills/{slug}/SKILL.md and plugins/codeforerunner/skills/{slug}/SKILL.md.
  • Node installer reads the same checked-in JSON instead of mirroring a JS slug array.
  • Include forerunner-refresh in Python installer surfaces; current Node installer includes it but Python installer does not.
  • Do not generate README or prompt guide tables from registry in this pass.
  • Do not put arch-review attribution metadata in registry.

Testing Decisions

  • Registry tasks all have prompt files.
  • Public prompt files are registered or intentionally private if that concept is added later.
  • forerunner doc rejects unregistered prompt files.
  • MCP tool list includes only registered tasks.
  • Refresh emits tasks sorted by refresh_order and excludes arch-review.
  • CLI and MCP scan-exempt behavior reads registry.
  • Installer task slugs read registry and include forerunner-refresh.
  • Node and Python installers consume the same JSON registry.

Out of Scope

  • Generating README or prompt-guide tables from registry.
  • Generating skill files from registry.
  • Changing prompt task content.
  • Creating a full build system around task metadata.

Origin

This Deepening Opportunity came from running /improve-codebase-architecture after implementing issue #43 (arch-review).

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions