@soederpop/luca 0.0.16 → 0.0.19
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/assistants/codingAssistant/CORE.md +25 -0
- package/assistants/codingAssistant/hooks.ts +3 -0
- package/assistants/codingAssistant/tools.ts +108 -0
- package/package.json +2 -2
- package/src/agi/features/assistant.ts +48 -0
- package/src/bootstrap/generated.ts +1 -1
- package/src/commands/chat.ts +83 -7
- package/src/introspection/generated.agi.ts +448 -448
- package/src/introspection/generated.node.ts +1073 -1073
- package/src/introspection/generated.web.ts +1 -1
- package/src/node/features/repl.ts +19 -6
- package/src/scaffolds/generated.ts +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { setBuildTimeData, setContainerBuildTimeData } from './index.js';
|
|
2
2
|
|
|
3
3
|
// Auto-generated introspection registry data
|
|
4
|
-
// Generated at: 2026-03-
|
|
4
|
+
// Generated at: 2026-03-20T21:12:58.860Z
|
|
5
5
|
|
|
6
6
|
setBuildTimeData('features.containerLink', {
|
|
7
7
|
"id": "features.containerLink",
|
|
@@ -75,12 +75,19 @@ export class Repl<
|
|
|
75
75
|
* ```
|
|
76
76
|
*/
|
|
77
77
|
async start(options: { historyPath?: string, context?: any } = {}) {
|
|
78
|
+
const { prompt = "> " } = this.options;
|
|
79
|
+
|
|
80
|
+
// If already started, resume with a fresh readline but reuse the VM context
|
|
78
81
|
if (this.isStarted) {
|
|
79
|
-
|
|
82
|
+
// Merge any new context into the existing VM context
|
|
83
|
+
if (options.context) {
|
|
84
|
+
for (const [k, v] of Object.entries(options.context)) {
|
|
85
|
+
this._vmContext![k] = v
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
return this._resume(prompt)
|
|
80
89
|
}
|
|
81
90
|
|
|
82
|
-
const { prompt = "> " } = this.options;
|
|
83
|
-
|
|
84
91
|
// Set up history file — per-project history keyed by cwd hash
|
|
85
92
|
const userHistoryPath = options.historyPath || this.options.historyPath
|
|
86
93
|
if (typeof userHistoryPath === 'string') {
|
|
@@ -107,8 +114,16 @@ export class Repl<
|
|
|
107
114
|
client: (...args: any[]) => this.container.client(...args),
|
|
108
115
|
})
|
|
109
116
|
|
|
110
|
-
|
|
117
|
+
this.state.set('started', true)
|
|
118
|
+
|
|
119
|
+
return this._resume(prompt)
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
/** Open a fresh readline and enter the REPL loop using the existing VM context. */
|
|
123
|
+
private _resume(prompt: string) {
|
|
111
124
|
const ctx = this._vmContext!
|
|
125
|
+
|
|
126
|
+
// Completer for tab autocomplete
|
|
112
127
|
const completer = (line: string): [string[], string] => {
|
|
113
128
|
// Dot-notation: e.g. container.fea<tab>
|
|
114
129
|
const dotMatch = line.match(/([a-zA-Z_$][\w$]*(?:\.[a-zA-Z_$][\w$]*)*)\.([a-zA-Z_$][\w$]*)?$/)
|
|
@@ -146,8 +161,6 @@ export class Repl<
|
|
|
146
161
|
completer,
|
|
147
162
|
})
|
|
148
163
|
|
|
149
|
-
this.state.set('started', true)
|
|
150
|
-
|
|
151
164
|
// REPL loop
|
|
152
165
|
let lastResult: any
|
|
153
166
|
const ask = (): void => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// Auto-generated scaffold and MCP readme content
|
|
2
|
-
// Generated at: 2026-03-
|
|
2
|
+
// Generated at: 2026-03-20T21:12:59.765Z
|
|
3
3
|
// Source: docs/scaffolds/*.md, docs/examples/assistant/, and docs/mcp/readme.md
|
|
4
4
|
//
|
|
5
5
|
// Do not edit manually. Run: luca build-scaffolds
|