Skip to content

Wire provider-driven mutation through Wright product surfaces #156

Description

@Teakowa

Follow-up from #139.

Goal

Expose provider-owned semantic mutation and edit validation consistently through Wright product surfaces without moving source-language edit semantics into Wright.

Context

Source-language implementations own the semantic understanding required to produce or validate safe edits. Wright owns orchestration and presentation across reusable driver/tooling, LSP, CLI, embedding, and agent-facing surfaces.

A product surface may consume a provider mutation capability, but it must not silently replace a refused or unavailable semantic edit with textual search/replace.

Scope

  • Route supported LSP mutation/refactoring operations through the owning provider capability for the active language.
  • Expose the same validated mutation capability through reusable Wright tooling/driver APIs and CLI surfaces where a command-level workflow is appropriate.
  • Preserve provider diagnostics, refusal reasons, provenance, and edit validation across the integration boundary.
  • Keep behavior explicit when no provider is configured or the provider does not support the requested mutation.
  • Reuse the common mutation path rather than creating independent edit semantics per surface.

Non-goals

  • Implementing OPY, DEL/OSTW, or raw Workshop mutation semantics in Wright.
  • Falling back to unvalidated textual search/replace when semantic mutation is unavailable or refused.
  • Regenerating complete source files as the default edit model.
  • Adding source-language syntax or semantics for the sake of a Wright surface.
  • Binding this task to a specific pre-1.0 release number or migration phase.

Acceptance criteria

  • Supported LSP mutation/refactoring operations can consume provider-produced validated edits for the active language.
  • Appropriate CLI/tooling surfaces can invoke the same provider-owned mutation capability or return an explicit unsupported/provider-not-configured/refusal diagnostic.
  • Provider refusal and validation failures remain explicit; no silent textual fallback is introduced.
  • Edits preserve unaffected source structure/trivia according to the owning provider's source-edit contract.
  • Wright product surfaces share the reusable integration path rather than duplicating source-language edit logic.
  • Existing non-provider behavior remains unchanged where no provider-driven mutation capability is requested or declared.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status
    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions