dsh-github-copilot 0.4.1 → 0.4.2-alpha.11
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 +42 -6
- package/CHANGELOG.md +126 -0
- package/README.md +75 -25
- package/README.zh.md +55 -20
- package/deployment-baseline.json +30 -3
- package/docs/auto-high-cost.md +51 -20
- package/docs/auto-iteration-review.json +13 -13
- package/docs/auto-task-routing.md +118 -19
- package/docs/automatic-model-routing.md +2 -1
- package/docs/copilot-accounts.md +6 -0
- package/docs/copilot-compaction.md +1 -1
- package/docs/plugin-diagnostics.md +159 -6
- package/lib/client.js +814 -59
- package/lib/client.js.map +1 -1
- package/lib/diagnostics-analysis.js +4 -2
- package/lib/diagnostics-types-qvtuvM5E.js +661 -0
- package/lib/index.js +8775 -7934
- package/lib/manual-compaction-recovery.js +1 -1
- package/lib/remote.js +278 -6
- package/lib/routed-web.js +1 -1
- package/lib/types/auto-allocation-diagnostics.d.ts +126 -0
- package/lib/types/auto-allocation-evidence.d.ts +5 -1
- package/lib/types/auto-allocation.d.ts +7 -2
- package/lib/types/auto-assessment-evidence.d.ts +65 -0
- package/lib/types/auto-model-host.d.ts +1 -0
- package/lib/types/auto-model-routing.d.ts +1 -1
- package/lib/types/auto-task-assessment.d.ts +4 -2
- package/lib/types/auto-task-classifier.d.ts +2 -1
- package/lib/types/compaction-continuation.d.ts +1 -1
- package/lib/types/config.d.ts +18 -2
- package/lib/types/context-evidence.d.ts +4 -4
- package/lib/types/copilot-auth.d.ts +2 -1
- package/lib/types/copilot-usage-remote.d.ts +1 -1
- package/lib/types/diagnostics-analysis.d.ts +3 -2
- package/lib/types/diagnostics-card.d.ts +1 -0
- package/lib/types/diagnostics-collector.d.ts +14 -0
- package/lib/types/diagnostics-host.d.ts +114 -3
- package/lib/types/diagnostics-remote.d.ts +11 -9
- package/lib/types/diagnostics-types.d.ts +486 -30
- package/lib/types/native-settings-style.d.ts +1 -1
- package/lib/types/preview-provider.d.ts +8 -2
- package/lib/types/preview-route.d.ts +1 -1
- package/lib/types/remote.d.ts +1 -1
- package/lib/types/request-body-composition.d.ts +17 -0
- package/lib/types/request-body-evidence.d.ts +2 -1
- package/lib/types/request-diagnostics.d.ts +278 -0
- package/lib/types/session-continuation-types.d.ts +2 -2
- package/lib/types/turn-selection-host.d.ts +2 -1
- package/lib/types/turn-selection.d.ts +39 -2
- package/package.json +2 -2
- package/lib/diagnostics-types-FVf6zjob.js +0 -182
package/deployment-baseline.json
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
},
|
|
9
9
|
"package": {
|
|
10
10
|
"name": "dsh-github-copilot",
|
|
11
|
-
"version": "0.4.
|
|
11
|
+
"version": "0.4.2-alpha.11"
|
|
12
12
|
},
|
|
13
13
|
"evidence": {
|
|
14
14
|
"kind": "source-and-synthetic-test-inventory",
|
|
@@ -296,6 +296,14 @@
|
|
|
296
296
|
"sourceMarkers": [
|
|
297
297
|
{"file": "src/diagnostics-types.ts", "marker": "DIAGNOSTICS_MAX_BYTES = 2 * 1024 * 1024"},
|
|
298
298
|
{"file": "src/diagnostics-collector.ts", "marker": "noteClientGaps"},
|
|
299
|
+
{"file": "src/auto-allocation-diagnostics.ts", "marker": "assessmentOutcome: assessmentOutcome.optional()"},
|
|
300
|
+
{"file": "src/request-diagnostics.ts", "marker": "REQUEST_DIAGNOSTICS_MAX_ROWS = 128"},
|
|
301
|
+
{"file": "src/request-diagnostics.ts", "marker": "CredentialChangeSchema"},
|
|
302
|
+
{"file": "src/diagnostics-collector.ts", "marker": "beginCredentialChange"},
|
|
303
|
+
{"file": "src/request-body-composition.ts", "marker": "bytes: 32 * 1024 * 1024"},
|
|
304
|
+
{"file": "src/request-body-composition.ts", "marker": "concurrent: 4"},
|
|
305
|
+
{"file": "src/request-diagnostics.ts", "marker": "REQUEST_DIAGNOSTICS_RETENTION_MS = 24 * 60 * 60 * 1000"},
|
|
306
|
+
{"file": "src/config.ts", "marker": "requestDiagnosticsEnabled: z.boolean().default(false).hidden().volatile()"},
|
|
299
307
|
{"file": "src/diagnostics-host.ts", "marker": "diagnosticsDomainForProfile"},
|
|
300
308
|
{"file": "src/diagnostics-client.ts", "marker": "createClientDiagnosticsScope"},
|
|
301
309
|
{"file": "src/remote.ts", "marker": "...diagnosticsRemote.descriptors"},
|
|
@@ -304,6 +312,15 @@
|
|
|
304
312
|
],
|
|
305
313
|
"tests": [
|
|
306
314
|
{"file": "tests/diagnostics-collector.spec.ts", "name": "is disabled until enabled, records success denominators and settles once"},
|
|
315
|
+
{"file": "tests/auto-allocation-diagnostics.spec.ts", "name": "separates assessment outcomes without changing model opportunities or exposing errors"},
|
|
316
|
+
{"file": "tests/auto-allocation-diagnostics.spec.ts", "name": "keeps legacy reasons unrecorded and captures no-fit and successful assessment outcomes"},
|
|
317
|
+
{"file": "tests/request-diagnostics.spec.ts", "name": "requires independent consent, captures status/timing and never infers upload or retry count"},
|
|
318
|
+
{"file": "tests/request-diagnostics.spec.ts", "name": "bounds credential evidence under request consent and fences late commit updates"},
|
|
319
|
+
{"file": "tests/diagnostics-card.spec.ts", "name": "keeps every diagnostic population collapsed independently without changing collection"},
|
|
320
|
+
{"file": "tests/request-body-composition.spec.ts", "name": "partitions a 20.4 MiB request without parsing its payload object graph"},
|
|
321
|
+
{"file": "tests/preview-transport-failures.spec.ts", "name": "does not wait for large-request composition before native success and updates the exact settled row"},
|
|
322
|
+
{"file": "tests/request-diagnostics.spec.ts", "name": "updates only its own retained record after native settlement, never across clear/pause/eviction"},
|
|
323
|
+
{"file": "tests/preview-transport-failures.spec.ts", "name": "records verified 408 once without changing the native error, serialized input or dispatch count"},
|
|
307
324
|
{"file": "tests/diagnostics-client.spec.ts", "name": "rejects stale status responses and settles an unmounted Checking operation once"},
|
|
308
325
|
{"file": "tests/diagnostics-card.spec.ts", "name": "requires a confirmed durable enable and a separate destructive clear confirmation"},
|
|
309
326
|
{"file": "tests/fixtures/diagnostics-storage-core.fixture.ts", "name": "isolates profiles on the home-wide backend and preserves memory on a real publish failure"},
|
|
@@ -728,7 +745,7 @@
|
|
|
728
745
|
{"file": "tests/request-body-timeout.spec.ts", "name": "reports a skipped opt-in compression reason without changing identity diagnostics"},
|
|
729
746
|
{"file": "tests/auto-task-assessment.spec.ts", "name": "rejects late results even before the scheduled timeout callback runs"},
|
|
730
747
|
{"file": "tests/auto-task-assessment.spec.ts", "name": "aborts preparation at the monotonic deadline before an adapter can start"},
|
|
731
|
-
{"file": "tests/preview-route.spec.ts", "name": "does not dispatch an auxiliary request when native preparation outlasts a delayed deadline timer"},
|
|
748
|
+
{"file": "tests/preview-route.spec.ts", "name": "does not dispatch an auxiliary request when native preparation outlasts a delayed deadline timer (budget %s)"},
|
|
732
749
|
{"file": "tests/preview-provider.spec.ts", "name": "checks the auxiliary deadline immediately before native %s Fetch and releases the lease"},
|
|
733
750
|
{"file": "tests/auto-task-classifier.spec.ts", "name": "prefers advertised reasoning-off candidates without inferring latency or model-name capabilities"},
|
|
734
751
|
{"file": "tests/auto-selection-explanation.spec.ts", "name": "distinguishes continuity and category pool from semantic model merit (%s)"},
|
|
@@ -1324,6 +1341,8 @@
|
|
|
1324
1341
|
"required": true,
|
|
1325
1342
|
"sourceMarkers": [
|
|
1326
1343
|
{"file": "src/auto-allocation.ts", "marker": "high-cost-v1"},
|
|
1344
|
+
{"file": "src/auto-allocation.ts", "marker": "high-cost-v2"},
|
|
1345
|
+
{"file": "src/auto-allocation.ts", "marker": "deferredHighCostCount"},
|
|
1327
1346
|
{"file": "src/config.ts", "marker": "highCostModelIds"},
|
|
1328
1347
|
{"file": "src/model-preferences-card.ts", "marker": "High cost"},
|
|
1329
1348
|
{"file": "src/turn-selection-host.ts", "marker": "allocationSummary"},
|
|
@@ -1332,7 +1351,9 @@
|
|
|
1332
1351
|
{"file": "docs/auto-high-cost.md", "marker": "separate acceptance"}
|
|
1333
1352
|
],
|
|
1334
1353
|
"tests": [
|
|
1335
|
-
{"file": "tests/auto-allocation.spec.ts", "name": "
|
|
1354
|
+
{"file": "tests/auto-allocation.spec.ts", "name": "simulates 20000 turns per previous state without selecting a deferred high-cost peer"},
|
|
1355
|
+
{"file": "tests/auto-allocation.spec.ts", "name": "keeps v1 historical weights readable without relabeling them as v2"},
|
|
1356
|
+
{"file": "tests/auto-allocation-evidence.spec.ts", "name": "keeps legacy-only summaries v1 and separates mixed-policy decisions explicitly"},
|
|
1336
1357
|
{"file": "tests/auto-allocation-evidence.spec.ts", "name": "counts each turn once, bounds retention and never recovers missing evidence after removal"},
|
|
1337
1358
|
{"file": "tests/auto-model-routing.spec.ts", "name": "keeps costly Fast models eligible and evidence opt-out independent of the selected route"},
|
|
1338
1359
|
{"file": "tests/authorization-controller.spec.ts", "name": "saves orthogonal high-cost preferences narrowly without credential or Session reads"},
|
|
@@ -1364,6 +1385,8 @@
|
|
|
1364
1385
|
{"file": "src/account-model-catalog.ts", "marker": "model_picker_category"},
|
|
1365
1386
|
{"file": "src/auto-task-assessment.ts", "marker": "COPILOT_AUTO_ASSESSMENT_CONTEXT_OMITTED"},
|
|
1366
1387
|
{"file": "src/auto-task-classifier.ts", "marker": "classifyTaskWithAdapter"},
|
|
1388
|
+
{"file": "src/config.ts", "marker": "autoSemanticAssessmentTimeoutMs:"},
|
|
1389
|
+
{"file": "src/config.ts", "marker": "autoSemanticAssessmentModel:"},
|
|
1367
1390
|
{"file": "src/auto-model-routing.ts", "marker": "targetCategory"},
|
|
1368
1391
|
{"file": "src/config.ts", "marker": "autoSemanticAssessment"},
|
|
1369
1392
|
{"file": "src/auto-selection-explanation.ts", "marker": "No candidate fits"},
|
|
@@ -1403,6 +1426,10 @@
|
|
|
1403
1426
|
{"file": "tests/auto-selection-explanation.spec.ts", "name": "distinguishes local rule coverage from absent conversation context in both languages"},
|
|
1404
1427
|
{"file": "tests/auto-task-assessment.spec.ts", "name": "preserves caller cancellation instead of using a success-shaped fallback"},
|
|
1405
1428
|
{"file": "tests/config.spec.ts", "name": "defaults semantic Auto assessment on while preserving explicit opt-out"},
|
|
1429
|
+
{"file": "tests/config.spec.ts", "name": "exposes a bounded assessment budget and optional exact classifier without changing opt-out"},
|
|
1430
|
+
{"file": "tests/auto-task-assessment.spec.ts", "name": "allows a response after the old eight-second budget under the new bounded default"},
|
|
1431
|
+
{"file": "tests/auto-task-assessment.spec.ts", "name": "still rejects a result at the new default deadline without relying on timer delivery"},
|
|
1432
|
+
{"file": "tests/auto-task-classifier.spec.ts", "name": "honors an explicit exact account classifier without category guessing or automatic fallback"},
|
|
1406
1433
|
{"file": "tests/preview-route.spec.ts", "name": "assesses Auto with setting %s and freezes the captured reason across retries"},
|
|
1407
1434
|
{"file": "tests/turn-selection-card.spec.ts", "name": "explains a captured task/category decision with progressive details (%s)"},
|
|
1408
1435
|
{"file": "tests/auto-model-routing.spec.ts", "name": "does not discard a complete Core assistant message when it contains reasoning"},
|
package/docs/auto-high-cost.md
CHANGED
|
@@ -42,28 +42,46 @@ unchanged official Core fixture, not that the affected live Host read the mark
|
|
|
42
42
|
before the historical Astra decision. Do not hardcode a model, change live
|
|
43
43
|
preferences or rewrite a frozen explanation to manufacture a repair.
|
|
44
44
|
|
|
45
|
-
## Routing policy
|
|
45
|
+
## Routing policy v2 (#410)
|
|
46
46
|
|
|
47
47
|
1. Account ownership, metadata validity, exclusion, input modality and input
|
|
48
48
|
headroom are hard requirements.
|
|
49
49
|
2. Assess each new turn using existing contextual local/semantic evidence.
|
|
50
50
|
Preserve existing demand categories and supplier-category fallback.
|
|
51
|
-
3. Inside the first fitting category only,
|
|
52
|
-
|
|
53
|
-
|
|
51
|
+
3. Inside the first fitting category only, use unmarked candidates if any fit.
|
|
52
|
+
Defer fitting marked candidates; otherwise use the marked-only fallback tier.
|
|
53
|
+
Ordinary candidates have weight 1 and an eligible previous ordinary model
|
|
54
|
+
receives multiplier 1.5. Marked candidates have weight 0.2 without continuity.
|
|
54
55
|
4. Select from cumulative positive weights using a stable Agent/turn seed.
|
|
55
56
|
Capture the selected ID, candidate weights and conditional expected shares.
|
|
56
57
|
No additional model calls are made to give candidates a chance.
|
|
57
58
|
5. When no model fits, retain the largest-input-budget native recovery path.
|
|
58
59
|
Cost cannot justify choosing a model that cannot fit.
|
|
59
60
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
61
|
+
This is a user-requested stronger cost preference, not calibrated quality or
|
|
62
|
+
billing facts. A marked previous model cannot retain the turn when an unmarked
|
|
63
|
+
peer fits the selected category. A lone fitting marked model is selected and an
|
|
64
|
+
all-marked pool remains usable. A marked Lightweight model can still serve a
|
|
65
|
+
simple task if that category has no fitting unmarked peer. Fit and supplier
|
|
66
|
+
category cannot prove peers can solve the task; no automatic escalation, extra
|
|
67
|
+
calls, in-turn switch or lower-category substitution is introduced.
|
|
68
|
+
Every participating final-tier candidate has positive opportunity; deferred
|
|
69
|
+
marked candidates have none. The bounded explanation reports their count,
|
|
70
|
+
not fake positive shares. Stable seeds do not prove independent random trials.
|
|
71
|
+
|
|
72
|
+
Historical v1 remains readable with its original mixed-pool weights and marked
|
|
73
|
+
continuity multiplier. Persistent cohorts retain original policy versions.
|
|
74
|
+
The Session summary separates incompatible policy cohorts and reports omitted
|
|
75
|
+
decisions instead of relabeling them or merging different opportunities.
|
|
76
|
+
|
|
77
|
+
Read-only October 11 alpha.10 aggregates showed 3 Astra selections against
|
|
78
|
+
2.868 summed expected selections across 18 opportunities, without Session or
|
|
79
|
+
sequence identity. The requested local Session's bounded native metadata showed
|
|
80
|
+
five Sol turns followed by two Astra turns; its last 178 messages belonged to
|
|
81
|
+
one frozen turn. This does not establish a distribution violation. A conditional
|
|
82
|
+
two-peer seeded reproduction matches the two Astra choices, but the exact
|
|
83
|
+
historical pool was not retained. V2 implements the user's stricter preference,
|
|
84
|
+
not a claimed repair to a proven random-number defect.
|
|
67
85
|
|
|
68
86
|
The auxiliary semantic classifier is a separate call, not another main-turn
|
|
69
87
|
allocation. It prefers an unmarked eligible Lightweight classifier; if only
|
|
@@ -80,7 +98,8 @@ Synthetic acceptance covers ordinary/marked/all-marked/single pools, every
|
|
|
80
98
|
supplier category, exclusions, capacity, category changes, stable seeds,
|
|
81
99
|
preference changes and admitted-turn freezing. Distribution checks use large
|
|
82
100
|
declared seed sets and compare actual allocation with conditional expected
|
|
83
|
-
shares, including a marked previous model
|
|
101
|
+
shares, including a marked previous model in a marked-only tier, deferred
|
|
102
|
+
high-cost candidates, and backward-compatible v1 evidence.
|
|
84
103
|
|
|
85
104
|
Runtime evidence must distinguish a selected decision from native attempted,
|
|
86
105
|
delivered, finished, failed and cancelled calls. Count a decision once per
|
|
@@ -90,14 +109,26 @@ and eligibility windows. No-fit decisions have no fitting-pool distribution.
|
|
|
90
109
|
Report category, assessment source, switching/continuity and marking state at
|
|
91
110
|
decision time, never reconstructed from today's settings.
|
|
92
111
|
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
112
|
+
The turn-selection dialog continues to expose bounded Host-lifetime evidence.
|
|
113
|
+
Separately, default-off Local diagnostics persists daily profile-local
|
|
114
|
+
allocation aggregates in the reviewed public storage domain when collection is
|
|
115
|
+
enabled. It records plugin/policy version, target/selected category,
|
|
116
|
+
demand/assessment source, model, high-cost/continuity flags, weight,
|
|
117
|
+
opportunities, conditional expected selections, actual selections and no-fit
|
|
118
|
+
counts. Retain at most 1,024 strata for 14 days under the shared 2 MiB snapshot
|
|
119
|
+
limit; expose restart, expiration, drops and truncation. There are no
|
|
120
|
+
Session/turn IDs, prompt/content, execution or task-outcome records, custom
|
|
121
|
+
Core history events, automatic uploads or tuning. The shared Local diagnostics
|
|
122
|
+
switch controls account/Checking and compaction aggregates; Auto allocation
|
|
123
|
+
collection has its own hidden volatile, default-off setting and can be enabled
|
|
124
|
+
without collecting those other populations. Missing history is unknown, not
|
|
125
|
+
zero usage or success, and selection remains distinct from execution, quality
|
|
126
|
+
and billing.
|
|
127
|
+
|
|
128
|
+
`autoAllocationEvidence: false` stops future Host-lifetime candidate captures
|
|
129
|
+
without changing selection; it does not disable the separately controlled
|
|
130
|
+
persistent Local diagnostics aggregates. The read-only exports perform no
|
|
131
|
+
automatic file writes/upload.
|
|
101
132
|
|
|
102
133
|
No prompt, answer, tool content, replay, credential, account name or raw Session
|
|
103
134
|
ID belongs in an aggregate review. Keep evidence local; no automatic upload.
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 1,
|
|
3
3
|
"feature": "autorouting",
|
|
4
|
-
"status": "
|
|
5
|
-
"policyVersion": "high-cost-
|
|
4
|
+
"status": "insufficient-sample",
|
|
5
|
+
"policyVersion": "high-cost-v2",
|
|
6
6
|
"observation": {
|
|
7
|
-
"start":
|
|
8
|
-
"end":
|
|
9
|
-
"sampleCount":
|
|
10
|
-
"limitations": "No
|
|
7
|
+
"start": "2026-10-08T00:00:00Z",
|
|
8
|
+
"end": "2026-10-09T23:59:59Z",
|
|
9
|
+
"sampleCount": 63,
|
|
10
|
+
"limitations": "The declared 63-sample window is the prior alpha.2 review, not the newer cohort. Separate alpha.10 read-only profile aggregates on October 11 show Astra 3 selections across 18 conditional opportunities, summed expected selections 2.868. No Session IDs or sequence in aggregates. Bounded native metadata from the requested local Session shows five Sol turns followed by two Astra turns; the last has 178 steps under one frozen allocation. Tail scan is limited, not full history. Actual per-turn pool/weights are not durably retained. Two user-reported valid unknown classifier results are not a population unknown rate. No content, credentials or raw export uploaded."
|
|
11
11
|
},
|
|
12
|
-
"previousReview": "
|
|
13
|
-
"findings": "
|
|
14
|
-
"decision": "
|
|
15
|
-
"validation": "
|
|
12
|
+
"previousReview": "Prior allocation review #332/#333, post-delivery review #334, fixed-outcome diagnostics #398, budget/config trial #400, classifier disable #405 and published capability/diagnostic repair #407.",
|
|
13
|
+
"findings": "Prior 63 decisions cannot attribute later incidents. Valid unknown is not a timeout. Projection regressions establish avoidable anchor loss/incidental-omission downgrade, not the actual task root cause. The reported Astra streak is two allocations, not 178 independent choices. Under an explicitly assumed two-model category pool, production Session/turn seeds reproduce both Astra choices at conditional shares 11.8% then 23.1%; this is conditional reproduction, not recovered decision evidence. A 20000-turn synthetic fixed-previous v1 scan yields 4563 Astra hits and 1014 adjacent pairs, showing runs are possible, not proving actual distribution conformity. No observed aggregate inflation is established. V1 intentionally grants marked continuity; the user now requests a stricter cost preference, not a statistically proven RNG repair.",
|
|
14
|
+
"decision": "Issues #409/#410: preserve bounded task anchor/chain and separate incidental omission from task limitations; keep genuine unknown, account proof, reasoning off, no tools, one call/no retry, 128 output tokens and native admission. In the first fitting supplier category, v2 uses unmarked candidates whenever available; marked candidates remain a fallback only when that category has no fitting unmarked peer. Remove marked continuity bonus, retain ordinary 1.5 bonus and positive within-tier weights. Record bounded deferred count and keep v1 codecs/cohorts readable without relabeling. Fit is not proof peers can solve the task; no automatic escalation, retry, category weakening or in-turn switch. No new persistent population or measured accuracy/cost-saving claim.",
|
|
15
|
+
"validation": "Projection and cost-tier regressions failed before implementation. Focused 121 tests and test typecheck pass, including 20000-seed scans per previous state, all-marked/ordinary positive distribution, deferred-only exclusion, legacy v1 decoding and persistent cohort preservation. Explicit missing-anchor tests retain conservative downshift protection. Native saved-mark/restart fixture now asserts cost tier rather than v1 shares. Full gate and exact alpha.11 pack/tarball verification remain required. No real model requests, credential access, profile edits or Desktop restart.",
|
|
16
16
|
"followUp": {
|
|
17
17
|
"owner": "Maintainer or Agent assigned to post-delivery review issue #334",
|
|
18
|
-
"trigger": "
|
|
19
|
-
"metric": "
|
|
20
|
-
"action": "Review
|
|
18
|
+
"trigger": "Review 200 new decisions with recorded reasons, or any further classifier capability/context/policy change; first inspect a successful unknown turn's projection and decoded-demand fields.",
|
|
19
|
+
"metric": "Unknown among valid results versus blocked simple/routine by projection and producer; v2 selected/no-fit counts and within-tier conditional expected/actual selections separately from v1 and deferred candidates. Count new turns, not messages. Legacy absence is unknown. Labeled quality/outcomes remain required; no billing/latency inference.",
|
|
20
|
+
"action": "Review anchor preservation and whether ordinary-tier choices pass independent task validation without underpowering complex work; review marked fallback only where actual fit evidence supports it. Retain genuine uncertainty. Do not infer solved/failed tasks from category or model ID. Defer further tuning without sufficient evidence; linked #334, no automatic upload or live benchmark."
|
|
21
21
|
}
|
|
22
22
|
}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Tracking: [#258](https://github.com/cloga/dsh-github-copilot/issues/258) and
|
|
4
4
|
[evidence refinement #262](https://github.com/cloga/dsh-github-copilot/issues/262).
|
|
5
5
|
|
|
6
|
-
**Current contract:** source candidate `0.4.
|
|
6
|
+
**Current contract:** source candidate `0.4.2-alpha.10`, targeting official DSH/Windows
|
|
7
7
|
Desktop `0.2.0-rc.2`. Semantic assessment is enabled by default with bounded
|
|
8
8
|
auxiliary timing/output evidence. Neither publication nor
|
|
9
9
|
these explanations prove the version loaded in a particular Host.
|
|
@@ -22,6 +22,38 @@ namespace; it is not an extra switch on the Web search card. This changes
|
|
|
22
22
|
subsequent assessments, not an already-admitted turn. Local known-task rules
|
|
23
23
|
still work when auxiliary inference is disabled.
|
|
24
24
|
|
|
25
|
+
The native plugin configuration exposes these profile-wide settings under
|
|
26
|
+
`github-copilot` (not the Web search routing card):
|
|
27
|
+
|
|
28
|
+
| Setting | Default | Meaning |
|
|
29
|
+
|---|---|---|
|
|
30
|
+
| `autoSemanticAssessmentTimeoutMs` | `30000` | Integer total preparation/response budget from 1000 to 120000 ms. `8000` restores the earlier budget; zero/unlimited is not supported. |
|
|
31
|
+
| `autoSemanticAssessmentModel` | `''` | Empty uses metadata-driven automatic classifier selection. A nonempty value is an exact current-account model ID, not a display name or virtual Auto choice. |
|
|
32
|
+
|
|
33
|
+
For example, keep automatic selection while allowing the new default budget:
|
|
34
|
+
|
|
35
|
+
```yaml
|
|
36
|
+
github-copilot:
|
|
37
|
+
autoSemanticAssessment: true
|
|
38
|
+
autoSemanticAssessmentTimeoutMs: 30000
|
|
39
|
+
autoSemanticAssessmentModel: ''
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
These fields require the new plugin release; adding them to an older version
|
|
43
|
+
does not implement the behavior. Changes apply to subsequent assessments,
|
|
44
|
+
not an admitted turn's steps/retries. The 30-second default is a user-approved
|
|
45
|
+
trial, not calibrated latency or proof that past unknown results were timeouts.
|
|
46
|
+
Larger budgets can increase time before the answer begins and auxiliary charges.
|
|
47
|
+
Native Chat/search deadlines and user cancellation are independent.
|
|
48
|
+
|
|
49
|
+
An explicit classifier may use any account-advertised category, but still must
|
|
50
|
+
be an entitled, unexcluded concrete model with text capability, validated protocol
|
|
51
|
+
and the existing input/output headroom. A missing, excluded or unsuitable choice
|
|
52
|
+
produces `COPILOT_AUTO_CLASSIFIER_CONFIGURED_MODEL_UNAVAILABLE`, then the existing
|
|
53
|
+
unknown-demand/unavailable diagnostic; no silent alternate classifier is called.
|
|
54
|
+
Answer selection remains a separate Auto decision. The classifier result does
|
|
55
|
+
not choose its own answer model.
|
|
56
|
+
|
|
25
57
|
Open the reply's selection explanation for the captured decision. Evidence is
|
|
26
58
|
Host-lifetime and bounded; after restart or eviction it can be unavailable.
|
|
27
59
|
Do not infer an old decision from the current picker.
|
|
@@ -30,7 +62,7 @@ Do not infer an old decision from the current picker.
|
|
|
30
62
|
|---|---|
|
|
31
63
|
| `uncertain` / unknown demand | The available evidence does not establish task demand; it is not a failed answer or a claim that the conversation is empty. |
|
|
32
64
|
| `insufficient-evidence` | A local rule or classifier could not justify a demand category. Longer context alone does not guarantee classification. |
|
|
33
|
-
| Semantic timeout | No validated result within the
|
|
65
|
+
| Semantic timeout | No validated result within the captured configured end-to-end budget (30 seconds by default). Demand remains unknown; Efficiency/Balance target Versatile, Intelligence targets Powerful, subject to eligibility and category fallback. |
|
|
34
66
|
| Missing auxiliary milestone | That milestone was not observed before assessment settled, not proof the supplier never sent data. |
|
|
35
67
|
| Selection unknown/unavailable | Captured selection evidence is absent or could not be read, distinct from unknown task demand. |
|
|
36
68
|
|
|
@@ -38,6 +70,21 @@ There is no assessment retry or automatic deadline extension. Caller cancellatio
|
|
|
38
70
|
aborts the turn rather than invoking fallback. Auxiliary calls can add latency
|
|
39
71
|
and supplier charges outside native answer Usage.
|
|
40
72
|
|
|
73
|
+
Classifier capability checks accept only explicit account-advertised disable
|
|
74
|
+
labels: `off`, protocol-native `none` for Responses/Completions, or `disabled`
|
|
75
|
+
for Anthropic. No aliases are applied to ordinary Chat model maps. Missing or
|
|
76
|
+
empty effort metadata does not prove absence of reasoning.
|
|
77
|
+
|
|
78
|
+
Strict request-local `semantic.candidateScan` evidence records at most 512
|
|
79
|
+
candidates, eligible counts and first-rejection counts for exclusions, explicit
|
|
80
|
+
ID mismatch, category, text input, unproven disable capability and budget.
|
|
81
|
+
Counts partition the examined pool, not all possible rejection reasons per model.
|
|
82
|
+
No candidate IDs, prompts or raw metadata are retained in these counts.
|
|
83
|
+
`preparationFailure: native-off-unavailable` separates native off preparation
|
|
84
|
+
from no-fit selection. No-fit Host warnings use fixed codes only. These fields
|
|
85
|
+
are ephemeral selection evidence, not a new persisted diagnostic population;
|
|
86
|
+
absent legacy evidence cannot be reconstructed.
|
|
87
|
+
|
|
41
88
|
## Requirements
|
|
42
89
|
|
|
43
90
|
Auto must explain why the initiating turn chose its actual route, not display a
|
|
@@ -93,17 +140,31 @@ existing managed native adapter, never an Auto ID and never `ctx.llm` routing
|
|
|
93
140
|
recursion. It has no tools, bounded text-only assessment context, bounded JSON
|
|
94
141
|
output, one deadline, cancellation and no new retry loop. Text from messages is
|
|
95
142
|
untrusted data, not router instructions. Files/images/reasoning/replay bodies
|
|
96
|
-
are not read;
|
|
97
|
-
downshifting. Assessment input is a separate projection: the actual chat
|
|
143
|
+
are not read; limited task text cannot justify downshifting. Assessment input is a separate projection: the actual chat
|
|
98
144
|
messages, system prompt, tools, attachments and history stay untouched.
|
|
99
145
|
|
|
100
146
|
Only locally unknown tasks invoke the enabled assessment. Context packing keeps
|
|
101
|
-
the current and nearest preceding user requests before recent output
|
|
102
|
-
|
|
147
|
+
the current and nearest preceding user requests before recent output. An explicit
|
|
148
|
+
continuation also reserves the nearest substantive user anchor among the previous
|
|
149
|
+
twelve user messages and the intervening user chain, then restores chronological
|
|
150
|
+
order. No expired anchor, task summary or semantic task boundary is invented.
|
|
151
|
+
At most twelve complete JSON rows, 1600 text
|
|
103
152
|
characters per row and 8000 serialized characters are retained; JSON escape
|
|
104
153
|
expansion is included in this bound. Any truncation, skipped row or non-text
|
|
105
|
-
content still marks
|
|
106
|
-
|
|
154
|
+
content still marks projection omission. A missing current request/continuation
|
|
155
|
+
anchor, a missing reserved user row, truncated reserved task text, or nontext
|
|
156
|
+
content in the reserved user chain separately marks `taskTextLimited` and prevents
|
|
157
|
+
a semantic simple/routine downshift. Incidental assistant/tool/history omissions
|
|
158
|
+
alone no longer force that downgrade. The classifier must still judge whether
|
|
159
|
+
the retained evidence establishes demand; retained text is not semantic
|
|
160
|
+
completeness and missing required details must remain unknown.
|
|
161
|
+
|
|
162
|
+
The instruction requests a schema without a pre-filled unknown answer and
|
|
163
|
+
distinguishes projected data omissions from missing relevant task evidence.
|
|
164
|
+
Unknown is permitted for genuinely indeterminate demand, not required merely
|
|
165
|
+
because a long conversation exceeds the projection bounds. No reasoning/tool
|
|
166
|
+
enablement, second inference, larger context/output budget or full-history
|
|
167
|
+
serialization is introduced.
|
|
107
168
|
|
|
108
169
|
The strict result contains demand (`simple`, `routine`, `complex`, `unknown`)
|
|
109
170
|
and finite evidence signals, not a model ID, raw reasoning or an uncalibrated
|
|
@@ -113,9 +174,16 @@ instead of falling back. Credential, metadata and account revocation remain
|
|
|
113
174
|
fatal through existing lease/admission guards. Extra calls incur supplier
|
|
114
175
|
charges and latency, separate from native chat Usage and without inferred cost.
|
|
115
176
|
|
|
177
|
+
Strict ephemeral explanation evidence optionally records retained row count
|
|
178
|
+
(0–12), the projection omission flag, task-text limitation, fixed continuation
|
|
179
|
+
anchor status and the classifier's decoded demand. No text, attachment values
|
|
180
|
+
or new persistent population is recorded. Legacy absent fields stay absent.
|
|
181
|
+
These fields distinguish a valid classifier `unknown` from plugin-side
|
|
182
|
+
simple/routine blocking; they do not establish accuracy or a live unknown rate.
|
|
183
|
+
|
|
116
184
|
## Auxiliary latency evidence and bounded output (#272)
|
|
117
185
|
|
|
118
|
-
The assessment
|
|
186
|
+
The assessment has one **configured end-to-end deadline, 30 seconds by default**, including account
|
|
119
187
|
discovery/preparation and the native call. It does not retry on timeout or try a
|
|
120
188
|
second classifier. The response budget is now 128 output tokens, with compact
|
|
121
189
|
demand JSON and at most three fixed signals requested. The strict decoder
|
|
@@ -131,16 +199,44 @@ this is not a hard real-time guarantee or evidence of a supplier latency cause.
|
|
|
131
199
|
The owned timer and abort listener are disposed when assessment settles.
|
|
132
200
|
|
|
133
201
|
Among eligible supplier Lightweight text candidates with the existing input
|
|
134
|
-
headroom
|
|
202
|
+
headroom and explicit reasoning-disable proof, automatic selection prefers
|
|
203
|
+
unmarked cost, then deterministic ID ordering. An explicit exact-ID setting selects only that
|
|
204
|
+
eligible model, without category or cost re-ranking.
|
|
135
205
|
This does not infer speed, health or quality from effort or model names, and
|
|
136
206
|
does not launch a second candidate if native support is absent.
|
|
137
207
|
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
208
|
+
Automatic selection is metadata-driven, not an empirical fastest/best model
|
|
209
|
+
search. No additional benchmark requests, adaptive deadlines, per-model health
|
|
210
|
+
ranking, cooldown or cross-turn cache are introduced. Those require separately
|
|
211
|
+
reviewed representative latency/accuracy/cost observations and consent, not a
|
|
212
|
+
guess from model names or a timeout suspicion. Review outcomes under #334 before
|
|
213
|
+
claiming the increased default improves live classification.
|
|
214
|
+
|
|
215
|
+
The classifier is eligible only when current account metadata advertises
|
|
216
|
+
an explicit protocol-compatible disable mode and the isolated, public prepared
|
|
217
|
+
model exposes `off`. It then
|
|
218
|
+
always requests `off`; otherwise assessment fails closed without dispatching
|
|
219
|
+
the classifier. The classifier-only model mapping serializes the native
|
|
220
|
+
disable form supported by the published adapter: Responses
|
|
221
|
+
`reasoning.effort: "none"`, OpenAI-compatible `reasoning_effort: "none"`, or
|
|
222
|
+
Anthropic `thinking.type: "disabled"`. This mapping is not added to shared
|
|
223
|
+
account models, so ordinary Chat behavior remains unchanged.
|
|
224
|
+
|
|
225
|
+
The auxiliary adapter also does not inherit configured Chat reasoning effort:
|
|
226
|
+
its isolated profile omits that default while ordinary Chat retains it. Tools
|
|
227
|
+
and an execution loop are absent. These checks establish the requested wire
|
|
228
|
+
payload in synthetic tests, not that every supplier honors the control
|
|
229
|
+
internally. Models lacking either advertised or native support are not used;
|
|
230
|
+
do not substitute `low` or `minimal`, which can enable reasoning.
|
|
231
|
+
|
|
232
|
+
Tools and an execution loop are absent. Only locally unknown tasks use one
|
|
233
|
+
classifier call per admitted turn; subsequent steps/retries reuse its result.
|
|
234
|
+
Text projection stays bounded to twelve rows, 1600 characters per row and
|
|
235
|
+
8000 serialized characters; files, images and replay bodies are not included.
|
|
236
|
+
The requested output budget remains 128 tokens. Neither those bounds nor the
|
|
237
|
+
waiting deadline establishes a hard supplier reasoning-token, credit or dollar
|
|
238
|
+
cap. Measure accuracy, elapsed time and auxiliary usage separately before
|
|
239
|
+
reducing context/output or claiming a cheapest/fastest classifier.
|
|
144
240
|
|
|
145
241
|
Captured Host-lifetime selection evidence now includes a bounded public
|
|
146
242
|
classifier ID, configured waiting budget, total monotonic assessment elapsed
|
|
@@ -189,9 +285,12 @@ explicit fallback only, not fabricated categories. Unknown/new category values
|
|
|
189
285
|
remain unclassified with a bounded catalog diagnostic.
|
|
190
286
|
|
|
191
287
|
Within the first fitting category, use stable positive weighted Session/turn
|
|
192
|
-
allocation
|
|
193
|
-
|
|
194
|
-
|
|
288
|
+
allocation within the unmarked tier when available, otherwise the high-cost
|
|
289
|
+
fallback tier. Ordinary weight 1 has finite previous-model multiplier 1.5;
|
|
290
|
+
marked weight 0.2 has no continuity bonus. Deferred candidates have no allocation
|
|
291
|
+
opportunity in that turn. Cost is independent of task difficulty and supplier
|
|
292
|
+
category; input fit does not prove task success. Never weaken category or
|
|
293
|
+
automatically escalate to establish whether another model can solve the task.
|
|
195
294
|
These are reviewed policy parameters, not measured quality or prices. Once
|
|
196
295
|
admitted, all steps/retries share the decision. No supplier cache savings are
|
|
197
296
|
claimed. See [high-cost requirements](./auto-high-cost.md) and
|
|
@@ -58,7 +58,8 @@ remains authoritative after final framing/attachment projection.
|
|
|
58
58
|
Task preference uses supplier `model_picker_category`, not capacity, model
|
|
59
59
|
names or reasoning effort as quality rankings. [Task policy](./auto-task-routing.md)
|
|
60
60
|
owns the demand matrix, default semantic assessment, category fallback,
|
|
61
|
-
finite continuity and stable positive-weight
|
|
61
|
+
cost-tier deferral, ordinary finite continuity and stable positive-weight
|
|
62
|
+
same-category within-tier allocation.
|
|
62
63
|
User-marked high cost is orthogonal to demand and category; see
|
|
63
64
|
[high-cost requirements](./auto-high-cost.md). Future policy changes must read
|
|
64
65
|
the [latest review](./auto-iteration-review.json) before implementation.
|
package/docs/copilot-accounts.md
CHANGED
|
@@ -17,6 +17,12 @@ normal native refresh by another same-account request. Upgrade to 0.4.1 for the
|
|
|
17
17
|
narrow plugin-owned refresh exception. This is synthetic regression evidence,
|
|
18
18
|
not attribution of a particular live error to refresh.
|
|
19
19
|
|
|
20
|
+
Separately enabled request diagnostics may now record fixed qualification,
|
|
21
|
+
notification and commit reasons plus bounded live-wire populations; see
|
|
22
|
+
[credential-change decisions](./plugin-diagnostics.md#credential-change-decisions-402).
|
|
23
|
+
Unknown notification source stays unknown. This observes the existing exception,
|
|
24
|
+
not a broader permission to preserve requests or a reconstruction of past failures.
|
|
25
|
+
|
|
20
26
|
Only a genuine native refresh through the plugin's public credential-store bridge
|
|
21
27
|
may qualify: normalized account grant, model entitlements and official
|
|
22
28
|
OAuth-derived endpoint must remain unchanged. Its exact returned object is
|
|
@@ -106,7 +106,7 @@ Original serialized value spans partition total bytes into `input`/`messages`, t
|
|
|
106
106
|
|
|
107
107
|
Responses tool pictures are also image blocks: the native SDK serializes them under `function_call_output.output[]`, separately from ordinary message `content[]`. Older plugin diagnostics incorrectly classified those spans as remaining history, so an old report of zero image bytes does not establish an image-free request. The corrected diagnostic applies only to newly observed failures; stored failures and history are not rewritten. Unknown output arrays remain residual, and the fix changes neither total bytes nor native image admission, offload budgets, replay or transport.
|
|
108
108
|
|
|
109
|
-
Analysis
|
|
109
|
+
Analysis up to 16 MiB retains the existing span validator. Larger verified-408 JSON bodies use a cooperative span scanner up to 32 MiB without allocating a full payload object graph or decoding image/replay content. Its 65,536-character yields, two-second monotonic deadline and four concurrent scan slots bound additional work; both paths retain 64-level depth, 131072-token, 65536-value and 128-serialized-key-character limits. Separately opted-in physical request observations may already have started that same work after Fetch invocation, without holding up ordinary native response delivery. Verified-408 guidance may await it and preserves Fetch-to-header timing measured before analysis. Missing, malformed, unsupported, size/work/time-limited or cancelled evidence remains explicitly unavailable, never partial success-shaped totals. Replay validation and recovery keep the original 16 MiB limits. These limits are **not supplier request limits or admission controls**. A measured approximately 20.4 MiB body does not establish why a timeout occurred. If image blocks dominate, an explicitly selected smaller `chatMaxRequestImageBytes` can authorize native image offload; if compressible history dominates, explicit native compaction can help. Tool definitions and opaque replay may remain; small failing requests still warrant network/service investigation. Neither choice is performed automatically or guaranteed to reduce 408 frequency.
|
|
110
110
|
|
|
111
111
|
This implementation is preventive, not a general rescue summarizer. A manual summary whose full input already exceeds the hard budget fails before model transport. It does not silently trim, fabricate a partial checkpoint, or claim that refusing the request recovered the history. Giant fixed prefixes or an indivisible latest unit can also prevent useful reduction.
|
|
112
112
|
|