@ai-ecoverse/slicc-agent 3.5.0 → 3.7.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.
Files changed (91) hide show
  1. package/README.md +21 -4
  2. package/bin/agent +76 -0
  3. package/dist/agent.js +7 -14
  4. package/dist/agent.js.map +2 -2
  5. package/dist/agents.js +133 -0
  6. package/dist/agents.js.map +7 -0
  7. package/dist/client.js +3 -1
  8. package/dist/client.js.map +2 -2
  9. package/dist/cone.js +2 -16
  10. package/dist/cone.js.map +2 -2
  11. package/dist/control.js +68 -10
  12. package/dist/control.js.map +2 -2
  13. package/dist/host.js +11 -2
  14. package/dist/host.js.map +2 -2
  15. package/dist/kernel/env.js +49 -5
  16. package/dist/kernel/env.js.map +2 -2
  17. package/dist/kernel/exec.js +2 -1
  18. package/dist/kernel/exec.js.map +2 -2
  19. package/dist/kernel/groups.js +31 -0
  20. package/dist/kernel/groups.js.map +7 -0
  21. package/dist/kernel/watch.js +86 -0
  22. package/dist/kernel/watch.js.map +2 -2
  23. package/dist/licks/index.js +16 -1
  24. package/dist/licks/index.js.map +2 -2
  25. package/dist/licks/lick.js.map +1 -1
  26. package/dist/licks/licks.js +12 -1
  27. package/dist/licks/licks.js.map +2 -2
  28. package/dist/main.js +38 -9
  29. package/dist/main.js.map +2 -2
  30. package/dist/roles/frontmatter.js +59 -0
  31. package/dist/roles/frontmatter.js.map +7 -0
  32. package/dist/roles/roles.js +204 -0
  33. package/dist/roles/roles.js.map +7 -0
  34. package/dist/scoops/cli.js +391 -0
  35. package/dist/scoops/cli.js.map +7 -0
  36. package/dist/scoops/extension.js +301 -0
  37. package/dist/scoops/extension.js.map +7 -0
  38. package/dist/scoops/identity.js +33 -0
  39. package/dist/scoops/identity.js.map +7 -0
  40. package/dist/scoops/index.js +120 -0
  41. package/dist/scoops/index.js.map +7 -0
  42. package/dist/scoops/requests.js +136 -0
  43. package/dist/scoops/requests.js.map +7 -0
  44. package/dist/scoops/service.js +409 -0
  45. package/dist/scoops/service.js.map +7 -0
  46. package/dist/scoops/sync.js +252 -0
  47. package/dist/scoops/sync.js.map +7 -0
  48. package/dist/scoops/visible.js +15 -0
  49. package/dist/scoops/visible.js.map +7 -0
  50. package/dist/services.js.map +2 -2
  51. package/dist/spectrum/agent-port.js +137 -54
  52. package/dist/spectrum/agent-port.js.map +2 -2
  53. package/dist/spectrum/messages.js +19 -10
  54. package/dist/spectrum/messages.js.map +2 -2
  55. package/dist/types/agent.d.ts +3 -1
  56. package/dist/types/agents.d.ts +54 -0
  57. package/dist/types/client.d.ts +3 -1
  58. package/dist/types/cone.d.ts +1 -3
  59. package/dist/types/control.d.ts +7 -1
  60. package/dist/types/host.d.ts +2 -1
  61. package/dist/types/kernel/client.d.ts +13 -0
  62. package/dist/types/kernel/env.d.ts +13 -2
  63. package/dist/types/kernel/exec.d.ts +2 -2
  64. package/dist/types/kernel/groups.d.ts +7 -0
  65. package/dist/types/kernel/watch.d.ts +12 -1
  66. package/dist/types/licks/index.d.ts +5 -0
  67. package/dist/types/licks/lick.d.ts +1 -1
  68. package/dist/types/licks/licks.d.ts +2 -1
  69. package/dist/types/main.d.ts +3 -0
  70. package/dist/types/roles/frontmatter.d.ts +7 -0
  71. package/dist/types/roles/roles.d.ts +48 -0
  72. package/dist/types/scoops/cli.d.ts +66 -0
  73. package/dist/types/scoops/extension.d.ts +63 -0
  74. package/dist/types/scoops/identity.d.ts +6 -0
  75. package/dist/types/scoops/index.d.ts +37 -0
  76. package/dist/types/scoops/requests.d.ts +32 -0
  77. package/dist/types/scoops/service.d.ts +116 -0
  78. package/dist/types/scoops/sync.d.ts +22 -0
  79. package/dist/types/scoops/visible.d.ts +4 -0
  80. package/dist/types/services.d.ts +30 -0
  81. package/dist/types/spectrum/agent-port.d.ts +13 -11
  82. package/dist/types/views.d.ts +12 -0
  83. package/dist/views.js +89 -0
  84. package/dist/views.js.map +7 -0
  85. package/package.json +6 -4
  86. package/packages/vfs-root/agents/delegate.md +8 -0
  87. package/packages/vfs-root/agents/oracle.md +25 -0
  88. package/packages/vfs-root/agents/reviewer.md +23 -0
  89. package/packages/vfs-root/agents/scout.md +30 -0
  90. package/packages/vfs-root/agents/worker.md +23 -0
  91. package/packages/vfs-root/skills/agent/SKILL.md +72 -0
@@ -0,0 +1,30 @@
1
+ ---
2
+ name: scout
3
+ description: Fast recon of files and folders that returns compressed context another agent can use without re-reading everything
4
+ tools: read, bash
5
+ thinking: low
6
+ aliases: explorer
7
+ ---
8
+
9
+ You are a scout. Investigate quickly and return findings that another agent, who has not seen the files, can act on.
10
+
11
+ Infer how thorough to be from the task; default to medium:
12
+ - quick: targeted lookups, key files only;
13
+ - medium: follow references, read the critical parts;
14
+ - thorough: trace every dependency, including tests.
15
+
16
+ Use bash (`grep -rn`, `find`, `ls`, `sed -n`) to locate things and read only the parts that matter. Do not change any file.
17
+
18
+ Answer in this shape:
19
+
20
+ ## Files
21
+ Exact paths with line ranges, and one line each on what is there.
22
+
23
+ ## Key facts
24
+ Types, functions, settings and constraints the next agent needs, quoted briefly.
25
+
26
+ ## How it fits together
27
+ A few sentences on the relationships between the pieces.
28
+
29
+ ## Start here
30
+ The one file and place where the next agent should begin, and why.
@@ -0,0 +1,23 @@
1
+ ---
2
+ name: worker
3
+ description: Implements a well-defined change and reports exactly what it changed
4
+ tools: read, write, edit, bash
5
+ aliases: developer, coder, implementer
6
+ ---
7
+
8
+ You are a worker. Make the change the task asks for, completely and carefully, and nothing else.
9
+
10
+ - Read what you need before you edit. Prefer small, exact edits over rewriting files.
11
+ - Run what proves the change works: the tests, the build, or a quick command that exercises it.
12
+ - If the task is ambiguous or blocked, stop and say what you need instead of guessing.
13
+
14
+ Answer in this shape:
15
+
16
+ ## Changed
17
+ Each file you changed, with one line on what and why.
18
+
19
+ ## Checked
20
+ The commands you ran and what they showed.
21
+
22
+ ## Open
23
+ Anything left undone, risky or worth a second look. Write "nothing" if there is nothing.
@@ -0,0 +1,72 @@
1
+ ---
2
+ name: agent
3
+ description: Hand work to scoops (helper agents in SLICC), synchronously for quick bounded answers or asynchronously for long or parallel work.
4
+ ---
5
+
6
+ # Agent
7
+
8
+ The `agent` command starts scoops: helper agents with their own conversation and their own folder under `/scoops/<handle>/`. A scoop cannot see your conversation, so every prompt must carry all the context it needs. The user can run the same command in a terminal and sees every scoop in the agents rail. `subagent` is the same command (`subagent spawn` = `agent --async`).
9
+
10
+ ## Synchronous: you need the answer now
11
+
12
+ ```sh
13
+ agent --name check --prompt "Read /home/app/src/config.ts and list every setting with its default"
14
+ agent --agent reviewer --file /tmp/diff.txt --prompt "Review this diff"
15
+ ```
16
+
17
+ The command blocks, prints the scoop's final answer on stdout and exits 0, or exits non-zero with the reason on stderr. Use it like any command, in pipes and scripts. Afterwards the scoop is stopped, its folder is removed, and its transcript is archived in `/tmp/agent-sessions/<handle>.md` (`--persist-session` keeps it in `/home/sessions/`, `--no-persist-session` keeps none).
18
+
19
+ - Give the command a bash timeout that fits the work. If your bash call is stopped, the scoop stops too; if it only times out while you keep working, the scoop continues and its answer arrives later as a lick.
20
+ - `--background-after <seconds>` hands a long run over on purpose: after that many seconds the command prints the handle and returns, and the answer arrives as a lick.
21
+ - `--read-only <path,path>` lets the scoop read more folders. In v6's form, `agent <cwd> <allowed-commands> <prompt>`, the scoop works in `<cwd>` and is told which commands to use; that list is not enforced.
22
+ - Scoops can run `agent` themselves, up to three levels deep.
23
+
24
+ ## Asynchronous: long or parallel work
25
+
26
+ ```sh
27
+ agent --async --name implementation --prompt "Complete task"
28
+ subagent spawn --agent scout --prompt "Map how licks are delivered"
29
+ ```
30
+
31
+ The command prints the scoop's handle at once. The scoop keeps working, and when it answers a request you sent, the report arrives as a `scoop-notify` lick: one line `[scoop <name> (<role>) <status>]`, the path of the full answer under `/scoops/<handle>/reports/`, its line count and a 1,000-character preview. Read the file when you need the whole answer. Only cones start async scoops.
32
+
33
+ To wake up once for several scoops instead of once per scoop:
34
+
35
+ ```sh
36
+ agent wait --notify review scout
37
+ ```
38
+
39
+ It returns at once, and one `scoop-wait` lick brings all their answers together. `agent wait <handle>...` blocks, 30 seconds by default (`--timeout <seconds>`), and prints the latest answers. Keep blocking waits short, because the user's messages can't reach you while you wait.
40
+
41
+ ## Roles, models and tools
42
+
43
+ `--agent <role>` gives a scoop a role, such as scout, worker, reviewer, oracle or delegate; `agent list --agents` shows every role and where it comes from. Put your own roles in `~/.pi/agent/agents/`. A project's `.pi/agents` folder is read only once the folder is trusted, which SLICC doesn't support yet.
44
+
45
+ A scoop starts with your provider, model and thinking level. Use `--model provider/model`, `--thinking` or `--effort` only when you mean to choose differently. Never pass `$PI_PROVIDER`, `$PI_MODEL` or `$PI_REASONING_LEVEL` back explicitly.
46
+
47
+ Without `--tools`, a scoop gets read, write, edit and bash; `--tools read,bash` is an allowlist. grep, find and ls map to bash, and bash can change files, so no tool list is truly read-only. A scoop's read, write and edit tools reach only its folder, /tmp and its working folder, and read /home; its bash is not confined, and the scoop is told so.
48
+
49
+ ## Inspect, talk, stop
50
+
51
+ ```sh
52
+ agent list
53
+ agent status <handle>
54
+ agent rename <handle> "new name"
55
+ agent send <handle> "message" # idle: a new request; busy: steers the current work
56
+ agent send <handle> --follow-up "message" # busy: after the current work
57
+ agent stop <handle>
58
+ ```
59
+
60
+ Stop every async scoop you no longer need. Stopping ends its work and removes it from the list; its transcript is kept, so rewinding a turn can bring it back, and its files stay in `/scoops/<handle>/`.
61
+
62
+ ## From inside a scoop
63
+
64
+ A scoop can post a progress note to its cone; it arrives as a lick:
65
+
66
+ ```sh
67
+ agent send parent "Halfway: the parser is done, starting on the tests"
68
+ ```
69
+
70
+ ## Limits
71
+
72
+ A cone can have 16 live scoops and start 64 per turn (`subagents.maxLiveScoops` and `subagents.maxPerTurn` in `~/.pi/agent/settings.json`).