Skip to content

chore: handle lightweight vs full plugin in shell file generation#35

Open
scappuccino-grid wants to merge 1 commit intomainfrom
chore/shell_f_handling
Open

chore: handle lightweight vs full plugin in shell file generation#35
scappuccino-grid wants to merge 1 commit intomainfrom
chore/shell_f_handling

Conversation

@scappuccino-grid
Copy link
Contributor

Distinguish between lightweight (rosetta@rosetta) and full (core@rosetta, grid@rosetta) plugins when deciding whether to generate shell files in Phase 2 of init-workspace-flow. Full plugins ship all instructions bundled so shells are not needed; lightweight plugins require shells to enable skills, agents, and workflows. When plugin type cannot be detected, ask the user with an explanation and suggest lightweight (the recommended install) as the default.

Also fixes inconsistent sentinel phrase used for plugin mode detection ("Rosetta plugin is already active" → "RUNNING AS A PLUGIN").

Distinguish between lightweight (rosetta@rosetta) and full (core@rosetta,
grid@rosetta) plugins when deciding whether to generate shell files in
Phase 2 of init-workspace-flow. Full plugins ship all instructions bundled
so shells are not needed; lightweight plugins require shells to enable
skills, agents, and workflows. When plugin type cannot be detected, ask
the user with an explanation and suggest lightweight (the recommended
install) as the default.

Also fixes inconsistent sentinel phrase used for plugin mode detection
("Rosetta plugin is already active" → "RUNNING AS A PLUGIN").

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@github-actions github-actions bot added enhancement New feature or request documentation Improvements or additions to documentation labels Mar 22, 2026
@github-actions
Copy link
Contributor

Rosetta Triage Review

Summary: This PR improves the init-workspace-flow by distinguishing between lightweight (rosetta@rosetta) and full (core@rosetta, grid@rosetta) plugin types when deciding whether to generate shell files in Phase 2. It also fixes an inconsistent sentinel phrase used for plugin mode detection.

Findings:

  • All 4 changed files are instruction/workflow documents under instructions/r2/core/ — no runtime code affected
  • The sentinel phrase fix ("Rosetta plugin is already active""RUNNING AS A PLUGIN") is a consistency bug fix; existing deployments relying on the old phrase would have silently misbehaved
  • The plugin_type = unknown branch correctly gates on HITL before writing any files — safe fallback behavior
  • The HITL question text is clear, well-structured, and nudges users toward the recommended lightweight install
  • Output contract of Phase 1 is properly updated (plugin_type added to state and validation checklist)
  • Phase 2 workflow context input list is updated to include state.plugin_type — consistent across all documents

Suggestions:

  • Consider adding a note in the pitfalls section of init-workspace-flow-shells.md clarifying that plugin_type = unknown should never persist past Phase 2 (it must be resolved before proceeding)
  • The branch name chore/shell_f_handling has a typo (shell_f likely intended as shell_file) — cosmetic only, no action needed

Automated triage by Rosetta agent

Copy link
Collaborator

@isolomatov-gd isolomatov-gd left a comment

Choose a reason for hiding this comment

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

There is a misunderstanding. Lightweight plugin should not be using instructions/r2/core/rules/plugin-files-mode.md, as such it should not even BE detected as plugin. Moreover lightweight is just a way to simplify two manual actions: installing MCP and adding bootstrap file.

- Before Phase 1: create `agents/init-workspace-flow-state.md`.
- Conditional phases:
- If you have already in context "RUNNING AS A PLUGIN": MUST NOT EXECUTE "shells" phase 2 AND "rules" phase 4
- If you have already in context "RUNNING AS A PLUGIN":
Copy link
Collaborator

Choose a reason for hiding this comment

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

@scappuccino-grid Why do we need further?

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

Labels

documentation Improvements or additions to documentation enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants