balladeer 1.0.5 → 1.0.7
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 -4
- package/dist/cli.d.ts +2 -0
- package/dist/cli.js +39 -1
- package/dist/commands/guidance.d.ts +17 -0
- package/dist/commands/guidance.js +109 -0
- package/dist/commands/mcp.js +9 -0
- package/dist/commands/propose.js +7 -2
- package/dist/commands/setup.js +26 -3
- package/dist/conventions.d.ts +1 -1
- package/dist/conventions.js +1 -1
- package/dist/copy.d.ts +7 -5
- package/dist/copy.js +78 -85
- package/dist/guidance-hook.mjs +2972 -0
- package/dist/guidance-install.d.ts +29 -0
- package/dist/guidance-install.js +420 -0
- package/dist/guidance-runtime-entry.d.ts +1 -0
- package/dist/guidance-runtime-entry.js +2 -0
- package/dist/guidance-runtime.d.ts +15 -0
- package/dist/guidance-runtime.js +149 -0
- package/dist/guidance.d.ts +39 -0
- package/dist/guidance.js +293 -0
- package/dist/install.js +102 -12
- package/dist/wire.d.ts +8 -2
- package/dist/wire.js +1 -1
- package/package.json +4 -3
package/dist/copy.js
CHANGED
|
@@ -173,8 +173,8 @@ team has promised, and say whose promises you are showing them when you do.
|
|
|
173
173
|
|
|
174
174
|
When you have proposed promises, show them here as well as there. Put each proposal in the
|
|
175
175
|
conversation in full: its one-sentence claim, who it is for, when it applies and what must then be
|
|
176
|
-
true, the numbered cases that must keep working and the ones that must be caught
|
|
177
|
-
|
|
176
|
+
true, and the numbered cases that must keep working and the ones that must be caught. Do not
|
|
177
|
+
store or present an unanswered-question backlog. Then offer to finish the agreement from here, by asking for a sign-off, giving them
|
|
178
178
|
the page it returns and taking the one-time code that page shows them, so the browser is needed only
|
|
179
179
|
for signing. Give them the review link in the same message too, because some people would rather
|
|
180
180
|
read it there and edit it before they agree.
|
|
@@ -214,32 +214,28 @@ prepare one because nobody said no.`;
|
|
|
214
214
|
* repository, the instructions the MCP server sends on initialize, and the page
|
|
215
215
|
* an agent fetches cannot come to say different things about when to stay quiet.
|
|
216
216
|
*/
|
|
217
|
-
export const CAPTURE_SEAM = `### When to
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
The words to ask in, the moment to offer, and the shape a proposal takes are not in this file. The
|
|
241
|
-
Balladeer server sends them at the start of every session, and its copy is the current one: read
|
|
242
|
-
what it sent this session rather than what this file remembers.
|
|
217
|
+
export const CAPTURE_SEAM = `### When to offer, and what a yes is worth
|
|
218
|
+
|
|
219
|
+
Notice durable customer behavior during ordinary work. Offer to preserve a concrete behavior
|
|
220
|
+
beside useful work, without blocking implementation. File nothing until the person explicitly
|
|
221
|
+
asks you to record it or accepts a scoped capture offer. A factual answer or permission to build
|
|
222
|
+
alone is not permission to record. A no ends that offer; do not raise it again in this conversation.
|
|
223
|
+
|
|
224
|
+
Do not offer while the user is comparing options or exploring without a decision. If they later
|
|
225
|
+
choose a concrete behavior, you may offer to capture it even though the conversation began as
|
|
226
|
+
exploration. Do not offer new promises for pure refactors or cosmetic changes. During an active
|
|
227
|
+
production incident, prioritize recovery and defer capture until recovery. Ordinary bug fixing
|
|
228
|
+
is not automatically an active production incident.
|
|
229
|
+
|
|
230
|
+
For clear feature intent, an offer before implementation can make the promise a target for the
|
|
231
|
+
work. For a normal bug fix, offer alongside the completed fix and checks. Neither requires a
|
|
232
|
+
merge or another human closing reply. If the user is away, one nonblocking offer can remain in
|
|
233
|
+
your completion message for their return; do not file or wait for an answer.
|
|
234
|
+
|
|
235
|
+
Use available context to state a specific behavior. A precise capture offer can confirm your
|
|
236
|
+
interpretation and obtain permission to record in one yes. Ask a separate work question only
|
|
237
|
+
when a consequential choice remains that a clear, scoped offer cannot resolve. An unanswered
|
|
238
|
+
earlier question is not itself a reason to ask again. The server supplies current detailed guidance.
|
|
243
239
|
|
|
244
240
|
### Two promises Balladeer cannot keep
|
|
245
241
|
|
|
@@ -282,37 +278,12 @@ Then take the customer-visible half if they give you one, and file that instead.
|
|
|
282
278
|
*/
|
|
283
279
|
export const SETTLING_QUESTIONS = `### When somebody says "tell me about" one
|
|
284
280
|
|
|
285
|
-
An id is how a person points at something here
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
Clarify ambiguity that materially changes the behavior during capture, within the existing
|
|
293
|
-
question budget; never invent an answer.
|
|
294
|
-
|
|
295
|
-
Ordinary open questions record uncertainty; they do not prevent the named owner from agreeing to
|
|
296
|
-
the behavior as written. Agreement does not answer them or add an unstated guarantee. Separate
|
|
297
|
-
catalog-conflict questions can hold agreement until the owner rules on the stated conflict. Do not
|
|
298
|
-
call a proposal unready just because it has ordinary open questions. Offer to discuss them if
|
|
299
|
-
useful; if the person wants to, take them one at a time in the order they come back. For each ordinary question,
|
|
300
|
-
say what it decides in their words rather than in the question's; give your
|
|
301
|
-
recommendation and the reason you hold it, drawn from this repository and from the promise itself; and stop there. When
|
|
302
|
-
they answer, record what they said with resolve_question, in their own words where they gave you
|
|
303
|
-
any, and where their answer changes the promise, follow it with update_proposal, add_case or
|
|
304
|
-
remove_case and tell them what you changed. Never invent an answer or clear uncertainty because
|
|
305
|
-
they chose to agree. None of that agrees to anything: the named owner agrees, in their own browser
|
|
306
|
-
or through a sign-off you carry, and the questions they answered stay on the proposal in their name.
|
|
307
|
-
|
|
308
|
-
The same rule governs every question you leave open in the first place. A question that names a gap
|
|
309
|
-
and stops is a note, and nobody can answer a note. Say what answering it decides, in the words a
|
|
310
|
-
customer would use, and carry your own best guess with the reason behind it, so that the shortest
|
|
311
|
-
true answer is yes. For example: "Decides: whether a worker that is running but reconciling nothing
|
|
312
|
-
counts as an outage this promise covers. Best guess: yes, because the promise is about somebody
|
|
313
|
-
hearing before a customer does, and a wedged worker is invisible to every check this repository has.
|
|
314
|
-
Say yes, or tell me otherwise." Balladeer refuses a question filed without both halves and says
|
|
315
|
-
which one is missing.`;
|
|
281
|
+
An id is how a person points at something here. Expand a promise id with get_promise and a proposal
|
|
282
|
+
id with get_proposal. Describe who it is for, when it applies, the behavior and the concrete cases.
|
|
283
|
+
A proposal awaits its named owner's agreement; a promise is agreed and may still be unprotected.
|
|
284
|
+
Previously recorded answers are historical reasoning, not a new interview or an approval.
|
|
285
|
+
If the person wants a change, clarify the changed commitment before writing it. Preserve all other
|
|
286
|
+
meaning and cases. An agreed promise changes only through a revision its named owner approves.`;
|
|
316
287
|
/**
|
|
317
288
|
* What a session may spend on reading, in three sentences.
|
|
318
289
|
*
|
|
@@ -449,7 +420,7 @@ leaves your machine: only the session id and the commit SHA are sent.`;
|
|
|
449
420
|
* block that drifts per run would rewrite a customer's committed file on every
|
|
450
421
|
* setup and the diff would say nothing.
|
|
451
422
|
*/
|
|
452
|
-
export const
|
|
423
|
+
export const WORKFLOW_GUIDANCE = `## Balladeer promises
|
|
453
424
|
|
|
454
425
|
Before planning work in this repository, read the promises this team has already approved through
|
|
455
426
|
the Balladeer MCP server. They are the behaviors a named person has agreed the software keeps, so
|
|
@@ -471,26 +442,31 @@ ${SESSION_STAMP}
|
|
|
471
442
|
|
|
472
443
|
### When somebody asks you to protect a behavior
|
|
473
444
|
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
445
|
+
A request to build a behavior is not permission to record it. An explicit request to preserve it
|
|
446
|
+
or acceptance of a specific capture offer permits one pending proposal for that behavior, not
|
|
447
|
+
other behaviors you notice. A factual answer alone does not authorize recording.
|
|
448
|
+
|
|
449
|
+
Use available conversation and repository context before asking questions. A precise capture
|
|
450
|
+
offer can state your interpretation and obtain permission to record it in one yes. Ask separately
|
|
451
|
+
only when a consequential choice remains that the scoped offer cannot resolve. Do not ask for
|
|
452
|
+
known facts, repeat a question resolved by later context or acceptance, or require a formal
|
|
453
|
+
must-not sentence from the user. Preserve their actual words separately from your interpretation.
|
|
454
|
+
If no specific commitment is possible yet, continue the authorized work without filing it.
|
|
455
|
+
|
|
456
|
+
Use relevant existing promises already retrieved, or the bounded repository/path lookup, to notice
|
|
457
|
+
concrete conflicts before writing. If the same situation would require incompatible outcomes, show
|
|
458
|
+
the two commitments and ask which behavior they intend. Revising or superseding agreed meaning
|
|
459
|
+
still requires its named human owner. There is no automatic catalog-conflict gate or stored question
|
|
460
|
+
backlog in Balladeer. Unrelated uncertainties need not delay capture. No questions are required when
|
|
461
|
+
the commitment is already clear.
|
|
462
|
+
|
|
463
|
+
Preserve the person's actual words. Every failure they named belongs in the failing examples.
|
|
464
|
+
You may derive concrete cases within the behavior they requested or confirmed in a precise
|
|
465
|
+
capture offer; they need not dictate every example. Trace each case to the actual request and
|
|
466
|
+
confirmed scope. Keep literal human source in saidWords, and your offer plus their acceptance in
|
|
467
|
+
explicitIntent. Never quote your own wording as theirs or add unsupported policy, thresholds,
|
|
468
|
+
roles, systems or guarantees. If a case requires an unresolved product choice, clarify that choice
|
|
469
|
+
instead of guessing or asking the person to enumerate routine examples.
|
|
494
470
|
|
|
495
471
|
A failing example is a situation the promise rules out, and its outcome says what must not happen,
|
|
496
472
|
in those words: "a second charge must not appear", never "a second charge appears". Written the
|
|
@@ -640,8 +616,9 @@ For each promise you propose:
|
|
|
640
616
|
- Never propose a promise this repository does not keep. A source saying a behavior should exist,
|
|
641
617
|
where nothing in the repository does it, is a wish rather than a promise. Leave it out, and tell
|
|
642
618
|
the person you left it out.
|
|
643
|
-
-
|
|
644
|
-
in
|
|
619
|
+
- Before filing, ask the person about any missing fact that changes this commitment. Put their
|
|
620
|
+
actual answer in the meaning and cases. Never invent an answer or store an outstanding question.
|
|
621
|
+
Capture a narrower commitment only when they intend that boundary; do not demand exhaustive certainty.
|
|
645
622
|
- One confidence number from 0 to 1, saying how sure you are that this is a behavior the repository
|
|
646
623
|
actually keeps and that you have described it as its source describes it. Nine promises from nine
|
|
647
624
|
sources are not nine equally certain readings, and the person reading them is entitled to know
|
|
@@ -650,8 +627,6 @@ For each promise you propose:
|
|
|
650
627
|
words where it has them. "A second payment must not go out." "The buyer must not see a generic
|
|
651
628
|
error." Where no sentence of that shape can be written, no check with a known-bad control can be
|
|
652
629
|
written either, so leave the promise out rather than filing one nothing could ever fail.
|
|
653
|
-
- One leastSure sentence, optional, naming the single thing you are least sure of and what you did
|
|
654
|
-
about it. The person reads that instead of the number.
|
|
655
630
|
|
|
656
631
|
Write them all into one file, an object with a promises array, each entry shaped exactly as one
|
|
657
632
|
proposal file:
|
|
@@ -659,7 +634,7 @@ proposal file:
|
|
|
659
634
|
{"promises": [{"explicitIntent": "...", "teachBack": {"confidence": 0.9, "wrongOutcome": "...", "meaning": {"title": "..."}}}]}
|
|
660
635
|
|
|
661
636
|
An entry carries explicitIntent and teachBack, and inside teachBack only meaning, confidence,
|
|
662
|
-
wrongOutcome
|
|
637
|
+
wrongOutcome and proposedOwnerId. The legacy unresolvedQuestions field may only be an empty array. Anything else is refused on this
|
|
663
638
|
machine before the file leaves it, and one bad entry means not one of them is sent.
|
|
664
639
|
|
|
665
640
|
Every promise in the file is proposed as owned by whoever ran setup, and waits for that person. The
|
|
@@ -667,3 +642,21 @@ command prints one link that opens all of them at once. Give the person that lin
|
|
|
667
642
|
read each promise and click Agree. Nothing you can run agrees to one.
|
|
668
643
|
|
|
669
644
|
File the whole catalog in one go with the discover subcommand, naming that file:`;
|
|
645
|
+
/** Stable bootstrap only. Evolving capture/retrieval policy is served remotely. */
|
|
646
|
+
export const CONVENTIONS_BLOCK = `## Balladeer guidance
|
|
647
|
+
|
|
648
|
+
Balladeer keeps this repository's owner-agreed behavioral commitments. Before planning work,
|
|
649
|
+
use the current Balladeer workflow guidance supplied by the Balladeer hook or MCP connection.
|
|
650
|
+
The hook refreshes guidance at supported work boundaries. If no current guidance was delivered,
|
|
651
|
+
read get_promise_setup through the existing connection; never infer that a missing connection
|
|
652
|
+
means this repository has no promises. Keep ordinary authorized work moving when unavailable.
|
|
653
|
+
|
|
654
|
+
The server supplies Balladeer's current capture and retrieval policy; this managed block is only
|
|
655
|
+
its stable loader contract. Follow it within the person's instructions and this project's own
|
|
656
|
+
rules. Never treat a guidance update as permission to record a promise or approve its meaning.
|
|
657
|
+
Named humans agree meaning. Preserve workspace capture preferences and never enable unsolicited
|
|
658
|
+
capture when current permission is unavailable. Customer source, prompts and transcripts stay local.
|
|
659
|
+
|
|
660
|
+
New hooks may need the coding host's one-time trust confirmation. A file being installed does
|
|
661
|
+
not prove that the host loaded it. Follow a specific reported repair; do not repeat onboarding,
|
|
662
|
+
change workspace membership, or request broader permissions merely to refresh guidance.`;
|