@agimon-ai/po-loop 0.0.0-alpha.0 → 0.0.0-stage
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 +2 -100
- package/package.json +3 -122
- package/LICENSE +0 -21
- package/dist/apiContracts.cjs +0 -17
- package/dist/apiContracts.cjs.map +0 -1
- package/dist/apiContracts.d.mts +0 -53
- package/dist/apiContracts.d.mts.map +0 -1
- package/dist/apiContracts.mjs +0 -13
- package/dist/apiContracts.mjs.map +0 -1
- package/dist/extensions/server.cjs +0 -673
- package/dist/extensions/server.cjs.map +0 -1
- package/dist/extensions/server.d.mts +0 -5
- package/dist/extensions/server.d.mts.map +0 -1
- package/dist/extensions/server.mjs +0 -668
- package/dist/extensions/server.mjs.map +0 -1
- package/dist/extensions/web.mjs +0 -257
- package/dist/extensions/web.mjs.map +0 -1
- package/dist/index.cjs +0 -0
- package/dist/index.d.mts +0 -2
- package/dist/index.mjs +0 -1
- package/dist/loopLaunchers-CfXIHzJR.cjs +0 -32
- package/dist/loopLaunchers-CfXIHzJR.cjs.map +0 -1
- package/dist/loopLaunchers-CskBMAKF.mjs +0 -15
- package/dist/loopLaunchers-CskBMAKF.mjs.map +0 -1
- package/dist/loopLaunchers-CykwUc-I.d.mts +0 -69
- package/dist/loopLaunchers-CykwUc-I.d.mts.map +0 -1
- package/dist/loopLaunchers.cjs +0 -5
- package/dist/loopLaunchers.d.mts +0 -2
- package/dist/loopLaunchers.mjs +0 -2
- package/llms.txt +0 -9
- package/src/prompts/po-use-loop/SKILL.md +0 -44
- package/src/types/loopView.ts +0 -73
package/README.md
CHANGED
|
@@ -1,101 +1,3 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Temporary Holding Version
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
Part of the [Po distribution](https://www.npmjs.com/package/@agimon-ai/po).
|
|
6
|
-
|
|
7
|
-
Several loops can coexist. Loop is a minor mode and remains active while at least one scheduled
|
|
8
|
-
prompt belongs to the current session.
|
|
9
|
-
|
|
10
|
-
> **Alpha:** launcher and scheduling contracts may change between releases.
|
|
11
|
-
|
|
12
|
-
## Requirements
|
|
13
|
-
|
|
14
|
-
- Node.js 24 or newer
|
|
15
|
-
|
|
16
|
-
## Install
|
|
17
|
-
|
|
18
|
-
The seeded `modes.yaml` selects Loop in `default.packages`. Keep it there or select it through a
|
|
19
|
-
layer; it is not fixed host infrastructure.
|
|
20
|
-
|
|
21
|
-
## Start and manage loops
|
|
22
|
-
|
|
23
|
-
Activate the Loop minor mode, then ask the agent to set an interval loop or a cron job; it uses the
|
|
24
|
-
`loop_start` tool. The Activity Loops section lists the session's loops whether or not the mode is
|
|
25
|
-
active, and each row has a stop control. `/loops` lists loops and `/loops stop <instanceId>` stops
|
|
26
|
-
one.
|
|
27
|
-
|
|
28
|
-
The default interval is 300 seconds. Accepted intervals range from 30 to 3600 seconds. A loop runs
|
|
29
|
-
its prompt once immediately, then schedules later passes.
|
|
30
|
-
|
|
31
|
-
If Pi is busy, a due pass waits for the shared agent to become idle. Multiple due signals can
|
|
32
|
-
coalesce rather than creating overlapping model turns. Stopping a loop prevents future passes but
|
|
33
|
-
does not rewind side effects from a pass already sent.
|
|
34
|
-
|
|
35
|
-
## Lifecycle and cost
|
|
36
|
-
|
|
37
|
-
Loop state belongs to the session's `doom/loop-launchers` service; it is not a durable queue.
|
|
38
|
-
Replacing or shutting down the session aborts pending launches and stops active timers. Resuming a
|
|
39
|
-
transcript does not restart old loops.
|
|
40
|
-
|
|
41
|
-
Every pass can start another model turn and repeat tool or external side effects. Choose
|
|
42
|
-
conservative intervals, make prompts idempotent where possible, and stop loops when the recurring
|
|
43
|
-
work is complete.
|
|
44
|
-
|
|
45
|
-
## Web extension slots
|
|
46
|
-
|
|
47
|
-
The Loop Activity section declares `loop.registration` for start controls and `loop.items` for
|
|
48
|
-
session-scoped instance rows. Other web plugins may fill either slot; Loop owns the section shell and
|
|
49
|
-
renders all registered fills without requiring a feature-specific dependency.
|
|
50
|
-
|
|
51
|
-
## Extension authors: cross-extension launchers
|
|
52
|
-
|
|
53
|
-
Launcher definitions use the shared Cordis service. A consumer registers a launcher and returns its
|
|
54
|
-
cleanup callback. Cordis removes that launcher when either package or the session unloads, then
|
|
55
|
-
registers it again when the provider returns.
|
|
56
|
-
|
|
57
|
-
```ts
|
|
58
|
-
import { DOOM_LOOP_LAUNCHERS_SERVICE, requireDoomLoopLaunchers } from '@agimon-ai/po-loop/loop-launchers';
|
|
59
|
-
import type { Context } from '@deepseek-ai/cordis';
|
|
60
|
-
|
|
61
|
-
export function myLoopPlugin(ctx: Context): void {
|
|
62
|
-
ctx.inject([DOOM_LOOP_LAUNCHERS_SERVICE], (sessionContext) => {
|
|
63
|
-
const registration = requireDoomLoopLaunchers(sessionContext).register({
|
|
64
|
-
id: 'example.recurring-check',
|
|
65
|
-
source: '@example/po-recurring-check',
|
|
66
|
-
label: 'Recurring check',
|
|
67
|
-
async launch({ instanceId, signal }) {
|
|
68
|
-
signal.throwIfAborted();
|
|
69
|
-
// Start session work. The returned stop callback owns cleanup.
|
|
70
|
-
return { instanceId, stop: () => undefined };
|
|
71
|
-
},
|
|
72
|
-
});
|
|
73
|
-
return () => registration.dispose('Contributor unloaded.');
|
|
74
|
-
});
|
|
75
|
-
}
|
|
76
|
-
```
|
|
77
|
-
|
|
78
|
-
Mount that plugin on the runner's shared Doom Cordis root. Loop owns the registry and default
|
|
79
|
-
launcher. Consumers depend only on
|
|
80
|
-
`@agimon-ai/po-loop/loop-launchers`; there is no process-global registry or
|
|
81
|
-
session-ID lookup API.
|
|
82
|
-
|
|
83
|
-
The package root exports the service contract
|
|
84
|
-
types.
|
|
85
|
-
|
|
86
|
-
## Development
|
|
87
|
-
|
|
88
|
-
```bash
|
|
89
|
-
pnpm build
|
|
90
|
-
pnpm typecheck
|
|
91
|
-
pnpm test
|
|
92
|
-
pnpm lint
|
|
93
|
-
```
|
|
94
|
-
|
|
95
|
-
Maintained by [Agimon](https://agimon.ai/about).
|
|
96
|
-
|
|
97
|
-
## License
|
|
98
|
-
|
|
99
|
-
MIT
|
|
100
|
-
|
|
101
|
-
Server entries live directly in `src/extensions/`. They declare commands, minor mode owners, and optional services. The helpers own registration and cleanup; `onDispose` clears UI state, while session service disposal stops pending launches and timers. Services live in named folders and public exports remain flat.
|
|
3
|
+
This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
|
package/package.json
CHANGED
|
@@ -1,125 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agimon-ai/po-loop",
|
|
3
|
-
"version": "0.0.0-
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
"ai",
|
|
7
|
-
"automation",
|
|
8
|
-
"coding-agent",
|
|
9
|
-
"developer-tools",
|
|
10
|
-
"pi-coding-agent",
|
|
11
|
-
"pi-extension",
|
|
12
|
-
"pi-package",
|
|
13
|
-
"po",
|
|
14
|
-
"prompt-scheduler",
|
|
15
|
-
"recurring-tasks"
|
|
16
|
-
],
|
|
17
|
-
"homepage": "https://agimon.ai",
|
|
18
|
-
"bugs": {
|
|
19
|
-
"url": "https://github.com/AgiFlow/po/issues"
|
|
20
|
-
},
|
|
21
|
-
"license": "MIT",
|
|
22
|
-
"author": "Vuong Ngo",
|
|
23
|
-
"repository": {
|
|
24
|
-
"type": "git",
|
|
25
|
-
"url": "git+https://github.com/AgiFlow/po.git",
|
|
26
|
-
"directory": "packages/minor/po-loop"
|
|
27
|
-
},
|
|
28
|
-
"files": [
|
|
29
|
-
"dist",
|
|
30
|
-
"llms.txt",
|
|
31
|
-
"src/prompts",
|
|
32
|
-
"src/types/loopView.ts",
|
|
33
|
-
"README.md",
|
|
34
|
-
"LICENSE",
|
|
35
|
-
"package.json"
|
|
36
|
-
],
|
|
37
|
-
"type": "module",
|
|
38
|
-
"main": "./dist/index.cjs",
|
|
39
|
-
"module": "./dist/index.mjs",
|
|
40
|
-
"types": "./dist/index.d.mts",
|
|
41
|
-
"jsnext:main": "./dist/index.mjs",
|
|
42
|
-
"exports": {
|
|
43
|
-
".": {
|
|
44
|
-
"types": "./dist/index.d.mts",
|
|
45
|
-
"import": "./dist/index.mjs",
|
|
46
|
-
"require": "./dist/index.cjs"
|
|
47
|
-
},
|
|
48
|
-
"./extensions/server": {
|
|
49
|
-
"types": "./dist/extensions/server.d.mts",
|
|
50
|
-
"import": "./dist/extensions/server.mjs",
|
|
51
|
-
"require": "./dist/extensions/server.cjs"
|
|
52
|
-
},
|
|
53
|
-
"./extensions/web": {
|
|
54
|
-
"import": "./dist/extensions/web.mjs"
|
|
55
|
-
},
|
|
56
|
-
"./loopLaunchers": {
|
|
57
|
-
"types": "./dist/loopLaunchers.d.mts",
|
|
58
|
-
"import": "./dist/loopLaunchers.mjs",
|
|
59
|
-
"require": "./dist/loopLaunchers.cjs"
|
|
60
|
-
},
|
|
61
|
-
"./package.json": "./package.json"
|
|
62
|
-
},
|
|
63
|
-
"publishConfig": {
|
|
64
|
-
"access": "public"
|
|
65
|
-
},
|
|
66
|
-
"dependencies": {
|
|
67
|
-
"@agimon-ai/po-core": "0.0.0-alpha.0",
|
|
68
|
-
"@agimon-ai/po-minor-mode": "0.0.0-alpha.0",
|
|
69
|
-
"@agimon-ai/po-ui": "0.0.0-alpha.0",
|
|
70
|
-
"@agimon-ai/po-web-components": "0.0.0-alpha.0",
|
|
71
|
-
"@deepseek-ai/cordis": "4.0.4",
|
|
72
|
-
"croner": "10.0.1",
|
|
73
|
-
"typebox": "1.3.34"
|
|
74
|
-
},
|
|
75
|
-
"devDependencies": {
|
|
76
|
-
"@agimon-ai/po-build": "0.0.0-alpha.0",
|
|
77
|
-
"@earendil-works/pi-coding-agent": "1.0.2",
|
|
78
|
-
"@types/node": "26.6.4",
|
|
79
|
-
"@types/react": "19.3.0",
|
|
80
|
-
"@types/react-dom": "19.3.0",
|
|
81
|
-
"@vitest/coverage-v8": "5.0.3",
|
|
82
|
-
"react": "19.3.0",
|
|
83
|
-
"react-dom": "19.3.0",
|
|
84
|
-
"tsdown": "0.23.0",
|
|
85
|
-
"typescript": "7.0.2",
|
|
86
|
-
"vitest": "5.0.3"
|
|
87
|
-
},
|
|
88
|
-
"peerDependencies": {
|
|
89
|
-
"@earendil-works/pi-coding-agent": "1.0.2"
|
|
90
|
-
},
|
|
91
|
-
"peerDependenciesMeta": {
|
|
92
|
-
"@earendil-works/pi-coding-agent": {
|
|
93
|
-
"optional": true
|
|
94
|
-
}
|
|
95
|
-
},
|
|
96
|
-
"engines": {
|
|
97
|
-
"node": ">=24"
|
|
98
|
-
},
|
|
99
|
-
"poServer": {
|
|
100
|
-
"entry": "./generated/server.ts",
|
|
101
|
-
"dist": "./dist/extensions/server.mjs",
|
|
102
|
-
"scopes": [
|
|
103
|
-
"session"
|
|
104
|
-
],
|
|
105
|
-
"contracts": {
|
|
106
|
-
"entry": "./src/exports/apiContracts.ts",
|
|
107
|
-
"dist": "./dist/apiContracts.mjs"
|
|
108
|
-
}
|
|
109
|
-
},
|
|
110
|
-
"poWeb": {
|
|
111
|
-
"pluginId": "loop",
|
|
112
|
-
"channels": [],
|
|
113
|
-
"client": "./dist/extensions/web.mjs",
|
|
114
|
-
"scopes": [
|
|
115
|
-
"session"
|
|
116
|
-
]
|
|
117
|
-
},
|
|
118
|
-
"scripts": {
|
|
119
|
-
"build": "tsdown",
|
|
120
|
-
"test": "vitest --run",
|
|
121
|
-
"typecheck": "tsc --noEmit && tsc --noEmit -p tsconfig.web.json",
|
|
122
|
-
"lint": "oxlint . && oxfmt . --check",
|
|
123
|
-
"fixcode": "oxlint . --fix && oxfmt ."
|
|
124
|
-
}
|
|
3
|
+
"version": "0.0.0-stage",
|
|
4
|
+
"stub": true,
|
|
5
|
+
"description": "Temporary package placeholder for staged publishing"
|
|
125
6
|
}
|
package/LICENSE
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2026 Vuong Ngo
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
package/dist/apiContracts.cjs
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
Object.defineProperties(exports, {
|
|
2
|
-
__esModule: { value: true },
|
|
3
|
-
[Symbol.toStringTag]: { value: "Module" }
|
|
4
|
-
});
|
|
5
|
-
//#region src/schemas/apiContracts.ts
|
|
6
|
-
/** This facet contributes agent tools, commands or lifecycle only, with no separate HTTP or socket surface. */
|
|
7
|
-
const apiContracts = (0, require("@agimon-ai/po-core/apiContracts").defineApiContract)({
|
|
8
|
-
version: 1,
|
|
9
|
-
http: [],
|
|
10
|
-
sockets: [],
|
|
11
|
-
dynamic: []
|
|
12
|
-
});
|
|
13
|
-
//#endregion
|
|
14
|
-
exports.apiContracts = apiContracts;
|
|
15
|
-
exports.default = apiContracts;
|
|
16
|
-
|
|
17
|
-
//# sourceMappingURL=apiContracts.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"apiContracts.cjs","names":["defineApiContract"],"sources":["../src/schemas/apiContracts.ts"],"sourcesContent":["import { defineApiContract } from '@agimon-ai/po-core/apiContracts';\n\n/** This facet contributes agent tools, commands or lifecycle only, with no separate HTTP or socket surface. */\nexport const apiContracts = defineApiContract({ version: 1, http: [], sockets: [], dynamic: [] });\nexport default apiContracts;\n"],"mappings":";;;;;;AAGA,MAAa,gBAAA,4CAAeA,CAAAA,CAAAA,kBAAAA,CAAkB;CAAE,SAAS;CAAG,MAAM,CAAC;CAAG,SAAS,CAAC;CAAG,SAAS,CAAC;AAAE,CAAC"}
|
package/dist/apiContracts.d.mts
DELETED
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
//#region src/schemas/apiContracts.d.ts
|
|
2
|
-
/** This facet contributes agent tools, commands or lifecycle only, with no separate HTTP or socket surface. */
|
|
3
|
-
export declare const apiContracts: {
|
|
4
|
-
version: 1;
|
|
5
|
-
protocols?: Record<string, string> | undefined;
|
|
6
|
-
schemas?: Record<string, boolean | object> | undefined;
|
|
7
|
-
http: {
|
|
8
|
-
id: string;
|
|
9
|
-
scope: "global" | "session" | "workspace";
|
|
10
|
-
basePath?: string | undefined;
|
|
11
|
-
path: string;
|
|
12
|
-
method: "DELETE" | "GET" | "HEAD" | "OPTIONS" | "PATCH" | "POST" | "PUT";
|
|
13
|
-
description: string;
|
|
14
|
-
availability?: string | undefined;
|
|
15
|
-
authentication: "device" | "none" | "owner";
|
|
16
|
-
parameters?: {
|
|
17
|
-
name: string;
|
|
18
|
-
in: "header" | "path" | "query";
|
|
19
|
-
required: boolean;
|
|
20
|
-
schema: boolean | object;
|
|
21
|
-
}[] | undefined;
|
|
22
|
-
body?: {
|
|
23
|
-
contentType: string;
|
|
24
|
-
contentTypes?: string[] | undefined;
|
|
25
|
-
required: boolean;
|
|
26
|
-
schema: boolean | object;
|
|
27
|
-
} | undefined;
|
|
28
|
-
responses: Record<string, {
|
|
29
|
-
description: string;
|
|
30
|
-
contentType?: string | undefined;
|
|
31
|
-
schema?: boolean | object | undefined;
|
|
32
|
-
events?: Record<string, boolean | object> | undefined;
|
|
33
|
-
}>;
|
|
34
|
-
}[];
|
|
35
|
-
sockets: {
|
|
36
|
-
id: string;
|
|
37
|
-
scope: "global" | "session" | "workspace";
|
|
38
|
-
description: string;
|
|
39
|
-
availability?: string | undefined;
|
|
40
|
-
service: string;
|
|
41
|
-
member: string;
|
|
42
|
-
direction: "client-to-server" | "server-to-client";
|
|
43
|
-
kind: "channel" | "method" | "state";
|
|
44
|
-
input: boolean | object;
|
|
45
|
-
output?: boolean | object | undefined;
|
|
46
|
-
errors?: boolean | object | undefined;
|
|
47
|
-
}[];
|
|
48
|
-
dynamic: string[];
|
|
49
|
-
gaps?: string[] | undefined;
|
|
50
|
-
};
|
|
51
|
-
//#endregion
|
|
52
|
-
export { apiContracts as default };
|
|
53
|
-
//# sourceMappingURL=apiContracts.d.mts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"apiContracts.d.mts","names":[],"sources":["../src/schemas/apiContracts.ts"],"mappings":";;qBAGa"}
|
package/dist/apiContracts.mjs
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { defineApiContract } from "@agimon-ai/po-core/apiContracts";
|
|
2
|
-
//#region src/schemas/apiContracts.ts
|
|
3
|
-
/** This facet contributes agent tools, commands or lifecycle only, with no separate HTTP or socket surface. */
|
|
4
|
-
const apiContracts = defineApiContract({
|
|
5
|
-
version: 1,
|
|
6
|
-
http: [],
|
|
7
|
-
sockets: [],
|
|
8
|
-
dynamic: []
|
|
9
|
-
});
|
|
10
|
-
//#endregion
|
|
11
|
-
export { apiContracts, apiContracts as default };
|
|
12
|
-
|
|
13
|
-
//# sourceMappingURL=apiContracts.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"apiContracts.mjs","names":[],"sources":["../src/schemas/apiContracts.ts"],"sourcesContent":["import { defineApiContract } from '@agimon-ai/po-core/apiContracts';\n\n/** This facet contributes agent tools, commands or lifecycle only, with no separate HTTP or socket surface. */\nexport const apiContracts = defineApiContract({ version: 1, http: [], sockets: [], dynamic: [] });\nexport default apiContracts;\n"],"mappings":";;;AAGA,MAAa,eAAe,kBAAkB;CAAE,SAAS;CAAG,MAAM,CAAC;CAAG,SAAS,CAAC;CAAG,SAAS,CAAC;AAAE,CAAC"}
|