free-coding-models 0.5.81 → 0.5.84
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 +25 -8
- package/bin/free-coding-models.js +20 -0
- package/changelog/v0.5.82.md +23 -0
- package/changelog/v0.5.83.md +22 -0
- package/changelog/v0.5.84.md +32 -0
- package/package.json +2 -2
- package/sources.js +167 -106
- package/src/core/benchmark.js +1 -1
- package/src/core/config.js +5 -0
- package/src/core/endpoint-installer.js +7 -2
- package/src/core/kilo.js +7 -0
- package/src/core/model-family.js +176 -0
- package/src/core/models-dev-index.js +1 -0
- package/src/core/opencode.js +14 -0
- package/src/core/ping.js +14 -4
- package/src/core/provider-key-tester.js +2 -1
- package/src/core/provider-metadata.js +11 -2
- package/src/core/quota-capabilities.js +1 -0
- package/src/core/router-daemon.js +47 -6
- package/src/core/router-dashboard.js +6 -1
- package/src/core/security.js +132 -65
- package/src/core/sync-set.js +1 -1
- package/src/core/tool-launchers.js +15 -5
- package/src/core/utils.js +88 -1
- package/src/data/benchmarks.json +6072 -216
- package/src/tui/app.js +7 -5
- package/src/tui/cli-help.js +4 -1
- package/src/tui/command-palette.js +3 -2
- package/src/tui/key-handler.js +172 -61
- package/src/tui/overlays.js +135 -94
- package/src/tui/render-helpers.js +42 -3
- package/src/tui/render-table.js +74 -4
- package/src/tui/theme.js +2 -0
- package/src/tui/tui-state.js +15 -1
- package/web/dist/assets/index-zdQvAW7c.js +40 -0
- package/web/dist/index.html +1 -1
- package/web/src/components/router/RouterView.jsx +38 -1
- package/web/dist/assets/index-Bb5I0K1-.js +0 -40
package/web/dist/index.html
CHANGED
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
49
49
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
50
50
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600&display=swap" rel="stylesheet">
|
|
51
|
-
<script type="module" crossorigin src="/assets/index-
|
|
51
|
+
<script type="module" crossorigin src="/assets/index-zdQvAW7c.js"></script>
|
|
52
52
|
<link rel="stylesheet" crossorigin href="/assets/index-C5-Ywvv3.css">
|
|
53
53
|
</head>
|
|
54
54
|
<body>
|
|
@@ -304,6 +304,32 @@ export default function RouterView({ onClose, onToast, favorites }) {
|
|
|
304
304
|
}
|
|
305
305
|
}
|
|
306
306
|
|
|
307
|
+
// 📖 t8 - family failover keeps the user inside the same model family when a
|
|
308
|
+
// request fails (e.g. DeepSeek on NIM -> DeepSeek on Together) instead of
|
|
309
|
+
// hopping to a different family. Per-set toggle, persisted via PUT /sets/:name.
|
|
310
|
+
const handleToggleFamilyFailover = async () => {
|
|
311
|
+
if (!activeSetName) return
|
|
312
|
+
const next = !(activeSet?.familyFailover !== false)
|
|
313
|
+
setSaveStatus(SAVE_STATUS_SAVING)
|
|
314
|
+
try {
|
|
315
|
+
const resp = await fetch(`/api/router/sets/${encodeURIComponent(activeSetName)}`, {
|
|
316
|
+
method: 'PUT',
|
|
317
|
+
headers: { 'Content-Type': 'application/json' },
|
|
318
|
+
body: JSON.stringify({ familyFailover: next }),
|
|
319
|
+
})
|
|
320
|
+
if (!resp.ok) {
|
|
321
|
+
const err = await resp.json().catch(() => ({}))
|
|
322
|
+
throw new Error(err.error || `HTTP ${resp.status}`)
|
|
323
|
+
}
|
|
324
|
+
setSaveStatus(SAVE_STATUS_SAVED)
|
|
325
|
+
onToast?.(`Family failover ${next ? 'enabled' : 'disabled'} for ${activeSetName}.`, 'info')
|
|
326
|
+
await fetchSets()
|
|
327
|
+
} catch (err) {
|
|
328
|
+
setSaveStatus(SAVE_STATUS_ERROR(err.message || String(err)))
|
|
329
|
+
onToast?.(`Failed to toggle family failover: ${err.message}`, 'error')
|
|
330
|
+
}
|
|
331
|
+
}
|
|
332
|
+
|
|
307
333
|
const persistReorder = useCallback(async (nextModels) => {
|
|
308
334
|
if (!activeSetName) return
|
|
309
335
|
setSaveStatus(SAVE_STATUS_SAVING)
|
|
@@ -716,6 +742,15 @@ export default function RouterView({ onClose, onToast, favorites }) {
|
|
|
716
742
|
))}
|
|
717
743
|
</select>
|
|
718
744
|
)}
|
|
745
|
+
<button
|
|
746
|
+
className={`${styles.smallBtn} ${(activeSet?.familyFailover !== false) ? styles.probeBtnActive : ''}`}
|
|
747
|
+
onClick={handleToggleFamilyFailover}
|
|
748
|
+
disabled={saveStatus.kind === 'saving'}
|
|
749
|
+
title="When a model fails, first retry the same family on another provider (e.g. DeepSeek on NIM -> DeepSeek on Together) before falling back to set order"
|
|
750
|
+
>
|
|
751
|
+
<IconRoute size={11} />
|
|
752
|
+
Family failover: {activeSet?.familyFailover !== false ? 'on' : 'off'}
|
|
753
|
+
</button>
|
|
719
754
|
</div>
|
|
720
755
|
<div className={styles.setActions}>
|
|
721
756
|
<SaveBadge status={saveStatus} />
|
|
@@ -1041,7 +1076,9 @@ export default function RouterView({ onClose, onToast, favorites }) {
|
|
|
1041
1076
|
</span>
|
|
1042
1077
|
<span className={styles.logDetail}>
|
|
1043
1078
|
{[
|
|
1044
|
-
|
|
1079
|
+
// 📖 t8 - a family hop stays in the same model family
|
|
1080
|
+
// (e.g. DeepSeek on another host) and is tagged as such.
|
|
1081
|
+
entry.failover ? (entry.failover_reason === 'family_failover' ? 'family' : 'failover') : '',
|
|
1045
1082
|
entry.stream ? 'stream' : '',
|
|
1046
1083
|
entry.error || '',
|
|
1047
1084
|
].filter(Boolean).join(', ')}
|