tryharness 0.7.83 → 0.7.86
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 +21 -19
- package/assets/dsh-plugin.mjs +75 -4
- package/assets/herdr-mod/harness/main.js +367 -0
- package/assets/herdr-mod/harness/mod.json +6 -0
- package/assets/opencode-plugin.js +87 -22
- package/assets/pi-extension.ts +81 -2
- package/cli.mjs +544 -208
- package/lib/adapters.mjs +62 -27
- package/lib/agentBinaries.mjs +6 -8
- package/lib/agentClaims.mjs +168 -0
- package/lib/agentReadTools.json +415 -0
- package/lib/agentSignIn.mjs +17 -18
- package/lib/agentWiring.mjs +114 -0
- package/lib/archetypes.js +10 -11
- package/lib/attention.mjs +100 -0
- package/lib/audit.mjs +1 -1
- package/lib/backupSetup.mjs +6 -28
- package/lib/bankrApprovals.mjs +86 -0
- package/lib/boardAccess.mjs +40 -66
- package/lib/boardBackup.mjs +86 -85
- package/lib/boardCommands.mjs +28 -0
- package/lib/boardFileCommands.mjs +29 -36
- package/lib/boardFiles.mjs +83 -15
- package/lib/boardMirror.mjs +78 -11
- package/lib/boardProtocol.json +191 -123
- package/lib/boardThreads.mjs +19 -37
- package/lib/boardTools.mjs +22 -15
- package/lib/boardWatches.mjs +43 -15
- package/lib/bridge.mjs +7 -3
- package/lib/browserAgentTools.mjs +59 -0
- package/lib/browserWake.mjs +0 -6
- package/lib/cards.mjs +52 -0
- package/lib/circling.mjs +189 -0
- package/lib/cleanup.mjs +234 -0
- package/lib/cloudBoot.mjs +21 -4
- package/lib/cloudSave.mjs +46 -5
- package/lib/compaction.mjs +8 -1
- package/lib/completion.mjs +358 -0
- package/lib/computerDevices.mjs +853 -0
- package/lib/connectionStatus.mjs +34 -0
- package/lib/connectors.mjs +139 -1
- package/lib/coordinator.mjs +108 -14
- package/lib/coreModels.mjs +36 -12
- package/lib/daemon.mjs +2426 -338
- package/lib/daemonLock.mjs +103 -0
- package/lib/deviceDoor.mjs +308 -0
- package/lib/deviceIdentity.mjs +114 -0
- package/lib/deviceList.mjs +172 -0
- package/lib/deviceSeal.mjs +74 -0
- package/lib/dispatcher.mjs +497 -26
- package/lib/dispatches.mjs +3 -3
- package/lib/environment.mjs +2 -1
- package/lib/environments.mjs +67 -41
- package/lib/events.mjs +318 -0
- package/lib/facts.mjs +170 -0
- package/lib/fileSource.mjs +540 -0
- package/lib/files.mjs +47 -2
- package/lib/gitHost.mjs +39 -1
- package/lib/goalCommands.mjs +12 -80
- package/lib/handover.mjs +21 -16
- package/lib/harnessOffers.mjs +140 -15
- package/lib/herdr.mjs +100 -15
- package/lib/herdrAppCall.mjs +19 -0
- package/lib/herdrCore.mjs +59 -0
- package/lib/herdrRuns.mjs +1126 -0
- package/lib/hookDialects.mjs +235 -50
- package/lib/identityLink.mjs +81 -0
- package/lib/inference.mjs +31 -2
- package/lib/jamAccess.mjs +82 -0
- package/lib/{projectBoard.mjs → jamBoard.mjs} +5 -4
- package/lib/{projectGit.mjs → jamGit.mjs} +53 -15
- package/lib/jamKey.mjs +274 -0
- package/lib/{projectPieces.mjs → jamPieces.mjs} +35 -29
- package/lib/{projectSettings.mjs → jamSettings.mjs} +12 -22
- package/lib/jamStore.mjs +973 -0
- package/lib/jamUpgrade.mjs +112 -0
- package/lib/jams.mjs +3079 -0
- package/lib/kanban.mjs +13 -7
- package/lib/landed.mjs +5 -1
- package/lib/library.mjs +41 -22
- package/lib/limits.mjs +91 -0
- package/lib/lineDiff.mjs +97 -0
- package/lib/lineup.mjs +18 -13
- package/lib/link.mjs +584 -0
- package/lib/localStack.mjs +75 -16
- package/lib/localmodels.mjs +58 -78
- package/lib/loopBackstop.mjs +2 -1
- package/lib/machine.mjs +544 -0
- package/lib/machineLink.mjs +446 -0
- package/lib/machineRoutes.mjs +68 -19
- package/lib/machineRuns.mjs +85 -4
- package/lib/machineSeal.mjs +6 -31
- package/lib/manager.mjs +134 -12
- package/lib/mcp-stdio.mjs +492 -215
- package/lib/mcpRelay.mjs +34 -35
- package/lib/members.json +1 -1
- package/lib/modelRoute.mjs +162 -0
- package/lib/nativeHost.mjs +81 -90
- package/lib/nativeSenses.mjs +258 -0
- package/lib/nerves.mjs +523 -0
- package/lib/network.mjs +117 -278
- package/lib/networkPlaces.mjs +578 -0
- package/lib/nextStep.mjs +95 -0
- package/lib/notify.mjs +2 -2
- package/lib/nudge.mjs +116 -10
- package/lib/originals.mjs +216 -0
- package/lib/outsideEvents.mjs +383 -0
- package/lib/outsideRuns.mjs +230 -0
- package/lib/ownMachines.mjs +674 -256
- package/lib/pain.mjs +215 -0
- package/lib/pairing.mjs +91 -11
- package/lib/paths.mjs +42 -3
- package/lib/peerProcess.mjs +21 -7
- package/lib/peopleLink.mjs +268 -0
- package/lib/personNotices.mjs +3 -2
- package/lib/phones.mjs +252 -542
- package/lib/placeCards.mjs +282 -0
- package/lib/placeChecks.mjs +95 -0
- package/lib/placeCommands.mjs +8 -17
- package/lib/placeRequests.mjs +152 -0
- package/lib/placeStore.mjs +295 -0
- package/lib/placeTool.d.ts +12 -0
- package/lib/placeTool.js +40 -0
- package/lib/places.mjs +63 -14
- package/lib/plans.mjs +53 -8
- package/lib/presence.mjs +270 -0
- package/lib/privateNetwork.d.ts +2 -0
- package/lib/privateNetwork.js +93 -0
- package/lib/proposals.mjs +300 -0
- package/lib/publicFetch.d.ts +32 -0
- package/lib/publicFetch.js +248 -0
- package/lib/reach.mjs +128 -0
- package/lib/rebuildable.mjs +72 -0
- package/lib/recall.mjs +216 -0
- package/lib/record.mjs +13 -0
- package/lib/reflexes.mjs +392 -0
- package/lib/relayLimits.mjs +31 -2
- package/lib/releaseNotice.mjs +198 -0
- package/lib/removeHarness.mjs +15 -4
- package/lib/repoLinks.mjs +204 -35
- package/lib/runAuthority.mjs +102 -39
- package/lib/runBrief.mjs +93 -40
- package/lib/runRequests.mjs +52 -14
- package/lib/runUsage.mjs +31 -0
- package/lib/runWorker.mjs +74 -25
- package/lib/runner.mjs +289 -45
- package/lib/runtime-install.mjs +37 -8
- package/lib/schedules.mjs +171 -47
- package/lib/screenWatches.mjs +221 -0
- package/lib/sealed.mjs +12 -30
- package/lib/sealedThreads.mjs +198 -392
- package/lib/secretStore.mjs +178 -0
- package/lib/secrets.mjs +11 -0
- package/lib/seen.mjs +3 -9
- package/lib/selfUpdate.mjs +51 -15
- package/lib/senseCall.mjs +1514 -0
- package/lib/senseHook.mjs +114 -0
- package/lib/senseTools.mjs +1298 -0
- package/lib/sessionBriefs.mjs +87 -0
- package/lib/sessionControl.mjs +63 -13
- package/lib/sessionFiles.mjs +85 -0
- package/lib/setupChoices.mjs +12 -3
- package/lib/setupMode.mjs +70 -25
- package/lib/sharedKeys.mjs +166 -0
- package/lib/sleep.mjs +396 -0
- package/lib/sources.mjs +306 -0
- package/lib/speech.mjs +166 -411
- package/lib/spoken.mjs +210 -0
- package/lib/steerHook.mjs +3 -1
- package/lib/steerQueue.mjs +40 -11
- package/lib/store.mjs +323 -130
- package/lib/stuck.mjs +85 -7
- package/lib/swarm.mjs +157 -49
- package/lib/swarmDevices.mjs +25 -85
- package/lib/swarmMemory.mjs +93 -9
- package/lib/t3.mjs +73 -3
- package/lib/taskCommands.mjs +51 -60
- package/lib/taskRooms.mjs +30 -4
- package/lib/taskRules.json +29 -0
- package/lib/taskRules.mjs +21 -0
- package/lib/taskRuns.mjs +74 -11
- package/lib/team.mjs +2 -1
- package/lib/threadActions.mjs +37 -9
- package/lib/threadAuthority.mjs +4 -4
- package/lib/threadBriefs.mjs +173 -43
- package/lib/threadNotes.mjs +320 -0
- package/lib/threadRecord.mjs +491 -0
- package/lib/threadRuns.mjs +216 -108
- package/lib/threadView.mjs +27 -30
- package/lib/threadWatches.mjs +1962 -0
- package/lib/timeSense.mjs +839 -0
- package/lib/tripwires.mjs +454 -0
- package/lib/ui.mjs +1 -1
- package/lib/vault.mjs +560 -45
- package/lib/vaultCommands.mjs +5 -3
- package/lib/vaultPeers.mjs +165 -0
- package/lib/vaultTools.d.ts +4 -1
- package/lib/vaultTools.js +22 -1
- package/lib/verdicts.mjs +12 -26
- package/lib/versions.mjs +117 -0
- package/lib/waitTool.mjs +278 -0
- package/lib/wakePicture.mjs +268 -0
- package/lib/wakeQueue.mjs +108 -0
- package/lib/watchResponses.mjs +533 -0
- package/lib/watches.mjs +290 -145
- package/lib/windowAsks.mjs +80 -17
- package/lib/worktrees.mjs +159 -9
- package/npm-shrinkwrap.json +138 -631
- package/package.json +7 -6
- package/release.json +211 -129
- package/lib/callSessions.mjs +0 -51
- package/lib/directLink.mjs +0 -349
- package/lib/peopleBoard.mjs +0 -131
- package/lib/projects.mjs +0 -2917
- package/lib/roomChannels.mjs +0 -667
|
@@ -12,8 +12,8 @@ import {
|
|
|
12
12
|
} from "./specialties.mjs";
|
|
13
13
|
|
|
14
14
|
// Working with other people's swarms (docs/swarm-organization.md, "Working with other people's swarms"; the words are
|
|
15
|
-
// GLOSSARY.md's): open pieces, claims, handoffs and each person's strengths in a shared room, on top of the
|
|
16
|
-
// record (
|
|
15
|
+
// GLOSSARY.md's): open pieces, claims, handoffs and each person's strengths in a shared room, on top of the jam's
|
|
16
|
+
// record (jams.mjs).
|
|
17
17
|
//
|
|
18
18
|
// - An open piece is a record entry (`piece`) with the specialty it needs and no owner. Any swarm in the room may claim
|
|
19
19
|
// it: each computer's own dispatcher, here in code, looks among its own agents in the room for a free one that carries
|
|
@@ -23,16 +23,16 @@ import {
|
|
|
23
23
|
// passes it on from its owner (at most HANDOFFS deep, never back to the agent it came from); a release by the owner's
|
|
24
24
|
// side puts it back up open. Two claims made at nearly the same moment: the first one made holds, and the computer
|
|
25
25
|
// whose claim lost stops its run.
|
|
26
|
-
// -
|
|
27
|
-
// claimed only once the person of the swarm that would take it says OK, and a guarded handoff to the other side
|
|
26
|
+
// - Work that needs a secret, spending or onchain actions does not go agent to agent across swarms by a claim: a guarded
|
|
27
|
+
// piece is claimed only once the person of the swarm that would take it says OK, and a guarded handoff to the other side
|
|
28
28
|
// waits for its receiving person. Both are proposals waiting on that one person, so they reach every surface as the
|
|
29
|
-
//
|
|
29
|
+
// jam's own `agree` needs-you card. Words that look like a secret never leave this computer. Using a secret across
|
|
30
|
+
// swarms goes through the vault, where the value stays on its own computer (vault.mjs).
|
|
30
31
|
|
|
31
32
|
export const HANDOFFS = 3;
|
|
32
|
-
// Kinds of record entry this module adds to a
|
|
33
|
+
// Kinds of record entry this module adds to a jam's record.
|
|
33
34
|
export const PIECE_KINDS = ["piece", "claim", "handoff", "accept", "release"];
|
|
34
35
|
const STRENGTHS = "strengths";
|
|
35
|
-
export const RECORD_KINDS = [...PIECE_KINDS, STRENGTHS];
|
|
36
36
|
// Declared side effects, as an outside agent's mandate names them (src/schemas/externalAgent.ts SIDE_EFFECT_CLASSES).
|
|
37
37
|
const EFFECTS = [
|
|
38
38
|
"financial_onchain",
|
|
@@ -74,13 +74,20 @@ export function guardOf(body) {
|
|
|
74
74
|
return null;
|
|
75
75
|
}
|
|
76
76
|
|
|
77
|
+
// Where the jam put an entry in its one order (its first event's sequence number); one not taken yet comes after all.
|
|
78
|
+
const placeOf = (entry) =>
|
|
79
|
+
Number.isInteger(entry.seq) ? entry.seq : Number.MAX_SAFE_INTEGER;
|
|
80
|
+
|
|
77
81
|
/**
|
|
78
|
-
* Who owns a piece now, worked out from the entries about it in the order
|
|
79
|
-
*
|
|
82
|
+
* Who owns a piece now, worked out from the entries about it in the order the jam took them (its sequence: two claims
|
|
83
|
+
* made at nearly the same moment are settled by which reached the jam first, whatever each computer's clock said; then
|
|
84
|
+
* by when made, side and id for entries not taken yet), so every computer holding the same entries agrees:
|
|
85
|
+
* `{ owner, from, depth, chain, offered, released, claimedBy }`.
|
|
80
86
|
*/
|
|
81
87
|
export function ownershipOf(entries) {
|
|
82
88
|
const ordered = [...entries].sort(
|
|
83
89
|
(a, b) =>
|
|
90
|
+
placeOf(a) - placeOf(b) ||
|
|
84
91
|
String(a.at).localeCompare(String(b.at)) ||
|
|
85
92
|
a.side.localeCompare(b.side) ||
|
|
86
93
|
a.id.localeCompare(b.id)
|
|
@@ -162,14 +169,14 @@ export function ownershipOf(entries) {
|
|
|
162
169
|
}
|
|
163
170
|
|
|
164
171
|
/**
|
|
165
|
-
* The pieces of one
|
|
172
|
+
* The pieces of one jam. Made by createJams, which hands it the jam's record (`items`, `item`,
|
|
166
173
|
* `write`), its names (`display`, `shared`, `local`), the room's agents (`ownAgents`, `remoteAgents`, `peopleOf`) and
|
|
167
174
|
* the run seams (`wakeRun`, `stopRun`, `laneOf`, `commitLane`, `changedFiles`).
|
|
168
175
|
*/
|
|
169
176
|
export function createPieces({
|
|
170
177
|
store,
|
|
171
178
|
log = () => {},
|
|
172
|
-
project,
|
|
179
|
+
jam: project,
|
|
173
180
|
items,
|
|
174
181
|
item,
|
|
175
182
|
write,
|
|
@@ -190,7 +197,7 @@ export function createPieces({
|
|
|
190
197
|
}) {
|
|
191
198
|
const pieceIn = (p, id) => {
|
|
192
199
|
const entry = item(id);
|
|
193
|
-
return entry?.kind === "piece" && entry.
|
|
200
|
+
return entry?.kind === "piece" && entry.jamId === p.id ? entry : null;
|
|
194
201
|
};
|
|
195
202
|
const eventsOf = (p, pieceId) =>
|
|
196
203
|
PIECE_KINDS.slice(1)
|
|
@@ -212,7 +219,7 @@ export function createPieces({
|
|
|
212
219
|
|
|
213
220
|
// ---- this side's dispatcher ----
|
|
214
221
|
|
|
215
|
-
// Whether an agent is at work anywhere on this computer now, or on a piece of work in this
|
|
222
|
+
// Whether an agent is at work anywhere on this computer now, or on a piece of work in this jam.
|
|
216
223
|
const busy = (p, agent) =>
|
|
217
224
|
Boolean(openWorkOf(p, p.me, agent)) ||
|
|
218
225
|
store.db.all(
|
|
@@ -277,7 +284,7 @@ export function createPieces({
|
|
|
277
284
|
piece: piece.id,
|
|
278
285
|
agent: shared(fresh, agent),
|
|
279
286
|
});
|
|
280
|
-
log(`
|
|
287
|
+
log(`jam ${fresh.id}: ${agent} claimed piece ${piece.id}`);
|
|
281
288
|
}
|
|
282
289
|
};
|
|
283
290
|
const timers = new Map();
|
|
@@ -288,7 +295,7 @@ export function createPieces({
|
|
|
288
295
|
try {
|
|
289
296
|
sweep(p);
|
|
290
297
|
} catch (error) {
|
|
291
|
-
log(`
|
|
298
|
+
log(`jam pieces: ${error.message}`);
|
|
292
299
|
}
|
|
293
300
|
}, SWEEP_MS);
|
|
294
301
|
timer.unref?.();
|
|
@@ -324,7 +331,7 @@ export function createPieces({
|
|
|
324
331
|
const accepted = state.acceptedBy === p.me;
|
|
325
332
|
const asker = hop?.from ?? piece.body.by ?? `${piece.side}/person`;
|
|
326
333
|
// A claim needs no OK; nor does what this side's person said yes to. A handoff from another swarm is work the
|
|
327
|
-
// other side pushed at a named agent, which `start` governs (
|
|
334
|
+
// other side pushed at a named agent, which `start` governs (jams.mjs gate).
|
|
328
335
|
const go =
|
|
329
336
|
!hop ||
|
|
330
337
|
accepted ||
|
|
@@ -351,7 +358,7 @@ export function createPieces({
|
|
|
351
358
|
/** This side's run on a piece ends where it is: stopped, its changes committed on its branch. */
|
|
352
359
|
const halted = (p, agent) => `piece-halted:${p.id}:${agent}`;
|
|
353
360
|
const halt = (p, work, fields) => {
|
|
354
|
-
// A run still going commits as it ends, into this piece's branch (
|
|
361
|
+
// A run still going commits as it ends, into this piece's branch (jams.mjs committed, stoppedWork).
|
|
355
362
|
if (
|
|
356
363
|
p.roomId &&
|
|
357
364
|
store
|
|
@@ -516,7 +523,7 @@ export function createPieces({
|
|
|
516
523
|
sweepSoon(p);
|
|
517
524
|
};
|
|
518
525
|
|
|
519
|
-
/** An entry of the
|
|
526
|
+
/** An entry of the jam's record was made here or arrived: the pieces it touches settle, and the dispatcher looks. */
|
|
520
527
|
const changed = (p, entry) => {
|
|
521
528
|
if (!p || !entry || p.status !== "open") return;
|
|
522
529
|
if (entry.kind === "piece") return sweepSoon(p);
|
|
@@ -621,8 +628,7 @@ export function createPieces({
|
|
|
621
628
|
const piece = items(p.id, "piece").find(
|
|
622
629
|
(entry) => stateOf(p, entry.id).owner === from && !doneOf(p, entry.id)
|
|
623
630
|
);
|
|
624
|
-
if (!piece)
|
|
625
|
-
throw new Error("You hold no piece in this project to hand on.");
|
|
631
|
+
if (!piece) throw new Error("You hold no piece in this jam to hand on.");
|
|
626
632
|
const state = stateOf(p, piece.id);
|
|
627
633
|
const named = String(to || "")
|
|
628
634
|
.trim()
|
|
@@ -655,7 +661,7 @@ export function createPieces({
|
|
|
655
661
|
entry.body.type === "handoff" &&
|
|
656
662
|
entry.body.piece === piece.id &&
|
|
657
663
|
!entry.body.withdrawn &&
|
|
658
|
-
!store.meta(`
|
|
664
|
+
!store.meta(`jam-accepted:${entry.id}`)
|
|
659
665
|
);
|
|
660
666
|
if (!waiting)
|
|
661
667
|
propose(
|
|
@@ -714,11 +720,11 @@ export function createPieces({
|
|
|
714
720
|
|
|
715
721
|
/** The person's and agents' piece commands; null for a command that isn't one. */
|
|
716
722
|
const command = (p, name, request, agent) => {
|
|
717
|
-
if (name === "board.
|
|
723
|
+
if (name === "board.jam.piece")
|
|
718
724
|
return post(p, agent === "user" ? "user" : agent, request);
|
|
719
|
-
if (name === "board.
|
|
725
|
+
if (name === "board.jam.release" && agent === "user")
|
|
720
726
|
return release(p, String(request.piece || ""));
|
|
721
|
-
if (name === "board.
|
|
727
|
+
if (name === "board.jam.handoff" && agent !== "user")
|
|
722
728
|
return handoff(p, agent, request);
|
|
723
729
|
return null;
|
|
724
730
|
};
|
|
@@ -779,7 +785,7 @@ export function createPieces({
|
|
|
779
785
|
entry.body.piece === piece.id &&
|
|
780
786
|
entry.side === p.me &&
|
|
781
787
|
!entry.body.withdrawn &&
|
|
782
|
-
!store.meta(`
|
|
788
|
+
!store.meta(`jam-accepted:${entry.id}`) &&
|
|
783
789
|
!items(p.id, "answer").some(
|
|
784
790
|
(answer) =>
|
|
785
791
|
answer.body.proposal === entry.id && answer.body.yes === false
|
|
@@ -831,7 +837,7 @@ export function createPieces({
|
|
|
831
837
|
});
|
|
832
838
|
};
|
|
833
839
|
|
|
834
|
-
/** What an agent in the room is told of the pieces, beside the rest of the
|
|
840
|
+
/** What an agent in the room is told of the pieces, beside the rest of the jam's record. */
|
|
835
841
|
const brief = (p, agent) => {
|
|
836
842
|
const pieces = view(p).filter((piece) => piece.state !== "done");
|
|
837
843
|
const own = pieces.find(
|
|
@@ -840,7 +846,7 @@ export function createPieces({
|
|
|
840
846
|
const state = own ? stateOf(p, own.id) : null;
|
|
841
847
|
return [
|
|
842
848
|
pieces.length
|
|
843
|
-
? `Open pieces of this
|
|
849
|
+
? `Open pieces of this jam (a swarm's dispatcher claims one for a free agent that fits; nobody routes another swarm's agents):\n${pieces
|
|
844
850
|
.map(
|
|
845
851
|
(piece) =>
|
|
846
852
|
`- "${lineOf(piece.summary, 160)}" needs ${piece.specialtyName}${piece.owner ? `, held by ${piece.owner.who}` : piece.state === "waiting" ? ", waiting for a person" : ", open"}`
|
|
@@ -850,7 +856,7 @@ export function createPieces({
|
|
|
850
856
|
own
|
|
851
857
|
? `You hold the piece "${lineOf(own.summary, 160)}". To pass it to another agent here, call plan_work with hand_to (one of your swarm's agents by name, or the other side's by its full name); you stay accountable until it reports. A piece is handed on at most ${HANDOFFS} times (${HANDOFFS - state.depth} left) and never back to the agent it came from.`
|
|
852
858
|
: "",
|
|
853
|
-
"To put up a piece any swarm in the room may claim, call plan_work with open and the specialty it needs.
|
|
859
|
+
"To put up a piece any swarm in the room may claim, call plan_work with open and the specialty it needs. A piece that needs a secret, spending or onchain actions waits for a person. To let the other swarm's agent use a secret you hold, without the value leaving this computer, use use_secret's pass.",
|
|
854
860
|
]
|
|
855
861
|
.filter(Boolean)
|
|
856
862
|
.join("\n");
|
|
@@ -871,7 +877,7 @@ export function createPieces({
|
|
|
871
877
|
return item(id);
|
|
872
878
|
};
|
|
873
879
|
|
|
874
|
-
/** The pieces as the
|
|
880
|
+
/** The pieces as the jam's board shows them (jamBoard.mjs), read without changing anything. */
|
|
875
881
|
const cards = (p) =>
|
|
876
882
|
items(p.id, "piece")
|
|
877
883
|
.filter((piece) => !piece.body.withdrawn)
|
|
@@ -1,35 +1,25 @@
|
|
|
1
|
-
// What a
|
|
2
|
-
//
|
|
3
|
-
// way from the same record, so they never disagree
|
|
1
|
+
// What a jam lets its agents do, and how its people change it: anything that gives agents more reach needs every
|
|
2
|
+
// current member; anything that takes reach away takes one, at once (owner, October 20; docs/jam-plan.md
|
|
3
|
+
// settled 8). Every member's computer works the settings out the same way from the same record, so they never disagree
|
|
4
|
+
// on what an agent may do. There is no setting that holds agents' words back: everyone in a jam sees everything
|
|
5
|
+
// (owner, November 12: holding agents' replies is "a little too strict everyone sees everything").
|
|
4
6
|
|
|
5
7
|
/**
|
|
6
8
|
* Each setting, narrowest first in `values`. `label` is how the person reads it; `on`/`off` read its two states for a
|
|
7
9
|
* yes/no setting, `choices` for one with words.
|
|
8
10
|
*/
|
|
9
11
|
export const SETTINGS = {
|
|
10
|
-
talk: {
|
|
11
|
-
label: "Agents talk to each other here without waiting for you",
|
|
12
|
-
values: [false, true],
|
|
13
|
-
initial: true,
|
|
14
|
-
},
|
|
15
12
|
start: {
|
|
16
|
-
// Consent to code running on this computer from
|
|
13
|
+
// Consent to code running on this computer from another person's words (security audit P2, October 25; D4): Claude
|
|
17
14
|
// Code or Codex runs it restricted in a copy (none of the person's credentials, no network, only the board and its
|
|
18
15
|
// own folder), any other agent still waits for the person's Start. On from the start: the person connected their
|
|
19
|
-
// swarm to
|
|
20
|
-
// are a trusted party doing collaborative work");
|
|
16
|
+
// swarm to collaborators to get work done (owner, October 31: "if hes connecting his AI to another persons, they
|
|
17
|
+
// are a trusted party doing collaborative work"); any member turns it off for everyone at once.
|
|
21
18
|
label:
|
|
22
|
-
"Agents start work
|
|
19
|
+
"Agents start work other people's agents ask for (this runs code on your computer)",
|
|
23
20
|
values: [false, true],
|
|
24
21
|
initial: true,
|
|
25
22
|
},
|
|
26
|
-
// Harness works on this person's credits, so it answers the other side only when both let it: money stays behind
|
|
27
|
-
// consent (owner, October 31), apart from the agents starting each other's work above.
|
|
28
|
-
harness: {
|
|
29
|
-
label: "Harness answers the other side (on your Harness credits)",
|
|
30
|
-
values: [false, true],
|
|
31
|
-
initial: false,
|
|
32
|
-
},
|
|
33
23
|
push: {
|
|
34
24
|
label: "Agents push their own branches",
|
|
35
25
|
values: [false, true],
|
|
@@ -67,7 +57,7 @@ export const initialSettings = () =>
|
|
|
67
57
|
export const validSetting = (key, value) =>
|
|
68
58
|
Object.hasOwn(SETTINGS, key) && SETTINGS[key].values.includes(value);
|
|
69
59
|
|
|
70
|
-
/** Whether moving `key` from `from` to `to` gives agents more reach, so
|
|
60
|
+
/** Whether moving `key` from `from` to `to` gives agents more reach, so every other member has to agree. */
|
|
71
61
|
export const widens = (key, from, to) => {
|
|
72
62
|
const order = SETTINGS[key].values;
|
|
73
63
|
return order.indexOf(to) > order.indexOf(from);
|
|
@@ -84,8 +74,8 @@ const consistent = (settings) =>
|
|
|
84
74
|
: settings;
|
|
85
75
|
|
|
86
76
|
/**
|
|
87
|
-
* The settings in force: those
|
|
88
|
-
*
|
|
77
|
+
* The settings in force: those the jam started with, then each change by when it took effect (a narrowing when it was
|
|
78
|
+
* made, a widening when the last member it needed agreed). Two changes at the same moment keep the narrower. Every
|
|
89
79
|
* change is `{ key, value, at }`.
|
|
90
80
|
*/
|
|
91
81
|
export function effectiveSettings(agreed, changes) {
|