@agentrq/agentrq-ws 0.7.1 → 0.7.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.
package/README.md CHANGED
@@ -45,7 +45,7 @@ Node 20.6 or newer.
45
45
  | `workspace` | Show the workspace title and mission |
46
46
  | `task get <taskId>` | Fetch a task, with `--conversation` for its history |
47
47
  | `task next` | Take the next not-started task — **this dequeues the queue** |
48
- | `task create <title>` | Create a task |
48
+ | `task create <title>` | Create a task, with `--clear-context` to send `/clear` to the agent first |
49
49
  | `task status <taskId> <status>` | Set a task's status |
50
50
  | `reply <taskId> <text>` | Send a message to a task |
51
51
  | `attachment get <id> --task <taskId>` | Download an attachment to a file |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agentrq/agentrq-ws",
3
- "version": "0.7.1",
3
+ "version": "0.7.2",
4
4
  "description": "AgentRQ workspace client \u2014 drive an AgentRQ workspace from the command line, using the workspace's own .mcp.json",
5
5
  "keywords": [
6
6
  "agentrq",
package/src/commands.js CHANGED
@@ -161,12 +161,16 @@ export const COMMANDS = [
161
161
  {
162
162
  path: ['task', 'create'],
163
163
  summary: 'Create a task',
164
- usage: 'agentrq-ws task create <title> [--body TEXT|@file|-] [--attach PATH]...',
164
+ usage: 'agentrq-ws task create <title> [--body TEXT|@file|-] [--clear-context] [--attach PATH]...',
165
165
  options: {
166
166
  body: { type: 'string', short: 'b', description: 'Task details (@file or - for stdin)' },
167
167
  assignee: { type: 'string', description: "'human' or 'agent' (default agent)" },
168
168
  cron: { type: 'string', description: "5-field cron schedule, e.g. '30 * * * *'" },
169
169
  event: { type: 'string', description: 'Event id to publish when the task completes' },
170
+ 'clear-context': {
171
+ type: 'boolean',
172
+ description: 'Send /clear to the agent before it picks this task up',
173
+ },
170
174
  attach: { type: 'string', multiple: true, description: 'File to attach (repeatable)' },
171
175
  },
172
176
  async run(ctx) {
@@ -178,6 +182,10 @@ export const COMMANDS = [
178
182
  assignee: ctx.values.assignee,
179
183
  cronSchedule: ctx.values.cron,
180
184
  eventId: ctx.values.event,
185
+ // Only sent when asked for. Absent means "use the workspace default",
186
+ // and a literal false would override that with an opinion the caller
187
+ // never expressed.
188
+ clearContext: ctx.values['clear-context'] || undefined,
181
189
  attachments: collectAttachments(ctx.values),
182
190
  })
183
191
  },