@descryy/mcp 0.9.1 → 0.11.0
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/dist/browser/auth.d.ts +76 -0
- package/dist/browser/auth.d.ts.map +1 -0
- package/dist/browser/auth.js +223 -0
- package/dist/browser/auth.js.map +1 -0
- package/dist/browser/capability-probe.d.ts +109 -0
- package/dist/browser/capability-probe.d.ts.map +1 -0
- package/dist/browser/capability-probe.js +201 -0
- package/dist/browser/capability-probe.js.map +1 -0
- package/dist/browser/driver.d.ts +342 -4
- package/dist/browser/driver.d.ts.map +1 -1
- package/dist/browser/driver.js +79 -1
- package/dist/browser/driver.js.map +1 -1
- package/dist/browser/evidence.d.ts +3 -0
- package/dist/browser/evidence.d.ts.map +1 -1
- package/dist/browser/evidence.js +6 -1
- package/dist/browser/evidence.js.map +1 -1
- package/dist/browser/fake-driver.d.ts +65 -8
- package/dist/browser/fake-driver.d.ts.map +1 -1
- package/dist/browser/fake-driver.js +235 -8
- package/dist/browser/fake-driver.js.map +1 -1
- package/dist/browser/fault-attribution.d.ts +178 -0
- package/dist/browser/fault-attribution.d.ts.map +1 -0
- package/dist/browser/fault-attribution.js +266 -0
- package/dist/browser/fault-attribution.js.map +1 -0
- package/dist/browser/identity-graph-write.d.ts +55 -0
- package/dist/browser/identity-graph-write.d.ts.map +1 -0
- package/dist/browser/identity-graph-write.js +45 -0
- package/dist/browser/identity-graph-write.js.map +1 -0
- package/dist/browser/page-probe.d.ts +81 -0
- package/dist/browser/page-probe.d.ts.map +1 -0
- package/dist/browser/page-probe.js +202 -0
- package/dist/browser/page-probe.js.map +1 -0
- package/dist/browser/playwright-driver.d.ts +79 -0
- package/dist/browser/playwright-driver.d.ts.map +1 -1
- package/dist/browser/playwright-driver.js +1138 -180
- package/dist/browser/playwright-driver.js.map +1 -1
- package/dist/browser/reach-recording-session.d.ts +44 -0
- package/dist/browser/reach-recording-session.d.ts.map +1 -0
- package/dist/browser/reach-recording-session.js +143 -0
- package/dist/browser/reach-recording-session.js.map +1 -0
- package/dist/browser/reachability.d.ts +168 -0
- package/dist/browser/reachability.d.ts.map +1 -0
- package/dist/browser/reachability.js +294 -0
- package/dist/browser/reachability.js.map +1 -0
- package/dist/browser/registry.d.ts +24 -0
- package/dist/browser/registry.d.ts.map +1 -1
- package/dist/browser/registry.js +21 -2
- package/dist/browser/registry.js.map +1 -1
- package/dist/browser/scenario-provenance.d.ts +1 -1
- package/dist/browser/scenario-provenance.d.ts.map +1 -1
- package/dist/browser/scenario-provenance.js +15 -1
- package/dist/browser/scenario-provenance.js.map +1 -1
- package/dist/browser/scenario-runner.d.ts +10 -2
- package/dist/browser/scenario-runner.d.ts.map +1 -1
- package/dist/browser/scenario-runner.js +77 -9
- package/dist/browser/scenario-runner.js.map +1 -1
- package/dist/browser/tool-support.d.ts +5 -1
- package/dist/browser/tool-support.d.ts.map +1 -1
- package/dist/browser/tool-support.js +80 -4
- package/dist/browser/tool-support.js.map +1 -1
- package/dist/browser/wait-target.d.ts +37 -0
- package/dist/browser/wait-target.d.ts.map +1 -0
- package/dist/browser/wait-target.js +54 -0
- package/dist/browser/wait-target.js.map +1 -0
- package/dist/heap.d.ts +61 -0
- package/dist/heap.d.ts.map +1 -0
- package/dist/heap.js +82 -0
- package/dist/heap.js.map +1 -0
- package/dist/heartbeat.d.ts +46 -0
- package/dist/heartbeat.d.ts.map +1 -0
- package/dist/heartbeat.js +66 -0
- package/dist/heartbeat.js.map +1 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/planner/predict-then-propose.d.ts +101 -0
- package/dist/planner/predict-then-propose.d.ts.map +1 -0
- package/dist/planner/predict-then-propose.js +88 -0
- package/dist/planner/predict-then-propose.js.map +1 -0
- package/dist/planner/propose-journey.d.ts +60 -0
- package/dist/planner/propose-journey.d.ts.map +1 -0
- package/dist/planner/propose-journey.js +96 -0
- package/dist/planner/propose-journey.js.map +1 -0
- package/dist/registry.d.ts +10 -1
- package/dist/registry.d.ts.map +1 -1
- package/dist/registry.js +5 -1
- package/dist/registry.js.map +1 -1
- package/dist/render.d.ts +4 -4
- package/dist/render.js +3 -3
- package/dist/scenarios/browser-run-plan-projection.d.ts +143 -0
- package/dist/scenarios/browser-run-plan-projection.d.ts.map +1 -0
- package/dist/scenarios/browser-run-plan-projection.js +228 -0
- package/dist/scenarios/browser-run-plan-projection.js.map +1 -0
- package/dist/scenarios/credential-ref.d.ts +102 -0
- package/dist/scenarios/credential-ref.d.ts.map +1 -0
- package/dist/scenarios/credential-ref.js +148 -0
- package/dist/scenarios/credential-ref.js.map +1 -0
- package/dist/scenarios/index.d.ts +4 -1
- package/dist/scenarios/index.d.ts.map +1 -1
- package/dist/scenarios/index.js +4 -1
- package/dist/scenarios/index.js.map +1 -1
- package/dist/scenarios/parse.d.ts.map +1 -1
- package/dist/scenarios/parse.js +42 -9
- package/dist/scenarios/parse.js.map +1 -1
- package/dist/scenarios/scenario.d.ts +39 -5
- package/dist/scenarios/scenario.d.ts.map +1 -1
- package/dist/scenarios/scenario.js +15 -2
- package/dist/scenarios/scenario.js.map +1 -1
- package/dist/scenarios/secret-ref.d.ts +86 -0
- package/dist/scenarios/secret-ref.d.ts.map +1 -0
- package/dist/scenarios/secret-ref.js +125 -0
- package/dist/scenarios/secret-ref.js.map +1 -0
- package/dist/server.d.ts +1 -1
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +8 -4
- package/dist/server.js.map +1 -1
- package/dist/session.d.ts +19 -0
- package/dist/session.d.ts.map +1 -1
- package/dist/session.js +36 -0
- package/dist/session.js.map +1 -1
- package/dist/tools/analyze-workspace.d.ts +52 -0
- package/dist/tools/analyze-workspace.d.ts.map +1 -0
- package/dist/tools/analyze-workspace.js +207 -0
- package/dist/tools/analyze-workspace.js.map +1 -0
- package/dist/tools/analyze.d.ts +50 -4
- package/dist/tools/analyze.d.ts.map +1 -1
- package/dist/tools/analyze.js +225 -5
- package/dist/tools/analyze.js.map +1 -1
- package/dist/tools/browser-close-session.d.ts +21 -1
- package/dist/tools/browser-close-session.d.ts.map +1 -1
- package/dist/tools/browser-close-session.js +71 -7
- package/dist/tools/browser-close-session.js.map +1 -1
- package/dist/tools/browser-navigate.d.ts +1 -1
- package/dist/tools/browser-navigate.d.ts.map +1 -1
- package/dist/tools/browser-navigate.js +5 -3
- package/dist/tools/browser-navigate.js.map +1 -1
- package/dist/tools/browser-run-scenario.d.ts.map +1 -1
- package/dist/tools/browser-run-scenario.js +6 -1
- package/dist/tools/browser-run-scenario.js.map +1 -1
- package/dist/tools/browser-save-scenario.d.ts.map +1 -1
- package/dist/tools/browser-save-scenario.js +84 -4
- package/dist/tools/browser-save-scenario.js.map +1 -1
- package/dist/tools/browser-select.d.ts +20 -0
- package/dist/tools/browser-select.d.ts.map +1 -0
- package/dist/tools/browser-select.js +120 -0
- package/dist/tools/browser-select.js.map +1 -0
- package/dist/tools/browser-snapshot.d.ts +17 -1
- package/dist/tools/browser-snapshot.d.ts.map +1 -1
- package/dist/tools/browser-snapshot.js +18 -5
- package/dist/tools/browser-snapshot.js.map +1 -1
- package/dist/tools/browser-start-session.d.ts.map +1 -1
- package/dist/tools/browser-start-session.js +161 -9
- package/dist/tools/browser-start-session.js.map +1 -1
- package/dist/tools/browser-submit.d.ts +18 -0
- package/dist/tools/browser-submit.d.ts.map +1 -0
- package/dist/tools/browser-submit.js +106 -0
- package/dist/tools/browser-submit.js.map +1 -0
- package/dist/tools/browser-wait-for.d.ts +41 -0
- package/dist/tools/browser-wait-for.d.ts.map +1 -0
- package/dist/tools/browser-wait-for.js +148 -0
- package/dist/tools/browser-wait-for.js.map +1 -0
- package/dist/tools/chain.d.ts +41 -0
- package/dist/tools/chain.d.ts.map +1 -0
- package/dist/tools/chain.js +105 -0
- package/dist/tools/chain.js.map +1 -0
- package/dist/tools/draw-conclusion.d.ts +44 -0
- package/dist/tools/draw-conclusion.d.ts.map +1 -0
- package/dist/tools/draw-conclusion.js +250 -0
- package/dist/tools/draw-conclusion.js.map +1 -0
- package/dist/tools/index.d.ts +7 -0
- package/dist/tools/index.d.ts.map +1 -1
- package/dist/tools/index.js +16 -0
- package/dist/tools/index.js.map +1 -1
- package/dist/tools/kit.d.ts +17 -0
- package/dist/tools/kit.d.ts.map +1 -1
- package/dist/tools/kit.js.map +1 -1
- package/dist/tools/observe-runtime.d.ts +17 -0
- package/dist/tools/observe-runtime.d.ts.map +1 -1
- package/dist/tools/observe-runtime.js +174 -10
- package/dist/tools/observe-runtime.js.map +1 -1
- package/dist/tools/predict-reach.d.ts +57 -0
- package/dist/tools/predict-reach.d.ts.map +1 -0
- package/dist/tools/predict-reach.js +159 -0
- package/dist/tools/predict-reach.js.map +1 -0
- package/dist/tools/propagation.d.ts +8 -3
- package/dist/tools/propagation.d.ts.map +1 -1
- package/dist/tools/propagation.js +16 -9
- package/dist/tools/propagation.js.map +1 -1
- package/dist/tools/propose-journey.d.ts +16 -0
- package/dist/tools/propose-journey.d.ts.map +1 -0
- package/dist/tools/propose-journey.js +121 -0
- package/dist/tools/propose-journey.js.map +1 -0
- package/dist/tools/runtime-journey-drive.d.ts +102 -0
- package/dist/tools/runtime-journey-drive.d.ts.map +1 -0
- package/dist/tools/runtime-journey-drive.js +247 -0
- package/dist/tools/runtime-journey-drive.js.map +1 -0
- package/dist/tools/scope.d.ts +3 -0
- package/dist/tools/scope.d.ts.map +1 -1
- package/dist/tools/scope.js +33 -6
- package/dist/tools/scope.js.map +1 -1
- package/dist/workspace-index.d.ts +164 -0
- package/dist/workspace-index.d.ts.map +1 -0
- package/dist/workspace-index.js +381 -0
- package/dist/workspace-index.js.map +1 -0
- package/package.json +32 -31
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
/** `browser_submit` submits the form an element sits in, through that form's own submit
|
|
2
|
+
* control — so the page sees the submission a person would produce, validation included.
|
|
3
|
+
* Consent is granted once, at `browser_start_session` (DEC-380): `class: "action"`,
|
|
4
|
+
* `describeAction` undefined, a verb cannot mint its own consent. Nothing is guessed: an
|
|
5
|
+
* element in no form, or in a form with no submit control, is refused by name. */
|
|
6
|
+
import { browserAnswer, emptyEvidence, mutationRefusal, observeAndCorrelate, useSession } from "../browser/tool-support.js";
|
|
7
|
+
import { NO_GRAPH_WRITE } from "../browser/graph-write.js";
|
|
8
|
+
import { NotSubmittableError, UnknownElementRefError } from "../browser/driver.js";
|
|
9
|
+
import { CANCELLED_STATE, cancellationHeadline, cancellationNotes } from "../cancellation.js";
|
|
10
|
+
import { requiredString } from "./kit.js";
|
|
11
|
+
const SCHEMA = {
|
|
12
|
+
type: "object",
|
|
13
|
+
properties: {
|
|
14
|
+
sessionId: { type: "string", description: "REQUIRED. The id returned by browser_start_session." },
|
|
15
|
+
ref: {
|
|
16
|
+
type: "string",
|
|
17
|
+
description: "REQUIRED. An element ref from a browser_snapshot reply, for any element inside the form to submit — " +
|
|
18
|
+
"a field or the submit button will both do. Refs are issued per snapshot and are invalidated by " +
|
|
19
|
+
"navigation, so take a fresh snapshot after the page changes.",
|
|
20
|
+
},
|
|
21
|
+
confirmToken: {
|
|
22
|
+
type: "string",
|
|
23
|
+
description: "Not normally needed. Consent is granted once, for the whole session, by browser_start_session, " +
|
|
24
|
+
"so this call performs its action directly. The field is declared because the handshake reads it " +
|
|
25
|
+
"for every action-class tool.",
|
|
26
|
+
},
|
|
27
|
+
},
|
|
28
|
+
required: ["sessionId", "ref"],
|
|
29
|
+
additionalProperties: false,
|
|
30
|
+
};
|
|
31
|
+
async function run(args, ctx) {
|
|
32
|
+
const sessionId = requiredString(args, "sessionId");
|
|
33
|
+
const ref = requiredString(args, "ref");
|
|
34
|
+
if (ctx.signal.aborted) {
|
|
35
|
+
return browserAnswer({
|
|
36
|
+
ctx,
|
|
37
|
+
state: CANCELLED_STATE,
|
|
38
|
+
headline: cancellationHeadline("nothing was submitted"),
|
|
39
|
+
notes: cancellationNotes("The form was left as it was.", "The browser session is still open and can still be used."),
|
|
40
|
+
data: { sessionId, ref, url: "", evidence: emptyEvidence(), graph: NO_GRAPH_WRITE },
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
const found = await useSession(ctx.session.browserSessions(), sessionId);
|
|
44
|
+
if (!found.ok) {
|
|
45
|
+
return browserAnswer({
|
|
46
|
+
ctx,
|
|
47
|
+
state: found.dead.state,
|
|
48
|
+
headline: found.dead.headline,
|
|
49
|
+
notes: found.dead.notes,
|
|
50
|
+
data: { sessionId, ref, url: "", evidence: found.dead.evidence, graph: NO_GRAPH_WRITE },
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
const { entry } = found;
|
|
54
|
+
const refused = mutationRefusal(entry);
|
|
55
|
+
if (refused !== null) {
|
|
56
|
+
return browserAnswer({
|
|
57
|
+
ctx,
|
|
58
|
+
state: "refused",
|
|
59
|
+
headline: `${entry.profile?.name ?? "This environment"} is read-only.`,
|
|
60
|
+
notes: [refused],
|
|
61
|
+
data: { sessionId, ref, url: entry.page.currentUrl(), evidence: emptyEvidence(), graph: NO_GRAPH_WRITE },
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
try {
|
|
65
|
+
ctx.progress("Submitting");
|
|
66
|
+
await entry.page.submit(ref);
|
|
67
|
+
}
|
|
68
|
+
catch (error) {
|
|
69
|
+
if (error instanceof UnknownElementRefError || error instanceof NotSubmittableError) {
|
|
70
|
+
return browserAnswer({
|
|
71
|
+
ctx,
|
|
72
|
+
state: "refused",
|
|
73
|
+
headline: error instanceof UnknownElementRefError
|
|
74
|
+
? `"${ref}" is not an element in this session's current snapshot.`
|
|
75
|
+
: `"${ref}" has nothing browser_submit can submit.`,
|
|
76
|
+
notes: [error.message],
|
|
77
|
+
data: { sessionId, ref, url: entry.page.currentUrl(), evidence: emptyEvidence(), graph: NO_GRAPH_WRITE },
|
|
78
|
+
});
|
|
79
|
+
}
|
|
80
|
+
throw error;
|
|
81
|
+
}
|
|
82
|
+
const observed = await observeAndCorrelate(ctx, entry);
|
|
83
|
+
return browserAnswer({
|
|
84
|
+
ctx,
|
|
85
|
+
headline: `Submitting on ${entry.page.currentUrl()}.`,
|
|
86
|
+
notes: observed.notes,
|
|
87
|
+
data: { sessionId, ref, url: entry.page.currentUrl(), evidence: observed.evidence, graph: observed.graph },
|
|
88
|
+
});
|
|
89
|
+
}
|
|
90
|
+
export const browserSubmitTool = {
|
|
91
|
+
name: "browser_submit",
|
|
92
|
+
title: "submit the form an element sits in",
|
|
93
|
+
description: "Submit the form containing an element in an open browser session, named by a ref from a " +
|
|
94
|
+
"browser_snapshot reply. It goes through the form's own submit control, so the page's submit handler " +
|
|
95
|
+
"runs and the form's validation is not bypassed — a form the application would reject is rejected here " +
|
|
96
|
+
"too. An element in no form, or in a form with no submit control, is refused rather than guessed at: " +
|
|
97
|
+
"in the second case something else on the page submits it, and clicking that is the honest route. " +
|
|
98
|
+
"Refused when the session's environment profile declares safetyLevel \"readOnly\".",
|
|
99
|
+
class: "action",
|
|
100
|
+
tier: "evidence",
|
|
101
|
+
version: "1.0.0",
|
|
102
|
+
inputSchema: SCHEMA,
|
|
103
|
+
run,
|
|
104
|
+
describeAction: () => undefined,
|
|
105
|
+
};
|
|
106
|
+
//# sourceMappingURL=browser-submit.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"browser-submit.js","sourceRoot":"","sources":["../../src/tools/browser-submit.ts"],"names":[],"mappings":"AAAA;;;;mFAImF;AAGnF,OAAO,EAAE,aAAa,EAAE,aAAa,EAAE,eAAe,EAAE,mBAAmB,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAC5H,OAAO,EAAE,cAAc,EAA0B,MAAM,2BAA2B,CAAC;AACnF,OAAO,EAAE,mBAAmB,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AACnF,OAAO,EAAE,eAAe,EAAE,oBAAoB,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAC9F,OAAO,EAAE,cAAc,EAAyC,MAAM,UA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,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC;gBACtB,IAAI,EAAE,EAAE,SAAS,EAAE,GAAG,EAAE,GAAG,EAAE,KAAK,CAAC,IAAI,CAAC,UAAU,EAAE,EAAE,QAAQ,EAAE,aAAa,EAAE,EAAE,KAAK,EAAE,cAAc,EAAE;aACzG,CAAC,CAAC;QACL,CAAC;QACD,MAAM,KAAK,CAAC;IACd,CAAC;IAED,MAAM,QAAQ,GAAG,MAAM,mBAAmB,CAAC,GAAG,EAAE,KAAK,CAAC,CAAC;IAEvD,OAAO,aAAa,CAAoB;QACtC,GAAG;QACH,QAAQ,EAAE,iBAAiB,KAAK,CAAC,IAAI,CAAC,UAAU,EAAE,GAAG;QACrD,KAAK,EAAE,QAAQ,CAAC,KAAK;QACrB,IAAI,EAAE,EAAE,SAAS,EAAE,GAAG,EAAE,GAAG,EAAE,KAAK,CAAC,IAAI,CAAC,UAAU,EAAE,EAAE,QAAQ,EAAE,QAAQ,CAAC,QAAQ,EAAE,KAAK,EAAE,QAAQ,CAAC,KAAK,EAAE;KAC3G,CAAC,CAAC;AACL,CAAC;AAED,MAAM,CAAC,MAAM,iBAAiB,GAAmB;IAC/C,IAAI,EAAE,gBAAgB;IACtB,KAAK,EAAE,oCAAoC;IAC3C,WAAW,EACT,0FAA0F;QAC1F,sGAAsG;QACtG,wGAAwG;QACxG,sGAAsG;QACtG,mGAAmG;QACnG,mFAAmF;IACrF,KAAK,EAAE,QAAQ;IACf,IAAI,EAAE,UAAU;IAChB,OAAO,EAAE,OAAO;IAChB,WAAW,EAAE,MAAM;IACnB,GAAG;IACH,cAAc,EAAE,GAAG,EAAE,CAAC,SAAS;CAChC,CAAC"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `browser_wait_for`: wait until a named element is on the page, or say it never arrived.
|
|
3
|
+
*
|
|
4
|
+
* Every other verb waits for the page to settle *after* it acted. This is the one that waits
|
|
5
|
+
* before acting, and it exists because the alternative an agent reaches for otherwise is
|
|
6
|
+
* snapshotting in a loop, or acting immediately and reporting whatever half-rendered page it
|
|
7
|
+
* happened to catch.
|
|
8
|
+
*
|
|
9
|
+
* It is `stateful-read`, not `action`: it changes nothing about the application. What it does
|
|
10
|
+
* change is what a later call in the same session sees — it takes a fresh snapshot, and that
|
|
11
|
+
* invalidates every ref issued before it. That is the same reason `browser_snapshot` is
|
|
12
|
+
* stateful-read rather than a pure read, so a `readOnly` profile permits this exactly as it
|
|
13
|
+
* permits navigate and snapshot.
|
|
14
|
+
*
|
|
15
|
+
* A timeout is an outcome, never a failure: the reply carries `appeared: false` *and* the
|
|
16
|
+
* page as it stood, because "it did not appear" alone leaves the caller with nothing to do
|
|
17
|
+
* next but guess again.
|
|
18
|
+
*/
|
|
19
|
+
import type { BrowserEvidenceReport } from "../browser/evidence.ts";
|
|
20
|
+
import { type BrowserGraphWrite } from "../browser/graph-write.ts";
|
|
21
|
+
import type { SnapshotElement } from "../browser/driver.ts";
|
|
22
|
+
import { type ToolDefinition } from "./kit.ts";
|
|
23
|
+
export interface BrowserWaitForData {
|
|
24
|
+
readonly sessionId: string;
|
|
25
|
+
readonly appeared: boolean;
|
|
26
|
+
/** How long was actually spent waiting, in ms. Short on an element already there. */
|
|
27
|
+
readonly waitedMs: number;
|
|
28
|
+
/** The ceiling that applied, after clamping. A caller asking for more than the maximum sees the maximum here rather than what it asked for. */
|
|
29
|
+
readonly timeoutMs: number;
|
|
30
|
+
readonly matched: SnapshotElement | null;
|
|
31
|
+
/** How many elements satisfied the target. More than one is not an error — the question was whether it is there — but `matched` is then one of several. */
|
|
32
|
+
readonly matchCount: number;
|
|
33
|
+
readonly url: string;
|
|
34
|
+
/** The page when the wait ended, on both outcomes. Every ref from before this call is now stale. */
|
|
35
|
+
readonly elements: readonly SnapshotElement[];
|
|
36
|
+
readonly totalElements: number;
|
|
37
|
+
readonly evidence: BrowserEvidenceReport;
|
|
38
|
+
readonly graph: BrowserGraphWrite;
|
|
39
|
+
}
|
|
40
|
+
export declare const browserWaitForTool: ToolDefinition;
|
|
41
|
+
//# sourceMappingURL=browser-wait-for.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"browser-wait-for.d.ts","sourceRoot":"","sources":["../../src/tools/browser-wait-for.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,wBAAwB,CAAC;AAEpE,OAAO,EAAkB,KAAK,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AACnF,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAE5D,OAAO,EAAqE,KAAK,cAAc,EAAE,MAAM,UAAU,CAAC;AAGlH,MAAM,WAAW,kBAAkB;IACjC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,qFAAqF;IACrF,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,+IAA+I;IAC/I,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,OAAO,EAAE,eAAe,GAAG,IAAI,CAAC;IACzC,2JAA2J;IAC3J,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,oGAAoG;IACpG,QAAQ,CAAC,QAAQ,EAAE,SAAS,eAAe,EAAE,CAAC;IAC9C,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;IAC/B,QAAQ,CAAC,QAAQ,EAAE,qBAAqB,CAAC;IACzC,QAAQ,CAAC,KAAK,EAAE,iBAAiB,CAAC;CACnC;AAiID,eAAO,MAAM,kBAAkB,EAAE,cAehC,CAAC"}
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `browser_wait_for`: wait until a named element is on the page, or say it never arrived.
|
|
3
|
+
*
|
|
4
|
+
* Every other verb waits for the page to settle *after* it acted. This is the one that waits
|
|
5
|
+
* before acting, and it exists because the alternative an agent reaches for otherwise is
|
|
6
|
+
* snapshotting in a loop, or acting immediately and reporting whatever half-rendered page it
|
|
7
|
+
* happened to catch.
|
|
8
|
+
*
|
|
9
|
+
* It is `stateful-read`, not `action`: it changes nothing about the application. What it does
|
|
10
|
+
* change is what a later call in the same session sees — it takes a fresh snapshot, and that
|
|
11
|
+
* invalidates every ref issued before it. That is the same reason `browser_snapshot` is
|
|
12
|
+
* stateful-read rather than a pure read, so a `readOnly` profile permits this exactly as it
|
|
13
|
+
* permits navigate and snapshot.
|
|
14
|
+
*
|
|
15
|
+
* A timeout is an outcome, never a failure: the reply carries `appeared: false` *and* the
|
|
16
|
+
* page as it stood, because "it did not appear" alone leaves the caller with nothing to do
|
|
17
|
+
* next but guess again.
|
|
18
|
+
*/
|
|
19
|
+
import { browserAnswer, observeAndCorrelate, useSession } from "../browser/tool-support.js";
|
|
20
|
+
import { NO_GRAPH_WRITE } from "../browser/graph-write.js";
|
|
21
|
+
import { describeWaitTarget, isEmptyWaitTarget, WAIT_TIMEOUT_MAX_MS } from "../browser/wait-target.js";
|
|
22
|
+
import { optionalInteger, optionalString, requiredString } from "./kit.js";
|
|
23
|
+
const SCHEMA = {
|
|
24
|
+
type: "object",
|
|
25
|
+
properties: {
|
|
26
|
+
sessionId: { type: "string", description: "REQUIRED. The id returned by browser_start_session." },
|
|
27
|
+
role: {
|
|
28
|
+
type: "string",
|
|
29
|
+
description: "The role to wait for, as browser_snapshot reports one — button, link, textbox, combobox, and so on. " +
|
|
30
|
+
"Give this, name, or both; at least one is required.",
|
|
31
|
+
},
|
|
32
|
+
name: {
|
|
33
|
+
type: "string",
|
|
34
|
+
description: "The element's name to wait for, as browser_snapshot reports it. Matched exactly, ignoring case and " +
|
|
35
|
+
"surrounding space — never as a substring, because a loose match would report that the thing you " +
|
|
36
|
+
"meant appeared when something merely similar did.",
|
|
37
|
+
},
|
|
38
|
+
timeoutMs: {
|
|
39
|
+
type: "integer",
|
|
40
|
+
minimum: 0,
|
|
41
|
+
description: `How long to wait at most, in ms. Defaults to 5000 and is capped at ${WAIT_TIMEOUT_MAX_MS}; the reply ` +
|
|
42
|
+
"says which ceiling actually applied. Running out is a normal answer, not an error — the reply then " +
|
|
43
|
+
"carries appeared: false together with the page as it stood, so you can see what is there instead.",
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
required: ["sessionId"],
|
|
47
|
+
additionalProperties: false,
|
|
48
|
+
};
|
|
49
|
+
async function run(args, ctx) {
|
|
50
|
+
const sessionId = requiredString(args, "sessionId");
|
|
51
|
+
const role = optionalString(args, "role");
|
|
52
|
+
const name = optionalString(args, "name");
|
|
53
|
+
const timeoutMs = optionalInteger(args, "timeoutMs", 0);
|
|
54
|
+
const target = { ...(role === undefined ? {} : { role }), ...(name === undefined ? {} : { name }) };
|
|
55
|
+
const empty = () => ({
|
|
56
|
+
sessionId,
|
|
57
|
+
appeared: false,
|
|
58
|
+
waitedMs: 0,
|
|
59
|
+
timeoutMs: 0,
|
|
60
|
+
matched: null,
|
|
61
|
+
matchCount: 0,
|
|
62
|
+
url: "",
|
|
63
|
+
elements: [],
|
|
64
|
+
totalElements: 0,
|
|
65
|
+
evidence: { consoleErrors: [], failedRequests: [], pendingRequests: [], totalRequests: 0, actions: [], unsettled: [], evidenceWarnings: [] },
|
|
66
|
+
graph: NO_GRAPH_WRITE,
|
|
67
|
+
});
|
|
68
|
+
// Refused before the session is touched: a target naming nothing would match the first
|
|
69
|
+
// element on the page, and a caller that got "it appeared" from that learned nothing true.
|
|
70
|
+
if (isEmptyWaitTarget(target)) {
|
|
71
|
+
return browserAnswer({
|
|
72
|
+
ctx,
|
|
73
|
+
state: "refused",
|
|
74
|
+
headline: "browser_wait_for needs something to wait for.",
|
|
75
|
+
notes: [
|
|
76
|
+
`Give role, name, or both — ${describeWaitTarget(target)} was supplied. Waiting for nothing in ` +
|
|
77
|
+
"particular would match whatever element happens to be first on the page, and report that as the " +
|
|
78
|
+
"thing you were waiting for.",
|
|
79
|
+
],
|
|
80
|
+
data: empty(),
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
const found = await useSession(ctx.session.browserSessions(), sessionId);
|
|
84
|
+
if (!found.ok) {
|
|
85
|
+
return browserAnswer({
|
|
86
|
+
ctx,
|
|
87
|
+
state: found.dead.state,
|
|
88
|
+
headline: found.dead.headline,
|
|
89
|
+
notes: found.dead.notes,
|
|
90
|
+
data: { ...empty(), evidence: found.dead.evidence },
|
|
91
|
+
});
|
|
92
|
+
}
|
|
93
|
+
const { entry } = found;
|
|
94
|
+
// No mutationRefusal here, deliberately: waiting changes nothing about the application, so
|
|
95
|
+
// a readOnly profile permits it exactly as it permits navigate and snapshot.
|
|
96
|
+
ctx.progress(`Waiting for ${describeWaitTarget(target)}`);
|
|
97
|
+
const outcome = await entry.page.waitFor(target, timeoutMs === undefined ? {} : { timeoutMs });
|
|
98
|
+
const observed = await observeAndCorrelate(ctx, entry);
|
|
99
|
+
const notes = [...observed.notes];
|
|
100
|
+
if (outcome.appeared) {
|
|
101
|
+
notes.push("This reply's snapshot is fresh, so any ref you were holding before this call is now stale — act on a " +
|
|
102
|
+
"ref from here.");
|
|
103
|
+
if (outcome.matchCount > 1) {
|
|
104
|
+
notes.push(`${outcome.matchCount} elements match ${describeWaitTarget(target)}; matched is the first of them. If ` +
|
|
105
|
+
"that is not the one you meant, narrow the target with the other field.");
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
else {
|
|
109
|
+
notes.push(`Nothing matching ${describeWaitTarget(target)} appeared within ${outcome.timeoutMs}ms. That is what the ` +
|
|
110
|
+
"page did, not a failure of the wait — the elements below are what it is showing instead.");
|
|
111
|
+
}
|
|
112
|
+
return browserAnswer({
|
|
113
|
+
ctx,
|
|
114
|
+
headline: outcome.appeared
|
|
115
|
+
? `${describeWaitTarget(target)} is on ${outcome.snapshot.url}, after ${outcome.waitedMs}ms.`
|
|
116
|
+
: `${describeWaitTarget(target)} did not appear on ${outcome.snapshot.url} within ${outcome.timeoutMs}ms.`,
|
|
117
|
+
notes,
|
|
118
|
+
data: {
|
|
119
|
+
sessionId: entry.sessionId,
|
|
120
|
+
appeared: outcome.appeared,
|
|
121
|
+
waitedMs: outcome.waitedMs,
|
|
122
|
+
timeoutMs: outcome.timeoutMs,
|
|
123
|
+
matched: outcome.matched,
|
|
124
|
+
matchCount: outcome.matchCount,
|
|
125
|
+
url: outcome.snapshot.url,
|
|
126
|
+
elements: outcome.snapshot.elements,
|
|
127
|
+
totalElements: outcome.snapshot.totalElements,
|
|
128
|
+
evidence: observed.evidence,
|
|
129
|
+
graph: observed.graph,
|
|
130
|
+
},
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
export const browserWaitForTool = {
|
|
134
|
+
name: "browser_wait_for",
|
|
135
|
+
title: "wait for an element to appear",
|
|
136
|
+
description: "Wait until an element with a given role and/or name is on the page in an open browser session, or " +
|
|
137
|
+
"until a ceiling you set. Use it instead of snapshotting in a loop, and instead of acting immediately " +
|
|
138
|
+
"on a page that is still rendering. It changes nothing about the application, so a readOnly environment " +
|
|
139
|
+
"permits it — but it does take a fresh snapshot, which invalidates every ref issued before the call. " +
|
|
140
|
+
"Running out of time is a normal answer: the reply then says the element did not appear and hands back " +
|
|
141
|
+
"the page as it stood, so you can see what is there instead of guessing again.",
|
|
142
|
+
class: "stateful-read",
|
|
143
|
+
tier: "evidence",
|
|
144
|
+
version: "1.0.0",
|
|
145
|
+
inputSchema: SCHEMA,
|
|
146
|
+
run,
|
|
147
|
+
};
|
|
148
|
+
//# sourceMappingURL=browser-wait-for.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"browser-wait-for.js","sourceRoot":"","sources":["../../src/tools/browser-wait-for.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAGH,OAAO,EAAE,aAAa,EAAE,mBAAmB,EAAE,UAAU,EAAE,M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AAU,OAAO,CAAC,QAAQ,CAAC,GAAG,WAAW,OAAO,CAAC,QAAQ,KAAK;YAC7F,CAAC,CAAC,GAAG,kBAAkB,CAAC,MAAM,CAAC,sBAAsB,OAAO,CAAC,QAAQ,CAAC,GAAG,WAAW,OAAO,CAAC,SAAS,KAAK;QAC5G,KAAK;QACL,IAAI,EAAE;YACJ,SAAS,EAAE,KAAK,CAAC,SAAS;YAC1B,QAAQ,EAAE,OAAO,CAAC,QAAQ;YAC1B,QAAQ,EAAE,OAAO,CAAC,QAAQ;YAC1B,SAAS,EAAE,OAAO,CAAC,SAAS;YAC5B,OAAO,EAAE,OAAO,CAAC,OAAO;YACxB,UAAU,EAAE,OAAO,CAAC,UAAU;YAC9B,GAAG,EAAE,OAAO,CAAC,QAAQ,CAAC,GAAG;YACzB,QAAQ,EAAE,OAAO,CAAC,QAAQ,CAAC,QAAQ;YACnC,aAAa,EAAE,OAAO,CAAC,QAAQ,CAAC,aAAa;YAC7C,QAAQ,EAAE,QAAQ,CAAC,QAAQ;YAC3B,KAAK,EAAE,QAAQ,CAAC,KAAK;SACtB;KACF,CAAC,CAAC;AACL,CAAC;AAED,MAAM,CAAC,MAAM,kBAAkB,GAAmB;IAChD,IAAI,EAAE,kBAAkB;IACxB,KAAK,EAAE,+BAA+B;IACtC,WAAW,EACT,oGAAoG;QACpG,uGAAuG;QACvG,yGAAyG;QACzG,sGAAsG;QACtG,wGAAwG;QACxG,+EAA+E;IACjF,KAAK,EAAE,eAAe;IACtB,IAAI,EAAE,UAAU;IAChB,OAAO,EAAE,OAAO;IAChB,WAAW,EAAE,MAAM;IACnB,GAAG;CACJ,CAAC"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `chain` — RG-9's five-hop user chain (click → request → endpoint → route →
|
|
3
|
+
* handler → line) as one MCP call. `impact`/`propagation` each answer one
|
|
4
|
+
* hop's worth of question; nothing before this walked all five in one call
|
|
5
|
+
* with a computed completeness verdict, so "chain complete" was a mockup
|
|
6
|
+
* string rather than a field.
|
|
7
|
+
*
|
|
8
|
+
* Two disclosed degradations carried through from `traceUserChain`
|
|
9
|
+
* (`@descryy/core`): the browser→endpoint hop only exists when the browser
|
|
10
|
+
* session that produced it was started with a `stackParser`
|
|
11
|
+
* (`browser_start_session`); and the route→handler hop ships for
|
|
12
|
+
* express/koa-router/fastify/hono/the Next.js App Router today, TypeScript
|
|
13
|
+
* only. Neither is a language check here — this tool walks whatever edges
|
|
14
|
+
* the graph holds and reports what it finds.
|
|
15
|
+
*/
|
|
16
|
+
import { type ChainStageName } from "@descryy/core";
|
|
17
|
+
import { type BriefNode, type NodeCandidates, type ToolDefinition } from "./kit.ts";
|
|
18
|
+
/** One named point in the chain, as reported to a caller. */
|
|
19
|
+
export interface ChainStageReport {
|
|
20
|
+
readonly name: ChainStageName;
|
|
21
|
+
readonly present: boolean;
|
|
22
|
+
/** Omitted, not null, wherever the stage carries no node of its own
|
|
23
|
+
* ("request" — no node type for an HTTP request; "line" — a location on
|
|
24
|
+
* the handler, not a separate node) or is missing. */
|
|
25
|
+
readonly node?: BriefNode;
|
|
26
|
+
/** Set iff `!present`. */
|
|
27
|
+
readonly reason?: string;
|
|
28
|
+
}
|
|
29
|
+
export interface ChainReport {
|
|
30
|
+
readonly origin: BriefNode;
|
|
31
|
+
readonly stages: readonly ChainStageReport[];
|
|
32
|
+
readonly verdict: "complete" | "partial";
|
|
33
|
+
readonly missingStage: ChainStageName | null;
|
|
34
|
+
readonly location: {
|
|
35
|
+
readonly file: string;
|
|
36
|
+
readonly startLine: number;
|
|
37
|
+
} | null;
|
|
38
|
+
}
|
|
39
|
+
export type ChainData = ChainReport | NodeCandidates;
|
|
40
|
+
export declare const chainTool: ToolDefinition;
|
|
41
|
+
//# sourceMappingURL=chain.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"chain.d.ts","sourceRoot":"","sources":["../../src/tools/chain.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAmC,KAAK,cAAc,EAAE,MAAM,eAAe,CAAC;AAErF,OAAO,EAIL,KAAK,SAAS,EACd,KAAK,cAAc,EAEnB,KAAK,cAAc,EACpB,MAAM,UAAU,CAAC;AAIlB,6DAA6D;AAC7D,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,IAAI,EAAE,cAAc,CAAC;IAC9B,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC;IAC1B;;2DAEuD;IACvD,QAAQ,CAAC,IAAI,CAAC,EAAE,SAAS,CAAC;IAC1B,0BAA0B;IAC1B,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,WAAW;IAC1B,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;IAC3B,QAAQ,CAAC,MAAM,EAAE,SAAS,gBAAgB,EAAE,CAAC;IAC7C,QAAQ,CAAC,OAAO,EAAE,UAAU,GAAG,SAAS,CAAC;IACzC,QAAQ,CAAC,YAAY,EAAE,cAAc,GAAG,IAAI,CAAC;IAC7C,QAAQ,CAAC,QAAQ,EAAE;QAAE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;CACjF;AAED,MAAM,MAAM,SAAS,GAAG,WAAW,GAAG,cAAc,CAAC;AAmFrD,eAAO,MAAM,SAAS,EAAE,cAevB,CAAC"}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `chain` — RG-9's five-hop user chain (click → request → endpoint → route →
|
|
3
|
+
* handler → line) as one MCP call. `impact`/`propagation` each answer one
|
|
4
|
+
* hop's worth of question; nothing before this walked all five in one call
|
|
5
|
+
* with a computed completeness verdict, so "chain complete" was a mockup
|
|
6
|
+
* string rather than a field.
|
|
7
|
+
*
|
|
8
|
+
* Two disclosed degradations carried through from `traceUserChain`
|
|
9
|
+
* (`@descryy/core`): the browser→endpoint hop only exists when the browser
|
|
10
|
+
* session that produced it was started with a `stackParser`
|
|
11
|
+
* (`browser_start_session`); and the route→handler hop ships for
|
|
12
|
+
* express/koa-router/fastify/hono/the Next.js App Router today, TypeScript
|
|
13
|
+
* only. Neither is a language check here — this tool walks whatever edges
|
|
14
|
+
* the graph holds and reports what it finds.
|
|
15
|
+
*/
|
|
16
|
+
import { traceUserChain } from "@descryy/core";
|
|
17
|
+
import { briefNode, optionalString, ToolInputError, } from "./kit.js";
|
|
18
|
+
import { resolveOneNode } from "./lookup.js";
|
|
19
|
+
function reportStage(stage) {
|
|
20
|
+
return {
|
|
21
|
+
name: stage.name,
|
|
22
|
+
present: stage.present,
|
|
23
|
+
...(stage.node === null ? {} : { node: briefNode(stage.node) }),
|
|
24
|
+
...(stage.reason === null ? {} : { reason: stage.reason }),
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
const SCHEMA = {
|
|
28
|
+
type: "object",
|
|
29
|
+
properties: {
|
|
30
|
+
nodeId: { type: "string", description: "Graph node id to start the chain from — the click's origin." },
|
|
31
|
+
symbol: {
|
|
32
|
+
type: "string",
|
|
33
|
+
description: "Symbol name to start from (a COMPONENT, PAGE or FUNCTION), when you do not have a node id. " +
|
|
34
|
+
"Ambiguity is reported rather than guessed at — narrow it with \"file\".",
|
|
35
|
+
},
|
|
36
|
+
file: {
|
|
37
|
+
type: "string",
|
|
38
|
+
description: "Repository-relative path, to disambiguate \"symbol\" or to start from a file.",
|
|
39
|
+
},
|
|
40
|
+
},
|
|
41
|
+
additionalProperties: false,
|
|
42
|
+
};
|
|
43
|
+
async function run(args, ctx) {
|
|
44
|
+
const nodeId = optionalString(args, "nodeId");
|
|
45
|
+
const symbol = optionalString(args, "symbol");
|
|
46
|
+
const file = optionalString(args, "file");
|
|
47
|
+
if (nodeId === undefined && symbol === undefined && file === undefined) {
|
|
48
|
+
throw new ToolInputError('give one of "nodeId", "symbol" or "file"');
|
|
49
|
+
}
|
|
50
|
+
const provider = ctx.session.provider();
|
|
51
|
+
const found = resolveOneNode(ctx.session, { nodeId, symbol, file });
|
|
52
|
+
if (found.node === null) {
|
|
53
|
+
const base = provider.baseStamp();
|
|
54
|
+
return {
|
|
55
|
+
result: {
|
|
56
|
+
data: { candidates: found.candidates.map(briefNode) },
|
|
57
|
+
stamp: { ...base, resolutionFloor: 0 },
|
|
58
|
+
truncated: false,
|
|
59
|
+
notes: found.notes,
|
|
60
|
+
},
|
|
61
|
+
nameLevel: true,
|
|
62
|
+
state: "refused",
|
|
63
|
+
headline: found.headline,
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
ctx.progress(`Walking the chain from ${found.node.name}`);
|
|
67
|
+
const chain = traceUserChain(provider, found.node.id);
|
|
68
|
+
const notes = [...found.notes, ...chain.notes];
|
|
69
|
+
return {
|
|
70
|
+
result: {
|
|
71
|
+
data: {
|
|
72
|
+
origin: briefNode(chain.data.origin),
|
|
73
|
+
stages: chain.data.stages.map(reportStage),
|
|
74
|
+
verdict: chain.data.verdict,
|
|
75
|
+
missingStage: chain.data.missingStage,
|
|
76
|
+
location: chain.data.location,
|
|
77
|
+
},
|
|
78
|
+
stamp: chain.stamp,
|
|
79
|
+
truncated: chain.truncated,
|
|
80
|
+
notes,
|
|
81
|
+
},
|
|
82
|
+
nameLevel: true,
|
|
83
|
+
...(chain.data.verdict === "partial" ? { state: "refused" } : {}),
|
|
84
|
+
headline: chain.data.verdict === "complete"
|
|
85
|
+
? `Chain complete: ${found.node.name} reaches ${chain.data.location?.file ?? "its handler"}` +
|
|
86
|
+
`${chain.data.location === null ? "" : `:${chain.data.location.startLine}`}.`
|
|
87
|
+
: `Chain incomplete at "${chain.data.missingStage}" — see stages for what is missing and why.`,
|
|
88
|
+
};
|
|
89
|
+
}
|
|
90
|
+
export const chainTool = {
|
|
91
|
+
name: "chain",
|
|
92
|
+
class: "read",
|
|
93
|
+
tier: "evidence",
|
|
94
|
+
version: "1.0.0",
|
|
95
|
+
title: "The click-to-line chain: click, request, endpoint, route, handler, line",
|
|
96
|
+
description: "Given a COMPONENT, PAGE or FUNCTION, walks click → request → endpoint → route → handler → " +
|
|
97
|
+
"line as one traversal and reports a computed completeness verdict: \"complete\", or " +
|
|
98
|
+
"\"partial\" naming which hop is missing and why. Never assumes complete. Two disclosed " +
|
|
99
|
+
"degradations: the browser→endpoint hop needs a stackParser on browser_start_session to exist " +
|
|
100
|
+
"at all, and route→handler is produced only by a narrow set of adapters and frameworks today " +
|
|
101
|
+
"— outside that reach this tool still runs, it will just name \"handler\" as missing.",
|
|
102
|
+
inputSchema: SCHEMA,
|
|
103
|
+
run,
|
|
104
|
+
};
|
|
105
|
+
//# sourceMappingURL=chain.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"chain.js","sourceRoot":"","sources":["../../src/tools/chain.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,cAAc,EAAwC,MAAM,eAAe,CAAC;AAErF,OAAO,EACL,SAAS,EACT,cAAc,EACd,cAAc,GAKf,MAAM,UAAU,CAAC;AAElB,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAwB7C,SAAS,WAAW,CAAC,KAAiB;IACpC,OAAO;QACL,IAAI,EAAE,KAAK,CAAC,IAAI;QAChB,OAAO,EAAE,KAAK,CAAC,OAAO;QACtB,GAAG,CAAC,KAAK,CAAC,IAAI,KAAK,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,IAAI,EAAE,SAAS,CAAC,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC;QAC/D,GAAG,CAAC,KAAK,CAAC,MAAM,KAAK,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,MAAM,EAAE,CAAC;KAC3D,CAAC;AACJ,CAAC;AAED,MAAM,MAAM,GAAG;IACb,IAAI,EAAE,QAAQ;IACd,UAA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,KAAK,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,SAAS,EAAE,GAAG;YAC/E,CAAC,CAAC,wBAAwB,KAAK,CAAC,IAAI,CAAC,YAAY,6CAA6C;KACnG,CAAC;AACJ,CAAC;AAED,MAAM,CAAC,MAAM,SAAS,GAAmB;IACvC,IAAI,EAAE,OAAO;IACb,KAAK,EAAE,MAAM;IACb,IAAI,EAAE,UAAU;IAChB,OAAO,EAAE,OAAO;IAChB,KAAK,EAAE,yEAAyE;IAChF,WAAW,EACT,4FAA4F;QAC5F,sFAAsF;QACtF,yFAAyF;QACzF,+FAA+F;QAC/F,8FAA8F;QAC9F,sFAAsF;IACxF,WAAW,EAAE,MAA4C;IACzD,GAAG;CACJ,CAAC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `draw_conclusion` — RG-8(a): routes evidence and a graph path through the real finding
|
|
3
|
+
* funnel (`@descryy/ir`'s G3/G4 gate, `packages/ir/src/finding.ts`) and returns a governed
|
|
4
|
+
* category, in the same five-category vocabulary (`ReportCategory`) the desktop's pipeline
|
|
5
|
+
* uses — not a raw evidence tally the caller has to interpret itself.
|
|
6
|
+
*
|
|
7
|
+
* This closes the open half of the `FINDING_CAPS` ruling: until this tool existed, nothing on
|
|
8
|
+
* the MCP surface ever called `reportCategory` — `observe_runtime` writes R4 facts and reports
|
|
9
|
+
* evidence counts, but never gates them into a category. An MCP client reading `observe_runtime`'s
|
|
10
|
+
* reply was, at most, "reading the evidence back" — this tool is what makes "the finding" an
|
|
11
|
+
* honest word for what MCP returns.
|
|
12
|
+
*
|
|
13
|
+
* **What this tool does not do.** It does not draw its own graph path or gather its own runtime
|
|
14
|
+
* evidence — those come from the caller, who already holds them from `impact`/`propagation` (a
|
|
15
|
+
* `GraphPathHop[]`) and `observe_runtime`/the browser tools (runtime observations). This tool is
|
|
16
|
+
* the gate alone: the same `reportCategory` arithmetic the architecture specifies, called once,
|
|
17
|
+
* from one place, so a category MCP returns and a category the desktop's pipeline computes are
|
|
18
|
+
* never two independently-typed re-implementations agreeing by coincidence.
|
|
19
|
+
*
|
|
20
|
+
* `class: "read"` — same as this server's other three conclusion tools (`validate`, `contracts`,
|
|
21
|
+
* `cross_pr`): it changes nothing and mints no token. A category computed from evidence the
|
|
22
|
+
* caller already supplied is a read over that evidence, not a new write against the target.
|
|
23
|
+
*/
|
|
24
|
+
import { type ResolutionLevel } from "@descryy/ir";
|
|
25
|
+
import { type ToolDefinition } from "./kit.ts";
|
|
26
|
+
export interface DrawConclusionData {
|
|
27
|
+
readonly failurePoint: string;
|
|
28
|
+
/** §19's five-category vocabulary — the same `ReportCategory` the desktop's report surface renders. */
|
|
29
|
+
readonly category: string;
|
|
30
|
+
/** The class (A/B/C) that capped it — rule 3, `reliabilityCap`. */
|
|
31
|
+
readonly reliabilityClass: string;
|
|
32
|
+
/** Step 2 alone, uncapped by the structural path — how strongly the evidence says the failure is real. */
|
|
33
|
+
readonly existence: string;
|
|
34
|
+
readonly resolution: ResolutionLevel;
|
|
35
|
+
readonly independentSignalTypes: number;
|
|
36
|
+
readonly directMechanismEvidence: boolean;
|
|
37
|
+
readonly hasRuntimeEvidence: boolean;
|
|
38
|
+
readonly humanAsserted: boolean;
|
|
39
|
+
/** Echoed back only when the caller supplied one — see the schema's own doc for why this is
|
|
40
|
+
* inert unless a future call also names `requireReproductionForConfirmed`. */
|
|
41
|
+
readonly reproductionCount: number | null;
|
|
42
|
+
}
|
|
43
|
+
export declare const drawConclusionTool: ToolDefinition;
|
|
44
|
+
//# sourceMappingURL=draw-conclusion.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"draw-conclusion.d.ts","sourceRoot":"","sources":["../../src/tools/draw-conclusion.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,EAWL,KAAK,eAAe,EAGrB,MAAM,aAAa,CAAC;AAErB,OAAO,EAA8F,KAAK,cAAc,EAAE,MAAM,UAAU,CAAC;AAG3I,MAAM,WAAW,kBAAkB;IACjC,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,uGAAuG;IACvG,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,mEAAmE;IACnE,QAAQ,CAAC,gBAAgB,EAAE,MAAM,CAAC;IAClC,0GAA0G;IAC1G,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,UAAU,EAAE,eAAe,CAAC;IACrC,QAAQ,CAAC,sBAAsB,EAAE,MAAM,CAAC;IACxC,QAAQ,CAAC,uBAAuB,EAAE,OAAO,CAAC;IAC1C,QAAQ,CAAC,kBAAkB,EAAE,OAAO,CAAC;IACrC,QAAQ,CAAC,aAAa,EAAE,OAAO,CAAC;IAChC;mFAC+E;IAC/E,QAAQ,CAAC,iBAAiB,EAAE,MAAM,GAAG,IAAI,CAAC;CAC3C;AAwND,eAAO,MAAM,kBAAkB,EAAE,cAgBhC,CAAC"}
|