codexmate 0.1.33 → 0.1.35

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.
Files changed (91) hide show
  1. package/README.md +27 -2
  2. package/README.vi.md +27 -2
  3. package/README.zh.md +27 -2
  4. package/cli/analytics-export-args.js +7 -0
  5. package/cli/local-bridge.js +10 -6
  6. package/cli/openai-chat-routing.js +38 -0
  7. package/cli/routing-bridge.js +143 -0
  8. package/cli/session-usage.js +4 -1
  9. package/cli/system-prompt-files.js +75 -53
  10. package/cli.js +191 -9
  11. package/lib/data/model-prices.json +1868 -0
  12. package/lib/file-sharing-lan.js +111 -0
  13. package/lib/file-sharing.js +196 -0
  14. package/lib/model-test-client.js +61 -0
  15. package/lib/model-test.js +126 -0
  16. package/lib/routing-groups.js +161 -0
  17. package/lib/session-context-health.js +5 -1
  18. package/lib/session-evidence-collections.js +85 -0
  19. package/lib/session-features.js +15 -0
  20. package/lib/session-project-git.js +65 -0
  21. package/lib/session-projects.js +12 -1
  22. package/lib/session-stories.js +67 -0
  23. package/lib/session-usage-ledger.js +77 -0
  24. package/lib/session-usage-pricing.js +42 -0
  25. package/lib/session-usage-report.js +101 -0
  26. package/package.json +4 -1
  27. package/plugins/file-sharing/manifest.mjs +10 -0
  28. package/plugins/file-sharing/methods.mjs +101 -0
  29. package/plugins/file-sharing/overview.mjs +3 -0
  30. package/plugins/file-sharing/ownership.mjs +5 -0
  31. package/plugins/prompt-templates/computed.mjs +9 -0
  32. package/plugins/registry.mjs +3 -0
  33. package/web-ui/app.js +25 -2
  34. package/web-ui/index.html +3 -2
  35. package/web-ui/logic.session-artifacts.mjs +39 -0
  36. package/web-ui/modules/app.computed.main-tabs.mjs +3 -0
  37. package/web-ui/modules/app.methods.agents.mjs +14 -1
  38. package/web-ui/modules/app.methods.install.mjs +23 -3
  39. package/web-ui/modules/app.methods.navigation.mjs +2 -0
  40. package/web-ui/modules/app.methods.prompts-editor.mjs +7 -4
  41. package/web-ui/modules/app.methods.session-actions.mjs +2 -2
  42. package/web-ui/modules/app.methods.session-browser.mjs +35 -0
  43. package/web-ui/modules/app.methods.system-prompt.mjs +99 -19
  44. package/web-ui/modules/app.methods.theme.mjs +4 -3
  45. package/web-ui/modules/app.methods.web-ui-preferences.mjs +12 -0
  46. package/web-ui/modules/i18n/locales/en.mjs +239 -5
  47. package/web-ui/modules/i18n/locales/ja.mjs +239 -5
  48. package/web-ui/modules/i18n/locales/vi.mjs +239 -5
  49. package/web-ui/modules/i18n/locales/zh-tw.mjs +239 -5
  50. package/web-ui/modules/i18n/locales/zh.mjs +239 -5
  51. package/web-ui/modules/model-test.mjs +82 -0
  52. package/web-ui/modules/plugins.methods.mjs +3 -1
  53. package/web-ui/modules/prompt-ecosystem.methods.mjs +4 -3
  54. package/web-ui/modules/routing.mjs +206 -0
  55. package/web-ui/modules/session-collections.mjs +65 -0
  56. package/web-ui/modules/session-evidence.mjs +81 -0
  57. package/web-ui/modules/session-features.mjs +15 -1
  58. package/web-ui/modules/session-git.mjs +39 -0
  59. package/web-ui/modules/session-stories.mjs +64 -0
  60. package/web-ui/modules/usage-pricing.mjs +30 -0
  61. package/web-ui/partials/index/layout-footer.html +1 -1
  62. package/web-ui/partials/index/layout-header.html +33 -12
  63. package/web-ui/partials/index/modals-basic.html +15 -0
  64. package/web-ui/partials/index/panel-plugins.html +3 -9
  65. package/web-ui/partials/index/panel-prompts.html +13 -7
  66. package/web-ui/partials/index/panel-routing.html +3 -0
  67. package/web-ui/partials/index/panel-sessions.html +20 -20
  68. package/web-ui/partials/index/panel-settings.html +11 -1
  69. package/web-ui/partials/index/panel-usage.html +2 -0
  70. package/web-ui/partials/index/plugin-file-sharing.html +47 -0
  71. package/web-ui/partials/index/routing-model-test.html +53 -0
  72. package/web-ui/partials/index/session-diagnostics.html +7 -4
  73. package/web-ui/partials/index/session-features.html +82 -2
  74. package/web-ui/partials/index/thread-handoff.html +73 -62
  75. package/web-ui/partials/index/usage-records.html +41 -0
  76. package/web-ui/res/web-ui-render.precompiled.js +1378 -230
  77. package/web-ui/styles/base-theme.css +1 -1
  78. package/web-ui/styles/modals-core.css +6 -5
  79. package/web-ui/styles/navigation-panels.css +4 -0
  80. package/web-ui/styles/plugins-panel.css +40 -1
  81. package/web-ui/styles/responsive.css +10 -5
  82. package/web-ui/styles/routing.css +78 -0
  83. package/web-ui/styles/session-features.css +180 -7
  84. package/web-ui/styles/sessions-list.css +74 -0
  85. package/web-ui/styles/sessions-preview.css +106 -68
  86. package/web-ui/styles/sessions-usage.css +8 -0
  87. package/web-ui/styles/settings-panel.css +30 -0
  88. package/web-ui/styles/system-prompt.css +8 -7
  89. package/web-ui/styles/theme-violet-tokens.css +52 -0
  90. package/web-ui/styles/theme-violet.css +1742 -0
  91. package/web-ui/styles.css +2 -0
@@ -14,19 +14,92 @@ export function createSystemPromptMethods(options = {}) {
14
14
 
15
15
  return {
16
16
 
17
- switchSysPromptScope(scope) {
18
- if (this.sysPromptLoading || this.sysPromptSaving) return;
17
+ currentSysPromptFileName() {
18
+ return this.sysPromptFileName || (this.sysPromptMode === 'append' ? 'APPEND_SYSTEM.md' : 'SYSTEM.md');
19
+ },
20
+
21
+ isSysPromptCustomFile() {
22
+ return !['SYSTEM.md', 'APPEND_SYSTEM.md'].includes(this.currentSysPromptFileName());
23
+ },
24
+
25
+ sysPromptTargetParams() {
26
+ return {
27
+ scope: this.sysPromptScope || 'global', mode: this.sysPromptMode || 'append',
28
+ ...(this.sysPromptFileName ? { fileName: this.sysPromptFileName } : {})
29
+ };
30
+ },
31
+
32
+ canSwitchSysPromptTarget() {
33
+ if (this.sysPromptLoading || this.sysPromptSaving || this.sysPromptDiffVisible) return false;
34
+ if (!this.hasSysPromptContentChanged()) return true;
35
+ this.showMessage(this.t('sysPrompt.fileUnsaved'), 'info');
36
+ return false;
37
+ },
38
+
39
+ loadSystemPromptFiles() {
40
+ if (!this.sysPromptFilesLoading) this._sysPromptFilesPromise = this.refreshSystemPromptFiles();
41
+ return this._sysPromptFilesPromise;
42
+ },
43
+
44
+ async refreshSystemPromptFiles() {
45
+ const scope = this.sysPromptScope || 'global';
46
+ const token = issueLatestRequestToken(this, '_sysPromptFilesRequestToken');
47
+ this.sysPromptFilesLoading = true;
48
+ try {
49
+ const result = await api('list-system-prompt-files', { scope });
50
+ if (!isLatestRequestToken(this, '_sysPromptFilesRequestToken', token) || scope !== this.sysPromptScope) return;
51
+ if (result.error) throw new Error(result.error);
52
+ this.sysPromptFiles = result.files;
53
+ const isListed = result.files.some(file => file.filename === this.currentSysPromptFileName());
54
+ if (!isListed && result.files.length && !this.hasSysPromptContentChanged()
55
+ && !this.sysPromptLoading && !this.sysPromptSaving && !this.sysPromptDiffVisible) {
56
+ await this.switchSysPromptFileName(result.files[0].filename);
57
+ return true;
58
+ }
59
+ if (!isListed) this.sysPromptFileMissing = true;
60
+ this.sysPromptFilesError = !isListed ? this.t('sysPrompt.fileMissing')
61
+ : (this.sysPromptFileMissing ? this.sysPromptFilesError : '');
62
+ } catch (error) {
63
+ if (isLatestRequestToken(this, '_sysPromptFilesRequestToken', token) && scope === this.sysPromptScope) {
64
+ this.sysPromptFilesError = error.message || this.t('toast.load.fail');
65
+ }
66
+ } finally {
67
+ if (isLatestRequestToken(this, '_sysPromptFilesRequestToken', token)) this.sysPromptFilesLoading = false;
68
+ }
69
+ },
70
+
71
+ switchSysPromptFileName(filename, event) {
72
+ if (event) event.target.value = this.currentSysPromptFileName();
73
+ if (filename === this.currentSysPromptFileName() || !this.canSwitchSysPromptTarget()) return;
74
+ if (!this.sysPromptFiles.some(file => file.filename === filename)) return;
75
+ this.sysPromptFileName = filename;
76
+ if (filename === 'SYSTEM.md') this.sysPromptMode = 'system';
77
+ if (filename === 'APPEND_SYSTEM.md') this.sysPromptMode = 'append';
78
+ this.closeSysHistory();
79
+ return this.loadSystemPrompt();
80
+ },
81
+
82
+ async switchSysPromptScope(scope) {
83
+ if (!this.canSwitchSysPromptTarget()) return;
19
84
  const normalized = scope === 'project' ? scope : 'global';
20
85
  if (normalized === this.sysPromptScope) return;
21
86
  this.sysPromptScope = normalized;
22
- this.loadSystemPrompt();
87
+ this.sysPromptFiles = [];
88
+ this._sysPromptFilesRequestToken = null;
89
+ this.sysPromptFilesLoading = false;
90
+ this.closeSysHistory();
91
+ const didLoadFallback = await this.loadSystemPromptFiles();
92
+ if (normalized !== this.sysPromptScope || didLoadFallback) return;
93
+ return this.loadSystemPrompt();
23
94
  },
24
95
 
25
96
  switchSysPromptMode(mode) {
26
- if (this.sysPromptLoading || this.sysPromptSaving) return;
97
+ if (!this.canSwitchSysPromptTarget()) return;
27
98
  const normalized = mode === 'system' ? mode : 'append';
28
99
  if (normalized === this.sysPromptMode) return;
29
100
  this.sysPromptMode = normalized;
101
+ this.sysPromptFileName = normalized === 'system' ? 'SYSTEM.md' : 'APPEND_SYSTEM.md';
102
+ this.closeSysHistory();
30
103
  this.loadSystemPrompt();
31
104
  },
32
105
 
@@ -53,24 +126,29 @@ export function createSystemPromptMethods(options = {}) {
53
126
  const mode = this.sysPromptMode || 'append';
54
127
  const content = typeof this.sysPromptContent === 'string' ? this.sysPromptContent : '';
55
128
  const original = typeof this.sysPromptOriginalContent === 'string' ? this.sysPromptOriginalContent : '';
56
- return `${scope}::${mode}::${content.length}::${content}::${original.length}::${original}`;
129
+ return `${scope}::${mode}::${this.currentSysPromptFileName()}::${content.length}::${content}::${original.length}::${original}`;
57
130
  },
58
131
 
59
132
  async loadSystemPrompt() {
60
133
  const requestToken = issueLatestRequestToken(this, '_sysPromptOpenRequestToken');
134
+ const filename = this.currentSysPromptFileName();
61
135
  this.sysPromptLoading = true;
136
+ this.sysPromptFileMissing = true;
62
137
  this.resetSysPromptDiffState();
63
138
  try {
64
- const params = {
65
- scope: this.sysPromptScope || 'global',
66
- mode: this.sysPromptMode || 'append'
67
- };
139
+ const params = this.sysPromptTargetParams();
68
140
  const res = await api('get-system-prompt', params);
69
- if (!isLatestRequestToken(this, '_sysPromptOpenRequestToken', requestToken)) return;
70
- if (res.error) {
71
- this.showMessage(res.error, 'error');
141
+ if (!isLatestRequestToken(this, '_sysPromptOpenRequestToken', requestToken)
142
+ || params.scope !== this.sysPromptScope || filename !== this.currentSysPromptFileName()) return;
143
+ if (res.error || (this.isSysPromptCustomFile() && !res.exists)) {
144
+ this.sysPromptFileMissing = true;
145
+ this.sysPromptFilesError = res.error || this.t('sysPrompt.fileMissing');
146
+ this.showMessage(this.sysPromptFilesError, 'error');
72
147
  return;
73
148
  }
149
+ this.sysPromptFileName = res.filename || this.currentSysPromptFileName();
150
+ this.sysPromptFileMissing = false;
151
+ this.sysPromptFilesError = '';
74
152
  this.sysPromptContent = res.content || '';
75
153
  this.sysPromptOriginalContent = this.sysPromptContent;
76
154
  this.sysPromptPath = res.path || '';
@@ -79,7 +157,9 @@ export function createSystemPromptMethods(options = {}) {
79
157
  this.sysHistoryBucket = res.historyBucket || '';
80
158
  } catch (e) {
81
159
  if (!isLatestRequestToken(this, '_sysPromptOpenRequestToken', requestToken)) return;
82
- this.showMessage(this.t('toast.load.fail'), 'error');
160
+ this.sysPromptFileMissing = true;
161
+ this.sysPromptFilesError = this.t('toast.load.fail');
162
+ this.showMessage(this.sysPromptFilesError, 'error');
83
163
  } finally {
84
164
  if (isLatestRequestToken(this, '_sysPromptOpenRequestToken', requestToken)) {
85
165
  this.sysPromptLoading = false;
@@ -147,8 +227,7 @@ export function createSystemPromptMethods(options = {}) {
147
227
  }
148
228
  const rpcParams = {
149
229
  ...previewRequest.params,
150
- scope: this.sysPromptScope || 'global',
151
- mode: this.sysPromptMode || 'append'
230
+ ...this.sysPromptTargetParams()
152
231
  };
153
232
  const res = await apiWithMeta('preview-system-prompt-diff', rpcParams);
154
233
  if (!shouldApplyPreviewState()) return;
@@ -188,7 +267,7 @@ export function createSystemPromptMethods(options = {}) {
188
267
  },
189
268
 
190
269
  async applySystemPrompt() {
191
- if (this.sysPromptSaving) return;
270
+ if (this.sysPromptSaving || this.sysPromptFileMissing) return;
192
271
  if (!this.sysPromptDiffVisible) {
193
272
  if (!this.hasSysPromptContentChanged()) {
194
273
  this.showMessage(this.t('toast.noChanges'), 'info');
@@ -214,8 +293,7 @@ export function createSystemPromptMethods(options = {}) {
214
293
  this.sysPromptSaving = true;
215
294
  try {
216
295
  const params = {
217
- scope: this.sysPromptScope || 'global',
218
- mode: this.sysPromptMode || 'append',
296
+ ...this.sysPromptTargetParams(),
219
297
  content: this.sysPromptContent,
220
298
  baseHash: this.sysPromptHash
221
299
  };
@@ -248,7 +326,7 @@ export function createSystemPromptMethods(options = {}) {
248
326
  exportSysPromptContent() {
249
327
  const content = typeof this.sysPromptContent === 'string' ? this.sysPromptContent : '';
250
328
  if (!content) return;
251
- const filename = (this.sysPromptMode === 'system' ? 'SYSTEM.md' : 'APPEND_SYSTEM.md');
329
+ const filename = this.sysPromptFileName || (this.sysPromptMode === 'system' ? 'SYSTEM.md' : 'APPEND_SYSTEM.md');
252
330
  this.downloadTextFile(filename, content, 'text/markdown;charset=utf-8');
253
331
  },
254
332
 
@@ -292,6 +370,7 @@ export function createSystemPromptMethods(options = {}) {
292
370
  if (typeof this.sysHistoryBucket === 'string' && this.sysHistoryBucket) {
293
371
  return this.sysHistoryBucket;
294
372
  }
373
+ if (this.isSysPromptCustomFile()) return '';
295
374
  const scope = this.sysPromptScope || 'global';
296
375
  return 'system_' + scope + '_global';
297
376
  },
@@ -299,6 +378,7 @@ export function createSystemPromptMethods(options = {}) {
299
378
  async openSysHistory() {
300
379
  if (this.sysHistoryLoading) return;
301
380
  const bucket = this.resolveSysHistoryBucket();
381
+ if (!bucket || this.sysPromptFileMissing) return;
302
382
  this.sysHistoryVisible = true;
303
383
  this.sysHistoryError = '';
304
384
  await this.loadSysHistory(bucket);
@@ -1,16 +1,17 @@
1
1
  const THEME_STORAGE_CACHE_KEY = 'codexmateThemeCache';
2
+ const NON_DEFAULT_THEMES = ['dark', 'ocean', 'violet'];
2
3
 
3
4
  export function createThemeMethods() {
4
5
  return {
5
6
  normalizeTheme(value) {
6
7
  const normalized = typeof value === 'string' ? value.trim().toLowerCase() : '';
7
- return normalized === 'dark' || normalized === 'ocean' ? normalized : 'light';
8
+ return NON_DEFAULT_THEMES.includes(normalized) ? normalized : 'light';
8
9
  },
9
10
  applyDocumentTheme() {
10
11
  try {
11
12
  if (typeof document === 'undefined' || !document.documentElement) return;
12
13
  const next = this.normalizeTheme(this.theme);
13
- if (next === 'dark' || next === 'ocean') {
14
+ if (NON_DEFAULT_THEMES.includes(next)) {
14
15
  document.documentElement.setAttribute('data-theme', next);
15
16
  } else {
16
17
  document.documentElement.removeAttribute('data-theme');
@@ -20,7 +21,7 @@ export function createThemeMethods() {
20
21
  // the server-side webUi preference store.
21
22
  const storage = typeof globalThis !== 'undefined' ? globalThis.localStorage : null;
22
23
  if (storage && typeof storage.setItem === 'function' && typeof storage.removeItem === 'function') {
23
- if (next === 'dark' || next === 'ocean') storage.setItem(THEME_STORAGE_CACHE_KEY, next);
24
+ if (NON_DEFAULT_THEMES.includes(next)) storage.setItem(THEME_STORAGE_CACHE_KEY, next);
24
25
  else storage.removeItem(THEME_STORAGE_CACHE_KEY);
25
26
  }
26
27
  } catch (_) {}
@@ -108,6 +108,8 @@ function normalizeNavigationSnapshot(vm, source = {}) {
108
108
  return {
109
109
  mainTab: typeof source.mainTab === 'string' ? source.mainTab : vm.mainTab,
110
110
  configMode: typeof source.configMode === 'string' ? source.configMode : vm.configMode,
111
+ modelTestTarget: source.modelTestTarget === 'pi' || source.modelTestTarget === 'codex'
112
+ ? source.modelTestTarget : vm.modelTestTarget === 'pi' ? 'pi' : 'codex',
111
113
  settingsTab: typeof source.settingsTab === 'string' ? source.settingsTab : vm.settingsTab,
112
114
  skillsTargetApp: source.skillsTargetApp === 'claude' || source.skillsTargetApp === 'codex' || source.skillsTargetApp === 'pi'
113
115
  ? source.skillsTargetApp
@@ -347,6 +349,8 @@ export function createWebUiPreferencesMethods(options = {}) {
347
349
  promptsPreviewCollapsed: normalizeBoolean(hasOwn(source, 'promptsPreviewCollapsed') ? source.promptsPreviewCollapsed : this.promptsPreviewCollapsed, true),
348
350
  sysPromptScope: normalizeSysPromptScope(hasOwn(source, 'sysPromptScope') ? source.sysPromptScope : this.sysPromptScope),
349
351
  sysPromptMode: normalizeSysPromptMode(hasOwn(source, 'sysPromptMode') ? source.sysPromptMode : this.sysPromptMode),
352
+ sysPromptFileName: typeof source.sysPromptFileName === 'string'
353
+ ? source.sysPromptFileName : (this.sysPromptFileName || ''),
350
354
  promptPresets: normalizePromptPresets(hasOwn(source, 'promptPresets') ? source.promptPresets : this.promptPresets),
351
355
  projectClaudeMdPath: typeof source.projectClaudeMdPath === 'string'
352
356
  ? source.projectClaudeMdPath
@@ -414,6 +418,9 @@ export function createWebUiPreferencesMethods(options = {}) {
414
418
  if (typeof source.sysPromptMode === 'string') {
415
419
  this.sysPromptMode = normalizeSysPromptMode(source.sysPromptMode);
416
420
  }
421
+ if (typeof source.sysPromptFileName === 'string') {
422
+ this.sysPromptFileName = source.sysPromptFileName;
423
+ }
417
424
  if (Array.isArray(source.promptPresets)) {
418
425
  this.promptPresets = normalizePromptPresets(source.promptPresets);
419
426
  if (this.selectedPromptPresetId && !this.promptPresets.some(preset => preset.id === this.selectedPromptPresetId)) {
@@ -481,6 +488,11 @@ export function createWebUiPreferencesMethods(options = {}) {
481
488
  if (Array.isArray(source.deletedClaudeSettingsImports)) {
482
489
  this.deletedClaudeSettingsImports = source.deletedClaudeSettingsImports;
483
490
  }
491
+ const modelTestTarget = source.navigation && source.navigation.modelTestTarget;
492
+ if (modelTestTarget === 'codex' || modelTestTarget === 'pi') {
493
+ if (typeof this.setModelTestTarget === 'function') this.setModelTestTarget(modelTestTarget);
494
+ else this.modelTestTarget = modelTestTarget;
495
+ }
484
496
  if (shouldApplyNavigation && source.navigation && typeof source.navigation === 'object') {
485
497
  const nav = source.navigation;
486
498
  if (typeof nav.settingsTab === 'string' && typeof this.normalizeSettingsTab === 'function') {
@@ -1,4 +1,103 @@
1
1
  const en = Object.freeze({
2
+ "modelTest.title": "Live test",
3
+ "modelTest.selection": "Choose a test model",
4
+ "modelTest.source": "Configuration source",
5
+ "modelTest.selectModel": "Select a model",
6
+ "modelTest.prompt": "Your message",
7
+ "modelTest.run": "Send test",
8
+ "modelTest.running": "Testing…",
9
+ "modelTest.completed": "Replied",
10
+ "modelTest.failed": "Test failed",
11
+ "modelTest.seconds": "{seconds} s",
12
+ "modelTest.loading": "Loading configured models…",
13
+ "modelTest.empty": "No configured models.",
14
+ "modelTest.required": "Enter a message and select a configured model.",
15
+ "modelTest.incomplete": "The reply reached the output limit and is incomplete.",
16
+
17
+ "routing.openai.purpose": "Expose a model routing API for OpenAI-compatible clients, with primary and backup models.",
18
+ "routing.openai.active": "OpenAI Chat configured for “{name}”.",
19
+ "routing.openai.off": "API disabled. Create a group and click Enable this group.",
20
+ "routing.openai.bindingHint": "Enabling a group activates this API; stopping it never falls back to Codex or Claude.",
21
+ "routing.openai.disable": "Disable API access",
22
+ "routing.openai.providers": "Reuse providers managed in Codex configuration, calling only Chat Completions. Codex need not be installed; neither native agent connection is changed.",
23
+ "routing.openai.baseUrl": "Client Base URL",
24
+ "routing.openai.model": "Client model ID",
25
+ "routing.openai.auth": "Use the CODEXMATE_HTTP_TOKEN access token as the client API key, not a provider secret. This token also grants access to the management API.",
26
+ "routing.openai.localOnly": "Without an access token, only loopback clients are allowed. If a client requires an API key, use local; it is never forwarded upstream.",
27
+ "routing.openai.alias": "routing is a fixed entry alias; the group selects the actual upstream models.",
28
+ "routing.openai.permission": "Group management uses Codex provider write access. Granting it allows local Codex configuration changes; enabling this group only saves routing selection.",
29
+ "routing.openai.use": "Enter the address and model ID below in an OpenAI-compatible client.",
30
+ "routing.purpose": "Set the model order for {agent}: choose a primary, then add backups if needed.",
31
+ "routing.help.title": "How it works and limits",
32
+ "routing.help.scope": "This page routes model requests. It does not start agents, run tasks or combine answers. Enabled means configuration is connected, not that a provider has passed a live check.",
33
+ "routing.help.errors": "Try the next group member only before output starts on HTTP 408 (timeout), 429 (rate limit) or 5xx (server error). Other 4xx errors and started replies never trigger a switch.",
34
+ "routing.help.model": "A provider supplies models. Name the group freely; enter a supported model ID for each group member, not a nickname. Existing configuration is prefilled; unknown IDs stay blank.",
35
+ "routing.start.create": "Create a model group: choose a primary; backups are optional.",
36
+ "routing.start.save": "Save the group.",
37
+ "routing.start.enable": "Click Enable this group.",
38
+ "routing.start.use": "After first activation, restart the selected agent and ask there.",
39
+ "routing.role.primary": "Primary",
40
+ "routing.role.backup": "Backup {index}",
41
+ "routing.role.member": "Model {index}",
42
+ "routing.editActive": "Editing an enabled group. Saved changes affect later requests; the current request is not replayed.",
43
+ "routing.defaultName": "{target} model group {index}",
44
+ "routing.nameRequired": "Enter a model group name.",
45
+ "routing.memberRequired": "Select a provider and enter a model for member {index}.",
46
+ "routing.memberMissing": "Member {index} has an unavailable provider. Replace or remove it.",
47
+ "routing.memberDuplicate": "Member {index} duplicates another member. Change its model or remove it.",
48
+ "routing.notActive": "This group is not active in the configuration. Refresh to check.",
49
+ "routing.activationUnconfirmed": "Binding completed; activation is unconfirmed. Refresh to check: {message}",
50
+ "routing.groupActivated": "“{name}” configured. For first use, restart the selected agent, then ask there.",
51
+ "routing.noProviders": "No selectable providers here yet. Add or check them in configuration.",
52
+ "routing.modelHint": "Enter a model ID supported by this provider",
53
+ "routing.inUse": "Enabled",
54
+ "routing.awaitingEnable": "Awaiting activation",
55
+ "routing.working": "Working…",
56
+ "routing.restorePool": "Stop using this group",
57
+ "routing.useGroup": "Enable this group",
58
+ "routing.bindEnable": "Enable this group",
59
+ "tab.routing": "Model test",
60
+ "kicker.routing": "",
61
+ "title.routing": "Model test",
62
+ "subtitle.routing": "",
63
+ "routing.target": "Connection target",
64
+ "routing.refresh": "Refresh",
65
+ "routing.create": "New model group",
66
+ "routing.failed": "Model routing setup did not finish.",
67
+ "routing.updated": "Model routing settings saved.",
68
+ "routing.loading": "Reading model routing settings",
69
+ "routing.bindingHint": "Creating a group does not enable it. For first use, click Enable this group.",
70
+ "routing.readOnly": "View only. Write access allows changes to this agent’s local configuration.",
71
+ "routing.edit": "Edit model group",
72
+ "routing.name": "Group name",
73
+ "routing.strategy": "Model selection",
74
+ "routing.strategy.order": "Primary first",
75
+ "routing.strategy.rotate": "Take turns",
76
+ "routing.strategy.order.hint": "Use the primary first; try backups on timeouts, rate limits or server errors before output starts.",
77
+ "routing.strategy.rotate.hint": "Rotate the preferred model per request, not multiple answers together.",
78
+ "routing.provider": "Provider",
79
+ "routing.model": "Model",
80
+ "routing.selectProvider": "Select provider",
81
+ "routing.unavailable": "Missing or excluded",
82
+ "routing.moveUp": "Move member up",
83
+ "routing.moveDown": "Move member down",
84
+ "routing.removeMember": "Remove member",
85
+ "routing.addMember": "Add member",
86
+ "routing.save": "Save",
87
+ "routing.empty": "No model groups yet. Follow these steps.",
88
+ "routing.openConfig": "Open configuration",
89
+ "routing.bound": "Bound",
90
+ "routing.memberCount": "View {count} model configurations",
91
+ "routing.unbind": "Unbind",
92
+ "routing.bind": "Bind only",
93
+ "routing.delete": "Delete",
94
+ "routing.deleteConfirm": "Delete routing group “{name}”? This cannot be undone.",
95
+ "routing.bridge.disable": "Restore agent configuration",
96
+ "routing.bridge.enable": "Connect model routing",
97
+ "routing.state.group": "Agent configured to use “{name}”.",
98
+ "routing.state.legacy": "Connected configuration; no model group selected.",
99
+ "routing.state.pending": "Enabled, but agent configuration is not connected.",
100
+ "routing.state.off": "Not enabled. Choose a group and click Enable this group.",
2
101
  "features.searchScope": "Search scope",
3
102
  "features.moreFilters": "More filters",
4
103
  "features.bookmarkHint": "Use the bookmark icon beside a message to keep useful excerpts.",
@@ -28,7 +127,11 @@ const en = Object.freeze({
28
127
  "features.index": "Full-text index",
29
128
  "features.refreshIndex": "Refresh index",
30
129
  "features.indexStatus": "{count} sessions indexed; refresh {processed}/{total}",
31
- "features.indexScope": "Covers discovered candidates only. Uses source, project and role filters above. Refresh for new messages.",
130
+ "features.indexCatalogTime": "Index catalog updated (UTC): {time}",
131
+ "features.indexSourceCoverage": "{source}: {count} candidates discovered; discovery limit {limit}",
132
+ "features.indexUnknown": "Unknown",
133
+ "features.indexCoverageUnknown": "No coverage record for the current source. Refresh the index.",
134
+ "features.indexScope": "Search covers indexed candidates, not all history or new messages. Catalog time is not a per-source sync time. Uses source, project and role filters above. Refresh for new messages.",
32
135
  "features.indexFailures": "{count} read failures; these records are not covered",
33
136
  "features.coverage": "Searched {scanned}/{total} indexed sessions",
34
137
  "features.partial": "Partial coverage; at most 100 matches are shown",
@@ -363,6 +466,7 @@ const en = Object.freeze({
363
466
  'side.update.availableWithVersion': 'Update available v{version}',
364
467
  'side.update.meta': 'Open update command',
365
468
  'side.update.metaVersions': 'Current v{current} → latest v{latest}',
469
+ 'side.update.commandHint': 'Run this in a terminal on the host running Codex Mate. Restart the service after a successful update.',
366
470
  'side.update.checkFailed': 'Failed to check latest version',
367
471
  'side.update.check': 'Check for updates',
368
472
  'side.update.checking': 'Checking for updates…',
@@ -483,7 +587,6 @@ const en = Object.freeze({
483
587
  'prompts.project.pathLabel': 'Project path (optional)',
484
588
  'prompts.project.selectPlaceholder': '-- Global (~/.claude/CLAUDE.md) --',
485
589
  'prompts.project.manualPlaceholder': 'Or enter a project root path...',
486
- 'prompts.project.detected': 'Editing CLAUDE.md in: {path}',
487
590
  'dashboard.doctor.title': 'Doctor',
488
591
  'dashboard.doctor.runChecks': 'Run checks',
489
592
  'dashboard.doctor.checking': 'Checking...',
@@ -582,11 +685,28 @@ const en = Object.freeze({
582
685
 
583
686
  // Plugins panel
584
687
  'plugins.sidebar.title': 'Plugins',
585
- 'plugins.sidebar.note': 'Reusable, standardized utilities. Future custom plugins should follow the same structure.',
586
688
  'plugins.sidebar.ariaList': 'Plugin list',
587
689
  'plugins.catalog.promptTemplates.title': 'Prompt templates',
588
690
  'plugins.catalog.promptTemplates.description': 'Standardized, template-driven prompt tools with variables, copy, and export helpers.',
589
691
  'plugins.status.standard': 'standard',
692
+ 'plugins.fileSharing.title': 'File sharing',
693
+ 'plugins.fileSharing.chooseFiles': 'Choose files',
694
+ 'plugins.fileSharing.chooseFolder': 'Choose folder',
695
+ 'plugins.fileSharing.confirm': 'Upload only the files listed below. Anyone authorized to access this Web instance can download them.',
696
+ 'plugins.fileSharing.upload': 'Upload',
697
+ 'plugins.fileSharing.empty': 'No shared files',
698
+ 'plugins.fileSharing.files': '{count} files',
699
+ 'plugins.fileSharing.remove': 'Remove share',
700
+ 'plugins.fileSharing.bytes': '{size} bytes',
701
+ 'plugins.fileSharing.download': 'Download',
702
+ 'plugins.fileSharing.copyLink': 'Copy LAN download link',
703
+ 'plugins.fileSharing.copyManually': 'Copy this download link manually.',
704
+ 'plugins.fileSharing.lanUnavailable': 'No private IPv4 interface is available, or the download port could not be opened.',
705
+ 'plugins.fileSharing.emptyFolder': 'Choose a folder containing at least one file.',
706
+ 'plugins.fileSharing.invalid': 'Invalid upload or path.',
707
+ 'plugins.fileSharing.busy': 'Another upload is in progress. Try again later.',
708
+ 'plugins.fileSharing.notFound': 'This share is no longer available. Refresh the list.',
709
+ 'plugins.fileSharing.failed': 'File sharing request failed. Try again.',
590
710
  'plugins.catalog.textTools.title': 'Text tools',
591
711
  'plugins.catalog.textTools.description': 'A set of lightweight plain-text utilities; the first tool compresses multi-line text into a single line.',
592
712
  'plugins.textTools.title': 'Text tools',
@@ -611,12 +731,10 @@ const en = Object.freeze({
611
731
  'plugins.promptTemplates.compose.chooseTemplateHint': 'Select a template to start composing.',
612
732
  'plugins.promptTemplates.compose.builtinSuffix': ' (built-in)',
613
733
  'plugins.promptTemplates.compose.empty': 'No templates available.',
614
- 'plugins.promptTemplates.compose.varsHint': 'Fill and add variables in “Manage”.',
615
734
  'plugins.promptTemplates.compose.missingCount': '{count} missing',
616
735
  'plugins.promptTemplates.compose.jumpToMissing': 'Jump to missing',
617
736
  'plugins.promptTemplates.compose.goManage': 'Manage variables',
618
737
  'plugins.promptTemplates.compose.outputTitle': 'Output',
619
- 'plugins.promptTemplates.compose.outputHint': 'Click “Copy” and paste into Codex/Claude.',
620
738
  'plugins.promptTemplates.compose.outputAria': 'Rendered prompt',
621
739
  'plugins.promptTemplates.compose.copy': 'Copy',
622
740
  'plugins.promptTemplates.manage.searchAria': 'Search templates',
@@ -1019,6 +1137,21 @@ const en = Object.freeze({
1019
1137
  'sessions.roleLabel.assistant': 'Assistant',
1020
1138
 
1021
1139
  // Usage panel
1140
+ "usage.records.title": "Usage record breakdown",
1141
+ "usage.records.scope": "Records use UTC dates: Codex cumulative deltas, Claude/Pi assistant usage and Gemini tokens from supported JSON sessions. Gemini totals include reasoning/tool tokens; cache reads are an input subset. Missing fields stay unknown. Existing charts use session update dates. Full-text estimates stay separate and do not represent cost.",
1142
+ "usage.records.coverage": "Scanned {scanned}/{candidates} candidate sessions; {unreported} without usage records, {unsupported} with unsupported record sources.",
1143
+ "usage.records.failed": "{count} sessions failed to load. Results are incomplete; refresh to retry.",
1144
+ "usage.records.total": "Recorded tokens",
1145
+ "usage.records.estimated": "Full-text estimated tokens",
1146
+ "usage.records.cacheRead": "Cache read",
1147
+ "usage.records.cacheWrite": "Cache write",
1148
+ "usage.records.unknown": "Unknown",
1149
+ "usage.records.date": "Date (UTC)",
1150
+ "usage.records.source": "Source",
1151
+ "usage.records.model": "Model",
1152
+ "usage.records.input": "Input",
1153
+ "usage.records.output": "Output",
1154
+ "usage.records.undated": "Tokens without record timestamps: {tokens}; not assigned to a day.",
1022
1155
  'usage.overview': 'Usage Overview',
1023
1156
  'usage.range.aria': 'Usage time range',
1024
1157
  'usage.range.7d': 'Last 7 days',
@@ -1354,6 +1487,7 @@ const en = Object.freeze({
1354
1487
  'settings.theme.light': 'Light',
1355
1488
  'settings.theme.dark': 'Dark',
1356
1489
  'settings.theme.ocean': 'Ocean',
1490
+ 'settings.theme.violet': 'Violet',
1357
1491
  'settings.theme.hint': 'Theme preference is saved automatically and persists across reloads.',
1358
1492
  'settings.sharePrefix.title': 'Share command prefix',
1359
1493
  'settings.sharePrefix.meta': 'Used as the prefix for “Copy share command” in the Web UI',
@@ -1736,6 +1870,10 @@ const en = Object.freeze({
1736
1870
  'kilocode.writeRequired': 'Enable KiloCode write access first',
1737
1871
  'kilocode.saved': 'KiloCode config saved',
1738
1872
  'kilocode.autoSaved': 'KiloCode config synced',
1873
+ 'sysPrompt.fileLabel': 'File',
1874
+ 'sysPrompt.filesLoading': 'Loading files…',
1875
+ 'sysPrompt.fileMissing': 'File removed or unreadable. Refresh the file list.',
1876
+ 'sysPrompt.fileUnsaved': 'Save or cancel your changes before switching files.',
1739
1877
  'sysPrompt.scope.label': 'Scope',
1740
1878
  'sysPrompt.scope.global': 'Global (~/.pi/agent/)',
1741
1879
  'sysPrompt.scope.project': 'Project (<cwd>/.pi/)',
@@ -1746,6 +1884,102 @@ const en = Object.freeze({
1746
1884
  'sysPrompt.hint.unsaved': 'Unsaved changes detected',
1747
1885
  'sysPrompt.hint.twoStepSave': 'Click preview to see the diff, then confirm to save.',
1748
1886
  'sysPrompt.toast.saved': 'System prompt saved',
1887
+ "evidence.title": "Cross-session evidence pack",
1888
+ "evidence.select": "Add to evidence pack",
1889
+ "evidence.remove": "Remove",
1890
+ "evidence.goal": "Handoff goal",
1891
+ "evidence.generate": "Generate evidence pack",
1892
+ "evidence.preview": "Preview ({count} characters)",
1893
+ "evidence.download": "Download Markdown",
1894
+ "evidence.memory": "Selections stay in this page only; reload clears them, not original records.",
1895
+ "evidence.scope": "Extracted historical selections only; not sent, current version not verified.",
1896
+ "evidence.path": "Source path",
1897
+ "evidence.status": "Historical evidence status",
1898
+ "evidence.passed": "Historical tool log reports success; current version unverified",
1899
+ "evidence.failed": "Historical tool log reports failure",
1900
+ "evidence.unverified": "Needs review",
1901
+ "evidence.changed": "Source changed; update the index and select again.",
1902
+ "evidence.limit": "Select up to 100 items.",
1903
+ "artifacts.format": "Output format",
1904
+ "artifacts.receipt": "Development receipt",
1905
+ "artifacts.relay": "Multi-agent relay pack",
1906
+ "artifacts.generate.receipt": "Generate development receipt",
1907
+ "artifacts.generate.relay": "Generate relay pack",
1908
+ "artifacts.scope": "Generated locally from selected historical material only. Not sent or executed; the current version has not been accepted.",
1909
+ "artifacts.goal": "Goal (user supplied)",
1910
+ "artifacts.note": "Additional notes (user supplied, optional)",
1911
+ "artifacts.notePlaceholder": "Add a change reason, next step or acceptance criteria; notes are not verification evidence.",
1912
+ "artifacts.unspecified": "Not supplied; add manually.",
1913
+ "artifacts.checks": "Historical check records",
1914
+ "artifacts.noVerdict": "Record counts do not prove task completion or passing tests on the current version. Source excerpts follow.",
1915
+ "artifacts.sources": "Selected material and sources",
1916
+ "artifacts.executor": "Stage 1: Executor",
1917
+ "artifacts.executorTask": "Check the goal, original sources and authorized scope. Act only with explicit authorization; stop for unclear goals or invalid sources. Report actual changes, checks, failures and unverified items. Do not replay historical commands.",
1918
+ "artifacts.reviewer": "Stage 2: Reviewer",
1919
+ "artifacts.reviewerTask": "Review executor results, original sources and the current version read-only. Separate facts, inferences and missing evidence. Delivery or self-reported reading does not mean completion. List the remaining manual acceptance steps.",
1920
+ "artifacts.uat": "Manual UAT: pending, not accepted",
1921
+ "artifacts.uatTask": "Retest the goal through its real entry on the version under review. Record observable results and failure criteria. Historical logs, handoffs and self-reported reading do not replace current acceptance.",
1922
+
1923
+ "collections.title": "Evidence collections",
1924
+ "collections.scope": "Only explicitly saved names, goals and source references persist. Opening replaces the temporary basket; reload requires reopening. Original sessions are not backed up.",
1925
+ "collections.name": "Collection name",
1926
+ "collections.save": "Save collection",
1927
+ "collections.saveAs": "Save as new",
1928
+ "collections.remove": "Remove collection",
1929
+ "collections.refresh": "Refresh collections",
1930
+ "collections.empty": "No saved collections",
1931
+ "collections.state.ready": "Source matches",
1932
+ "collections.state.changed": "Source changed",
1933
+ "collections.state.unavailable": "Source unavailable",
1934
+ "stories.title": "Development story",
1935
+ "stories.scope": "Explicit user links do not prove authorship or passing tests. Local metadata only; no Git writes or uploads.",
1936
+ "stories.linked": "User-linked",
1937
+ "stories.unavailable": "Session is outside current discovered candidates",
1938
+ "stories.session": "Linked session",
1939
+ "stories.choose": "Choose a current project session",
1940
+ "stories.note": "Reason for change",
1941
+ "stories.save": "Save link",
1942
+ "stories.remove": "Remove link",
1943
+ "stories.refresh": "Refresh links",
1944
+ "features.error.collection-input-invalid": "Check the collection name, goal and selected references",
1945
+ "features.error.collection-not-found": "Collection was removed; refresh the list",
1946
+ "features.error.collection-source-unavailable": "Source changed or is unavailable; update the index and reselect",
1947
+ "features.error.story-input-invalid": "Check the project, full commit SHA and note",
1948
+ "features.error.story-project-unavailable": "Project is outside current discovery",
1949
+ "features.error.story-session-unavailable": "Session is outside current project candidates",
1950
+ "features.error.story-not-found": "Link was removed; refresh the list",
1951
+ "features.error.project-git-commit-invalid": "Commit is outside the current project’s latest 30 commits",
1952
+
1953
+ "pricing.title": "Cost reference (USD)",
1954
+ "pricing.scope": "Estimate using bundled base text-token rates, not a bill. Excludes tiers, service levels, cache durations, tools and multimodal extras; does not infer historical billing providers.",
1955
+ "pricing.total": "Reference total",
1956
+ "pricing.subtotal": "Known-row subtotal",
1957
+ "pricing.coverage": "Priced {known}; unknown {unknown}; failed {failed}; unreported {unreported}; unsupported {unsupported}",
1958
+ "pricing.basis": "Basis",
1959
+ "pricing.rates": "Per million tokens: input {input} / output {output} / cache read {cached} / cache write {created}",
1960
+ "pricing.download": "Download price reference JSON",
1961
+ "pricing.reason.base-rate": "Base-rate estimate",
1962
+ "pricing.reason.model-unknown": "Model price unknown",
1963
+ "pricing.reason.usage-incomplete": "Incomplete token categories",
1964
+ "pricing.reason.usage-unclassified": "Unclassified tokens",
1965
+ "pricing.reason.rate-missing": "Category rate missing",
1966
+
1967
+ "git.title": "Git change associations (read-only)",
1968
+ "git.scope": "Inspect the current project repository. Candidates are commits within 24 hours of session update time, not causation or passed tests. Never writes Git or uploads sessions.",
1969
+ "git.detached": "Detached HEAD",
1970
+ "git.noHead": "No commits",
1971
+ "git.changes": "{count} changed files",
1972
+ "git.truncated": "Limited to 30 commits and 50 changed files; this list is truncated.",
1973
+ "git.candidate": "Time-based candidate",
1974
+ "git.refresh": "Refresh Git",
1975
+ "git.status.ready": "Current Git state loaded",
1976
+ "git.status.unborn": "Repository has no commits",
1977
+ "git.status.not-repository": "Not a Git repository",
1978
+ "git.status.path-unavailable": "Project path unavailable",
1979
+ "git.status.git-unavailable": "Git not found",
1980
+ "git.status.read-timeout": "Git read timed out",
1981
+ "git.status.read-failed": "Git read failed",
1982
+
1749
1983
  });
1750
1984
 
1751
1985
  export { en };