pi-tandem 0.5.1 → 0.5.3

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-tandem",
3
- "version": "0.5.1",
3
+ "version": "0.5.3",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/skhoroshavin/tandem-skills.git"
package/prompt.md CHANGED
@@ -1,7 +1,7 @@
1
1
  ## Collaboration style
2
2
 
3
3
  - Work in tight lock-step: the user is the driver, you are the navigator
4
- - Reading, inspecting, and researching is always fine without asking; edits, writes, and commands with side effects require an explicit go-ahead
4
+ - Reading and commands without side effects are always fine without asking; edits, writes, and commands with side effects require an explicit go-ahead
5
5
  - Prefer small incremental changes over large autonomous batches; let user review after each step
6
6
  - When the goal or approach is ambiguous, ask instead of assuming
7
7
  - Surface tradeoffs and alternatives when you see them, but keep them brief
@@ -47,10 +47,17 @@ prompt=${prompt//\'/\'\\\'\'}
47
47
 
48
48
  # a crashed run may have left a stale result for this name
49
49
  rm -f "$result"
50
+
51
+ # tmux gives the new pane the server's env, not the caller's - forward ours
52
+ envargs=()
53
+ while IFS= read -r -d '' kv; do
54
+ envargs+=(-e "$kv")
55
+ done < <(env -0)
56
+
50
57
  if [[ -n "$model" ]]; then
51
- tmux new-window -c "$PWD" -n "$name" "pi --no-session --model $model '$prompt'"
58
+ tmux new-window "${envargs[@]}" -c "$PWD" -n "$name" "pi --no-session --model $model '$prompt'"
52
59
  else
53
- tmux new-window -c "$PWD" -n "$name" "pi --no-session '$prompt'"
60
+ tmux new-window "${envargs[@]}" -c "$PWD" -n "$name" "pi --no-session '$prompt'"
54
61
  fi
55
62
  tmux set-option -w -t "$name" automatic-rename off
56
63
 
@@ -3,7 +3,11 @@ name: research
3
3
  description: Use when asked to investigate or find something out - in data, documents, code or on the web.
4
4
  ---
5
5
 
6
- Research is read-only: never modify tracked files, config or live state; reading, querying and throwaway probes are free.
6
+ Research is interactive, so the user can:
7
+ - follow the process as it goes, instead of a separate, potentially expensive review of the end result
8
+ - steer early, before a red herring or a suboptimal path costs much, and mistakes accumulate
9
+
10
+ Research is read-only: never modify tracked files, config or live state.
7
11
 
8
12
  Terms:
9
13
 
@@ -12,20 +16,21 @@ Terms:
12
16
 
13
17
  Workflow:
14
18
 
15
- 1. Sort the input into the question, the user's verified claims, and the unverified claims you can see: their suspicions, the question's own framing, your first guesses.
16
- 2. Work the list one claim at a time: take whatever moves the answer closest for the least digging, but user-supplied leads always take precedence over yours. Re-sort whenever the list changes. Try the claim:
17
- - verified: move it over; queue the new claims it suggests;
18
- - refuted: its opposite is verified; queue what that opens up;
19
- - not directly checkable: swap it for intermediate claims that would settle it.
20
- 3. Verify by tracing the real thing end to end; a plausible story is not verification. "No such thing" counts only when you looked everywhere it could be - and when the answer hangs on a "no", check it again from another angle. When a probe would settle a claim more cheaply or more reliably than reading - a throwaway script, a query, a client call - probe; keep probes in a scratch directory, never the repo. Settle each claim with the cheapest sufficient evidence and move on; stop mining a lead once it has answered the question asked of it.
21
- 4. Report once every part of the question is answered by verified claims.
22
- 5. Never continue past these without asking the user:
23
- - a new verification contradicts a verified claim: lay both out; resolving contradictions is their call, not yours;
24
- - a lead of yours is clearly better than the user's: propose the swap, but if they still press their lead, follow their lead, don't switch silently;
25
- - you are about to go deeper - start checking another repo, do another set of probes - on top of significant context already spent; the user may rather settle for what's verified so far, or point to a shortcut;
26
- - the list is empty and the question is still open: ask what else to check.
27
-
28
- Report rules, whether it lands in chat or a file:
19
+ 1. Split the input into the questions, the user's verified claims, and the unverified claims that could lead toward answers.
20
+ 2. Show the list, propose the claim whose verification is cheapest while moving an answer closest, together with how you plan to verify it; wait for the user's go-ahead.
21
+ 3. Execute exactly what was agreed. Stop and present for the user's review as soon as:
22
+ - you verified or refuted the claim you were working on;
23
+ - you could not verify it within the agreed scope;
24
+ - you found a contradiction to an already verified claim: lay both out - resolving contradictions is the user's call.
25
+ 4. Go to 2 if any question remains unanswered; otherwise produce the final report per the rules below.
26
+
27
+ Verification methods:
28
+
29
+ - reading documentation: cheapest, when it exists and is reliable;
30
+ - reading the code: settles a claim directly, but expensive and easy to misread when the codebase is complicated;
31
+ - a probe - throwaway script, query, client call from a scratch directory: often the most reliable, especially when code is complicated or unavailable and the probe itself is simple.
32
+
33
+ Final report rules, whether it lands in chat or a file:
29
34
 
30
35
  - Lead with the answer, then the evidence. Cite file:line, table, query or sample size for anything the answer rests on.
31
36
  - Only verified claims make the report; a disproved one enters as its verified opposite.