@promptbook/google 0.114.0-4 → 0.114.0-41
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 +9 -9
- package/esm/index.es.js +15 -18
- package/esm/index.es.js.map +1 -1
- package/esm/src/_packages/components.index.d.ts +4 -0
- package/esm/src/_packages/types.index.d.ts +4 -0
- package/esm/src/avatars/renderAvatarVisualTerminalText.d.ts +80 -0
- package/esm/src/avatars/types/AvatarVisualDefinition.d.ts +54 -0
- package/esm/src/book-2.0/agent-source/AgentReferenceResolutionIssue.d.ts +45 -0
- package/esm/src/book-2.0/agent-source/AgentSourceParseResult.d.ts +5 -0
- package/esm/src/book-2.0/agent-source/ParsedUnknownCommitment.d.ts +26 -0
- package/esm/src/book-2.0/agent-source/deduplicateSystemMessage.d.ts +14 -0
- package/esm/src/book-2.0/agent-source/explicitFromCommitment.d.ts +62 -0
- package/esm/src/book-2.0/agent-source/extractAgentReferenceTokens.d.ts +32 -0
- package/esm/src/book-2.0/agent-source/getBookCommitmentLineType.d.ts +19 -0
- package/esm/src/book-2.0/agent-source/parseAgentSourceWithCommitments.unknown.test.d.ts +1 -0
- package/esm/src/book-2.0/agent-source/resolveInheritedAgentSource.d.ts +73 -0
- package/esm/src/book-2.0/book-language-documentation/getSafeCodeBlock.d.ts +1 -1
- package/esm/src/book-3.0/AgentMessageRunReport.d.ts +46 -0
- package/esm/src/book-3.0/AgentPlannedMessagesSidecar.d.ts +127 -0
- package/esm/src/book-3.0/AgentPlannedMessagesSidecar.test.d.ts +1 -0
- package/esm/src/book-3.0/AgentTeamConversationWorkspace.d.ts +85 -0
- package/esm/src/book-3.0/cliAgentEnv.d.ts +3 -3
- package/esm/src/book-3.0/createAgentMessageSidecarBaseName.d.ts +13 -0
- package/esm/src/book-3.0/describeAgentPlannedMessageSchedule.d.ts +31 -0
- package/esm/src/book-components/BookEditor/createDeprecatedCommitmentDiagnostics.browser.d.ts +1 -9
- package/esm/src/book-components/BookEditor/createDuplicateFromCommitmentDiagnostics.d.ts +28 -0
- package/esm/src/book-components/BookEditor/createDuplicateFromCommitmentDiagnostics.test.d.ts +1 -0
- package/esm/src/book-components/BookEditor/createUnknownCommitmentDiagnostics.d.ts +28 -0
- package/esm/src/book-components/BookEditor/createUnknownCommitmentDiagnostics.test.d.ts +1 -0
- package/esm/src/book-components/Chat/Chat/ChatProps.d.ts +3 -2
- package/esm/src/book-components/Chat/Chat/renderAgentProjectDiff.d.ts +13 -0
- package/esm/src/book-components/Chat/Chat/renderAgentProjectToolCallDetails.d.ts +16 -0
- package/esm/src/book-components/Chat/MockedChat/MockedChat.test.d.ts +2 -0
- package/esm/src/book-components/Chat/utils/agentProjectToolCall.d.ts +85 -0
- package/esm/src/book-components/Chat/utils/agentProjectToolCall.test.d.ts +1 -0
- package/esm/src/book-components/Chat/utils/externalSourceToolCall.d.ts +38 -0
- package/esm/src/book-components/Chat/utils/renderMarkdown.d.ts +68 -3
- package/esm/src/book-components/Chat/utils/timeoutToolCallPresentation.d.ts +30 -0
- package/esm/src/cli/$initializePromptbookCliProgram.d.ts +8 -0
- package/esm/src/cli/cli-commands/coder/$ensureCoderHarnessGitignoreRules.d.ts +10 -0
- package/esm/src/cli/cli-commands/coder/$ensureCoderHarnessGitignoreRules.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/coder/GitChangesMode.d.ts +28 -0
- package/esm/src/cli/cli-commands/coder/agentCliOptions.d.ts +21 -0
- package/esm/src/cli/cli-commands/coder/boilerplateCount.d.ts +1 -1
- package/esm/src/cli/cli-commands/coder/boilerplateTemplates.d.ts +8 -21
- package/esm/src/cli/cli-commands/coder/coderReferencedArtifacts.d.ts +33 -0
- package/esm/src/cli/cli-commands/coder/ensureCoderGitignoreFile.d.ts +14 -1
- package/esm/src/cli/cli-commands/coder/ensureCoderPackageJsonFile.d.ts +4 -2
- package/esm/src/cli/cli-commands/coder/ensureCoderVscodeSettingsFile.d.ts +2 -0
- package/esm/src/cli/cli-commands/coder/ensureDirectory.d.ts +6 -0
- package/esm/src/cli/cli-commands/coder/generate-boilerplates.d.ts +1 -1
- package/esm/src/cli/cli-commands/coder/getDefaultCoderPackageJsonScripts.d.ts +6 -0
- package/esm/src/cli/cli-commands/coder/init.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/coder/initializeCoderProjectConfiguration.d.ts +8 -5
- package/esm/src/cli/cli-commands/coder/list.d.ts +10 -0
- package/esm/src/cli/cli-commands/coder/list.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/coder/mergeStringRecordJsonFile.d.ts +19 -1
- package/esm/src/cli/cli-commands/coder/printCoderRunFailure.d.ts +6 -0
- package/esm/src/cli/cli-commands/coder/server.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/coder/verify.d.ts +1 -1
- package/esm/src/cli/cli-commands/coder/waitOptions.d.ts +12 -0
- package/esm/src/cli/cli-commands/coder.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/$askForConfirmation.d.ts +11 -0
- package/esm/src/cli/cli-commands/common/$askForConfirmation.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/LocalAgentBookCollection.d.ts +46 -0
- package/esm/src/cli/cli-commands/common/createLocalAgentReferenceResolver.d.ts +8 -0
- package/esm/src/cli/cli-commands/common/disk-space/$assertSufficientFreeDiskSpace.d.ts +12 -0
- package/esm/src/cli/cli-commands/common/disk-space/$assertSufficientFreeDiskSpace.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/disk-space/$readFreeDiskSpaceStatus.d.ts +11 -0
- package/esm/src/cli/cli-commands/common/disk-space/$readFreeDiskSpaceStatus.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/disk-space/FreeDiskSpaceStatus.d.ts +33 -0
- package/esm/src/cli/cli-commands/common/disk-space/formatFreeDiskSpaceBytes.d.ts +6 -0
- package/esm/src/cli/cli-commands/common/disk-space/formatFreeDiskSpaceBytes.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/disk-space/formatLowFreeDiskSpaceWarning.d.ts +10 -0
- package/esm/src/cli/cli-commands/common/disk-space/freeDiskSpaceConstants.d.ts +28 -0
- package/esm/src/cli/cli-commands/common/disk-space/resolveFreeDiskSpaceLevel.d.ts +7 -0
- package/esm/src/cli/cli-commands/common/disk-space/resolveFreeDiskSpaceLevel.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/ensureAdamAgentBook.d.ts +12 -0
- package/esm/src/cli/cli-commands/common/harness/$applyHarnessInstallationStatus.d.ts +3 -2
- package/esm/src/cli/cli-commands/common/harness/$checkHarnessInstallation.d.ts +3 -3
- package/esm/src/cli/cli-commands/common/harness/$checkHarnessInstallation.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/harness/$ensureHarnessInstallations.d.ts +4 -3
- package/esm/src/cli/cli-commands/common/harness/$resolveHarnessCommandPath.d.ts +14 -0
- package/esm/src/cli/cli-commands/common/harness/$resolveHarnessInstallationOrigin.d.ts +10 -0
- package/esm/src/cli/cli-commands/common/harness/$runHarnessInstallationCommand.d.ts +43 -0
- package/esm/src/cli/cli-commands/common/harness/HARNESS_DEFAULT_MODELS.d.ts +25 -0
- package/esm/src/cli/cli-commands/common/harness/HarnessDefinition.d.ts +62 -0
- package/esm/src/cli/cli-commands/common/harness/HarnessInstallationOrigin.d.ts +36 -0
- package/esm/src/cli/cli-commands/common/harness/HarnessInstallationStatus.d.ts +8 -2
- package/esm/src/cli/cli-commands/common/harness/HarnessUpdatePlan.d.ts +23 -0
- package/esm/src/cli/cli-commands/common/harness/buildHarnessInstallCommand.d.ts +4 -1
- package/esm/src/cli/cli-commands/common/harness/formatHarnessManualUpdateInstruction.d.ts +8 -0
- package/esm/src/cli/cli-commands/common/harness/formatHarnessManualUpdateInstruction.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/harness/resolveHarnessInstallationMethodFromPaths.d.ts +31 -0
- package/esm/src/cli/cli-commands/common/harness/resolveHarnessInstallationMethodFromPaths.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/harness/resolveHarnessUpdatePlan.d.ts +12 -0
- package/esm/src/cli/cli-commands/common/harness/resolveHarnessUpdatePlan.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/npm/$askForNpmPackageInstallationApproval.d.ts +11 -0
- package/{umd/src/cli/cli-commands/common/harness/$resolveLatestHarnessVersion.d.ts → esm/src/cli/cli-commands/common/npm/$resolveLatestNpmPackageVersion.d.ts} +2 -3
- package/esm/src/cli/cli-commands/common/npm/$resolveLatestNpmPackageVersion.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/npm/$resolveNpmGlobalPrefixPath.d.ts +9 -0
- package/esm/src/cli/cli-commands/common/npm/buildNpmPackageInstallCommand.d.ts +12 -0
- package/esm/src/cli/cli-commands/common/npm/buildNpmPackageInstallCommand.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/npm/extractNpmPackageVersionFromOutput.d.ts +12 -0
- package/esm/src/cli/cli-commands/common/npm/extractNpmPackageVersionFromOutput.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/npm/isNpmPackageVersionOutdated.d.ts +12 -0
- package/esm/src/cli/cli-commands/common/npm/isNpmPackageVersionOutdated.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/projectInitialization.d.ts +6 -0
- package/esm/src/cli/cli-commands/common/promptPriorityCliOptions.d.ts +7 -0
- package/esm/src/cli/cli-commands/common/promptRunnerCliOptions.d.ts +17 -4
- package/esm/src/cli/cli-commands/common/promptbook-cli/$checkPromptbookCliInstallations.d.ts +9 -0
- package/esm/src/cli/cli-commands/common/promptbook-cli/$checkPromptbookCliInstallations.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/promptbook-cli/$ensurePromptbookCliInstallations.d.ts +15 -0
- package/esm/src/cli/cli-commands/common/promptbook-cli/$ensurePromptbookCliInstallations.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/promptbook-cli/$resolvePromptbookCliInstallations.d.ts +12 -0
- package/esm/src/cli/cli-commands/common/promptbook-cli/$resolvePromptbookCliInstallations.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/promptbook-cli/$updatePromptbookCliInstallation.d.ts +10 -0
- package/esm/src/cli/cli-commands/common/promptbook-cli/$updatePromptbookCliInstallation.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/promptbook-cli/PromptbookCliInstallation.d.ts +66 -0
- package/esm/src/cli/cli-commands/common/promptbook-cli/PromptbookCliInstallationStatus.d.ts +26 -0
- package/esm/src/cli/cli-commands/common/promptbook-cli/buildPromptbookCliInstallCommand.d.ts +7 -0
- package/esm/src/cli/cli-commands/common/promptbook-cli/formatPromptbookCliInstallationWarning.d.ts +7 -0
- package/esm/src/cli/cli-commands/common/questionsCliOptions.d.ts +45 -0
- package/esm/src/cli/cli-commands/common/questionsCliOptions.test.d.ts +1 -0
- package/esm/src/cli/cli-commands/common/resolveBundledAgentBookPath.d.ts +6 -0
- package/esm/src/cli/cli-commands/common/resolveLocalAgentSource.d.ts +19 -0
- package/esm/src/cli/common/$deprecateCliCommand.d.ts +3 -0
- package/esm/src/cli/common/$hideCliCommandFromHelp.d.ts +11 -0
- package/esm/src/cli/common/$hideCliCommandFromHelp.test.d.ts +1 -0
- package/esm/src/cli/common/$requireCliSubcommand.d.ts +18 -0
- package/esm/src/cli/common/$requireCliSubcommand.test.d.ts +1 -0
- package/esm/src/collection/agent-collection/constructors/agent-collection-in-supabase/AgentCollectionInSupabase.d.ts +15 -0
- package/esm/src/commitments/WRITING_RULES/WRITING_RULES.d.ts +14 -7
- package/esm/src/commitments/index.d.ts +1 -1
- package/esm/src/executables/platforms/locateAppOnWindows.d.ts +1 -1
- package/esm/src/executables/platforms/locateAppOnWindows.test.d.ts +1 -0
- package/esm/src/llm-providers/vercel/VercelExecutionToolsOptions.d.ts +5 -2
- package/esm/src/utils/agent-message-runtime/AgentMessageProjectChange.d.ts +76 -0
- package/esm/src/utils/agent-message-runtime/AgentMessageTouchedExternalSource.d.ts +45 -0
- package/esm/src/utils/agent-message-runtime/parseAgentMessageRuntimeLogEvents.d.ts +62 -0
- package/esm/src/utils/agent-message-runtime/resolveAgentMessageRuntimeActivity.d.ts +3 -3
- package/esm/src/utils/agent-message-runtime/resolveAgentMessageTouchedExternalSources.d.ts +18 -0
- package/esm/src/utils/agent-message-runtime/resolveAgentMessageTouchedExternalSources.test.d.ts +1 -0
- package/esm/src/utils/agent-message-runtime/resolveAgentMessageTouchedProjectNames.d.ts +19 -0
- package/esm/src/utils/agent-message-runtime/resolveAgentMessageTouchedProjectNames.test.d.ts +1 -0
- package/esm/src/utils/agents/terminalAgentAvatarVisual.d.ts +5 -2
- package/esm/src/utils/ascii-art/convertImageDataToAsciiArt.d.ts +6 -0
- package/esm/src/utils/ascii-art/createAnsiColorCode.d.ts +46 -0
- package/esm/src/utils/files/findFilesByGlob.d.ts +28 -0
- package/esm/src/utils/misc/debounce.d.ts +4 -2
- package/esm/src/utils/misc/debounce.test.d.ts +1 -0
- package/esm/src/utils/misc/emojis.d.ts +3 -2
- package/esm/src/utils/random/$generateBookBoilerplate.test.d.ts +1 -0
- package/esm/src/version.d.ts +1 -1
- package/package.json +3 -6
- package/umd/index.umd.js +15 -18
- package/umd/index.umd.js.map +1 -1
- package/umd/src/_packages/components.index.d.ts +4 -0
- package/umd/src/_packages/types.index.d.ts +4 -0
- package/umd/src/avatars/renderAvatarVisualTerminalText.d.ts +80 -0
- package/umd/src/avatars/renderAvatarVisualTerminalText.test.d.ts +1 -0
- package/umd/src/avatars/types/AvatarVisualDefinition.d.ts +54 -0
- package/umd/src/book-2.0/agent-source/AgentReferenceResolutionIssue.d.ts +45 -0
- package/umd/src/book-2.0/agent-source/AgentSourceParseResult.d.ts +5 -0
- package/umd/src/book-2.0/agent-source/ParsedUnknownCommitment.d.ts +26 -0
- package/umd/src/book-2.0/agent-source/createAgentModelRequirements.deduplication.test.d.ts +1 -0
- package/umd/src/book-2.0/agent-source/createAgentModelRequirementsWithCommitments.unknown.test.d.ts +1 -0
- package/umd/src/book-2.0/agent-source/deduplicateSystemMessage.d.ts +14 -0
- package/umd/src/book-2.0/agent-source/deduplicateSystemMessage.test.d.ts +1 -0
- package/umd/src/book-2.0/agent-source/explicitFromCommitment.d.ts +62 -0
- package/umd/src/book-2.0/agent-source/extractAgentReferenceTokens.d.ts +32 -0
- package/umd/src/book-2.0/agent-source/getBookCommitmentLineType.d.ts +19 -0
- package/umd/src/book-2.0/agent-source/parseAgentSourceWithCommitments.unknown.test.d.ts +1 -0
- package/umd/src/book-2.0/agent-source/resolveInheritedAgentSource.d.ts +73 -0
- package/umd/src/book-2.0/book-language-documentation/getSafeCodeBlock.d.ts +1 -1
- package/umd/src/book-3.0/AgentMessageRunReport.d.ts +46 -0
- package/umd/src/book-3.0/AgentPlannedMessagesSidecar.d.ts +127 -0
- package/umd/src/book-3.0/AgentPlannedMessagesSidecar.test.d.ts +1 -0
- package/umd/src/book-3.0/AgentTeamConversationWorkspace.d.ts +85 -0
- package/umd/src/book-3.0/cliAgentEnv.d.ts +3 -3
- package/umd/src/book-3.0/createAgentMessageSidecarBaseName.d.ts +13 -0
- package/umd/src/book-3.0/describeAgentPlannedMessageSchedule.d.ts +31 -0
- package/umd/src/book-components/BookEditor/createDeprecatedCommitmentDiagnostics.browser.d.ts +1 -9
- package/umd/src/book-components/BookEditor/createDuplicateFromCommitmentDiagnostics.d.ts +28 -0
- package/umd/src/book-components/BookEditor/createDuplicateFromCommitmentDiagnostics.test.d.ts +1 -0
- package/umd/src/book-components/BookEditor/createUnknownCommitmentDiagnostics.d.ts +28 -0
- package/umd/src/book-components/BookEditor/createUnknownCommitmentDiagnostics.test.d.ts +1 -0
- package/umd/src/book-components/Chat/Chat/ChatProps.d.ts +3 -2
- package/umd/src/book-components/Chat/Chat/renderAgentProjectDiff.d.ts +13 -0
- package/umd/src/book-components/Chat/Chat/renderAgentProjectToolCallDetails.d.ts +16 -0
- package/umd/src/book-components/Chat/MockedChat/MockedChat.test.d.ts +2 -0
- package/umd/src/book-components/Chat/utils/agentProjectToolCall.d.ts +85 -0
- package/umd/src/book-components/Chat/utils/agentProjectToolCall.test.d.ts +1 -0
- package/umd/src/book-components/Chat/utils/externalSourceToolCall.d.ts +38 -0
- package/umd/src/book-components/Chat/utils/renderMarkdown.d.ts +68 -3
- package/umd/src/book-components/Chat/utils/timeoutToolCallPresentation.d.ts +30 -0
- package/umd/src/cli/$initializePromptbookCliProgram.d.ts +8 -0
- package/umd/src/cli/cli-commands/coder/$ensureCoderHarnessGitignoreRules.d.ts +10 -0
- package/umd/src/cli/cli-commands/coder/$ensureCoderHarnessGitignoreRules.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/coder/GitChangesMode.d.ts +28 -0
- package/umd/src/cli/cli-commands/coder/agentCliOptions.d.ts +21 -0
- package/umd/src/cli/cli-commands/coder/boilerplateCount.d.ts +1 -1
- package/umd/src/cli/cli-commands/coder/boilerplateTemplates.d.ts +8 -21
- package/umd/src/cli/cli-commands/coder/coderReferencedArtifacts.d.ts +33 -0
- package/umd/src/cli/cli-commands/coder/ensureCoderGitignoreFile.d.ts +14 -1
- package/umd/src/cli/cli-commands/coder/ensureCoderPackageJsonFile.d.ts +4 -2
- package/umd/src/cli/cli-commands/coder/ensureCoderVscodeSettingsFile.d.ts +2 -0
- package/umd/src/cli/cli-commands/coder/ensureDirectory.d.ts +6 -0
- package/umd/src/cli/cli-commands/coder/generate-boilerplates.d.ts +1 -1
- package/umd/src/cli/cli-commands/coder/getDefaultCoderPackageJsonScripts.d.ts +6 -0
- package/umd/src/cli/cli-commands/coder/init.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/coder/initializeCoderProjectConfiguration.d.ts +8 -5
- package/umd/src/cli/cli-commands/coder/list.d.ts +10 -0
- package/umd/src/cli/cli-commands/coder/list.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/coder/mergeStringRecordJsonFile.d.ts +19 -1
- package/umd/src/cli/cli-commands/coder/printCoderRunFailure.d.ts +6 -0
- package/umd/src/cli/cli-commands/coder/server.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/coder/verify.d.ts +1 -1
- package/umd/src/cli/cli-commands/coder/waitOptions.d.ts +12 -0
- package/umd/src/cli/cli-commands/coder.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/$askForConfirmation.d.ts +11 -0
- package/umd/src/cli/cli-commands/common/$askForConfirmation.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/LocalAgentBookCollection.d.ts +46 -0
- package/umd/src/cli/cli-commands/common/createLocalAgentReferenceResolver.d.ts +8 -0
- package/umd/src/cli/cli-commands/common/disk-space/$assertSufficientFreeDiskSpace.d.ts +12 -0
- package/umd/src/cli/cli-commands/common/disk-space/$assertSufficientFreeDiskSpace.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/disk-space/$readFreeDiskSpaceStatus.d.ts +11 -0
- package/umd/src/cli/cli-commands/common/disk-space/$readFreeDiskSpaceStatus.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/disk-space/FreeDiskSpaceStatus.d.ts +33 -0
- package/umd/src/cli/cli-commands/common/disk-space/formatFreeDiskSpaceBytes.d.ts +6 -0
- package/umd/src/cli/cli-commands/common/disk-space/formatFreeDiskSpaceBytes.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/disk-space/formatLowFreeDiskSpaceWarning.d.ts +10 -0
- package/umd/src/cli/cli-commands/common/disk-space/freeDiskSpaceConstants.d.ts +28 -0
- package/umd/src/cli/cli-commands/common/disk-space/resolveFreeDiskSpaceLevel.d.ts +7 -0
- package/umd/src/cli/cli-commands/common/disk-space/resolveFreeDiskSpaceLevel.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/ensureAdamAgentBook.d.ts +12 -0
- package/umd/src/cli/cli-commands/common/harness/$applyHarnessInstallationStatus.d.ts +3 -2
- package/umd/src/cli/cli-commands/common/harness/$checkHarnessInstallation.d.ts +3 -3
- package/umd/src/cli/cli-commands/common/harness/$checkHarnessInstallation.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/harness/$ensureHarnessInstallations.d.ts +4 -3
- package/umd/src/cli/cli-commands/common/harness/$resolveHarnessCommandPath.d.ts +14 -0
- package/umd/src/cli/cli-commands/common/harness/$resolveHarnessInstallationOrigin.d.ts +10 -0
- package/umd/src/cli/cli-commands/common/harness/$runHarnessInstallationCommand.d.ts +43 -0
- package/umd/src/cli/cli-commands/common/harness/HARNESS_DEFAULT_MODELS.d.ts +25 -0
- package/umd/src/cli/cli-commands/common/harness/HarnessDefinition.d.ts +62 -0
- package/umd/src/cli/cli-commands/common/harness/HarnessInstallationOrigin.d.ts +36 -0
- package/umd/src/cli/cli-commands/common/harness/HarnessInstallationStatus.d.ts +8 -2
- package/umd/src/cli/cli-commands/common/harness/HarnessUpdatePlan.d.ts +23 -0
- package/umd/src/cli/cli-commands/common/harness/buildHarnessInstallCommand.d.ts +4 -1
- package/umd/src/cli/cli-commands/common/harness/formatHarnessManualUpdateInstruction.d.ts +8 -0
- package/umd/src/cli/cli-commands/common/harness/formatHarnessManualUpdateInstruction.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/harness/resolveHarnessInstallationMethodFromPaths.d.ts +31 -0
- package/umd/src/cli/cli-commands/common/harness/resolveHarnessInstallationMethodFromPaths.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/harness/resolveHarnessUpdatePlan.d.ts +12 -0
- package/umd/src/cli/cli-commands/common/harness/resolveHarnessUpdatePlan.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/npm/$askForNpmPackageInstallationApproval.d.ts +11 -0
- package/{esm/src/cli/cli-commands/common/harness/$resolveLatestHarnessVersion.d.ts → umd/src/cli/cli-commands/common/npm/$resolveLatestNpmPackageVersion.d.ts} +2 -3
- package/umd/src/cli/cli-commands/common/npm/$resolveLatestNpmPackageVersion.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/npm/$resolveNpmGlobalPrefixPath.d.ts +9 -0
- package/umd/src/cli/cli-commands/common/npm/buildNpmPackageInstallCommand.d.ts +12 -0
- package/umd/src/cli/cli-commands/common/npm/buildNpmPackageInstallCommand.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/npm/extractNpmPackageVersionFromOutput.d.ts +12 -0
- package/umd/src/cli/cli-commands/common/npm/extractNpmPackageVersionFromOutput.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/npm/isNpmPackageVersionOutdated.d.ts +12 -0
- package/umd/src/cli/cli-commands/common/npm/isNpmPackageVersionOutdated.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/projectInitialization.d.ts +6 -0
- package/umd/src/cli/cli-commands/common/promptPriorityCliOptions.d.ts +7 -0
- package/umd/src/cli/cli-commands/common/promptRunnerCliOptions.d.ts +17 -4
- package/umd/src/cli/cli-commands/common/promptbook-cli/$checkPromptbookCliInstallations.d.ts +9 -0
- package/umd/src/cli/cli-commands/common/promptbook-cli/$checkPromptbookCliInstallations.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/promptbook-cli/$ensurePromptbookCliInstallations.d.ts +15 -0
- package/umd/src/cli/cli-commands/common/promptbook-cli/$ensurePromptbookCliInstallations.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/promptbook-cli/$resolvePromptbookCliInstallations.d.ts +12 -0
- package/umd/src/cli/cli-commands/common/promptbook-cli/$resolvePromptbookCliInstallations.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/promptbook-cli/$updatePromptbookCliInstallation.d.ts +10 -0
- package/umd/src/cli/cli-commands/common/promptbook-cli/$updatePromptbookCliInstallation.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/promptbook-cli/PromptbookCliInstallation.d.ts +66 -0
- package/umd/src/cli/cli-commands/common/promptbook-cli/PromptbookCliInstallationStatus.d.ts +26 -0
- package/umd/src/cli/cli-commands/common/promptbook-cli/buildPromptbookCliInstallCommand.d.ts +7 -0
- package/umd/src/cli/cli-commands/common/promptbook-cli/formatPromptbookCliInstallationWarning.d.ts +7 -0
- package/umd/src/cli/cli-commands/common/questionsCliOptions.d.ts +45 -0
- package/umd/src/cli/cli-commands/common/questionsCliOptions.test.d.ts +1 -0
- package/umd/src/cli/cli-commands/common/resolveBundledAgentBookPath.d.ts +6 -0
- package/umd/src/cli/cli-commands/common/resolveLocalAgentSource.d.ts +19 -0
- package/umd/src/cli/common/$deprecateCliCommand.d.ts +3 -0
- package/umd/src/cli/common/$hideCliCommandFromHelp.d.ts +11 -0
- package/umd/src/cli/common/$hideCliCommandFromHelp.test.d.ts +1 -0
- package/umd/src/cli/common/$requireCliSubcommand.d.ts +18 -0
- package/umd/src/cli/common/$requireCliSubcommand.test.d.ts +1 -0
- package/umd/src/collection/agent-collection/constructors/agent-collection-in-supabase/AgentCollectionInSupabase.d.ts +15 -0
- package/umd/src/commitments/WRITING_RULES/WRITING_RULES.d.ts +14 -7
- package/umd/src/commitments/index.d.ts +1 -1
- package/umd/src/executables/platforms/locateAppOnWindows.d.ts +1 -1
- package/umd/src/executables/platforms/locateAppOnWindows.test.d.ts +1 -0
- package/umd/src/llm-providers/vercel/VercelExecutionToolsOptions.d.ts +5 -2
- package/umd/src/utils/agent-message-runtime/AgentMessageProjectChange.d.ts +76 -0
- package/umd/src/utils/agent-message-runtime/AgentMessageTouchedExternalSource.d.ts +45 -0
- package/umd/src/utils/agent-message-runtime/parseAgentMessageRuntimeLogEvents.d.ts +62 -0
- package/umd/src/utils/agent-message-runtime/resolveAgentMessageRuntimeActivity.d.ts +3 -3
- package/umd/src/utils/agent-message-runtime/resolveAgentMessageTouchedExternalSources.d.ts +18 -0
- package/umd/src/utils/agent-message-runtime/resolveAgentMessageTouchedExternalSources.test.d.ts +1 -0
- package/umd/src/utils/agent-message-runtime/resolveAgentMessageTouchedProjectNames.d.ts +19 -0
- package/umd/src/utils/agent-message-runtime/resolveAgentMessageTouchedProjectNames.test.d.ts +1 -0
- package/umd/src/utils/agents/terminalAgentAvatarVisual.d.ts +5 -2
- package/umd/src/utils/ascii-art/convertImageDataToAsciiArt.d.ts +6 -0
- package/umd/src/utils/ascii-art/createAnsiColorCode.d.ts +46 -0
- package/umd/src/utils/files/findFilesByGlob.d.ts +28 -0
- package/umd/src/utils/misc/debounce.d.ts +4 -2
- package/umd/src/utils/misc/debounce.test.d.ts +1 -0
- package/umd/src/utils/misc/emojis.d.ts +3 -2
- package/umd/src/utils/random/$generateBookBoilerplate.test.d.ts +1 -0
- package/umd/src/version.d.ts +1 -1
- package/esm/src/cli/cli-commands/coder/agentCodingFile.d.ts +0 -13
- package/esm/src/cli/cli-commands/common/harness/$askForHarnessInstallationApproval.d.ts +0 -9
- package/esm/src/cli/cli-commands/common/harness/$installHarness.d.ts +0 -13
- package/esm/src/cli/cli-commands/common/harness/extractHarnessVersionFromOutput.d.ts +0 -11
- package/esm/src/cli/cli-commands/common/harness/isHarnessVersionOutdated.d.ts +0 -9
- package/umd/src/cli/cli-commands/coder/agentCodingFile.d.ts +0 -13
- package/umd/src/cli/cli-commands/common/harness/$askForHarnessInstallationApproval.d.ts +0 -9
- package/umd/src/cli/cli-commands/common/harness/$installHarness.d.ts +0 -13
- package/umd/src/cli/cli-commands/common/harness/extractHarnessVersionFromOutput.d.ts +0 -11
- package/umd/src/cli/cli-commands/common/harness/isHarnessVersionOutdated.d.ts +0 -9
- /package/esm/src/{cli/cli-commands/common/harness/extractHarnessVersionFromOutput.test.d.ts → avatars/renderAvatarVisualTerminalText.test.d.ts} +0 -0
- /package/esm/src/{cli/cli-commands/common/harness/isHarnessVersionOutdated.test.d.ts → book-2.0/agent-source/createAgentModelRequirements.deduplication.test.d.ts} +0 -0
- /package/{umd/src/cli/cli-commands/common/harness/extractHarnessVersionFromOutput.test.d.ts → esm/src/book-2.0/agent-source/createAgentModelRequirementsWithCommitments.unknown.test.d.ts} +0 -0
- /package/{umd/src/cli/cli-commands/common/harness/isHarnessVersionOutdated.test.d.ts → esm/src/book-2.0/agent-source/deduplicateSystemMessage.test.d.ts} +0 -0
|
@@ -72,6 +72,52 @@ export type AvatarVisualRenderContext = {
|
|
|
72
72
|
* @private shared contract for the avatar rendering system
|
|
73
73
|
*/
|
|
74
74
|
export type AvatarVisual = (context: AvatarVisualRenderContext) => void;
|
|
75
|
+
/**
|
|
76
|
+
* One painted character cell of a terminal-text avatar frame.
|
|
77
|
+
*
|
|
78
|
+
* @private shared contract for the avatar rendering system
|
|
79
|
+
*/
|
|
80
|
+
export type AvatarVisualTerminalTextCell = {
|
|
81
|
+
/**
|
|
82
|
+
* Single character painted in the cell.
|
|
83
|
+
*/
|
|
84
|
+
readonly character: string;
|
|
85
|
+
/**
|
|
86
|
+
* Color of the character as a CSS color string, optionally with an alpha channel.
|
|
87
|
+
*/
|
|
88
|
+
readonly color: string_color;
|
|
89
|
+
};
|
|
90
|
+
/**
|
|
91
|
+
* One rendered terminal-text avatar frame as a grid of character cells.
|
|
92
|
+
*
|
|
93
|
+
* Rows are ordered top to bottom, cells left to right, and `null` leaves the terminal background visible.
|
|
94
|
+
*
|
|
95
|
+
* @private shared contract for the avatar rendering system
|
|
96
|
+
*/
|
|
97
|
+
export type AvatarVisualTerminalTextGrid = ReadonlyArray<ReadonlyArray<AvatarVisualTerminalTextCell | null>>;
|
|
98
|
+
/**
|
|
99
|
+
* Rendering context forwarded to a terminal-text avatar visual.
|
|
100
|
+
*
|
|
101
|
+
* Unlike `AvatarVisualRenderContext` this carries no canvas, because the visual paints
|
|
102
|
+
* character cells of a fixed terminal grid instead of pixels.
|
|
103
|
+
*
|
|
104
|
+
* @private shared contract for the avatar rendering system
|
|
105
|
+
*/
|
|
106
|
+
export type AvatarVisualTerminalTextRenderContext = {
|
|
107
|
+
readonly columns: number;
|
|
108
|
+
readonly rows: number;
|
|
109
|
+
readonly timeMs: number;
|
|
110
|
+
readonly avatarDefinition: AvatarDefinition;
|
|
111
|
+
readonly palette: AvatarPalette;
|
|
112
|
+
readonly createRandom: (salt: string) => () => number;
|
|
113
|
+
readonly interaction: AvatarInteractionState;
|
|
114
|
+
};
|
|
115
|
+
/**
|
|
116
|
+
* Signature of one terminal-text avatar visual renderer.
|
|
117
|
+
*
|
|
118
|
+
* @private shared contract for the avatar rendering system
|
|
119
|
+
*/
|
|
120
|
+
export type AvatarVisualTerminalText = (context: AvatarVisualTerminalTextRenderContext) => AvatarVisualTerminalTextGrid;
|
|
75
121
|
/**
|
|
76
122
|
* Metadata and renderer for one built-in avatar visual.
|
|
77
123
|
*
|
|
@@ -84,6 +130,14 @@ export type AvatarVisualDefinition = {
|
|
|
84
130
|
readonly isAnimated: boolean;
|
|
85
131
|
readonly supportsPointerTracking?: boolean;
|
|
86
132
|
readonly render: AvatarVisual;
|
|
133
|
+
/**
|
|
134
|
+
* Optional native terminal renderer of visuals which are themselves made of characters.
|
|
135
|
+
*
|
|
136
|
+
* Character-based visuals lose their identity when they are rasterized onto a canvas and
|
|
137
|
+
* converted back into half-block ASCII art, so they paint the terminal character grid directly.
|
|
138
|
+
* Visuals without this renderer are rasterized through `renderAvatarVisualAsciiArt` instead.
|
|
139
|
+
*/
|
|
140
|
+
readonly renderTerminalText?: AvatarVisualTerminalText;
|
|
87
141
|
};
|
|
88
142
|
/**
|
|
89
143
|
* Props of the shared `<Avatar/>` component.
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import type { BookCommitment } from '../../commitments/_base/BookCommitment';
|
|
2
|
+
import type { AgentReferenceResolver } from './AgentReferenceResolver';
|
|
3
|
+
/**
|
|
4
|
+
* Structured issue captured when compact agent reference resolution fails.
|
|
5
|
+
*
|
|
6
|
+
* @private internal utility of agent reference resolution
|
|
7
|
+
*/
|
|
8
|
+
export type AgentReferenceResolutionIssue = {
|
|
9
|
+
/**
|
|
10
|
+
* Commitment where the unresolved token appeared.
|
|
11
|
+
*/
|
|
12
|
+
readonly commitmentType: BookCommitment;
|
|
13
|
+
/**
|
|
14
|
+
* Original token text (for example `{Unknown Agent}` or `@UnknownAgent`).
|
|
15
|
+
*/
|
|
16
|
+
readonly token: string;
|
|
17
|
+
/**
|
|
18
|
+
* Normalized token payload used for lookup.
|
|
19
|
+
*/
|
|
20
|
+
readonly reference: string;
|
|
21
|
+
/**
|
|
22
|
+
* Human-readable explanation of why the token could not be resolved.
|
|
23
|
+
*/
|
|
24
|
+
readonly message: string;
|
|
25
|
+
};
|
|
26
|
+
/**
|
|
27
|
+
* Extension implemented by resolvers that can expose accumulated resolution issues.
|
|
28
|
+
*
|
|
29
|
+
* @private internal utility of agent reference resolution
|
|
30
|
+
*/
|
|
31
|
+
export type IssueTrackingAgentReferenceResolver = AgentReferenceResolver & {
|
|
32
|
+
/**
|
|
33
|
+
* Returns tracked issues and clears the internal queue.
|
|
34
|
+
*/
|
|
35
|
+
consumeResolutionIssues(): Array<AgentReferenceResolutionIssue>;
|
|
36
|
+
};
|
|
37
|
+
/**
|
|
38
|
+
* Drains unresolved compact-reference issues from a resolver when supported.
|
|
39
|
+
*
|
|
40
|
+
* @param resolver - Resolver instance that may implement issue tracking.
|
|
41
|
+
* @returns Collected issues or an empty list.
|
|
42
|
+
*
|
|
43
|
+
* @private internal utility of agent reference resolution
|
|
44
|
+
*/
|
|
45
|
+
export declare function consumeAgentReferenceResolutionIssues(resolver?: AgentReferenceResolver): Array<AgentReferenceResolutionIssue>;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { ParsedCommitment } from '../../commitments/_base/ParsedCommitment';
|
|
2
2
|
import type { string_agent_name } from '../../types/string_agent_name';
|
|
3
|
+
import type { ParsedUnknownCommitment } from './ParsedUnknownCommitment';
|
|
3
4
|
/**
|
|
4
5
|
* Result of parsing agent source for commitments
|
|
5
6
|
*
|
|
@@ -18,6 +19,10 @@ export type AgentSourceParseResult = {
|
|
|
18
19
|
* All parsed commitments
|
|
19
20
|
*/
|
|
20
21
|
commitments: ParsedCommitment[];
|
|
22
|
+
/**
|
|
23
|
+
* Uppercase commitment blocks whose types are not registered by Promptbook.
|
|
24
|
+
*/
|
|
25
|
+
unknownCommitments: ParsedUnknownCommitment[];
|
|
21
26
|
/**
|
|
22
27
|
* Lines that are not commitments (for system message)
|
|
23
28
|
*/
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* An uppercase Book commitment block whose keyword is not registered by Promptbook.
|
|
3
|
+
*
|
|
4
|
+
* Unknown commitments are retained as system-message context instead of being applied
|
|
5
|
+
* as executable commitments.
|
|
6
|
+
*
|
|
7
|
+
* @private internal type of `parseAgentSourceWithCommitments`
|
|
8
|
+
*/
|
|
9
|
+
export type ParsedUnknownCommitment = {
|
|
10
|
+
/**
|
|
11
|
+
* Uppercase unknown commitment type, for example `FOO` or `BAR BZZ`.
|
|
12
|
+
*/
|
|
13
|
+
readonly type: string;
|
|
14
|
+
/**
|
|
15
|
+
* Original first line, retained for precise editor diagnostics.
|
|
16
|
+
*/
|
|
17
|
+
readonly originalLine: string;
|
|
18
|
+
/**
|
|
19
|
+
* Line number in the agent source (1-based).
|
|
20
|
+
*/
|
|
21
|
+
readonly lineNumber: number;
|
|
22
|
+
/**
|
|
23
|
+
* Complete unknown commitment block, including its keyword and continuation lines.
|
|
24
|
+
*/
|
|
25
|
+
readonly source: string;
|
|
26
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/umd/src/book-2.0/agent-source/createAgentModelRequirementsWithCommitments.unknown.test.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Removes duplicated instructions from a generated system message
|
|
3
|
+
*
|
|
4
|
+
* Commitments are applied one by one, so a commitment used multiple times in one book repeats its whole
|
|
5
|
+
* section, including the shared guidance preamble. For example two `WRITING RULES` commitments emit the
|
|
6
|
+
* `## Writing rules` heading and its guidance paragraph twice. This function merges all sections sharing
|
|
7
|
+
* one heading into the position of their first occurrence and keeps every identical block only once.
|
|
8
|
+
*
|
|
9
|
+
* @param systemMessage The assembled system message which may contain repeated sections and blocks
|
|
10
|
+
* @returns The system message where each section heading and each identical block appears exactly once
|
|
11
|
+
*
|
|
12
|
+
* @private internal utility of `createAgentModelRequirementsWithCommitments`
|
|
13
|
+
*/
|
|
14
|
+
export declare function deduplicateSystemMessage(systemMessage: string): string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import type { string_book } from './string_book';
|
|
2
|
+
/**
|
|
3
|
+
* One explicit `FROM` commitment written in a book.
|
|
4
|
+
*
|
|
5
|
+
* @private utility of Agents Server inheritance resolution
|
|
6
|
+
*/
|
|
7
|
+
export type ExplicitFromCommitment = {
|
|
8
|
+
/**
|
|
9
|
+
* Zero-based index of the line the commitment was found on, within the scanned lines.
|
|
10
|
+
*/
|
|
11
|
+
readonly lineIndex: number;
|
|
12
|
+
/**
|
|
13
|
+
* Trimmed commitment content, empty string for a blank `FROM`.
|
|
14
|
+
*/
|
|
15
|
+
readonly content: string;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Collects every explicit single-line `FROM` commitment of one book.
|
|
19
|
+
*
|
|
20
|
+
* This lightweight parser is intentionally limited to the subset needed by inheritance
|
|
21
|
+
* resolution so it stays safe to bundle into the Next.js proxy path.
|
|
22
|
+
*
|
|
23
|
+
* @param sourceLines - Book source already split into lines.
|
|
24
|
+
* @returns Found `FROM` commitments in source order, empty when the book declares no parent.
|
|
25
|
+
*
|
|
26
|
+
* @private utility of Agents Server inheritance resolution
|
|
27
|
+
*/
|
|
28
|
+
export declare function collectExplicitFromCommitments(sourceLines: ReadonlyArray<string>): ReadonlyArray<ExplicitFromCommitment>;
|
|
29
|
+
/**
|
|
30
|
+
* Returns the effective explicit `FROM` commitment of one book.
|
|
31
|
+
*
|
|
32
|
+
* A book may repeat `FROM`, in which case the last one wins and overrides every earlier one.
|
|
33
|
+
*
|
|
34
|
+
* @param agentSource - Raw book source.
|
|
35
|
+
* @returns The last explicit `FROM` commitment, or `undefined` when the book declares no parent.
|
|
36
|
+
*
|
|
37
|
+
* @private utility of Agents Server inheritance resolution
|
|
38
|
+
*/
|
|
39
|
+
export declare function getEffectiveExplicitFromCommitment(agentSource: string_book): ExplicitFromCommitment | undefined;
|
|
40
|
+
/**
|
|
41
|
+
* Returns the effective explicit `FROM` commitment content of one book.
|
|
42
|
+
*
|
|
43
|
+
* A book may repeat `FROM`, in which case the last one wins and overrides every earlier one.
|
|
44
|
+
*
|
|
45
|
+
* @param agentSource - Raw book source.
|
|
46
|
+
* @returns Trimmed commitment content, empty string for a blank explicit `FROM`, or `undefined` when `FROM` is absent.
|
|
47
|
+
*
|
|
48
|
+
* @private utility of Agents Server inheritance resolution
|
|
49
|
+
*/
|
|
50
|
+
export declare function getExplicitFromCommitmentContent(agentSource: string_book): string | undefined;
|
|
51
|
+
/**
|
|
52
|
+
* Returns true when one book declares no parent at all and therefore implicitly inherits from `@Adam`.
|
|
53
|
+
*
|
|
54
|
+
* Writing no `FROM` commitment is equivalent to writing `FROM @Adam`, so only an explicit
|
|
55
|
+
* `FROM @Null` / `FROM {Void}` turns the inheritance off.
|
|
56
|
+
*
|
|
57
|
+
* @param agentSource - Raw book source.
|
|
58
|
+
* @returns True when the implicit `@Adam` ancestor applies to this book.
|
|
59
|
+
*
|
|
60
|
+
* @private utility of Agents Server inheritance resolution
|
|
61
|
+
*/
|
|
62
|
+
export declare function isImplicitAdamInheritance(agentSource: string_book): boolean;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Matched compact agent reference token inside commitment content.
|
|
3
|
+
*
|
|
4
|
+
* @private internal utility of agent reference resolution
|
|
5
|
+
*/
|
|
6
|
+
export type AgentReferenceTokenMatch = {
|
|
7
|
+
/**
|
|
8
|
+
* Original token text, for example `{Agent Name}` or `@AgentId`.
|
|
9
|
+
*/
|
|
10
|
+
readonly token: string;
|
|
11
|
+
/**
|
|
12
|
+
* Token payload used for lookup.
|
|
13
|
+
*/
|
|
14
|
+
readonly reference: string;
|
|
15
|
+
/**
|
|
16
|
+
* Zero-based character offset of `token` in the scanned content.
|
|
17
|
+
*/
|
|
18
|
+
readonly index: number;
|
|
19
|
+
/**
|
|
20
|
+
* Length of `token` in characters.
|
|
21
|
+
*/
|
|
22
|
+
readonly length: number;
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* Extracts compact agent-reference tokens from commitment content.
|
|
26
|
+
*
|
|
27
|
+
* @param content - Commitment content to inspect.
|
|
28
|
+
* @returns Matched compact reference tokens.
|
|
29
|
+
*
|
|
30
|
+
* @private internal utility of agent reference resolution
|
|
31
|
+
*/
|
|
32
|
+
export declare function extractAgentReferenceTokens(content: string): Array<AgentReferenceTokenMatch>;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Creates the regex used to recognize the uppercase commitment type at the beginning of a Book line.
|
|
3
|
+
*
|
|
4
|
+
* A fresh regular expression keeps Monaco tokenizer state isolated from parser calls.
|
|
5
|
+
*
|
|
6
|
+
* @returns Regular expression matching one Book commitment-like line.
|
|
7
|
+
*
|
|
8
|
+
* @private internal utility of Book parsing and `<BookEditor/>`
|
|
9
|
+
*/
|
|
10
|
+
export declare function createBookCommitmentLineTypeRegex(): RegExp;
|
|
11
|
+
/**
|
|
12
|
+
* Extracts the uppercase commitment type from a Book line, including types not registered by Promptbook.
|
|
13
|
+
*
|
|
14
|
+
* @param line - One raw Book source line.
|
|
15
|
+
* @returns Matched commitment type or `null` when the line does not begin with commitment syntax.
|
|
16
|
+
*
|
|
17
|
+
* @private internal utility of Book parsing and `<BookEditor/>`
|
|
18
|
+
*/
|
|
19
|
+
export declare function getBookCommitmentLineType(line: string): string | null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import type { string_agent_url } from '../../types/string_agent_url';
|
|
2
|
+
import type { string_book } from './string_book';
|
|
3
|
+
import type { AgentReferenceResolver } from './AgentReferenceResolver';
|
|
4
|
+
/**
|
|
5
|
+
* Shared options for resolving one agent source with inheritance and imports applied.
|
|
6
|
+
*
|
|
7
|
+
* @private internal utility of agent source resolution
|
|
8
|
+
*/
|
|
9
|
+
export type ResolveInheritedAgentSourceOptions = {
|
|
10
|
+
/** Current recursion depth, forwarded to the source importer. */
|
|
11
|
+
readonly recursionLevel?: number;
|
|
12
|
+
/**
|
|
13
|
+
* The URL of the Adam agent to use as the default ancestor
|
|
14
|
+
*
|
|
15
|
+
* @default 'https://core.ptbk.io/agents/adam'
|
|
16
|
+
*/
|
|
17
|
+
readonly adamAgentUrl?: string_agent_url;
|
|
18
|
+
/**
|
|
19
|
+
* Custom resolver used to expand compact agent references.
|
|
20
|
+
*/
|
|
21
|
+
readonly agentReferenceResolver?: AgentReferenceResolver;
|
|
22
|
+
/**
|
|
23
|
+
* Canonical URL of the currently resolved agent.
|
|
24
|
+
*/
|
|
25
|
+
readonly currentAgentUrl?: string_agent_url;
|
|
26
|
+
/**
|
|
27
|
+
* Additional equivalent URLs that should be treated as the current agent while detecting cycles.
|
|
28
|
+
*/
|
|
29
|
+
readonly currentAgentAliases?: ReadonlyArray<string_agent_url>;
|
|
30
|
+
/**
|
|
31
|
+
* Already visited agent URLs in the current resolution stack.
|
|
32
|
+
*/
|
|
33
|
+
readonly inheritancePath?: ReadonlyArray<string_agent_url>;
|
|
34
|
+
/**
|
|
35
|
+
* Source importer supplied by the host application.
|
|
36
|
+
*/
|
|
37
|
+
readonly agentSourceImporter: AgentSourceImporter;
|
|
38
|
+
};
|
|
39
|
+
/**
|
|
40
|
+
* Context passed to a custom agent source importer.
|
|
41
|
+
*
|
|
42
|
+
* @private internal utility of agent source resolution
|
|
43
|
+
*/
|
|
44
|
+
export type AgentSourceImporterContext = {
|
|
45
|
+
/**
|
|
46
|
+
* Commitment that requested the imported source.
|
|
47
|
+
*/
|
|
48
|
+
readonly commitmentType: 'FROM' | 'IMPORT';
|
|
49
|
+
/**
|
|
50
|
+
* Import options propagated from the current resolution pass.
|
|
51
|
+
*/
|
|
52
|
+
readonly importAgentOptions: {
|
|
53
|
+
readonly recursionLevel?: number;
|
|
54
|
+
readonly inheritancePath?: ReadonlyArray<string_agent_url>;
|
|
55
|
+
};
|
|
56
|
+
};
|
|
57
|
+
/**
|
|
58
|
+
* Loads and recursively resolves one referenced agent using the caller's transport.
|
|
59
|
+
*
|
|
60
|
+
* @private internal utility of agent source resolution
|
|
61
|
+
*/
|
|
62
|
+
export type AgentSourceImporter = (agentUrl: string_agent_url, context: AgentSourceImporterContext) => Promise<string_book>;
|
|
63
|
+
/**
|
|
64
|
+
* Resolves agent source with inheritance (FROM commitment)
|
|
65
|
+
*
|
|
66
|
+
* It recursively fetches the parent agent source and merges it with the current source.
|
|
67
|
+
*
|
|
68
|
+
* @param agentSource The initial agent source
|
|
69
|
+
* @returns The resolved agent source with inheritance applied
|
|
70
|
+
*
|
|
71
|
+
* @private internal utility of agent source resolution
|
|
72
|
+
*/
|
|
73
|
+
export declare function resolveInheritedAgentSource(agentSource: string_book, options: ResolveInheritedAgentSourceOptions): Promise<string_book>;
|
|
@@ -5,6 +5,6 @@
|
|
|
5
5
|
* @param language - Optional info-string language label.
|
|
6
6
|
* @returns Fenced code block.
|
|
7
7
|
*
|
|
8
|
-
* @private internal utility of `createStandaloneBookLanguageMarkdown`
|
|
8
|
+
* @private internal utility of `createStandaloneBookLanguageMarkdown` and of the `ptbk coder` run traces
|
|
9
9
|
*/
|
|
10
10
|
export declare function getSafeCodeBlock(content: string, language?: string): string;
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import type { Usage } from '../execution/Usage';
|
|
2
|
+
import type { AgentMessageProjectChange } from '../utils/agent-message-runtime/AgentMessageProjectChange';
|
|
3
|
+
import type { AgentMessageTouchedExternalSource } from '../utils/agent-message-runtime/AgentMessageTouchedExternalSource';
|
|
2
4
|
import type { CodexLoginMethod } from './codexLoginMethod';
|
|
3
5
|
/**
|
|
4
6
|
* File suffix appended to one answered message book to store its run report sidecar.
|
|
@@ -9,6 +11,23 @@ import type { CodexLoginMethod } from './codexLoginMethod';
|
|
|
9
11
|
* @private internal constant of the agent folder convention
|
|
10
12
|
*/
|
|
11
13
|
export declare const AGENT_MESSAGE_RUN_REPORT_FILE_SUFFIX = ".report.json";
|
|
14
|
+
/**
|
|
15
|
+
* Exact wall-clock interval during which one harness processed an agent message.
|
|
16
|
+
*
|
|
17
|
+
* Note: [🚉] This is fully serializable as JSON
|
|
18
|
+
*
|
|
19
|
+
* @private internal type of the agent folder convention
|
|
20
|
+
*/
|
|
21
|
+
export type AgentMessageRunExecutionTiming = {
|
|
22
|
+
/**
|
|
23
|
+
* ISO 8601 timestamp captured immediately before the harness begins the message.
|
|
24
|
+
*/
|
|
25
|
+
readonly startedAt: string;
|
|
26
|
+
/**
|
|
27
|
+
* ISO 8601 timestamp captured when the harness finishes the message.
|
|
28
|
+
*/
|
|
29
|
+
readonly finishedAt: string;
|
|
30
|
+
};
|
|
12
31
|
/**
|
|
13
32
|
* Report describing how one queued agent message was answered by a CLI harness runner.
|
|
14
33
|
*
|
|
@@ -44,6 +63,33 @@ export type AgentMessageRunReport = {
|
|
|
44
63
|
* Usage statistics of the run (price, token counts, duration).
|
|
45
64
|
*/
|
|
46
65
|
readonly usage: Usage;
|
|
66
|
+
/**
|
|
67
|
+
* Measured wall-clock timing of the actual harness execution, excluding time spent waiting in the queue.
|
|
68
|
+
*/
|
|
69
|
+
readonly executionTiming?: AgentMessageRunExecutionTiming;
|
|
70
|
+
/**
|
|
71
|
+
* Directory names of the agent projects the harness worked with while answering the message.
|
|
72
|
+
*
|
|
73
|
+
* Reported by the runner from its live runtime log, which is deleted once the message is
|
|
74
|
+
* answered, so this is the only trace of the projects one answer viewed or edited.
|
|
75
|
+
*/
|
|
76
|
+
readonly touchedProjectNames?: ReadonlyArray<string>;
|
|
77
|
+
/**
|
|
78
|
+
* Sources outside the agent — integrations, websites and web searches — the harness reached
|
|
79
|
+
* while answering the message.
|
|
80
|
+
*
|
|
81
|
+
* Reported from the same live runtime log as `touchedProjectNames`, so this is the only trace
|
|
82
|
+
* of what one answer touched beyond the agent itself.
|
|
83
|
+
*/
|
|
84
|
+
readonly touchedExternalSources?: ReadonlyArray<AgentMessageTouchedExternalSource>;
|
|
85
|
+
/**
|
|
86
|
+
* Changes the harness made to the agent projects while answering the message.
|
|
87
|
+
*
|
|
88
|
+
* Every agent project is a git repository and the runner commits each answer into it, so one
|
|
89
|
+
* entry describes exactly what one message did to one project — including the diff of the
|
|
90
|
+
* commit it created.
|
|
91
|
+
*/
|
|
92
|
+
readonly projectChanges?: ReadonlyArray<AgentMessageProjectChange>;
|
|
47
93
|
};
|
|
48
94
|
/**
|
|
49
95
|
* Builds the run-report sidecar path for one message book path.
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Relative directory holding the planned-message sidecar of each queued message.
|
|
3
|
+
*
|
|
4
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
5
|
+
*/
|
|
6
|
+
export declare const AGENT_PLANNED_MESSAGES_DIRECTORY_PATH: string;
|
|
7
|
+
/**
|
|
8
|
+
* Command actions an agent can request from its planned-message sidecar.
|
|
9
|
+
*
|
|
10
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
11
|
+
*/
|
|
12
|
+
export declare const AGENT_PLANNED_MESSAGE_COMMAND_ACTIONS: readonly ["set", "update", "cancel"];
|
|
13
|
+
/**
|
|
14
|
+
* One planned-message command action.
|
|
15
|
+
*
|
|
16
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
17
|
+
*/
|
|
18
|
+
export type AgentPlannedMessageCommandAction = (typeof AGENT_PLANNED_MESSAGE_COMMAND_ACTIONS)[number];
|
|
19
|
+
/**
|
|
20
|
+
* One planned message that is already waiting to wake the agent.
|
|
21
|
+
*
|
|
22
|
+
* A planned message can repeat like `setInterval`, run a bounded number of times, or wake the agent
|
|
23
|
+
* only once, so the whole schedule is what the agent compares with its goal, while `dueAt` only says
|
|
24
|
+
* when the nearest wake-up happens.
|
|
25
|
+
*
|
|
26
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
27
|
+
*/
|
|
28
|
+
export type AgentPlannedMessageSnapshot = {
|
|
29
|
+
readonly timeoutId: string;
|
|
30
|
+
readonly dueAt: string;
|
|
31
|
+
readonly message: string | null;
|
|
32
|
+
/**
|
|
33
|
+
* Repeat interval in milliseconds, or `null` for a planned message that does not repeat at a fixed
|
|
34
|
+
* interval.
|
|
35
|
+
*/
|
|
36
|
+
readonly intervalMs: number | null;
|
|
37
|
+
/**
|
|
38
|
+
* Five-field cron expression driving the repetitions, or `null` when the planned message does not
|
|
39
|
+
* follow a cron.
|
|
40
|
+
*/
|
|
41
|
+
readonly cronExpression: string | null;
|
|
42
|
+
/**
|
|
43
|
+
* Moment before which the planned message never wakes the agent, or `null` when it has no starting
|
|
44
|
+
* date.
|
|
45
|
+
*/
|
|
46
|
+
readonly startsAt: string | null;
|
|
47
|
+
/**
|
|
48
|
+
* Moment after which the planned message never wakes the agent again, or `null` when it has no
|
|
49
|
+
* ending date.
|
|
50
|
+
*/
|
|
51
|
+
readonly endsAt: string | null;
|
|
52
|
+
/**
|
|
53
|
+
* Total number of wake-ups the planned message performs, or `null` when it repeats until it is
|
|
54
|
+
* cancelled.
|
|
55
|
+
*/
|
|
56
|
+
readonly maxRunCount: number | null;
|
|
57
|
+
/**
|
|
58
|
+
* Number of times the planned message already woke the agent.
|
|
59
|
+
*/
|
|
60
|
+
readonly runCount: number;
|
|
61
|
+
};
|
|
62
|
+
/**
|
|
63
|
+
* One command written by the coding harness into its planned-message sidecar.
|
|
64
|
+
*
|
|
65
|
+
* The payload stays untyped on purpose: it is untrusted harness output and is validated by the very
|
|
66
|
+
* same shared planned-message actions that back the model tools and the internal runtime API.
|
|
67
|
+
*
|
|
68
|
+
* For a `set` command, `milliseconds` is the repeat interval of the planned message, not a one-shot
|
|
69
|
+
* delay, and `cronExpression`, `startsAt`, `endsAt`, and `maxRunCount` bound how it repeats. An
|
|
70
|
+
* `update` command changes the very same fields of the planned message named by `timeoutId`, where a
|
|
71
|
+
* field that is left out stays as it is and an explicit `null` removes the bound.
|
|
72
|
+
*
|
|
73
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
74
|
+
*/
|
|
75
|
+
export type AgentPlannedMessageCommand = {
|
|
76
|
+
readonly action: AgentPlannedMessageCommandAction;
|
|
77
|
+
readonly milliseconds?: unknown;
|
|
78
|
+
readonly cronExpression?: unknown;
|
|
79
|
+
readonly startsAt?: unknown;
|
|
80
|
+
readonly endsAt?: unknown;
|
|
81
|
+
readonly maxRunCount?: unknown;
|
|
82
|
+
readonly message?: unknown;
|
|
83
|
+
readonly timeoutId?: unknown;
|
|
84
|
+
};
|
|
85
|
+
/**
|
|
86
|
+
* Planned-message sidecar prepared for one queued message.
|
|
87
|
+
*
|
|
88
|
+
* `currentPlannedMessages` is written by the Agents Server and is read-only for the agent, while
|
|
89
|
+
* `commands` is the only channel through which a coding harness can plan or cancel a wake-up.
|
|
90
|
+
*
|
|
91
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
92
|
+
*/
|
|
93
|
+
export type AgentPlannedMessagesSidecar = {
|
|
94
|
+
readonly version: 1;
|
|
95
|
+
readonly agentPermanentId: string;
|
|
96
|
+
readonly currentPlannedMessages: ReadonlyArray<AgentPlannedMessageSnapshot>;
|
|
97
|
+
readonly commands: ReadonlyArray<AgentPlannedMessageCommand>;
|
|
98
|
+
};
|
|
99
|
+
/**
|
|
100
|
+
* Creates the relative planned-message sidecar path of one queued message.
|
|
101
|
+
*
|
|
102
|
+
* @param messageFileName - File name of the queued `.book` message.
|
|
103
|
+
* @returns Relative path of the sidecar inside the agent folder.
|
|
104
|
+
*
|
|
105
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
106
|
+
*/
|
|
107
|
+
export declare function createAgentPlannedMessagesSidecarPath(messageFileName: string): string;
|
|
108
|
+
/**
|
|
109
|
+
* Serializes one planned-message sidecar into its stored representation.
|
|
110
|
+
*
|
|
111
|
+
* @param sidecar - Sidecar prepared for one queued message.
|
|
112
|
+
* @returns Pretty-printed JSON the coding harness can edit by hand.
|
|
113
|
+
*
|
|
114
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
115
|
+
*/
|
|
116
|
+
export declare function createAgentPlannedMessagesSidecarContent(sidecar: AgentPlannedMessagesSidecar): string;
|
|
117
|
+
/**
|
|
118
|
+
* Parses one untrusted planned-message sidecar written back by a coding harness.
|
|
119
|
+
*
|
|
120
|
+
* A malformed sidecar never fails the already answered chat, so this returns `null` instead of throwing.
|
|
121
|
+
*
|
|
122
|
+
* @param sidecarContent - Raw file content read from the agent folder.
|
|
123
|
+
* @returns Normalized sidecar, or `null` when it cannot be used.
|
|
124
|
+
*
|
|
125
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
126
|
+
*/
|
|
127
|
+
export declare function parseAgentPlannedMessagesSidecar(sidecarContent: string): AgentPlannedMessagesSidecar | null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Relative directory for an active TEAM conversation workspace.
|
|
3
|
+
*
|
|
4
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
5
|
+
*/
|
|
6
|
+
export declare const AGENT_TEAM_CONVERSATIONS_DIRECTORY_PATH: string;
|
|
7
|
+
/**
|
|
8
|
+
* Relative directory where completed TEAM conversation transcripts are retained.
|
|
9
|
+
*
|
|
10
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
11
|
+
*/
|
|
12
|
+
export declare const AGENT_FINISHED_TEAM_CONVERSATIONS_DIRECTORY_PATH: string;
|
|
13
|
+
/**
|
|
14
|
+
* Name of the JSON manifest that describes one TEAM conversation workspace.
|
|
15
|
+
*
|
|
16
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
17
|
+
*/
|
|
18
|
+
export declare const AGENT_TEAM_CONVERSATION_MANIFEST_FILE_NAME = "team.json";
|
|
19
|
+
/**
|
|
20
|
+
* Name of the read-only teammate-source directory inside one TEAM workspace.
|
|
21
|
+
*
|
|
22
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
23
|
+
*/
|
|
24
|
+
export declare const AGENT_TEAMMATE_SOURCES_DIRECTORY_NAME = "teammates";
|
|
25
|
+
/**
|
|
26
|
+
* One primary agent represented in a TEAM workspace manifest.
|
|
27
|
+
*
|
|
28
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
29
|
+
*/
|
|
30
|
+
export type AgentTeamConversationPrimaryAgent = {
|
|
31
|
+
readonly permanentId: string;
|
|
32
|
+
readonly agentName: string;
|
|
33
|
+
};
|
|
34
|
+
/**
|
|
35
|
+
* One local teammate made available to the coding harness for a single user turn.
|
|
36
|
+
*
|
|
37
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
38
|
+
*/
|
|
39
|
+
export type AgentTeamConversationTeammate = {
|
|
40
|
+
readonly permanentId: string;
|
|
41
|
+
readonly agentName: string;
|
|
42
|
+
readonly url: string;
|
|
43
|
+
readonly instructions: string;
|
|
44
|
+
readonly sourceFileName: string;
|
|
45
|
+
};
|
|
46
|
+
/**
|
|
47
|
+
* Persisted roster snapshot for the optional TEAM workspace of one queued message.
|
|
48
|
+
*
|
|
49
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
50
|
+
*/
|
|
51
|
+
export type AgentTeamConversationWorkspaceManifest = {
|
|
52
|
+
readonly version: 1;
|
|
53
|
+
readonly primaryAgent: AgentTeamConversationPrimaryAgent;
|
|
54
|
+
readonly teammates: ReadonlyArray<AgentTeamConversationTeammate>;
|
|
55
|
+
};
|
|
56
|
+
/**
|
|
57
|
+
* Creates the stable directory name that belongs to one queued `.book` message.
|
|
58
|
+
*
|
|
59
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
60
|
+
*/
|
|
61
|
+
export declare function createAgentTeamConversationWorkspaceDirectoryName(messageFileName: string): string;
|
|
62
|
+
/**
|
|
63
|
+
* Creates the relative active workspace path for one queued message.
|
|
64
|
+
*
|
|
65
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
66
|
+
*/
|
|
67
|
+
export declare function createAgentTeamConversationWorkspacePath(messageFileName: string): string;
|
|
68
|
+
/**
|
|
69
|
+
* Creates the relative completed-workspace path for one queued message.
|
|
70
|
+
*
|
|
71
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
72
|
+
*/
|
|
73
|
+
export declare function createFinishedAgentTeamConversationWorkspacePath(messageFileName: string): string;
|
|
74
|
+
/**
|
|
75
|
+
* Creates the source-snapshot file name for one teammate.
|
|
76
|
+
*
|
|
77
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
78
|
+
*/
|
|
79
|
+
export declare function createAgentTeamTeammateSourceFileName(teammatePermanentId: string): string;
|
|
80
|
+
/**
|
|
81
|
+
* Checks whether unknown JSON has the minimum shape required for a TEAM workspace manifest.
|
|
82
|
+
*
|
|
83
|
+
* @private internal convention shared by the Agents Server and agent-folder runner
|
|
84
|
+
*/
|
|
85
|
+
export declare function isAgentTeamConversationWorkspaceManifest(value: unknown): value is AgentTeamConversationWorkspaceManifest;
|