Skip to content

Proposal: Add workspace control plane proposal#956

Open
rajashree-n wants to merge 3 commits intoFission-AI:mainfrom
rajashree-n:multi-repo-openspec-workspace
Open

Proposal: Add workspace control plane proposal#956
rajashree-n wants to merge 3 commits intoFission-AI:mainfrom
rajashree-n:multi-repo-openspec-workspace

Conversation

@rajashree-n
Copy link
Copy Markdown

@rajashree-n rajashree-n commented Apr 11, 2026

Summary

This PR adds a draft OpenSpec proposal for first-class multi-repo workspace support using a dedicated control-plane pattern.

The new change introduces:

  • a checked-in openspec-workspace.yaml manifest as the source of truth for workspace topology
  • a new openspec workspace command surface with init, sync, and doctor
  • generated workspace router files like .agents.md derived from the manifest
  • a dedicated control-plane repo pattern that works across sibling repos without requiring a monorepo

Context

This draft is based on the multi-repo workspace pattern described in my comment on issue #725:
#725 (comment)

Why

OpenSpec is currently project-root centric. That works well for single repos, but it leaves multi-repo teams without a standard way to keep agents grounded across a shared workspace.

This proposal targets a common setup like:

scm/
├── openspec-management/
├── service-auth/
└── service-payments/

The goal is to let teams manage shared specs, schemas, and repo routing from a single control plane while preserving repo-local ownership of existing AGENTS.md files.

What’s Included

  • proposal.md
  • design.md
  • tasks.md
  • spec delta for cli-workspace
  • spec delta for workspace-manifest

Key Design Choices

  • openspec init remains project-scoped
  • multi-repo support is introduced as a separate openspec workspace command group
  • .agents.md is treated as a generated artifact, not the primary contract
  • repo-local AGENTS.md files are referenced, not overwritten
  • sibling repo discovery is supported, but discovered entries must be reviewed before writing

Validation

  • openspec validate add-workspace-control-plane passed locally

Status

Draft proposal only. No runtime CLI implementation is included in this PR.

Summary by CodeRabbit

  • Documentation
    • Added design, proposal, spec, and task docs describing a new workspace control‑plane for multi-repo OpenSpec management.
    • Specified a checked‑in workspace manifest and validation rules, plus router generation and drift detection behaviors.
    • Documented a new CLI surface: openspec workspace with init, sync, and doctor commands and expected workflows.

@rajashree-n rajashree-n requested a review from TabishB as a code owner April 11, 2026 22:15
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 11, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 9db421b8-f273-4ea5-8043-fb6cb3c78b27

📥 Commits

Reviewing files that changed from the base of the PR and between caeebea and c54a1f5.

📒 Files selected for processing (1)
  • openspec/changes/add-workspace-control-plane/tasks.md
✅ Files skipped from review due to trivial changes (1)
  • openspec/changes/add-workspace-control-plane/tasks.md

📝 Walkthrough

Walkthrough

Adds design, proposal, specs, and task documentation for a new first-class multi-repo "workspace" control-plane in OpenSpec, plus a small .openspec.yaml metadata file. No code or public API declarations were changed.

Changes

Cohort / File(s) Summary
Change Metadata
openspec/changes/add-workspace-control-plane/.openspec.yaml
New per-change metadata file with schema: spec-driven and created timestamp.
Design & Proposal
openspec/changes/add-workspace-control-plane/design.md, openspec/changes/add-workspace-control-plane/proposal.md
Adds design and proposal documents defining a checked-in openspec-workspace.yaml manifest, control-plane scaffolding expectations, generated-router ownership rules, and CLI surface (`workspace init
CLI & Manifest Specs
openspec/changes/add-workspace-control-plane/specs/cli-workspace/spec.md, openspec/changes/add-workspace-control-plane/specs/workspace-manifest/spec.md
Formalizes CLI requirements and manifest schema: discovery with user review, path normalization, validation rules (duplicate names/paths, missing control-plane), and router-generation behavior (.agents.md handling).
Tasks / Roadmap
openspec/changes/add-workspace-control-plane/tasks.md
Task checklist for implementing workspace commands, manifest read/write/validation, discovery, scaffold behavior, router generation, drift detection, diagnostics, and tests.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant CLI as "openspec CLI"
    participant Manifest as "openspec-workspace.yaml"
    participant RepoFS as "Sibling Repos / Filesystem"
    participant Generator as "Router Generator"

    User->>CLI: run `openspec workspace init` (root)
    CLI->>RepoFS: discover candidate repos + instruction files
    RepoFS-->>CLI: list of candidates
    CLI->>User: present discovered entries for review
    User-->>CLI: confirm selections
    CLI->>Manifest: write `openspec-workspace.yaml` (normalized paths)
    CLI->>RepoFS: scaffold control-plane repo files if missing
    User->>CLI: run `openspec workspace sync`
    CLI->>Manifest: read manifest
    CLI->>Generator: generate routers (.agents.md) per manifest config
    Generator->>RepoFS: write generated router files (unless repo-local preserved)
    CLI->>User: report summary & drift info
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Possibly related PRs

Suggested reviewers

  • TabishB

Poem

🐰 I hopped from repo to root with cheer,
A workspace map now drawn so clear,
Init, sync, doctor — tools in paw,
Manifests stitch the paths we saw,
Together we keep agents near. 🥕

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Proposal: Add workspace control plane proposal' accurately describes the main change: adding a comprehensive proposal for multi-repo workspace control-plane support with manifest, CLI commands, and specifications.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
openspec/changes/add-workspace-control-plane/tasks.md (1)

17-17: Clarify scope of instruction file detection.

The phrasing "such as AGENTS.md" suggests support for multiple instruction file formats, but the design and specs consistently reference only AGENTS.md. If other formats are intended, they should be documented in the design/specs; otherwise, consider simplifying to "Detect candidate AGENTS.md instruction files".

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@openspec/changes/add-workspace-control-plane/tasks.md` at line 17, Update the
checklist entry text in tasks.md to clarify scope: replace the ambiguous item
"Detect candidate instruction files such as `AGENTS.md`" with a specific
form—either "Detect candidate `AGENTS.md` instruction files" if only AGENTS.md
is supported, or enumerate the supported filenames/formats (e.g., `AGENTS.md`,
`INSTRUCTIONS.md`) if multiple are intended; adjust the string in the checklist
line so the wording in the document matches the actual supported formats
referenced by the design/specs.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@openspec/changes/add-workspace-control-plane/tasks.md`:
- Line 17: Update the checklist entry text in tasks.md to clarify scope: replace
the ambiguous item "Detect candidate instruction files such as `AGENTS.md`" with
a specific form—either "Detect candidate `AGENTS.md` instruction files" if only
AGENTS.md is supported, or enumerate the supported filenames/formats (e.g.,
`AGENTS.md`, `INSTRUCTIONS.md`) if multiple are intended; adjust the string in
the checklist line so the wording in the document matches the actual supported
formats referenced by the design/specs.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 85ab990f-78d5-4082-a663-75310442c6af

📥 Commits

Reviewing files that changed from the base of the PR and between 9b5007d and caeebea.

📒 Files selected for processing (6)
  • openspec/changes/add-workspace-control-plane/.openspec.yaml
  • openspec/changes/add-workspace-control-plane/design.md
  • openspec/changes/add-workspace-control-plane/proposal.md
  • openspec/changes/add-workspace-control-plane/specs/cli-workspace/spec.md
  • openspec/changes/add-workspace-control-plane/specs/workspace-manifest/spec.md
  • openspec/changes/add-workspace-control-plane/tasks.md

@rajashree-n rajashree-n marked this pull request as draft April 11, 2026 22:36
@rajashree-n rajashree-n changed the title [DRAFT] Add workspace control plane proposal Proposal: Add workspace control plane proposal Apr 11, 2026
@rajashree-n rajashree-n marked this pull request as ready for review April 12, 2026 07:17
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