@capagents/forgeqe 3.2.3 → 3.2.4
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/HOW_TO_USE.md +8 -0
- package/dist/docs-site/docs/get-started/index.html +7 -0
- package/dist/docs-site/docs/search.js +1 -1
- package/dist/forgeqe.js +1769 -1769
- package/dist/web/assets/{3d-force-graph-Bt0kE6fK.js → 3d-force-graph-iP39yI0v.js} +1 -1
- package/dist/web/assets/{Agent-CsZ7vFCx.js → Agent-COXI7WgW.js} +1 -1
- package/dist/web/assets/{AgentWork-Bjy58QJs.js → AgentWork-LD5CQxet.js} +1 -1
- package/dist/web/assets/{ApiTests-_8-mU4o4.js → ApiTests-Dpwqmpr1.js} +9 -5
- package/dist/web/assets/{Browse-DXN091Tl.js → Browse-DIcTvI-C.js} +1 -1
- package/dist/web/assets/{Chat--mi_QDYP.js → Chat-DNw_jYbD.js} +1 -1
- package/dist/web/assets/{CommandPalette-DpYwTkxH.js → CommandPalette-B6QRxOka.js} +1 -1
- package/dist/web/assets/{Compare-CBatuMuQ.js → Compare-hz0ft2yP.js} +1 -1
- package/dist/web/assets/{Cost-Biq5Isox.js → Cost-C231Bf_A.js} +1 -1
- package/dist/web/assets/{Data-0_y_XKGw.js → Data-DODs050c.js} +1 -1
- package/dist/web/assets/{Desktop-DPKPECCb.js → Desktop-CUV43rdi.js} +1 -1
- package/dist/web/assets/{DesktopReview-COQqvQ7S.js → DesktopReview-WEIFBq-L.js} +1 -1
- package/dist/web/assets/{DeviceScreen-D8u68b5B.js → DeviceScreen-ClPTc5Ot.js} +1 -1
- package/dist/web/assets/{Evidence-_PkdHSff.js → Evidence-DhN_bTZ-.js} +1 -1
- package/dist/web/assets/{Explore-Bum9glmY.js → Explore-CjowiWJe.js} +1 -1
- package/dist/web/assets/{Features-OENuS23e.js → Features-BnagyBie.js} +1 -1
- package/dist/web/assets/{Flags-BqepPJcc.js → Flags-DlkY7U4M.js} +1 -1
- package/dist/web/assets/{Flaky-CCLSqsfC.js → Flaky-BkD01mRw.js} +1 -1
- package/dist/web/assets/{Impact-9PxyQO57.js → Impact-BM4_vIEv.js} +1 -1
- package/dist/web/assets/{Jobs-BGuNihAj.js → Jobs-U9kJUVM9.js} +1 -1
- package/dist/web/assets/{KindPage-T4AUKlMQ.js → KindPage-BkK5AQw0.js} +1 -1
- package/dist/web/assets/{LiveDevice-CP5RZ30S.js → LiveDevice-Bjc2r797.js} +1 -1
- package/dist/web/assets/{Migration-CrkuTtB7.js → Migration-BDDE_0TS.js} +1 -1
- package/dist/web/assets/{Mobile-BlHPt6gb.js → Mobile-D2qAF8X5.js} +1 -1
- package/dist/web/assets/{Observability-nbCRQf-p.js → Observability-CLFC0ze7.js} +1 -1
- package/dist/web/assets/{PageAgent-B17N29Vg.js → PageAgent-Dz5CuEUe.js} +1 -1
- package/dist/web/assets/{Product-y5qWviku.js → Product-DkEI-0vu.js} +3 -3
- package/dist/web/assets/{Production-3yYw4c-9.js → Production-CgfLjbSa.js} +1 -1
- package/dist/web/assets/{Quality-DZjyRpSa.js → Quality-8E667GJi.js} +1 -1
- package/dist/web/assets/{Readiness-DR-KExeM.js → Readiness-Bbkq2lNV.js} +1 -1
- package/dist/web/assets/{Record-DNByPZFL.js → Record-JR4HeyTe.js} +1 -1
- package/dist/web/assets/{Regression-Dewx-pZm.js → Regression-_9u6qDMk.js} +1 -1
- package/dist/web/assets/{RelationGraph-BlR8ewL9.js → RelationGraph-BnhbeI6t.js} +1 -1
- package/dist/web/assets/{Reports-Ca7Kewsb.js → Reports-DxjHb0vA.js} +1 -1
- package/dist/web/assets/{Response-CQMw9bTX.js → Response-BvQV20vS.js} +1 -1
- package/dist/web/assets/{Responsive-CEuJK8lj.js → Responsive-DNC31nTr.js} +1 -1
- package/dist/web/assets/{RunDiff-CYVCUyER.js → RunDiff-BXqh9adv.js} +1 -1
- package/dist/web/assets/{Runs-DPqjZhbv.js → Runs-PsPMVpQl.js} +1 -1
- package/dist/web/assets/{Settings-DmFBERmV.js → Settings-DEOCWX5o.js} +3 -3
- package/dist/web/assets/{Steps-AUxLKS75.js → Steps-C18OGSAM.js} +1 -1
- package/dist/web/assets/{TestCases-ZZx3n1uf.js → TestCases-MIOqrvt0.js} +1 -1
- package/dist/web/assets/{TestData-aY6U1NQz.js → TestData-DtPsGVwq.js} +1 -1
- package/dist/web/assets/{TestDebt-C6y5j1or.js → TestDebt-C8zEVY4j.js} +1 -1
- package/dist/web/assets/{TestManagement-8O_G3MDS.js → TestManagement-cXbBFksQ.js} +1 -1
- package/dist/web/assets/{WhatsNew-CABuR9OZ.js → WhatsNew-vGPOJXT2.js} +1 -1
- package/dist/web/assets/{dataParts-DqE6xkYJ.js → dataParts-D08j24QD.js} +1 -1
- package/dist/web/assets/{desktopAppPath-CqwJou-7.js → desktopAppPath-DyQr1aFk.js} +1 -1
- package/dist/web/assets/{diff-CdVbBfvE.js → diff-CVufIkRR.js} +1 -1
- package/dist/web/assets/{highlight-BbSbwn5i.js → highlight-BpaRxd70.js} +1 -1
- package/dist/web/assets/{index-CeVry7Jo.js → index-q1r33z9g.js} +6 -6
- package/dist/web/assets/input-ChhA0xMm.js +1 -0
- package/dist/web/assets/{pageBack-CGpBg0rz.js → pageBack-Dhl5PHZE.js} +1 -1
- package/dist/web/assets/{palette-sQXAx0hh.js → palette-CpGAHix6.js} +1 -1
- package/dist/web/assets/{paletteCommands-BUbZcBfs.js → paletteCommands-Der7qNEc.js} +1 -1
- package/dist/web/assets/{parts-CY9Brfn9.js → parts-eyvIPENF.js} +1 -1
- package/dist/web/assets/{productParts-DLa8Xzv7.js → productParts-2Y8IjOa0.js} +1 -1
- package/dist/web/assets/{qualityParts-Dfn1l_k_.js → qualityParts-CdoLEG3a.js} +1 -1
- package/dist/web/assets/{recordTest-CPRlUK1r.js → recordTest-vps_1X_-.js} +1 -1
- package/dist/web/assets/{stepper-D9tX3bS5.js → stepper-Cb6rnj2p.js} +1 -1
- package/dist/web/index.html +4 -4
- package/docs/user-guide.html +7 -0
- package/package.json +1 -1
- package/py/forgeqe_engine/copilot_gateway.py +81 -2
- package/py/forgeqe_engine/copilot_models.py +37 -1
- package/py/forgeqe_engine/llm.py +10 -1
- package/dist/web/assets/input-CK9KiscI.js +0 -1
|
@@ -55,13 +55,49 @@ def client_outdated(message: str) -> bool:
|
|
|
55
55
|
return bool(_OUTDATED.search(message or ""))
|
|
56
56
|
|
|
57
57
|
|
|
58
|
+
# Copilot's runtime could not send the request to GitHub's Copilot server at all (2026-11-20 on, from one company
|
|
59
|
+
# network: "Failed native model HTTP request: error sending request for url (https://api.business.githubcopilot.com/
|
|
60
|
+
# responses): client error (SendRequest)"). Every model is reached at that address, so another model fails the same way;
|
|
61
|
+
# what got through was the requests without a screenshot.
|
|
62
|
+
_NETWORK = re.compile(r"failed native model http request|error sending request for url|client error \(sendrequest\)", re.I)
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
def network_failed(message: str) -> bool:
|
|
66
|
+
"""Whether Copilot's error says the request could not be sent to GitHub's Copilot server (the network, not a model)."""
|
|
67
|
+
return bool(_NETWORK.search(message or ""))
|
|
68
|
+
|
|
69
|
+
|
|
58
70
|
def model_failed(status: Optional[int], message: str) -> bool:
|
|
59
71
|
"""Whether a failed request says the model itself is not working: a time-out, or a model error of Copilot's."""
|
|
60
72
|
if status == 504:
|
|
61
73
|
return True
|
|
62
74
|
if status != 502:
|
|
63
75
|
return False
|
|
64
|
-
return not _NOT_THE_MODEL.search(message or "") and not client_outdated(message)
|
|
76
|
+
return not _NOT_THE_MODEL.search(message or "") and not client_outdated(message) and not network_failed(message)
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
# How screenshots go to Copilot while requests carrying them do not get through (`screenshot_level`): kept like a model's
|
|
80
|
+
# health, by these names, for COOLDOWN_S, then screenshots go as they are again.
|
|
81
|
+
SMALLER_SHOTS = "screenshots:smaller"
|
|
82
|
+
NO_SHOTS = "screenshots:none"
|
|
83
|
+
SHOT_LEVELS = ("as they are", "smaller", "not at all")
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
def screenshot_level(health: "ModelHealth") -> int:
|
|
87
|
+
"""0: screenshots as they are; 1: smaller (one side at most SMALL_SIDE, JPEG); 2: none, the page's text only."""
|
|
88
|
+
if not health.healthy(NO_SHOTS):
|
|
89
|
+
return 2
|
|
90
|
+
if not health.healthy(SMALLER_SHOTS):
|
|
91
|
+
return 1
|
|
92
|
+
return 0
|
|
93
|
+
|
|
94
|
+
|
|
95
|
+
def screenshots_failed(health: "ModelHealth", level: int) -> int:
|
|
96
|
+
"""A request with screenshots at `level` could not be sent: the next ones go one level down. Returns the new level."""
|
|
97
|
+
if level >= 2:
|
|
98
|
+
return 2
|
|
99
|
+
health.fail(NO_SHOTS if level == 1 else SMALLER_SHOTS)
|
|
100
|
+
return level + 1
|
|
65
101
|
|
|
66
102
|
|
|
67
103
|
def health_file() -> str:
|
package/py/forgeqe_engine/llm.py
CHANGED
|
@@ -255,10 +255,17 @@ class ModelFailures:
|
|
|
255
255
|
self.timeout_s = timeout_s
|
|
256
256
|
self.count = 0
|
|
257
257
|
self.reason = ""
|
|
258
|
+
# Failures after which the gateway changed what the next request sends (another model, a smaller screenshot or
|
|
259
|
+
# none): each gives one more try, at most MAX_ROOM, so a run is not stopped just before the change is tried.
|
|
260
|
+
self.room = 0
|
|
261
|
+
|
|
262
|
+
MAX_ROOM = 3
|
|
263
|
+
_CHANGED = ("GitHub Copilot adjusted the next requests", "GitHub Copilot switched models")
|
|
258
264
|
|
|
259
265
|
def answered(self) -> None:
|
|
260
266
|
self.count = 0
|
|
261
267
|
self.reason = ""
|
|
268
|
+
self.room = 0
|
|
262
269
|
|
|
263
270
|
def failed(self, error: BaseException, elapsed_s: float = 0.0) -> None:
|
|
264
271
|
import asyncio
|
|
@@ -271,10 +278,12 @@ class ModelFailures:
|
|
|
271
278
|
return
|
|
272
279
|
self.count += 1
|
|
273
280
|
self.reason = reason
|
|
281
|
+
if any(w in str(getattr(error, "message", "") or error) for w in self._CHANGED):
|
|
282
|
+
self.room = min(self.MAX_ROOM, self.room + 1)
|
|
274
283
|
|
|
275
284
|
@property
|
|
276
285
|
def stuck(self) -> bool:
|
|
277
|
-
return self.count >= self.limit
|
|
286
|
+
return self.count >= self.limit + self.room
|
|
278
287
|
|
|
279
288
|
def message(self) -> str:
|
|
280
289
|
where = (
|