@myagentroam/marctl 0.11.10 → 0.11.11

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@myagentroam/marctl",
3
- "version": "0.11.10",
3
+ "version": "0.11.11",
4
4
  "description": "MyAgentRoam command-line interface for authorized Node access.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
@@ -55,11 +55,10 @@ Usage:
55
55
  [--client-message-id <id>] [--json]
56
56
  {program} wait [<id>] [--agent <id> ...] [--mode any|all]
57
57
  [--wait-for message|completion] [--timeout <duration>] [--json]
58
- {program} stop <id> --execution <execution-id> [--json]
58
+ {program} stop <id> [--json]
59
59
  {program} list [--scope tree|active] [--query <title>]
60
60
  [--limit <1..100>] [--json]
61
- {program} view [<id>] [--history] [--cursor <cursor>]
62
- [--limit <1..100>] [--json]
61
+ {program} view [<id>] [--json]
63
62
 
64
63
  Management:
65
64
  {program} config [<id>] [--model-id <id>] [--effort <value>] [--json]
@@ -77,22 +76,26 @@ Management:
77
76
  {program} wait <id> --run <run-id> [--until approval] --timeout <duration>
78
77
  {program} goal get|clear <id> [--json]
79
78
  {program} goal set <id> (-m <text> | --message-file <file|->) [--json]
80
- {program} current | show [<id>] | graph [<id>] | history [<id>]
79
+ {program} current | show [<id>] | graph [<id>]
80
+ {program} history [<id>] [--cursor <cursor>] [--limit <1..100>] [--json]
81
81
 
82
82
  Input and results:
83
83
  Start defaults to the current Session Runner; a terminal without a current
84
84
  Session must specify --runner or --parent. Start returns without waiting.
85
85
  Send appends by default; --steer provides timely input and --queue defers.
86
86
  --goal sets or replaces a Goal; --clear-goal clears it. Send can update a Goal
87
- without text; omitted Goal is unchanged. Stop clears the target Session Goal.
87
+ without text; omitted Goal is unchanged. Stop targets the current execution
88
+ and clears the target Session Goal.
88
89
  Wait defaults to direct-child completion and 30s; 0ms is a snapshot.
89
- Positive timeouts below 10s become 10s; maximum is 5m. Waiting does not stop.
90
+ Positive timeouts use the requested duration; maximum is 5m.
91
+ Waiting does not stop the task.
90
92
  -m and --message-file are exclusive; files use UTF-8 and - reads stdin.
91
93
  List defaults to the containing tree, including idle Sessions. Without a
92
94
  current Session it defaults to active; explicit tree requires a Session.
93
95
  Active includes running and sleeping Sessions in the current Workspace.
94
96
  List returns currentAgentId (null without a Session), flat sessions and
95
- truncated. Limit defaults to 100, maximum 100; no cursor or pagination.
97
+ truncated. Limit defaults to 10, maximum 100; no cursor or pagination.
98
+ Active Sessions come first, then recent activity descending.
96
99
  Configuration and prompt changes apply to future executions.
97
100
  Prefer --steer for timely communication or course correction.
98
101
  Reserve --queue for explicitly requested deferred input: it is consumed after
@@ -106,8 +109,8 @@ Input and results:
106
109
 
107
110
  show --json includes session.status, session.modelId, session.effort,
108
111
  session.title, session.runId, session.recentTools, session.queuedCount and
109
- session.latestMessage. List entries have id, parentSessionId, title, runner
110
- and status; wait may include progress.
112
+ session.latestMessage. List entries have id, parentSessionId, title and
113
+ status; wait may include progress. View omits Run and Execution IDs.
111
114
  Status is RUNNING/IDLE/SLEEPING. In history, segments[].items[] with
112
115
  kind === "assistant_message" expose payload.text.
113
116
 
@@ -54,11 +54,10 @@ ${configurationHelp}
54
54
  [--client-message-id <id>] [--json]
55
55
  {program} wait [<id>] [--agent <id> ...] [--mode any|all]
56
56
  [--wait-for message|completion] [--timeout <duration>] [--json]
57
- {program} stop <id> --execution <execution-id> [--json]
57
+ {program} stop <id> [--json]
58
58
  {program} list [--scope tree|active] [--query <title>]
59
59
  [--limit <1..100>] [--json]
60
- {program} view [<id>] [--history] [--cursor <cursor>]
61
- [--limit <1..100>] [--json]
60
+ {program} view [<id>] [--json]
62
61
 
63
62
  管理:
64
63
  {program} config [<id>] [--model-id <id>] [--effort <value>] [--json]
@@ -76,20 +75,22 @@ ${configurationHelp}
76
75
  {program} wait <id> --run <run-id> [--until approval] --timeout <duration>
77
76
  {program} goal get|clear <id> [--json]
78
77
  {program} goal set <id> (-m <text> | --message-file <file|->) [--json]
79
- {program} current | show [<id>] | graph [<id>] | history [<id>]
78
+ {program} current | show [<id>] | graph [<id>]
79
+ {program} history [<id>] [--cursor <cursor>] [--limit <1..100>] [--json]
80
80
 
81
81
  输入与结果:
82
82
  start 默认当前会话的 Runner;没有当前会话的终端须指定 --runner 或
83
83
  --parent。start 不等待。
84
84
  send 默认追加;--steer 优先补充,--queue 排队。--goal 设置或替换目标,
85
85
  --clear-goal 清除目标;send 可仅更新目标,省略则不修改。
86
- stop 清除目标会话的 Goal。wait 默认等待直接子会话终态 30 秒,
87
- 0ms 为快照;正数小于 10 秒按 10 秒等待,最多 5 分钟。等待不会停止任务。
86
+ stop 停止目标当前执行并清除 Goal。wait 默认等待直接子会话终态 30 秒,
87
+ 0ms 为快照;正数按传入时长等待,最多 5 分钟。等待不会停止任务。
88
88
  -m 与 --message-file 互斥;文件使用 UTF-8,- 从 stdin 读取。
89
89
  list 默认查询所在会话树,包含空闲会话;
90
90
  没有当前会话时默认 active,显式 tree 须有会话上下文。active 包含当前
91
91
  Workspace 中运行及睡眠的会话。返回 currentAgentId(无会话时为 null)、
92
- 扁平 sessions 和 truncated。limit 默认及上限均为 100,无 cursor 或分页。
92
+ 扁平 sessions 和 truncated。limit 默认 10、上限 100,无 cursor 或分页。
93
+ 活跃会话优先,其后按最近活动时间倒序。
93
94
  配置和持久提示从后续执行生效。
94
95
  即时沟通或纠偏优先使用 --steer。
95
96
  建议仅将 --queue 用于明确要求延后的输入:当前工作及前面的队列项结束后才消费,
@@ -100,8 +101,8 @@ ${configurationHelp}
100
101
 
101
102
  show --json 包含 session.status、session.modelId、session.effort、
102
103
  session.title、session.runId、session.recentTools、session.queuedCount 和
103
- session.latestMessage。list 每项仅含 id、parentSessionId、title、runner 和
104
- status;wait 可能包含 progress;
104
+ session.latestMessage。list 每项仅含 id、parentSessionId、title 和 status;
105
+ wait 可能包含 progress;view 不公开 Run 或 Execution ID。
105
106
  状态为 RUNNING/IDLE/SLEEPING。历史中 segments[].items[] 的
106
107
  kind === "assistant_message" 包含 payload.text。
107
108
 
@@ -7,7 +7,7 @@ const commands = {
7
7
  list: ['scope', 'query', 'limit'],
8
8
  graph: ['limit'],
9
9
  show: [],
10
- view: ['cursor', 'limit', 'history'],
10
+ view: [],
11
11
  history: ['cursor', 'limit'],
12
12
  start: [
13
13
  'runner',
@@ -42,7 +42,7 @@ const commands = {
42
42
  'approval',
43
43
  'decision'
44
44
  ],
45
- stop: ['execution'],
45
+ stop: [],
46
46
  'goal.get': [],
47
47
  'goal.set': ['message', 'message-file'],
48
48
  'goal.clear': [],
@@ -57,7 +57,6 @@ const fieldNames = {
57
57
  run: 'runId',
58
58
  approval: 'approvalId',
59
59
  timeout: 'timeoutMs',
60
- execution: 'executionId',
61
60
  'wait-for': 'waitFor',
62
61
  'clear-goal': 'clearGoal'
63
62
  };
@@ -112,11 +111,8 @@ export function parseSessionArgs(argv, translate = createTranslator()) {
112
111
  args[key] = true;
113
112
  continue;
114
113
  }
115
- if (
116
- (flag === '--clear-goal' && ['start', 'send'].includes(action)) ||
117
- (flag === '--history' && action === 'view')
118
- ) {
119
- const key = flag === '--history' ? 'history' : 'clearGoal';
114
+ if (flag === '--clear-goal' && ['start', 'send'].includes(action)) {
115
+ const key = 'clearGoal';
120
116
  if (Object.hasOwn(args, key)) throw invalid();
121
117
  args[key] = true;
122
118
  continue;
@@ -180,7 +176,6 @@ export function parseSessionArgs(argv, translate = createTranslator()) {
180
176
  !['mar-agent', 'codex', 'claude-code', 'opencode'].includes(args.runner)
181
177
  )
182
178
  throw invalid();
183
- if (action === 'stop' && !args.executionId) throw invalid();
184
179
  if (action === 'wait' && args.sessionId && args.agentIds?.length) throw invalid();
185
180
  if (
186
181
  args.until !== undefined &&
@@ -17,15 +17,13 @@ export async function prepareAgentNetworkRequest({ args, stdin, translate, sessi
17
17
  'parentSessionId',
18
18
  'scope',
19
19
  'waitFor',
20
- 'mode',
21
- 'executionId'
20
+ 'mode'
22
21
  ])
23
22
  if (args[name] !== undefined) input[name] = args[name];
24
23
  if (['send', 'stop', 'view', 'wait'].includes(args.action) && sessionId)
25
24
  input.agentId = sessionId;
26
25
  if (args.action === 'wait' && args.agentIds?.length) input.agentIds = args.agentIds;
27
26
  if (args.action === 'wait' && args.timeoutMs !== undefined) input.waitMs = args.timeoutMs;
28
- if (args.action === 'view' && args.history) input.includeHistory = true;
29
27
  if (args.message !== undefined || args.messageFile !== undefined)
30
28
  input.content = await messageContent(args, stdin, 100000, translate);
31
29
  if (args.goal !== undefined) input.goal = { objective: args.goal.trim() };