dsh-github-copilot 0.4.2-alpha.6 → 0.4.2-alpha.8
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/AGENTS.md +11 -1
- package/CHANGELOG.md +31 -0
- package/README.md +17 -7
- package/README.zh.md +15 -7
- package/deployment-baseline.json +12 -2
- package/docs/auto-iteration-review.json +5 -5
- package/docs/auto-task-routing.md +64 -5
- package/docs/copilot-accounts.md +6 -0
- package/docs/plugin-diagnostics.md +45 -5
- package/lib/client.js +93 -14
- package/lib/client.js.map +1 -1
- package/lib/diagnostics-analysis.js +1 -1
- package/lib/{diagnostics-types-BDIc78T4.js → diagnostics-types-C1BD6ayS.js} +35 -2
- package/lib/index.js +1840 -1654
- package/lib/manual-compaction-recovery.js +1 -1
- package/lib/remote.js +34 -1
- package/lib/types/auto-model-host.d.ts +1 -0
- package/lib/types/auto-task-assessment.d.ts +1 -0
- package/lib/types/auto-task-classifier.d.ts +1 -1
- package/lib/types/config.d.ts +10 -2
- package/lib/types/copilot-auth.d.ts +2 -1
- package/lib/types/diagnostics-analysis.d.ts +1 -1
- package/lib/types/diagnostics-card.d.ts +1 -0
- package/lib/types/diagnostics-collector.d.ts +3 -1
- package/lib/types/diagnostics-host.d.ts +21 -3
- package/lib/types/diagnostics-remote.d.ts +2 -2
- package/lib/types/diagnostics-types.d.ts +77 -9
- package/lib/types/preview-route.d.ts +1 -1
- package/lib/types/request-diagnostics.d.ts +82 -0
- package/package.json +1 -1
package/lib/client.js
CHANGED
|
@@ -6653,6 +6653,32 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6653
6653
|
requestCount: integer$1
|
|
6654
6654
|
}).strict()
|
|
6655
6655
|
]);
|
|
6656
|
+
const CredentialChangeReasonSchema = _enum([
|
|
6657
|
+
"qualified",
|
|
6658
|
+
"unknown-source",
|
|
6659
|
+
"account-changed",
|
|
6660
|
+
"endpoint-changed",
|
|
6661
|
+
"entitlements-changed",
|
|
6662
|
+
"expired",
|
|
6663
|
+
"auth-mismatch",
|
|
6664
|
+
"duplicate-notification",
|
|
6665
|
+
"missing-notification",
|
|
6666
|
+
"commit-mismatch",
|
|
6667
|
+
"write-failed",
|
|
6668
|
+
"write-conflict"
|
|
6669
|
+
]);
|
|
6670
|
+
const CredentialChangeSchema = object({
|
|
6671
|
+
changeId: string().uuid(),
|
|
6672
|
+
observedAt: integer$1,
|
|
6673
|
+
version: string().max(64).regex(/^\d+\.\d+\.\d+(?:-[a-zA-Z0-9.-]+)?$/),
|
|
6674
|
+
phase: _enum(["notification", "commit"]),
|
|
6675
|
+
reason: CredentialChangeReasonSchema,
|
|
6676
|
+
preparing: integer$1,
|
|
6677
|
+
dispatched: integer$1,
|
|
6678
|
+
alreadyAborted: integer$1,
|
|
6679
|
+
preserved: integer$1,
|
|
6680
|
+
revoked: integer$1
|
|
6681
|
+
}).strict();
|
|
6656
6682
|
const RequestDiagnosticsSchema = object({
|
|
6657
6683
|
rows: array(object({
|
|
6658
6684
|
streamId: string().uuid(),
|
|
@@ -6698,7 +6724,14 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6698
6724
|
dropped: integer$1,
|
|
6699
6725
|
evicted: integer$1,
|
|
6700
6726
|
pending: integer$1.max(128).optional(),
|
|
6701
|
-
interruptedOnReopen: integer$1.optional()
|
|
6727
|
+
interruptedOnReopen: integer$1.optional(),
|
|
6728
|
+
credentialChanges: object({
|
|
6729
|
+
rows: array(CredentialChangeSchema).max(128),
|
|
6730
|
+
dropped: integer$1,
|
|
6731
|
+
evicted: integer$1,
|
|
6732
|
+
pending: integer$1.max(128).optional(),
|
|
6733
|
+
interruptedOnReopen: integer$1.optional()
|
|
6734
|
+
}).strict().optional()
|
|
6702
6735
|
}).strict();
|
|
6703
6736
|
//#endregion
|
|
6704
6737
|
//#region lib/types/diagnostics-types.js
|
|
@@ -7190,7 +7223,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7190
7223
|
};
|
|
7191
7224
|
//#endregion
|
|
7192
7225
|
//#region package.json
|
|
7193
|
-
var version = "0.4.2-alpha.
|
|
7226
|
+
var version = "0.4.2-alpha.8";
|
|
7194
7227
|
//#endregion
|
|
7195
7228
|
//#region lib/types/diagnostics-client.js
|
|
7196
7229
|
let owner;
|
|
@@ -7420,6 +7453,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7420
7453
|
}, [remote]);
|
|
7421
7454
|
const rows = view?.snapshot.rows ?? [];
|
|
7422
7455
|
const requests = view?.snapshot.requests;
|
|
7456
|
+
const credentials = requests?.credentialChanges;
|
|
7423
7457
|
const auto = view?.snapshot.autoAllocation;
|
|
7424
7458
|
const autoOpportunities = auto?.rows.reduce((sum, row) => sum + row.opportunities, 0) ?? 0;
|
|
7425
7459
|
const autoExpected = auto?.rows.reduce((sum, row) => sum + row.expectedSelections, 0) ?? 0;
|
|
@@ -7481,12 +7515,18 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7481
7515
|
return (0, react.createElement)("section", {
|
|
7482
7516
|
"aria-label": "Local diagnostics",
|
|
7483
7517
|
"data-copilot-native-ui": true,
|
|
7518
|
+
"data-copilot-diagnostics": true,
|
|
7484
7519
|
style: section
|
|
7485
|
-
}, (0, react.createElement)("style", null, nativeSettingsCss), (0, react.createElement)("h3", { style: nativeHeadingStyle }, "Local diagnostics"), (0, react.createElement)("
|
|
7486
|
-
|
|
7487
|
-
|
|
7488
|
-
|
|
7489
|
-
|
|
7520
|
+
}, (0, react.createElement)("style", null, nativeSettingsCss + "\n[data-copilot-diagnostics] details { min-width: 0; }"), (0, react.createElement)("h3", { style: nativeHeadingStyle }, "Local diagnostics"), (0, react.createElement)("p", { style: {
|
|
7521
|
+
...nativeCaptionStyle,
|
|
7522
|
+
margin: 0
|
|
7523
|
+
} }, "Expand a diagnostic group to inspect its evidence. Collection controls are independent; opening a group does not enable collection."), failed ? (0, react.createElement)("p", {
|
|
7524
|
+
role: "alert",
|
|
7525
|
+
style: { margin: 0 }
|
|
7526
|
+
}, "Could not confirm the operation. Read status before retrying; no write is automatically replayed.") : null, (0, react.createElement)("details", null, (0, react.createElement)("summary", null, "Auto allocation observations", (0, react.createElement)("span", { style: {
|
|
7527
|
+
...nativeCaptionStyle,
|
|
7528
|
+
marginInlineStart: 8
|
|
7529
|
+
} }, !view ? "Status unknown" : `${view.autoAllocationEnabled ? "Enabled" : "Paused"} · ${auto ? `${autoRows.length} retained strata` : "Evidence unavailable"}`)), (0, react.createElement)("p", {
|
|
7490
7530
|
role: "status",
|
|
7491
7531
|
style: { margin: 0 }
|
|
7492
7532
|
}, !view ? busy ? "Reading observation status…" : "Observation status is unknown." : `${view.autoAllocationEnabled ? view.state === "ready" ? "Enabled" : "Enabled · storage unavailable" : "Paused"} · ${auto === void 0 ? "Auto observations unavailable in this snapshot" : auto.status === "observed" ? "Data observed" : view.state === "ready" ? "No observations collected" : "Observation status unavailable"}` + (view.dirty ? " · Latest changes not fully persisted" : "")), auto ? (0, react.createElement)("p", { style: { margin: 0 } }, `${autoWindow} · ${auto.rows.length + auto.noFitRows.length} retained strata · ${auto.rowsTruncated ? "row limit reached" : "row limit not reached"}` + (auto.dropped ? ` · ${auto.dropped} dropped` : "") + (auto.expired ? ` · ${auto.expired} expired` : "") + (auto.restarts ? ` · ${auto.restarts} restarts observed` : "") + (auto.saturated ? ` · ${auto.saturated} counters saturated` : "")) : null, autoRows.length ? (0, react.createElement)("div", { style: {
|
|
@@ -7546,7 +7586,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7546
7586
|
} }, row.noFit ?? "—")))))) : null, auto?.status === "observed" && autoRows.length === 0 ? (0, react.createElement)("p", { style: { margin: 0 } }, "No retained strata in this snapshot; this does not mean there were no decisions.") : !auto ? (0, react.createElement)("p", { style: { margin: 0 } }, "Auto allocation aggregates are unavailable in this snapshot.") : view && auto.status !== "observed" && view.state !== "ready" ? (0, react.createElement)("p", { style: { margin: 0 } }, "Storage is not ready; retained Auto observation status is unknown.") : view && auto.status !== "observed" ? (0, react.createElement)("p", { style: { margin: 0 } }, "No retained observations yet.") : null, autoRows.length ? (0, react.createElement)("p", { style: {
|
|
7547
7587
|
...nativeCaptionStyle,
|
|
7548
7588
|
margin: 0
|
|
7549
|
-
} }, `${autoOpportunities} candidate opportunities · ${autoExpected.toFixed(3)} expected selections · ${autoSelections} actual selections · ${autoNoFit} no-fit decisions. Compare expected and selected counts only within matching cohorts; these are not execution, quality or billing evidence. Assessment outcomes explain classification only, not the supplier root cause. Legacy reasons are not recorded; sum Selected or No-fit, not candidate opportunities, when counting decisions by outcome.`) : null), view ? (0, react.createElement)("details", null, (0, react.createElement)("summary", null, "Physical request observations"
|
|
7589
|
+
} }, `${autoOpportunities} candidate opportunities · ${autoExpected.toFixed(3)} expected selections · ${autoSelections} actual selections · ${autoNoFit} no-fit decisions. Compare expected and selected counts only within matching cohorts; these are not execution, quality or billing evidence. Assessment outcomes explain classification only, not the supplier root cause. Legacy reasons are not recorded; sum Selected or No-fit, not candidate opportunities, when counting decisions by outcome.`) : null), view ? (0, react.createElement)("details", null, (0, react.createElement)("summary", null, "Physical request observations", (0, react.createElement)("span", { style: {
|
|
7590
|
+
...nativeCaptionStyle,
|
|
7591
|
+
marginInlineStart: 8
|
|
7592
|
+
} }, `${view.requestEnabled === void 0 ? "Status unknown" : view.requestEnabled ? "Enabled" : "Paused"} · ${requests?.rows.length ?? 0} retained`)), (0, react.createElement)("p", { style: { margin: 0 } }, requests ? `${requests.rows.length} retained requests · ${requests.pending ?? 0} sampled pending · ${requests.dropped} dropped · ${requests.evicted} expired/evicted · ${requests.interruptedOnReopen ?? 0} interrupted on reopen` : "No retained request observations. This does not establish zero failures or enabled collection."), (0, react.createElement)("p", { style: {
|
|
7550
7593
|
...nativeCaptionStyle,
|
|
7551
7594
|
margin: 0
|
|
7552
7595
|
} }, "Managed native adapter dispatches only. Local body-write completion is not supplier receipt. Stream-done is a native terminal observation, not tool execution or billing success. No Core retry count or Session/turn attribution is inferred."), requests?.rows.length ? (0, react.createElement)("div", { style: {
|
|
@@ -7585,7 +7628,46 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7585
7628
|
} }, row.model), (0, react.createElement)("td", { style: {
|
|
7586
7629
|
padding: 6,
|
|
7587
7630
|
overflowWrap: "anywhere"
|
|
7588
|
-
} }, `${row.outcome} / ${row.reason}`), (0, react.createElement)("td", { style: { padding: 6 } }, row.httpStatus ?? "—"), (0, react.createElement)("td", { style: { padding: 6 } }, `${row.composition.totalBytes ?? "unknown"} / ${row.wireBytes ?? "unknown"} (${row.encoding}; composition ${row.composition.state})`), (0, react.createElement)("td", { style: { padding: 6 } }, `${row.responseHeadersMs ?? "unknown"} / ${row.upload?.state === "observed" ? row.upload.bodyWriteCompleteMs ?? "unknown" : "unknown"}`)))))) : null) : null, view
|
|
7631
|
+
} }, `${row.outcome} / ${row.reason}`), (0, react.createElement)("td", { style: { padding: 6 } }, row.httpStatus ?? "—"), (0, react.createElement)("td", { style: { padding: 6 } }, `${row.composition.totalBytes ?? "unknown"} / ${row.wireBytes ?? "unknown"} (${row.encoding}; composition ${row.composition.state})`), (0, react.createElement)("td", { style: { padding: 6 } }, `${row.responseHeadersMs ?? "unknown"} / ${row.upload?.state === "observed" ? row.upload.bodyWriteCompleteMs ?? "unknown" : "unknown"}`)))))) : null) : null, view ? (0, react.createElement)("details", null, (0, react.createElement)("summary", null, "Credential change observations", (0, react.createElement)("span", { style: {
|
|
7632
|
+
...nativeCaptionStyle,
|
|
7633
|
+
marginInlineStart: 8
|
|
7634
|
+
} }, credentials ? `${credentials.rows.length} retained` : "Not recorded")), (0, react.createElement)("p", { style: {
|
|
7635
|
+
...nativeCaptionStyle,
|
|
7636
|
+
margin: 0
|
|
7637
|
+
} }, "Uses the independent request-observation consent. Fixed qualification and commit reasons only; no credentials, account or Session identifiers. Unknown source does not identify an external writer. Counts describe live managed wires at each observation, not native retries or successful completion."), credentials ? (0, react.createElement)("p", { style: { margin: 0 } }, `${credentials.dropped} dropped · ${credentials.evicted} expired/evicted · ${credentials.pending ?? 0} sampled pending · ${credentials.interruptedOnReopen ?? 0} interrupted on reopen. Matching random change IDs join notification and commit observations only; no historical incident is reconstructed.`) : (0, react.createElement)("p", { style: { margin: 0 } }, "Credential-change evidence was not recorded in this snapshot. This does not establish zero changes or failures."), credentials?.rows.length ? (0, react.createElement)("div", { style: {
|
|
7638
|
+
overflowX: "auto",
|
|
7639
|
+
minWidth: 0
|
|
7640
|
+
} }, (0, react.createElement)("table", { style: {
|
|
7641
|
+
width: "100%",
|
|
7642
|
+
borderCollapse: "collapse",
|
|
7643
|
+
textAlign: "left",
|
|
7644
|
+
font: "inherit"
|
|
7645
|
+
} }, (0, react.createElement)("caption", { style: {
|
|
7646
|
+
...nativeCaptionStyle,
|
|
7647
|
+
textAlign: "left",
|
|
7648
|
+
marginBottom: 8
|
|
7649
|
+
} }, "Latest retained credential-change decisions"), (0, react.createElement)("thead", null, (0, react.createElement)("tr", null, ...[
|
|
7650
|
+
"Time (UTC)",
|
|
7651
|
+
"Change ID",
|
|
7652
|
+
"Phase / reason",
|
|
7653
|
+
"Preparing / dispatched",
|
|
7654
|
+
"Preserved / revoked",
|
|
7655
|
+
"Already aborted"
|
|
7656
|
+
].map((label) => (0, react.createElement)("th", {
|
|
7657
|
+
key: label,
|
|
7658
|
+
scope: "col",
|
|
7659
|
+
style: {
|
|
7660
|
+
padding: 6,
|
|
7661
|
+
font: "inherit",
|
|
7662
|
+
fontWeight: 500
|
|
7663
|
+
}
|
|
7664
|
+
}, label)))), (0, react.createElement)("tbody", null, ...credentials.rows.slice().sort((left, right) => right.observedAt - left.observedAt).map((row, index) => (0, react.createElement)("tr", { key: `${row.changeId}/${row.phase}/${index}` }, (0, react.createElement)("td", { style: {
|
|
7665
|
+
padding: 6,
|
|
7666
|
+
whiteSpace: "nowrap"
|
|
7667
|
+
} }, new Date(row.observedAt).toISOString()), (0, react.createElement)("td", { style: {
|
|
7668
|
+
padding: 6,
|
|
7669
|
+
overflowWrap: "anywhere"
|
|
7670
|
+
} }, row.changeId), (0, react.createElement)("td", { style: { padding: 6 } }, `${row.phase} / ${row.reason}`), (0, react.createElement)("td", { style: { padding: 6 } }, `${row.preparing} / ${row.dispatched}`), (0, react.createElement)("td", { style: { padding: 6 } }, `${row.preserved} / ${row.revoked}`), (0, react.createElement)("td", { style: { padding: 6 } }, row.alreadyAborted)))))) : null) : null, view && populations.length ? (0, react.createElement)("details", null, (0, react.createElement)("summary", null, "Account and compaction observations"), (0, react.createElement)("div", { style: {
|
|
7589
7671
|
overflowX: "auto",
|
|
7590
7672
|
minWidth: 0
|
|
7591
7673
|
} }, (0, react.createElement)("table", { style: {
|
|
@@ -7638,13 +7720,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7638
7720
|
], population)))))))) : null, view && !populations.length ? (0, react.createElement)("details", null, (0, react.createElement)("summary", null, "Account and compaction observations"), (0, react.createElement)("p", null, "No retained operation observations. This is not evidence of zero failures.")) : null, (0, react.createElement)("details", null, (0, react.createElement)("summary", null, "Collection controls"), (0, react.createElement)("p", { style: { margin: 0 } }, view?.requestEnabled === void 0 ? "Request observations unavailable in this snapshot." : `Request observations ${view.requestEnabled ? "enabled" : "paused"}. ${requests?.rows.length ?? 0} retained physical requests; ${requests?.dropped ?? 0} dropped; ${requests?.evicted ?? 0} expired/evicted.`), (0, react.createElement)("p", { style: {
|
|
7639
7721
|
...nativeCaptionStyle,
|
|
7640
7722
|
margin: 0
|
|
7641
|
-
} }, "Separate opt-in: retain at most 128 content-free physical requests for 24 hours. Includes model, payload byte counts, transport timing, HTTP status and
|
|
7723
|
+
} }, "Separate opt-in: retain at most 128 content-free physical requests and 128 credential-change observations for 24 hours within the shared storage cap. Includes model, payload byte counts, transport timing, HTTP status, terminal categories and fixed credential qualification reasons, not bodies, credentials, URLs, headers or Session/turn IDs. Random stream IDs correlate native SDK dispatches only; dispatch index is not a Core retry count."), (0, react.createElement)("p", {
|
|
7642
7724
|
role: "status",
|
|
7643
7725
|
style: { margin: 0 }
|
|
7644
|
-
}, !remote ? "Diagnostics controls are unavailable in this connection." : !view ? busy ? "Reading local collection status…" : "Collection status is unknown." : `${view.enabled ? view.state === "ready" ? "Local collection enabled" : "Local collection configured on; storage not ready" : "Local collection paused"} · Storage ${view.state}` + (view.diagnostic === "none" ? "" : ` · ${view.diagnostic}`) + (view.dirty ? " · Not all observations are persisted yet" : "")),
|
|
7645
|
-
role: "alert",
|
|
7646
|
-
style: { margin: 0 }
|
|
7647
|
-
}, "Could not confirm the operation. Read status before retrying; no write is automatically replayed.") : null, clientDiagnosticsReportingFailed() ? (0, react.createElement)("p", {
|
|
7726
|
+
}, !remote ? "Diagnostics controls are unavailable in this connection." : !view ? busy ? "Reading local collection status…" : "Collection status is unknown." : `${view.enabled ? view.state === "ready" ? "Local collection enabled" : "Local collection configured on; storage not ready" : "Local collection paused"} · Storage ${view.state}` + (view.diagnostic === "none" ? "" : ` · ${view.diagnostic}`) + (view.dirty ? " · Not all observations are persisted yet" : "")), clientDiagnosticsReportingFailed() ? (0, react.createElement)("p", {
|
|
7648
7727
|
role: "alert",
|
|
7649
7728
|
style: { margin: 0 }
|
|
7650
7729
|
}, "Some Client observations could not be confirmed. Client counts are incomplete; Host counts are separate.") : null, (0, react.createElement)("div", { style: {
|