@promptbook/cli 0.112.0-69 → 0.112.0-71
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/esm/index.es.js +4764 -3735
- package/esm/index.es.js.map +1 -1
- package/esm/scripts/run-agent-messages/main/listLocalAgentRunnerProjects.d.ts +11 -0
- package/esm/scripts/run-agent-messages/main/loadAgentMessageQueueSnapshot.d.ts +25 -0
- package/esm/scripts/run-agent-messages/main/pullLatestChangesForAgentQueueIfEnabled.d.ts +1 -1
- package/esm/scripts/run-agent-messages/main/runAgentMessages.d.ts +3 -1
- package/esm/scripts/run-agent-messages/main/runMultipleAgentMessages.d.ts +7 -0
- package/esm/scripts/run-agent-messages/main/shouldRunPeriodicTask.d.ts +7 -0
- package/esm/scripts/run-agent-messages/main/synchronizeGithubAgentRunnerRepositories.d.ts +27 -0
- package/esm/scripts/run-agent-messages/main/tickAgentMessages.d.ts +3 -1
- package/esm/scripts/run-agent-messages/main/validateAgentWatchOptions.d.ts +5 -0
- package/esm/scripts/run-agent-messages/main/withCurrentWorkingDirectory.d.ts +4 -0
- package/esm/scripts/run-agent-messages/ui/buildAgentRunInitialsVisual.d.ts +1 -1
- package/esm/scripts/run-agent-messages/ui/initializeAgentRunUi.d.ts +15 -0
- package/esm/scripts/run-agent-messages/ui/loadAgentRunUiMetadata.d.ts +4 -0
- package/esm/scripts/run-codex-prompts/git/agentGitIdentity.d.ts +4 -0
- package/esm/src/avatars/types/AvatarVisualDefinition.d.ts +1 -1
- package/esm/src/avatars/visuals/avatar3dProjectionShared.d.ts +141 -0
- package/esm/src/avatars/visuals/octopus3dAvatarVisual.d.ts +7 -0
- package/esm/src/cli/cli-commands/agent/agentProjectPaths.d.ts +2 -2
- package/esm/src/cli/cli-commands/agent/initializeAgentRunnerCommand.d.ts +22 -0
- package/esm/src/cli/cli-commands/agent/runMultiple.d.ts +10 -0
- package/esm/src/cli/cli-commands/agent.d.ts +3 -2
- package/esm/src/cli/other/install.test.d.ts +1 -0
- package/esm/src/commitments/USE_TIMEOUT/USE_TIMEOUT.d.ts +1 -1
- package/esm/src/commitments/WALLET/WALLET.d.ts +1 -1
- package/esm/src/version.d.ts +1 -1
- package/package.json +1 -1
- package/umd/index.umd.js +4769 -3740
- package/umd/index.umd.js.map +1 -1
- package/umd/scripts/run-agent-messages/main/listLocalAgentRunnerProjects.d.ts +11 -0
- package/umd/scripts/run-agent-messages/main/loadAgentMessageQueueSnapshot.d.ts +25 -0
- package/umd/scripts/run-agent-messages/main/pullLatestChangesForAgentQueueIfEnabled.d.ts +1 -1
- package/umd/scripts/run-agent-messages/main/runAgentMessages.d.ts +3 -1
- package/umd/scripts/run-agent-messages/main/runMultipleAgentMessages.d.ts +7 -0
- package/umd/scripts/run-agent-messages/main/shouldRunPeriodicTask.d.ts +7 -0
- package/umd/scripts/run-agent-messages/main/synchronizeGithubAgentRunnerRepositories.d.ts +27 -0
- package/umd/scripts/run-agent-messages/main/tickAgentMessages.d.ts +3 -1
- package/umd/scripts/run-agent-messages/main/validateAgentWatchOptions.d.ts +5 -0
- package/umd/scripts/run-agent-messages/main/withCurrentWorkingDirectory.d.ts +4 -0
- package/umd/scripts/run-agent-messages/ui/buildAgentRunInitialsVisual.d.ts +1 -1
- package/umd/scripts/run-agent-messages/ui/initializeAgentRunUi.d.ts +15 -0
- package/umd/scripts/run-agent-messages/ui/loadAgentRunUiMetadata.d.ts +4 -0
- package/umd/scripts/run-codex-prompts/git/agentGitIdentity.d.ts +4 -0
- package/umd/src/avatars/types/AvatarVisualDefinition.d.ts +1 -1
- package/umd/src/avatars/visuals/avatar3dProjectionShared.d.ts +141 -0
- package/umd/src/avatars/visuals/octopus3dAvatarVisual.d.ts +7 -0
- package/umd/src/cli/cli-commands/agent/agentProjectPaths.d.ts +2 -2
- package/umd/src/cli/cli-commands/agent/initializeAgentRunnerCommand.d.ts +22 -0
- package/umd/src/cli/cli-commands/agent/runMultiple.d.ts +10 -0
- package/umd/src/cli/cli-commands/agent.d.ts +3 -2
- package/umd/src/cli/other/install.test.d.ts +1 -0
- package/umd/src/commitments/USE_TIMEOUT/USE_TIMEOUT.d.ts +1 -1
- package/umd/src/commitments/WALLET/WALLET.d.ts +1 -1
- package/umd/src/version.d.ts +1 -1
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* One local direct-child repository that looks like a Promptbook agent runner project.
|
|
3
|
+
*/
|
|
4
|
+
export type LocalAgentRunnerProject = {
|
|
5
|
+
readonly directoryName: string;
|
|
6
|
+
readonly projectPath: string;
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Lists local agent runner repositories from direct child directories of the given root.
|
|
10
|
+
*/
|
|
11
|
+
export declare function listLocalAgentRunnerProjects(rootPath: string): Promise<ReadonlyArray<LocalAgentRunnerProject>>;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import type { AgentMessageFile } from '../messages/AgentMessageFile';
|
|
2
|
+
/**
|
|
3
|
+
* Queue counts and files used to render the agent-run dashboard.
|
|
4
|
+
*/
|
|
5
|
+
export type AgentMessageQueueSnapshot = {
|
|
6
|
+
readonly queuedMessages: ReadonlyArray<AgentMessageFile>;
|
|
7
|
+
readonly finishedMessageCount: number;
|
|
8
|
+
};
|
|
9
|
+
/**
|
|
10
|
+
* Reads current queued and finished message counts for the agent dashboard.
|
|
11
|
+
*/
|
|
12
|
+
export declare function loadAgentMessageQueueSnapshot(projectPath: string): Promise<AgentMessageQueueSnapshot>;
|
|
13
|
+
/**
|
|
14
|
+
* Converts agent queue counts into the prompt-style snapshot used by the shared rich UI state.
|
|
15
|
+
*/
|
|
16
|
+
export declare function createAgentQueueProgressSnapshot(queueSnapshot: AgentMessageQueueSnapshot): {
|
|
17
|
+
done: number;
|
|
18
|
+
forAgent: number;
|
|
19
|
+
belowMinimumPriority: number;
|
|
20
|
+
toBeWritten: number;
|
|
21
|
+
};
|
|
22
|
+
/**
|
|
23
|
+
* Returns the normalized queued-messages path shown in the UI.
|
|
24
|
+
*/
|
|
25
|
+
export declare function getQueuedAgentMessagesDirectoryLabel(): string;
|
|
@@ -5,5 +5,5 @@ import type { AgentRunOptions } from '../AgentRunOptions';
|
|
|
5
5
|
export declare function pullLatestChangesForAgentQueueIfEnabled(options: {
|
|
6
6
|
readonly projectPath: string;
|
|
7
7
|
readonly runOptions: AgentRunOptions;
|
|
8
|
-
readonly logMessage
|
|
8
|
+
readonly logMessage?: string;
|
|
9
9
|
}): Promise<number | undefined>;
|
|
@@ -2,4 +2,6 @@ import type { AgentRunOptions } from '../AgentRunOptions';
|
|
|
2
2
|
/**
|
|
3
3
|
* Watches the queued message directory and answers messages one by one.
|
|
4
4
|
*/
|
|
5
|
-
export declare function runAgentMessages(options: AgentRunOptions
|
|
5
|
+
export declare function runAgentMessages(options: AgentRunOptions, controls?: {
|
|
6
|
+
readonly shouldContinue?: () => boolean;
|
|
7
|
+
}): Promise<void>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { AgentRunOptions } from '../AgentRunOptions';
|
|
2
|
+
/**
|
|
3
|
+
* Watches all direct child agent repositories from the current directory in one shared session.
|
|
4
|
+
*/
|
|
5
|
+
export declare function runMultipleAgentMessages(options: AgentRunOptions, controls?: {
|
|
6
|
+
readonly shouldContinue?: () => boolean;
|
|
7
|
+
}): Promise<void>;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Environment variable carrying the GitHub token used to discover and clone agent repositories.
|
|
3
|
+
*/
|
|
4
|
+
export declare const PROMPTBOOK_AGENT_RUNNER_GITHUB_TOKEN_ENV = "PROMPTBOOK_AGENT_RUNNER_GITHUB_TOKEN";
|
|
5
|
+
/**
|
|
6
|
+
* Environment variable carrying the GitHub owner whose `agent-*` repositories should be mirrored locally.
|
|
7
|
+
*/
|
|
8
|
+
export declare const PROMPTBOOK_AGENT_RUNNER_GITHUB_OWNER_ENV = "PROMPTBOOK_AGENT_RUNNER_GITHUB_OWNER";
|
|
9
|
+
/**
|
|
10
|
+
* Result of one GitHub synchronization round.
|
|
11
|
+
*/
|
|
12
|
+
export type GithubAgentRunnerRepositoriesSynchronizationResult = {
|
|
13
|
+
readonly clonedRepositoryNames: ReadonlyArray<string>;
|
|
14
|
+
readonly owner?: string;
|
|
15
|
+
readonly synchronizedAt?: number;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Loads the optional GitHub repository-mirroring configuration for multi-agent runs.
|
|
19
|
+
*/
|
|
20
|
+
export declare function loadAgentRunnerGithubConfiguration(): {
|
|
21
|
+
readonly token: string;
|
|
22
|
+
readonly owner: string;
|
|
23
|
+
} | null;
|
|
24
|
+
/**
|
|
25
|
+
* Clones missing `agent-*` repositories from the configured GitHub owner into the direct child directories of `rootPath`.
|
|
26
|
+
*/
|
|
27
|
+
export declare function synchronizeGithubAgentRunnerRepositories(rootPath: string): Promise<GithubAgentRunnerRepositoriesSynchronizationResult>;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
+
import { type CoderRunUiHandle } from '../../run-codex-prompts/ui/renderCoderRunUi';
|
|
1
2
|
import type { AgentRunOptions } from '../AgentRunOptions';
|
|
2
3
|
import type { AgentMessageFile } from '../messages/AgentMessageFile';
|
|
3
4
|
import { type FinishedAgentMessageFile } from '../messages/moveAgentMessageToFinished';
|
|
4
5
|
/**
|
|
5
|
-
* Result of one `ptbk agent
|
|
6
|
+
* Result of one `ptbk agent run-once` invocation.
|
|
6
7
|
*/
|
|
7
8
|
export type AgentTickResult = {
|
|
8
9
|
readonly isMessageProcessed: boolean;
|
|
@@ -15,6 +16,7 @@ export type AgentTickResult = {
|
|
|
15
16
|
*/
|
|
16
17
|
export type TickAgentMessagesOptions = {
|
|
17
18
|
readonly isQuietWhenIdle?: boolean;
|
|
19
|
+
readonly uiHandle?: CoderRunUiHandle;
|
|
18
20
|
};
|
|
19
21
|
/**
|
|
20
22
|
* Answers one queued `.book` message thread and moves it to `messages/finished`.
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { AgentRunOptions } from '../AgentRunOptions';
|
|
2
|
+
import { type AgentMessageQueueSnapshot } from '../main/loadAgentMessageQueueSnapshot';
|
|
3
|
+
import { type CoderRunUiHandle } from '../../run-codex-prompts/ui/renderCoderRunUi';
|
|
4
|
+
/**
|
|
5
|
+
* Creates and seeds the persistent rich terminal UI used by `ptbk agent run`.
|
|
6
|
+
*/
|
|
7
|
+
export declare function initializeAgentRunUi(projectPath: string, options: AgentRunOptions, queueSnapshot: AgentMessageQueueSnapshot): Promise<CoderRunUiHandle | undefined>;
|
|
8
|
+
/**
|
|
9
|
+
* Updates the persistent rich UI to the idle watch state.
|
|
10
|
+
*/
|
|
11
|
+
export declare function updateAgentRunUiForWatching(uiHandle: CoderRunUiHandle, queueSnapshot: AgentMessageQueueSnapshot, statusMessage?: string): void;
|
|
12
|
+
/**
|
|
13
|
+
* Updates the persistent rich UI while the runner refreshes the queue repository.
|
|
14
|
+
*/
|
|
15
|
+
export declare function updateAgentRunUiForPulling(uiHandle: CoderRunUiHandle, queueSnapshot: AgentMessageQueueSnapshot, statusMessage: string): void;
|
|
@@ -10,6 +10,10 @@ export type AgentRunUiMetadata = {
|
|
|
10
10
|
* Reads the local agent title and latest queued user message for the rich agent dashboard.
|
|
11
11
|
*/
|
|
12
12
|
export declare function loadAgentRunUiMetadata(projectPath: string, queuedMessage: AgentMessageFile): Promise<AgentRunUiMetadata>;
|
|
13
|
+
/**
|
|
14
|
+
* Reads the local `agent.book` title and falls back to a stable generic name when unavailable.
|
|
15
|
+
*/
|
|
16
|
+
export declare function readLocalAgentName(projectPath: string): Promise<string>;
|
|
13
17
|
/**
|
|
14
18
|
* Extracts the latest `MESSAGE @User` block while preserving the original line breaks.
|
|
15
19
|
*/
|
|
@@ -25,3 +25,7 @@ export declare function buildAgentGitSigningFlag(identity?: AgentGitIdentity | u
|
|
|
25
25
|
* Prints a one-time style tip when coding-agent commits fall back to the user's default Git configuration.
|
|
26
26
|
*/
|
|
27
27
|
export declare function printAgentGitIdentityTipIfNeeded(): void;
|
|
28
|
+
/**
|
|
29
|
+
* Defers the coding-agent Git identity tip until process shutdown so long-running UIs stay uninterrupted.
|
|
30
|
+
*/
|
|
31
|
+
export declare function printAgentGitIdentityTipAtProcessExitIfNeeded(): void;
|
|
@@ -7,7 +7,7 @@ import type { AvatarDefinition } from './AvatarDefinition';
|
|
|
7
7
|
*
|
|
8
8
|
* @private shared contract for the avatar rendering system
|
|
9
9
|
*/
|
|
10
|
-
export type AvatarVisualId = 'pixel-art' | 'octopus' | 'octopus2' | 'octopus3' | 'ascii-octopus' | 'minecraft' | 'minecraft2' | 'fractal' | 'orb';
|
|
10
|
+
export type AvatarVisualId = 'pixel-art' | 'octopus' | 'octopus2' | 'octopus3' | 'octopus3d' | 'ascii-octopus' | 'minecraft' | 'minecraft2' | 'fractal' | 'orb';
|
|
11
11
|
/**
|
|
12
12
|
* Derived color palette used by avatar visuals.
|
|
13
13
|
*
|
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* One 3D point used by the shared avatar projection helpers.
|
|
3
|
+
*
|
|
4
|
+
* @private helper of the 3D avatar visuals
|
|
5
|
+
*/
|
|
6
|
+
export type Point3D = {
|
|
7
|
+
readonly x: number;
|
|
8
|
+
readonly y: number;
|
|
9
|
+
readonly z: number;
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* One projected 2D point derived from scene-space 3D coordinates.
|
|
13
|
+
*
|
|
14
|
+
* @private helper of the 3D avatar visuals
|
|
15
|
+
*/
|
|
16
|
+
export type ProjectedPoint = {
|
|
17
|
+
readonly x: number;
|
|
18
|
+
readonly y: number;
|
|
19
|
+
readonly z: number;
|
|
20
|
+
};
|
|
21
|
+
/**
|
|
22
|
+
* Default camera distance ratio shared by the proper-3D avatar visuals.
|
|
23
|
+
*
|
|
24
|
+
* @private helper of the 3D avatar visuals
|
|
25
|
+
*/
|
|
26
|
+
export declare const DEFAULT_3D_CAMERA_DISTANCE_RATIO = 1.4;
|
|
27
|
+
/**
|
|
28
|
+
* Clamps one number into the provided range.
|
|
29
|
+
*
|
|
30
|
+
* @param value Input value.
|
|
31
|
+
* @param minimumValue Inclusive lower bound.
|
|
32
|
+
* @param maximumValue Inclusive upper bound.
|
|
33
|
+
* @returns Clamped value.
|
|
34
|
+
*
|
|
35
|
+
* @private helper of the 3D avatar visuals
|
|
36
|
+
*/
|
|
37
|
+
export declare function clampNumber(value: number, minimumValue: number, maximumValue: number): number;
|
|
38
|
+
/**
|
|
39
|
+
* Rotates one point around the local Y axis.
|
|
40
|
+
*
|
|
41
|
+
* @param point Source point.
|
|
42
|
+
* @param angle Rotation angle in radians.
|
|
43
|
+
* @returns Rotated point.
|
|
44
|
+
*
|
|
45
|
+
* @private helper of the 3D avatar visuals
|
|
46
|
+
*/
|
|
47
|
+
export declare function rotatePointAroundY(point: Point3D, angle: number): Point3D;
|
|
48
|
+
/**
|
|
49
|
+
* Rotates one point around the local X axis.
|
|
50
|
+
*
|
|
51
|
+
* @param point Source point.
|
|
52
|
+
* @param angle Rotation angle in radians.
|
|
53
|
+
* @returns Rotated point.
|
|
54
|
+
*
|
|
55
|
+
* @private helper of the 3D avatar visuals
|
|
56
|
+
*/
|
|
57
|
+
export declare function rotatePointAroundX(point: Point3D, angle: number): Point3D;
|
|
58
|
+
/**
|
|
59
|
+
* Applies the local rotations and translation to one scene point.
|
|
60
|
+
*
|
|
61
|
+
* @param localPoint Point in local object space.
|
|
62
|
+
* @param center Object center in scene space.
|
|
63
|
+
* @param rotationX Object pitch in radians.
|
|
64
|
+
* @param rotationY Object yaw in radians.
|
|
65
|
+
* @returns Transformed scene-space point.
|
|
66
|
+
*
|
|
67
|
+
* @private helper of the 3D avatar visuals
|
|
68
|
+
*/
|
|
69
|
+
export declare function transformScenePoint(localPoint: Point3D, center: Point3D, rotationX: number, rotationY: number): Point3D;
|
|
70
|
+
/**
|
|
71
|
+
* Projects one scene point into canvas coordinates.
|
|
72
|
+
*
|
|
73
|
+
* @param point Scene-space point.
|
|
74
|
+
* @param size Canvas size in CSS pixels.
|
|
75
|
+
* @param sceneCenterX Horizontal scene center.
|
|
76
|
+
* @param sceneCenterY Vertical scene center.
|
|
77
|
+
* @param cameraDistanceRatio Optional camera distance ratio.
|
|
78
|
+
* @returns Projected point.
|
|
79
|
+
*
|
|
80
|
+
* @private helper of the 3D avatar visuals
|
|
81
|
+
*/
|
|
82
|
+
export declare function projectScenePoint(point: Point3D, size: number, sceneCenterX: number, sceneCenterY: number, cameraDistanceRatio?: number): ProjectedPoint;
|
|
83
|
+
/**
|
|
84
|
+
* Interpolates between two projected points.
|
|
85
|
+
*
|
|
86
|
+
* @param startPoint Start point.
|
|
87
|
+
* @param endPoint End point.
|
|
88
|
+
* @param ratio Interpolation ratio in the range `[0, 1]`.
|
|
89
|
+
* @returns Interpolated projected point.
|
|
90
|
+
*
|
|
91
|
+
* @private helper of the 3D avatar visuals
|
|
92
|
+
*/
|
|
93
|
+
export declare function interpolateProjectedPoint(startPoint: ProjectedPoint, endPoint: ProjectedPoint, ratio: number): ProjectedPoint;
|
|
94
|
+
/**
|
|
95
|
+
* Subtracts one 3D point from another.
|
|
96
|
+
*
|
|
97
|
+
* @param leftPoint Left point.
|
|
98
|
+
* @param rightPoint Right point.
|
|
99
|
+
* @returns Difference vector.
|
|
100
|
+
*
|
|
101
|
+
* @private helper of the 3D avatar visuals
|
|
102
|
+
*/
|
|
103
|
+
export declare function subtractPoint3D(leftPoint: Point3D, rightPoint: Point3D): Point3D;
|
|
104
|
+
/**
|
|
105
|
+
* Computes the 3D cross product of two vectors.
|
|
106
|
+
*
|
|
107
|
+
* @param leftVector Left vector.
|
|
108
|
+
* @param rightVector Right vector.
|
|
109
|
+
* @returns Cross product.
|
|
110
|
+
*
|
|
111
|
+
* @private helper of the 3D avatar visuals
|
|
112
|
+
*/
|
|
113
|
+
export declare function crossProduct3D(leftVector: Point3D, rightVector: Point3D): Point3D;
|
|
114
|
+
/**
|
|
115
|
+
* Computes the 3D dot product of two vectors.
|
|
116
|
+
*
|
|
117
|
+
* @param leftVector Left vector.
|
|
118
|
+
* @param rightVector Right vector.
|
|
119
|
+
* @returns Dot product.
|
|
120
|
+
*
|
|
121
|
+
* @private helper of the 3D avatar visuals
|
|
122
|
+
*/
|
|
123
|
+
export declare function dotProduct3D(leftVector: Point3D, rightVector: Point3D): number;
|
|
124
|
+
/**
|
|
125
|
+
* Normalizes one 3D vector while keeping zero vectors stable.
|
|
126
|
+
*
|
|
127
|
+
* @param vector Source vector.
|
|
128
|
+
* @returns Normalized vector.
|
|
129
|
+
*
|
|
130
|
+
* @private helper of the 3D avatar visuals
|
|
131
|
+
*/
|
|
132
|
+
export declare function normalizeVector3(vector: Point3D): Point3D;
|
|
133
|
+
/**
|
|
134
|
+
* Measures the perimeter of one projected quad.
|
|
135
|
+
*
|
|
136
|
+
* @param corners Quad corners.
|
|
137
|
+
* @returns Perimeter length.
|
|
138
|
+
*
|
|
139
|
+
* @private helper of the 3D avatar visuals
|
|
140
|
+
*/
|
|
141
|
+
export declare function getProjectedQuadPerimeter(corners: readonly [ProjectedPoint, ProjectedPoint, ProjectedPoint, ProjectedPoint]): number;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { AvatarVisualDefinition } from '../types/AvatarVisualDefinition';
|
|
2
|
+
/**
|
|
3
|
+
* Proper 3D Octopus visual built from projected organic meshes and tentacles.
|
|
4
|
+
*
|
|
5
|
+
* @private built-in avatar visual
|
|
6
|
+
*/
|
|
7
|
+
export declare const octopus3dAvatarVisual: AvatarVisualDefinition;
|
|
@@ -11,13 +11,13 @@ export declare const AGENT_BOOK_FILE_PATH = "agent.book";
|
|
|
11
11
|
*/
|
|
12
12
|
export declare const AGENT_MESSAGES_DIRECTORY_PATH = "messages";
|
|
13
13
|
/**
|
|
14
|
-
* Relative path to queued user messages consumed by `ptbk agent
|
|
14
|
+
* Relative path to queued user messages consumed by `ptbk agent run-once`.
|
|
15
15
|
*
|
|
16
16
|
* @private internal utility of `ptbk agent`
|
|
17
17
|
*/
|
|
18
18
|
export declare const AGENT_QUEUED_MESSAGES_DIRECTORY_PATH: string;
|
|
19
19
|
/**
|
|
20
|
-
* Relative path to answered messages written by `ptbk agent
|
|
20
|
+
* Relative path to answered messages written by `ptbk agent run-once`.
|
|
21
21
|
*
|
|
22
22
|
* @private internal utility of `ptbk agent`
|
|
23
23
|
*/
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { Command as Program } from 'commander';
|
|
2
|
+
import type { $side_effect } from '../../../utils/organization/$side_effect';
|
|
3
|
+
import { createAgentRunOptionsFromCliOptions } from './agentRunCliOptions';
|
|
4
|
+
/**
|
|
5
|
+
* Shared command-registration options for `ptbk agent` runner subcommands.
|
|
6
|
+
*
|
|
7
|
+
* @private internal utility of `ptbk agent`
|
|
8
|
+
*/
|
|
9
|
+
type InitializeAgentRunnerCommandOptions = {
|
|
10
|
+
readonly commandName: string;
|
|
11
|
+
readonly aliases?: ReadonlyArray<string>;
|
|
12
|
+
readonly summary: string;
|
|
13
|
+
readonly featureLines: ReadonlyArray<string>;
|
|
14
|
+
readonly loadExecutor: () => Promise<(runOptions: ReturnType<typeof createAgentRunOptionsFromCliOptions>) => Promise<unknown>>;
|
|
15
|
+
};
|
|
16
|
+
/**
|
|
17
|
+
* Registers one runner-backed `ptbk agent` subcommand with the shared option and error handling flow.
|
|
18
|
+
*
|
|
19
|
+
* @private internal utility of `ptbk agent`
|
|
20
|
+
*/
|
|
21
|
+
export declare function $initializeAgentRunnerCommand(program: Program, options: InitializeAgentRunnerCommandOptions): $side_effect;
|
|
22
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { Command as Program } from 'commander';
|
|
2
|
+
import type { $side_effect } from '../../../utils/organization/$side_effect';
|
|
3
|
+
/**
|
|
4
|
+
* Initializes `agent run-multiple` command for Promptbook CLI utilities.
|
|
5
|
+
*
|
|
6
|
+
* Note: `$` is used to indicate that this function is not a pure function - it registers a command in the CLI.
|
|
7
|
+
*
|
|
8
|
+
* @private internal function of `promptbookCli`
|
|
9
|
+
*/
|
|
10
|
+
export declare function $initializeAgentRunMultipleCommand(program: Program): $side_effect;
|
|
@@ -5,8 +5,9 @@ import type { $side_effect } from '../../utils/organization/$side_effect';
|
|
|
5
5
|
*
|
|
6
6
|
* The agent command provides utilities for repository-backed message queues:
|
|
7
7
|
* - init: Initialize local agent queue and instruction files
|
|
8
|
-
* - tick: Answer one queued message and exit
|
|
9
|
-
* - run: Watch
|
|
8
|
+
* - run-once (alias: tick): Answer one queued message and exit
|
|
9
|
+
* - run-agent (alias: run): Watch one queue and answer messages one by one
|
|
10
|
+
* - run-multiple: Watch direct child agent repositories in one shared session
|
|
10
11
|
*
|
|
11
12
|
* Note: `$` is used to indicate that this function is not a pure function - it registers a command in the CLI.
|
|
12
13
|
*
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -3,7 +3,7 @@ import type { ToolFunction } from '../../scripting/javascript/JavascriptExecutio
|
|
|
3
3
|
import type { string_javascript_name } from '../../types/string_person_fullname';
|
|
4
4
|
import { BaseCommitmentDefinition } from '../_base/BaseCommitmentDefinition';
|
|
5
5
|
export { setTimeoutToolRuntimeAdapter } from './setTimeoutToolRuntimeAdapter';
|
|
6
|
-
export type { CancelTimeoutToolResult, ListTimeoutsToolResult, SetTimeoutToolResult, TimeoutToolListItem, TimeoutToolRuntimeAdapter, TimeoutToolRuntimeContext, UpdateTimeoutToolResult } from './TimeoutToolRuntimeAdapter';
|
|
6
|
+
export type { CancelTimeoutToolResult, ListTimeoutsToolResult, SetTimeoutToolResult, TimeoutToolListItem, TimeoutToolRuntimeAdapter, TimeoutToolRuntimeContext, UpdateTimeoutToolResult, } from './TimeoutToolRuntimeAdapter';
|
|
7
7
|
/**
|
|
8
8
|
* `USE TIMEOUT` commitment definition.
|
|
9
9
|
*
|
|
@@ -3,7 +3,7 @@ import type { ToolFunction } from '../../scripting/javascript/JavascriptExecutio
|
|
|
3
3
|
import type { string_javascript_name } from '../../types/string_person_fullname';
|
|
4
4
|
import { BaseCommitmentDefinition } from '../_base/BaseCommitmentDefinition';
|
|
5
5
|
export { setWalletToolRuntimeAdapter } from './setWalletToolRuntimeAdapter';
|
|
6
|
-
export type { WalletRecordType, WalletToolRecord, WalletToolRuntimeAdapter, WalletToolRuntimeContext } from './WalletToolRuntimeAdapter';
|
|
6
|
+
export type { WalletRecordType, WalletToolRecord, WalletToolRuntimeAdapter, WalletToolRuntimeContext, } from './WalletToolRuntimeAdapter';
|
|
7
7
|
/**
|
|
8
8
|
* WALLET commitment definition.
|
|
9
9
|
*
|
package/esm/src/version.d.ts
CHANGED
|
@@ -15,7 +15,7 @@ export declare const BOOK_LANGUAGE_VERSION: string_semantic_version;
|
|
|
15
15
|
export declare const PROMPTBOOK_ENGINE_VERSION: string_promptbook_version;
|
|
16
16
|
/**
|
|
17
17
|
* Represents the version string of the Promptbook engine.
|
|
18
|
-
* It follows semantic versioning (e.g., `0.112.0-
|
|
18
|
+
* It follows semantic versioning (e.g., `0.112.0-70`).
|
|
19
19
|
*
|
|
20
20
|
* @generated
|
|
21
21
|
*/
|
package/package.json
CHANGED