@darknesskiller/opencode-cliproxyapi 0.2.0 → 0.2.1
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 +13 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +12 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,17 @@ All notable changes to this project are documented here.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/)
|
|
6
6
|
and this project follows [Semantic Versioning](https://semver.org/).
|
|
7
7
|
|
|
8
|
+
## [0.2.1] - 2026-09-09
|
|
9
|
+
|
|
10
|
+
### Fixed
|
|
11
|
+
|
|
12
|
+
- Stop OpenCode from adding its own default reasoning efforts on top of the
|
|
13
|
+
server-reported ones. OpenCode merges per-model default variants
|
|
14
|
+
(e.g. `medium` for OpenAI-compatible models) with the plugin's variants, so
|
|
15
|
+
models configured on CLIProxyAPI with only `low`/`high`/`max` used to show
|
|
16
|
+
`low`/`medium`/`high`/`max` in the picker. Unreported default efforts are
|
|
17
|
+
now disabled and the picker shows exactly the server-supported set.
|
|
18
|
+
|
|
8
19
|
## [0.2.0] - 2026-09-09
|
|
9
20
|
|
|
10
21
|
### Added
|
|
@@ -52,7 +63,8 @@ and this project follows [Semantic Versioning](https://semver.org/).
|
|
|
52
63
|
- Automatic model names and capability hints in OpenCode's model picker.
|
|
53
64
|
- Local plugin and npm package installation flows.
|
|
54
65
|
|
|
55
|
-
[Unreleased]: https://github.com/DarknessKiller/opencode-cliproxyapi/compare/v0.2.
|
|
66
|
+
[Unreleased]: https://github.com/DarknessKiller/opencode-cliproxyapi/compare/v0.2.1...HEAD
|
|
67
|
+
[0.2.1]: https://github.com/DarknessKiller/opencode-cliproxyapi/compare/v0.2.0...v0.2.1
|
|
56
68
|
[0.2.0]: https://github.com/DarknessKiller/opencode-cliproxyapi/compare/v0.1.2...v0.2.0
|
|
57
69
|
[0.1.2]: https://github.com/DarknessKiller/opencode-cliproxyapi/compare/v0.1.1...v0.1.2
|
|
58
70
|
[0.1.1]: https://github.com/DarknessKiller/opencode-cliproxyapi/compare/v0.1.0...v0.1.1
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAU,MAAM,EAA+B,MAAM,qBAAqB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAU,MAAM,EAA+B,MAAM,qBAAqB,CAAA;AAmCtF,eAAO,MAAM,iBAAiB,EAAE,MA8E/B,CAAA;;;;;AAED,wBAGwB;AACxB,OAAO,EACL,sBAAsB,EACtB,cAAc,EACd,wBAAwB,EACxB,gBAAgB,EAChB,YAAY,EACZ,yBAAyB,EACzB,2BAA2B,GAC5B,MAAM,cAAc,CAAA;AACrB,YAAY,EAAE,YAAY,EAAE,oBAAoB,EAAE,sBAAsB,EAAE,MAAM,cAAc,CAAA"}
|
package/dist/index.js
CHANGED
|
@@ -231,9 +231,20 @@ function reasoningEffortConfig(model, input) {
|
|
|
231
231
|
const defaultLevel = efforts.defaultLevel !== undefined && efforts.levels.includes(efforts.defaultLevel) ? efforts.defaultLevel : undefined;
|
|
232
232
|
return {
|
|
233
233
|
...defaultLevel ? { options: { reasoningEffort: defaultLevel } } : {},
|
|
234
|
-
variants:
|
|
234
|
+
variants: {
|
|
235
|
+
...Object.fromEntries(efforts.levels.map((level) => [level, { reasoningEffort: level }])),
|
|
236
|
+
...disabledVariants(efforts.levels)
|
|
237
|
+
}
|
|
235
238
|
};
|
|
236
239
|
}
|
|
240
|
+
var OPENCODE_DEFAULT_EFFORTS = ["none", "minimal", "low", "medium", "high", "xhigh", "max", "ultra"];
|
|
241
|
+
function disabledVariants(supported) {
|
|
242
|
+
const supportedSet = new Set(supported);
|
|
243
|
+
return Object.fromEntries(OPENCODE_DEFAULT_EFFORTS.filter((effort) => !supportedSet.has(effort)).map((effort) => [
|
|
244
|
+
effort,
|
|
245
|
+
{ disabled: true }
|
|
246
|
+
]));
|
|
247
|
+
}
|
|
237
248
|
function resolveModelNpm(catalog, providerID, modelID) {
|
|
238
249
|
const provider = catalog[providerID];
|
|
239
250
|
return provider?.models[modelID] ?? provider?.npm;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/package.json",
|
|
3
3
|
"name": "@darknesskiller/opencode-cliproxyapi",
|
|
4
|
-
"version": "0.2.
|
|
4
|
+
"version": "0.2.1",
|
|
5
5
|
"description": "Fork of opencode-cliproxyapi that discovers CLIProxyAPI models and auto-configures reasoning-effort variants in OpenCode.",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"license": "MIT",
|