total-recall-brain 3.1.2 → 3.2.2

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 (63) hide show
  1. package/extension/background.js +99 -0
  2. package/extension/content-script.css +16 -0
  3. package/extension/content-script.js +134 -0
  4. package/extension/icons/README.md +27 -0
  5. package/extension/icons/icon-128.png +0 -0
  6. package/extension/icons/icon-16.png +0 -0
  7. package/extension/icons/icon-48.png +0 -0
  8. package/extension/lib/brain-client.js +47 -0
  9. package/extension/manifest.json +39 -0
  10. package/extension/options/options.css +218 -0
  11. package/extension/options/options.html +72 -0
  12. package/extension/options/options.js +99 -0
  13. package/extension/popup/popup.css +221 -0
  14. package/extension/popup/popup.html +44 -0
  15. package/extension/popup/popup.js +107 -0
  16. package/extension/sidepanel/sidepanel.css +340 -0
  17. package/extension/sidepanel/sidepanel.html +38 -0
  18. package/extension/sidepanel/sidepanel.js +229 -0
  19. package/frontend/README.md +73 -0
  20. package/frontend/index.html +17 -0
  21. package/frontend/package.json +31 -0
  22. package/frontend/src/App.css +2 -0
  23. package/frontend/src/App.tsx +390 -0
  24. package/frontend/src/api.ts +688 -0
  25. package/frontend/src/assets/hero.png +0 -0
  26. package/frontend/src/assets/react.svg +1 -0
  27. package/frontend/src/assets/vite.svg +1 -0
  28. package/frontend/src/components/BrainSelector.tsx +272 -0
  29. package/frontend/src/components/DaemonLogsTab.tsx +54 -0
  30. package/frontend/src/components/Graph3D.tsx +850 -0
  31. package/frontend/src/components/MarkdownUtils.tsx +99 -0
  32. package/frontend/src/components/ResearchAgendaTab.tsx +707 -0
  33. package/frontend/src/components/TaskQueueTab.tsx +185 -0
  34. package/frontend/src/index.css +1589 -0
  35. package/frontend/src/main.tsx +10 -0
  36. package/frontend/src/pages/ApiKeysPage.tsx +288 -0
  37. package/frontend/src/pages/AutomationsPage.tsx +354 -0
  38. package/frontend/src/pages/ChatPage.tsx +831 -0
  39. package/frontend/src/pages/DeploymentsPage.tsx +275 -0
  40. package/frontend/src/pages/FilesPage.tsx +384 -0
  41. package/frontend/src/pages/HealthPage.tsx +91 -0
  42. package/frontend/src/pages/IntegrationsPage.tsx +382 -0
  43. package/frontend/src/pages/LoginPage.tsx +237 -0
  44. package/frontend/src/pages/MemoryPage.tsx +1192 -0
  45. package/frontend/src/pages/SandboxPage.tsx +113 -0
  46. package/frontend/src/pages/SettingsPage.tsx +662 -0
  47. package/frontend/src/pages/SkillsPage.tsx +618 -0
  48. package/frontend/src/pages/TasksPage.tsx +392 -0
  49. package/frontend/src/pages/UsagePage.tsx +260 -0
  50. package/frontend/src/types.ts +163 -0
  51. package/frontend/tsconfig.app.json +25 -0
  52. package/frontend/tsconfig.json +7 -0
  53. package/frontend/tsconfig.node.json +24 -0
  54. package/frontend/vite.config.ts +24 -0
  55. package/package.json +8 -1
  56. package/scaffold/.agent/skills/total-recall/memory-vault/concepts/cli-help-reference.md +35 -8
  57. package/scaffold/.agent/skills/total-recall/memory-vault/invariants/operating-instructions.md +13 -8
  58. package/scaffold/.agent/skills/total-recall/memory-vault/preferences/always-websearch-gap.md +28 -1
  59. package/scaffold/.agent/skills/total-recall/memory-vault/preferences/topic-research-sop.md +28 -1
  60. package/scaffold/.agent/skills/total-recall/skills/ssss/references/ssss-spec.md +830 -81
  61. package/src/cli/backup.mjs +172 -1
  62. package/src/cli/setup.mjs +24 -0
  63. package/src/server/rest.mjs +56 -7
@@ -0,0 +1,185 @@
1
+ import React from 'react'
2
+ import type { Task } from '../types'
3
+
4
+ interface TaskQueueTabProps {
5
+ tasks: Task[]
6
+ loading: boolean
7
+ showTaskForm: boolean
8
+ setShowTaskForm: (v: boolean) => void
9
+ taskCategory: string
10
+ setTaskCategory: (v: string) => void
11
+ taskTarget: string
12
+ setTaskTarget: (v: string) => void
13
+ taskBody: string
14
+ setTaskBody: (v: string) => void
15
+ taskSubmitting: boolean
16
+ handleCreateTask: (e: React.FormEvent) => void
17
+ }
18
+
19
+ export default function TaskQueueTab(props: TaskQueueTabProps) {
20
+ const {
21
+ tasks,
22
+ loading,
23
+ showTaskForm,
24
+ setShowTaskForm,
25
+ taskCategory,
26
+ setTaskCategory,
27
+ taskTarget,
28
+ setTaskTarget,
29
+ taskBody,
30
+ setTaskBody,
31
+ taskSubmitting,
32
+ handleCreateTask,
33
+ } = props
34
+
35
+ return (
36
+ <div>
37
+ <div style={{ display: 'flex', justifyContent: 'space-between', alignItems: 'center', marginBottom: 16 }}>
38
+ <h3 style={{ margin: 0 }}>Active Scheduler Tasks</h3>
39
+ <button
40
+ className="btn btn-sm btn-ghost"
41
+ onClick={() => setShowTaskForm(!showTaskForm)}
42
+ style={{ borderColor: 'var(--border)' }}
43
+ >
44
+ {showTaskForm ? 'Cancel' : '+ Add Custom Task'}
45
+ </button>
46
+ </div>
47
+
48
+ {/* Collapsible Task Form */}
49
+ {showTaskForm && (
50
+ <form onSubmit={handleCreateTask} style={{
51
+ background: 'var(--bg-secondary)',
52
+ border: '1px solid var(--border)',
53
+ borderRadius: 12,
54
+ padding: 20,
55
+ marginBottom: 20,
56
+ display: 'flex',
57
+ flexDirection: 'column',
58
+ gap: 12
59
+ }}>
60
+ <div style={{ display: 'grid', gridTemplateColumns: '1fr 2fr', gap: 16 }}>
61
+ <label style={{ display: 'flex', flexDirection: 'column', gap: 6, fontSize: 12, color: 'var(--text-secondary)' }}>
62
+ Subsystem Category
63
+ <select
64
+ value={taskCategory}
65
+ onChange={e => setTaskCategory(e.target.value)}
66
+ style={{
67
+ padding: '8px 10px',
68
+ borderRadius: 8,
69
+ background: 'var(--bg-primary)',
70
+ color: 'var(--text-primary)',
71
+ border: '1px solid var(--border)',
72
+ outline: 'none'
73
+ }}
74
+ >
75
+ <option value="fact-seeker">Fact Seeker</option>
76
+ <option value="post-mortem-daily">Post Mortem Daemon</option>
77
+ <option value="clarity-rewriter">Clarity Rewriter</option>
78
+ <option value="drift-detector">Drift Detector</option>
79
+ <option value="dream">Dream Cycle</option>
80
+ </select>
81
+ </label>
82
+ <label style={{ display: 'flex', flexDirection: 'column', gap: 6, fontSize: 12, color: 'var(--text-secondary)' }}>
83
+ Target Operation / Description
84
+ <input
85
+ type="text"
86
+ required
87
+ placeholder="e.g. Audit security.yml files for weak encryption configs"
88
+ value={taskTarget}
89
+ onChange={e => setTaskTarget(e.target.value)}
90
+ style={{
91
+ padding: '8px 10px',
92
+ borderRadius: 8,
93
+ background: 'var(--bg-primary)',
94
+ color: 'var(--text-primary)',
95
+ border: '1px solid var(--border)',
96
+ outline: 'none'
97
+ }}
98
+ />
99
+ </label>
100
+ </div>
101
+ <label style={{ display: 'flex', flexDirection: 'column', gap: 6, fontSize: 12, color: 'var(--text-secondary)' }}>
102
+ Verification Payload Body (Optional Markdown)
103
+ <textarea
104
+ placeholder="Additional context or markdown checklist rules..."
105
+ value={taskBody}
106
+ onChange={e => setTaskBody(e.target.value)}
107
+ style={{
108
+ padding: '10px',
109
+ borderRadius: 8,
110
+ background: 'var(--bg-primary)',
111
+ color: 'var(--text-primary)',
112
+ border: '1px solid var(--border)',
113
+ outline: 'none',
114
+ minHeight: 80,
115
+ resize: 'vertical'
116
+ }}
117
+ />
118
+ </label>
119
+ <button
120
+ type="submit"
121
+ className="btn btn-primary"
122
+ disabled={taskSubmitting || !taskTarget.trim()}
123
+ style={{ alignSelf: 'flex-end', minWidth: 120 }}
124
+ >
125
+ {taskSubmitting ? 'Enqueuing...' : 'Create Task'}
126
+ </button>
127
+ </form>
128
+ )}
129
+
130
+ {/* Tasks Grid */}
131
+ <div className="card-grid" style={{ display: 'flex', flexDirection: 'column', gap: 12 }}>
132
+ {loading && tasks.length === 0 ? (
133
+ [1, 2, 3].map(i => <div key={i} className="skeleton" style={{ height: 68 }} />)
134
+ ) : tasks.length === 0 ? (
135
+ <div style={{
136
+ textAlign: 'center',
137
+ padding: '50px 20px',
138
+ color: 'var(--text-tertiary)',
139
+ border: '1px dashed var(--border)',
140
+ borderRadius: 12
141
+ }}>
142
+ No tasks are currently running.
143
+ <br />
144
+ <span style={{ fontSize: 12 }}>Click <strong>Seed Gaps</strong> above to trigger autonomous background schedules.</span>
145
+ </div>
146
+ ) : (
147
+ tasks.map(t => (
148
+ <div key={t.slug} className="card" style={{
149
+ padding: '16px 20px',
150
+ display: 'flex',
151
+ justifyContent: 'space-between',
152
+ alignItems: 'center',
153
+ background: 'var(--bg-secondary)',
154
+ border: '1px solid var(--border)',
155
+ borderRadius: 12
156
+ }}>
157
+ <div style={{ flex: 1, marginRight: 16 }}>
158
+ <div style={{ display: 'flex', alignItems: 'center', gap: 8, marginBottom: 4 }}>
159
+ <span className="badge badge-accent" style={{ fontSize: 11 }}>{t.category}</span>
160
+ <h4 style={{ margin: 0, fontSize: 14, fontWeight: 600 }}>{t.target}</h4>
161
+ </div>
162
+ {t.body && (
163
+ <p style={{ margin: '6px 0 0', fontSize: 12, color: 'var(--text-secondary)', lineBreak: 'anywhere' }}>
164
+ {t.body}
165
+ </p>
166
+ )}
167
+ <div style={{ display: 'flex', gap: 16, marginTop: 8, fontSize: 11, color: 'var(--text-tertiary)' }}>
168
+ <span>Ref: <code>{t.slug}</code></span>
169
+ <span>Priority Weight: {t.priority}</span>
170
+ </div>
171
+ </div>
172
+ <span className={`badge ${
173
+ t.status === 'completed' ? 'badge-success' :
174
+ t.status === 'failed' ? 'badge-error' :
175
+ 'badge-warning'
176
+ }`} style={{ textTransform: 'capitalize', minWidth: 80, textAlign: 'center' }}>
177
+ {t.status}
178
+ </span>
179
+ </div>
180
+ ))
181
+ )}
182
+ </div>
183
+ </div>
184
+ )
185
+ }