Skip to content

[UX] Branch conversation without incompatible attachments #77

Description

@Eastsidegunn

Summary

Add a non-destructive model-switch escape hatch that creates a new conversation branch containing portable textual context while excluding incompatible native attachments from that branch's active provider projection.

This builds on the target-context projection introduced by #76. It must not mutate or delete the original branch, its messages, or its attachment registry.

Motivation

When every attachment in a conversation is incompatible with the requested model, merely suspending all files can make the remaining conversation misleading, while /new discards useful textual discussion. Users need a middle path:

Keep current model
Branch without files
Start a blank chat

Required semantics

  • Fork from the current session position using Pi's existing branch/session machinery.
  • Preserve portable text, tool history and summaries that remain meaningful without the native inputs.
  • Establish an explicit compatibility boundary in the new branch.
  • Exclude selected incompatible attachment/native-state identities from the new branch's active projection.
  • Preserve the original branch unchanged and navigable.
  • Never synthesize a file summary, conversion or placeholder claiming the target model saw the file.
  • Make exclusions visible in branch metadata, /files, exports and SDK/RPC results.

UX

Offer Branch without files when a model-switch portability report finds all attachments incompatible, and optionally for partial incompatibility.

Before committing, show:

New branch for Azure OpenAI / gpt-5

Preserved
✓ conversation text
✓ results.xlsx

Excluded from this branch context
✗ demo.mp4 — video input unsupported

The user can confirm or cancel. Switching back to the original branch restores its original model/context state.

Non-goals

Acceptance criteria

  • A branch can be created from a session containing incompatible native attachments.
  • The original branch and attachment references are unchanged.
  • The new branch preserves portable conversation context.
  • Excluded attachments are not sent to the target provider.
  • The compatibility boundary and excluded IDs survive save/resume.
  • /files, JSON/HTML export and SDK/RPC inspection expose the branch exclusions.
  • Returning to the original branch restores its prior attachment projection.
  • No local conversion or fabricated file summary is introduced.
  • Existing Pi branch/tree behavior remains compatible.

Dependency

Depends on #76.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions