Skip to content

feat(sync): bootstrap prompt variations from LaunchDarkly - #800

Draft
ctawiah wants to merge 11 commits into
ctawiah/AIC-3344/bootstrap-add-flowfrom
ctawiah/AIC-3344/interactive-bootstrap
Draft

ctawiah wants to merge 11 commits into
ctawiah/AIC-3344/bootstrap-add-flowfrom
ctawiah/AIC-3344/interactive-bootstrap

Conversation

@ctawiah

@ctawiah ctawiah commented Sep 12, 2026

Copy link
Copy Markdown
Contributor

Context

This PR adds the first user-facing LaunchDarkly-to-local workflow for Phase 1 prompt variation sync. It is intended for initial setup when .launchdarkly does not exist and for explicitly adding more server variations later with ldcli sync prompt --add.

The interactive flow discovers projects, AI Configs, and variations through the API, then delegates file creation to the atomic local store from the preceding PR. Existing local variations are unavailable for selection, so bootstrap and add cannot overwrite local work. This PR does not update existing files or apply local changes back to LaunchDarkly.

Summary

  • Lists projects and AI Configs through paginated API requests.
  • Lets users select a project, AI Config, and one or more prompt variations interactively.
  • Writes only sync-owned fields and leaves the remote variation comment server-owned.
  • Bootstraps .launchdarkly when it is missing and supports adding variations with ldcli sync prompt --add.
  • Keeps bootstrap and add selections read-only with --dry-run, printing each target path and exact file content without creating or changing local files.
  • Clearly separates each dry-run file preview so paths and content are easy to distinguish.
  • Reuses the atomic local variation store and works with Git or non-Git workspaces.
  • Includes no tool, skill, source metadata file, or source-selection behavior.

Verification

  • go test ./internal/sync/... ./cmd/sync -count=1

@ctawiah
ctawiah added this pull request to stack #799 September 12, 2026 00:33
@ctawiah
ctawiah force-pushed the ctawiah/AIC-3344/interactive-bootstrap branch from 466477d to eb2aab0 Compare September 14, 2026 21:14
@ctawiah
ctawiah force-pushed the ctawiah/AIC-3344/interactive-bootstrap branch from de743af to 4c03a67 Compare September 16, 2026 16:52
@ctawiah
ctawiah force-pushed the ctawiah/AIC-3344/interactive-bootstrap branch from 4c03a67 to 0bd5840 Compare September 16, 2026 17:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant