@goodandready/dsh-ollama-cloud-provider 0.1.22 → 0.1.23
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/CHANGELOG.md +10 -0
- package/README.md +4 -4
- package/README.ru.md +4 -4
- package/README.zh.md +4 -4
- package/lib/client.js +277 -16
- package/lib/index.d.ts +18 -0
- package/lib/index.js +101 -4
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.1.23 — 2026-11-05
|
|
4
|
+
|
|
5
|
+
- Richer model catalog rows grouped by effective context, collapsible groups,
|
|
6
|
+
drag reorder persisted as `modelOrder`, and context labels/badges.
|
|
7
|
+
- Added manual catalog entries/overrides with id, display name, context,
|
|
8
|
+
max output, vision, thinking, reasoning efforts/default and tools. Entries
|
|
9
|
+
merge over live discovery; disabled entries are hidden from the picker and
|
|
10
|
+
invalid ids are rejected.
|
|
11
|
+
- Added model grouping/reorder/render tests and manual merge tests; 128/128.
|
|
12
|
+
|
|
3
13
|
## 0.1.22 — 2026-11-05
|
|
4
14
|
|
|
5
15
|
- Added `/ollama-context` with 4k/8k/16k/32k/64k/128k presets, custom token
|
package/README.md
CHANGED
|
@@ -137,17 +137,17 @@ npm pack
|
|
|
137
137
|
Install the published package:
|
|
138
138
|
|
|
139
139
|
```bash
|
|
140
|
-
dsh plugin --profile web add @goodandready/dsh-ollama-cloud-provider@0.1.
|
|
140
|
+
dsh plugin --profile web add @goodandready/dsh-ollama-cloud-provider@0.1.23
|
|
141
141
|
# DSH Desktop:
|
|
142
|
-
dsh plugin --profile desktop add @goodandready/dsh-ollama-cloud-provider@0.1.
|
|
142
|
+
dsh plugin --profile desktop add @goodandready/dsh-ollama-cloud-provider@0.1.23
|
|
143
143
|
```
|
|
144
144
|
|
|
145
145
|
Or install the packed tarball into a profile:
|
|
146
146
|
|
|
147
147
|
```bash
|
|
148
|
-
dsh plugin --profile web add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.
|
|
148
|
+
dsh plugin --profile web add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.23.tgz
|
|
149
149
|
# DSH Desktop:
|
|
150
|
-
dsh plugin --profile desktop add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.
|
|
150
|
+
dsh plugin --profile desktop add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.23.tgz
|
|
151
151
|
```
|
|
152
152
|
|
|
153
153
|
Restart dsh (or DSH Desktop), then pick **Ollama Cloud** in the model picker.
|
package/README.ru.md
CHANGED
|
@@ -103,17 +103,17 @@ npm pack
|
|
|
103
103
|
Установка опубликованного пакета из npm:
|
|
104
104
|
|
|
105
105
|
```bash
|
|
106
|
-
dsh plugin --profile web add @goodandready/dsh-ollama-cloud-provider@0.1.
|
|
106
|
+
dsh plugin --profile web add @goodandready/dsh-ollama-cloud-provider@0.1.23
|
|
107
107
|
# DSH Desktop:
|
|
108
|
-
dsh plugin --profile desktop add @goodandready/dsh-ollama-cloud-provider@0.1.
|
|
108
|
+
dsh plugin --profile desktop add @goodandready/dsh-ollama-cloud-provider@0.1.23
|
|
109
109
|
```
|
|
110
110
|
|
|
111
111
|
Либо установка из упакованного tarball:
|
|
112
112
|
|
|
113
113
|
```bash
|
|
114
|
-
dsh plugin --profile web add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.
|
|
114
|
+
dsh plugin --profile web add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.23.tgz
|
|
115
115
|
# DSH Desktop:
|
|
116
|
-
dsh plugin --profile desktop add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.
|
|
116
|
+
dsh plugin --profile desktop add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.23.tgz
|
|
117
117
|
```
|
|
118
118
|
|
|
119
119
|
После установки перезапустите dsh (или DSH Desktop) и выберите **Ollama Cloud** в списке моделей.
|
package/README.zh.md
CHANGED
|
@@ -102,17 +102,17 @@ npm pack
|
|
|
102
102
|
从 npm 安装已发布版本:
|
|
103
103
|
|
|
104
104
|
```bash
|
|
105
|
-
dsh plugin --profile web add @goodandready/dsh-ollama-cloud-provider@0.1.
|
|
105
|
+
dsh plugin --profile web add @goodandready/dsh-ollama-cloud-provider@0.1.23
|
|
106
106
|
# DSH 桌面端:
|
|
107
|
-
dsh plugin --profile desktop add @goodandready/dsh-ollama-cloud-provider@0.1.
|
|
107
|
+
dsh plugin --profile desktop add @goodandready/dsh-ollama-cloud-provider@0.1.23
|
|
108
108
|
```
|
|
109
109
|
|
|
110
110
|
或通过打包文件安装:
|
|
111
111
|
|
|
112
112
|
```bash
|
|
113
|
-
dsh plugin --profile web add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.
|
|
113
|
+
dsh plugin --profile web add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.23.tgz
|
|
114
114
|
# DSH 桌面端:
|
|
115
|
-
dsh plugin --profile desktop add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.
|
|
115
|
+
dsh plugin --profile desktop add /absolute/path/to/goodandready-dsh-ollama-cloud-provider-0.1.23.tgz
|
|
116
116
|
```
|
|
117
117
|
|
|
118
118
|
安装完成后重启 dsh 或 DSH 桌面端,在模型列表中选择 **Ollama Cloud** 即可。
|
package/lib/client.js
CHANGED
|
@@ -124,6 +124,19 @@ window.__ModuleLoader__.load({
|
|
|
124
124
|
attemptTimeoutHint: "Whole-attempt timeout; a fresh budget is created for every retry.",
|
|
125
125
|
maxOutputTokens: "Output limit (0 = provider default)",
|
|
126
126
|
contextWindow: "Context window override",
|
|
127
|
+
contextGroup: "context",
|
|
128
|
+
dragOrder: "Drag to reorder",
|
|
129
|
+
manualModels: "Manual catalog entries",
|
|
130
|
+
manualModelsHint: "Add or override models beyond live discovery. Disabled entries stay visible here but are hidden from the picker.",
|
|
131
|
+
addManualModel: "Add model",
|
|
132
|
+
removeManualModel: "Remove entry",
|
|
133
|
+
modelId: "Model id",
|
|
134
|
+
modelName: "Display name",
|
|
135
|
+
maxTokens: "Max output tokens",
|
|
136
|
+
reasoningEfforts: "Reasoning efforts",
|
|
137
|
+
manualEffortsHint: "Comma-separated levels, e.g. off, low, medium, high.",
|
|
138
|
+
defaultReasoning: "Default effort",
|
|
139
|
+
enabled: "Enabled",
|
|
127
140
|
generation: "Generation defaults",
|
|
128
141
|
generationHint: "Native Ollama defaults. Empty fields are not sent; request options still win.",
|
|
129
142
|
temperature: "Temperature",
|
|
@@ -336,6 +349,19 @@ window.__ModuleLoader__.load({
|
|
|
336
349
|
attemptTimeoutHint: "整次尝试超时;每次重试都会创建新的预算。",
|
|
337
350
|
maxOutputTokens: "输出上限(0 = 提供方默认)",
|
|
338
351
|
contextWindow: "上下文窗口覆盖",
|
|
352
|
+
contextGroup: "上下文",
|
|
353
|
+
dragOrder: "拖动排序",
|
|
354
|
+
manualModels: "手动目录条目",
|
|
355
|
+
manualModelsHint: "在实时发现之外添加或覆盖模型。禁用条目仍在此显示,但会从选择器隐藏。",
|
|
356
|
+
addManualModel: "添加模型",
|
|
357
|
+
removeManualModel: "删除条目",
|
|
358
|
+
modelId: "模型 ID",
|
|
359
|
+
modelName: "显示名称",
|
|
360
|
+
maxTokens: "最大输出 token",
|
|
361
|
+
reasoningEfforts: "推理档位",
|
|
362
|
+
manualEffortsHint: "逗号分隔,例如 off, low, medium, high。",
|
|
363
|
+
defaultReasoning: "默认档位",
|
|
364
|
+
enabled: "启用",
|
|
339
365
|
generation: "生成默认值",
|
|
340
366
|
generationHint: "Ollama 原生默认值;空字段不发送,请求参数优先。",
|
|
341
367
|
temperature: "Temperature",
|
|
@@ -1675,6 +1701,20 @@ window.__ModuleLoader__.load({
|
|
|
1675
1701
|
stickySession: state.config.stickySession,
|
|
1676
1702
|
visibleModels: state.config.showAllModels ? allIds : [...state.config.visibleModels],
|
|
1677
1703
|
filterModelsByPlan: state.config.filterModelsByPlan,
|
|
1704
|
+
modelVisibility: { ...state.config.modelVisibility },
|
|
1705
|
+
manualModels: (state.config.manualModels ?? []).map((model) => ({
|
|
1706
|
+
id: model.id,
|
|
1707
|
+
enabled: model.enabled !== false,
|
|
1708
|
+
name: model.name ?? "",
|
|
1709
|
+
contextWindow: model.contextWindow === void 0 ? "" : String(model.contextWindow),
|
|
1710
|
+
maxTokens: model.maxTokens === void 0 ? "" : String(model.maxTokens),
|
|
1711
|
+
image: model.image === true,
|
|
1712
|
+
thinking: model.thinking === true,
|
|
1713
|
+
reasoningEfforts: (model.reasoningEfforts ?? []).join(", "),
|
|
1714
|
+
defaultReasoning: model.defaultReasoning ?? "",
|
|
1715
|
+
tools: model.tools === true
|
|
1716
|
+
})),
|
|
1717
|
+
modelOrder: [...state.config.modelOrder ?? []],
|
|
1678
1718
|
showAll: state.config.showAllModels,
|
|
1679
1719
|
modelTransports: { ...state.config.modelTransports }
|
|
1680
1720
|
};
|
|
@@ -1736,6 +1776,20 @@ window.__ModuleLoader__.load({
|
|
|
1736
1776
|
visibleModels: draft.showAll ? [] : draft.visibleModels,
|
|
1737
1777
|
showAllModels: draft.showAll,
|
|
1738
1778
|
filterModelsByPlan: draft.filterModelsByPlan,
|
|
1779
|
+
modelVisibility: draft.modelVisibility,
|
|
1780
|
+
manualModels: draft.manualModels.filter((model) => model.id.trim() !== "").map((model) => ({
|
|
1781
|
+
id: model.id.trim(),
|
|
1782
|
+
enabled: model.enabled,
|
|
1783
|
+
...model.name.trim() === "" ? {} : { name: model.name.trim() },
|
|
1784
|
+
...numberOrNull(model.contextWindow) === null ? {} : { contextWindow: numberOrNull(model.contextWindow) },
|
|
1785
|
+
...numberOrNull(model.maxTokens) === null ? {} : { maxTokens: numberOrNull(model.maxTokens) },
|
|
1786
|
+
image: model.image,
|
|
1787
|
+
thinking: model.thinking,
|
|
1788
|
+
...stopList(model.reasoningEfforts).length === 0 ? {} : { reasoningEfforts: stopList(model.reasoningEfforts) },
|
|
1789
|
+
...model.defaultReasoning.trim() === "" ? {} : { defaultReasoning: model.defaultReasoning.trim() },
|
|
1790
|
+
tools: model.tools
|
|
1791
|
+
})),
|
|
1792
|
+
modelOrder: draft.modelOrder.filter((id) => id !== ""),
|
|
1739
1793
|
modelTransports: Object.fromEntries(Object.entries(draft.modelTransports).filter(([, value]) => value !== ""))
|
|
1740
1794
|
};
|
|
1741
1795
|
}
|
|
@@ -1993,6 +2047,40 @@ window.__ModuleLoader__.load({
|
|
|
1993
2047
|
]
|
|
1994
2048
|
});
|
|
1995
2049
|
}
|
|
2050
|
+
// src/client/model-groups.ts
|
|
2051
|
+
function formatContext(value) {
|
|
2052
|
+
if (value >= 1e6) return `${(value / 1e6).toFixed(value % 1e6 === 0 ? 0 : 1)}M`;
|
|
2053
|
+
return `${Math.round(value / 1024)}K`;
|
|
2054
|
+
}
|
|
2055
|
+
/** Stable groups by effective context, richest first. */
|
|
2056
|
+
function groupModels(models, contextLabel) {
|
|
2057
|
+
const groups = /* @__PURE__ */ new Map();
|
|
2058
|
+
for (const model of models) {
|
|
2059
|
+
const existing = groups.get(model.contextWindow);
|
|
2060
|
+
if (existing !== void 0) {
|
|
2061
|
+
existing.models.push(model);
|
|
2062
|
+
continue;
|
|
2063
|
+
}
|
|
2064
|
+
groups.set(model.contextWindow, {
|
|
2065
|
+
key: String(model.contextWindow),
|
|
2066
|
+
label: `${formatContext(model.contextWindow)} ${contextLabel}`,
|
|
2067
|
+
contextWindow: model.contextWindow,
|
|
2068
|
+
models: [model]
|
|
2069
|
+
});
|
|
2070
|
+
}
|
|
2071
|
+
return [...groups.values()].sort((left, right) => right.contextWindow - left.contextWindow);
|
|
2072
|
+
}
|
|
2073
|
+
function reorderIds(order, ids, from, to) {
|
|
2074
|
+
const base = [.../* @__PURE__ */ new Set([...order, ...ids])];
|
|
2075
|
+
const source = base.indexOf(from);
|
|
2076
|
+
const target = base.indexOf(to);
|
|
2077
|
+
if (source < 0 || target < 0 || source === target) return base;
|
|
2078
|
+
const [moved] = base.splice(source, 1);
|
|
2079
|
+
if (moved === void 0) return base;
|
|
2080
|
+
const insertAt = source < target ? target - 1 : target;
|
|
2081
|
+
base.splice(insertAt, 0, moved);
|
|
2082
|
+
return base;
|
|
2083
|
+
}
|
|
1996
2084
|
// src/client/update-state.ts
|
|
1997
2085
|
function updateBadge(status) {
|
|
1998
2086
|
if (status.latestCheckFailed) return "failed";
|
|
@@ -2113,10 +2201,22 @@ window.__ModuleLoader__.load({
|
|
|
2113
2201
|
}
|
|
2114
2202
|
// src/client/settings-page.tsx
|
|
2115
2203
|
function ModelEntry(props) {
|
|
2116
|
-
const { model, visible, transport, onVisible, onTransport, t } = props;
|
|
2204
|
+
const { model, visible, transport, onVisible, onTransport, onDragStart, onDrop, dragging, t } = props;
|
|
2117
2205
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
2118
|
-
className:
|
|
2206
|
+
className: `ocl-model${dragging === true ? " ocl-dragging" : ""}`,
|
|
2207
|
+
draggable: onDragStart !== void 0,
|
|
2208
|
+
onDragStart,
|
|
2209
|
+
onDragOver: (event) => {
|
|
2210
|
+
if (onDrop !== void 0) event.preventDefault();
|
|
2211
|
+
},
|
|
2212
|
+
onDrop,
|
|
2119
2213
|
children: [
|
|
2214
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
2215
|
+
className: "ocl-drag-handle",
|
|
2216
|
+
title: t("dragOrder"),
|
|
2217
|
+
"aria-hidden": "true",
|
|
2218
|
+
children: "⋮⋮"
|
|
2219
|
+
}),
|
|
2120
2220
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
|
|
2121
2221
|
type: "checkbox",
|
|
2122
2222
|
checked: visible,
|
|
@@ -2202,6 +2302,8 @@ window.__ModuleLoader__.load({
|
|
|
2202
2302
|
const [loading, setLoading] = (0, react.useState)(true);
|
|
2203
2303
|
const [saving, setSaving] = (0, react.useState)(false);
|
|
2204
2304
|
const [search, setSearch] = (0, react.useState)("");
|
|
2305
|
+
const [dragId, setDragId] = (0, react.useState)(null);
|
|
2306
|
+
const [collapsedGroups, setCollapsedGroups] = (0, react.useState)({});
|
|
2205
2307
|
const [keyDraft, setKeyDraft] = (0, react.useState)("");
|
|
2206
2308
|
const [accountKeys, setAccountKeys] = (0, react.useState)({});
|
|
2207
2309
|
const [testModel, setTestModel] = (0, react.useState)("gpt-oss:120b");
|
|
@@ -2309,6 +2411,41 @@ window.__ModuleLoader__.load({
|
|
|
2309
2411
|
const worst = worstUsedPercent(report);
|
|
2310
2412
|
const activeAccount = state.accounts.find((account) => account.active);
|
|
2311
2413
|
const filtered = state.models.filter((model) => search.trim() === "" || model.id.toLowerCase().includes(search.trim().toLowerCase()));
|
|
2414
|
+
const groups = groupModels(filtered, t("contextGroup"));
|
|
2415
|
+
const modelIds = state.models.map((model) => model.id);
|
|
2416
|
+
const moveModel = (from, to) => {
|
|
2417
|
+
if (from === to) return;
|
|
2418
|
+
update({ modelOrder: reorderIds(draft.modelOrder, modelIds, from, to) });
|
|
2419
|
+
};
|
|
2420
|
+
const toggleGroup = (key) => {
|
|
2421
|
+
setCollapsedGroups((current) => ({
|
|
2422
|
+
...current,
|
|
2423
|
+
[key]: current[key] !== true
|
|
2424
|
+
}));
|
|
2425
|
+
};
|
|
2426
|
+
const addManualModel = () => {
|
|
2427
|
+
update({ manualModels: [...draft.manualModels, {
|
|
2428
|
+
id: "",
|
|
2429
|
+
enabled: true,
|
|
2430
|
+
name: "",
|
|
2431
|
+
contextWindow: "",
|
|
2432
|
+
maxTokens: "",
|
|
2433
|
+
image: false,
|
|
2434
|
+
thinking: false,
|
|
2435
|
+
reasoningEfforts: "",
|
|
2436
|
+
defaultReasoning: "",
|
|
2437
|
+
tools: true
|
|
2438
|
+
}] });
|
|
2439
|
+
};
|
|
2440
|
+
const updateManual = (index, patch) => {
|
|
2441
|
+
update({ manualModels: draft.manualModels.map((model, position) => position === index ? {
|
|
2442
|
+
...model,
|
|
2443
|
+
...patch
|
|
2444
|
+
} : model) });
|
|
2445
|
+
};
|
|
2446
|
+
const removeManual = (index) => {
|
|
2447
|
+
update({ manualModels: draft.manualModels.filter((_model, position) => position !== index) });
|
|
2448
|
+
};
|
|
2312
2449
|
const toggleModel = (id, visible) => {
|
|
2313
2450
|
const current = new Set(draft.visibleModels);
|
|
2314
2451
|
if (visible) current.add(id);
|
|
@@ -2923,22 +3060,142 @@ window.__ModuleLoader__.load({
|
|
|
2923
3060
|
children: filtered.length === 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
2924
3061
|
className: "ocl-hint",
|
|
2925
3062
|
children: t("modelsEmpty")
|
|
2926
|
-
}) :
|
|
2927
|
-
model,
|
|
2928
|
-
|
|
2929
|
-
|
|
2930
|
-
|
|
2931
|
-
|
|
2932
|
-
|
|
2933
|
-
|
|
2934
|
-
|
|
2935
|
-
|
|
2936
|
-
|
|
2937
|
-
|
|
2938
|
-
|
|
3063
|
+
}) : groups.map((group) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
3064
|
+
className: "ocl-model-group",
|
|
3065
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
|
|
3066
|
+
type: "button",
|
|
3067
|
+
className: "ocl-model-group-head",
|
|
3068
|
+
onClick: () => toggleGroup(group.key),
|
|
3069
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", { children: [
|
|
3070
|
+
collapsedGroups[group.key] === true ? "▸" : "▾",
|
|
3071
|
+
" ",
|
|
3072
|
+
group.label
|
|
3073
|
+
] }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
3074
|
+
className: "ocl-badge",
|
|
3075
|
+
children: group.models.length
|
|
3076
|
+
})]
|
|
3077
|
+
}), collapsedGroups[group.key] === true ? null : group.models.map((model) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ModelEntry, {
|
|
3078
|
+
model,
|
|
3079
|
+
visible: draft.showAll || draft.visibleModels.includes(model.id),
|
|
3080
|
+
transport: draft.modelTransports[model.id] ?? "",
|
|
3081
|
+
dragging: dragId === model.id,
|
|
3082
|
+
onDragStart: () => setDragId(model.id),
|
|
3083
|
+
onDrop: () => {
|
|
3084
|
+
if (dragId !== null) moveModel(dragId, model.id);
|
|
3085
|
+
setDragId(null);
|
|
3086
|
+
},
|
|
3087
|
+
onVisible: (visible) => toggleModel(model.id, visible),
|
|
3088
|
+
onTransport: (transport) => {
|
|
3089
|
+
const next = { ...draft.modelTransports };
|
|
3090
|
+
if (transport === "") delete next[model.id];
|
|
3091
|
+
else next[model.id] = transport;
|
|
3092
|
+
update({ modelTransports: next });
|
|
3093
|
+
},
|
|
3094
|
+
t
|
|
3095
|
+
}, model.id))]
|
|
3096
|
+
}, group.key))
|
|
2939
3097
|
})
|
|
2940
3098
|
]
|
|
2941
3099
|
}),
|
|
3100
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("section", {
|
|
3101
|
+
className: "ocl-card",
|
|
3102
|
+
children: [
|
|
3103
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("h3", {
|
|
3104
|
+
className: "ocl-card-title",
|
|
3105
|
+
children: [t("manualModels"), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
|
|
3106
|
+
type: "button",
|
|
3107
|
+
className: "ocl-button",
|
|
3108
|
+
onClick: addManualModel,
|
|
3109
|
+
children: t("addManualModel")
|
|
3110
|
+
})]
|
|
3111
|
+
}),
|
|
3112
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
3113
|
+
className: "ocl-hint",
|
|
3114
|
+
children: t("manualModelsHint")
|
|
3115
|
+
}),
|
|
3116
|
+
draft.manualModels.map((model, index) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
3117
|
+
className: "ocl-model-section",
|
|
3118
|
+
children: [
|
|
3119
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
3120
|
+
className: "ocl-grid",
|
|
3121
|
+
children: [
|
|
3122
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Field, {
|
|
3123
|
+
label: t("modelId"),
|
|
3124
|
+
value: model.id,
|
|
3125
|
+
onChange: (value) => updateManual(index, { id: value })
|
|
3126
|
+
}),
|
|
3127
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Field, {
|
|
3128
|
+
label: t("modelName"),
|
|
3129
|
+
value: model.name,
|
|
3130
|
+
onChange: (value) => updateManual(index, { name: value })
|
|
3131
|
+
}),
|
|
3132
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Field, {
|
|
3133
|
+
label: t("contextWindow"),
|
|
3134
|
+
type: "number",
|
|
3135
|
+
value: model.contextWindow,
|
|
3136
|
+
onChange: (value) => updateManual(index, { contextWindow: value })
|
|
3137
|
+
}),
|
|
3138
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Field, {
|
|
3139
|
+
label: t("maxTokens"),
|
|
3140
|
+
type: "number",
|
|
3141
|
+
value: model.maxTokens,
|
|
3142
|
+
onChange: (value) => updateManual(index, { maxTokens: value })
|
|
3143
|
+
}),
|
|
3144
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Field, {
|
|
3145
|
+
label: t("reasoningEfforts"),
|
|
3146
|
+
hint: t("manualEffortsHint"),
|
|
3147
|
+
value: model.reasoningEfforts,
|
|
3148
|
+
onChange: (value) => updateManual(index, { reasoningEfforts: value })
|
|
3149
|
+
}),
|
|
3150
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Field, {
|
|
3151
|
+
label: t("defaultReasoning"),
|
|
3152
|
+
value: model.defaultReasoning,
|
|
3153
|
+
onChange: (value) => updateManual(index, { defaultReasoning: value })
|
|
3154
|
+
})
|
|
3155
|
+
]
|
|
3156
|
+
}),
|
|
3157
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
|
|
3158
|
+
className: "ocl-row",
|
|
3159
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
|
|
3160
|
+
type: "checkbox",
|
|
3161
|
+
checked: model.enabled,
|
|
3162
|
+
onChange: (event) => updateManual(index, { enabled: event.target.checked })
|
|
3163
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: t("enabled") })]
|
|
3164
|
+
}),
|
|
3165
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
|
|
3166
|
+
className: "ocl-row",
|
|
3167
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
|
|
3168
|
+
type: "checkbox",
|
|
3169
|
+
checked: model.image,
|
|
3170
|
+
onChange: (event) => updateManual(index, { image: event.target.checked })
|
|
3171
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: t("vision") })]
|
|
3172
|
+
}),
|
|
3173
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
|
|
3174
|
+
className: "ocl-row",
|
|
3175
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
|
|
3176
|
+
type: "checkbox",
|
|
3177
|
+
checked: model.thinking,
|
|
3178
|
+
onChange: (event) => updateManual(index, { thinking: event.target.checked })
|
|
3179
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: t("reasoning") })]
|
|
3180
|
+
}),
|
|
3181
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
|
|
3182
|
+
className: "ocl-row",
|
|
3183
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
|
|
3184
|
+
type: "checkbox",
|
|
3185
|
+
checked: model.tools,
|
|
3186
|
+
onChange: (event) => updateManual(index, { tools: event.target.checked })
|
|
3187
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: t("tools") })]
|
|
3188
|
+
}),
|
|
3189
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
|
|
3190
|
+
type: "button",
|
|
3191
|
+
className: "ocl-button ocl-button-danger",
|
|
3192
|
+
onClick: () => removeManual(index),
|
|
3193
|
+
children: t("removeManualModel")
|
|
3194
|
+
})
|
|
3195
|
+
]
|
|
3196
|
+
}, `${model.id}-${index}`))
|
|
3197
|
+
]
|
|
3198
|
+
}),
|
|
2942
3199
|
state !== null && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LocalModelsCard, {
|
|
2943
3200
|
t,
|
|
2944
3201
|
config: state.config,
|
|
@@ -3277,7 +3534,11 @@ window.__ModuleLoader__.load({
|
|
|
3277
3534
|
.ocl-bar-fill-warn { background: var(--ocl-warning); opacity: 1; }
|
|
3278
3535
|
.ocl-bar-fill-bad { background: var(--ocl-danger); opacity: 1; }
|
|
3279
3536
|
.ocl-models { display: flex; flex-direction: column; gap: 6px; max-height: 340px; overflow: auto; padding-right: 4px; }
|
|
3280
|
-
.ocl-model { display: grid; grid-template-columns: 22px minmax(0,1fr) 120px; gap: 8px; align-items: center; font-size: 12px; padding: 3px 0; }
|
|
3537
|
+
.ocl-model { display: grid; grid-template-columns: 16px 22px minmax(0,1fr) 120px; gap: 8px; align-items: center; font-size: 12px; padding: 3px 0; }
|
|
3538
|
+
.ocl-drag-handle { cursor: grab; color: var(--ocl-text-secondary); user-select: none; }
|
|
3539
|
+
.ocl-dragging { opacity: 0.5; }
|
|
3540
|
+
.ocl-model-group { display: flex; flex-direction: column; gap: 2px; }
|
|
3541
|
+
.ocl-model-group-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; padding: 4px 0; border: 0; background: none; color: var(--ocl-text-secondary); font-size: 11px; font-weight: 650; cursor: pointer; text-align: left; }
|
|
3281
3542
|
.ocl-model-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
3282
3543
|
.ocl-model-legend { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; color: var(--ocl-text-secondary); font-size: 11px; }
|
|
3283
3544
|
.ocl-model-legend > span { display: inline-flex; align-items: center; gap: 5px; }
|
package/lib/index.d.ts
CHANGED
|
@@ -23,6 +23,18 @@ interface ModelPriceOverride {
|
|
|
23
23
|
* Plugin configuration. Every field except the literal `apiKey` is volatile:
|
|
24
24
|
* the harness projects settings forms from schema fields carrying that marker.
|
|
25
25
|
*/
|
|
26
|
+
interface ManualModel {
|
|
27
|
+
id: string;
|
|
28
|
+
enabled?: boolean;
|
|
29
|
+
name?: string;
|
|
30
|
+
contextWindow?: number;
|
|
31
|
+
maxTokens?: number;
|
|
32
|
+
image?: boolean;
|
|
33
|
+
thinking?: boolean;
|
|
34
|
+
reasoningEfforts?: string[];
|
|
35
|
+
defaultReasoning?: string;
|
|
36
|
+
tools?: boolean;
|
|
37
|
+
}
|
|
26
38
|
interface Config {
|
|
27
39
|
/** Credential reference resolved per request; defaults to `OLLAMA_API_KEY`. */
|
|
28
40
|
apiKeyEnv?: string;
|
|
@@ -52,6 +64,10 @@ interface Config {
|
|
|
52
64
|
showAllModels?: boolean;
|
|
53
65
|
/** Per-model visibility overrides; wins over `visibleModels`. */
|
|
54
66
|
modelVisibility?: Record<string, boolean>;
|
|
67
|
+
/** Manual catalog entries and overrides; merged over live discovery. */
|
|
68
|
+
manualModels?: ManualModel[];
|
|
69
|
+
/** Stable picker order; ids not listed follow by name. */
|
|
70
|
+
modelOrder?: string[];
|
|
55
71
|
/** Hide models the cloud marks unsupported in the API; defaults to true. */
|
|
56
72
|
filterModelsByPlan?: boolean;
|
|
57
73
|
/** Global context-window override. */
|
|
@@ -108,6 +124,8 @@ interface ResolvedConfig {
|
|
|
108
124
|
visibleModels: readonly string[];
|
|
109
125
|
showAllModels: boolean;
|
|
110
126
|
modelVisibility: Readonly<Record<string, boolean>>;
|
|
127
|
+
manualModels: readonly ManualModel[];
|
|
128
|
+
modelOrder: readonly string[];
|
|
111
129
|
filterModelsByPlan: boolean;
|
|
112
130
|
contextWindow?: number;
|
|
113
131
|
contextWindowOverrides: Readonly<Record<string, number>>;
|
package/lib/index.js
CHANGED
|
@@ -77,7 +77,7 @@ const DEFAULT_API_BASE = "https://ollama.com";
|
|
|
77
77
|
const DEFAULT_OPENAI_BASE = "https://ollama.com/v1";
|
|
78
78
|
const DEFAULT_USAGE_URL = "https://ollama.com/api/usage";
|
|
79
79
|
const DEFAULT_BALANCE_URL = "https://ollama.com/api/balance";
|
|
80
|
-
const DEFAULT_USER_AGENT = "dsh-ollama-cloud-provider/0.1.
|
|
80
|
+
const DEFAULT_USER_AGENT = "dsh-ollama-cloud-provider/0.1.23";
|
|
81
81
|
const DEFAULT_CONTEXT_WINDOW = 131072;
|
|
82
82
|
const DEFAULT_MAX_TOKENS = 32768;
|
|
83
83
|
const DEFAULT_GENERATE_MAX_TOKENS = 131072;
|
|
@@ -100,6 +100,19 @@ const Config = z.object({
|
|
|
100
100
|
visibleModels: markVolatile(z.array(z.string()).default([])),
|
|
101
101
|
showAllModels: markVolatile(z.boolean()),
|
|
102
102
|
modelVisibility: markVolatile(z.dict(z.boolean()).default({})),
|
|
103
|
+
manualModels: markVolatile(z.array(z.object({
|
|
104
|
+
id: z.string(),
|
|
105
|
+
enabled: z.boolean().default(true),
|
|
106
|
+
name: z.string(),
|
|
107
|
+
contextWindow: z.number().min(1).max(1e7).step(1),
|
|
108
|
+
maxTokens: z.number().min(1).max(1e7).step(1),
|
|
109
|
+
image: z.boolean(),
|
|
110
|
+
thinking: z.boolean(),
|
|
111
|
+
reasoningEfforts: z.array(z.string()),
|
|
112
|
+
defaultReasoning: z.string(),
|
|
113
|
+
tools: z.boolean()
|
|
114
|
+
})).default([])),
|
|
115
|
+
modelOrder: markVolatile(z.array(z.string()).default([])),
|
|
103
116
|
filterModelsByPlan: markVolatile(z.boolean().default(true)),
|
|
104
117
|
contextWindow: markVolatile(z.number().min(1).max(1e7).step(1)),
|
|
105
118
|
contextWindowOverrides: markVolatile(z.dict(z.number().min(1).max(1e7).step(1)).default({})),
|
|
@@ -161,6 +174,36 @@ function nonEmptyStrings(value) {
|
|
|
161
174
|
const out = value.filter((entry) => typeof entry === "string" && entry.trim() !== "");
|
|
162
175
|
return out.length === 0 ? void 0 : out;
|
|
163
176
|
}
|
|
177
|
+
function manualModelList(value) {
|
|
178
|
+
if (!Array.isArray(value)) return [];
|
|
179
|
+
const out = [];
|
|
180
|
+
for (const entry of value) {
|
|
181
|
+
if (typeof entry !== "object" || entry === null || Array.isArray(entry)) continue;
|
|
182
|
+
const record = entry;
|
|
183
|
+
const id = typeof record.id === "string" ? record.id.trim() : "";
|
|
184
|
+
if (id === "" || id.includes("..") || !/^[A-Za-z0-9][A-Za-z0-9._:/-]*$/.test(id)) continue;
|
|
185
|
+
const name = typeof record.name === "string" ? record.name.trim() : "";
|
|
186
|
+
const contextWindow = integerInRange(record.contextWindow, 1, 1e7);
|
|
187
|
+
const maxTokens = integerInRange(record.maxTokens, 1, 1e7);
|
|
188
|
+
const efforts = Array.isArray(record.reasoningEfforts) ? record.reasoningEfforts.filter((item) => typeof item === "string" && item.trim() !== "") : void 0;
|
|
189
|
+
const thinking = typeof record.thinking === "boolean" ? record.thinking : void 0;
|
|
190
|
+
const normalizedEfforts = thinking === true && (efforts === void 0 || efforts.length === 0) ? ["off", "high"] : thinking === false ? [] : efforts;
|
|
191
|
+
const defaultReasoning = typeof record.defaultReasoning === "string" && record.defaultReasoning.trim() !== "" ? record.defaultReasoning.trim() : void 0;
|
|
192
|
+
out.push({
|
|
193
|
+
id,
|
|
194
|
+
enabled: record.enabled !== false,
|
|
195
|
+
...name === "" ? {} : { name },
|
|
196
|
+
...contextWindow === void 0 ? {} : { contextWindow },
|
|
197
|
+
...maxTokens === void 0 ? {} : { maxTokens },
|
|
198
|
+
...typeof record.image === "boolean" ? { image: record.image } : {},
|
|
199
|
+
...thinking === void 0 ? {} : { thinking },
|
|
200
|
+
...normalizedEfforts === void 0 ? {} : { reasoningEfforts: normalizedEfforts },
|
|
201
|
+
...defaultReasoning === void 0 ? {} : { defaultReasoning },
|
|
202
|
+
...typeof record.tools === "boolean" ? { tools: record.tools } : {}
|
|
203
|
+
});
|
|
204
|
+
}
|
|
205
|
+
return out;
|
|
206
|
+
}
|
|
164
207
|
function recordOf$1(value) {
|
|
165
208
|
return typeof value === "object" && value !== null && !Array.isArray(value) ? value : {};
|
|
166
209
|
}
|
|
@@ -234,6 +277,8 @@ function resolveConfig(config) {
|
|
|
234
277
|
visibleModels,
|
|
235
278
|
showAllModels: config.showAllModels === true ? true : config.showAllModels === false ? false : visibleModels.length === 0,
|
|
236
279
|
modelVisibility: booleanRecord(config.modelVisibility),
|
|
280
|
+
manualModels: manualModelList(config.manualModels),
|
|
281
|
+
modelOrder: Array.isArray(config.modelOrder) ? config.modelOrder.filter((id) => typeof id === "string" && id !== "") : [],
|
|
237
282
|
filterModelsByPlan: config.filterModelsByPlan !== false,
|
|
238
283
|
...typeof config.contextWindow === "number" && Number.isInteger(config.contextWindow) && config.contextWindow > 0 ? { contextWindow: config.contextWindow } : {},
|
|
239
284
|
contextWindowOverrides: numberRecord(config.contextWindowOverrides),
|
|
@@ -1348,12 +1393,24 @@ function baseMeta(id, base) {
|
|
|
1348
1393
|
name: id
|
|
1349
1394
|
} : meta;
|
|
1350
1395
|
}
|
|
1396
|
+
function manualModelFor(id, config) {
|
|
1397
|
+
return config.manualModels.find((entry) => entry.id === id);
|
|
1398
|
+
}
|
|
1351
1399
|
function effectiveModel(id, config) {
|
|
1352
1400
|
const meta = baseMeta(id, config.apiBase);
|
|
1401
|
+
const manual = manualModelFor(id, config);
|
|
1353
1402
|
return {
|
|
1354
1403
|
...meta,
|
|
1404
|
+
name: manual?.name ?? meta.name,
|
|
1355
1405
|
transport: config.modelTransports[id] ?? config.transport,
|
|
1356
|
-
contextWindow: config.contextWindowOverrides[id] ?? config.contextWindow ?? meta.contextWindow
|
|
1406
|
+
contextWindow: config.contextWindowOverrides[id] ?? manual?.contextWindow ?? config.contextWindow ?? meta.contextWindow,
|
|
1407
|
+
maxTokens: manual?.maxTokens ?? meta.maxTokens,
|
|
1408
|
+
input: manual?.image === true ? ["text", "image"] : manual?.image === false ? ["text"] : meta.input,
|
|
1409
|
+
reasoning: manual?.reasoningEfforts ?? meta.reasoning,
|
|
1410
|
+
reasoningToggle: manual?.thinking ?? meta.reasoningToggle,
|
|
1411
|
+
...(manual?.defaultReasoning ?? meta.defaultReasoning) === void 0 ? {} : { defaultReasoning: manual?.defaultReasoning ?? meta.defaultReasoning },
|
|
1412
|
+
tools: manual?.tools ?? meta.tools,
|
|
1413
|
+
available: manual?.enabled === false ? false : meta.available
|
|
1357
1414
|
};
|
|
1358
1415
|
}
|
|
1359
1416
|
/** Effective per-request output default; `0` means "omit the field". */
|
|
@@ -1370,11 +1427,20 @@ function modelVisible(id, config) {
|
|
|
1370
1427
|
return config.visibleModels.includes(id);
|
|
1371
1428
|
}
|
|
1372
1429
|
function modelAvailable(id, config) {
|
|
1430
|
+
if (manualModelFor(id, config)?.enabled === false) return false;
|
|
1373
1431
|
if (!config.filterModelsByPlan) return true;
|
|
1374
|
-
return
|
|
1432
|
+
return effectiveModel(id, config).available !== false;
|
|
1375
1433
|
}
|
|
1376
1434
|
function sortForPicker(ids, config, unfiltered = false) {
|
|
1435
|
+
const order = new Map([...config.modelOrder.map((id, index) => [id, index]), ...config.visibleModels.map((id, index) => [id, config.modelOrder.length + index])]);
|
|
1377
1436
|
return ids.filter((id) => unfiltered || modelVisible(id, config) && modelAvailable(id, config)).sort((left, right) => {
|
|
1437
|
+
const leftOrder = order.get(left);
|
|
1438
|
+
const rightOrder = order.get(right);
|
|
1439
|
+
if (leftOrder !== void 0 || rightOrder !== void 0) {
|
|
1440
|
+
if (leftOrder === void 0) return 1;
|
|
1441
|
+
if (rightOrder === void 0) return -1;
|
|
1442
|
+
if (leftOrder !== rightOrder) return leftOrder - rightOrder;
|
|
1443
|
+
}
|
|
1378
1444
|
const a = effectiveModel(left, config);
|
|
1379
1445
|
const b = effectiveModel(right, config);
|
|
1380
1446
|
if (a.free !== b.free) return a.free ? -1 : 1;
|
|
@@ -2755,7 +2821,8 @@ var OllamaCloudAdapter = class extends LlmAdapter {
|
|
|
2755
2821
|
}
|
|
2756
2822
|
async listModels(provider, opts) {
|
|
2757
2823
|
const config = this.deps.config();
|
|
2758
|
-
|
|
2824
|
+
const discovered = await refreshCatalog(config, this.fetchImpl);
|
|
2825
|
+
return sortForPicker([.../* @__PURE__ */ new Set([...discovered, ...config.manualModels.map((model) => model.id)])], config, opts?.unfiltered === true).map((id) => {
|
|
2759
2826
|
const model = effectiveModel(id, config);
|
|
2760
2827
|
return {
|
|
2761
2828
|
provider,
|
|
@@ -4457,6 +4524,8 @@ function publicConfig(config) {
|
|
|
4457
4524
|
visibleModels: config.visibleModels,
|
|
4458
4525
|
showAllModels: config.showAllModels,
|
|
4459
4526
|
modelVisibility: config.modelVisibility,
|
|
4527
|
+
manualModels: config.manualModels,
|
|
4528
|
+
modelOrder: config.modelOrder,
|
|
4460
4529
|
filterModelsByPlan: config.filterModelsByPlan,
|
|
4461
4530
|
contextWindow: config.contextWindow ?? null,
|
|
4462
4531
|
contextWindowOverrides: config.contextWindowOverrides,
|
|
@@ -4573,6 +4642,32 @@ function cleanModelAccountRules(value) {
|
|
|
4573
4642
|
}
|
|
4574
4643
|
return out;
|
|
4575
4644
|
}
|
|
4645
|
+
function cleanManualModels(value) {
|
|
4646
|
+
if (!Array.isArray(value)) return [];
|
|
4647
|
+
const out = [];
|
|
4648
|
+
for (const entry of value) {
|
|
4649
|
+
if (typeof entry !== "object" || entry === null || Array.isArray(entry)) continue;
|
|
4650
|
+
const record = entry;
|
|
4651
|
+
const id = typeof record.id === "string" ? record.id.trim() : "";
|
|
4652
|
+
if (id === "" || id.includes("..") || !/^[A-Za-z0-9][A-Za-z0-9._:/-]*$/.test(id)) continue;
|
|
4653
|
+
const efforts = Array.isArray(record.reasoningEfforts) ? record.reasoningEfforts.filter((item) => typeof item === "string" && item.trim() !== "") : void 0;
|
|
4654
|
+
const thinking = typeof record.thinking === "boolean" ? record.thinking : void 0;
|
|
4655
|
+
const normalizedEfforts = thinking === true && (efforts === void 0 || efforts.length === 0) ? ["off", "high"] : thinking === false ? [] : efforts;
|
|
4656
|
+
out.push({
|
|
4657
|
+
id,
|
|
4658
|
+
enabled: record.enabled !== false,
|
|
4659
|
+
...typeof record.name === "string" && record.name.trim() !== "" ? { name: record.name.trim() } : {},
|
|
4660
|
+
...typeof record.contextWindow === "number" && Number.isInteger(record.contextWindow) && record.contextWindow > 0 ? { contextWindow: record.contextWindow } : {},
|
|
4661
|
+
...typeof record.maxTokens === "number" && Number.isInteger(record.maxTokens) && record.maxTokens > 0 ? { maxTokens: record.maxTokens } : {},
|
|
4662
|
+
...typeof record.image === "boolean" ? { image: record.image } : {},
|
|
4663
|
+
...thinking === void 0 ? {} : { thinking },
|
|
4664
|
+
...normalizedEfforts === void 0 ? {} : { reasoningEfforts: normalizedEfforts },
|
|
4665
|
+
...typeof record.defaultReasoning === "string" && record.defaultReasoning.trim() !== "" ? { defaultReasoning: record.defaultReasoning.trim() } : {},
|
|
4666
|
+
...typeof record.tools === "boolean" ? { tools: record.tools } : {}
|
|
4667
|
+
});
|
|
4668
|
+
}
|
|
4669
|
+
return out;
|
|
4670
|
+
}
|
|
4576
4671
|
function cleanBooleanRecord(value) {
|
|
4577
4672
|
if (typeof value !== "object" || value === null || Array.isArray(value)) return {};
|
|
4578
4673
|
const out = {};
|
|
@@ -4798,6 +4893,8 @@ function configOps(patch) {
|
|
|
4798
4893
|
if ("visibleModels" in patch) set("visibleModels", cleanStringArray(patch.visibleModels));
|
|
4799
4894
|
if ("showAllModels" in patch) set("showAllModels", patch.showAllModels === true);
|
|
4800
4895
|
if ("modelVisibility" in patch) set("modelVisibility", cleanBooleanRecord(patch.modelVisibility));
|
|
4896
|
+
if ("manualModels" in patch) set("manualModels", cleanManualModels(patch.manualModels));
|
|
4897
|
+
if ("modelOrder" in patch) set("modelOrder", cleanStringArray(patch.modelOrder));
|
|
4801
4898
|
if ("filterModelsByPlan" in patch) set("filterModelsByPlan", patch.filterModelsByPlan === true);
|
|
4802
4899
|
if ("contextWindow" in patch) set("contextWindow", patch.contextWindow);
|
|
4803
4900
|
if ("contextWindowOverrides" in patch) set("contextWindowOverrides", cleanNumberRecord(patch.contextWindowOverrides));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@goodandready/dsh-ollama-cloud-provider",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.23",
|
|
4
4
|
"description": "Ollama Cloud LLM provider plugin for DeepSeek Harness (dsh).",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
"build": "tsdown",
|
|
74
74
|
"prepare": "tsdown 1>&2",
|
|
75
75
|
"typecheck": "tsc --noEmit",
|
|
76
|
-
"test": "node --import tsx --test tests/core.test.ts tests/usage.test.ts tests/adapter.test.ts tests/routes.test.ts tests/native.test.ts tests/openai-chat.test.ts tests/commands.test.ts tests/tui-settings.test.ts tests/analytics.test.ts tests/apply.test.ts tests/account-rules.test.ts tests/request-log.test.ts tests/image-budget.test.ts tests/tool-schema.test.ts tests/tools.test.ts tests/plugin-updater.test.ts tests/compat.test.ts tests/status.test.ts tests/settings-draft.test.ts tests/update-state.test.ts tests/ui-render.test.tsx tests/update-card-view.test.tsx tests/web.test.ts tests/mock-ollama.test.ts tests/local.test.ts tests/reasoning.test.ts tests/catalog-cache.test.ts tests/local-models.test.ts tests/attempt.test.ts",
|
|
76
|
+
"test": "node --import tsx --test tests/core.test.ts tests/usage.test.ts tests/adapter.test.ts tests/routes.test.ts tests/native.test.ts tests/openai-chat.test.ts tests/commands.test.ts tests/tui-settings.test.ts tests/analytics.test.ts tests/apply.test.ts tests/account-rules.test.ts tests/request-log.test.ts tests/image-budget.test.ts tests/tool-schema.test.ts tests/tools.test.ts tests/plugin-updater.test.ts tests/compat.test.ts tests/status.test.ts tests/settings-draft.test.ts tests/update-state.test.ts tests/ui-render.test.tsx tests/update-card-view.test.tsx tests/web.test.ts tests/mock-ollama.test.ts tests/local.test.ts tests/reasoning.test.ts tests/catalog-cache.test.ts tests/local-models.test.ts tests/attempt.test.ts tests/model-groups.test.tsx",
|
|
77
77
|
"check": "npm run typecheck && npm test && npm run build",
|
|
78
78
|
"release": "npm run check && npm pack",
|
|
79
79
|
"sync:models": "node scripts/sync-models.mjs"
|