docs(openspec): Propose local-rule-routing change#23
Open
thecodedrift wants to merge 9 commits into
Open
Conversation
Add the change contract for a local-first rule-routing layer: a deterministic detect command plus route/existing/static/remote recipes that keep authoring on-device and gate the login wall behind reasonable confidence with a confirm-before-service fallback. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Defines a spec-driven OpenSpec contract for a local-first rule-authoring “routing front door” in Taskless, centered around an offline detect signal scan and a help-recipe based classifier (route) that prefers local authoring paths (existing / static) and escalates to the service (remote) only with explicit user confirmation when needed.
Changes:
- Adds a new OpenSpec change set (
local-rule-routing) with proposal/design docs and a spec-driven manifest. - Introduces CLI requirements for
taskless detect --jsonand for theroute/existing/static/remotehelp-recipe layer (including rationale-first and confirmation-gated escalation semantics). - Updates the
skill-tasklesscontract to engage routing when a linter is named (instead of suppressing) and to route rule-authoring via the newroutetopic.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 12 comments.
Show a summary per file
| File | Description |
|---|---|
| openspec/changes/local-rule-routing/specs/skill-taskless/spec.md | Updates the skill triggering and routing contract to use the new routing front door. |
| openspec/changes/local-rule-routing/specs/cli-rule-routing/spec.md | Specifies the routing recipe contract and the three destinations (existing/static/remote). |
| openspec/changes/local-rule-routing/specs/cli-help/spec.md | Requires help-topic registration + telemetry for routing topics. |
| openspec/changes/local-rule-routing/specs/cli-detect/spec.md | Specifies an offline, deterministic detect --json signal scan + stable JSON output requirement. |
| openspec/changes/local-rule-routing/proposal.md | High-level motivation, scope, and impact summary for the change stack. |
| openspec/changes/local-rule-routing/design.md | Detailed design decisions, constraints, and routing rationale/fallback model. |
| openspec/changes/local-rule-routing/.openspec.yaml | Declares the change set as spec-driven with creation date. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Resolve Copilot review on PR #23: - Drop the "provably cannot be built locally" framing in the proposal; it set a stricter bar than the confidence-gated contract. Login is suggested when route is not reasonably confident a rule is locally solvable, or when a confident local attempt fails and the user confirms. - Tighten the cli-rule-routing spec so routing distinguishes three states: confident-local, reasonable-belief-not-local (-> remote), and genuine uncertainty (-> ask). Mere uncertainty no longer reads as a remote trigger. - Reference the canonical `npx @taskless/cli help route` invocation in the skill-taskless spec instead of a bare `taskless` binary name. - Fix Markdown inline-code spans that were split across line breaks. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Reword the cli-detect spec: detect validates its --json output against an internal Zod schema before printing (same as info/check), rather than a "published output schema." The schema is an internal contract and detect exposes no --schema mode. Resolves the remaining Copilot note on PR #23. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This was referenced Jun 12, 2026
Add the change contract for a local-first rule-routing layer: a deterministic detect command plus route/existing/static/remote recipes that keep authoring on-device and gate the login wall behind reasonable confidence with a confirm-before-service fallback. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Resolve Copilot review on PR #23: - Drop the "provably cannot be built locally" framing in the proposal; it set a stricter bar than the confidence-gated contract. Login is suggested when route is not reasonably confident a rule is locally solvable, or when a confident local attempt fails and the user confirms. - Tighten the cli-rule-routing spec so routing distinguishes three states: confident-local, reasonable-belief-not-local (-> remote), and genuine uncertainty (-> ask). Mere uncertainty no longer reads as a remote trigger. - Reference the canonical `npx @taskless/cli help route` invocation in the skill-taskless spec instead of a bare `taskless` binary name. - Fix Markdown inline-code spans that were split across line breaks. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Reword the cli-detect spec: detect validates its --json output against an internal Zod schema before printing (same as info/check), rather than a "published output schema." The schema is an internal contract and detect exposes no --schema mode. Resolves the remaining Copilot note on PR #23. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
6923eb3 to
934cfb9
Compare
A change is archived exactly once, when all of its work has landed. In a stack of PRs, only the tip carries the archived change; the PRs below it still carry the in-flight change directory by design — so failing the archive check on them is noise. Split the workflow into a stack-position detector and the archive check. The detector marks a PR as the tip when no other OPEN PR targets its head branch as a base; the archive job is gated on that, so non-tip PRs show the check as SKIPPED and only the tip (or a standalone PR) runs it. Also broaden the trigger from base=main to all PRs so the (skipped) check is visible across the whole stack, mirroring how we think about changes in flight vs all changes landed. Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* main: chore(skill): Refine the stacked-PR archive-check guidance chore(skill): Scope iterate-pr archive check to the stack tip chore(config): Allow git-town in project settings
…at/local-rule-routing * origin/feat/local-rule-routing: ci(openspec): Skip the archive check on non-tip stacked PRs (#31) docs(openspec): Clarify detect output schema is internal, not published docs(openspec): Address review feedback on local-rule-routing contract docs(openspec): Propose local-rule-routing change
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.
Establish the OpenSpec change contract for a local-first rule-routing layer in the Taskless CLI and skill.
Today authoring a rule routes straight to the login-gated
rule create, which runs generation off the developer's machine, and the skill suppresses itself whenever a user names a linter (eslint, ruff, biome) — stepping back from exactly the requests where Taskless could help author the rule in that tool's dialect. This change defines a routing front door that keeps authoring on-device whenever possible and only escalates to the service (with explicit confirmation) when a rule genuinely can't be built locally.The contract introduces:
cli-detect— a deterministic, offlinetaskless detect --jsonsignal scan.cli-rule-routing—route/existing/static/remoterecipes with a confidence-gated contract: reason before routing, commit local on reasonable confidence, and treat try-verify-escalate as a failure fallback that prompts-and-confirms before spending a generation.cli-help(modified) — register the four routing topics + intent telemetry.skill-taskless(modified) — reverse named-tool suppression so naming a linter engages routing; the 1024-char description ceiling is a first-class gating constraint.This change deliberately does not define static-vs-runtime classification — that cut is owned upstream by the Runtime Rules project (TSKL) and lives behind
remote.routeonly decides local-vs-remote.This is the base of a stack; implementation PRs land on top of it group by group.
Refs TSKL Runtime Rules
Stack generated by Git Town