aura-code 0.3.6 → 0.5.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.
Files changed (109) hide show
  1. package/README.md +54 -2
  2. package/dist/agent/compactor.d.ts +26 -0
  3. package/dist/agent/compactor.js +156 -0
  4. package/dist/agent/compactor.js.map +1 -0
  5. package/dist/agent/design.d.ts +17 -0
  6. package/dist/agent/design.js +175 -0
  7. package/dist/agent/design.js.map +1 -0
  8. package/dist/agent/loop.js +8 -1
  9. package/dist/agent/loop.js.map +1 -1
  10. package/dist/agent/system-prompt.d.ts +1 -1
  11. package/dist/agent/system-prompt.js +5 -2
  12. package/dist/agent/system-prompt.js.map +1 -1
  13. package/dist/cli/display.js +40 -4
  14. package/dist/cli/display.js.map +1 -1
  15. package/dist/cli/index.js +258 -44
  16. package/dist/cli/index.js.map +1 -1
  17. package/dist/config/defaults.js +1 -1
  18. package/dist/config/defaults.js.map +1 -1
  19. package/dist/config/project-config.d.ts +6 -0
  20. package/dist/config/project-config.js +2 -0
  21. package/dist/config/project-config.js.map +1 -1
  22. package/dist/dream/dream.d.ts +48 -0
  23. package/dist/dream/dream.js +187 -0
  24. package/dist/dream/dream.js.map +1 -0
  25. package/dist/kanban/index.d.ts +5 -0
  26. package/dist/kanban/index.js +11 -0
  27. package/dist/kanban/index.js.map +1 -0
  28. package/dist/kanban/pipeline.d.ts +16 -0
  29. package/dist/kanban/pipeline.js +910 -0
  30. package/dist/kanban/pipeline.js.map +1 -0
  31. package/dist/kanban/server.d.ts +5 -0
  32. package/dist/kanban/server.js +820 -0
  33. package/dist/kanban/server.js.map +1 -0
  34. package/dist/kanban/types.d.ts +75 -0
  35. package/dist/kanban/types.js +6 -0
  36. package/dist/kanban/types.js.map +1 -0
  37. package/dist/learnlight/driven.d.ts +2 -0
  38. package/dist/learnlight/driven.js +109 -0
  39. package/dist/learnlight/driven.js.map +1 -0
  40. package/dist/learnlight/index.d.ts +4 -0
  41. package/dist/learnlight/index.js +32 -0
  42. package/dist/learnlight/index.js.map +1 -0
  43. package/dist/learnlight/lesson-prep.d.ts +36 -0
  44. package/dist/learnlight/lesson-prep.js +224 -0
  45. package/dist/learnlight/lesson-prep.js.map +1 -0
  46. package/dist/learnlight/report.d.ts +2 -0
  47. package/dist/learnlight/report.js +37 -0
  48. package/dist/learnlight/report.js.map +1 -0
  49. package/dist/learnlight/types.d.ts +72 -0
  50. package/dist/learnlight/types.js +6 -0
  51. package/dist/learnlight/types.js.map +1 -0
  52. package/dist/perception/graph-store.d.ts +11 -0
  53. package/dist/perception/graph-store.js +33 -0
  54. package/dist/perception/graph-store.js.map +1 -1
  55. package/dist/perception/index.d.ts +1 -1
  56. package/dist/perception/index.js +2 -1
  57. package/dist/perception/index.js.map +1 -1
  58. package/dist/providers/factory.d.ts +16 -0
  59. package/dist/providers/factory.js +72 -0
  60. package/dist/providers/factory.js.map +1 -1
  61. package/dist/providers/openai-compatible.js +80 -49
  62. package/dist/providers/openai-compatible.js.map +1 -1
  63. package/dist/research/council.d.ts +26 -0
  64. package/dist/research/council.js +225 -0
  65. package/dist/research/council.js.map +1 -0
  66. package/dist/research/research.d.ts +24 -0
  67. package/dist/research/research.js +116 -0
  68. package/dist/research/research.js.map +1 -0
  69. package/dist/ruby/alternator.d.ts +36 -1
  70. package/dist/ruby/alternator.js +40 -31
  71. package/dist/ruby/alternator.js.map +1 -1
  72. package/dist/ruby/stats.js +10 -11
  73. package/dist/ruby/stats.js.map +1 -1
  74. package/dist/ruby/types.js +1 -1
  75. package/dist/ruby/types.js.map +1 -1
  76. package/dist/safety/permissions.d.ts +8 -0
  77. package/dist/safety/permissions.js +12 -0
  78. package/dist/safety/permissions.js.map +1 -1
  79. package/dist/setup/provider-registry.js +14 -0
  80. package/dist/setup/provider-registry.js.map +1 -1
  81. package/dist/setup/provider-test.js +24 -2
  82. package/dist/setup/provider-test.js.map +1 -1
  83. package/dist/setup/telegram-wizard.d.ts +57 -0
  84. package/dist/setup/telegram-wizard.js +343 -0
  85. package/dist/setup/telegram-wizard.js.map +1 -0
  86. package/dist/tools/audio-transcribe.d.ts +20 -0
  87. package/dist/tools/audio-transcribe.js +39 -28
  88. package/dist/tools/audio-transcribe.js.map +1 -1
  89. package/dist/tools/gmail-tool.d.ts +11 -0
  90. package/dist/tools/gmail-tool.js +221 -0
  91. package/dist/tools/gmail-tool.js.map +1 -0
  92. package/dist/tools/read-file.js +13 -0
  93. package/dist/tools/read-file.js.map +1 -1
  94. package/dist/tools/telegram-bot.js +103 -18
  95. package/dist/tools/telegram-bot.js.map +1 -1
  96. package/dist/tools/telegram-voice.d.ts +22 -0
  97. package/dist/tools/telegram-voice.js +203 -0
  98. package/dist/tools/telegram-voice.js.map +1 -0
  99. package/dist/tools/telegram.d.ts +6 -1
  100. package/dist/tools/telegram.js +115 -5
  101. package/dist/tools/telegram.js.map +1 -1
  102. package/dist/tools/video-render.d.ts +11 -0
  103. package/dist/tools/video-render.js +189 -0
  104. package/dist/tools/video-render.js.map +1 -0
  105. package/dist/util/errors.js +6 -0
  106. package/dist/util/errors.js.map +1 -1
  107. package/dist/viz/index.js +816 -30
  108. package/dist/viz/index.js.map +1 -1
  109. package/package.json +3 -2
@@ -0,0 +1,187 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.lastDreamTimestamp = lastDreamTimestamp;
37
+ exports.runDream = runDream;
38
+ const fs = __importStar(require("fs"));
39
+ const path = __importStar(require("path"));
40
+ const episode_capture_js_1 = require("../ruby/episode-capture.js");
41
+ const factory_js_1 = require("../providers/factory.js");
42
+ const DREAMS_DIRNAME = 'dreams';
43
+ const STATE_FILENAME = '.last.json';
44
+ function dreamsDir(projectRoot) {
45
+ return path.join(projectRoot, DREAMS_DIRNAME);
46
+ }
47
+ /** Timestamp (ms) of the last dream for this project, or 0 if never. */
48
+ function lastDreamTimestamp(projectRoot) {
49
+ try {
50
+ const raw = fs.readFileSync(path.join(dreamsDir(projectRoot), STATE_FILENAME), 'utf8');
51
+ const parsed = JSON.parse(raw);
52
+ return typeof parsed.lastDreamTs === 'number' ? parsed.lastDreamTs : 0;
53
+ }
54
+ catch {
55
+ return 0;
56
+ }
57
+ }
58
+ function writeState(projectRoot, lastDreamTs) {
59
+ const dir = dreamsDir(projectRoot);
60
+ fs.mkdirSync(dir, { recursive: true });
61
+ fs.writeFileSync(path.join(dir, STATE_FILENAME), JSON.stringify({ lastDreamTs }, null, 2));
62
+ }
63
+ /** Compact, low-token digest of one episode for the consolidation prompt. */
64
+ function digestEpisode(ep) {
65
+ const tier = ep.rubySucceeded ? 'ruby' : ep.largeModelUsed ? `large(${ep.largeModelUsed})` : 'none';
66
+ const ok = ep.reviewerApproved ? 'approved' : 'unreviewed';
67
+ const secs = Math.round(ep.durationMs / 1000);
68
+ return `- [${ep.taskCategory}] "${ep.task.slice(0, 140)}" — tier=${tier}, ${ok}, ${secs}s`;
69
+ }
70
+ function buildConsolidationPrompt(episodes) {
71
+ const system = 'You are Aura consolidating a day of work into durable memory, like a brain dreaming. ' +
72
+ 'You are given digests of today\'s task episodes. Produce concise, reusable knowledge — ' +
73
+ 'not a transcript. Be specific and tagged. Respond in GitHub Markdown with EXACTLY these ' +
74
+ 'sections and nothing else:\n\n' +
75
+ '## Lessons\n(bullet list; each line starts with a [tag] in brackets, e.g. [routing], [tooling], [bug]. ' +
76
+ 'State what was learned, generalised beyond the single task.)\n\n' +
77
+ '## Patterns\n(bullet list of recurring task shapes or failure modes seen across episodes.)\n\n' +
78
+ '## Open threads\n(bullet list of unresolved problems worth picking up tomorrow; ' +
79
+ 'prefix each with [todo]. Empty bullet "- none" if nothing.)\n\n' +
80
+ '## Tomorrow brief\n(2–4 sentences: what Aura should be ready for next session.)';
81
+ const user = `Today's episodes (${episodes.length}):\n\n` +
82
+ episodes.map(digestEpisode).join('\n');
83
+ return { system, user };
84
+ }
85
+ function header(date, episodes, since) {
86
+ const succeeded = episodes.filter(e => e.reviewerApproved).length;
87
+ const rubyWins = episodes.filter(e => e.rubySucceeded).length;
88
+ const sinceStr = since > 0 ? new Date(since).toISOString() : 'beginning';
89
+ const cats = [...new Set(episodes.map(e => e.taskCategory))].join(', ') || '—';
90
+ return (`# Dream — ${date}\n\n` +
91
+ `> ${episodes.length} episodes recalled since ${sinceStr} · ` +
92
+ `${succeeded} approved · ${rubyWins} ruby wins\n` +
93
+ `> Categories: ${cats}\n`);
94
+ }
95
+ /**
96
+ * Run a dream. Pure with respect to I/O sources: caller supplies the provider.
97
+ * Never throws on an empty day — returns { skipped: true }.
98
+ *
99
+ * IMPORTANT: the `.last.json` state cutoff is only advanced when the LLM
100
+ * consolidation succeeds. If the primary provider fails, a single retry on a
101
+ * local Ollama instance is attempted before giving up gracefully. Episodes are
102
+ * NEVER burned (cut off) when the provider is unreachable.
103
+ */
104
+ async function runDream(opts) {
105
+ const { projectRoot, provider } = opts;
106
+ const ollamaFallbackModel = opts.ollamaFallbackModel === undefined ? 'llama3.2' : opts.ollamaFallbackModel;
107
+ const date = new Date().toISOString().slice(0, 10);
108
+ const since = opts.full ? 0 : (opts.since ?? lastDreamTimestamp(projectRoot));
109
+ const all = await (0, episode_capture_js_1.loadEpisodes)(projectRoot);
110
+ const episodes = all.filter(e => e.timestamp > since);
111
+ if (episodes.length === 0) {
112
+ return { path: '', date, episodeCount: 0, recalledSince: since, skipped: true, reason: 'no new episodes since last dream' };
113
+ }
114
+ // ── Consolidate via the LLM ──────────────────────────────────────────────
115
+ // Critical invariant: we do NOT advance the cutoff unless this succeeds.
116
+ const { system, user } = buildConsolidationPrompt(episodes);
117
+ let body;
118
+ let providerError;
119
+ const tryComplete = async (p) => {
120
+ const res = await p.complete(system, [{ role: 'user', content: user }], []);
121
+ const text = (res.text ?? '').trim();
122
+ if (!text)
123
+ throw new Error('Provider returned an empty response');
124
+ return text;
125
+ };
126
+ // Primary attempt
127
+ try {
128
+ body = await tryComplete(provider);
129
+ }
130
+ catch (primaryErr) {
131
+ const primaryMsg = primaryErr instanceof Error ? primaryErr.message : String(primaryErr);
132
+ // ── Ollama fallback ───────────────────────────────────────────────────
133
+ // Attempt one retry on a local Ollama instance before giving up.
134
+ if (ollamaFallbackModel) {
135
+ const ollamaBaseUrl = 'http://localhost:11434/v1';
136
+ const ollamaHealthy = await (0, factory_js_1.checkOllamaHealth)('http://localhost:11434').catch(() => false);
137
+ if (ollamaHealthy) {
138
+ try {
139
+ const ollamaProvider = (0, factory_js_1.createProvider)({
140
+ model: `ollama/${ollamaFallbackModel}`,
141
+ baseUrl: ollamaBaseUrl,
142
+ // Dream consolidations are bounded by episode digest size, not raw
143
+ // context — keep max_tokens conservative for small local models.
144
+ maxTokens: 2048,
145
+ });
146
+ body = await tryComplete(ollamaProvider);
147
+ // Ollama succeeded — note it but don't treat as an error.
148
+ providerError = undefined;
149
+ }
150
+ catch (ollamaErr) {
151
+ const ollamaMsg = ollamaErr instanceof Error ? ollamaErr.message : String(ollamaErr);
152
+ providerError = `primary: ${primaryMsg}; ollama fallback: ${ollamaMsg}`;
153
+ }
154
+ }
155
+ else {
156
+ providerError = `${primaryMsg} (Ollama not reachable at ${ollamaBaseUrl})`;
157
+ }
158
+ }
159
+ else {
160
+ providerError = primaryMsg;
161
+ }
162
+ }
163
+ // ── Provider failed — preserve episodes, return without writing state ─────
164
+ if (providerError !== undefined) {
165
+ return {
166
+ path: '',
167
+ date,
168
+ episodeCount: episodes.length,
169
+ recalledSince: since,
170
+ skipped: true,
171
+ reason: 'provider error — episodes preserved for next :dream run',
172
+ providerError,
173
+ };
174
+ }
175
+ // ── Write dream file ──────────────────────────────────────────────────────
176
+ const md = `${header(date, episodes, since)}\n${body}\n`;
177
+ const dir = dreamsDir(projectRoot);
178
+ fs.mkdirSync(dir, { recursive: true });
179
+ // One file per date; re-running the same day overwrites that day's dream.
180
+ const outPath = path.join(dir, `${date}.md`);
181
+ fs.writeFileSync(outPath, md);
182
+ // Advance the cutoff ONLY on success.
183
+ const newest = Math.max(...episodes.map(e => e.timestamp));
184
+ writeState(projectRoot, newest);
185
+ return { path: outPath, date, episodeCount: episodes.length, recalledSince: since, skipped: false };
186
+ }
187
+ //# sourceMappingURL=dream.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dream.js","sourceRoot":"","sources":["../../src/dream/dream.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwCA,gDAQC;AAwDD,4BAsGC;AA9MD,uCAAyB;AACzB,2CAA6B;AAC7B,mEAA0D;AAG1D,wDAA4E;AA2B5E,MAAM,cAAc,GAAG,QAAQ,CAAC;AAChC,MAAM,cAAc,GAAG,YAAY,CAAC;AAEpC,SAAS,SAAS,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,CAAC,GAAG,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC;IAC3D,UAAU,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC;IAEhC,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,YAAY,EAAE,QAAQ,CAAC,MAAM,EAAE,aAAa,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;AACtG,CAAC"}
@@ -0,0 +1,5 @@
1
+ export { startKanbanServer } from './server.js';
2
+ export type { KanbanServerOptions } from './server.js';
3
+ export { runPipeline, getBoardTasks, getRowLabels } from './pipeline.js';
4
+ export type { OnProgress, PipelineOptions } from './pipeline.js';
5
+ export type { KanbanTask, PipelinePhase, PipelineRow, TaskStatus, PhaseResult, TaskExecution, PipelineReport, RowReport, ProgressEvent, } from './types.js';
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getRowLabels = exports.getBoardTasks = exports.runPipeline = exports.startKanbanServer = void 0;
4
+ // Kanban Pipeline Module
5
+ var server_js_1 = require("./server.js");
6
+ Object.defineProperty(exports, "startKanbanServer", { enumerable: true, get: function () { return server_js_1.startKanbanServer; } });
7
+ var pipeline_js_1 = require("./pipeline.js");
8
+ Object.defineProperty(exports, "runPipeline", { enumerable: true, get: function () { return pipeline_js_1.runPipeline; } });
9
+ Object.defineProperty(exports, "getBoardTasks", { enumerable: true, get: function () { return pipeline_js_1.getBoardTasks; } });
10
+ Object.defineProperty(exports, "getRowLabels", { enumerable: true, get: function () { return pipeline_js_1.getRowLabels; } });
11
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/kanban/index.ts"],"names":[],"mappings":";;;AAAA,yBAAyB;AACzB,yCAAgD;AAAvC,8GAAA,iBAAiB,OAAA;AAE1B,6CAAyE;AAAhE,0GAAA,WAAW,OAAA;AAAE,4GAAA,aAAa,OAAA;AAAE,2GAAA,YAAY,OAAA"}
@@ -0,0 +1,16 @@
1
+ import type { KanbanTask, PipelineRow, PipelineReport, ProgressEvent } from './types.js';
2
+ export type OnProgress = (event: ProgressEvent) => void;
3
+ export interface PipelineOptions {
4
+ /** Project root for running shell commands / tests. */
5
+ projectRoot: string;
6
+ /** Callback for real-time progress events. */
7
+ onProgress?: OnProgress;
8
+ }
9
+ /**
10
+ * Run every row through its pipeline phases.
11
+ * Tasks that originate in a given phase are only processed from that phase
12
+ * onward (e.g. a task in "execute" skips read and plan).
13
+ */
14
+ export declare function runPipeline(opts: PipelineOptions): Promise<PipelineReport>;
15
+ export declare function getBoardTasks(): KanbanTask[];
16
+ export declare function getRowLabels(): Record<PipelineRow, string>;