@expiren/opencode-antigravity-auth 1.6.37 → 1.6.38
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/index.js +2 -14
- package/dist/index.js.map +2 -2
- package/dist/src/plugin/request.d.ts.map +1 -1
- package/dist/src/plugin/request.js +1 -13
- package/dist/src/plugin/request.js.map +1 -1
- package/dist/src/plugin.d.ts.map +1 -1
- package/dist/src/plugin.js +3 -4
- package/dist/src/plugin.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -8155,21 +8155,9 @@ async function transformAntigravityResponse(response, streaming, debugContext, r
|
|
|
8155
8155
|
effectiveModel,
|
|
8156
8156
|
usage.cachedContentTokenCount,
|
|
8157
8157
|
0,
|
|
8158
|
-
usage.promptTokenCount
|
|
8158
|
+
usage.promptTokenCount ?? usage.totalTokenCount
|
|
8159
8159
|
);
|
|
8160
8160
|
}
|
|
8161
|
-
if (usage.cachedContentTokenCount !== void 0) {
|
|
8162
|
-
headers.set("x-antigravity-cached-content-token-count", String(usage.cachedContentTokenCount));
|
|
8163
|
-
}
|
|
8164
|
-
if (usage.totalTokenCount !== void 0) {
|
|
8165
|
-
headers.set("x-antigravity-total-token-count", String(usage.totalTokenCount));
|
|
8166
|
-
}
|
|
8167
|
-
if (usage.promptTokenCount !== void 0) {
|
|
8168
|
-
headers.set("x-antigravity-prompt-token-count", String(usage.promptTokenCount));
|
|
8169
|
-
}
|
|
8170
|
-
if (usage.candidatesTokenCount !== void 0) {
|
|
8171
|
-
headers.set("x-antigravity-candidates-token-count", String(usage.candidatesTokenCount));
|
|
8172
|
-
}
|
|
8173
8161
|
},
|
|
8174
8162
|
transformThinkingParts
|
|
8175
8163
|
},
|
|
@@ -12649,6 +12637,7 @@ var createAntigravityPlugin = (providerId) => async ({ client, directory }) => {
|
|
|
12649
12637
|
);
|
|
12650
12638
|
}
|
|
12651
12639
|
};
|
|
12640
|
+
let apiRequestCount = 0;
|
|
12652
12641
|
let shouldSwitchAccount = false;
|
|
12653
12642
|
let headerStyle = preferredHeaderStyle;
|
|
12654
12643
|
pushDebug(`headerStyle=${headerStyle} explicit=${explicitQuota}`);
|
|
@@ -12706,7 +12695,6 @@ var createAntigravityPlugin = (providerId) => async ({ client, directory }) => {
|
|
|
12706
12695
|
let tokenConsumed = false;
|
|
12707
12696
|
let capacityRetryCount = 0;
|
|
12708
12697
|
let lastEndpointIndex = -1;
|
|
12709
|
-
let apiRequestCount = 0;
|
|
12710
12698
|
for (let i = 0; i < ANTIGRAVITY_ENDPOINT_FALLBACKS.length; i++) {
|
|
12711
12699
|
if (i !== lastEndpointIndex) {
|
|
12712
12700
|
capacityRetryCount = 0;
|