@evandu/super-pi 0.1.276 → 0.1.278

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 (47) hide show
  1. package/agents/code-designer.md +1 -0
  2. package/agents/document-organizer.md +1 -0
  3. package/agents/group-rsi.md +44 -2
  4. package/agents/rsi-builder.md +58 -0
  5. package/agents/solution-designer.md +1 -0
  6. package/desktop/main.cjs +10 -5
  7. package/desktop/preload.cjs +2 -2
  8. package/desktop/window-state.cjs +59 -0
  9. package/dist/client/.super-pi-client-sources.json +9 -8
  10. package/dist/client/assets/{CodeMirrorEditor-WFfkDO6N.js → CodeMirrorEditor-CmfIAppR.js} +1 -1
  11. package/dist/client/assets/{GitDiffEditor-PPULzRIU.js → GitDiffEditor-BZ2Kff1j.js} +1 -1
  12. package/dist/client/assets/{GitDiffEditor-DOFVNrEW.css → GitDiffEditor-DP0DQ9Y5.css} +1 -1
  13. package/dist/client/assets/index-B5TLGyEw.css +1 -0
  14. package/dist/client/assets/{index-BjauxoWZ.js → index-sXiJhOAC.js} +14 -14
  15. package/dist/client/index.html +2 -2
  16. package/dist/server/agents.d.ts +1 -1
  17. package/dist/server/agents.js +1 -1
  18. package/dist/server/application/group-chat-service.d.ts +18 -0
  19. package/dist/server/application/group-chat-service.js +42 -4
  20. package/dist/server/application/group-execution.js +4 -1
  21. package/dist/server/application/group-rsi.d.ts +1 -0
  22. package/dist/server/application/group-rsi.js +34 -6
  23. package/dist/server/application/rsi-service.d.ts +49 -0
  24. package/dist/server/application/rsi-service.js +372 -0
  25. package/dist/server/application/run-service.d.ts +3 -0
  26. package/dist/server/application/run-service.js +10 -1
  27. package/dist/server/http-server.js +4 -1
  28. package/dist/server/index.js +35 -1
  29. package/dist/server/native-tools-extension.js +9 -4
  30. package/dist/server/rsi-evidence.d.ts +2 -0
  31. package/dist/server/rsi-evidence.js +7 -0
  32. package/dist/server/rsi-http.d.ts +3 -0
  33. package/dist/server/rsi-http.js +105 -0
  34. package/dist/server/runtime.d.ts +5 -1
  35. package/dist/server/runtime.js +15 -1
  36. package/dist/server/server-context.d.ts +2 -0
  37. package/dist/server/tool-runner.js +8 -3
  38. package/dist/server/user-tools-extension.d.ts +5 -0
  39. package/dist/server/user-tools-extension.js +50 -0
  40. package/dist/server/user-tools.d.ts +86 -0
  41. package/dist/server/user-tools.js +259 -0
  42. package/dist/shared/group-chat.d.ts +18 -0
  43. package/dist/shared/rsi.d.ts +44 -0
  44. package/dist/shared/rsi.js +1 -0
  45. package/package.json +5 -1
  46. package/skills/super-pi-capability-development/SKILL.md +32 -0
  47. package/dist/client/assets/index-CnNljc5p.css +0 -1
@@ -19,6 +19,16 @@ export type GroupRsiFinding = {
19
19
  applicability: string;
20
20
  disposition?: "accepted" | "dismissed";
21
21
  feedback?: string;
22
+ ownership?: "platform" | "user" | "mixed" | "unclassified";
23
+ ownershipReason?: string;
24
+ capability?: {
25
+ kind: "tool" | "skill";
26
+ slug: string;
27
+ name: string;
28
+ acceptance: string;
29
+ repeatToolIds?: string[];
30
+ baseVersion?: number;
31
+ };
22
32
  };
23
33
  export type GroupRsiReport = {
24
34
  id: string;
@@ -31,6 +41,12 @@ export type GroupRsiReport = {
31
41
  retrospective: string;
32
42
  findings: GroupRsiFinding[];
33
43
  model?: GroupModel;
44
+ artifactReads?: string[];
45
+ runEvidence?: {
46
+ startedAt: string;
47
+ finishedAt: string;
48
+ elapsedMs: number;
49
+ }[];
34
50
  };
35
51
  export type GroupRsi = {
36
52
  enabled: boolean;
@@ -42,6 +58,7 @@ export type GroupRsi = {
42
58
  sourceKey?: string;
43
59
  reports: GroupRsiReport[];
44
60
  pending?: boolean;
61
+ automaticImprovements?: boolean;
45
62
  };
46
63
  export type GroupModerator = {
47
64
  model?: GroupModel;
@@ -90,6 +107,7 @@ export type GroupExecutionStep = GroupExecutionStepBase & ({
90
107
  detail?: string;
91
108
  lastUpdateAt?: string;
92
109
  durationMs?: number;
110
+ result?: string;
93
111
  });
94
112
  export type GroupExecutionTrace = {
95
113
  steps: GroupExecutionStep[];
@@ -0,0 +1,44 @@
1
+ import type { GroupRsi, GroupRsiFinding } from "./group-chat.js";
2
+ export type RsiSource = {
3
+ kind: "session" | "group";
4
+ id: string;
5
+ workspaceId: string;
6
+ };
7
+ export type RsiImprovement = {
8
+ id: string;
9
+ key: string;
10
+ source: RsiSource;
11
+ findingId: string;
12
+ reportId: string;
13
+ slug: string;
14
+ kind: "tool" | "skill";
15
+ name: string;
16
+ acceptance: string;
17
+ status: "queued" | "running" | "available" | "failed" | "interrupted" | "cancelled";
18
+ createdAt: string;
19
+ updatedAt: string;
20
+ conversationId?: string;
21
+ error?: string;
22
+ evidence: GroupRsiFinding["evidence"];
23
+ version?: number;
24
+ evidenceContext?: string;
25
+ };
26
+ export type RsiSnapshot = {
27
+ state: GroupRsi;
28
+ improvements: RsiImprovement[];
29
+ capabilities: {
30
+ slug: string;
31
+ name: string;
32
+ kind: "tool" | "skill";
33
+ version: number;
34
+ applicability: string;
35
+ }[];
36
+ usage: {
37
+ slug: string;
38
+ version: number;
39
+ status: string;
40
+ durationMs: number;
41
+ at: string;
42
+ }[];
43
+ };
44
+ export declare const rsiKey: (source: RsiSource) => string;
@@ -0,0 +1 @@
1
+ export const rsiKey = (source) => `${source.kind}:${source.workspaceId}:${source.id}`;
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "superPi": {
4
4
  "managedDirectListener": true
5
5
  },
6
- "version": "0.1.276",
6
+ "version": "0.1.278",
7
7
  "description": "Web control plane and companion for Pi",
8
8
  "license": "MIT",
9
9
  "type": "module",
@@ -54,6 +54,9 @@
54
54
  "pack:server": "npm run build && node scripts/pack-server.mjs"
55
55
  },
56
56
  "check:logic": [
57
+ "scripts/rsi-capability-loop.test.mjs",
58
+
59
+ "scripts/desktop-window-state.test.mjs",
57
60
  "scripts/remote-listener.test.mjs",
58
61
  "scripts/group-member-sessions.test.mjs",
59
62
  "scripts/group-member-pi-history.test.mjs",
@@ -327,6 +330,7 @@
327
330
  "scripts/session-reminder-pmo-rights.test.mjs"
328
331
  ],
329
332
  "check:browser": [
333
+ "scripts/rsi-session-browser.test.mjs",
330
334
  "scripts/message-source-links-browser.test.mjs",
331
335
  "scripts/settings-number-drafts-browser.test.mjs",
332
336
  "scripts/remote-tool-runtime-browser.test.mjs",
@@ -0,0 +1,32 @@
1
+ ---
2
+ name: super-pi-capability-development
3
+ description: Turn recurring enterprise scripts and validated workflows into persistent agent-callable user tools and skills, using user_tool and user_tool_manage.
4
+ ---
5
+
6
+ # Reusable user capabilities
7
+
8
+ Use this for recurring analysis of company-specific systems, private data formats, or specialized business procedures. First call `user_tool` with `action: "list"`. Read applicability and instructions; reuse an existing suitable tool instead of rebuilding it. General platform deficiencies belong in the RSI platform findings and are not hot-patched into the installed application.
9
+
10
+ For a new agent-callable tool, use `user_tool_manage` action `register` with `specification`:
11
+
12
+ ```json
13
+ {
14
+ "kind": "tool",
15
+ "slug": "company-result-summary",
16
+ "name": "Company result summary",
17
+ "description": "Summarize numeric values in the company's result format",
18
+ "applicability": "Numeric values from the internal results adapter",
19
+ "instructions": "Call user_tool invoke with values; empty input returns zero.",
20
+ "files": [{"path":"run.py","content":"import json,sys\np=json.load(sys.stdin)\nprint(json.dumps({'sum':sum(p['values'])}))\n"}],
21
+ "script": {"path":"run.py","parameters":{"values":{"type":"array","required":true}}},
22
+ "tests": [{"params":{"values":[2,3]},"expected":{"sum":5}},{"params":{"values":[]},"expected":{"sum":0}}]
23
+ }
24
+ ```
25
+
26
+ Registration returns the immutable version. Then call `validate` with the slug and version. The platform runs actual Python tests. Failed candidates stay unavailable; fix them by registering a new version. Use real normal and edge cases from the task, not fabricated success receipts. Dependencies use exact `pkg==version` pins in `environment.requires`. Python receives JSON on stdin and prints one JSON object; do not build a second server or model client.
27
+
28
+ Verified tools are discovered by subsequent ordinary sessions and group members through `user_tool`. Use `invoke` with slug, params, and optionally a pinned version. Instructions can be registered as kind `skill`, then activated with `activate-skill` and a `testedTool` already validated by the platform. Pure untested prompt text must remain a draft, not a verified workflow.
29
+
30
+ The platform owns storage outside its npm installation. Do not edit `node_modules` or rewrite an existing registered version's files. Reuse enterprise MCP connections when available; do not embed personal credentials in files or test fixtures. A sidebar page for humans uses the separate super-pi-tool-development skill and `tool_register`.
31
+
32
+ Report actual tests and usage receipts. Functional readiness alone does not prove task-level speed or quality improvement; keep those claims pending until observed in later work.