dsh-agy-link 0.2.4 → 0.2.5

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.
Files changed (2) hide show
  1. package/dist/index.js +88 -19
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -10,10 +10,18 @@ import { randomBytes } from "node:crypto";
10
10
  import { fileURLToPath } from "node:url";
11
11
  //#region src/common/types.ts
12
12
  const PROVIDER_ID = "antigravity";
13
- const PLUGIN_ID = "agy-link";
14
13
  const DEFAULT_FALLBACK_MODELS = [
15
14
  {
16
- id: "gemini-3-6-flash",
15
+ id: "gemini-3.7-flash",
16
+ name: "Gemini 3.7 Flash",
17
+ efforts: [
18
+ "low",
19
+ "medium",
20
+ "high"
21
+ ]
22
+ },
23
+ {
24
+ id: "gemini-3.6-flash",
17
25
  name: "Gemini 3.6 Flash",
18
26
  efforts: [
19
27
  "low",
@@ -22,13 +30,80 @@ const DEFAULT_FALLBACK_MODELS = [
22
30
  ]
23
31
  },
24
32
  {
25
- id: "gemini-3-1-pro",
33
+ id: "gemini-3.5-flash",
34
+ name: "Gemini 3.5 Flash",
35
+ efforts: [
36
+ "low",
37
+ "medium",
38
+ "high"
39
+ ]
40
+ },
41
+ {
42
+ id: "gemini-3.1-pro",
26
43
  name: "Gemini 3.1 Pro",
27
44
  efforts: ["low", "high"]
28
45
  },
46
+ {
47
+ id: "gemini-3.1-flash-lite",
48
+ name: "Gemini 3.1 Flash Lite"
49
+ },
50
+ {
51
+ id: "gemini-2.5-pro",
52
+ name: "Gemini 2.5 Pro",
53
+ efforts: ["low", "high"]
54
+ },
55
+ {
56
+ id: "gemini-2.5-flash",
57
+ name: "Gemini 2.5 Flash",
58
+ efforts: [
59
+ "low",
60
+ "medium",
61
+ "high"
62
+ ]
63
+ },
64
+ {
65
+ id: "gemini-2.5-flash-lite",
66
+ name: "Gemini 2.5 Flash Lite"
67
+ },
68
+ {
69
+ id: "claude-opus-4-8",
70
+ name: "Claude Opus 4.8 (Thinking)"
71
+ },
72
+ {
73
+ id: "claude-opus-4-6",
74
+ name: "Claude Opus 4.6 (Thinking)"
75
+ },
76
+ {
77
+ id: "claude-opus-4-5",
78
+ name: "Claude Opus 4.5 (Thinking)"
79
+ },
80
+ {
81
+ id: "claude-opus-4",
82
+ name: "Claude Opus 4 (Thinking)"
83
+ },
29
84
  {
30
85
  id: "claude-sonnet-4-6",
31
86
  name: "Claude Sonnet 4.6 (Thinking)"
87
+ },
88
+ {
89
+ id: "claude-sonnet-4-5",
90
+ name: "Claude Sonnet 4.5 (Thinking)"
91
+ },
92
+ {
93
+ id: "claude-sonnet-4",
94
+ name: "Claude Sonnet 4 (Thinking)"
95
+ },
96
+ {
97
+ id: "claude-haiku-4-5",
98
+ name: "Claude Haiku 4.5"
99
+ },
100
+ {
101
+ id: "gpt-oss-120b",
102
+ name: "GPT-OSS 120B"
103
+ },
104
+ {
105
+ id: "gpt-oss-20b",
106
+ name: "GPT-OSS 20B"
32
107
  }
33
108
  ];
34
109
  function defaultConfig() {
@@ -624,7 +699,12 @@ function findEntry(catalog, id) {
624
699
  function defaultEffortFor(entry, cfg) {
625
700
  if (!entry.efforts) return void 0;
626
701
  if (cfg.defaultEffort !== "" && entry.efforts.includes(cfg.defaultEffort)) return cfg.defaultEffort;
627
- return entry.efforts.includes("medium") ? "medium" : entry.efforts[entry.efforts.length - 1];
702
+ for (const pref of [
703
+ "high",
704
+ "medium",
705
+ "low"
706
+ ]) if (entry.efforts.includes(pref)) return pref;
707
+ return entry.efforts[entry.efforts.length - 1];
628
708
  }
629
709
  //#endregion
630
710
  //#region src/host/parser.ts
@@ -1787,10 +1867,12 @@ function defineAgyAskTool(deps) {
1787
1867
  throw new Error("agy_ask: schema is not valid JSON: " + String(e));
1788
1868
  }
1789
1869
  const readPaths = typeof args.readPaths === "string" && args.readPaths.trim() !== "" ? args.readPaths.split(/[ ,]+/).filter(Boolean) : [];
1870
+ const entry = findEntry(deps.catalog(), model);
1871
+ const effort = args.effort ?? (entry?.efforts ? defaultEffortFor(entry, cfg) : void 0);
1790
1872
  const res = await runAgyOnce(deps, {
1791
1873
  prompt: args.prompt,
1792
1874
  model: model === "" ? void 0 : model,
1793
- effort: args.effort,
1875
+ effort,
1794
1876
  mode: args.mode,
1795
1877
  timeoutMs: args.timeoutMinutes ? args.timeoutMinutes * 6e4 : void 0,
1796
1878
  signal: exec.signal,
@@ -2486,11 +2568,7 @@ function apply(ctx, entryConfig = {}) {
2486
2568
  const catalog = new ModelCatalog(async (signal) => {
2487
2569
  const b = bin();
2488
2570
  if (!b) throw new Error("agy binary not found");
2489
- const out = await probeProcess(b, [
2490
- "models",
2491
- "--output-format",
2492
- "json"
2493
- ], 3e4, signal);
2571
+ const out = await probeProcess(b, ["models"], 3e4, signal);
2494
2572
  if (out.code !== 0 && out.stdout.trim() === "") throw new Error("agy models failed: " + (out.stderrTail.trim() !== "" ? out.stderrTail.trim().slice(-200) : "exit " + String(out.code)));
2495
2573
  return {
2496
2574
  stdout: out.stdout,
@@ -2566,15 +2644,6 @@ function apply(ctx, entryConfig = {}) {
2566
2644
  } catch (e) {
2567
2645
  log("adapter registration failed: " + String(e));
2568
2646
  }
2569
- try {
2570
- ctx.llm.registerConfigurableProviders([{
2571
- provider: PROVIDER_ID,
2572
- displayName: "Antigravity (agy CLI)",
2573
- settingsNs: PLUGIN_ID,
2574
- settingsPath: [],
2575
- declared: false
2576
- }]);
2577
- } catch {}
2578
2647
  ctx.commands.register(agyCommandDefinition({
2579
2648
  cfg: getConfig,
2580
2649
  bin,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-agy-link",
3
- "version": "0.2.4",
3
+ "version": "0.2.5",
4
4
  "description": "Google Antigravity (agy CLI) models for DeepSeek Harness — stream Gemini/Claude/GPT-OSS subscriptions into DSH with thinking, tool activity, token usage and in-GUI Google OAuth login.",
5
5
  "type": "module",
6
6
  "license": "MIT",