@codemem/server 0.23.0 → 0.24.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/dist/index.js +30 -1
- package/dist/index.js.map +1 -1
- package/dist/routes/config.d.ts.map +1 -1
- package/package.json +2 -2
- package/static/app.js +346 -86
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/routes/config.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAKH,OAAO,EAKN,KAAK,eAAe,EAKpB,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/routes/config.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAKH,OAAO,EAKN,KAAK,eAAe,EAKpB,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAwF5B,MAAM,WAAW,kBAAkB;IAClC,UAAU,CAAC,EAAE,MAAM,eAAe,GAAG,IAAI,CAAC;CAC1C;AA+PD,wBAAgB,YAAY,CAAC,IAAI,GAAE,kBAAuB,8EA6GzD"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codemem/server",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.24.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"types": "./dist/index.d.ts",
|
|
6
6
|
"exports": {
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"drizzle-orm": "^0.45.2",
|
|
20
20
|
"hono": "^4.12.11",
|
|
21
21
|
"limiter": "^3.0.0",
|
|
22
|
-
"@codemem/core": "^0.
|
|
22
|
+
"@codemem/core": "^0.24.0"
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"@types/better-sqlite3": "^7.6.13",
|
package/static/app.js
CHANGED
|
@@ -11740,6 +11740,15 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
11740
11740
|
claudeCommand: "claude_command",
|
|
11741
11741
|
observerProvider: "observer_provider",
|
|
11742
11742
|
observerModel: "observer_model",
|
|
11743
|
+
observerTierRoutingEnabled: "observer_tier_routing_enabled",
|
|
11744
|
+
observerSimpleModel: "observer_simple_model",
|
|
11745
|
+
observerSimpleTemperature: "observer_simple_temperature",
|
|
11746
|
+
observerRichModel: "observer_rich_model",
|
|
11747
|
+
observerRichTemperature: "observer_rich_temperature",
|
|
11748
|
+
observerRichOpenAIUseResponses: "observer_rich_openai_use_responses",
|
|
11749
|
+
observerRichReasoningEffort: "observer_rich_reasoning_effort",
|
|
11750
|
+
observerRichReasoningSummary: "observer_rich_reasoning_summary",
|
|
11751
|
+
observerRichMaxOutputTokens: "observer_rich_max_output_tokens",
|
|
11743
11752
|
observerRuntime: "observer_runtime",
|
|
11744
11753
|
observerAuthSource: "observer_auth_source",
|
|
11745
11754
|
observerAuthFile: "observer_auth_file",
|
|
@@ -11781,6 +11790,15 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
11781
11790
|
claudeCommand: "",
|
|
11782
11791
|
observerProvider: "",
|
|
11783
11792
|
observerModel: "",
|
|
11793
|
+
observerTierRoutingEnabled: false,
|
|
11794
|
+
observerSimpleModel: "",
|
|
11795
|
+
observerSimpleTemperature: "",
|
|
11796
|
+
observerRichModel: "",
|
|
11797
|
+
observerRichTemperature: "",
|
|
11798
|
+
observerRichOpenAIUseResponses: false,
|
|
11799
|
+
observerRichReasoningEffort: "",
|
|
11800
|
+
observerRichReasoningSummary: "",
|
|
11801
|
+
observerRichMaxOutputTokens: "",
|
|
11784
11802
|
observerRuntime: "api_http",
|
|
11785
11803
|
observerAuthSource: "auto",
|
|
11786
11804
|
observerAuthFile: "",
|
|
@@ -11826,6 +11844,27 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
11826
11844
|
if (value === void 0 || value === null) return "";
|
|
11827
11845
|
return String(value);
|
|
11828
11846
|
}
|
|
11847
|
+
function asBooleanValue(value) {
|
|
11848
|
+
if (typeof value === "boolean") return value;
|
|
11849
|
+
if (typeof value === "number") return value !== 0;
|
|
11850
|
+
if (typeof value === "string") {
|
|
11851
|
+
const normalized = value.trim().toLowerCase();
|
|
11852
|
+
if (!normalized) return false;
|
|
11853
|
+
if ([
|
|
11854
|
+
"0",
|
|
11855
|
+
"false",
|
|
11856
|
+
"no",
|
|
11857
|
+
"off"
|
|
11858
|
+
].includes(normalized)) return false;
|
|
11859
|
+
if ([
|
|
11860
|
+
"1",
|
|
11861
|
+
"true",
|
|
11862
|
+
"yes",
|
|
11863
|
+
"on"
|
|
11864
|
+
].includes(normalized)) return true;
|
|
11865
|
+
}
|
|
11866
|
+
return Boolean(value);
|
|
11867
|
+
}
|
|
11829
11868
|
function toProviderList(value) {
|
|
11830
11869
|
if (!Array.isArray(value)) return [];
|
|
11831
11870
|
return value.filter((item) => typeof item === "string" && item.trim().length > 0);
|
|
@@ -11879,6 +11918,10 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
11879
11918
|
}
|
|
11880
11919
|
case "observer_provider":
|
|
11881
11920
|
case "observer_model":
|
|
11921
|
+
case "observer_simple_model":
|
|
11922
|
+
case "observer_rich_model":
|
|
11923
|
+
case "observer_rich_reasoning_effort":
|
|
11924
|
+
case "observer_rich_reasoning_summary":
|
|
11882
11925
|
case "observer_auth_file":
|
|
11883
11926
|
case "sync_host":
|
|
11884
11927
|
case "sync_coordinator_url":
|
|
@@ -11901,6 +11944,9 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
11901
11944
|
}
|
|
11902
11945
|
case "observer_auth_timeout_ms":
|
|
11903
11946
|
case "observer_max_chars":
|
|
11947
|
+
case "observer_simple_temperature":
|
|
11948
|
+
case "observer_rich_temperature":
|
|
11949
|
+
case "observer_rich_max_output_tokens":
|
|
11904
11950
|
case "pack_observation_limit":
|
|
11905
11951
|
case "pack_session_limit":
|
|
11906
11952
|
case "raw_events_sweeper_interval_s":
|
|
@@ -11922,7 +11968,9 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
11922
11968
|
return Number.isFinite(parsed) ? parsed : "";
|
|
11923
11969
|
}
|
|
11924
11970
|
case "sync_enabled":
|
|
11925
|
-
case "sync_mdns":
|
|
11971
|
+
case "sync_mdns":
|
|
11972
|
+
case "observer_tier_routing_enabled":
|
|
11973
|
+
case "observer_rich_openai_use_responses": return asBooleanValue(config?.[key]);
|
|
11926
11974
|
default: return hasOwn(config, key) ? config[key] : "";
|
|
11927
11975
|
}
|
|
11928
11976
|
}
|
|
@@ -11935,6 +11983,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
11935
11983
|
}
|
|
11936
11984
|
function getObserverModelHint() {
|
|
11937
11985
|
const values = settingsRenderState.values;
|
|
11986
|
+
if (values.observerTierRoutingEnabled) return "Tiered routing is enabled: simple/rich model selection now lives in Processing.";
|
|
11938
11987
|
const inferred = inferObserverModel(values.observerRuntime.trim() || "api_http", values.observerProvider.trim(), normalizeTextValue(values.observerModel));
|
|
11939
11988
|
return `${[
|
|
11940
11989
|
"observer_model",
|
|
@@ -11942,6 +11991,19 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
11942
11991
|
"observer_runtime"
|
|
11943
11992
|
].some((key) => hasOwn(settingsEnvOverrides, key)) ? "Env override" : inferred.source}: ${inferred.model}`;
|
|
11944
11993
|
}
|
|
11994
|
+
function getTieredRoutingHelperText() {
|
|
11995
|
+
if (!settingsRenderState.values.observerTierRoutingEnabled) return "Off: codemem uses the base observer settings from the Connection tab for all batches.";
|
|
11996
|
+
return "On: codemem can route simpler batches to a lighter model and richer batches to a higher-quality configuration.";
|
|
11997
|
+
}
|
|
11998
|
+
function getObserverModelLabel() {
|
|
11999
|
+
return settingsRenderState.values.observerTierRoutingEnabled ? "Base model fallback" : "Model";
|
|
12000
|
+
}
|
|
12001
|
+
function getObserverModelTooltip() {
|
|
12002
|
+
return settingsRenderState.values.observerTierRoutingEnabled ? "Tiered routing is enabled, so Processing controls the simple/rich models. This base model is only a fallback." : "Leave blank to use a recommended model for your selected mode/provider.";
|
|
12003
|
+
}
|
|
12004
|
+
function getObserverModelDescription() {
|
|
12005
|
+
return settingsRenderState.values.observerTierRoutingEnabled ? "Tiered routing is active. Use this only as a fallback while the Processing tab owns simple/rich model selection." : "Default: `gpt-5.1-codex-mini` for Direct API; `claude-4.5-haiku` for Local Claude session.";
|
|
12006
|
+
}
|
|
11945
12007
|
function positionHelpTooltipElement(el, anchor) {
|
|
11946
12008
|
const rect = anchor.getBoundingClientRect();
|
|
11947
12009
|
const margin = 8;
|
|
@@ -12273,6 +12335,15 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
12273
12335
|
claudeCommand: claudeCommand.length ? JSON.stringify(claudeCommand, null, 2) : "",
|
|
12274
12336
|
observerProvider: asInputString(effectiveOrConfigured(config, effective, "observer_provider")),
|
|
12275
12337
|
observerModel: asInputString(effectiveOrConfigured(config, effective, "observer_model")),
|
|
12338
|
+
observerTierRoutingEnabled: asBooleanValue(effectiveOrConfigured(config, effective, "observer_tier_routing_enabled")),
|
|
12339
|
+
observerSimpleModel: asInputString(effectiveOrConfigured(config, effective, "observer_simple_model")),
|
|
12340
|
+
observerSimpleTemperature: asInputString(effectiveOrConfigured(config, effective, "observer_simple_temperature")),
|
|
12341
|
+
observerRichModel: asInputString(effectiveOrConfigured(config, effective, "observer_rich_model")),
|
|
12342
|
+
observerRichTemperature: asInputString(effectiveOrConfigured(config, effective, "observer_rich_temperature")),
|
|
12343
|
+
observerRichOpenAIUseResponses: asBooleanValue(effectiveOrConfigured(config, effective, "observer_rich_openai_use_responses")),
|
|
12344
|
+
observerRichReasoningEffort: asInputString(effectiveOrConfigured(config, effective, "observer_rich_reasoning_effort")),
|
|
12345
|
+
observerRichReasoningSummary: asInputString(effectiveOrConfigured(config, effective, "observer_rich_reasoning_summary")),
|
|
12346
|
+
observerRichMaxOutputTokens: asInputString(effectiveOrConfigured(config, effective, "observer_rich_max_output_tokens")),
|
|
12276
12347
|
observerRuntime: asInputString(effectiveOrConfigured(config, effective, "observer_runtime")) || "api_http",
|
|
12277
12348
|
observerAuthSource: asInputString(effectiveOrConfigured(config, effective, "observer_auth_source")) || "auto",
|
|
12278
12349
|
observerAuthFile: asInputString(effectiveOrConfigured(config, effective, "observer_auth_file")),
|
|
@@ -12284,11 +12355,11 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
12284
12355
|
packObservationLimit: asInputString(effectiveOrConfigured(config, effective, "pack_observation_limit")),
|
|
12285
12356
|
packSessionLimit: asInputString(effectiveOrConfigured(config, effective, "pack_session_limit")),
|
|
12286
12357
|
rawEventsSweeperIntervalS: asInputString(effectiveOrConfigured(config, effective, "raw_events_sweeper_interval_s")),
|
|
12287
|
-
syncEnabled:
|
|
12358
|
+
syncEnabled: asBooleanValue(effectiveOrConfigured(config, effective, "sync_enabled")),
|
|
12288
12359
|
syncHost: asInputString(effectiveOrConfigured(config, effective, "sync_host")),
|
|
12289
12360
|
syncPort: asInputString(effectiveOrConfigured(config, effective, "sync_port")),
|
|
12290
12361
|
syncInterval: asInputString(effectiveOrConfigured(config, effective, "sync_interval_s")),
|
|
12291
|
-
syncMdns:
|
|
12362
|
+
syncMdns: asBooleanValue(effectiveOrConfigured(config, effective, "sync_mdns")),
|
|
12292
12363
|
syncCoordinatorUrl: asInputString(effectiveOrConfigured(config, effective, "sync_coordinator_url")),
|
|
12293
12364
|
syncCoordinatorGroup: asInputString(effectiveOrConfigured(config, effective, "sync_coordinator_group")),
|
|
12294
12365
|
syncCoordinatorTimeout: asInputString(effectiveOrConfigured(config, effective, "sync_coordinator_timeout_s")),
|
|
@@ -12378,16 +12449,34 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
12378
12449
|
});
|
|
12379
12450
|
}
|
|
12380
12451
|
const authCacheTtlInput = values.observerAuthCacheTtlS.trim();
|
|
12452
|
+
const simpleTemperatureInput = values.observerSimpleTemperature.trim();
|
|
12453
|
+
const richTemperatureInput = values.observerRichTemperature.trim();
|
|
12454
|
+
const richMaxOutputTokensInput = values.observerRichMaxOutputTokens.trim();
|
|
12381
12455
|
const sweeperIntervalInput = values.rawEventsSweeperIntervalS.trim();
|
|
12382
12456
|
const authCacheTtl = authCacheTtlInput === "" ? "" : Number(authCacheTtlInput);
|
|
12457
|
+
const simpleTemperature = simpleTemperatureInput === "" ? "" : Number(simpleTemperatureInput);
|
|
12458
|
+
const richTemperature = richTemperatureInput === "" ? "" : Number(richTemperatureInput);
|
|
12459
|
+
const richMaxOutputTokens = richMaxOutputTokensInput === "" ? "" : Number(richMaxOutputTokensInput);
|
|
12383
12460
|
const sweeperIntervalNum = Number(sweeperIntervalInput);
|
|
12384
12461
|
const sweeperInterval = sweeperIntervalInput === "" ? "" : sweeperIntervalNum;
|
|
12385
12462
|
if (authCacheTtlInput !== "" && !Number.isFinite(authCacheTtl)) throw new Error("observer auth cache ttl must be a number");
|
|
12463
|
+
if (simpleTemperatureInput !== "" && (typeof simpleTemperature !== "number" || !Number.isFinite(simpleTemperature) || simpleTemperature < 0)) throw new Error("simple tier temperature must be a non-negative number");
|
|
12464
|
+
if (richTemperatureInput !== "" && (typeof richTemperature !== "number" || !Number.isFinite(richTemperature) || richTemperature < 0)) throw new Error("rich tier temperature must be a non-negative number");
|
|
12465
|
+
if (richMaxOutputTokensInput !== "" && (typeof richMaxOutputTokens !== "number" || !Number.isFinite(richMaxOutputTokens) || richMaxOutputTokens <= 0 || !Number.isInteger(richMaxOutputTokens))) throw new Error("rich tier max output tokens must be a positive integer");
|
|
12386
12466
|
if (sweeperIntervalInput !== "" && (!Number.isFinite(sweeperIntervalNum) || sweeperIntervalNum <= 0)) throw new Error("raw-event sweeper interval must be a positive number");
|
|
12387
12467
|
return {
|
|
12388
12468
|
claude_command: claudeCommand,
|
|
12389
12469
|
observer_provider: normalizeTextValue(values.observerProvider),
|
|
12390
12470
|
observer_model: normalizeTextValue(values.observerModel),
|
|
12471
|
+
observer_tier_routing_enabled: values.observerTierRoutingEnabled,
|
|
12472
|
+
observer_simple_model: normalizeTextValue(values.observerSimpleModel),
|
|
12473
|
+
observer_simple_temperature: simpleTemperature,
|
|
12474
|
+
observer_rich_model: normalizeTextValue(values.observerRichModel),
|
|
12475
|
+
observer_rich_temperature: richTemperature,
|
|
12476
|
+
observer_rich_openai_use_responses: values.observerRichOpenAIUseResponses,
|
|
12477
|
+
observer_rich_reasoning_effort: normalizeTextValue(values.observerRichReasoningEffort),
|
|
12478
|
+
observer_rich_reasoning_summary: normalizeTextValue(values.observerRichReasoningSummary),
|
|
12479
|
+
observer_rich_max_output_tokens: richMaxOutputTokens,
|
|
12391
12480
|
observer_runtime: normalizeTextValue(values.observerRuntime || "api_http") || "api_http",
|
|
12392
12481
|
observer_auth_source: normalizeTextValue(values.observerAuthSource || "auto") || "auto",
|
|
12393
12482
|
observer_auth_file: normalizeTextValue(values.observerAuthFile),
|
|
@@ -12657,6 +12746,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
12657
12746
|
const observerMaxCharsDefault = state.configDefaults?.observer_max_chars || "";
|
|
12658
12747
|
const showAuthFile = values.observerAuthSource === "file";
|
|
12659
12748
|
const showAuthCommand = values.observerAuthSource === "command";
|
|
12749
|
+
const showTieredRouting = values.observerTierRoutingEnabled;
|
|
12660
12750
|
return /* @__PURE__ */ u("div", {
|
|
12661
12751
|
className: "modal-card",
|
|
12662
12752
|
children: [
|
|
@@ -12794,11 +12884,11 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
12794
12884
|
className: "field-label",
|
|
12795
12885
|
children: [/* @__PURE__ */ u("label", {
|
|
12796
12886
|
htmlFor: "observerModel",
|
|
12797
|
-
children:
|
|
12887
|
+
children: getObserverModelLabel()
|
|
12798
12888
|
}), /* @__PURE__ */ u("button", {
|
|
12799
12889
|
"aria-label": "About model defaults",
|
|
12800
12890
|
className: "help-icon",
|
|
12801
|
-
"data-tooltip":
|
|
12891
|
+
"data-tooltip": getObserverModelTooltip(),
|
|
12802
12892
|
type: "button",
|
|
12803
12893
|
children: "?"
|
|
12804
12894
|
})]
|
|
@@ -12811,7 +12901,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
12811
12901
|
}),
|
|
12812
12902
|
/* @__PURE__ */ u("div", {
|
|
12813
12903
|
className: "small",
|
|
12814
|
-
children:
|
|
12904
|
+
children: getObserverModelDescription()
|
|
12815
12905
|
}),
|
|
12816
12906
|
/* @__PURE__ */ u("div", {
|
|
12817
12907
|
className: "small",
|
|
@@ -13071,89 +13161,259 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
13071
13161
|
"data-settings-panel": "queue",
|
|
13072
13162
|
hidden: settingsActiveTab !== "queue",
|
|
13073
13163
|
id: "settingsPanelQueue",
|
|
13074
|
-
children: [
|
|
13075
|
-
|
|
13076
|
-
|
|
13077
|
-
|
|
13078
|
-
children: "Processing"
|
|
13079
|
-
}), /* @__PURE__ */ u(Field, { children: [
|
|
13080
|
-
/* @__PURE__ */ u("div", {
|
|
13081
|
-
className: "field-label",
|
|
13082
|
-
children: [/* @__PURE__ */ u("label", {
|
|
13083
|
-
htmlFor: "rawEventsSweeperIntervalS",
|
|
13084
|
-
children: "Background processing interval (seconds)"
|
|
13085
|
-
}), /* @__PURE__ */ u("button", {
|
|
13086
|
-
"aria-label": "About background processing interval",
|
|
13087
|
-
className: "help-icon",
|
|
13088
|
-
"data-tooltip": "How often codemem checks for queued events to process in the background.",
|
|
13089
|
-
type: "button",
|
|
13090
|
-
children: "?"
|
|
13091
|
-
})]
|
|
13092
|
-
}),
|
|
13093
|
-
/* @__PURE__ */ u("input", {
|
|
13094
|
-
id: "rawEventsSweeperIntervalS",
|
|
13095
|
-
min: "1",
|
|
13096
|
-
onInput: onTextInput("rawEventsSweeperIntervalS"),
|
|
13097
|
-
type: "number",
|
|
13098
|
-
value: values.rawEventsSweeperIntervalS
|
|
13099
|
-
}),
|
|
13100
|
-
/* @__PURE__ */ u("div", {
|
|
13101
|
-
className: "small",
|
|
13102
|
-
children: "How often background flush checks pending raw events."
|
|
13103
|
-
})
|
|
13104
|
-
] })]
|
|
13105
|
-
}), /* @__PURE__ */ u("div", {
|
|
13106
|
-
className: "settings-group settings-advanced",
|
|
13107
|
-
hidden: hiddenUnlessAdvanced(),
|
|
13108
|
-
children: [
|
|
13109
|
-
/* @__PURE__ */ u("h3", {
|
|
13164
|
+
children: [
|
|
13165
|
+
/* @__PURE__ */ u("div", {
|
|
13166
|
+
className: "settings-group",
|
|
13167
|
+
children: [/* @__PURE__ */ u("h3", {
|
|
13110
13168
|
className: "settings-group-title",
|
|
13111
|
-
children: "
|
|
13112
|
-
}),
|
|
13113
|
-
|
|
13114
|
-
|
|
13115
|
-
|
|
13116
|
-
|
|
13117
|
-
|
|
13118
|
-
|
|
13119
|
-
|
|
13120
|
-
|
|
13121
|
-
|
|
13122
|
-
|
|
13123
|
-
|
|
13124
|
-
|
|
13169
|
+
children: "Processing"
|
|
13170
|
+
}), /* @__PURE__ */ u(Field, { children: [
|
|
13171
|
+
/* @__PURE__ */ u("div", {
|
|
13172
|
+
className: "field-label",
|
|
13173
|
+
children: [/* @__PURE__ */ u("label", {
|
|
13174
|
+
htmlFor: "rawEventsSweeperIntervalS",
|
|
13175
|
+
children: "Background processing interval (seconds)"
|
|
13176
|
+
}), /* @__PURE__ */ u("button", {
|
|
13177
|
+
"aria-label": "About background processing interval",
|
|
13178
|
+
className: "help-icon",
|
|
13179
|
+
"data-tooltip": "How often codemem checks for queued events to process in the background.",
|
|
13180
|
+
type: "button",
|
|
13181
|
+
children: "?"
|
|
13182
|
+
})]
|
|
13183
|
+
}),
|
|
13184
|
+
/* @__PURE__ */ u("input", {
|
|
13185
|
+
id: "rawEventsSweeperIntervalS",
|
|
13186
|
+
min: "1",
|
|
13187
|
+
onInput: onTextInput("rawEventsSweeperIntervalS"),
|
|
13188
|
+
type: "number",
|
|
13189
|
+
value: values.rawEventsSweeperIntervalS
|
|
13190
|
+
}),
|
|
13191
|
+
/* @__PURE__ */ u("div", {
|
|
13192
|
+
className: "small",
|
|
13193
|
+
children: "How often background flush checks pending raw events."
|
|
13194
|
+
})
|
|
13195
|
+
] })]
|
|
13196
|
+
}),
|
|
13197
|
+
/* @__PURE__ */ u("div", {
|
|
13198
|
+
className: "settings-group",
|
|
13199
|
+
children: [
|
|
13200
|
+
/* @__PURE__ */ u("h3", {
|
|
13201
|
+
className: "settings-group-title",
|
|
13202
|
+
children: "Tiered observer routing"
|
|
13203
|
+
}),
|
|
13204
|
+
/* @__PURE__ */ u("div", {
|
|
13205
|
+
className: "field field-checkbox",
|
|
13206
|
+
children: [/* @__PURE__ */ u("input", {
|
|
13207
|
+
checked: values.observerTierRoutingEnabled,
|
|
13208
|
+
className: "cm-checkbox",
|
|
13209
|
+
id: "observerTierRoutingEnabled",
|
|
13210
|
+
onChange: onCheckboxInput("observerTierRoutingEnabled"),
|
|
13211
|
+
type: "checkbox"
|
|
13212
|
+
}), /* @__PURE__ */ u("label", {
|
|
13213
|
+
htmlFor: "observerTierRoutingEnabled",
|
|
13214
|
+
children: "Enable tiered routing"
|
|
13215
|
+
})]
|
|
13216
|
+
}),
|
|
13217
|
+
/* @__PURE__ */ u("div", {
|
|
13218
|
+
className: "small",
|
|
13219
|
+
children: getTieredRoutingHelperText()
|
|
13220
|
+
}),
|
|
13221
|
+
/* @__PURE__ */ u(Field, {
|
|
13222
|
+
hidden: !showTieredRouting,
|
|
13223
|
+
children: [
|
|
13224
|
+
/* @__PURE__ */ u("div", {
|
|
13225
|
+
className: "field-label",
|
|
13226
|
+
children: [/* @__PURE__ */ u("label", {
|
|
13227
|
+
htmlFor: "observerSimpleModel",
|
|
13228
|
+
children: "Simple tier model"
|
|
13229
|
+
}), /* @__PURE__ */ u("button", {
|
|
13230
|
+
"aria-label": "About simple tier model",
|
|
13231
|
+
className: "help-icon",
|
|
13232
|
+
"data-tooltip": "Used for lighter replay batches. Leave blank to keep codemem's routing defaults or base observer fallback.",
|
|
13233
|
+
type: "button",
|
|
13234
|
+
children: "?"
|
|
13235
|
+
})]
|
|
13236
|
+
}),
|
|
13237
|
+
/* @__PURE__ */ u("input", {
|
|
13238
|
+
id: "observerSimpleModel",
|
|
13239
|
+
onInput: onTextInput("observerSimpleModel"),
|
|
13240
|
+
placeholder: "leave empty for default",
|
|
13241
|
+
value: values.observerSimpleModel
|
|
13242
|
+
}),
|
|
13243
|
+
/* @__PURE__ */ u("div", {
|
|
13244
|
+
className: "small",
|
|
13245
|
+
children: "Used when a batch falls below rich-routing thresholds."
|
|
13246
|
+
})
|
|
13247
|
+
]
|
|
13248
|
+
}),
|
|
13249
|
+
/* @__PURE__ */ u(Field, {
|
|
13250
|
+
hidden: !showTieredRouting,
|
|
13251
|
+
children: [
|
|
13252
|
+
/* @__PURE__ */ u("div", {
|
|
13253
|
+
className: "field-label",
|
|
13254
|
+
children: [/* @__PURE__ */ u("label", {
|
|
13255
|
+
htmlFor: "observerRichModel",
|
|
13256
|
+
children: "Rich tier model"
|
|
13257
|
+
}), /* @__PURE__ */ u("button", {
|
|
13258
|
+
"aria-label": "About rich tier model",
|
|
13259
|
+
className: "help-icon",
|
|
13260
|
+
"data-tooltip": "Used for larger or more complex replay batches. Leave blank to keep codemem's rich-tier defaults.",
|
|
13261
|
+
type: "button",
|
|
13262
|
+
children: "?"
|
|
13263
|
+
})]
|
|
13264
|
+
}),
|
|
13265
|
+
/* @__PURE__ */ u("input", {
|
|
13266
|
+
id: "observerRichModel",
|
|
13267
|
+
onInput: onTextInput("observerRichModel"),
|
|
13268
|
+
placeholder: "leave empty for default",
|
|
13269
|
+
value: values.observerRichModel
|
|
13270
|
+
}),
|
|
13271
|
+
/* @__PURE__ */ u("div", {
|
|
13272
|
+
className: "small",
|
|
13273
|
+
children: "Used when routing detects a richer replay batch."
|
|
13274
|
+
})
|
|
13275
|
+
]
|
|
13276
|
+
}),
|
|
13277
|
+
/* @__PURE__ */ u(Field, {
|
|
13278
|
+
className: "field field-checkbox",
|
|
13279
|
+
hidden: !showTieredRouting,
|
|
13280
|
+
children: [/* @__PURE__ */ u("input", {
|
|
13281
|
+
checked: values.observerRichOpenAIUseResponses,
|
|
13282
|
+
className: "cm-checkbox",
|
|
13283
|
+
id: "observerRichOpenAIUseResponses",
|
|
13284
|
+
onChange: onCheckboxInput("observerRichOpenAIUseResponses"),
|
|
13285
|
+
type: "checkbox"
|
|
13286
|
+
}), /* @__PURE__ */ u("label", {
|
|
13287
|
+
htmlFor: "observerRichOpenAIUseResponses",
|
|
13288
|
+
children: "Use OpenAI Responses API for rich tier"
|
|
13289
|
+
})]
|
|
13290
|
+
}),
|
|
13291
|
+
/* @__PURE__ */ u(Field, {
|
|
13292
|
+
className: "field settings-advanced",
|
|
13293
|
+
hidden: !showTieredRouting || hiddenUnlessAdvanced(),
|
|
13294
|
+
children: [/* @__PURE__ */ u("label", {
|
|
13295
|
+
htmlFor: "observerSimpleTemperature",
|
|
13296
|
+
children: "Simple tier temperature"
|
|
13297
|
+
}), /* @__PURE__ */ u("input", {
|
|
13298
|
+
id: "observerSimpleTemperature",
|
|
13299
|
+
min: "0",
|
|
13300
|
+
onInput: onTextInput("observerSimpleTemperature"),
|
|
13301
|
+
step: "0.1",
|
|
13125
13302
|
type: "number",
|
|
13126
|
-
value: values.
|
|
13127
|
-
})
|
|
13128
|
-
|
|
13129
|
-
|
|
13130
|
-
|
|
13131
|
-
|
|
13132
|
-
|
|
13133
|
-
|
|
13134
|
-
|
|
13135
|
-
|
|
13136
|
-
|
|
13137
|
-
|
|
13138
|
-
|
|
13139
|
-
|
|
13140
|
-
|
|
13141
|
-
|
|
13142
|
-
|
|
13143
|
-
|
|
13303
|
+
value: values.observerSimpleTemperature
|
|
13304
|
+
})]
|
|
13305
|
+
}),
|
|
13306
|
+
/* @__PURE__ */ u(Field, {
|
|
13307
|
+
className: "field settings-advanced",
|
|
13308
|
+
hidden: !showTieredRouting || hiddenUnlessAdvanced(),
|
|
13309
|
+
children: [/* @__PURE__ */ u("label", {
|
|
13310
|
+
htmlFor: "observerRichTemperature",
|
|
13311
|
+
children: "Rich tier temperature"
|
|
13312
|
+
}), /* @__PURE__ */ u("input", {
|
|
13313
|
+
id: "observerRichTemperature",
|
|
13314
|
+
min: "0",
|
|
13315
|
+
onInput: onTextInput("observerRichTemperature"),
|
|
13316
|
+
step: "0.1",
|
|
13317
|
+
type: "number",
|
|
13318
|
+
value: values.observerRichTemperature
|
|
13319
|
+
})]
|
|
13320
|
+
}),
|
|
13321
|
+
/* @__PURE__ */ u(Field, {
|
|
13322
|
+
className: "field settings-advanced",
|
|
13323
|
+
hidden: !showTieredRouting || hiddenUnlessAdvanced(),
|
|
13324
|
+
children: [/* @__PURE__ */ u("label", {
|
|
13325
|
+
htmlFor: "observerRichReasoningEffort",
|
|
13326
|
+
children: "Rich tier reasoning effort"
|
|
13327
|
+
}), /* @__PURE__ */ u("input", {
|
|
13328
|
+
id: "observerRichReasoningEffort",
|
|
13329
|
+
onInput: onTextInput("observerRichReasoningEffort"),
|
|
13330
|
+
placeholder: "leave empty for default",
|
|
13331
|
+
value: values.observerRichReasoningEffort
|
|
13332
|
+
})]
|
|
13333
|
+
}),
|
|
13334
|
+
/* @__PURE__ */ u(Field, {
|
|
13335
|
+
className: "field settings-advanced",
|
|
13336
|
+
hidden: !showTieredRouting || hiddenUnlessAdvanced(),
|
|
13337
|
+
children: [/* @__PURE__ */ u("label", {
|
|
13338
|
+
htmlFor: "observerRichReasoningSummary",
|
|
13339
|
+
children: "Rich tier reasoning summary"
|
|
13340
|
+
}), /* @__PURE__ */ u("input", {
|
|
13341
|
+
id: "observerRichReasoningSummary",
|
|
13342
|
+
onInput: onTextInput("observerRichReasoningSummary"),
|
|
13343
|
+
placeholder: "leave empty for default",
|
|
13344
|
+
value: values.observerRichReasoningSummary
|
|
13345
|
+
})]
|
|
13346
|
+
}),
|
|
13347
|
+
/* @__PURE__ */ u(Field, {
|
|
13348
|
+
className: "field settings-advanced",
|
|
13349
|
+
hidden: !showTieredRouting || hiddenUnlessAdvanced(),
|
|
13350
|
+
children: [/* @__PURE__ */ u("label", {
|
|
13351
|
+
htmlFor: "observerRichMaxOutputTokens",
|
|
13352
|
+
children: "Rich tier max output tokens"
|
|
13353
|
+
}), /* @__PURE__ */ u("input", {
|
|
13354
|
+
id: "observerRichMaxOutputTokens",
|
|
13144
13355
|
min: "1",
|
|
13145
|
-
onInput: onTextInput("
|
|
13356
|
+
onInput: onTextInput("observerRichMaxOutputTokens"),
|
|
13357
|
+
step: "1",
|
|
13146
13358
|
type: "number",
|
|
13147
|
-
value: values.
|
|
13148
|
-
})
|
|
13149
|
-
|
|
13150
|
-
|
|
13151
|
-
|
|
13152
|
-
|
|
13153
|
-
|
|
13154
|
-
|
|
13155
|
-
|
|
13156
|
-
|
|
13359
|
+
value: values.observerRichMaxOutputTokens
|
|
13360
|
+
})]
|
|
13361
|
+
})
|
|
13362
|
+
]
|
|
13363
|
+
}),
|
|
13364
|
+
/* @__PURE__ */ u("div", {
|
|
13365
|
+
className: "settings-group settings-advanced",
|
|
13366
|
+
hidden: hiddenUnlessAdvanced(),
|
|
13367
|
+
children: [
|
|
13368
|
+
/* @__PURE__ */ u("h3", {
|
|
13369
|
+
className: "settings-group-title",
|
|
13370
|
+
children: "Context Pack Limits"
|
|
13371
|
+
}),
|
|
13372
|
+
/* @__PURE__ */ u(Field, {
|
|
13373
|
+
className: "field settings-advanced",
|
|
13374
|
+
hidden: hiddenUnlessAdvanced(),
|
|
13375
|
+
children: [
|
|
13376
|
+
/* @__PURE__ */ u("label", {
|
|
13377
|
+
htmlFor: "packObservationLimit",
|
|
13378
|
+
children: "Observation limit"
|
|
13379
|
+
}),
|
|
13380
|
+
/* @__PURE__ */ u("input", {
|
|
13381
|
+
id: "packObservationLimit",
|
|
13382
|
+
min: "1",
|
|
13383
|
+
onInput: onTextInput("packObservationLimit"),
|
|
13384
|
+
type: "number",
|
|
13385
|
+
value: values.packObservationLimit
|
|
13386
|
+
}),
|
|
13387
|
+
/* @__PURE__ */ u("div", {
|
|
13388
|
+
className: "small",
|
|
13389
|
+
children: "Default number of observations to include in a pack."
|
|
13390
|
+
})
|
|
13391
|
+
]
|
|
13392
|
+
}),
|
|
13393
|
+
/* @__PURE__ */ u(Field, {
|
|
13394
|
+
className: "field settings-advanced",
|
|
13395
|
+
hidden: hiddenUnlessAdvanced(),
|
|
13396
|
+
children: [
|
|
13397
|
+
/* @__PURE__ */ u("label", {
|
|
13398
|
+
htmlFor: "packSessionLimit",
|
|
13399
|
+
children: "Session summary limit"
|
|
13400
|
+
}),
|
|
13401
|
+
/* @__PURE__ */ u("input", {
|
|
13402
|
+
id: "packSessionLimit",
|
|
13403
|
+
min: "1",
|
|
13404
|
+
onInput: onTextInput("packSessionLimit"),
|
|
13405
|
+
type: "number",
|
|
13406
|
+
value: values.packSessionLimit
|
|
13407
|
+
}),
|
|
13408
|
+
/* @__PURE__ */ u("div", {
|
|
13409
|
+
className: "small",
|
|
13410
|
+
children: "Default number of session summaries to include in a pack."
|
|
13411
|
+
})
|
|
13412
|
+
]
|
|
13413
|
+
})
|
|
13414
|
+
]
|
|
13415
|
+
})
|
|
13416
|
+
]
|
|
13157
13417
|
}),
|
|
13158
13418
|
/* @__PURE__ */ u("div", {
|
|
13159
13419
|
className: panelClass("sync"),
|
|
@@ -13360,7 +13620,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${titl
|
|
|
13360
13620
|
try {
|
|
13361
13621
|
const runtime = await loadRuntimeInfo();
|
|
13362
13622
|
if (!runtime?.version) return;
|
|
13363
|
-
setRuntimeLabel(runtime.version, "
|
|
13623
|
+
setRuntimeLabel(runtime.version, "dfc218f");
|
|
13364
13624
|
} catch {}
|
|
13365
13625
|
}
|
|
13366
13626
|
var lastAnnouncedRefreshState = null;
|