feat!: Consolidate Taskless skills into one router + recipe-driven CLI help - #18
Merged
Conversation
Adds the OpenSpec change artifacts (proposal, design, tasks, spec deltas) for collapsing the 10 per-task Taskless skills into a single consolidated `taskless` skill plus single `tskl` command. Drives recipes through `npx @taskless/cli help <topic>` to remove always-loaded context bloat. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Removes the user-facing --schema flag from every CLI command (info, check, rules create/improve/meta/verify). Schemas will be embedded inline in `tskl help <topic>` output via zod-to-json-schema in a follow-up. Zod schemas themselves remain as the source of truth. Deletes packages/cli/src/util/schema-output.ts and the schema.test.ts integration tests. Drops the verify --schema CLI integration test; the underlying getSchemaPayload() function and its unit tests stay since the recipe will reuse the payload content. Part of consolidate-taskless-skills (task group 12). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Renames the help command's events to surface agent intent: cli_help → help_index (agent fetched the topic list) cli_help_<topic>→ help_<topic> (agent fetched a specific recipe) (new) → help_unknown (agent asked for a missing topic) Adds cli_<action>_completed events to every action command (info, check, rule create/improve/delete/meta/verify, auth login/logout/status) with success and durationMs properties. Hard rename — no dual-emit window. Wraps each command's run() in try/finally so the completion event fires regardless of whether the command returned normally or threw via the local fail() helper. Part of consolidate-taskless-skills (task group 11). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
BREAKING CHANGE: `taskless rules <command>` is no longer recognized. Users must invoke `taskless rule create`, `taskless rule improve`, `taskless rule delete`, `taskless rule verify`, `taskless rule meta`. Aligns the CLI verb with how recipes will address commands (`tskl help rule create` reads naturally only if the CLI takes the singular form). The internal source file `commands/rules.ts` keeps its name; the citty subcommand registration switches to `rule`. Renames help files (rules-*.txt → rule-*.txt) and updates user-facing references in error messages, README, and help text. Internal filesystem paths like `.taskless/rules/` stay (that's a directory of rules, not the verb). Part of consolidate-taskless-skills (task group 2). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Adds packages/cli/src/types/errors.ts defining the stable CliErrorCode
union (AUTH_REQUIRED, NO_GITHUB_REMOTE, RULE_GENERATION_FAILED,
RULE_NOT_FOUND, INVALID_INPUT, NETWORK_ERROR, SCAN_FAILED, INTERNAL_ERROR)
and a makeErrorEnvelope() helper.
When any action command exits with an error and --json is set, the
output is now the standardized envelope:
{ "ok": false, "code": "<CODE>", "message": "<...>" }
Migrates fail() helpers in rules create/improve/meta/verify and the
catch path in check to emit codes:
- INVALID_INPUT for --from validation, missing rule ID, bad metadata
- AUTH_REQUIRED / NO_GITHUB_REMOTE for identity resolution
- NETWORK_ERROR for API submit/poll
- RULE_GENERATION_FAILED for terminal API failures
- RULE_NOT_FOUND when rule metadata is missing
- SCAN_FAILED for ast-grep scan errors
Recipes will reference these codes by name in their `## Errors`
sections so agents can branch on them.
Part of consolidate-taskless-skills (task group 6, code paths complete;
unit tests for code-emission deferred to task 6.4 follow-up).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Recognized on every command. Behavior matrix:
rule create / rule improve → exit with pointer to local-only recipe
(per Option A: generation runs in the
agent via `taskless help <topic> --anonymous`,
not in the CLI itself)
rule delete / verify / meta → accepted as no-op (purely local)
check → accepted as no-op (no auth dependency)
info → skip the API/auth probe, report local
state only
auth login → exit 1 with "auth commands cannot be
anonymous"
auth logout → accepted as no-op (logout is local)
init → accepted as no-op
The flag is universally accepted by the parser so agents never have to
remember which commands accept it. Tests for the per-command matrix
deferred to task 3.7 follow-up.
Part of consolidate-taskless-skills (task group 3).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Removes the optional-skills wizard step (`steps/optional-skills.ts`) and the corresponding `promptOptionalSkills()` call in `runWizard()`. With v0.7's catalog reducing to a single mandatory skill, there's nothing to opt into. Bare `taskless` without a TTY now prints a short context preamble followed by the topic index from `help`, so agents and pipes get something useful instead of citty's default usage screen. Init reporting now lists obsolete skills and commands removed during re-install (the underlying state.ts already tracked them; this just surfaces the removals so users see the cleanup). Updates wizard-integration tests to drop optional-skills mocks and restructure the summary-cancel test to seed the manifest with a stale skill name (instead of relying on the optional-skill diff). Part of consolidate-taskless-skills (task group 10). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Adds three capabilities to `taskless help`:
1. Anonymous variant lookup. Filename convention <topic>.anonymous.txt
marks a local-only recipe. When `--anonymous` is passed, the help
command serves the variant if present and falls back to the
canonical recipe otherwise. The variant set is derived at build
time via import.meta.glob (O(1) lookup, no central registry).
2. Recipe placeholders. {{CLI_VERSION}} interpolates the build-time
CLI version into the recipe header. {{INPUT_SCHEMA}} interpolates
a JSON Schema rendered from the topic's Zod input source via
z.toJSONSchema() (zod 4 built-in — no zod-to-json-schema dep).
Currently wired for rule-create and rule-improve.
3. No-args index now leads with a human slug ("for agents… for
humans…") and ends with the --anonymous note. Same machine output
shape, friendlier preamble for developers who wander into it.
Telemetry: topic events now include `anonymous: boolean` so the
funnel can distinguish authed vs local-only intent.
Recipe content authoring is deferred to task 8.
Part of consolidate-taskless-skills (task group 7).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…s skill BREAKING CHANGE: Replaces the 10 per-task skills (taskless-check, taskless-ci, taskless-create-rule, taskless-create-rule-anonymous, taskless-delete-rule, taskless-improve-rule, taskless-improve-rule- anonymous, taskless-info, taskless-login, taskless-logout) with one consolidated `taskless` skill, and the 6 slash commands with one `/tskl` router command. The new skill is a ~40-line router whose body explicitly tells the agent it does NOT have step-by-step instructions and must fetch the canonical recipe via `npx @taskless/cli help <topic>`. The recipes themselves stay in the CLI bundle (per task 8) so agents always read the version current to the installed CLI, not whatever was frozen into a SKILL.md at install time. The trigger description anchors on Taskless-specific phrases or .taskless/ directory references and explicitly says "do NOT trigger on generic ESLint, linting, or rule requests". This tightens the over-firing of the previous create/improve/delete triggers, which listed phrases like "create a rule" / "add a lint rule" with no Taskless anchor. Catalog reduces to a single mandatory entry (`taskless`). getOptionalSkillNames() and isOptionalSkill() now return empty / false. The Vite assertSkillVersions guard already handles arbitrary catalog sizes. Existing v0.6 installs auto-migrate via the idempotent reinstall path in install.ts: the manifest records the 10 old skill names; on next init, applyInstallPlan reads the previous state, computes removals, deletes the obsolete files, writes the new single skill + command, and updates the manifest. Init reporting (added in task 10) surfaces the cleanup so users see what changed. Test fixtures (apply-install-plan, wizard-integration, init-no- interactive, cli) updated to reference the new skill name. The "does NOT install optional skills" test is removed since there are no optional skills. Part of consolidate-taskless-skills (task groups 1 and 9). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…test
Adds an integration test in apply-install-plan.test.ts that:
1. Seeds 10 v0.6 skill directories and 6 v0.6 command files on disk
2. Records all of them in the install state manifest (as v0.6 would
have left it)
3. Runs applyInstallPlan with the v0.7 plan (single taskless skill
+ single tskl.md command)
4. Asserts:
- 10 obsolete skills + 6 obsolete commands removed from disk
- new taskless/SKILL.md + commands/tskl/tskl.md present
- manifest updated to reflect the new layout
- returned counts match (10 removed skills, 6 removed commands,
1 written skill, 1 written command)
Proves the idempotent reinstall path correctly migrates v0.6 installs
to v0.7 without requiring a separate migration script.
Part of consolidate-taskless-skills (task group 13).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Rewrites every help/*.txt file to follow the recipe template:
# Topic: <name> (CLI v{{CLI_VERSION}} / topic v1)
## Goal
## Preconditions
## Steps
## Input schema (where applicable, via {{INPUT_SCHEMA}})
## Errors
## See Also
Recipes authored:
- rule-create.txt — API-backed; embeds zod-derived JSON schema
- rule-create.anonymous.txt — local-only; agent-driven verify loop
- rule-improve.txt — API-backed; embeds iterate input schema
- rule-improve.anonymous.txt — local-only; in-place edit + verify loop
- rule-delete.txt — local file removal
- rule-verify.txt — agent-internal, used by anonymous loops
- rule-meta.txt — agent-internal, used by improve flow
- rule.txt — umbrella pointing at the subcommand recipes
- check.txt — full + diff scan patterns, JSON output shape
- auth.txt — combined login/logout/status with branches
- info.txt — local state report
- ci.txt — ported from v0.6 taskless-ci skill body
- init.txt — points user at `npx @taskless/cli`
Removes the obsolete per-subcommand auth-login.txt / auth-logout.txt
files; auth.txt now covers all three branches.
Each recipe ends with an Errors table mapping the standardized
CliErrorCode values (AUTH_REQUIRED, NO_GITHUB_REMOTE, INVALID_INPUT,
NETWORK_ERROR, RULE_GENERATION_FAILED, RULE_NOT_FOUND, SCAN_FAILED,
INTERNAL_ERROR) to user-facing fixes — agents can branch on the code
field of the JSON error envelope.
Smoke-tested: `taskless help rule create` renders correctly with the
embedded schema; `--anonymous` returns the local-only variant;
`taskless help` prints the new human slug + topic table.
Part of consolidate-taskless-skills (task group 8).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Adds a changeset describing the consolidate-taskless-skills change: - 10 per-task skills + 6 commands → 1 skill + 1 command - CLI verb rename (rules → rule, breaking) - --schema flag removed - Global --anonymous flag added - Telemetry rename (hard cut) - Standardized JSON error envelope - Recipe template + on-demand fetch via `taskless help <topic>` Migration is automatic on next `npx @taskless/cli` (idempotent reinstall reads the manifest, deletes obsolete files, writes the new single skill + command). Updates the root README to reflect the consolidated structure and the new "add a topic recipe" workflow (replaces "add a new skill"). Updates packages/cli/README.md with the new init wizard description (no optional-skills step), `--anonymous` matrix, and `taskless help` documentation. Plugin/marketplace JSON version bumps are deferred to `pnpm bump` (part of the release workflow that consumes the changeset). Closes the consolidate-taskless-skills OpenSpec change. All 12 task groups complete; ready for /opsx:archive. Part of consolidate-taskless-skills (task group 15). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Adds three new test files (31 tests total):
error-envelope.test.ts (7 tests):
Asserts each command's --json failure path emits the standardized
{ ok: false, code, message } envelope with the documented stable
codes (INVALID_INPUT for missing/bad --from input, RULE_NOT_FOUND
for missing rule meta, etc.). Also asserts the envelope shape has
exactly the documented fields.
anonymous-flag.test.ts (10 tests):
Covers the per-command --anonymous behavior matrix end-to-end:
- info skips API/auth probe (loggedIn: false)
- auth login rejects with "auth commands cannot be anonymous"
- auth logout / check / rule delete / rule verify / rule meta /
init: accept as no-op (same behavior as without the flag)
- rule create / rule improve: exit with pointer to local-only recipe
help-extensions.test.ts (12 tests):
- No-args output: human slug, topic table, --anonymous mention
- Recipe rendering: {{CLI_VERSION}} and {{INPUT_SCHEMA}} interpolation
- Anonymous variant: returns .anonymous variant when present, falls
back to canonical when absent, omitted flag returns canonical
- Unknown topic exits non-zero
- Bare taskless (non-TTY) routes to topic index with preamble
Also fixes a small regression in bare-taskless non-TTY: the parent's
`-d <path>` flag was being mis-parsed as a topic name by the help
command. Now forwards the parent's rawArgs explicitly so the help
command's flag-aware positional extraction handles them correctly.
Closes the deferred test items 6.4, 3.7, and 7.7.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Adds a dedicated `taskless update` subcommand that runs the same non-interactive install path as `taskless init --no-interactive` but without requiring the agent to know about (or explain) the flag. Detects installed tools, computes the diff against the recorded state, writes the consolidated skill, removes obsolete files, and prints a summary. Use case: agent or user already has Taskless installed and wants to refresh to a new bundled version. `npx @taskless/cli update` is the clean way to ask for that without a wizard popping up. Emits cli_update / cli_update_completed telemetry events with the same `locations`, `success`, `durationMs` shape as init. Updates the consolidated skill body and the /tskl router to include the new "Update existing install → `npx @taskless/cli update`" row. Adds `help/update.txt` recipe. Tests: two new cases in init-no-interactive.test.ts cover the detected-tools and `.agents/` fallback paths for `update`. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Syncs the change's delta specs into the main spec catalog and moves
the change directory to openspec/changes/archive/.
Spec sync summary:
ADDED (new main spec):
• skill-taskless
MODIFIED (8 capabilities merged):
• analytics — telemetry rename to help_*/cli_*_completed
• cli — global --anonymous flag + standardized error envelope
• cli-auth — --anonymous handling on login/logout + error envelope
• cli-check — --anonymous no-op + error envelope
• cli-help — anonymous variant lookup, schema embedding,
no-args index slug, intent telemetry
• cli-init — wizard simplification (no optional skills),
install manifest changes, bare-taskless routing
• cli-rules — rules → rule rename across every requirement,
anonymous local-only branches added
• skills — collapsed per-task skills into single taskless
skill, plugin manifest, command file conventions
REMOVED (7 capability dirs deleted):
• cli-flag-schema (--schema flag removed)
• skill-create-rule, skill-improve-rule, skill-delete-rule,
skill-auth-login, skill-auth-logout, skill-ci
(folded into skill-taskless)
Tasks.md cleaned up before archive: tasks 5.1-5.4 marked as
superseded by Option A (anonymous flow stays agent-driven),
others closed against where they were actually completed.
Build clean, 186/186 tests pass.
Closes TSKL-231.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR consolidates Taskless’s agent surface area by replacing multiple per-task skills/commands with a single taskless router skill and a single /tskl router command, shifting detailed agent instructions into on-demand CLI “help recipes” (taskless help <topic>). It also updates the CLI to support recipe variant lookup (--anonymous), standardized JSON error envelopes, a rules → rule verb rename, and adds a dedicated taskless update subcommand.
Changes:
- Replace 10 Taskless skills + 6 slash commands with one router skill (
skills/taskless) and one router command (commands/tskl/tskl.md). - Add/expand
taskless helprecipe system (topic index, per-topic recipes, anonymous variants, schema interpolation). - Update CLI behavior: global
--anonymousmatrix, standardized{ ok:false, code, message }JSON failures, telemetry taxonomy changes, andtaskless update.
Reviewed changes
Copilot reviewed 100 out of 100 changed files in this pull request and generated 10 comments.
Show a summary per file
| File | Description |
|---|---|
| skills/taskless/SKILL.md | Adds the consolidated router skill that delegates to taskless help <topic>. |
| skills/taskless-logout/SKILL.md | Removes legacy per-task skill (logout). |
| skills/taskless-login/SKILL.md | Removes legacy per-task skill (login). |
| skills/taskless-info/SKILL.md | Removes legacy per-task skill (info). |
| skills/taskless-improve-rule/SKILL.md | Removes legacy per-task skill (improve rule). |
| skills/taskless-improve-rule-anonymous/SKILL.md | Removes legacy per-task skill (anonymous improve). |
| skills/taskless-delete-rule/SKILL.md | Removes legacy per-task skill (delete rule). |
| skills/taskless-create-rule/SKILL.md | Removes legacy per-task skill (create rule). |
| skills/taskless-create-rule-anonymous/SKILL.md | Removes legacy per-task skill (anonymous create). |
| skills/taskless-check/SKILL.md | Removes legacy per-task skill (check). |
| README.md | Updates repo docs to describe the consolidated skill/command + recipe approach. |
| packages/cli/test/wizard-integration.test.ts | Updates wizard integration tests for “no optional skills” and consolidated install output. |
| packages/cli/test/verify.test.ts | Removes CLI-level rules verify --schema test now that --schema is removed. |
| packages/cli/test/rule-from.test.ts | Updates tests for rules → rule verb rename. |
| packages/cli/test/init-no-interactive.test.ts | Updates init tests for consolidated skill; adds taskless update coverage. |
| packages/cli/test/help-extensions.test.ts | Adds end-to-end tests for help index/topics, interpolation, variants, and non-TTY routing. |
| packages/cli/test/error-envelope.test.ts | Adds tests asserting standardized JSON error envelope codes/shape. |
| packages/cli/test/cli.test.ts | Updates CLI install test to check new consolidated skill + router command. |
| packages/cli/test/anonymous-flag.test.ts | Adds coverage for the per-command --anonymous behavior matrix. |
| packages/cli/src/wizard/steps/optional-skills.ts | Removes optional-skills wizard step implementation. |
| packages/cli/src/wizard/index.ts | Updates wizard flow to remove optional skills selection and install embedded skills directly. |
| packages/cli/src/util/schema-output.ts | Removes deprecated --schema printing utility. |
| packages/cli/src/types/errors.ts | Introduces stable error-code union + JSON envelope helpers. |
| packages/cli/src/install/catalog.ts | Shrinks skill catalog to a single mandatory taskless skill. |
| packages/cli/src/index.ts | Adds update subcommand, renames rules → rule, and routes non-TTY bare taskless to help index. |
| packages/cli/src/help/update.txt | Adds a recipe for the new update topic. |
| packages/cli/src/help/rules.txt | Removes old rules help topic file. |
| packages/cli/src/help/rules-verify.txt | Removes old rules verify help topic file. |
| packages/cli/src/help/rules-meta.txt | Removes old rules meta help topic file. |
| packages/cli/src/help/rules-improve.txt | Removes old rules improve help topic file. |
| packages/cli/src/help/rules-delete.txt | Removes old rules delete help topic file. |
| packages/cli/src/help/rules-create.txt | Removes old rules create help topic file. |
| packages/cli/src/help/rule.txt | Adds new rule umbrella recipe topic. |
| packages/cli/src/help/rule-verify.txt | Adds new rule verify recipe topic. |
| packages/cli/src/help/rule-meta.txt | Adds new rule meta recipe topic. |
| packages/cli/src/help/rule-improve.txt | Adds new API-backed rule improve recipe topic. |
| packages/cli/src/help/rule-improve.anonymous.txt | Adds local-only rule improve --anonymous recipe variant. |
| packages/cli/src/help/rule-delete.txt | Adds new rule delete recipe topic. |
| packages/cli/src/help/rule-create.txt | Adds new API-backed rule create recipe topic. |
| packages/cli/src/help/rule-create.anonymous.txt | Adds local-only rule create --anonymous recipe variant. |
| packages/cli/src/help/init.txt | Rewrites init help into the canonical recipe template. |
| packages/cli/src/help/info.txt | Rewrites info help into the canonical recipe template, including --anonymous behavior. |
| packages/cli/src/help/ci.txt | Adds CI wiring recipe as a help topic (replacing optional CI skill). |
| packages/cli/src/help/check.txt | Rewrites check help into the canonical recipe template. |
| packages/cli/src/help/auth.txt | Rewrites auth help into the canonical recipe template. |
| packages/cli/src/help/auth-logout.txt | Removes old auth-logout help topic file. |
| packages/cli/src/help/auth-login.txt | Removes old auth-login help topic file. |
| packages/cli/src/commands/init.ts | Adds update subcommand and makes --anonymous accepted for init/update. |
| packages/cli/src/commands/info.ts | Adds --anonymous behavior and completion telemetry; swaps to standardized envelope helper. |
| packages/cli/src/commands/help.ts | Implements recipe lookup, anonymous variants, interpolation, and new telemetry events. |
| packages/cli/src/commands/check.ts | Accepts --anonymous (no-op), adds standardized error envelope on scan failures, and completion telemetry. |
| packages/cli/src/commands/auth.ts | Adds --anonymous behavior handling + completion telemetry. |
| packages/cli/README.md | Updates CLI docs for singular rule, help recipes, and --anonymous behavior matrix. |
| openspec/specs/skill-taskless/spec.md | Adds spec for the consolidated taskless skill/router behavior. |
| openspec/specs/skill-improve-rule/spec.md | Removes superseded per-skill spec (improve rule). |
| openspec/specs/skill-delete-rule/spec.md | Removes superseded per-skill spec (delete rule). |
| openspec/specs/skill-ci/spec.md | Removes superseded per-skill spec (CI). |
| openspec/specs/skill-auth-logout/spec.md | Removes superseded per-skill spec (auth logout). |
| openspec/specs/skill-auth-login/spec.md | Removes superseded per-skill spec (auth login). |
| openspec/specs/cli/spec.md | Extends CLI spec for --anonymous and standardized error envelopes. |
| openspec/specs/cli-flag-schema/spec.md | Removes spec for the deprecated --schema flag. |
| openspec/specs/cli-check/spec.md | Adds check requirements for --anonymous no-op + standardized envelope on failure. |
| openspec/specs/cli-auth/spec.md | Updates auth spec for --anonymous handling and JSON envelope requirements. |
| openspec/specs/analytics/spec.md | Updates telemetry taxonomy (help intent + action start/completion). |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/skills/spec.md | Archives consolidated skill/command requirements snapshot (change record). |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/skill-taskless/spec.md | Archives consolidated taskless skill spec (change record). |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/skill-improve-rule/spec.md | Archives removal/migration notes for improve-rule skill spec. |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/skill-delete-rule/spec.md | Archives removal/migration notes for delete-rule skill spec. |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/skill-create-rule/spec.md | Archives removal/migration notes for create-rule skill spec. |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/skill-ci/spec.md | Archives removal/migration notes for CI skill spec. |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/skill-auth-logout/spec.md | Archives removal/migration notes for auth-logout skill spec. |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/skill-auth-login/spec.md | Archives removal/migration notes for auth-login skill spec. |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/cli/spec.md | Archives CLI requirements for consolidation (change record). |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/cli-init/spec.md | Archives init/update behavior requirements (change record). |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/cli-help/spec.md | Archives help recipe/variant/schema requirements (change record). |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/cli-flag-schema/spec.md | Archives removal/migration notes for --schema flag. |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/cli-check/spec.md | Archives check changes requirements (change record). |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/cli-auth/spec.md | Archives auth changes requirements (change record). |
| openspec/changes/archive/2026-05-10-consolidate-taskless-skills/specs/analytics/spec.md | Archives telemetry taxonomy changes (change record). |
| commands/tskl/tskl.md | Adds single /tskl router command file. |
| commands/tskl/rule.md | Removes legacy per-command router file. |
| commands/tskl/logout.md | Removes legacy per-command router file. |
| commands/tskl/login.md | Removes legacy per-command router file. |
| commands/tskl/info.md | Removes legacy per-command router file. |
| commands/tskl/improve.md | Removes legacy per-command router file. |
| commands/tskl/check.md | Removes legacy per-command router file. |
| .changeset/consolidate-taskless-skills.md | Adds changeset describing the consolidation, breaking changes, and new features. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Drop obsolete scripts/generate-commands.ts and its build:/bump: hooks. The script's prefix-based "skills/taskless-*" model is incompatible with the v0.7 consolidation: there is now one skills/taskless/SKILL.md plus a single hand-authored commands/tskl/tskl.md whose body intentionally diverges from the skill body. Update the infrastructure spec and README to reflect that command files are now hand-maintained. Address Copilot review feedback on PR #18: - rule-create.txt: report timestamped test path .taskless/rule-tests/<id>-YYYYMMDD-test.yml in step 9. - rule-create.anonymous.txt: stop claiming {{INPUT_SCHEMA}} embeds the ast-grep schema. Point step 1 to the upstream ast-grep rule reference; rewrite the "ast-grep schema" section to be honest about what is and isn't embedded; reword the Errors header so verify's layered output is not confused with the {ok:false,...} envelope. - rule-delete.txt: replace the --json envelope table with the actual plain-text behavior; rule delete does not accept --json. - auth.txt: replace the --json envelope table with documented plain-text behavior for each failure mode; auth commands do not accept --json. - check.txt: clarify that success:false in JSON output means rule matches were found (an expected outcome) and that the {ok:false,code,message} envelope only applies to scan failures such as SCAN_FAILED. - info.ts: write the INTERNAL_ERROR envelope to stdout via console.log instead of stderr, matching every other JSON-mode output path. Lint, typecheck, build, and the 186-test suite all pass locally. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The cli capability spec mandates a standardized { ok:false, code,
message } envelope on stdout when --json is set and the command
exits with an error. cli-auth/spec.md scenario "Auth login network
failure in JSON mode" makes this explicit for the auth subcommands.
The implementations were missing the flag entirely, leaving the
recipes and the spec divergent.
Add --json support and the envelope path to:
- auth login: --anonymous rejection emits INVALID_INPUT; device-flow
cancellations route by reason (denied -> AUTH_REQUIRED; expired or
caught error -> NETWORK_ERROR). The URL/code chatter is suppressed
in --json mode so stdout stays a single parseable envelope on
failure.
- auth logout: accepts --json. Success is silent on stdout; the
envelope path is reserved for future error cases. No real error
paths exist today, so no behavior change on the happy path.
- auth (status, no subcommand): accepts --json for forward-compat;
status output stays plain text since there are no error paths.
- rule delete: --json + missing rule -> RULE_NOT_FOUND envelope.
Success is silent on stdout in --json mode.
Recipes (auth.txt, rule-delete.txt) are restored to document the
--json envelope contract now that the implementation matches.
Tests in error-envelope.test.ts cover rule delete (RULE_NOT_FOUND
and silent success), auth login --anonymous --json (INVALID_INPUT),
and auth logout --json (silent success). 190 tests pass.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Result of running the locally-built CLI to install the v0.7 consolidation into this repo's own .claude directory, used as a test bed for verifying the install/migration flow end-to-end. - Remove the 10 stale per-task taskless-* skill symlinks (taskless-check, taskless-ci, taskless-create-rule, taskless-create-rule-anonymous, taskless-delete-rule, taskless-improve-rule, taskless-improve-rule-anonymous, taskless-info, taskless-login, taskless-logout). Their source directories were deleted in the consolidation; the symlinks were dangling. - Add .claude/skills/taskless symlink pointing at the consolidated skill source. - Add .claude/.gitignore to keep local-state files (*.local.json, *.lock) out of the repo. - Update .taskless/taskless.json to reflect the new single-skill manifest and bump the recorded cliVersion to 0.6.0. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…recipes) Address the latest Copilot review feedback on PR #18: - check.txt (medium): correct the `success` field semantics. The CLI sets success based on whether any error-severity finding exists, not whether any match exists. Rewrite step 4 to explicitly cover all three cases: success:false (>=1 error finding, exit 1); success:true with non-empty results (warning/info/hint only, exit 0); empty results (clean). Restate that findings are not envelope-routed; the envelope only appears on scan failure. - check.txt (low): rewrite the step-3 JSON sample to match the real `CheckResult` shape (`source`, `ruleId`, `severity`, `message`, `note`, `file`, `range: { start, end }`, `matchedText`, `fix`) so agents don't parse non-existent keys. - README.md (low): add `update` to the `taskless help` topic inventory now that the recipe and subcommand exist. - auth.ts (low): track the emitted `CliErrorCode` in the login command's `fail` closure and include `errorCode` on `cli_auth_login_completed` when `success: false`, per the analytics spec. Scoped to this file; rolling the pattern across other `cli_<action>_completed` events is a broader cleanup tracked separately. - update.txt (low): drop the contradictory "silent on success" line and document the actual behavior (prints a summary of skills/commands added, removed, or kept in sync, matching `init --no-interactive`). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The Errors section of rule-create.anonymous.txt claimed
\`rule verify --json\` always emits the layered result and never the
\`{ ok:false, code, message }\` envelope. That's wrong: when \`<id>\`
is missing, the command emits the standardized INVALID_INPUT
envelope on stdout and exits non-zero; only when \`<id>\` is supplied
does it emit the layered \`{ success, schema, requirements, tests }\`
shape. Split the Errors table into envelope vs layered rows so the
two paths are unambiguous.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
thecodedrift
marked this pull request as ready for review
May 12, 2026 03:08
thecodedrift
added a commit
that referenced
this pull request
May 12, 2026
Drop obsolete scripts/generate-commands.ts and its build:/bump: hooks. The script's prefix-based "skills/taskless-*" model is incompatible with the v0.7 consolidation: there is now one skills/taskless/SKILL.md plus a single hand-authored commands/tskl/tskl.md whose body intentionally diverges from the skill body. Update the infrastructure spec and README to reflect that command files are now hand-maintained. Address Copilot review feedback on PR #18: - rule-create.txt: report timestamped test path .taskless/rule-tests/<id>-YYYYMMDD-test.yml in step 9. - rule-create.anonymous.txt: stop claiming {{INPUT_SCHEMA}} embeds the ast-grep schema. Point step 1 to the upstream ast-grep rule reference; rewrite the "ast-grep schema" section to be honest about what is and isn't embedded; reword the Errors header so verify's layered output is not confused with the {ok:false,...} envelope. - rule-delete.txt: replace the --json envelope table with the actual plain-text behavior; rule delete does not accept --json. - auth.txt: replace the --json envelope table with documented plain-text behavior for each failure mode; auth commands do not accept --json. - check.txt: clarify that success:false in JSON output means rule matches were found (an expected outcome) and that the {ok:false,code,message} envelope only applies to scan failures such as SCAN_FAILED. - info.ts: write the INTERNAL_ERROR envelope to stdout via console.log instead of stderr, matching every other JSON-mode output path. Lint, typecheck, build, and the 186-test suite all pass locally. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
thecodedrift
added a commit
that referenced
this pull request
May 12, 2026
…recipes) Address the latest Copilot review feedback on PR #18: - check.txt (medium): correct the `success` field semantics. The CLI sets success based on whether any error-severity finding exists, not whether any match exists. Rewrite step 4 to explicitly cover all three cases: success:false (>=1 error finding, exit 1); success:true with non-empty results (warning/info/hint only, exit 0); empty results (clean). Restate that findings are not envelope-routed; the envelope only appears on scan failure. - check.txt (low): rewrite the step-3 JSON sample to match the real `CheckResult` shape (`source`, `ruleId`, `severity`, `message`, `note`, `file`, `range: { start, end }`, `matchedText`, `fix`) so agents don't parse non-existent keys. - README.md (low): add `update` to the `taskless help` topic inventory now that the recipe and subcommand exist. - auth.ts (low): track the emitted `CliErrorCode` in the login command's `fail` closure and include `errorCode` on `cli_auth_login_completed` when `success: false`, per the analytics spec. Scoped to this file; rolling the pattern across other `cli_<action>_completed` events is a broader cleanup tracked separately. - update.txt (low): drop the contradictory "silent on success" line and document the actual behavior (prints a summary of skills/commands added, removed, or kept in sync, matching `init --no-interactive`). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Collapses the 10 per-task Taskless skills + 6 slash commands into a single
tasklessskill plus a single/tsklrouter. Per-task instructions move out of always-loaded skill bodies and intonpx @taskless/cli help <topic>recipes, fetched on demand.A customer reported that loading the Taskless plugin caused the Claude Code harness to evict other skills from the working set. Codex behaves similarly. The 1,367 lines previously committed across 10 SKILL.md files + 6 near-duplicate slash command files were inflating the agent's always-loaded surface even when the user wasn't doing anything Taskless-related. Worse, the per-skill triggers were inconsistent —
taskless-create-rulelisted phrases like"create a rule","add a lint rule","detect this pattern"with no Taskless anchor, so it over-fired in any repo that uses ESLint.This change is the result of a long design conversation captured in
openspec/changes/archive/2026-05-10-consolidate-taskless-skills/(proposal, design, tasks, 16 capability spec deltas). The high-bit decisions:Skill body becomes a router, not a recipe. The new
skills/taskless/SKILL.mdis ~50 lines: it tells the agent it does NOT have the steps, instructs it to fetch the canonical recipe vianpx @taskless/cli help <topic>, and lists the available topics. Recipes live in the CLI bundle, so agents always read the version current to the installed CLI rather than whatever was frozen into a SKILL.md at install time.Trigger description anchors on Taskless. The single description requires the user to reference Taskless explicitly OR for
.taskless/to be referenced. Generic ESLint/lint/rule phrasing without that anchor SHALL NOT trigger. The skill body's first step is a.taskless/presence check with graceful failure ("ask the user to confirm they meant Taskless"). This is strictly better than today's mixed-bag where rule-create/improve/delete fire promiscuously.--anonymousis global, with a per-command behavior matrix (option A from the design discussion). Oninfoit skips the API/auth probe; onauth loginit errors with "auth commands cannot be anonymous"; onrule create/rule improvethe CLI exits with a pointer to the local-only recipe variant (the agent owns the local generation flow per the recipe — we did NOT bundle Claude SDK in the CLI). Everywhere else it's accepted as a no-op so agents don't have to remember which commands accept it.Anonymous variants live as
<topic>.anonymous.txtalongside the canonical recipes. Build-time map keeps lookup O(1); fetchingtaskless help rule create --anonymousreturns the variant when one exists and falls back to the canonical recipe otherwise. No central registry to keep in sync.Recipe template is fixed. Every
tskl help <topic>returns the same shape:# Topic: <name> (CLI v<x.y.z> / topic v<n>)header,## Goal,## Preconditions,## Steps, optional## Input schema(JSON Schema rendered from Zod viaz.toJSONSchema()and interpolated through a{{INPUT_SCHEMA}}placeholder),## Errors(mapping stable error codes to user-facing fixes),## See Also. The fixed shape lets agents pattern-match consistently.Standardized JSON error envelope. When
--jsonis set, failures emit{ ok: false, code: \"<CODE>\", message: \"<...>\" }with stable codes (AUTH_REQUIRED,NO_GITHUB_REMOTE,RULE_GENERATION_FAILED,RULE_NOT_FOUND,INVALID_INPUT,NETWORK_ERROR,SCAN_FAILED,INTERNAL_ERROR). Recipes reference these codes by name in their## Errorssections so agents can branch on the code field rather than parsing English error strings.CLI verb rename:
rules→rule(singular) sotskl help rule createreads naturally and the next CLI command the agent runs is the same noun (taskless rule create). No compatibility alias — the plural form errors cleanly.Telemetry hard-renamed to
help_<topic>(intent),help_index(no-args fetch),help_unknown(probable confusion),cli_<action>(action started),cli_<action>_completed(success + durationMs). The funnel makes wrong-topic re-routing observable as a derivable signal: ahelp_<topic_a>event followed by nocli_<action_a>and a subsequenthelp_<topic_b>indicates the agent fetched, didn't act, and re-routed.taskless updateas its own subcommand. Same logic asinit --no-interactivebut exposed as a dedicated verb so agents can refresh installs without explaining flags.Migration is automatic. The existing
state.tsinstall plumbing records what was written per target. On nextnpx @taskless/cli, the install reads previous state, computes the diff (10 obsolete skills + 6 obsolete commands removed, 1 new skill + 1 new command added), confirms with the user, applies, and reports the cleanup. Integration test inapply-install-plan.test.tsproves the v0.6 → v0.7 path end-to-end.Out of scope for this change (deliberate non-goals from the design):
tskl helpoutput (markdown is sufficient for agents)The full motivation, alternatives considered, decisions, risks, and open questions are captured in
openspec/changes/archive/2026-05-10-consolidate-taskless-skills/{proposal,design}.md.Closes TSKL-231 (internal feedback)