gcf-aif-ext 0.15.0 → 0.18.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/README.md +34 -7
- package/commands/gcf.js +218 -30
- package/extension.json +1 -1
- package/hooks/pre-commit.js +4 -2
- package/lib/agent-permissions.js +2 -2
- package/lib/audit-core.js +11 -5
- package/lib/board.js +41 -8
- package/lib/bundle.js +58 -13
- package/lib/config-set.js +2 -2
- package/lib/design-check.js +37 -9
- package/lib/design-parts.js +787 -0
- package/lib/design.js +2 -0
- package/lib/domain.js +406 -36
- package/lib/git.js +13 -6
- package/lib/history.js +1 -0
- package/lib/id.js +47 -0
- package/lib/inbox-categories.js +228 -0
- package/lib/inbox.js +238 -86
- package/lib/integrate.js +14 -2
- package/lib/lessons.js +11 -3
- package/lib/main-lock.js +17 -0
- package/lib/migrate.js +3 -3
- package/lib/transitions.js +2 -0
- package/lib/unit-ops.js +6 -2
- package/lib/validate-item.js +3 -0
- package/lib/work-ops.js +81 -10
- package/package.json +1 -1
- package/profiles/game.md +2 -2
- package/profiles/pillars.md +3 -3
- package/schemas/item.schema.json +1 -0
- package/skills/gcf-adopt/SKILL.md +1 -1
- package/skills/gcf-card/SKILL.md +2 -2
- package/skills/gcf-chat/SKILL.md +8 -5
- package/skills/gcf-debate/SKILL.md +2 -2
- package/skills/gcf-ingest/SKILL.md +5 -3
- package/skills/gcf-init/SKILL.md +13 -9
- package/skills/gcf-triage/SKILL.md +7 -7
- package/skills/gcf-vision/SKILL.md +8 -3
- package/templates/PILLARS.md +2 -0
- package/templates/agents-block.md +14 -6
package/lib/design.js
CHANGED
|
@@ -23,6 +23,8 @@ export const HEADER_KEYS = [
|
|
|
23
23
|
'flags',
|
|
24
24
|
'reopens',
|
|
25
25
|
];
|
|
26
|
+
// GCF-PRD §5.3: no more than 7 pillars.
|
|
27
|
+
export const PILLARS_MAX = 7;
|
|
26
28
|
// Engineering decisions of the agent, not words of the designer: no provenance needed.
|
|
27
29
|
export const AGENT_SLOTS = ['check', 'measure', 'contract', 'interactions'];
|
|
28
30
|
|
package/lib/domain.js
CHANGED
|
@@ -4,9 +4,10 @@
|
|
|
4
4
|
// draws these and builds each command from `args` and `fields`; it hard-codes none of them.
|
|
5
5
|
import { ITEM_MOVES, STORED } from './transitions.js';
|
|
6
6
|
import { DEFAULT_GATE, GATES, ITEM_TYPES, SEVERITIES, UNIT_ITEM_TYPES } from './validate-item.js';
|
|
7
|
-
import {
|
|
7
|
+
import { BASE_CATEGORIES, mergeVocabulary, questionOnly } from './inbox-categories.js';
|
|
8
8
|
import { NOTE_MAX } from './work-ops.js';
|
|
9
9
|
import { SESSION_TTL_MS } from './session-mark.js';
|
|
10
|
+
import { RUN_MODES } from './gcf-paths.js';
|
|
10
11
|
|
|
11
12
|
// The status a run starts from; the order of its column is the run order.
|
|
12
13
|
export const RUNS_FROM = 'ready';
|
|
@@ -71,14 +72,21 @@ const decide = (choice, help, fields = [], danger) => ({
|
|
|
71
72
|
...(danger && { danger }),
|
|
72
73
|
});
|
|
73
74
|
const text = (key, label, extra = {}) => ({ key, label, kind: 'text', ...extra });
|
|
74
|
-
// How an item's run goes: a board offers
|
|
75
|
-
//
|
|
76
|
-
//
|
|
77
|
-
const
|
|
78
|
-
const MODEL = text('model', 'Model of its run', { presets: 'model', help:
|
|
79
|
-
const EFFORT = text('effort', 'Effort of its run', { presets: 'effort', help:
|
|
75
|
+
// How an item's run goes (decision 36): a board offers Default (`default`), which leaves the
|
|
76
|
+
// choice to the project's `agent.model|effort`, else the agent's defaults (Opus, High), then its
|
|
77
|
+
// agent's presets (`presets`). The console takes any word.
|
|
78
|
+
const picks = (d) => `Default: the project's setting, else ${d}`;
|
|
79
|
+
const MODEL = text('model', 'Model of its run', { presets: 'model', help: picks('Opus') });
|
|
80
|
+
const EFFORT = text('effort', 'Effort of its run', { presets: 'effort', help: picks('High') });
|
|
81
|
+
// Where an item's runs go (Methodology §7): the operator's choice over the project's run_mode;
|
|
82
|
+
// the framework does not judge which a project's work needs.
|
|
83
|
+
const RUN_MODE_HELP = {
|
|
84
|
+
worktree: 'its own copy, several runs at once; its branch merges after a green verify',
|
|
85
|
+
main: 'the project folder, one run at a time; the agent records its move there',
|
|
86
|
+
};
|
|
80
87
|
|
|
81
|
-
// An item's moves (§4.1), offered by `items[].moves`.
|
|
88
|
+
// An item's moves (§4.1), offered by `items[].moves`. A project chat agent may propose one with
|
|
89
|
+
// `propose` (AD-12, AD-53): the board shows it as a card, the operator's click makes it.
|
|
82
90
|
const ITEM_SPECS = {
|
|
83
91
|
submit: {
|
|
84
92
|
label: 'submit',
|
|
@@ -141,6 +149,7 @@ const ITEM_SPECS = {
|
|
|
141
149
|
help: 'Stop it until the operator answers',
|
|
142
150
|
args: ['gcf', 'block', '{id}'],
|
|
143
151
|
fields: [REASON],
|
|
152
|
+
propose: true,
|
|
144
153
|
},
|
|
145
154
|
unblock: {
|
|
146
155
|
label: 'unblock',
|
|
@@ -157,6 +166,7 @@ const ITEM_SPECS = {
|
|
|
157
166
|
danger: true,
|
|
158
167
|
rare: true,
|
|
159
168
|
drag: 'graveyard',
|
|
169
|
+
propose: true,
|
|
160
170
|
},
|
|
161
171
|
depends: {
|
|
162
172
|
label: 'depends',
|
|
@@ -167,6 +177,7 @@ const ITEM_SPECS = {
|
|
|
167
177
|
{ key: 'remove', label: 'Remove: ids it no longer waits for', kind: 'ids' },
|
|
168
178
|
],
|
|
169
179
|
rare: true,
|
|
180
|
+
propose: true,
|
|
170
181
|
},
|
|
171
182
|
agent: {
|
|
172
183
|
label: 'model / effort',
|
|
@@ -175,6 +186,26 @@ const ITEM_SPECS = {
|
|
|
175
186
|
fields: [MODEL, EFFORT],
|
|
176
187
|
rare: true,
|
|
177
188
|
},
|
|
189
|
+
mode: {
|
|
190
|
+
label: 'run mode',
|
|
191
|
+
help: 'Where its runs go: the project folder or a worktree of their own; the next run takes it',
|
|
192
|
+
args: ['gcf', 'item', 'mode', '{id}'],
|
|
193
|
+
fields: [
|
|
194
|
+
{
|
|
195
|
+
// The item's field it sets, so the drawer's change starts from its value.
|
|
196
|
+
key: 'run_mode',
|
|
197
|
+
flag: 'run',
|
|
198
|
+
label: 'Its runs go',
|
|
199
|
+
kind: 'choice',
|
|
200
|
+
required: true,
|
|
201
|
+
options: [
|
|
202
|
+
{ value: 'default', label: "default: the project's run_mode" },
|
|
203
|
+
...RUN_MODES.map((m) => ({ value: m, label: m, help: RUN_MODE_HELP[m] })),
|
|
204
|
+
],
|
|
205
|
+
},
|
|
206
|
+
],
|
|
207
|
+
rare: true,
|
|
208
|
+
},
|
|
178
209
|
attach: {
|
|
179
210
|
label: 'attach',
|
|
180
211
|
help: 'Give the item a file (a chat image, a reference): committed in its attachments',
|
|
@@ -199,11 +230,10 @@ const RUN = {
|
|
|
199
230
|
// shows the proposal, the operator's click makes it.
|
|
200
231
|
const NEW_ITEM = {
|
|
201
232
|
label: 'create',
|
|
202
|
-
help: 'A new work item, committed; the core refuses a type the phase does not take',
|
|
203
|
-
args: ['gcf', 'item', 'new', '
|
|
233
|
+
help: 'A new work item, committed; its id comes from the title; the core refuses a type the phase does not take',
|
|
234
|
+
args: ['gcf', 'item', 'new', '--commit'],
|
|
204
235
|
propose: true,
|
|
205
236
|
fields: [
|
|
206
|
-
{ key: 'id', label: 'Id (lowercase-hyphen slug)', kind: 'slug', required: true },
|
|
207
237
|
{
|
|
208
238
|
key: 'type',
|
|
209
239
|
label: 'Type',
|
|
@@ -235,11 +265,13 @@ const NEW_ITEM = {
|
|
|
235
265
|
},
|
|
236
266
|
text('release', 'Version', { required: true, when: { key: 'type', is: ['release'] } }),
|
|
237
267
|
text('channel', 'Channel', { required: true, when: { key: 'type', is: ['release'] } }),
|
|
238
|
-
text('title', 'Title: one line, what it gives'),
|
|
268
|
+
text('title', 'Title: one line, what it gives', { required: true }),
|
|
239
269
|
text('system', 'Subsystems, comma-separated'),
|
|
240
|
-
{ key: 'depends', label: 'Depends on
|
|
241
|
-
|
|
242
|
-
|
|
270
|
+
{ key: 'depends', label: 'Depends on', kind: 'ids' },
|
|
271
|
+
// One live feature, picked by its title (decision 34).
|
|
272
|
+
{ key: 'parent', label: 'Parent feature', kind: 'ids', single: true, of: ['feature'] },
|
|
273
|
+
// A milestone of game.md: a board picks it from the read's `design.milestones` (`from`).
|
|
274
|
+
text('milestone', 'Milestone', { from: 'milestones' }),
|
|
243
275
|
text('blocked', 'Start blocked: why (e.g. "file needed")'),
|
|
244
276
|
MODEL,
|
|
245
277
|
EFFORT,
|
|
@@ -256,6 +288,294 @@ const NEW_ITEM = {
|
|
|
256
288
|
],
|
|
257
289
|
};
|
|
258
290
|
|
|
291
|
+
// A part of the design a save names (`gcf design part`): its kind, and the hash it was read at.
|
|
292
|
+
const PART_FIELDS = [
|
|
293
|
+
{
|
|
294
|
+
key: 'kind',
|
|
295
|
+
label: 'Part',
|
|
296
|
+
kind: 'choice',
|
|
297
|
+
required: true,
|
|
298
|
+
hidden: true,
|
|
299
|
+
options: ['doc', 'system', 'unit'].map((k) => ({ value: k, label: k })),
|
|
300
|
+
},
|
|
301
|
+
text('base', 'Read at', { hidden: true }),
|
|
302
|
+
text('system', 'Subsystem of a new unit', { hidden: true }),
|
|
303
|
+
text('type', 'Type of a new unit', { hidden: true }),
|
|
304
|
+
text('title', 'Title of a new unit', { hidden: true }),
|
|
305
|
+
];
|
|
306
|
+
|
|
307
|
+
// The design's moves (Board-PRD §5.24): a part saved from its form or as text, a session's
|
|
308
|
+
// files recorded, a designer's bundle brought back, a new unit, a draft discarded, a pillar retired, a unit dropped.
|
|
309
|
+
// Every save goes through the import's three-way check and the design check.
|
|
310
|
+
const DESIGN_SPECS = {
|
|
311
|
+
'design-save': {
|
|
312
|
+
label: 'save',
|
|
313
|
+
help: 'Save the edited fields; refused when the part changed since, or on a new finding',
|
|
314
|
+
args: ['gcf', 'design', 'save', '{id}'],
|
|
315
|
+
fields: [
|
|
316
|
+
...PART_FIELDS,
|
|
317
|
+
// The edited fields as JSON, key → value: a form builds it, not the operator.
|
|
318
|
+
{ key: 'fields', label: 'Fields', kind: 'longtext', required: true, stdin: true },
|
|
319
|
+
],
|
|
320
|
+
},
|
|
321
|
+
'design-save-text': {
|
|
322
|
+
label: 'save text',
|
|
323
|
+
help: 'Save the part as text: for what a form cannot hold (a comment, prose)',
|
|
324
|
+
args: ['gcf', 'design', 'save', '{id}'],
|
|
325
|
+
fields: [
|
|
326
|
+
...PART_FIELDS,
|
|
327
|
+
{ key: 'text', label: 'Text', kind: 'longtext', required: true, stdin: true },
|
|
328
|
+
],
|
|
329
|
+
},
|
|
330
|
+
'design-commit': {
|
|
331
|
+
label: 'record design',
|
|
332
|
+
help: 'Commit what a design session wrote; refused while the design check has a finding',
|
|
333
|
+
args: ['gcf', 'design', 'commit'],
|
|
334
|
+
fields: [text('message', 'What changed, one line')],
|
|
335
|
+
},
|
|
336
|
+
'design-import': {
|
|
337
|
+
label: 'import',
|
|
338
|
+
help: "Bring a designer's edited bundle back: what changed in gcf/ meanwhile is reported",
|
|
339
|
+
args: ['gcf', 'design', 'import', '--commit'],
|
|
340
|
+
fields: [{ key: 'bundle', label: 'Bundle', kind: 'longtext', required: true, stdin: true }],
|
|
341
|
+
},
|
|
342
|
+
'design-new-unit': {
|
|
343
|
+
label: 'add unit',
|
|
344
|
+
help: 'A new unit of the subsystem, its slots TBD; its id comes from the title',
|
|
345
|
+
args: ['gcf', 'design', 'save', '--kind', 'unit'],
|
|
346
|
+
fields: [
|
|
347
|
+
text('system', 'Subsystem', { required: true }),
|
|
348
|
+
{
|
|
349
|
+
key: 'type',
|
|
350
|
+
label: 'Type',
|
|
351
|
+
kind: 'choice',
|
|
352
|
+
required: true,
|
|
353
|
+
options: UNIT_ITEM_TYPES.map((t) => ({ value: t, label: t })),
|
|
354
|
+
},
|
|
355
|
+
text('title', 'Title', { required: true }),
|
|
356
|
+
{
|
|
357
|
+
key: 'fields',
|
|
358
|
+
label: 'Fields',
|
|
359
|
+
kind: 'longtext',
|
|
360
|
+
required: true,
|
|
361
|
+
stdin: true,
|
|
362
|
+
hidden: true,
|
|
363
|
+
},
|
|
364
|
+
],
|
|
365
|
+
},
|
|
366
|
+
'design-discard': {
|
|
367
|
+
label: 'discard draft',
|
|
368
|
+
help: "The agent's draft not recorded goes: its files as the last record has them",
|
|
369
|
+
args: ['gcf', 'design', 'discard'],
|
|
370
|
+
fields: [],
|
|
371
|
+
danger: true,
|
|
372
|
+
},
|
|
373
|
+
'pillar-retire': {
|
|
374
|
+
label: 'retire',
|
|
375
|
+
help: 'The game no longer holds it: units left with no pillar read pillars: TBD',
|
|
376
|
+
args: ['gcf', 'pillar', 'retire', '{id}'],
|
|
377
|
+
fields: [REASON],
|
|
378
|
+
danger: true,
|
|
379
|
+
},
|
|
380
|
+
'unit-drop': {
|
|
381
|
+
label: 'drop',
|
|
382
|
+
help: 'The unit leaves the design into the graveyard, with the reason',
|
|
383
|
+
args: ['gcf', 'drop', '{id}'],
|
|
384
|
+
fields: [REASON, { key: 'tags', label: 'Graveyard tags', kind: 'tags' }],
|
|
385
|
+
danger: true,
|
|
386
|
+
},
|
|
387
|
+
};
|
|
388
|
+
|
|
389
|
+
// What an agent does for the design from the board (Board-PRD §5.24): each start opens a
|
|
390
|
+
// project chat thread that follows its skill, not gcf-chat, with the first message `say`
|
|
391
|
+
// (`{file}`: an uploaded GDD, `{unit}`: a unit id, `{system}`: a subsystem, `{text}`: the
|
|
392
|
+
// operator's words). `edits`: the
|
|
393
|
+
// files its agent writes without a permission card; everything else still asks.
|
|
394
|
+
const DESIGN_EDITS = [
|
|
395
|
+
'gcf/game.md',
|
|
396
|
+
'gcf/glossary.md',
|
|
397
|
+
'gcf/backlog.md',
|
|
398
|
+
'gcf/open-questions.md',
|
|
399
|
+
'gcf/INDEX.md',
|
|
400
|
+
'gcf/design/**',
|
|
401
|
+
];
|
|
402
|
+
const STARTS = {
|
|
403
|
+
vision: {
|
|
404
|
+
label: 'Create with agent',
|
|
405
|
+
help: 'An interview about the game: genre, fantasy, references, loop, scope, what it is not',
|
|
406
|
+
skill: 'gcf-vision',
|
|
407
|
+
say: 'Start the game design with me: the vision interview.',
|
|
408
|
+
edits: DESIGN_EDITS,
|
|
409
|
+
},
|
|
410
|
+
ingest: {
|
|
411
|
+
label: 'Import GDD',
|
|
412
|
+
help: 'A GDD (.md) becomes design units, questions, and drafts of the vision and glossary',
|
|
413
|
+
skill: 'gcf-ingest',
|
|
414
|
+
takes: 'file',
|
|
415
|
+
say: 'Import the GDD {file}.',
|
|
416
|
+
edits: DESIGN_EDITS,
|
|
417
|
+
},
|
|
418
|
+
'review-gdd': {
|
|
419
|
+
label: 'Review GDD first',
|
|
420
|
+
help: 'Expert lenses read the GDD before its import; their findings become questions',
|
|
421
|
+
skill: 'gcf-debate',
|
|
422
|
+
takes: 'file',
|
|
423
|
+
say: 'Review the GDD {file}; it is not imported yet.',
|
|
424
|
+
edits: ['gcf/open-questions.md', 'gcf/INDEX.md'],
|
|
425
|
+
},
|
|
426
|
+
pillars: {
|
|
427
|
+
label: 'Pillars interview',
|
|
428
|
+
help: "The game's 2..7 pillars, each with what it forbids and its review question",
|
|
429
|
+
skill: 'gcf-init',
|
|
430
|
+
say:
|
|
431
|
+
'gcf/ exists: run the pillars interview with me; with gcf/PILLARS.md empty, start from ' +
|
|
432
|
+
'candidates you draw from the vision and the design units.',
|
|
433
|
+
edits: ['gcf/PILLARS.md', 'gcf/INDEX.md'],
|
|
434
|
+
},
|
|
435
|
+
'revise-pillars': {
|
|
436
|
+
label: 'Revise with agent',
|
|
437
|
+
help: 'Talk a change of the pillars through: the agent proposes, you confirm',
|
|
438
|
+
skill: 'gcf-init',
|
|
439
|
+
takes: 'text',
|
|
440
|
+
say: 'Revise the pillars with me: {text}',
|
|
441
|
+
edits: ['gcf/PILLARS.md', 'gcf/INDEX.md'],
|
|
442
|
+
},
|
|
443
|
+
'revise-vision': {
|
|
444
|
+
label: 'Change with agent',
|
|
445
|
+
help: 'Talk a change of the vision, scope or milestones through',
|
|
446
|
+
skill: 'gcf-vision',
|
|
447
|
+
takes: 'text',
|
|
448
|
+
say: 'Change the vision with me: {text}',
|
|
449
|
+
edits: DESIGN_EDITS,
|
|
450
|
+
},
|
|
451
|
+
debate: {
|
|
452
|
+
label: 'Review with agent',
|
|
453
|
+
help: 'Expert lenses read the whole design: holes and contradictions become questions',
|
|
454
|
+
skill: 'gcf-debate',
|
|
455
|
+
say: 'Review the design.',
|
|
456
|
+
edits: DESIGN_EDITS,
|
|
457
|
+
},
|
|
458
|
+
'debate-unit': {
|
|
459
|
+
label: 'Review with agent',
|
|
460
|
+
help: 'Expert lenses read this unit',
|
|
461
|
+
skill: 'gcf-debate',
|
|
462
|
+
takes: 'unit',
|
|
463
|
+
say: 'Review unit {unit}.',
|
|
464
|
+
edits: DESIGN_EDITS,
|
|
465
|
+
},
|
|
466
|
+
// A draft beside an empty or TBD part (decision 35): the agent writes it, records nothing; the
|
|
467
|
+
// operator records it, edits it in the form, or discards it.
|
|
468
|
+
'draft-glossary': {
|
|
469
|
+
label: 'Draft with agent',
|
|
470
|
+
help: 'A draft of the glossary from the vision and the units: you record it, edit or discard it',
|
|
471
|
+
skill: 'gcf-vision',
|
|
472
|
+
say: 'Draft gcf/glossary.md from the vision and the design units. Write it, do not record it.',
|
|
473
|
+
edits: DESIGN_EDITS,
|
|
474
|
+
},
|
|
475
|
+
'draft-system': {
|
|
476
|
+
label: 'Draft with agent',
|
|
477
|
+
help: "A draft of the subsystem's purpose from its units and the vision",
|
|
478
|
+
skill: 'gcf-vision',
|
|
479
|
+
takes: 'system',
|
|
480
|
+
say:
|
|
481
|
+
'Draft the purpose of subsystem {system} from its units and the vision. Write it, do not ' +
|
|
482
|
+
'record it.',
|
|
483
|
+
edits: DESIGN_EDITS,
|
|
484
|
+
},
|
|
485
|
+
'name-pillars': {
|
|
486
|
+
label: 'Name with agent',
|
|
487
|
+
help: 'A short name for each pillar without one, from its statement',
|
|
488
|
+
skill: 'gcf-init',
|
|
489
|
+
say:
|
|
490
|
+
'Give each pillar of gcf/PILLARS.md without a name a short name of 2 to 4 words from its ' +
|
|
491
|
+
'statement. Change nothing else, do not record it.',
|
|
492
|
+
edits: ['gcf/PILLARS.md', 'gcf/INDEX.md'],
|
|
493
|
+
},
|
|
494
|
+
card: {
|
|
495
|
+
label: 'Fill TBDs with agent',
|
|
496
|
+
help: "Go through the unit's TBDs together; it goes into work only when you say so",
|
|
497
|
+
skill: 'gcf-card',
|
|
498
|
+
takes: 'unit',
|
|
499
|
+
say: 'Go through the TBDs of unit {unit} with me; take it into work only when I say so.',
|
|
500
|
+
edits: DESIGN_EDITS,
|
|
501
|
+
},
|
|
502
|
+
};
|
|
503
|
+
|
|
504
|
+
// The way from an empty project to its first work, in order: the board shows each step done or
|
|
505
|
+
// not (the board read's `design.steps`) with the starts that do it.
|
|
506
|
+
const DESIGN_STEPS = [
|
|
507
|
+
{
|
|
508
|
+
id: 'design',
|
|
509
|
+
label: 'The game design',
|
|
510
|
+
help: 'Import a GDD, or create the design with an agent: design units, the vision, the scope',
|
|
511
|
+
starts: ['ingest', 'review-gdd', 'vision', 'draft-glossary'],
|
|
512
|
+
},
|
|
513
|
+
{
|
|
514
|
+
id: 'pillars',
|
|
515
|
+
label: 'Pillars',
|
|
516
|
+
help: 'What the game always holds: every unit and every review answers to them',
|
|
517
|
+
starts: ['pillars', 'name-pillars'],
|
|
518
|
+
},
|
|
519
|
+
{
|
|
520
|
+
id: 'questions',
|
|
521
|
+
label: 'Open questions',
|
|
522
|
+
help: 'What the design leaves open: a unit a question holds cannot go into work',
|
|
523
|
+
},
|
|
524
|
+
{
|
|
525
|
+
id: 'work',
|
|
526
|
+
label: 'First work',
|
|
527
|
+
help: 'A unit with no TBD and no question goes into work: it becomes a card on the board',
|
|
528
|
+
starts: ['card'],
|
|
529
|
+
},
|
|
530
|
+
];
|
|
531
|
+
|
|
532
|
+
// The game's own inbox categories (Board-PRD §2.6), merged over the framework's base.
|
|
533
|
+
const GAME_CATEGORIES = [
|
|
534
|
+
{
|
|
535
|
+
id: 'playtest',
|
|
536
|
+
label: 'Play note',
|
|
537
|
+
help: 'What you saw while playing',
|
|
538
|
+
rank: 5,
|
|
539
|
+
group: 'to-sort',
|
|
540
|
+
// An agent records one only in a playtest session, on the operator's words.
|
|
541
|
+
set_by: ['you', 'agent'],
|
|
542
|
+
details: null,
|
|
543
|
+
later: true,
|
|
544
|
+
},
|
|
545
|
+
{
|
|
546
|
+
id: 'tune',
|
|
547
|
+
label: 'Tune note',
|
|
548
|
+
help: 'A note on the feel or a number of an item that waits for its verdict',
|
|
549
|
+
rank: 10,
|
|
550
|
+
group: 'ideas',
|
|
551
|
+
set_by: ['you'],
|
|
552
|
+
details: null,
|
|
553
|
+
later: true,
|
|
554
|
+
},
|
|
555
|
+
];
|
|
556
|
+
|
|
557
|
+
/** The inbox's vocabulary of a GCF project: the base and the game's layer (decision 32). */
|
|
558
|
+
export const inboxVocabulary = () => mergeVocabulary(BASE_CATEGORIES, GAME_CATEGORIES);
|
|
559
|
+
|
|
560
|
+
// An entry's category: one an entry can be filed in or moved into; the core checks who may.
|
|
561
|
+
const CATEGORY = (dflt) => ({
|
|
562
|
+
key: 'category',
|
|
563
|
+
label: 'Category',
|
|
564
|
+
kind: 'choice',
|
|
565
|
+
required: true,
|
|
566
|
+
...(dflt && { default: dflt }),
|
|
567
|
+
options: inboxVocabulary()
|
|
568
|
+
.categories.filter((c) => !questionOnly(c) && c.set_by.length)
|
|
569
|
+
.map((c) => ({ value: c.id, label: c.label, help: c.help })),
|
|
570
|
+
});
|
|
571
|
+
const DETAIL = {
|
|
572
|
+
key: 'detail',
|
|
573
|
+
label: 'Detail',
|
|
574
|
+
kind: 'text',
|
|
575
|
+
max: 30,
|
|
576
|
+
help: 'One lowercase word after the category: asset, static-analysis, framework',
|
|
577
|
+
};
|
|
578
|
+
|
|
259
579
|
// The moves of the domain's blocks: the phase, the inbox, the questions, the run order.
|
|
260
580
|
const BLOCK_SPECS = {
|
|
261
581
|
'item-new': NEW_ITEM,
|
|
@@ -275,19 +595,14 @@ const BLOCK_SPECS = {
|
|
|
275
595
|
},
|
|
276
596
|
'inbox-add': {
|
|
277
597
|
label: 'add',
|
|
278
|
-
help: 'A raw note for triage (an idea, a playtest note, a
|
|
598
|
+
help: 'A raw note for triage (an idea, a playtest note, a bug); line 1 is its title',
|
|
279
599
|
args: ['gcf', 'inbox', 'add', '--commit'],
|
|
280
600
|
fields: [
|
|
281
601
|
{ key: 'text', label: 'Text', kind: 'longtext', required: true },
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
label: 'Source',
|
|
285
|
-
kind: 'choice',
|
|
286
|
-
default: 'operator',
|
|
287
|
-
options: SOURCES.map((s) => ({ value: s, label: s })),
|
|
288
|
-
},
|
|
289
|
-
{ key: 'tags', label: 'Tags', kind: 'tags' },
|
|
602
|
+
CATEGORY('note'),
|
|
603
|
+
DETAIL,
|
|
290
604
|
],
|
|
605
|
+
propose: true,
|
|
291
606
|
},
|
|
292
607
|
'inbox-drop': {
|
|
293
608
|
label: 'erase',
|
|
@@ -295,15 +610,28 @@ const BLOCK_SPECS = {
|
|
|
295
610
|
args: ['gcf', 'inbox', 'drop', '{id}', '--commit'],
|
|
296
611
|
fields: [],
|
|
297
612
|
danger: true,
|
|
613
|
+
propose: true,
|
|
298
614
|
},
|
|
299
|
-
'inbox-
|
|
300
|
-
label: '
|
|
301
|
-
help: '
|
|
302
|
-
args: ['gcf', 'inbox', '
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
615
|
+
'inbox-category': {
|
|
616
|
+
label: 'sort',
|
|
617
|
+
help: 'Give the entry another category or detail; where it came from stays',
|
|
618
|
+
args: ['gcf', 'inbox', 'category', '{id}', '--commit'],
|
|
619
|
+
// An emptied detail goes as `--detail=`: it clears the one there.
|
|
620
|
+
fields: [CATEGORY(), { ...DETAIL, clear: true }],
|
|
621
|
+
propose: true,
|
|
622
|
+
},
|
|
623
|
+
'inbox-later': {
|
|
624
|
+
label: 'later',
|
|
625
|
+
help: 'Put the entry away to Later: nothing there asks for you now',
|
|
626
|
+
args: ['gcf', 'inbox', 'later', '{id}', '--commit'],
|
|
627
|
+
fields: [],
|
|
628
|
+
propose: true,
|
|
629
|
+
},
|
|
630
|
+
'inbox-back': {
|
|
631
|
+
label: 'back',
|
|
632
|
+
help: 'Take the entry back from Later to its group',
|
|
633
|
+
args: ['gcf', 'inbox', 'later', '{id}', '--off', '--commit'],
|
|
634
|
+
fields: [],
|
|
307
635
|
},
|
|
308
636
|
'question-answer': {
|
|
309
637
|
label: 'answer',
|
|
@@ -317,6 +645,7 @@ const BLOCK_SPECS = {
|
|
|
317
645
|
args: ['gcf', 'prioritize', '{ids}'],
|
|
318
646
|
fields: [],
|
|
319
647
|
},
|
|
648
|
+
...DESIGN_SPECS,
|
|
320
649
|
};
|
|
321
650
|
|
|
322
651
|
// The item fields a board shows: on the card (`card`), in the drawer (all that have a value).
|
|
@@ -339,6 +668,7 @@ const FIELDS = [
|
|
|
339
668
|
// `edit`: the move that changes it, from the drawer.
|
|
340
669
|
{ key: 'model', label: 'model', kind: 'text', card: true, edit: 'agent' },
|
|
341
670
|
{ key: 'effort', label: 'effort', kind: 'text', edit: 'agent' },
|
|
671
|
+
{ key: 'run_mode', label: 'run mode', kind: 'text', edit: 'mode' },
|
|
342
672
|
{ key: 'tune_count', label: 'tune', kind: 'text', help: 'Tune verdicts so far', card: true },
|
|
343
673
|
{
|
|
344
674
|
key: 'waits_for',
|
|
@@ -380,11 +710,23 @@ const TERMS = [
|
|
|
380
710
|
'A parent item: when its children are done, the operator decides: close, continue or kill',
|
|
381
711
|
],
|
|
382
712
|
['design unit', 'A mechanic, resource, rule, constraint or entity of gcf/design/'],
|
|
713
|
+
[
|
|
714
|
+
'GDD import',
|
|
715
|
+
'A GDD becomes design units (each slot a GDD quote or TBD), questions, drafts of the vision ' +
|
|
716
|
+
'and the glossary, and pillar candidates: no item until a unit goes into work',
|
|
717
|
+
],
|
|
718
|
+
['pillar', 'What the game always holds: units cite it, a review asks its question'],
|
|
719
|
+
[
|
|
720
|
+
'record design',
|
|
721
|
+
'One commit of what a design session wrote: pillars, vision, glossary, units, questions',
|
|
722
|
+
],
|
|
383
723
|
['phase', 'The stage of the project (prototype, vertical slice…): the types it takes'],
|
|
384
724
|
['WIP', 'Items built and waiting for a verdict; at the limit new verdict work stops'],
|
|
385
725
|
['verify', 'The DoD: the project test and build commands, green on the code as it is'],
|
|
386
726
|
['inbox', 'Raw input waiting for triage: it becomes an item or is erased'],
|
|
387
727
|
['lesson', 'An inbox entry an agent session left: what got in its way'],
|
|
728
|
+
['category', 'What an inbox entry or a question asks of you: it sets its group and rank'],
|
|
729
|
+
['Later', 'Inbox entries put away: nothing there asks for you now'],
|
|
388
730
|
['D1', 'A question only the operator answers; it blocks the units it names'],
|
|
389
731
|
['D2', 'An assumption the agent made and works with; it comes back when its trigger fires'],
|
|
390
732
|
['unplayed', 'Closed by its checks without a playtest; it waits for one'],
|
|
@@ -396,12 +738,20 @@ const SECTIONS = {
|
|
|
396
738
|
phase: { next: 'phase-next' },
|
|
397
739
|
release: {},
|
|
398
740
|
wip: { help: 'Items awaiting a verdict / wip_built_limit' },
|
|
399
|
-
inbox: {
|
|
741
|
+
inbox: {
|
|
742
|
+
add: 'inbox-add',
|
|
743
|
+
drop: 'inbox-drop',
|
|
744
|
+
category: 'inbox-category',
|
|
745
|
+
later: 'inbox-later',
|
|
746
|
+
back: 'inbox-back',
|
|
747
|
+
// The vocabulary as data: the board draws its groups and choices from it, knows none.
|
|
748
|
+
...inboxVocabulary(),
|
|
749
|
+
},
|
|
400
750
|
questions: { answer: 'question-answer' },
|
|
401
751
|
lessons: {},
|
|
402
752
|
playtest: {
|
|
403
|
-
// The inbox
|
|
404
|
-
|
|
753
|
+
// The inbox category a note from the playtest screen goes with.
|
|
754
|
+
category: 'playtest',
|
|
405
755
|
waits: ['awaiting-verdict', 'unplayed'],
|
|
406
756
|
verdicts: ['verdict:keep', 'verdict:tune', 'verdict:kill'],
|
|
407
757
|
},
|
|
@@ -409,6 +759,20 @@ const SECTIONS = {
|
|
|
409
759
|
// `match`: the item's field Related holds against the graveyard's tags.
|
|
410
760
|
graveyard: { label: 'Graveyard', match: 'system' },
|
|
411
761
|
units: { label: 'Design units' },
|
|
762
|
+
// The game design screen (Board-PRD §5.24): the read's `design` block, its moves and starts.
|
|
763
|
+
design: {
|
|
764
|
+
label: 'Design',
|
|
765
|
+
steps: DESIGN_STEPS,
|
|
766
|
+
save: 'design-save',
|
|
767
|
+
save_text: 'design-save-text',
|
|
768
|
+
commit: 'design-commit',
|
|
769
|
+
import: 'design-import',
|
|
770
|
+
new_unit: 'design-new-unit',
|
|
771
|
+
discard: 'design-discard',
|
|
772
|
+
retire: 'pillar-retire',
|
|
773
|
+
drop: 'unit-drop',
|
|
774
|
+
answer: 'question-answer',
|
|
775
|
+
},
|
|
412
776
|
};
|
|
413
777
|
|
|
414
778
|
// The gcf commands that change the project: a project chat asks the operator before each one
|
|
@@ -424,6 +788,9 @@ const CHANGES = [
|
|
|
424
788
|
'design export',
|
|
425
789
|
'design import',
|
|
426
790
|
'design migrate',
|
|
791
|
+
'design save',
|
|
792
|
+
'design commit',
|
|
793
|
+
'design discard',
|
|
427
794
|
'take',
|
|
428
795
|
'done',
|
|
429
796
|
'drop',
|
|
@@ -438,7 +805,9 @@ const CHANGES = [
|
|
|
438
805
|
'block',
|
|
439
806
|
'unblock',
|
|
440
807
|
'inbox add',
|
|
441
|
-
'inbox
|
|
808
|
+
'inbox category',
|
|
809
|
+
'inbox later',
|
|
810
|
+
'inbox migrate',
|
|
442
811
|
'inbox drop',
|
|
443
812
|
'lessons add',
|
|
444
813
|
'config set',
|
|
@@ -496,6 +865,7 @@ export function domainOf(extensions = {}) {
|
|
|
496
865
|
new_item: 'item-new',
|
|
497
866
|
rank: 'prioritize',
|
|
498
867
|
chat: CHAT,
|
|
868
|
+
starts: STARTS,
|
|
499
869
|
// A session's mark nobody refreshed for this long stops making its item `running`.
|
|
500
870
|
session_ttl_min: SESSION_TTL_MS / 60_000,
|
|
501
871
|
};
|
package/lib/git.js
CHANGED
|
@@ -55,10 +55,15 @@ const BY = ['run', 'session', 'operator'];
|
|
|
55
55
|
|
|
56
56
|
/**
|
|
57
57
|
* Who makes a move: `GCF_MOVE_BY` when it names one (the harness sets `run` for both run modes),
|
|
58
|
-
* else a harness run's owner, else a Claude Code session, else the operator.
|
|
58
|
+
* else a harness run's owner, else a Claude Code session, else the operator. Inside a run or a
|
|
59
|
+
* session `GCF_MOVE_BY` cannot name the operator: an agent would claim the operator's moves.
|
|
60
|
+
* shortcut: an agent that unsets its own markers still passes for the operator; a trusted channel
|
|
61
|
+
* of who runs a command would close it.
|
|
59
62
|
*/
|
|
60
63
|
export function moveBy(env = process.env) {
|
|
61
|
-
|
|
64
|
+
const agent = Boolean(env.GCF_RUN_OWNER || env.CLAUDE_CODE_SESSION_ID);
|
|
65
|
+
const named = env.GCF_MOVE_BY ?? '';
|
|
66
|
+
if (BY.includes(named) && !(agent && named === 'operator')) return named;
|
|
62
67
|
if (env.GCF_RUN_OWNER) return 'run';
|
|
63
68
|
|
|
64
69
|
return env.CLAUDE_CODE_SESSION_ID ? 'session' : 'operator';
|
|
@@ -66,17 +71,19 @@ export function moveBy(env = process.env) {
|
|
|
66
71
|
|
|
67
72
|
/**
|
|
68
73
|
* The trailer paragraph of a move's commit as `git commit`/`git merge` arguments (`gcf item
|
|
69
|
-
* history` reads it): the items and units it touched, the domain's move key, who made it
|
|
70
|
-
*
|
|
71
|
-
*
|
|
74
|
+
* history` reads it): the items and units it touched, the domain's move key, who made it, and
|
|
75
|
+
* the board's proposal it carries out (its recovery finds the move by it). A separate `-m`, not
|
|
76
|
+
* `--trailer`: any git version takes it. None without a move key.
|
|
77
|
+
* @param {{key?: string, items?: string[], proposal?: string}} [move]
|
|
72
78
|
*/
|
|
73
|
-
export function moveTrailers({ key, items = [] } = {}) {
|
|
79
|
+
export function moveTrailers({ key, items = [], proposal } = {}) {
|
|
74
80
|
if (!key) return [];
|
|
75
81
|
const ids = [...new Set(items)];
|
|
76
82
|
const lines = [
|
|
77
83
|
...(ids.length ? [`GCF-Items: ${ids.join(', ')}`] : []),
|
|
78
84
|
`GCF-Move: ${key}`,
|
|
79
85
|
`GCF-By: ${moveBy()}`,
|
|
86
|
+
...(proposal ? [`GCF-Proposal: ${proposal}`] : []),
|
|
80
87
|
];
|
|
81
88
|
|
|
82
89
|
return ['-m', lines.join('\n')];
|
package/lib/history.js
CHANGED
|
@@ -22,6 +22,7 @@ export const OLD_SUBJECTS = [
|
|
|
22
22
|
[/^gcf\(decide\): ([a-z]+) (\S+)$/, (m) => ({ move: `decide:${m[1]}`, ids: [m[2]] })],
|
|
23
23
|
[/^gcf\(priority\): (\S+(?:, \S+)*)$/, (m) => ({ move: 'prioritize', ids: m[1].split(', ') })],
|
|
24
24
|
[/^gcf\(item\): (\S+) model \S+, effort \S+$/, (m) => ({ move: 'agent', ids: [m[1]] })],
|
|
25
|
+
[/^gcf\(item\): (\S+) runs in \S+$/, (m) => ({ move: 'mode', ids: [m[1]] })],
|
|
25
26
|
[/^gcf\(item\): (\S+)$/, (m) => ({ move: 'item-new', ids: [m[1]] })],
|
|
26
27
|
[/^gcf\(integrate\): (\S+)(?: plan)?$/, (m) => ({ move: 'integrate', ids: [m[1]] })],
|
|
27
28
|
// A submit or close may say why it went without a green verify or with tasks unticked.
|