@trevonistrevon/pi-loop 0.1.7 → 0.1.9
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/CONTRIBUTING.md +1 -1
- package/dist/index.js +2 -0
- package/package.json +2 -2
- package/src/index.ts +2 -0
package/CONTRIBUTING.md
CHANGED
package/dist/index.js
CHANGED
|
@@ -237,6 +237,7 @@ Use this tool whenever the user asks to:
|
|
|
237
237
|
- "watch for..." or "when X happens, do Y"
|
|
238
238
|
- "schedule a recurring check"
|
|
239
239
|
- set up a periodic monitor or poller
|
|
240
|
+
- has a task list with open items — create a loop to work through tasks automatically
|
|
240
241
|
|
|
241
242
|
DO NOT use raw Bash loops (for/sleep/while). Use LoopCreate instead — it integrates with the session lifecycle, survives across turns, and the scheduler handles timing.
|
|
242
243
|
|
|
@@ -261,6 +262,7 @@ Skip this tool when the task is a one-off check (just do it directly) or when th
|
|
|
261
262
|
"When the user asks for a loop, repeating task, periodic check, or scheduled reminder, use LoopCreate — not raw Bash for/sleep/while.",
|
|
262
263
|
"Use LoopCreate for any 'every X seconds/minutes/hours' requests.",
|
|
263
264
|
"After creating a loop, tell the user the loop ID so they can cancel it with LoopDelete.",
|
|
265
|
+
"After creating tasks with TaskCreate, create a loop to keep working through them: LoopCreate trigger='30s' prompt='Run TaskList, pick the next available pending task, work on it. Continue until all tasks are completed.' This ensures the agent keeps making progress across turns instead of stopping after one task.",
|
|
264
266
|
],
|
|
265
267
|
parameters: Type.Object({
|
|
266
268
|
trigger: Type.String({ description: "Cron expression (e.g., '5m', '1h', '0 9 * * 1-5'), event source (e.g., 'tool_execution_start'), or JSON hybrid spec" }),
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trevonistrevon/pi-loop",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.9",
|
|
4
4
|
"description": "A pi extension for cron/event-based agent re-wake loops and background process monitoring.",
|
|
5
5
|
"author": "trevonistrevon",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"repository": {
|
|
8
8
|
"type": "git",
|
|
9
|
-
"url": "https://github.com/
|
|
9
|
+
"url": "https://github.com/trvon/pi-loop.git"
|
|
10
10
|
},
|
|
11
11
|
"keywords": [
|
|
12
12
|
"pi-package",
|
package/src/index.ts
CHANGED
|
@@ -260,6 +260,7 @@ Use this tool whenever the user asks to:
|
|
|
260
260
|
- "watch for..." or "when X happens, do Y"
|
|
261
261
|
- "schedule a recurring check"
|
|
262
262
|
- set up a periodic monitor or poller
|
|
263
|
+
- has a task list with open items — create a loop to work through tasks automatically
|
|
263
264
|
|
|
264
265
|
DO NOT use raw Bash loops (for/sleep/while). Use LoopCreate instead — it integrates with the session lifecycle, survives across turns, and the scheduler handles timing.
|
|
265
266
|
|
|
@@ -284,6 +285,7 @@ Skip this tool when the task is a one-off check (just do it directly) or when th
|
|
|
284
285
|
"When the user asks for a loop, repeating task, periodic check, or scheduled reminder, use LoopCreate — not raw Bash for/sleep/while.",
|
|
285
286
|
"Use LoopCreate for any 'every X seconds/minutes/hours' requests.",
|
|
286
287
|
"After creating a loop, tell the user the loop ID so they can cancel it with LoopDelete.",
|
|
288
|
+
"After creating tasks with TaskCreate, create a loop to keep working through them: LoopCreate trigger='30s' prompt='Run TaskList, pick the next available pending task, work on it. Continue until all tasks are completed.' This ensures the agent keeps making progress across turns instead of stopping after one task.",
|
|
287
289
|
],
|
|
288
290
|
parameters: Type.Object({
|
|
289
291
|
trigger: Type.String({ description: "Cron expression (e.g., '5m', '1h', '0 9 * * 1-5'), event source (e.g., 'tool_execution_start'), or JSON hybrid spec" }),
|