Enforce issue-linked target workflow prompts#35
Merged
Conversation
Constraint: Non-trivial target repo work must be blocked until target and change-control issues plus a GitHub Development linked branch exist.\nRejected: Keep role-prefixed manual task branches | They allow work to start without issue-linked GitHub Development traceability.\nConfidence: high\nScope-risk: narrow\nDirective: Preserve the issue -> change-control -> gh issue develop -> PR to dev sequence when editing target workflow prompts.\nTested: python3 -m pytest -q; git diff --check\nNot-tested: npm/Gradle target app commands; this repository has no package or service backend manifest.
This was referenced Apr 30, 2026
Constraint: Control-plane repositories must remain together while product repositories need a predictable local home for seeded agent documents.\nRejected: Clone target repos directly beside the three control-plane repos | It blurs the control-plane root with product workspaces.\nConfidence: high\nScope-risk: narrow\nDirective: Keep three agent repos under <CLEVER_ROOT> and target repos under <CLEVER_ROOT>/projects/<project-slug>/<target-repo>.\nTested: python3 -m pytest -q; git diff --check\nNot-tested: live target repo bootstrap clone; this change updates prompt/script packet contracts only.
Constraint: The CLEVER root separates the agent workspace from product project checkouts.\nRejected: Place control-plane repos directly under <CLEVER_ROOT> | The intended root has a clever-agent-workspace child containing the three agent repos.\nConfidence: high\nScope-risk: narrow\nDirective: Keep agent repos in <CLEVER_ROOT>/clever-agent-workspace and target repos in <CLEVER_ROOT>/projects/<project-slug>/<target-repo>.\nTested: python3 -m pytest -q; git diff --check\nNot-tested: live clone into the corrected folder layout.
Constraint: Python preflight must confirm the CLEVER_ROOT session layout before startup work begins.\nRejected: Only document the layout | The bootstrap packet also needs machine-readable session_open_check evidence.\nConfidence: high\nScope-risk: moderate\nDirective: Read workspace_check.session_open_check before startup questions; target repos belong under <CLEVER_ROOT>/projects even when a legacy direct layout is detected.\nTested: python3 -m pytest -q; python3 .agent/skills/bootstrap-clever-work/scripts/bootstrap_clever_work.py --cwd "/Users/jiin/Documents/Files/03_Work_EVnSolution/01_Repos/03_CLEVER_Agent/clever-agent-project" --workspace-check --json; git diff --check\nNot-tested: live nested <CLEVER_ROOT>/clever-agent-workspace checkout with real git remotes.
Constraint: Prompts received at CLEVER_ROOT must not trigger ad-hoc implementation before the agent workflow is inherited.\nRejected: Rely on prose-only startup guidance | The preflight now exposes agent_response_contract so the response style is machine-readable.\nConfidence: high\nScope-risk: narrow\nDirective: First response should state that initial setup runs first, then continue with the provided prompt after repo/rules/pull/agent-document injection succeeds.\nTested: python3 -m pytest -q; python3 .agent/skills/bootstrap-clever-work/scripts/bootstrap_clever_work.py --cwd "/Users/jiin/Documents/Files/03_Work_EVnSolution/01_Repos/03_CLEVER_Agent/clever-agent-project" --workspace-check --json; python3 -m py_compile .agent/skills/bootstrap-clever-work/scripts/bootstrap_clever_work.py; git diff --check\nNot-tested: end-to-end live target repo creation and ruleset application.
Constraint: Users need a copy-paste prompt for agents opened at CLEVER_ROOT that prevents ad-hoc implementation.\nRejected: Only describe the folder layout | Users need a concrete prompt that makes agents inherit the CLEVER workflow first.\nConfidence: high\nScope-risk: narrow\nDirective: Keep the root-level prompt aligned with session_open_check and agent_response_contract.\nTested: python3 -m pytest -q; python3 -m py_compile .agent/skills/bootstrap-clever-work/scripts/bootstrap_clever_work.py; git diff --check\nNot-tested: live first-run copy-paste into a fresh agent session.
Constraint: The README prompt should be a short user-facing instruction, not an exhaustive procedure dump.\nRejected: Long CLEVER_ROOT preflight prompt | It obscured the core action: create a folder, fetch the three repos, then follow agent-project.\nConfidence: high\nScope-risk: narrow\nDirective: Keep the root prompt concise and defer operational details to clever-agent-project README/AGENTS.\nTested: python3 -m pytest -q; python3 -m py_compile .agent/skills/bootstrap-clever-work/scripts/bootstrap_clever_work.py; git diff --check\nNot-tested: live copy-paste into a fresh agent session.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
<CLEVER_ROOT>/clever-agent-workspace/, and product/service target repos live under<CLEVER_ROOT>/projects/<project-slug>/<target-repo>/where agent seed documents are injected.workspace_check.session_open_checkso bootstrap validation confirms the CLEVER_ROOT-based session layout before startup questions.preflight_check.agent_response_contractso prompts received at<CLEVER_ROOT>do not trigger ad-hoc work; the agent first inherits the CLEVER workflow, completes initial setup, then continues with the user's prompt.clever-agent-projectto prepare the work.Intended folder layout
README root prompt shape
The README now provides a short user-facing prompt that says, in effect:
Linked issues
Concurrent Work Gate
Validation
python3 -m pytest -q— 84 passed, 2 skippedpython3 .agent/skills/bootstrap-clever-work/scripts/bootstrap_clever_work.py --cwd "$PWD" --workspace-check --json— emittedworkspace_check.session_open_check(legacy-layoutin this current checkout, with expected nested path reported)python3 -m py_compile .agent/skills/bootstrap-clever-work/scripts/bootstrap_clever_work.py— passedgit diff --check— passedNotes
mainas the protected PR base; the prompt changes themselves instruct target repositories to use work branches fromdevand PRs intodev.