@mcowger/pi-plexus 1.1.1 → 1.2.0
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/README.md +7 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -116,7 +116,11 @@ Run inside OpenCode:
|
|
|
116
116
|
/connect
|
|
117
117
|
```
|
|
118
118
|
|
|
119
|
-
Select **Plexus** and enter your base URL and API key.
|
|
119
|
+
Select **Plexus** and enter your base URL and API key. OpenCode has no live model-discovery hook for custom providers, so the model list is seeded from the on-disk cache at startup. Run `/plexus-refresh` to force a live fetch from Plexus and rewrite the cache, then restart OpenCode to pick up the refreshed list:
|
|
120
|
+
|
|
121
|
+
```
|
|
122
|
+
/plexus-refresh
|
|
123
|
+
```
|
|
120
124
|
|
|
121
125
|
You may enter either the Plexus root URL or the `/v1` API base URL:
|
|
122
126
|
|
|
@@ -197,7 +201,7 @@ packages/
|
|
|
197
201
|
plugin.ts # Plugin export: config hook, provider hook, auth handler
|
|
198
202
|
mapper.ts # PlexusApiModel → OpenCode ConfigModel
|
|
199
203
|
cache.ts # model cache I/O
|
|
200
|
-
config-store.ts # resolveConfig,
|
|
204
|
+
config-store.ts # resolveConfig, readStoredAuth
|
|
201
205
|
log.ts # logger via OpenCode SDK
|
|
202
206
|
constants.ts # provider ID, env var names, timeouts
|
|
203
207
|
url.ts # URL helpers (trimURL, apiBase, modelsUrl)
|
|
@@ -228,7 +232,7 @@ Models with a falsy `id` are skipped. Missing metadata falls back to safe defaul
|
|
|
228
232
|
## Adapter behavior
|
|
229
233
|
|
|
230
234
|
- **pi** refreshes on session start and through `/plexus refresh`. It accepts either root URLs or URLs ending in `/v1` and normalizes them before calling Plexus.
|
|
231
|
-
- **OpenCode** seeds the provider from cache or a placeholder model during config loading
|
|
235
|
+
- **OpenCode** seeds the provider from the on-disk cache (or a placeholder model) once, during config loading — OpenCode's `provider.models` hook never fires for custom providers, so there is no live discovery at startup. Run `/plexus-refresh` to force a live fetch and rewrite the cache; because OpenCode has no way to hot-reload a custom provider's model list mid-session, a restart is required afterward to see the refreshed models in the picker.
|
|
232
236
|
- OpenCode models retain their upstream model ID, SDK dialect, release date, and reasoning metadata so OpenCode can generate its native GPT, Claude, Gemini, and OpenAI-compatible variants and apply its current request transforms. DeepSeek models also preserve `reasoning_content` across tool-call turns.
|
|
233
237
|
- OpenCode uses a 250K-token context window when Plexus supplies no context metadata; its output fallback remains 20% of that window.
|
|
234
238
|
- Both adapters convert Plexus's per-token base and tier rates to the per-million-token units expected by their host.
|