reevesagents 1.3.2 → 1.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.
- package/AGENTS.md +14 -5
- package/CHANGELOG.md +28 -0
- package/README.md +114 -45
- package/dist/{chunk-VTLLF2Z4.js → chunk-6RPG22BH.js} +2 -148
- package/dist/{chunk-KVMBCWLI.js → chunk-BWJKK6LM.js} +252 -2
- package/dist/{chunk-GUM4JMVF.js → chunk-HL5MTR5M.js} +2 -2
- package/dist/{chunk-36SYE7IU.js → chunk-LKJSQLX2.js} +256 -10
- package/dist/{chunk-TO32PH23.js → chunk-LZMMFJYG.js} +2 -2
- package/dist/chunk-OHEIERAD.js +61 -0
- package/dist/cli.js +150 -36
- package/dist/index.d.ts +3 -1
- package/dist/index.js +2 -2
- package/dist/{router-AOJOUKAY.js → router-7MRY24Y5.js} +325 -211
- package/dist/{server-Y4HMP3OI.js → server-BNCUJ4YU.js} +20 -15
- package/dist/{server-I2ROVLSH.js → server-TUKVM6PW.js} +74 -28
- package/dist/{tui-launch-SJNFGH42.js → tui-launch-Y5YXPUHS.js} +2 -2
- package/dist/web/app.js +42 -1
- package/dist/web/index.html +24 -0
- package/package.json +1 -1
- package/dist/chunk-5Q5XP5QI.js +0 -29
|
@@ -2,31 +2,32 @@
|
|
|
2
2
|
import {
|
|
3
3
|
localeCatalog,
|
|
4
4
|
translatePhrase
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-BWJKK6LM.js";
|
|
6
6
|
import {
|
|
7
7
|
modelValuesForProvider
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-LZMMFJYG.js";
|
|
9
9
|
import {
|
|
10
10
|
REEVESAGENTS_VERSION,
|
|
11
|
-
attach,
|
|
12
|
-
attachAll,
|
|
13
|
-
detach,
|
|
14
|
-
hostStatus,
|
|
15
11
|
listRunApprovals,
|
|
16
12
|
resolveRunApproval
|
|
17
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-6RPG22BH.js";
|
|
18
14
|
import {
|
|
19
15
|
CONFIG_FIELDS,
|
|
20
16
|
LANGUAGE_OPTIONS,
|
|
21
17
|
PROVIDERS,
|
|
22
18
|
archiveAndRemoveRun,
|
|
19
|
+
attach,
|
|
20
|
+
attachAll,
|
|
23
21
|
autoCleanupRuns,
|
|
22
|
+
coerceExtraArgs,
|
|
24
23
|
computeRunStatus,
|
|
25
24
|
deleteAgent,
|
|
26
25
|
deletePreset,
|
|
27
26
|
deleteRunHistory,
|
|
27
|
+
detach,
|
|
28
28
|
detectAvailable,
|
|
29
29
|
findAgent,
|
|
30
|
+
hostStatus,
|
|
30
31
|
isLanguageCode,
|
|
31
32
|
killAgent,
|
|
32
33
|
listAgents,
|
|
@@ -47,8 +48,9 @@ import {
|
|
|
47
48
|
spawnWorker,
|
|
48
49
|
startRun,
|
|
49
50
|
startRunFromPreset,
|
|
50
|
-
stopRun
|
|
51
|
-
|
|
51
|
+
stopRun,
|
|
52
|
+
verifyServerLaunch
|
|
53
|
+
} from "./chunk-LKJSQLX2.js";
|
|
52
54
|
import "./chunk-D24DQQ6V.js";
|
|
53
55
|
|
|
54
56
|
// src/web/server.ts
|
|
@@ -614,20 +616,21 @@ async function createTerminal(body) {
|
|
|
614
616
|
const permissions = normalizePermissionsInput(body.permissions);
|
|
615
617
|
const auth_mode = parseAuthModeInput(body.auth_mode);
|
|
616
618
|
const effort = parseEffortInput(body.effort);
|
|
619
|
+
const extra_args = coerceExtraArgs(body.extra_args);
|
|
617
620
|
const nickname = sanitizeNickname(typeof body.nickname === "string" ? body.nickname : "");
|
|
618
621
|
const runName = sanitizeRunName(typeof body.run_name === "string" ? body.run_name : "");
|
|
619
622
|
const prompt = typeof body.prompt === "string" ? body.prompt : "";
|
|
620
623
|
const runId = typeof body.run_id === "string" && body.run_id ? body.run_id : null;
|
|
621
624
|
if (runId) {
|
|
622
625
|
readRun(runId);
|
|
623
|
-
const agent = spawnWorker({ run_id: runId, provider: normalizedProvider, nickname: nickname || void 0, model, permissions, auth_mode, effort, task: prompt });
|
|
626
|
+
const agent = spawnWorker({ run_id: runId, provider: normalizedProvider, nickname: nickname || void 0, model, permissions, auth_mode, effort, extra_args, task: prompt });
|
|
624
627
|
return { id: agent.id, run_id: agent.run_id };
|
|
625
628
|
}
|
|
626
629
|
const workingDir = typeof body.working_dir === "string" && body.working_dir.trim() ? body.working_dir.trim() : process.cwd();
|
|
627
630
|
const result = startRun({
|
|
628
631
|
name: runName || nickname || providerDisplayName(normalizedProvider),
|
|
629
632
|
working_dir: workingDir,
|
|
630
|
-
root: { provider: normalizedProvider, nickname: nickname || void 0, model, permissions, auth_mode, effort, task: prompt }
|
|
633
|
+
root: { provider: normalizedProvider, nickname: nickname || void 0, model, permissions, auth_mode, effort, extra_args, task: prompt }
|
|
631
634
|
});
|
|
632
635
|
const root = result.agents[0];
|
|
633
636
|
if (!root) throw new Error("run created no agent");
|
|
@@ -656,8 +659,10 @@ function detachMcpHostAction(body) {
|
|
|
656
659
|
const result = detach(key);
|
|
657
660
|
return { result, hosts: hostStatus() };
|
|
658
661
|
}
|
|
659
|
-
function attachAllMcpHostsAction() {
|
|
660
|
-
|
|
662
|
+
async function attachAllMcpHostsAction() {
|
|
663
|
+
const results = attachAll();
|
|
664
|
+
const verify = await verifyServerLaunch();
|
|
665
|
+
return { results, hosts: hostStatus(), verify };
|
|
661
666
|
}
|
|
662
667
|
function configPayload() {
|
|
663
668
|
const config = loadConfig().global;
|
|
@@ -828,7 +833,7 @@ async function handleRequest(req, res, ctx) {
|
|
|
828
833
|
}
|
|
829
834
|
if (method === "POST" && path === "/api/mcp-hosts/attach-all") {
|
|
830
835
|
try {
|
|
831
|
-
sendJson(res, 200, attachAllMcpHostsAction());
|
|
836
|
+
sendJson(res, 200, await attachAllMcpHostsAction());
|
|
832
837
|
} catch (err) {
|
|
833
838
|
sendJson(res, 400, { error: errMessage(err) });
|
|
834
839
|
}
|
|
@@ -1015,4 +1020,4 @@ async function startWebServer(options = {}) {
|
|
|
1015
1020
|
export {
|
|
1016
1021
|
startWebServer
|
|
1017
1022
|
};
|
|
1018
|
-
//# sourceMappingURL=server-
|
|
1023
|
+
//# sourceMappingURL=server-BNCUJ4YU.js.map
|
|
@@ -1,26 +1,27 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
REEVESAGENTS_VERSION,
|
|
4
|
-
attach,
|
|
5
|
-
attachAll,
|
|
6
4
|
createRunApproval,
|
|
7
|
-
detach,
|
|
8
|
-
hostStatus,
|
|
9
5
|
listRunApprovals,
|
|
10
6
|
readRunApproval,
|
|
11
7
|
resolveRunApproval
|
|
12
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-6RPG22BH.js";
|
|
13
9
|
import {
|
|
14
10
|
ALLOWED_KEYS,
|
|
15
11
|
BIN,
|
|
16
12
|
CONFIG_FIELDS,
|
|
17
13
|
PROVIDER_DEFS,
|
|
18
14
|
archiveAndRemoveRun,
|
|
15
|
+
attach,
|
|
16
|
+
attachAll,
|
|
17
|
+
coerceExtraArgs,
|
|
19
18
|
deleteAgent,
|
|
20
19
|
deletePreset,
|
|
21
20
|
deleteRunHistory,
|
|
21
|
+
detach,
|
|
22
22
|
detectAvailable,
|
|
23
23
|
findAgent,
|
|
24
|
+
hostStatus,
|
|
24
25
|
interrupt,
|
|
25
26
|
isProvider,
|
|
26
27
|
killAgent,
|
|
@@ -42,7 +43,7 @@ import {
|
|
|
42
43
|
startRunFromPreset,
|
|
43
44
|
startRunWithHead,
|
|
44
45
|
stopRun
|
|
45
|
-
} from "./chunk-
|
|
46
|
+
} from "./chunk-LKJSQLX2.js";
|
|
46
47
|
import "./chunk-D24DQQ6V.js";
|
|
47
48
|
|
|
48
49
|
// src/mcp/server.ts
|
|
@@ -171,7 +172,8 @@ function spawnHandler(a) {
|
|
|
171
172
|
working_dir: typeof a.working_dir === "string" ? a.working_dir : void 0,
|
|
172
173
|
permissions: parsePermissions(a.permissions),
|
|
173
174
|
auth_mode: parseAuthMode(a.auth_mode),
|
|
174
|
-
effort: parseEffort(a.effort)
|
|
175
|
+
effort: parseEffort(a.effort),
|
|
176
|
+
extra_args: coerceExtraArgs(a.extra_args)
|
|
175
177
|
};
|
|
176
178
|
if (typeof a.run_id === "string" && a.run_id.trim()) {
|
|
177
179
|
const cap = loadConfig().global.max_agents;
|
|
@@ -216,7 +218,8 @@ var TOOLS = [
|
|
|
216
218
|
working_dir: { type: "string" },
|
|
217
219
|
permissions: { type: "string", enum: ["ask", "skip"], description: "ask prompts for each action; skip runs autonomously. Blank uses the global default." },
|
|
218
220
|
auth_mode: { type: "string", enum: ["default", "api-key"], description: "How the CLI authenticates. Blank uses the provider default." },
|
|
219
|
-
effort: { type: "string", enum: ["default", "low", "medium", "high", "xhigh", "max"], description: "Reasoning effort, for providers that support it. Blank uses the provider default." }
|
|
221
|
+
effort: { type: "string", enum: ["default", "low", "medium", "high", "xhigh", "max"], description: "Reasoning effort, for providers that support it. Blank uses the provider default." },
|
|
222
|
+
extra_args: { type: "array", items: { type: "string" }, description: 'Extra flags appended verbatim to the launch, for provider options ReevesAgents does not model. Each flag and its value is a separate item, e.g. ["--remote-control"].' }
|
|
220
223
|
},
|
|
221
224
|
required: ["provider"]
|
|
222
225
|
},
|
|
@@ -582,43 +585,86 @@ function handleAgentMcpTool(name, a) {
|
|
|
582
585
|
return fail(e instanceof Error ? e.message : String(e));
|
|
583
586
|
}
|
|
584
587
|
}
|
|
588
|
+
var GUIDE_URI = "reevesagents://guide";
|
|
589
|
+
var MCP_INSTRUCTIONS = `reevesagents lets you run and steer other AI CLI agents from this session: Claude Code, Codex, Kimi, Qwen, OpenCode, Hermes, and more, each in its own tmux window. Hand slices of work to other models, then read or redirect what they do.
|
|
590
|
+
|
|
591
|
+
Drive loop:
|
|
592
|
+
1. list_providers - which CLIs are installed here and their models.
|
|
593
|
+
2. spawn { provider, task } - start an agent; returns agent_id and run_id. Omit run_id to keep adding agents to the same run.
|
|
594
|
+
3. read { agent_id } - an agent's recent output.
|
|
595
|
+
4. send_text { agent_id, text } then send_key { agent_id, key: "enter" } - type a message and submit it. send_text alone does NOT submit.
|
|
596
|
+
5. kill { agent_id } or stop { run_id } when done.
|
|
597
|
+
|
|
598
|
+
Every id comes from spawn or list. Read the reevesagents://guide resource for a worked example.`;
|
|
599
|
+
var GUIDE_TEXT = `# reevesagents: drive a team of AI CLIs
|
|
600
|
+
|
|
601
|
+
You can spawn and steer other coding CLIs from here. Each agent is a real CLI in its own tmux window on this machine. reevesagents never proxies model traffic or stores credentials; each CLI uses its own login.
|
|
602
|
+
|
|
603
|
+
## Worked example: hand a task to Codex, then steer it
|
|
604
|
+
1. list_providers confirm "codex" is available
|
|
605
|
+
2. spawn { "provider": "codex", "task": "summarize README.md" }
|
|
606
|
+
returns { "agent_id": "ab12...", "run_id": "cd34..." }
|
|
607
|
+
3. read { "agent_id": "ab12..." } see what it produced
|
|
608
|
+
4. send_text { "agent_id": "ab12...", "text": "now write tests for it" }
|
|
609
|
+
send_key { "agent_id": "ab12...", "key": "enter" }
|
|
610
|
+
5. kill { "agent_id": "ab12..." } stop it when finished
|
|
611
|
+
|
|
612
|
+
## Notes
|
|
613
|
+
- send_text types but does not submit; always follow it with send_key enter.
|
|
614
|
+
- Omit run_id on spawn to add agents to the run you started; pass run_id to target a specific run.
|
|
615
|
+
- list shows every run and agent; read shows recent output (20 lines by default).
|
|
616
|
+
- Spawned agents are plain CLIs and cannot spawn others unless you attach this MCP to them too.`;
|
|
617
|
+
function listMcpResources() {
|
|
618
|
+
return [
|
|
619
|
+
{
|
|
620
|
+
uri: PROVIDER_CATALOG_URI,
|
|
621
|
+
name: "Providers and models",
|
|
622
|
+
description: "CLI providers this machine can launch and their known models.",
|
|
623
|
+
mimeType: "application/json"
|
|
624
|
+
},
|
|
625
|
+
{
|
|
626
|
+
uri: GUIDE_URI,
|
|
627
|
+
name: "Getting started",
|
|
628
|
+
description: "What reevesagents is and a worked example of driving an agent.",
|
|
629
|
+
mimeType: "text/markdown"
|
|
630
|
+
}
|
|
631
|
+
];
|
|
632
|
+
}
|
|
633
|
+
function readMcpResource(uri) {
|
|
634
|
+
if (uri === PROVIDER_CATALOG_URI) {
|
|
635
|
+
return { uri, mimeType: "application/json", text: JSON.stringify(buildProviderCatalog()) };
|
|
636
|
+
}
|
|
637
|
+
if (uri === GUIDE_URI) {
|
|
638
|
+
return { uri, mimeType: "text/markdown", text: GUIDE_TEXT };
|
|
639
|
+
}
|
|
640
|
+
throw new Error(`Unknown resource: ${uri}`);
|
|
641
|
+
}
|
|
585
642
|
async function startAgentMcpServer() {
|
|
586
643
|
const server = new Server(
|
|
587
644
|
{ name: "reevesagents", version: REEVESAGENTS_VERSION },
|
|
588
|
-
{ capabilities: { tools: {}, resources: {} } }
|
|
645
|
+
{ capabilities: { tools: {}, resources: {} }, instructions: MCP_INSTRUCTIONS }
|
|
589
646
|
);
|
|
590
647
|
server.setRequestHandler(ListToolsRequestSchema, async () => ({ tools: MCP_TOOLS }));
|
|
591
648
|
server.setRequestHandler(CallToolRequestSchema, async (request) => {
|
|
592
649
|
const { name, arguments: args = {} } = request.params;
|
|
593
650
|
return handleAgentMcpTool(name, args);
|
|
594
651
|
});
|
|
595
|
-
server.setRequestHandler(ListResourcesRequestSchema, async () => ({
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
uri: PROVIDER_CATALOG_URI,
|
|
599
|
-
name: "Providers and models",
|
|
600
|
-
description: "CLI providers this machine can launch and their known models.",
|
|
601
|
-
mimeType: "application/json"
|
|
602
|
-
}
|
|
603
|
-
]
|
|
652
|
+
server.setRequestHandler(ListResourcesRequestSchema, async () => ({ resources: listMcpResources() }));
|
|
653
|
+
server.setRequestHandler(ReadResourceRequestSchema, async (request) => ({
|
|
654
|
+
contents: [readMcpResource(request.params.uri)]
|
|
604
655
|
}));
|
|
605
|
-
server.setRequestHandler(ReadResourceRequestSchema, async (request) => {
|
|
606
|
-
const { uri } = request.params;
|
|
607
|
-
if (uri !== PROVIDER_CATALOG_URI) throw new Error(`Unknown resource: ${uri}`);
|
|
608
|
-
return {
|
|
609
|
-
contents: [
|
|
610
|
-
{ uri, mimeType: "application/json", text: JSON.stringify(buildProviderCatalog()) }
|
|
611
|
-
]
|
|
612
|
-
};
|
|
613
|
-
});
|
|
614
656
|
const transport = new StdioServerTransport();
|
|
615
657
|
await server.connect(transport);
|
|
616
658
|
}
|
|
617
659
|
export {
|
|
660
|
+
GUIDE_TEXT,
|
|
661
|
+
MCP_INSTRUCTIONS,
|
|
618
662
|
MCP_TOOLS,
|
|
619
663
|
buildProviderCatalog,
|
|
620
664
|
handleAgentMcpTool,
|
|
665
|
+
listMcpResources,
|
|
666
|
+
readMcpResource,
|
|
621
667
|
sessionRunIsLive,
|
|
622
668
|
startAgentMcpServer
|
|
623
669
|
};
|
|
624
|
-
//# sourceMappingURL=server-
|
|
670
|
+
//# sourceMappingURL=server-TUKVM6PW.js.map
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
import {
|
|
3
3
|
closeTuiWebServer,
|
|
4
4
|
startWebFromTui
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-HL5MTR5M.js";
|
|
6
6
|
export {
|
|
7
7
|
closeTuiWebServer,
|
|
8
8
|
startWebFromTui
|
|
9
9
|
};
|
|
10
|
-
//# sourceMappingURL=tui-launch-
|
|
10
|
+
//# sourceMappingURL=tui-launch-Y5YXPUHS.js.map
|
package/dist/web/app.js
CHANGED
|
@@ -68,6 +68,8 @@
|
|
|
68
68
|
'web.cwdHelp': 'Agents start in this directory.',
|
|
69
69
|
'web.promptHelp': 'Sent to the agent after its window opens.',
|
|
70
70
|
'web.promptPlaceholder': 'What should this agent start working on?',
|
|
71
|
+
'web.extraArgs': 'Extra flags',
|
|
72
|
+
'web.extraArgsHelp': 'Passed to the CLI on launch, after the flags ReevesAgents sets.',
|
|
71
73
|
'web.cancel': 'Cancel',
|
|
72
74
|
'web.create': 'Create',
|
|
73
75
|
'web.providerDefault': 'Provider default',
|
|
@@ -103,6 +105,7 @@
|
|
|
103
105
|
'web.stopAgentError': 'Could not stop agent: {{message}}',
|
|
104
106
|
'web.stopRunConfirm': 'Stop run "{{name}}"? Every agent in it will be stopped.',
|
|
105
107
|
'web.stopRunError': 'Could not stop run: {{message}}',
|
|
108
|
+
'web.deletePresetConfirm': 'Delete preset "{{name}}"?',
|
|
106
109
|
'web.deleteRunConfirm': 'Delete stopped run "{{name}}"? A simple history record will be kept.',
|
|
107
110
|
'web.deleteRunError': 'Could not delete stopped run: {{message}}',
|
|
108
111
|
'web.deleteAgentConfirm': 'Delete stopped agent "{{name}}"? This removes the saved agent record.',
|
|
@@ -231,6 +234,7 @@
|
|
|
231
234
|
fCwd: document.getElementById('f-cwd'),
|
|
232
235
|
cwdField: document.getElementById('cwd-field'),
|
|
233
236
|
fPrompt: document.getElementById('f-prompt'),
|
|
237
|
+
fExtraArgs: document.getElementById('f-extra-args'),
|
|
234
238
|
newError: document.getElementById('new-error'),
|
|
235
239
|
newCancel: document.getElementById('new-cancel'),
|
|
236
240
|
newSubmit: document.getElementById('new-submit'),
|
|
@@ -253,6 +257,14 @@
|
|
|
253
257
|
aboutDialog: document.getElementById('about-dialog'),
|
|
254
258
|
aboutList: document.getElementById('about-list'),
|
|
255
259
|
aboutClose: document.getElementById('about-close'),
|
|
260
|
+
welcomeDialog: document.getElementById('welcome-dialog'),
|
|
261
|
+
welcomeTitle: document.getElementById('welcome-title'),
|
|
262
|
+
welcomeSubtitle: document.getElementById('welcome-subtitle'),
|
|
263
|
+
welcomeIntro: document.getElementById('welcome-intro'),
|
|
264
|
+
welcomeDoorRun: document.getElementById('welcome-door-run'),
|
|
265
|
+
welcomeDoorConnect: document.getElementById('welcome-door-connect'),
|
|
266
|
+
welcomeConnect: document.getElementById('welcome-connect'),
|
|
267
|
+
welcomeClose: document.getElementById('welcome-close'),
|
|
256
268
|
configBtn: document.getElementById('config-btn'),
|
|
257
269
|
configDialog: document.getElementById('config-dialog'),
|
|
258
270
|
configList: document.getElementById('config-list'),
|
|
@@ -276,6 +288,7 @@
|
|
|
276
288
|
let language = 'en'
|
|
277
289
|
let languages = []
|
|
278
290
|
let messages = WEB_EN
|
|
291
|
+
let welcomeChecked = false
|
|
279
292
|
let selectedId = null
|
|
280
293
|
let session = null // { id, ws, term, fit, observer }
|
|
281
294
|
let createContext = { kind: 'run', runId: '' }
|
|
@@ -327,6 +340,7 @@
|
|
|
327
340
|
renderSidebar()
|
|
328
341
|
reconcileCreateDialog()
|
|
329
342
|
reconcileSelectedAgent()
|
|
343
|
+
if (!welcomeChecked) { welcomeChecked = true; maybeShowWelcome() }
|
|
330
344
|
}
|
|
331
345
|
|
|
332
346
|
function subscribe() {
|
|
@@ -400,6 +414,13 @@
|
|
|
400
414
|
el.presetsBtn.textContent = t('web.presets')
|
|
401
415
|
el.doctorBtn.textContent = t('web.doctor')
|
|
402
416
|
el.aboutBtn.textContent = t('web.about')
|
|
417
|
+
el.welcomeTitle.textContent = t('setup.title')
|
|
418
|
+
el.welcomeSubtitle.textContent = t('setup.subtitle')
|
|
419
|
+
el.welcomeIntro.textContent = t('setup.intro')
|
|
420
|
+
el.welcomeDoorRun.textContent = `${t('setup.startRun')} (${t('setup.startRunHint')})`
|
|
421
|
+
el.welcomeDoorConnect.textContent = `${t('setup.connectAll')} (${t('setup.connectAllHint')})`
|
|
422
|
+
el.welcomeConnect.textContent = t('web.agentControl')
|
|
423
|
+
el.welcomeClose.textContent = t('setup.done')
|
|
403
424
|
el.mcpDialogTitle.textContent = t('web.mcpTitle')
|
|
404
425
|
el.mcpDialogSubtitle.textContent = t('web.mcpSubtitle')
|
|
405
426
|
el.mcpEmpty.textContent = t('web.mcpEmpty')
|
|
@@ -442,6 +463,8 @@
|
|
|
442
463
|
document.querySelector('#cwd-field .field-label').textContent = t('web.workingDirectory')
|
|
443
464
|
document.querySelector('#f-cwd').placeholder = t('web.cwdPlaceholder')
|
|
444
465
|
document.querySelector('#prompt-field .field-label').innerHTML = `${t('web.initialPrompt')} <span class="field-opt">${t('web.initialPromptOpt')}</span>`
|
|
466
|
+
document.querySelector('#extra-args-field .field-label').innerHTML = `${t('web.extraArgs')} <span class="field-opt">${t('web.optional')}</span>`
|
|
467
|
+
setText('#extra-args-help', t('web.extraArgsHelp'))
|
|
445
468
|
setText('#agent-run-help', t('web.agentRunHelp'))
|
|
446
469
|
setText('#run-name-help', t('web.runNameHelp'))
|
|
447
470
|
setText('#provider-help', t('web.providerHelp'))
|
|
@@ -1415,6 +1438,7 @@
|
|
|
1415
1438
|
el.fPermissions.value = 'ask'
|
|
1416
1439
|
el.fPrompt.value = ''
|
|
1417
1440
|
el.fCwd.value = ''
|
|
1441
|
+
el.fExtraArgs.value = ''
|
|
1418
1442
|
updatePermissionSelection()
|
|
1419
1443
|
}
|
|
1420
1444
|
|
|
@@ -1530,6 +1554,7 @@
|
|
|
1530
1554
|
permissions: el.fPermissions.value,
|
|
1531
1555
|
nickname: el.fNickname.value.trim(),
|
|
1532
1556
|
prompt: el.fPrompt.value,
|
|
1557
|
+
extra_args: el.fExtraArgs.value.trim(),
|
|
1533
1558
|
run_id: createContext.kind === 'agent' ? createContext.runId : undefined,
|
|
1534
1559
|
run_name: createContext.kind === 'run' ? el.fRunName.value.trim() || undefined : undefined,
|
|
1535
1560
|
working_dir: createContext.kind === 'run' ? el.fCwd.value.trim() || undefined : undefined,
|
|
@@ -1649,6 +1674,20 @@
|
|
|
1649
1674
|
}
|
|
1650
1675
|
}
|
|
1651
1676
|
|
|
1677
|
+
// Show a one-time getting-started popup on a browser's first visit. The flag
|
|
1678
|
+
// lives in localStorage, so it never nags after the first dismissal.
|
|
1679
|
+
function maybeShowWelcome() {
|
|
1680
|
+
let seen
|
|
1681
|
+
try {
|
|
1682
|
+
seen = window.localStorage.getItem('reeves.welcomed') === '1'
|
|
1683
|
+
} catch {
|
|
1684
|
+
return
|
|
1685
|
+
}
|
|
1686
|
+
if (seen) return
|
|
1687
|
+
try { window.localStorage.setItem('reeves.welcomed', '1') } catch { /* private mode: skip persistence */ }
|
|
1688
|
+
el.welcomeDialog.showModal()
|
|
1689
|
+
}
|
|
1690
|
+
|
|
1652
1691
|
function openMcpDialog() {
|
|
1653
1692
|
setMcpError(null)
|
|
1654
1693
|
mcpHosts = []
|
|
@@ -1977,7 +2016,7 @@
|
|
|
1977
2016
|
}
|
|
1978
2017
|
|
|
1979
2018
|
async function deletePreset(name) {
|
|
1980
|
-
if (!confirm(
|
|
2019
|
+
if (!confirm(t('web.deletePresetConfirm', { name }))) return
|
|
1981
2020
|
el.presetsError.hidden = true
|
|
1982
2021
|
try {
|
|
1983
2022
|
await api('POST', `/api/presets/${encodeURIComponent(name)}/delete`, { confirm: true })
|
|
@@ -2019,6 +2058,8 @@
|
|
|
2019
2058
|
el.doctorClose.addEventListener('click', () => el.doctorDialog.close())
|
|
2020
2059
|
el.aboutBtn.addEventListener('click', openAboutDialog)
|
|
2021
2060
|
el.aboutClose.addEventListener('click', () => el.aboutDialog.close())
|
|
2061
|
+
el.welcomeConnect.addEventListener('click', () => { el.welcomeDialog.close(); openMcpDialog() })
|
|
2062
|
+
el.welcomeClose.addEventListener('click', () => el.welcomeDialog.close())
|
|
2022
2063
|
el.configBtn.addEventListener('click', openConfigDialog)
|
|
2023
2064
|
el.configSave.addEventListener('click', saveConfig)
|
|
2024
2065
|
el.configClose.addEventListener('click', () => el.configDialog.close())
|
package/dist/web/index.html
CHANGED
|
@@ -179,6 +179,12 @@
|
|
|
179
179
|
<span id="prompt-help" class="field-help">Sent to the agent after its window opens.</span>
|
|
180
180
|
</label>
|
|
181
181
|
|
|
182
|
+
<label class="field" id="extra-args-field">
|
|
183
|
+
<span class="field-label">Extra flags <span class="field-opt">optional</span></span>
|
|
184
|
+
<input id="f-extra-args" type="text" placeholder="--remote-control" autocomplete="off" />
|
|
185
|
+
<span id="extra-args-help" class="field-help">Passed to the CLI on launch, after the flags ReevesAgents sets.</span>
|
|
186
|
+
</label>
|
|
187
|
+
|
|
182
188
|
<div id="new-error" class="dialog-error" hidden></div>
|
|
183
189
|
|
|
184
190
|
<div class="dialog-actions">
|
|
@@ -236,6 +242,24 @@
|
|
|
236
242
|
</div>
|
|
237
243
|
</dialog>
|
|
238
244
|
|
|
245
|
+
<dialog id="welcome-dialog" class="dialog mcp-dialog">
|
|
246
|
+
<div class="mcp-panel">
|
|
247
|
+
<div class="dialog-header">
|
|
248
|
+
<div id="welcome-title" class="dialog-title">Get started</div>
|
|
249
|
+
<div id="welcome-subtitle" class="dialog-subtitle">Set up reevesagents and connect your CLIs.</div>
|
|
250
|
+
</div>
|
|
251
|
+
<div class="about-list">
|
|
252
|
+
<div id="welcome-intro"></div>
|
|
253
|
+
<div id="welcome-door-run"></div>
|
|
254
|
+
<div id="welcome-door-connect"></div>
|
|
255
|
+
</div>
|
|
256
|
+
<div class="dialog-actions">
|
|
257
|
+
<button type="button" id="welcome-connect" class="btn btn-accent">Agent control</button>
|
|
258
|
+
<button type="button" id="welcome-close" class="btn">Continue</button>
|
|
259
|
+
</div>
|
|
260
|
+
</div>
|
|
261
|
+
</dialog>
|
|
262
|
+
|
|
239
263
|
<dialog id="config-dialog" class="dialog mcp-dialog">
|
|
240
264
|
<div class="mcp-panel">
|
|
241
265
|
<div class="dialog-header">
|
package/package.json
CHANGED
package/dist/chunk-5Q5XP5QI.js
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
import {
|
|
3
|
-
stateRoot
|
|
4
|
-
} from "./chunk-36SYE7IU.js";
|
|
5
|
-
|
|
6
|
-
// src/core/tui-open.ts
|
|
7
|
-
import { mkdirSync, readFileSync, writeFileSync } from "fs";
|
|
8
|
-
import { join } from "path";
|
|
9
|
-
function tokenPath() {
|
|
10
|
-
return join(stateRoot(), "tui-open-token");
|
|
11
|
-
}
|
|
12
|
-
function readTuiOpenToken() {
|
|
13
|
-
try {
|
|
14
|
-
return readFileSync(tokenPath(), "utf-8").trim();
|
|
15
|
-
} catch {
|
|
16
|
-
return "";
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
function writeTuiOpenToken() {
|
|
20
|
-
mkdirSync(stateRoot(), { recursive: true });
|
|
21
|
-
writeFileSync(tokenPath(), `${Date.now()}
|
|
22
|
-
`, "utf-8");
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export {
|
|
26
|
-
readTuiOpenToken,
|
|
27
|
-
writeTuiOpenToken
|
|
28
|
-
};
|
|
29
|
-
//# sourceMappingURL=chunk-5Q5XP5QI.js.map
|