@caishenai/cli 0.0.172 → 0.0.173
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.
|
@@ -1939,6 +1939,46 @@
|
|
|
1939
1939
|
"name": "Gemini 4 Argon",
|
|
1940
1940
|
"recommended": false
|
|
1941
1941
|
},
|
|
1942
|
+
{
|
|
1943
|
+
"capabilities": {
|
|
1944
|
+
"contextWindowTokens": 1048576,
|
|
1945
|
+
"functionCall": true,
|
|
1946
|
+
"imageOutput": false,
|
|
1947
|
+
"inputModalities": [
|
|
1948
|
+
"text",
|
|
1949
|
+
"image",
|
|
1950
|
+
"video",
|
|
1951
|
+
"audio"
|
|
1952
|
+
],
|
|
1953
|
+
"knowledgeCutoff": "2026-03-31",
|
|
1954
|
+
"maxOutput": 65536,
|
|
1955
|
+
"outputModalities": [
|
|
1956
|
+
"text"
|
|
1957
|
+
],
|
|
1958
|
+
"reasoning": true,
|
|
1959
|
+
"reasoningEfforts": [
|
|
1960
|
+
"low",
|
|
1961
|
+
"medium",
|
|
1962
|
+
"high"
|
|
1963
|
+
],
|
|
1964
|
+
"structuredOutput": true,
|
|
1965
|
+
"video": true,
|
|
1966
|
+
"vision": true
|
|
1967
|
+
},
|
|
1968
|
+
"context_window": 1048576,
|
|
1969
|
+
"description": "100 万上下文 | 前沿推理 | 长程 Agent",
|
|
1970
|
+
"endpoint_types": [
|
|
1971
|
+
"gemini",
|
|
1972
|
+
"openai"
|
|
1973
|
+
],
|
|
1974
|
+
"group": "",
|
|
1975
|
+
"group_name": "",
|
|
1976
|
+
"hidden": false,
|
|
1977
|
+
"id": "gemini-4-carbon",
|
|
1978
|
+
"max_output_tokens": 65536,
|
|
1979
|
+
"name": "Gemini 4 Carbon",
|
|
1980
|
+
"recommended": false
|
|
1981
|
+
},
|
|
1942
1982
|
{
|
|
1943
1983
|
"capabilities": {
|
|
1944
1984
|
"contextWindowTokens": 1048576,
|
|
@@ -2180,7 +2220,7 @@
|
|
|
2180
2220
|
"tool": "gemini"
|
|
2181
2221
|
}
|
|
2182
2222
|
],
|
|
2183
|
-
"revision": "2026-11-
|
|
2223
|
+
"revision": "2026-11-10T18:59:17Z-15",
|
|
2184
2224
|
"schema": 1,
|
|
2185
2225
|
"tools": {
|
|
2186
2226
|
"claude": {
|
|
@@ -1939,6 +1939,46 @@
|
|
|
1939
1939
|
"name": "Gemini 4 Argon",
|
|
1940
1940
|
"recommended": false
|
|
1941
1941
|
},
|
|
1942
|
+
{
|
|
1943
|
+
"capabilities": {
|
|
1944
|
+
"contextWindowTokens": 1048576,
|
|
1945
|
+
"functionCall": true,
|
|
1946
|
+
"imageOutput": false,
|
|
1947
|
+
"inputModalities": [
|
|
1948
|
+
"text",
|
|
1949
|
+
"image",
|
|
1950
|
+
"video",
|
|
1951
|
+
"audio"
|
|
1952
|
+
],
|
|
1953
|
+
"knowledgeCutoff": "2026-03-31",
|
|
1954
|
+
"maxOutput": 65536,
|
|
1955
|
+
"outputModalities": [
|
|
1956
|
+
"text"
|
|
1957
|
+
],
|
|
1958
|
+
"reasoning": true,
|
|
1959
|
+
"reasoningEfforts": [
|
|
1960
|
+
"low",
|
|
1961
|
+
"medium",
|
|
1962
|
+
"high"
|
|
1963
|
+
],
|
|
1964
|
+
"structuredOutput": true,
|
|
1965
|
+
"video": true,
|
|
1966
|
+
"vision": true
|
|
1967
|
+
},
|
|
1968
|
+
"context_window": 1048576,
|
|
1969
|
+
"description": "100 万上下文 | 前沿推理 | 长程 Agent",
|
|
1970
|
+
"endpoint_types": [
|
|
1971
|
+
"gemini",
|
|
1972
|
+
"openai"
|
|
1973
|
+
],
|
|
1974
|
+
"group": "",
|
|
1975
|
+
"group_name": "",
|
|
1976
|
+
"hidden": false,
|
|
1977
|
+
"id": "gemini-4-carbon",
|
|
1978
|
+
"max_output_tokens": 65536,
|
|
1979
|
+
"name": "Gemini 4 Carbon",
|
|
1980
|
+
"recommended": false
|
|
1981
|
+
},
|
|
1942
1982
|
{
|
|
1943
1983
|
"capabilities": {
|
|
1944
1984
|
"contextWindowTokens": 1048576,
|
|
@@ -2180,7 +2220,7 @@
|
|
|
2180
2220
|
"tool": "gemini"
|
|
2181
2221
|
}
|
|
2182
2222
|
],
|
|
2183
|
-
"revision": "2026-11-
|
|
2223
|
+
"revision": "2026-11-10T18:59:17Z-15",
|
|
2184
2224
|
"schema": 1,
|
|
2185
2225
|
"tools": {
|
|
2186
2226
|
"claude": {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{chmodSync as t,existsSync as r,readFileSync as e}from"fs";import{join as n}from"path";import{i18n as o}from"../i18n.js";import{prettyModelName as i}from"../gateway-models.js";import{getAgyRules as a}from"../model-registry.js";import{logger as l}from"../../utils/logger.js";import{readPersistentEnvFile as s,removePersistentEnv as c,writePersistentEnv as u}from"../persistent-env.js";import{backupBeforeWrite as p,atomicWriteFile as
|
|
1
|
+
import{chmodSync as t,existsSync as r,readFileSync as e}from"fs";import{join as n}from"path";import{i18n as o}from"../i18n.js";import{prettyModelName as i}from"../gateway-models.js";import{getAgyRules as a}from"../model-registry.js";import{logger as l}from"../../utils/logger.js";import{readPersistentEnvFile as s,removePersistentEnv as c,writePersistentEnv as u}from"../persistent-env.js";import{backupBeforeWrite as p,atomicWriteFile as m}from"./backup.js";import{findInstalls as d,mirrorInstallCommand as g}from"./tool-installs.js";import{toolHome as y}from"./types.js";import{brand as f,PROVIDER_KEY as h}from"../brand.js";const v="agy",A="AGY_LLM_GATEWAY_URL",_="AGY_LLM_GATEWAY_API_KEY",E="AGY_LLM_GATEWAY_MODELS",j=["GEMINI_API_KEY","GOOGLE_GEMINI_BASE_URL"],w="gemini",K=()=>n(y(),".gemini","antigravity-cli"),b=()=>n(K(),"settings.json"),I=()=>n(K(),`${h}.env`),P=()=>n(y(),".antigravity","settings.json"),M=f().installMirror?.agy,G={command:"agy",native:{binDir:"win32"===process.platform?["AppData","Local","agy","bin"]:[".local","bin"],updateArgs:["update"],dataDirs:[]},...M?{mirrorScript:{sh:`${M}/install.sh`,ps1:`${M}/install.ps1`}}:{}};function L(t){return!!t&&"object"==typeof t&&!Array.isArray(t)}function $(t,n){if(!r(t))return{};const o=e(t,"utf-8");if(!o.trim())return{};try{const t=JSON.parse(o);if(!L(t))throw new Error(`${n} root must be an object`);return t}catch(t){throw new Error(`Existing ${n} cannot be parsed; back it up and fix it first: ${t instanceof Error?t.message:String(t)}`)}}const C=()=>$(b(),"~/.gemini/antigravity-cli/settings.json"),N=()=>$(P(),"~/.antigravity/settings.json");function S(r,e,n){p(r),m(r,JSON.stringify(e,null,2)+"\n",n),void 0!==n&&t(r,n)}function Y(t){return(t||"").replace(/\/+$/,"").replace(/\/v1(beta)?$/,"")}const x=/-(minimal|low|medium|high|xhigh|max)$/;function k(t){const r=a().gatewayModels,e=t?r.filter(r=>t.models.includes(r)||t.models.includes(r.replace(x,""))):[];return e.length>0?e:r}function O(t){const r=t.replace(/-preview$/,""),e=x.exec(r)?.[1];return e?`${i(r.replace(x,""))} (${e[0].toUpperCase()}${e.slice(1)})`:i(r)}function U(t){const r=t.gateway;return L(r)&&!0===r.enabled&&"string"==typeof r.apiKey&&r.apiKey.trim()&&"string"==typeof r.url?{url:r.url,apiKey:r.apiKey}:null}function D(t){const r=t.models;return L(r)&&Array.isArray(r.list)?r.list.map(t=>L(t)&&"string"==typeof t.modelId?t.modelId:"").filter(Boolean):[]}function R(){try{if(C().modelProvider!==w)return null}catch{return null}const t=s(I()),r=t.GEMINI_API_KEY;return r&&r.trim()?{apiKey:r,url:t.GOOGLE_GEMINI_BASE_URL??""}:null}function T(t){const r=s(I());return r[A]===t.url&&r[_]===t.apiKey}function B(t,r,e){const n=C(),o=N();o.gateway={...L(o.gateway)?o.gateway:{},enabled:!0,url:r,apiKey:t,wireProtocol:"genai"},o.models={...L(o.models)?o.models:{},defaultModelId:e[0],list:e.map(t=>({modelId:t,displayName:O(t),supportsThinking:!0}))},S(P(),o,384),j.some(t=>void 0!==s(I())[t])&&c(v,I(),j);const i=u(v,I(),{[A]:r,[_]:t,[E]:e.join(",")}).rcFiles;for(const t of j)delete process.env[t];return n.modelProvider===w&&(delete n.modelProvider,S(b(),n)),i}let W=null,J=null;export const antigravityAdapter={name:"agy",displayName:"Antigravity CLI",command:"agy",installCommand:g(G),installSpec:G,configPath:P(),wantsModelCatalog:!0,loadPrivateConfig(t){C(),N();const r=k(t.catalog);W=B(t.apiKey,Y(t.baseUrl),r),J=r},unloadPrivateConfig(){try{const t=N();U(t)&&(delete t.gateway,delete t.models,S(P(),t,384))}catch(t){l.logError("antigravityAdapter.unloadPrivateConfig",t)}try{const t=C();t.modelProvider===w&&(delete t.modelProvider,S(b(),t))}catch(t){l.logError("antigravityAdapter.unloadPrivateConfig",t)}c(v,I(),[A,_,E,...j])},detectCurrentConfig(){try{const t=U(N());if(t)return{apiKey:t.apiKey}}catch{return{apiKey:null}}return{apiKey:R()?.apiKey??null}},listedModels(){try{const t=N(),r=U(t);if(r)return T(r)?D(t):[]}catch{return null}return R()?[]:null},refreshModelMenu(t){const r=N(),e=U(r)??R();if(!e)return;const n=k(t.catalog),o=e.url||Y(t.baseUrl),i=U(r);null!==i&&T(i)&&D(r).join(",")===n.join(",")&&s(I())[E]===n.join(",")&&null===R()||B(e.apiKey,o,n)},getConfig(){try{return N()}catch(t){return l.logError("antigravityAdapter.getConfig",t),null}},applyNotes(){const t=[];if(J&&J.length>0){const r=J.map(O);t.push({kind:"summary",text:o.t("tools.agy.menu_written",{count:String(r.length),list:r.join(o.t("tools.grok.list_separator")),default:r[0]})})}return null===W||0===d(G).length||t.push({kind:"action",text:o.t("tools.agy.open_new_terminal")}),t},backupPaths:()=>[P(),b(),I()],forceResetPaths:()=>[I()]};
|
package/dist/models.json
CHANGED
package/models.json
CHANGED