Skip to content
Source
Sign inSign up
TanStack/intent

Add interactive skill permission setup to `intent install` #220

ClosedLadyBluenotes(GitHub profile, opens in a new tab) opened this issue 0 comments

Problem

intent install currently writes generic loading guidance by default, while intent install --map scans already permitted skills, or all discovered packages when no allowlist is set, and writes mappings. It does not help a consumer discover permission candidates, choose packages, or write intent.skills. The current policy is package-level; individual skill selection in this flow depends on #219.

User outcome

A human can run intent install, review discovered packages and skills, explicitly choose permissions, confirm the proposed configuration, and receive the existing guidance output in the same workflow.

In scope

  • Discover available package and skill candidates using the current discovery behavior.
  • Present packages for explicit human selection and, after #219 defines the grammar, support individual skill selection.
  • Show the proposed intent.skills changes and destination file before writing.
  • Require explicit confirmation before changing package.json.
  • Write or update the selected configuration owner while preserving its formatting and unrelated fields.
  • Preserve existing intent.exclude values and unrelated intent fields.
  • Continue to create or update the existing managed guidance block.
  • Provide a cancellation path with no configuration or guidance write.
  • Make the package.json update atomic so a failed write cannot leave partial JSON.
  • Report configuration and guidance results separately if a later guidance write or verification fails.
  • Prevent accidental permission writes in noninteractive use.

Out of scope

  • Content locks, hashes, or byte-level verification.
  • Frozen CI or noninteractive trust enforcement.
  • Native skill placement or delivery synchronization.
  • Git sources.

Acceptance criteria

  • The command discovers available permission candidates before presenting selections.
  • The human can select packages and, when #219 is complete, supported individual skills.
  • The command previews the exact permission changes and destination file before confirmation.
  • A documented deterministic rule chooses the package.json that owns the edited intent.skills declaration.
  • The command writes only after explicit confirmation.
  • The preview identifies newly permitted sources or skills as trust changes and preserves the acknowledged-risk notice for permit-all configuration.
  • Canceling leaves package.json and guidance files unchanged.
  • Discovery, validation, or configuration write failure does not leave a partial package.json update.
  • Existing package JSON formatting and unrelated fields are preserved.
  • Existing exclusions and unrelated intent configuration are preserved.
  • Existing guidance is created or updated as part of the confirmed flow.
  • A guidance failure after a successful configuration write reports both outcomes accurately and does not report full success.
  • Noninteractive use cannot trigger an unreviewed permission write.
  • The command reports whether permissions and guidance were changed, unchanged, canceled, or failed.

Dependencies

  • #219 for individual skill selection. The package-level setup flow can ship independently.

Open decisions

  • Decide how to evolve the current noninteractive default guidance behavior without silently breaking existing automation: keep it behind an explicit mode, make interactive setup TTY-only with a defined non-TTY behavior, or introduce a distinct action.
  • Decide the deterministic configuration owner rule for nested projects and inherited intent.skills declarations.
  • Decide whether a confirmed first run always creates explicit intent.skills or can retain the current absent-configuration migration mode.

Prior exploration

#204 explored interactive install together with content locking and managed delivery. This issue keeps only permission setup and the existing guidance output.

Sign in to join this conversation.