@excitedjs/dreamux 0.9.4 → 0.9.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,50 @@
1
+ # Codex Turns In Dreamux
2
+
3
+ ## What A Turn Is
4
+
5
+ A turn is one model round opened by user input and kept alive until the model
6
+ stops requesting tools. While a turn is active, additional input can be folded
7
+ into that same turn and processed at the next model step.
8
+
9
+ ## Start Versus Steer
10
+
11
+ - `turn/start` is aggregate behavior: it starts a fresh turn when idle and can
12
+ fold input into the currently active turn when busy.
13
+ - `turn/steer` targets an active turn and should fail when no active turn
14
+ exists or the expected turn id does not match.
15
+
16
+ Operational rule: when you need deterministic injection, identify whether a
17
+ turn is active before choosing start or steer behavior.
18
+
19
+ ## Why Steering Is Not Instant
20
+
21
+ Tool calls return control only at yield boundaries. If the active turn is
22
+ waiting inside a long-running command or poll, injected input is usually not
23
+ processed until that tool call yields and the model samples again.
24
+
25
+ ## Background Work Does Not Wake An Idle Model
26
+
27
+ A background command completing is an event for the host, not new user input.
28
+ If the dispatcher starts background work and ends the turn without polling,
29
+ the model may not observe completion until another user input starts a turn.
30
+
31
+ ## Compaction Can Repeat Replies
32
+
33
+ Long conversations can compact mid-turn. After compaction, the model may
34
+ re-sample and repeat a prior response. Diagnose this by checking whether there
35
+ was one inbound user message and a compaction marker between repeated assistant
36
+ messages. Do not infer duplicate external delivery from repeated text alone.
37
+
38
+ ## Head-Of-Line Blocking
39
+
40
+ Modern Dreamux dispatcher inbound should submit accepted messages without
41
+ waiting for the previous turn to complete. If a later message waits behind a
42
+ long turn, check whether the running version still uses a serial turn
43
+ submission path or whether another gate rejected the later message.
44
+
45
+ ## App-Server Readiness
46
+
47
+ Before business RPCs, the Codex app-server connection must complete the
48
+ initialize handshake. A daemon that exits before binding its socket, fails the
49
+ handshake, or cannot read workspace-local skills should be treated as a
50
+ startup readiness failure, not as a chat delivery bug.
@@ -0,0 +1,62 @@
1
+ ---
2
+ name: team-dev-workflow
3
+ description: Coordinate multi-teammate software development workflows from a Dreamux dispatcher: adversarial MR/PR review, design negotiation, merge readiness checks, cleanup, and unblocking a teammate. Use for coordination cycles, not ordinary single-repo edits.
4
+ ---
5
+
6
+ # Team Development Workflow
7
+
8
+ Use this skill when the dispatcher is coordinating people or teammates around a
9
+ software change. It is methodology layered on top of the `dispatcher` skill:
10
+ `dispatcher` owns `tm` mechanics, while this skill owns review, design, merge,
11
+ and unblock workflow.
12
+
13
+ ## Confirm Scope
14
+
15
+ Use this skill when:
16
+
17
+ - An MR/PR needs independent adversarial review before merge.
18
+ - A design direction is unsettled and two independent proposals should be
19
+ compared.
20
+ - A reviewed MR/PR is ready to merge and the teammate/worktree/branch need
21
+ cleanup.
22
+ - A teammate is blocked by git state, missing context, wrong base, or missed
23
+ review comments.
24
+
25
+ Do not use this skill for a normal implementation request such as "fix this
26
+ bug" or "add this endpoint". Delegate that as one bounded repository task with
27
+ the `dispatcher` skill.
28
+
29
+ ## Coordinator Posture
30
+
31
+ - Verify facts from the target repo and platform before deciding.
32
+ - Do not edit target repo code from the coordinator context. Delegate repo work
33
+ to a teammate in that repo.
34
+ - Keep prompts short: intent, coordinates, hard constraints, and requested
35
+ artifact.
36
+ - When the target repo is public, explicitly forbid internal domains, tokens,
37
+ private identifiers, and machine-local paths in commits, MR/PRs, and comments.
38
+ - Prefer one accountable teammate per branch or review thread; reuse it for
39
+ follow-up rather than spawning duplicates.
40
+
41
+ ## Scenario Routing
42
+
43
+ Read the matching reference before acting:
44
+
45
+ | Intent | Reference |
46
+ |---|---|
47
+ | Review an MR/PR or issue proposal adversarially | `references/review-cycle.md` |
48
+ | Compare two design directions before implementation | `references/design-negotiation.md` |
49
+ | Merge a reviewed change and clean up state | `references/merge-and-cleanup.md` |
50
+ | Dispatch or unblock a teammate | `references/dispatch-and-unblock.md` |
51
+
52
+ ## Cross-Cutting Rules
53
+
54
+ - Reviewers must be independent from authors. Fresh context matters more than
55
+ a specific vendor or model family.
56
+ - The author does not review or merge its own work.
57
+ - CI and merge mode are target-repo policy. Read the repo/platform rules before
58
+ acting.
59
+ - Same-account automation may be unable to submit a formal approval or change
60
+ request. In that case, use a top-level MR/PR comment with a clear verdict.
61
+ - A clean review means no blocking findings on the current head, with required
62
+ checks green.
@@ -0,0 +1,40 @@
1
+ # Design Negotiation
2
+
3
+ ## Trigger
4
+
5
+ A design or architecture direction is unsettled, expensive to reverse, and has
6
+ more than one plausible path. This is for choosing an approach before
7
+ implementation, not for reviewing a finished MR/PR.
8
+
9
+ ## Steps
10
+
11
+ 1. Write one neutral input brief for all participants:
12
+ - business need and observable facts
13
+ - relevant repo paths, scripts, and constraints
14
+ - candidate approaches as reference only, not a forced shortlist
15
+ - required output shape
16
+ - validation expectations
17
+ 2. Dispatch two independent teammates in parallel with the same input brief.
18
+ Ask each to write a v1 proposal to a file.
19
+ 3. Wait for both v1 files and verify they exist before continuing.
20
+ 4. Swap the v1 files. Ask each teammate to read the other proposal and write a
21
+ v2 that states:
22
+ - what it adopts
23
+ - what it rebuts
24
+ - its revised recommendation
25
+ - remaining ambiguity
26
+ 5. Hand both v2 proposals to the human intact. The coordinator does not
27
+ synthesize a third proposal or preselect a winner.
28
+
29
+ ## Closeout
30
+
31
+ The human receives two revised, independently argued proposals. If both v2s
32
+ converge, report the convergence as evidence; still keep both proposals
33
+ available.
34
+
35
+ ## Anti-Patterns
36
+
37
+ - Do not tell either teammate about the other in the v1 round.
38
+ - Do not skip the v2 cross-read.
39
+ - Do not add a coordinator-authored compromise.
40
+ - Do not let a teammate spawn its own reviewers for this cycle.
@@ -0,0 +1,39 @@
1
+ # Dispatch And Unblock
2
+
3
+ ## Trigger
4
+
5
+ You are assigning a teammate to a target repo, or a teammate is blocked by git
6
+ state, wrong base, missing context, or missed platform comments.
7
+
8
+ ## Steps
9
+
10
+ 1. Verify the target repository path and intended base branch before spawning.
11
+ 2. Reuse an existing teammate when it already owns the branch or MR/PR.
12
+ 3. Ensure the teammate brief includes only:
13
+ - intent
14
+ - branch, issue, or MR/PR coordinates
15
+ - hard constraints
16
+ - requested artifact
17
+ 4. Tell the teammate to sync its working branch before editing when the task
18
+ will produce commits.
19
+ 5. Tell the teammate to pull all current issue or MR/PR comments before acting.
20
+ Repeat this on follow-up turns when comments may have changed.
21
+ 6. For public targets, include the no-internal-content constraint explicitly.
22
+ 7. Set a short queryable task subject if the teammate tooling supports it.
23
+
24
+ ## Unblocking
25
+
26
+ If a teammate cannot write git metadata because of sandbox permissions, the
27
+ coordinator may run the git operation from outside the sandbox: fetch, create a
28
+ branch, commit staged teammate-authored content, push, or clean a worktree. Do
29
+ only the git movement needed to unblock. The teammate still owns analysis and
30
+ content changes.
31
+
32
+ If a teammate started from the wrong base, stop it, remove the bad worktree,
33
+ reset the main checkout to the intended base, and spawn again. Do not ask a
34
+ teammate to build on a known-bad branch unless the human accepts that risk.
35
+
36
+ ## Closeout
37
+
38
+ The teammate is on the intended base, has current platform comments, has a
39
+ minimal brief, and is no longer blocked on git or missing context.
@@ -0,0 +1,37 @@
1
+ # Merge And Cleanup
2
+
3
+ ## Trigger
4
+
5
+ An MR/PR has a clean independent review on the current head and required checks
6
+ are green.
7
+
8
+ ## Steps
9
+
10
+ 1. Re-read the current head SHA, required check status, draft state, and merge
11
+ state from the target platform.
12
+ 2. If the MR/PR is a draft, mark it ready before merging and confirm the head
13
+ SHA did not change.
14
+ 3. Scan the MR/PR title for bracketed CI-skip tokens. Remove or reword them
15
+ before squash merging so post-merge workflows are not skipped.
16
+ 4. Merge using the target repo's allowed mode and branch-deletion policy.
17
+ 5. Clean up the review cycle immediately:
18
+ - stop or close the reviewer teammate
19
+ - remove the review worktree
20
+ - delete the review branch if the cycle created one
21
+ - close the author teammate when its branch is no longer needed
22
+ 6. Record the final status in teammate history where the tooling supports it.
23
+
24
+ ## Closeout
25
+
26
+ The change is on the target branch, required post-merge workflows are not
27
+ accidentally skipped, and no temporary teammate, worktree, or review branch from
28
+ the cycle remains active.
29
+
30
+ ## Exceptions
31
+
32
+ | Case | Action |
33
+ |---|---|
34
+ | Merge state is unclear | Check required status checks specifically; optional jobs may be noisy. |
35
+ | Same-account formal approval is missing | Use the clean review comment as the gate when platform policy allows owner/admin merge. |
36
+ | Worktree removal refuses | Use the platform or git command intended for forced worktree cleanup; the branch already landed. |
37
+ | Cleanup must be delayed | State what remains and when it will be removed. |
@@ -0,0 +1,46 @@
1
+ # Review Cycle
2
+
3
+ ## Trigger
4
+
5
+ An MR/PR or issue proposal needs adversarial review before it can merge or move
6
+ to implementation.
7
+
8
+ Skip this cycle only when the change is trivial, the human already accepted the
9
+ risk, or an equally rigorous independent review already exists on the current
10
+ head.
11
+
12
+ ## Steps
13
+
14
+ 1. Identify the author, branch, MR/PR or issue number, and current head SHA.
15
+ 2. Confirm the target repo and platform visibility. If public, include a
16
+ no-internal-content constraint in the reviewer brief.
17
+ 3. Confirm the change is ready to review: current branch pushed, required
18
+ checks known, and merge state readable.
19
+ 4. Reuse an existing reviewer teammate only if it already owns this exact
20
+ branch or review thread. Otherwise spawn one independent reviewer.
21
+ 5. Give the reviewer an adversarial brief:
22
+ - verify the author's claims instead of trusting them
23
+ - inspect the current diff against the target base
24
+ - run or justify focused verification
25
+ - report P0/P1/P2 findings with file and line references
26
+ - do not edit, commit, push, or merge
27
+ 6. Bucket the verdict:
28
+ - no P0/P1: eligible for merge once required checks are green
29
+ - P0/P1: send the author a fix brief quoting the findings exactly
30
+ - P2 only: merge with follow-up or ask for a cheap one-shot fix
31
+ 7. Recheck with the same reviewer after any force-push. Anchor the recheck on
32
+ the prior findings, new head SHA, and reported fixes.
33
+
34
+ ## Closeout
35
+
36
+ The current head has an independent clean verdict, required checks are green,
37
+ and any remaining non-blocking follow-up is explicit.
38
+
39
+ ## Exceptions
40
+
41
+ | Case | Action |
42
+ |---|---|
43
+ | Base advanced | Ask the author to rebase or merge the target base, then re-run checks. |
44
+ | Reviewer and author disagree | Escalate both positions to the human; do not silently pick a side. |
45
+ | Formal review action is rejected | Post the same verdict as a top-level MR/PR comment. |
46
+ | A reviewed line moved after force-push | Quote the problem statement so the reviewer can relocate it. |