@hachej/boring-agent 0.1.103 → 0.1.105
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/dist/{chunk-7QM22DU7.js → chunk-6DRHERVK.js} +7 -5
- package/dist/{chunk-TW7G33QH.js → chunk-F2OJI2LX.js} +64 -15
- package/dist/{chunk-6WKQ4FC4.js → chunk-LFN45QDZ.js} +259 -140
- package/dist/core/index.d.ts +5 -5
- package/dist/{createHarness-4Q6DQBRT.js → createHarness-GMBZZPTN.js} +1 -1
- package/dist/{errors-szpcDUFQ.d.ts → errors-DH7C01Pm.d.ts} +1 -1
- package/dist/{file-search-BXdSm-Yq.d.ts → file-search-qcD5zItr.d.ts} +3 -3
- package/dist/front/index.d.ts +12 -2
- package/dist/front/index.js +200 -135
- package/dist/front/styles.css +56 -15
- package/dist/{harness-erpL2SER.d.ts → harness-Dcd08yKr.d.ts} +1 -1
- package/dist/{lease-K-EZhdL-.d.ts → lease-DffrPrQn.d.ts} +1 -1
- package/dist/{piChatEvent-g1nIBh44.d.ts → piChatEvent-iNSXiFQq.d.ts} +5 -0
- package/dist/{piChatSessionService-DugeRHzb.d.ts → piChatSessionService-DQSQ_kWZ.d.ts} +1 -1
- package/dist/server/agent-host/testing/gatewayConformance.d.ts +5 -5
- package/dist/server/agent-host/testing/gatewayConformance.js +1 -1
- package/dist/server/index.d.ts +53 -42
- package/dist/server/index.js +5 -3
- package/dist/server/worker/index.js +3 -3
- package/dist/shared/index.d.ts +93 -19
- package/dist/shared/index.js +1 -1
- package/dist/{types-BnjMLAd5.d.ts → types-BTsdaAQ2.d.ts} +33 -14
- package/docs/ERROR_CODES.md +1 -1
- package/package.json +6 -6
package/dist/shared/index.d.ts
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { s as AgentTool } from '../harness-
|
|
2
|
-
export { c as AGENT_NOT_IMPLEMENTED_UNTIL_T1, b as Agent, d as AgentActor, e as AgentCoreHarness, f as AgentCoreHarnessFactory, g as AgentCorePromptInput, h as AgentCoreSessionAdapter, i as AgentCoreSessionSnapshot, j as AgentEvent, A as AgentHarness, k as AgentMessageContent, l as AgentMessagePart, m as AgentNotImplementedError, a as AgentReadiness, n as AgentReadinessStatus, o as AgentResolveInputResponse, t as AgentRuntimeAdapter, p as AgentSendInput, q as AgentStartReceipt, r as AgentStreamOptions, u as CoreAgentConfig, J as JSONSchema, M as MessageAttachment, R as RunContext, S as SendMessageInput, T as TelemetryEvent, v as TelemetrySink, w as ToolExecContext, x as ToolResult, y as noopTelemetry, z as safeCapture, B as sessionStreamPath } from '../harness-
|
|
3
|
-
import { F as FileSearch } from '../file-search-
|
|
4
|
-
export { A as AGENT_KNOWLEDGE_FILESYSTEM_ID, a as AGENT_RESOURCES_FILESYSTEM_ID, b as AgentSkillResource, L as LeaseBoundWorkspaceAgent, W as WorkspaceAgentDirectRunCallback, c as WorkspaceAgentDirectRunInput, d as WorkspaceAgentDispatch, e as WorkspaceAgentDispatcher, f as WorkspaceAgentDispatcherContext, g as WorkspaceAgentDispatcherDispatchInput, h as WorkspaceAgentDispatcherSendInput, i as WorkspaceAgentGatewayBinding } from '../file-search-
|
|
1
|
+
import { s as AgentTool } from '../harness-Dcd08yKr.js';
|
|
2
|
+
export { c as AGENT_NOT_IMPLEMENTED_UNTIL_T1, b as Agent, d as AgentActor, e as AgentCoreHarness, f as AgentCoreHarnessFactory, g as AgentCorePromptInput, h as AgentCoreSessionAdapter, i as AgentCoreSessionSnapshot, j as AgentEvent, A as AgentHarness, k as AgentMessageContent, l as AgentMessagePart, m as AgentNotImplementedError, a as AgentReadiness, n as AgentReadinessStatus, o as AgentResolveInputResponse, t as AgentRuntimeAdapter, p as AgentSendInput, q as AgentStartReceipt, r as AgentStreamOptions, u as CoreAgentConfig, J as JSONSchema, M as MessageAttachment, R as RunContext, S as SendMessageInput, T as TelemetryEvent, v as TelemetrySink, w as ToolExecContext, x as ToolResult, y as noopTelemetry, z as safeCapture, B as sessionStreamPath } from '../harness-Dcd08yKr.js';
|
|
3
|
+
import { F as FileSearch } from '../file-search-qcD5zItr.js';
|
|
4
|
+
export { A as AGENT_KNOWLEDGE_FILESYSTEM_ID, a as AGENT_RESOURCES_FILESYSTEM_ID, b as AgentSkillResource, L as LeaseBoundWorkspaceAgent, W as WorkspaceAgentDirectRunCallback, c as WorkspaceAgentDirectRunInput, d as WorkspaceAgentDispatch, e as WorkspaceAgentDispatcher, f as WorkspaceAgentDispatcherContext, g as WorkspaceAgentDispatcherDispatchInput, h as WorkspaceAgentDispatcherSendInput, i as WorkspaceAgentGatewayBinding } from '../file-search-qcD5zItr.js';
|
|
5
5
|
import { b as Workspace, c as Sandbox } from '../sandbox-BMhut3kh.js';
|
|
6
6
|
export { E as Entry, d as ExecOptions, a as ExecResult, I as IsolatedCodeInput, e as IsolatedCodeOutput, R as READONLY_FILESYSTEM_MUTATION_CODE, f as RUNTIME_FILESYSTEM_CAPABILITIES, g as ReadonlyFilesystemMutationError, h as RuntimeFilesystemCapability, i as SandboxCapability, S as Stat, j as WorkspaceRuntimeContext, k as WorkspaceWatchControlEvent, l as isReadonlyFilesystemMutationError } from '../sandbox-BMhut3kh.js';
|
|
7
|
-
import { B as BoringChatPart, p as ToolUiMetadata, q as AgentConsumptionErrorCode } from '../piChatEvent-
|
|
8
|
-
export { A as AgentDefinitionErrorCode, o as AgentDeploymentErrorCode, r as ApiErrorPayload, s as ApiErrorPayloadSchema, t as ApiErrorResponse, u as ApiErrorResponseSchema, v as BoringChatMessage, l as ChatAttachmentPayload, w as ChatError, C as ChatModelSelection, x as ChatSubmitPayload, h as CommandReceipt, E as ERROR_CODES, y as ErrorCode, z as ErrorLogFields, D as ErrorLogFieldsSchema, F as FollowUpPayload, f as FollowUpReceipt, I as InterruptPayload, k as InterruptReceipt, c as PiChatEvent, G as PiChatHeartbeatFrame, P as PiChatSnapshot, H as PiChatStatus, J as PiChatStreamFrame, d as PromptPayload, e as PromptReceipt, Q as QueueClearPayload, g as QueueClearReceipt, m as QueuedUserMessage, K as SAFE_NATIVE_SESSION_ID, n as SessionCtx, L as SessionDetail, a as SessionListOptions, S as SessionStore, b as SessionSummary, i as StopPayload, j as StopReceipt, T as ThinkingLevel, M as extractToolUiMetadata, N as isToolUiMetadata } from '../piChatEvent-
|
|
9
|
-
import { S as SchemaValidationError, A as AgentSchemaIssue, a as Sha256Digest, b as AgentSchemaValidationResult, C as CredentialConsumerBindingId, c as CredentialFieldId, P as ProviderCredentialRefV1, d as AuthorizedWorkspaceCredentialScopeV1 } from '../lease-
|
|
10
|
-
export { e as AgentDefinition, f as AgentDefinitionDigestAsset, g as AgentDefinitionReference, h as AgentDefinitionValidationError, i as AgentDeployment, j as AgentDeploymentValidationError, k as CompiledAgentBundle, l as CompiledAgentDefinition, m as CreateShareEntryInput, n as CredentialConsumerBindingRegistryV1, o as CredentialConsumerBindingV1, p as CredentialConsumerKindV1, q as CredentialDeliveryV1, r as CredentialFieldDefinitionV1, E as ExternalManagedAccountReferenceDefinitionV1, I as InMemoryShareEntryStore, O as OpaqueRefSchema, s as OpaqueShareLocatorIdSchema, t as PROVIDER_CREDENTIAL_REF_VERSION, u as ProviderCategoryV1, v as ProviderCredentialDefinitionV1, w as ProviderCredentialRefFactoryV1, x as ProviderDefinitionV1, y as ProviderId, z as ProviderRegistryV1, R as ResolvedCredentialLeaseV1, B as ResolvedCredentialMaterialV1, D as SandboxHandleRecord, F as SandboxHandleStore, G as Sha256DigestSchema, H as ShareEntryErrorCode, J as ShareEntryProvenance, K as ShareEntryProvenanceSchema, L as ShareEntryResolution, M as ShareEntryStore, N as ShareEntryTombstone, Q as ShareEntryV1, T as ShareEntryV1Schema, U as ShareEntryValidationError, V as VerifiedWorkspaceCredentialAuthorityV1, W as VerifiedWorkspaceCredentialPrincipalV1, X as WorkspaceCredentialAuthorityVerifierV1, Y as WorkspaceCredentialResolverV1, Z as createAgentAssetDigest, _ as createAgentDefinitionDigest, $ as createAgentDeploymentDigest, a0 as createCredentialConsumerBindingRegistryV1, a1 as createProviderCredentialRefFactoryV1, a2 as createProviderRegistryV1, a3 as providerCredentialFieldsV1, a4 as resolveShareEntry, a5 as validateAgentDefinition, a6 as validateAgentDeployment } from '../lease-
|
|
7
|
+
import { B as BoringChatPart, p as ToolUiMetadata, q as AgentConsumptionErrorCode } from '../piChatEvent-iNSXiFQq.js';
|
|
8
|
+
export { A as AgentDefinitionErrorCode, o as AgentDeploymentErrorCode, r as ApiErrorPayload, s as ApiErrorPayloadSchema, t as ApiErrorResponse, u as ApiErrorResponseSchema, v as BoringChatMessage, l as ChatAttachmentPayload, w as ChatError, C as ChatModelSelection, x as ChatSubmitPayload, h as CommandReceipt, E as ERROR_CODES, y as ErrorCode, z as ErrorLogFields, D as ErrorLogFieldsSchema, F as FollowUpPayload, f as FollowUpReceipt, I as InterruptPayload, k as InterruptReceipt, c as PiChatEvent, G as PiChatHeartbeatFrame, P as PiChatSnapshot, H as PiChatStatus, J as PiChatStreamFrame, d as PromptPayload, e as PromptReceipt, Q as QueueClearPayload, g as QueueClearReceipt, m as QueuedUserMessage, K as SAFE_NATIVE_SESSION_ID, n as SessionCtx, L as SessionDetail, a as SessionListOptions, S as SessionStore, b as SessionSummary, i as StopPayload, j as StopReceipt, T as ThinkingLevel, M as extractToolUiMetadata, N as isToolUiMetadata } from '../piChatEvent-iNSXiFQq.js';
|
|
9
|
+
import { S as SchemaValidationError, A as AgentSchemaIssue, a as Sha256Digest, b as AgentSchemaValidationResult, C as CredentialConsumerBindingId, c as CredentialFieldId, P as ProviderCredentialRefV1, d as AuthorizedWorkspaceCredentialScopeV1 } from '../lease-DffrPrQn.js';
|
|
10
|
+
export { e as AgentDefinition, f as AgentDefinitionDigestAsset, g as AgentDefinitionReference, h as AgentDefinitionValidationError, i as AgentDeployment, j as AgentDeploymentValidationError, k as CompiledAgentBundle, l as CompiledAgentDefinition, m as CreateShareEntryInput, n as CredentialConsumerBindingRegistryV1, o as CredentialConsumerBindingV1, p as CredentialConsumerKindV1, q as CredentialDeliveryV1, r as CredentialFieldDefinitionV1, E as ExternalManagedAccountReferenceDefinitionV1, I as InMemoryShareEntryStore, O as OpaqueRefSchema, s as OpaqueShareLocatorIdSchema, t as PROVIDER_CREDENTIAL_REF_VERSION, u as ProviderCategoryV1, v as ProviderCredentialDefinitionV1, w as ProviderCredentialRefFactoryV1, x as ProviderDefinitionV1, y as ProviderId, z as ProviderRegistryV1, R as ResolvedCredentialLeaseV1, B as ResolvedCredentialMaterialV1, D as SandboxHandleRecord, F as SandboxHandleStore, G as Sha256DigestSchema, H as ShareEntryErrorCode, J as ShareEntryProvenance, K as ShareEntryProvenanceSchema, L as ShareEntryResolution, M as ShareEntryStore, N as ShareEntryTombstone, Q as ShareEntryV1, T as ShareEntryV1Schema, U as ShareEntryValidationError, V as VerifiedWorkspaceCredentialAuthorityV1, W as VerifiedWorkspaceCredentialPrincipalV1, X as WorkspaceCredentialAuthorityVerifierV1, Y as WorkspaceCredentialResolverV1, Z as createAgentAssetDigest, _ as createAgentDefinitionDigest, $ as createAgentDeploymentDigest, a0 as createCredentialConsumerBindingRegistryV1, a1 as createProviderCredentialRefFactoryV1, a2 as createProviderRegistryV1, a3 as providerCredentialFieldsV1, a4 as resolveShareEntry, a5 as validateAgentDefinition, a6 as validateAgentDeployment } from '../lease-DffrPrQn.js';
|
|
11
11
|
import { z } from 'zod';
|
|
12
|
-
export { e as AGENT_GATEWAY_ERROR_CODES, f as AgentFollowUpCommand, A as AgentGateway, g as AgentGatewayError, h as AgentGatewayErrorCode, i as AgentGatewayErrorDTO, j as AgentPromptCommand, k as AgentScopeVerifier, d as AgentSendReceipt, c as AgentSessionActivity, l as AgentSessionConnection, m as AgentSessionEvent, n as AgentSessionPage, b as AgentSessionRef, o as AgentSessionStateSnapshot, p as AgentSessionSummary, q as AgentSummary, r as AuthSubjectId, a as AuthorizedAgentScope, s as AuthorizedAgentSessionQuery, C as ConnectAgentSessionInput, t as CreateAgentSessionInput, D as DeleteAgentSessionInput, I as IdempotentAgentControl, u as IdempotentAgentSend, v as IdempotentQueueClear, J as JsonPrimitive, w as JsonSafe, x as JsonValue, L as ListAgentsInput, R as ReadAgentSessionStateInput, y as RenameAgentSessionInput, V as VerifiedAgentScopeClaim, W as WorkspaceScopeId } from '../errors-
|
|
12
|
+
export { e as AGENT_GATEWAY_ERROR_CODES, f as AgentFollowUpCommand, A as AgentGateway, g as AgentGatewayError, h as AgentGatewayErrorCode, i as AgentGatewayErrorDTO, j as AgentPromptCommand, k as AgentScopeVerifier, d as AgentSendReceipt, c as AgentSessionActivity, l as AgentSessionConnection, m as AgentSessionEvent, n as AgentSessionPage, b as AgentSessionRef, o as AgentSessionStateSnapshot, p as AgentSessionSummary, q as AgentSummary, r as AuthSubjectId, a as AuthorizedAgentScope, s as AuthorizedAgentSessionQuery, C as ConnectAgentSessionInput, t as CreateAgentSessionInput, D as DeleteAgentSessionInput, I as IdempotentAgentControl, u as IdempotentAgentSend, v as IdempotentQueueClear, J as JsonPrimitive, w as JsonSafe, x as JsonValue, L as ListAgentsInput, R as ReadAgentSessionStateInput, y as RenameAgentSessionInput, V as VerifiedAgentScopeClaim, W as WorkspaceScopeId } from '../errors-DH7C01Pm.js';
|
|
13
13
|
import '@mariozechner/pi-coding-agent';
|
|
14
14
|
|
|
15
15
|
declare const ToolUiMetadataSchema: z.ZodObject<{
|
|
@@ -100,12 +100,32 @@ declare const QueuedUserMessageSchema: z.ZodObject<{
|
|
|
100
100
|
clientSeq?: number | undefined;
|
|
101
101
|
}>;
|
|
102
102
|
declare const PiChatStatusSchema: z.ZodEnum<["idle", "hydrating", "submitted", "streaming", "aborting", "error"]>;
|
|
103
|
+
declare const ChatModelSelectionSchema: z.ZodObject<{
|
|
104
|
+
provider: z.ZodString;
|
|
105
|
+
id: z.ZodString;
|
|
106
|
+
}, "strip", z.ZodTypeAny, {
|
|
107
|
+
id: string;
|
|
108
|
+
provider: string;
|
|
109
|
+
}, {
|
|
110
|
+
id: string;
|
|
111
|
+
provider: string;
|
|
112
|
+
}>;
|
|
103
113
|
declare const PiChatSnapshotSchema: z.ZodObject<{
|
|
104
114
|
protocolVersion: z.ZodLiteral<1>;
|
|
105
115
|
sessionId: z.ZodString;
|
|
106
116
|
seq: z.ZodNumber;
|
|
107
117
|
status: z.ZodEnum<["idle", "hydrating", "submitted", "streaming", "aborting", "error"]>;
|
|
108
118
|
activeTurnId: z.ZodOptional<z.ZodString>;
|
|
119
|
+
currentModel: z.ZodOptional<z.ZodObject<{
|
|
120
|
+
provider: z.ZodString;
|
|
121
|
+
id: z.ZodString;
|
|
122
|
+
}, "strip", z.ZodTypeAny, {
|
|
123
|
+
id: string;
|
|
124
|
+
provider: string;
|
|
125
|
+
}, {
|
|
126
|
+
id: string;
|
|
127
|
+
provider: string;
|
|
128
|
+
}>>;
|
|
109
129
|
messages: z.ZodArray<z.ZodObject<{
|
|
110
130
|
id: z.ZodString;
|
|
111
131
|
role: z.ZodEnum<["user", "assistant", "system"]>;
|
|
@@ -229,6 +249,10 @@ declare const PiChatSnapshotSchema: z.ZodObject<{
|
|
|
229
249
|
details?: unknown;
|
|
230
250
|
retryable?: boolean | undefined;
|
|
231
251
|
} | undefined;
|
|
252
|
+
currentModel?: {
|
|
253
|
+
id: string;
|
|
254
|
+
provider: string;
|
|
255
|
+
} | undefined;
|
|
232
256
|
activeTurnId?: string | undefined;
|
|
233
257
|
}, {
|
|
234
258
|
status: "idle" | "aborting" | "error" | "streaming" | "hydrating" | "submitted";
|
|
@@ -263,6 +287,10 @@ declare const PiChatSnapshotSchema: z.ZodObject<{
|
|
|
263
287
|
details?: unknown;
|
|
264
288
|
retryable?: boolean | undefined;
|
|
265
289
|
} | undefined;
|
|
290
|
+
currentModel?: {
|
|
291
|
+
id: string;
|
|
292
|
+
provider: string;
|
|
293
|
+
} | undefined;
|
|
266
294
|
activeTurnId?: string | undefined;
|
|
267
295
|
}>;
|
|
268
296
|
declare const PiChatEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
@@ -280,6 +308,34 @@ declare const PiChatEventSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
|
280
308
|
seq: number;
|
|
281
309
|
}>, z.ZodObject<{
|
|
282
310
|
seq: z.ZodNumber;
|
|
311
|
+
} & {
|
|
312
|
+
type: z.ZodLiteral<"model-changed">;
|
|
313
|
+
currentModel: z.ZodObject<{
|
|
314
|
+
provider: z.ZodString;
|
|
315
|
+
id: z.ZodString;
|
|
316
|
+
}, "strip", z.ZodTypeAny, {
|
|
317
|
+
id: string;
|
|
318
|
+
provider: string;
|
|
319
|
+
}, {
|
|
320
|
+
id: string;
|
|
321
|
+
provider: string;
|
|
322
|
+
}>;
|
|
323
|
+
}, "strip", z.ZodTypeAny, {
|
|
324
|
+
type: "model-changed";
|
|
325
|
+
currentModel: {
|
|
326
|
+
id: string;
|
|
327
|
+
provider: string;
|
|
328
|
+
};
|
|
329
|
+
seq: number;
|
|
330
|
+
}, {
|
|
331
|
+
type: "model-changed";
|
|
332
|
+
currentModel: {
|
|
333
|
+
id: string;
|
|
334
|
+
provider: string;
|
|
335
|
+
};
|
|
336
|
+
seq: number;
|
|
337
|
+
}>, z.ZodObject<{
|
|
338
|
+
seq: z.ZodNumber;
|
|
283
339
|
} & {
|
|
284
340
|
type: z.ZodLiteral<"agent-end">;
|
|
285
341
|
turnId: z.ZodString;
|
|
@@ -741,6 +797,34 @@ declare const PiChatStreamFrameSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type
|
|
|
741
797
|
seq: number;
|
|
742
798
|
}>, z.ZodObject<{
|
|
743
799
|
seq: z.ZodNumber;
|
|
800
|
+
} & {
|
|
801
|
+
type: z.ZodLiteral<"model-changed">;
|
|
802
|
+
currentModel: z.ZodObject<{
|
|
803
|
+
provider: z.ZodString;
|
|
804
|
+
id: z.ZodString;
|
|
805
|
+
}, "strip", z.ZodTypeAny, {
|
|
806
|
+
id: string;
|
|
807
|
+
provider: string;
|
|
808
|
+
}, {
|
|
809
|
+
id: string;
|
|
810
|
+
provider: string;
|
|
811
|
+
}>;
|
|
812
|
+
}, "strip", z.ZodTypeAny, {
|
|
813
|
+
type: "model-changed";
|
|
814
|
+
currentModel: {
|
|
815
|
+
id: string;
|
|
816
|
+
provider: string;
|
|
817
|
+
};
|
|
818
|
+
seq: number;
|
|
819
|
+
}, {
|
|
820
|
+
type: "model-changed";
|
|
821
|
+
currentModel: {
|
|
822
|
+
id: string;
|
|
823
|
+
provider: string;
|
|
824
|
+
};
|
|
825
|
+
seq: number;
|
|
826
|
+
}>, z.ZodObject<{
|
|
827
|
+
seq: z.ZodNumber;
|
|
744
828
|
} & {
|
|
745
829
|
type: z.ZodLiteral<"agent-end">;
|
|
746
830
|
turnId: z.ZodString;
|
|
@@ -1186,16 +1270,6 @@ declare const PiChatStreamFrameSchema: z.ZodUnion<[z.ZodDiscriminatedUnion<"type
|
|
|
1186
1270
|
type: "heartbeat";
|
|
1187
1271
|
now: string;
|
|
1188
1272
|
}>]>;
|
|
1189
|
-
declare const ChatModelSelectionSchema: z.ZodObject<{
|
|
1190
|
-
provider: z.ZodString;
|
|
1191
|
-
id: z.ZodString;
|
|
1192
|
-
}, "strip", z.ZodTypeAny, {
|
|
1193
|
-
id: string;
|
|
1194
|
-
provider: string;
|
|
1195
|
-
}, {
|
|
1196
|
-
id: string;
|
|
1197
|
-
provider: string;
|
|
1198
|
-
}>;
|
|
1199
1273
|
declare const ThinkingLevelSchema: z.ZodEnum<["off", "low", "medium", "high"]>;
|
|
1200
1274
|
declare const ChatAttachmentPayloadSchema: z.ZodObject<{
|
|
1201
1275
|
filename: z.ZodOptional<z.ZodString>;
|
package/dist/shared/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { FastifyRequest, FastifyPluginAsync } from 'fastify';
|
|
2
|
-
import { C as ToolReadinessRequirement, v as TelemetrySink, s as AgentTool, D as AgentHarnessFactory } from './harness-
|
|
3
|
-
import { F as FileSearch, b as AgentSkillResource, c as WorkspaceAgentDirectRunInput, L as LeaseBoundWorkspaceAgent } from './file-search-
|
|
2
|
+
import { C as ToolReadinessRequirement, v as TelemetrySink, s as AgentTool, D as AgentHarnessFactory } from './harness-Dcd08yKr.js';
|
|
3
|
+
import { F as FileSearch, b as AgentSkillResource, c as WorkspaceAgentDirectRunInput, L as LeaseBoundWorkspaceAgent } from './file-search-qcD5zItr.js';
|
|
4
4
|
import { b as Workspace, h as RuntimeFilesystemCapability, j as WorkspaceRuntimeContext, c as Sandbox } from './sandbox-BMhut3kh.js';
|
|
5
|
-
import { b as AgentSessionRef, V as VerifiedAgentScopeClaim, i as AgentGatewayErrorDTO, x as JsonValue, a as AuthorizedAgentScope, A as AgentGateway, k as AgentScopeVerifier } from './errors-
|
|
6
|
-
import { C as ChatModelSelection } from './piChatEvent-
|
|
5
|
+
import { b as AgentSessionRef, V as VerifiedAgentScopeClaim, i as AgentGatewayErrorDTO, x as JsonValue, a as AuthorizedAgentScope, A as AgentGateway, k as AgentScopeVerifier } from './errors-DH7C01Pm.js';
|
|
6
|
+
import { C as ChatModelSelection } from './piChatEvent-iNSXiFQq.js';
|
|
7
7
|
import { RuntimeHostOperations, RuntimeFilesystemBinding as RuntimeFilesystemBinding$1 } from '@hachej/boring-bash/agent';
|
|
8
8
|
import { CreateNodeWorkspaceOptions, BoringAgentRuntimePaths } from '@hachej/boring-sandbox/providers/node-workspace';
|
|
9
9
|
import { PackageSource, ExtensionFactory } from '@mariozechner/pi-coding-agent';
|
|
@@ -86,11 +86,11 @@ interface ModelsRoutesOptions {
|
|
|
86
86
|
* (fail closed) so hosts can enforce hard stops.
|
|
87
87
|
* recordUsage once per native assistant message carrying usage.
|
|
88
88
|
* `usageId` is a stable idempotency key.
|
|
89
|
-
* settleRun when the run reaches a native terminal state and
|
|
90
|
-
*
|
|
91
|
-
* releaseRun when the run
|
|
92
|
-
*
|
|
93
|
-
*
|
|
89
|
+
* settleRun when the run reaches a native terminal state and billable
|
|
90
|
+
* usage or an authoritative all-zero usage row was recorded.
|
|
91
|
+
* releaseRun when the run does not settle: rejected execution, cleared
|
|
92
|
+
* queue, cancel/abort, error before usage, or a fail-closed
|
|
93
|
+
* fallback charge.
|
|
94
94
|
*
|
|
95
95
|
* Every run terminates with exactly one settle or release from the
|
|
96
96
|
* coordinator; sinks should still treat all four methods as idempotent
|
|
@@ -102,8 +102,8 @@ interface AgentMeteringSink {
|
|
|
102
102
|
reserveRun(input: MeteringReserveInput): Promise<MeteringReservationResult>;
|
|
103
103
|
/** Records the usage and returns the credit micros it was actually billed. The
|
|
104
104
|
* coordinator counts a usage as billable from this charged amount (not raw provider
|
|
105
|
-
* fields)
|
|
106
|
-
*
|
|
105
|
+
* fields). A complete, internally consistent all-zero report settles at zero;
|
|
106
|
+
* potentially billable usage priced to 0 retains fail-closed fallback. */
|
|
107
107
|
recordUsage(input: MeteringUsageInput): Promise<MeteringUsageResult>;
|
|
108
108
|
settleRun(input: MeteringSettleInput): Promise<void>;
|
|
109
109
|
releaseRun(input: MeteringReleaseInput): Promise<void>;
|
|
@@ -754,6 +754,21 @@ interface AgentInstructionFileRef {
|
|
|
754
754
|
readonly path: string;
|
|
755
755
|
readonly role: 'persona';
|
|
756
756
|
}
|
|
757
|
+
/**
|
|
758
|
+
* An authored instruction file as the fleet composer knows it: a canonical
|
|
759
|
+
* HOST absolute path, not yet addressed against any workspace.
|
|
760
|
+
*
|
|
761
|
+
* The two shapes are deliberately distinct. A multi-workspace host (the CLI
|
|
762
|
+
* hub, core) serves a DIFFERENT root per request, so composition cannot know
|
|
763
|
+
* which root a ref should be relative to; only the request can. The spec
|
|
764
|
+
* therefore carries sources, and `describe` publishes the subset that is
|
|
765
|
+
* reachable through the root actually being served (gh-1189).
|
|
766
|
+
*/
|
|
767
|
+
interface AgentInstructionSource {
|
|
768
|
+
/** Canonical absolute path on the host filesystem. */
|
|
769
|
+
readonly absolutePath: string;
|
|
770
|
+
readonly role: 'persona';
|
|
771
|
+
}
|
|
757
772
|
interface ConfiguredAgentHostAgentSpec {
|
|
758
773
|
readonly agentTypeId: string;
|
|
759
774
|
readonly definition: {
|
|
@@ -775,8 +790,12 @@ interface ConfiguredAgentHostAgentSpec {
|
|
|
775
790
|
/** Host path of the package's `knowledge/` folder. */
|
|
776
791
|
readonly rootDir: string;
|
|
777
792
|
};
|
|
778
|
-
/**
|
|
779
|
-
|
|
793
|
+
/**
|
|
794
|
+
* Authored instruction sources behind `definition.instructions`, as host
|
|
795
|
+
* absolute paths. Addressed against a served workspace root per request by
|
|
796
|
+
* `describe`, never at composition time.
|
|
797
|
+
*/
|
|
798
|
+
readonly instructionSources?: readonly AgentInstructionSource[];
|
|
780
799
|
readonly plugins?: readonly {
|
|
781
800
|
/** Canonical app-preflighted plugin ID. */
|
|
782
801
|
readonly name: string;
|
|
@@ -986,4 +1005,4 @@ interface CreatedAgentHost {
|
|
|
986
1005
|
runWithWorkspaceAgent(input: AgentHostDispatcherRunInput, run: (binding: LeaseBoundWorkspaceAgent) => Promise<void>): Promise<void>;
|
|
987
1006
|
}
|
|
988
1007
|
|
|
989
|
-
export {
|
|
1008
|
+
export { PI_PACKAGE_RESOURCE_FILTERS as $, type AgentGatewayEffect as A, type BuiltinRuntimeModeId as B, type ConfiguredAgentHostAgentSpec as C, type AgentRequestLedgerRecord as D, type AgentFleetCompiler as E, type AgentRequestTarget as F, type RuntimeFilesystemAccessDecision as G, type AgentHostDescription as H, type AgentHostDirectProjectionOptions as I, type AgentHostDispatcherRunInput as J, type AgentHostEnvironmentLease as K, type AgentHostHandle as L, type ModeContext as M, type LegacyDefaultAgentHostSpec as N, type MeteringReleaseInput as O, type ProvisionWorkspaceRuntimeOptions as P, type MeteringReleaseReason as Q, type RuntimeModeAdapter as R, type MeteringReservationResult as S, type MeteringReserveInput as T, type MeteringRunKind as U, type MeteringRunScope as V, type WorkspaceProvisioningResult as W, type MeteringRunStatus as X, type MeteringSettleInput as Y, type MeteringUsage as Z, type MeteringUsageInput as _, type PiPackageSource as a, type PiExtensionFactory as a0, type PluginSkillSource as a1, type ResolvedEnvironmentScope as a2, type RuntimeFilesystemBindingOperations as a3, type RuntimeNodePackageSpec as a4, type RuntimeProvisioningContribution as a5, type RuntimePythonSpec as a6, type RuntimeTemplateContribution as a7, type WorkspaceProvisioningExecResult as a8, compactPiPackages as a9, mergePiPackageSources as aa, normalizeMeteringUsage as ab, piPackageSourceKey as ac, type RuntimeModeId as b, type AgentRuntimeHostOperations as c, type RuntimeBashStrategy as d, type RuntimeFilesystemStrategy as e, type WorkspaceProvisioningAdapter as f, type AgentInstructionSource as g, type AgentInstructionFileRef as h, type AgentHostAgentSpec as i, type RuntimeBundle as j, type PiHarnessOptions as k, type AgentMeteringSink as l, type RuntimeFilesystemBinding as m, type CreatedAgentHost as n, type MeteringErrorLogger as o, ReadyStatusTracker as p, type CreateAgentHostOptions as q, type CompiledAgentHostAgentSpec as r, type AgentRequestLedger as s, type AgentEffectAdmission as t, type AuthorizedEnvironmentIntent as u, type AgentHostEnvironmentScope as v, type ResolvedAgentRuntimeScope as w, type AgentRequestKey as x, type AgentRequestLedgerPrepareResult as y, type AgentRequestFailure as z };
|
package/docs/ERROR_CODES.md
CHANGED
|
@@ -45,7 +45,7 @@ All API failures must use the response envelope:
|
|
|
45
45
|
| `AGENT_FLEET_MODEL_POLICY_UNCOMPILED` | Agent fleet configuration declares a model policy that the app fleet compiler did not resolve | 500 | configure app fleet compiler | error | stable (trusted API) |
|
|
46
46
|
| `AGENT_FLEET_SEAT_PERSONA_INVALID` | `loadConfiguredAgentFleet` excluded a fleet.yaml seat because its persona package failed to materialize or compose | 500 | fix persona package/spec | error | stable (trusted API) |
|
|
47
47
|
| `AGENT_FLEET_SEAT_SKILL_DIGEST_MISMATCH` | `loadConfiguredAgentFleet` excluded a fleet.yaml seat because a pinned skill's canonical content was unavailable or its digest drifted | 500 | run `pnpm write:skill-digests` or fix the skill file | error | stable (trusted API) |
|
|
48
|
-
| `AGENT_FLEET_SEAT_INSTRUCTIONS_PATH_UNPUBLISHABLE` | `
|
|
48
|
+
| `AGENT_FLEET_SEAT_INSTRUCTIONS_PATH_UNPUBLISHABLE` | `GET /api/v1/agents/:agentTypeId/describe` withheld the link to a seat's persona `instructions.md` for THIS request. Usually because the workspace root serving the request does not contain the personas tree (the fleet is composed from a repository root while the request is served from somewhere else); also when the persona canonically resolves outside that root through a symlink, when the source no longer exists, or when the seat name is not a safe path segment. NOT an HTTP error: the describe call still returns 200 — the code is only logged as a warning while that link is omitted from the response | 200 (log-only) | expected whenever a request is served from a workspace the personas are outside of — the seat runs normally, only the Agent-details instruction link is withheld. Serve the request from a workspace that contains the personas tree to get the link. If the message names an unsafe composed path, rename the seat directory to `[A-Za-z0-9][A-Za-z0-9._-]*` | warn | stable (trusted API) |
|
|
49
49
|
| `AGENT_FLEET_CONFIG_FILE_INVALID` | `loadConfiguredAgentFleet`'s fleet.yaml could not be read, parsed, or validated (whole-fleet failure, not per-seat) | 500 | fix `.agents/factory/fleet.yaml` | error | stable (trusted API) |
|
|
50
50
|
| `AGENT_DEFINITION_ID_CONFLICT` | Multiple discovered plugin packages claim the same agent definition id, so every claimant is excluded | 500 | remove or rename conflicting definitions | error | stable (trusted API) |
|
|
51
51
|
| `AGENT_DEFINITION_UNSEATED` | A discovered agent package is not named by the fleet roster and remains inert | 200 | seat it in class-B fleet config if activation is intended | info | stable (trusted API) |
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hachej/boring-agent",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.105",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"description": "Pane-embeddable coding agent. Ships direct/local/vercel-sandbox execution modes behind one interface.",
|
|
@@ -85,12 +85,12 @@
|
|
|
85
85
|
"@streamdown/math": "^1.0.2",
|
|
86
86
|
"@streamdown/mermaid": "^1.0.2",
|
|
87
87
|
"@tanstack/react-query": "^5.101.4",
|
|
88
|
-
"ai": "^7.0.
|
|
88
|
+
"ai": "^7.0.65",
|
|
89
89
|
"class-variance-authority": "^0.7.1",
|
|
90
90
|
"clsx": "^2.1.1",
|
|
91
91
|
"cmdk": "^1.1.1",
|
|
92
92
|
"diff": "^9.0.0",
|
|
93
|
-
"fastify": "^5.
|
|
93
|
+
"fastify": "^5.12.0",
|
|
94
94
|
"lucide-react": "^1.31.0",
|
|
95
95
|
"motion": "^13.1.0",
|
|
96
96
|
"nanoid": "^6.0.0",
|
|
@@ -100,9 +100,9 @@
|
|
|
100
100
|
"use-stick-to-bottom": "^1.1.6",
|
|
101
101
|
"yaml": "^2.9.0",
|
|
102
102
|
"zod": "^3.25.76",
|
|
103
|
-
"@hachej/boring-bash": "0.1.
|
|
104
|
-
"@hachej/boring-
|
|
105
|
-
"@hachej/boring-
|
|
103
|
+
"@hachej/boring-bash": "0.1.105",
|
|
104
|
+
"@hachej/boring-sandbox": "0.1.105",
|
|
105
|
+
"@hachej/boring-ui-kit": "0.1.105"
|
|
106
106
|
},
|
|
107
107
|
"devDependencies": {
|
|
108
108
|
"@vercel/sandbox": "3.0.0",
|