talking-stick 0.1.0-alpha
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/README.md +166 -0
- package/dist/cli.js +701 -0
- package/dist/commands.js +70 -0
- package/dist/config.js +31 -0
- package/dist/db.js +177 -0
- package/dist/errors.js +20 -0
- package/dist/identity.js +184 -0
- package/dist/index.js +12 -0
- package/dist/install.js +272 -0
- package/dist/mcp-server.js +171 -0
- package/dist/path-resolution.js +101 -0
- package/dist/process-utils.js +93 -0
- package/dist/server.js +3 -0
- package/dist/service.js +980 -0
- package/dist/session-store.js +80 -0
- package/dist/skill-install.js +107 -0
- package/dist/types.js +1 -0
- package/docs/ambient-presence.md +191 -0
- package/docs/releases/0.1.0-alpha.md +32 -0
- package/docs/talking-stick-plan.md +1156 -0
- package/package.json +40 -0
- package/skills/talking-stick/SKILL.md +132 -0
- package/skills/talking-stick/agents/openai.yaml +4 -0
package/package.json
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "talking-stick",
|
|
3
|
+
"version": "0.1.0-alpha",
|
|
4
|
+
"description": "MCP coordination server for path-scoped agent handoffs.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"bin": {
|
|
7
|
+
"tt": "./dist/cli.js"
|
|
8
|
+
},
|
|
9
|
+
"exports": {
|
|
10
|
+
".": "./dist/index.js"
|
|
11
|
+
},
|
|
12
|
+
"files": [
|
|
13
|
+
"dist",
|
|
14
|
+
"skills",
|
|
15
|
+
"docs",
|
|
16
|
+
"README.md"
|
|
17
|
+
],
|
|
18
|
+
"scripts": {
|
|
19
|
+
"build": "tsc -p tsconfig.build.json",
|
|
20
|
+
"prepare": "tsc -p tsconfig.build.json",
|
|
21
|
+
"test": "vitest run",
|
|
22
|
+
"typecheck": "tsc -p tsconfig.json --noEmit"
|
|
23
|
+
},
|
|
24
|
+
"dependencies": {
|
|
25
|
+
"@modelcontextprotocol/sdk": "^1.29.0",
|
|
26
|
+
"better-sqlite3": "^12.9.0",
|
|
27
|
+
"zod": "^3.25.76"
|
|
28
|
+
},
|
|
29
|
+
"devDependencies": {
|
|
30
|
+
"@types/better-sqlite3": "^7.6.13",
|
|
31
|
+
"@types/node": "^25.6.0",
|
|
32
|
+
"tsx": "^4.21.0",
|
|
33
|
+
"typescript": "^6.0.3",
|
|
34
|
+
"vitest": "^4.1.5"
|
|
35
|
+
},
|
|
36
|
+
"engines": {
|
|
37
|
+
"node": ">=22"
|
|
38
|
+
},
|
|
39
|
+
"license": "UNLICENSED"
|
|
40
|
+
}
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: talking-stick
|
|
3
|
+
description: Use when working in a repo that coordinates multiple agent harnesses with Talking Stick (`tt` / `talking-stick`), or when the user asks you to avoid parallel work, wait your turn, pass structured handoffs, or coordinate with Claude, Codex, Gemini, or OpenCode in the same workspace. Also use when a workspace contains a `.talking-stick/` marker or when the MCP tools `list_rooms`, `join_path`, `wait_for_turn`, `heartbeat`, `release_stick`, `pass_stick`, `takeover_stick`, `get_room_state`, or `get_room_events` are available.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
This skill teaches a harness how to behave in a Talking Stick workspace.
|
|
7
|
+
|
|
8
|
+
## Core Rule
|
|
9
|
+
|
|
10
|
+
Do not perform shared workspace edits, commits, migrations, or other owner-style work until you hold the stick.
|
|
11
|
+
|
|
12
|
+
If you only need status, read status. If you need to work, join and wait.
|
|
13
|
+
|
|
14
|
+
## When To Use
|
|
15
|
+
|
|
16
|
+
Use this skill when any of these are true:
|
|
17
|
+
|
|
18
|
+
- the user mentions `talking-stick`, `tt`, handoffs, turn-taking, or avoiding parallel work
|
|
19
|
+
- the repo is known to use Talking Stick coordination
|
|
20
|
+
- a `.talking-stick/` marker exists
|
|
21
|
+
- the Talking Stick MCP tools are available in the current harness
|
|
22
|
+
|
|
23
|
+
Do not use this skill for ordinary single-agent work in repos that are not using Talking Stick.
|
|
24
|
+
|
|
25
|
+
## Workflow
|
|
26
|
+
|
|
27
|
+
### 1. Check that Talking Stick is actually available
|
|
28
|
+
|
|
29
|
+
If the Talking Stick MCP tools are not available, say so briefly. Do not pretend coordination is active.
|
|
30
|
+
|
|
31
|
+
If coordination is required and the tools are missing, ask the user whether they want to install or enable Talking Stick first.
|
|
32
|
+
|
|
33
|
+
### 2. Join the workspace room once
|
|
34
|
+
|
|
35
|
+
On the first substantial task in a Talking Stick workspace:
|
|
36
|
+
|
|
37
|
+
1. call `join_path` with the current workspace path
|
|
38
|
+
2. keep the returned `room_id`
|
|
39
|
+
3. note the returned policy, especially `heartbeatIntervalMs`
|
|
40
|
+
|
|
41
|
+
If the workspace is nested, accept the resolved canonical path the server returns.
|
|
42
|
+
|
|
43
|
+
### 3. Wait before doing shared work
|
|
44
|
+
|
|
45
|
+
Before making shared edits or running owner-style actions, call `wait_for_turn`.
|
|
46
|
+
|
|
47
|
+
Possible outcomes:
|
|
48
|
+
|
|
49
|
+
- `your_turn`: you may proceed
|
|
50
|
+
- `not_yet`: do not mutate shared state; you may still plan, inspect, review, or talk with the user
|
|
51
|
+
- `takeover_available`: surface the reason and make takeover explicit
|
|
52
|
+
- `closed`: stop and explain that the room is closed
|
|
53
|
+
|
|
54
|
+
### 4. While waiting
|
|
55
|
+
|
|
56
|
+
If you do not have the stick:
|
|
57
|
+
|
|
58
|
+
- do not make shared repo changes
|
|
59
|
+
- do not silently race another harness
|
|
60
|
+
- it is fine to read, plan, review, or help the user think
|
|
61
|
+
- tell the user who currently holds or is reserved the turn when that is useful
|
|
62
|
+
|
|
63
|
+
### 5. While holding the stick
|
|
64
|
+
|
|
65
|
+
If the task may run longer than a few minutes, heartbeat periodically.
|
|
66
|
+
|
|
67
|
+
Use the cadence from `join_path.policy.heartbeatIntervalMs` when available. Do not invent your own cadence if the server already told you one.
|
|
68
|
+
|
|
69
|
+
### 6. Takeover is explicit
|
|
70
|
+
|
|
71
|
+
If `wait_for_turn` reports `takeover_available`:
|
|
72
|
+
|
|
73
|
+
- explain why takeover is available (`owner_timeout`, `owner_gone`, `claim_timeout`, `recipient_gone`)
|
|
74
|
+
- do not silently take over just because it is possible
|
|
75
|
+
- if takeover is chosen, call `takeover_stick`
|
|
76
|
+
- after takeover, call `get_room_events` so you can reconstruct the last handoff before touching code
|
|
77
|
+
|
|
78
|
+
### 7. Finish with a real handoff
|
|
79
|
+
|
|
80
|
+
When you are done with your turn:
|
|
81
|
+
|
|
82
|
+
- use `release_stick` for normal sequence continuation
|
|
83
|
+
- use `pass_stick` only when a specific member should go next
|
|
84
|
+
|
|
85
|
+
Always include a non-empty handoff.
|
|
86
|
+
|
|
87
|
+
Minimum handoff quality:
|
|
88
|
+
|
|
89
|
+
- `status`: what you finished, what changed, and what remains true
|
|
90
|
+
- `next_action`: the concrete next step for the next owner
|
|
91
|
+
|
|
92
|
+
Add `artifacts`, `open_questions`, and `do_not` when they will save the next harness real time or prevent rework.
|
|
93
|
+
|
|
94
|
+
Example:
|
|
95
|
+
|
|
96
|
+
```json
|
|
97
|
+
{
|
|
98
|
+
"status": "Added the MCP smoke test and verified it against two clients sharing one SQLite database.",
|
|
99
|
+
"next_action": "Run the same handoff path through the human CLI and confirm pass/release behavior matches the MCP flow.",
|
|
100
|
+
"artifacts": [
|
|
101
|
+
{
|
|
102
|
+
"path": "tests/mcp-smoke.test.ts",
|
|
103
|
+
"role": "review",
|
|
104
|
+
"note": "End-to-end MCP adapter smoke coverage."
|
|
105
|
+
}
|
|
106
|
+
],
|
|
107
|
+
"open_questions": [
|
|
108
|
+
"Should install-skill default to copy or link for local development?"
|
|
109
|
+
]
|
|
110
|
+
}
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
## Recovery and Inspection
|
|
114
|
+
|
|
115
|
+
Use these reads when you need context:
|
|
116
|
+
|
|
117
|
+
- `list_rooms`: discover active rooms under a path
|
|
118
|
+
- `get_room_state`: authoritative current room projection
|
|
119
|
+
- `get_room_events`: replay recent claims, releases, passes, and takeovers
|
|
120
|
+
|
|
121
|
+
Prefer `get_room_state` over guessing from local memory when ownership may have changed.
|
|
122
|
+
|
|
123
|
+
## Behavior Priorities
|
|
124
|
+
|
|
125
|
+
In a Talking Stick workspace, prefer these properties in order:
|
|
126
|
+
|
|
127
|
+
1. no accidental parallel work
|
|
128
|
+
2. clear ownership
|
|
129
|
+
3. good handoffs
|
|
130
|
+
4. explicit recovery when someone stalls
|
|
131
|
+
|
|
132
|
+
Do not optimize for speed by cutting around the coordination protocol. The point of the protocol is to make multi-agent work predictable.
|