@promptbook/cli 0.114.0-3 → 0.114.0-5
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 +4 -12
- package/apps/agents-server/{USE_TIMEOUT_CHIP_QA.md → TIMEOUT_CHIP_QA.md} +1 -1
- package/apps/agents-server/src/app/agents/[agentName]/api/chat/resolveAgentChatRouteContext.ts +5 -12
- package/apps/agents-server/src/app/agents/[agentName]/api/voice/route.ts +4 -9
- package/apps/agents-server/src/app/api/scrape/route.ts +1 -1
- package/apps/agents-server/src/app/layout.tsx +25 -0
- package/apps/agents-server/src/app/system/user-wallet/UserWalletDraft.ts +2 -2
- package/apps/agents-server/src/components/AgentProfile/AgentCapabilityChips.tsx +1 -24
- package/apps/agents-server/src/components/Header/Header.tsx +8 -0
- package/apps/agents-server/src/components/Header/HeaderTypes.ts +5 -0
- package/apps/agents-server/src/components/Header/buildHeaderSystemMenuItems.ts +118 -30
- package/apps/agents-server/src/components/Header/resolveHeaderSystemActivities.ts +86 -0
- package/apps/agents-server/src/components/Homepage/AgentCard.tsx +0 -3
- package/apps/agents-server/src/components/LayoutWrapper/LayoutWrapper.tsx +8 -0
- package/apps/agents-server/src/components/NewAgentDialog/NewAgentWizardState.ts +0 -12
- package/apps/agents-server/src/components/NewAgentDialog/NewAgentWizardUseSetupStep.tsx +0 -58
- package/apps/agents-server/src/components/NewAgentDialog/newAgentWizardPresets.ts +0 -56
- package/apps/agents-server/src/components/WalletRecordDialog/useWalletRecordDialogState.ts +1 -1
- package/apps/agents-server/src/languages/ServerTranslationKeys.ts +0 -10
- package/apps/agents-server/src/languages/translations/czech.yaml +0 -10
- package/apps/agents-server/src/languages/translations/english.yaml +0 -10
- package/apps/agents-server/src/message-providers/email/smtp/SmtpMessageProvider.ts +1 -1
- package/apps/agents-server/src/tools/$provideOpenAiAgentKitExecutionToolsForServer.ts +0 -191
- package/apps/agents-server/src/tools/$provideOpenAiAssistantExecutionToolsForServer.ts +0 -3
- package/apps/agents-server/src/tools/run_browser.ts +1 -1
- package/apps/agents-server/src/tools/send_email.ts +3 -3
- package/apps/agents-server/src/utils/handleChatCompletion/createHandleChatCompletionPromptContext.ts +0 -1
- package/apps/agents-server/src/utils/handleChatCompletion/resolveHandleChatCompletionRuntime.ts +4 -12
- package/apps/agents-server/src/utils/manGoOnboarding/manGoOnboardingAgentBooks.ts +0 -1
- package/apps/agents-server/src/utils/messages/parseUseEmailSmtpCredential.ts +1 -1
- package/apps/agents-server/src/utils/resolveUseEmailSmtpCredential.ts +1 -1
- package/apps/agents-server/src/utils/useEmailSmtpWalletConstants.ts +5 -5
- package/apps/agents-server/src/utils/userChat/createRunUserChatJobExecutionContext.ts +5 -12
- package/apps/agents-server/src/utils/userWallet/UserWalletRecord.ts +1 -1
- package/apps/agents-server/src/utils/userWallet/resolveUseEmailSmtpCredentialFromWallet.ts +1 -1
- package/apps/agents-server/src/utils/vpsSelfUpdate/deleteVpsSelfUpdateInstalledVersion.ts +2 -1
- package/apps/agents-server/src/utils/vpsSelfUpdate/isVpsSelfUpdateJobRunning.ts +16 -0
- package/apps/agents-server/src/utils/vpsSelfUpdate/startVpsSelfUpdate.ts +2 -1
- package/apps/agents-server/src/utils/vpsSelfUpdate.ts +1 -0
- package/esm/index.es.js +2885 -6344
- package/esm/index.es.js.map +1 -1
- package/esm/scripts/run-codex-prompts/common/createCoderRunStepTracker.d.ts +48 -0
- package/esm/scripts/run-codex-prompts/prompts/buildPromptStatusDetails.d.ts +43 -0
- package/esm/scripts/run-codex-prompts/prompts/formatCoderRunSteps.d.ts +6 -3
- package/esm/scripts/run-codex-prompts/prompts/isPromptSectionUnfinished.d.ts +8 -0
- package/esm/scripts/run-codex-prompts/prompts/markPromptDone.d.ts +1 -1
- package/esm/scripts/run-codex-prompts/prompts/markPromptInProgress.d.ts +27 -0
- package/esm/scripts/run-codex-prompts/prompts/resolvePromptStatusLine.d.ts +19 -0
- package/esm/scripts/run-codex-prompts/prompts/writePromptStatusLine.d.ts +9 -0
- package/esm/scripts/run-codex-prompts/server/buildCoderServerPromptResponse.d.ts +1 -1
- package/esm/scripts/run-codex-prompts/server/coderServerHtml.d.ts +1 -1
- package/esm/scripts/run-codex-prompts/server/updatePromptSection.d.ts +1 -1
- package/esm/scripts/run-codex-prompts/testing/runPromptWithTestFeedback.d.ts +6 -0
- package/esm/scripts/verify-prompts/$orderPromptFiles.d.ts +9 -0
- package/esm/scripts/verify-prompts/VerifyPromptsOrder.d.ts +26 -0
- package/esm/scripts/verify-prompts/verify-prompts.d.ts +3 -2
- package/esm/src/book-2.0/agent-source/AgentBasicInformation.d.ts +3 -3
- package/esm/src/cli/cli-commands/coder/boilerplateCount.d.ts +52 -0
- package/esm/src/cli/cli-commands/coder/generate-boilerplates.d.ts +3 -2
- package/esm/src/cli/cli-commands/coder/verify.d.ts +1 -1
- package/esm/src/commitments/{COMPONENT/COMPONENT.d.ts → META_FULLNAME/META_FULLNAME.d.ts} +8 -5
- package/esm/src/commitments/META_ID/META_ID.d.ts +32 -0
- package/esm/src/commitments/index.d.ts +4 -12
- package/esm/src/llm-providers/agent/Agent.d.ts +1 -1
- package/esm/src/llm-providers/openai/OpenAiAgentKitExecutionToolsToolBuilder.d.ts +1 -1
- package/esm/src/{commitments/USE_BROWSER → scrapers/_common/utils}/fetchUrlContent.d.ts +2 -3
- package/esm/src/version.d.ts +1 -1
- package/package.json +1 -1
- package/src/_packages/components.readme.md +1 -1
- package/src/book-2.0/agent-source/AgentBasicInformation.ts +3 -9
- package/src/book-2.0/agent-source/createAgentModelRequirementsWithCommitments/filterCommitmentsForAgentModelRequirements.ts +0 -23
- package/src/book-2.0/agent-source/createAgentModelRequirementsWithCommitments.ts +0 -2
- package/src/book-2.0/agent-source/parseAgentSource/applyMetaCommitment.ts +16 -31
- package/src/book-2.0/agent-source/parseAgentSource/createCapabilitiesFromCommitment.ts +0 -35
- package/src/book-2.0/book-language-documentation/bookLanguageDocumentationExamples.ts +0 -25
- package/src/book-2.0/book-language-documentation/createStandaloneBookLanguageMarkdown.ts +2 -10
- package/src/book-2.0/book-language-documentation/czechBookLanguageManualDictionary.ts +7 -32
- package/src/book-2.0/book-language-documentation/englishBookLanguageManualDictionary.ts +6 -31
- package/src/book-components/BookEditor/useBookEditorMonacoLanguage.ts +1 -1
- package/src/cli/cli-commands/coder/boilerplateCount.ts +139 -0
- package/src/cli/cli-commands/coder/generate-boilerplates.ts +52 -44
- package/src/cli/cli-commands/coder/getDefaultCoderPackageJsonScripts.ts +3 -1
- package/src/cli/cli-commands/coder/init.ts +2 -1
- package/src/cli/cli-commands/coder/verify.ts +29 -5
- package/src/commitments/ACTION/ACTION.ts +3 -3
- package/src/commitments/{META → META_DESCRIPTION}/META_DESCRIPTION.ts +1 -1
- package/src/commitments/META_FULLNAME/META_FULLNAME.ts +70 -0
- package/src/commitments/META_ID/META_ID.ts +78 -0
- package/src/commitments/_common/getAllCommitmentsToolFunctionsForNode.ts +1 -49
- package/src/commitments/index.ts +6 -24
- package/src/llm-providers/agent/Agent.ts +1 -1
- package/src/llm-providers/openai/OpenAiAgentKitExecutionToolsToolBuilder.ts +2 -2
- package/src/other/templates/getTemplatesPipelineCollection.ts +735 -693
- package/src/{commitments/USE_BROWSER → scrapers/_common/utils}/fetchUrlContent.ts +8 -9
- package/src/version.ts +2 -2
- package/src/versions.txt +2 -0
- package/umd/index.umd.js +2888 -6347
- package/umd/index.umd.js.map +1 -1
- package/umd/scripts/run-codex-prompts/common/createCoderRunStepTracker.d.ts +48 -0
- package/umd/scripts/run-codex-prompts/prompts/buildPromptStatusDetails.d.ts +43 -0
- package/umd/scripts/run-codex-prompts/prompts/formatCoderRunSteps.d.ts +6 -3
- package/umd/scripts/run-codex-prompts/prompts/isPromptSectionUnfinished.d.ts +8 -0
- package/umd/scripts/run-codex-prompts/prompts/markPromptDone.d.ts +1 -1
- package/umd/scripts/run-codex-prompts/prompts/markPromptInProgress.d.ts +27 -0
- package/umd/scripts/run-codex-prompts/prompts/resolvePromptStatusLine.d.ts +19 -0
- package/umd/scripts/run-codex-prompts/prompts/writePromptStatusLine.d.ts +9 -0
- package/umd/scripts/run-codex-prompts/server/buildCoderServerPromptResponse.d.ts +1 -1
- package/umd/scripts/run-codex-prompts/server/coderServerHtml.d.ts +1 -1
- package/umd/scripts/run-codex-prompts/server/updatePromptSection.d.ts +1 -1
- package/umd/scripts/run-codex-prompts/testing/runPromptWithTestFeedback.d.ts +6 -0
- package/umd/scripts/verify-prompts/$orderPromptFiles.d.ts +9 -0
- package/umd/scripts/verify-prompts/VerifyPromptsOrder.d.ts +26 -0
- package/umd/scripts/verify-prompts/verify-prompts.d.ts +3 -2
- package/umd/src/book-2.0/agent-source/AgentBasicInformation.d.ts +3 -3
- package/umd/src/cli/cli-commands/coder/boilerplateCount.d.ts +52 -0
- package/umd/src/cli/cli-commands/coder/generate-boilerplates.d.ts +3 -2
- package/umd/src/cli/cli-commands/coder/verify.d.ts +1 -1
- package/umd/src/commitments/{COMPONENT/COMPONENT.d.ts → META_FULLNAME/META_FULLNAME.d.ts} +8 -5
- package/umd/src/commitments/META_ID/META_ID.d.ts +32 -0
- package/umd/src/commitments/index.d.ts +4 -12
- package/umd/src/llm-providers/agent/Agent.d.ts +1 -1
- package/umd/src/llm-providers/openai/OpenAiAgentKitExecutionToolsToolBuilder.d.ts +1 -1
- package/umd/src/{commitments/USE_BROWSER → scrapers/_common/utils}/fetchUrlContent.d.ts +2 -3
- package/umd/src/version.d.ts +1 -1
- package/apps/agents-server/src/tools/configureTimeoutToolRuntimeAdapterForServer.ts +0 -381
- package/apps/agents-server/src/utils/emails/extractUseEmailConfigurationFromAgentSource.ts +0 -42
- package/esm/scripts/run-codex-prompts/prompts/replacePromptTodoStatusLine.d.ts +0 -7
- package/esm/src/commitments/MEMORY/MEMORY.d.ts +0 -48
- package/esm/src/commitments/MEMORY/MemoryToolNames.d.ts +0 -11
- package/esm/src/commitments/MEMORY/MemoryToolRuntimeAdapter.d.ts +0 -149
- package/esm/src/commitments/MEMORY/createMemorySystemMessage.d.ts +0 -6
- package/esm/src/commitments/MEMORY/createMemoryToolFunctions.d.ts +0 -8
- package/esm/src/commitments/MEMORY/createMemoryTools.d.ts +0 -14
- package/esm/src/commitments/MEMORY/getMemoryCommitmentDocumentation.d.ts +0 -6
- package/esm/src/commitments/MEMORY/getMemoryToolRuntimeAdapterOrDisabledResult.d.ts +0 -17
- package/esm/src/commitments/MEMORY/getMemoryToolTitles.d.ts +0 -7
- package/esm/src/commitments/MEMORY/parseMemoryToolArgs.d.ts +0 -61
- package/esm/src/commitments/MEMORY/resolveMemoryRuntimeContext.d.ts +0 -8
- package/esm/src/commitments/MEMORY/setMemoryToolRuntimeAdapter.d.ts +0 -13
- package/esm/src/commitments/META/META.d.ts +0 -65
- package/esm/src/commitments/USE/aggregateUseCommitmentSystemMessages.d.ts +0 -32
- package/esm/src/commitments/USE_BROWSER/USE_BROWSER.d.ts +0 -58
- package/esm/src/commitments/USE_BROWSER/fetchUrlContentViaBrowser.d.ts +0 -13
- package/esm/src/commitments/USE_BROWSER/resolveRunBrowserToolForNode.d.ts +0 -10
- package/esm/src/commitments/USE_DEEPSEARCH/USE_DEEPSEARCH.d.ts +0 -47
- package/esm/src/commitments/USE_EMAIL/USE_EMAIL.d.ts +0 -38
- package/esm/src/commitments/USE_EMAIL/parseUseEmailCommitmentContent.d.ts +0 -21
- package/esm/src/commitments/USE_EMAIL/parseUseEmailCommitmentContent.test.d.ts +0 -1
- package/esm/src/commitments/USE_EMAIL/resolveSendEmailToolForNode.d.ts +0 -11
- package/esm/src/commitments/USE_EMAIL/sendEmailViaBrowser.d.ts +0 -13
- package/esm/src/commitments/USE_SEARCH_ENGINE/USE_SEARCH_ENGINE.d.ts +0 -46
- package/esm/src/commitments/USE_SEARCH_ENGINE/USE_SEARCH_ENGINE.test.d.ts +0 -1
- package/esm/src/commitments/USE_SPAWN/USE_SPAWN.d.ts +0 -38
- package/esm/src/commitments/USE_SPAWN/USE_SPAWN.test.d.ts +0 -1
- package/esm/src/commitments/USE_SPAWN/resolveSpawnAgentToolForNode.d.ts +0 -9
- package/esm/src/commitments/USE_SPAWN/spawnAgentViaBrowser.d.ts +0 -12
- package/esm/src/commitments/USE_TIME/USE_TIME.d.ts +0 -43
- package/esm/src/commitments/USE_TIME/USE_TIME.test.d.ts +0 -1
- package/esm/src/commitments/USE_TIMEOUT/TimeoutToolNames.d.ts +0 -11
- package/esm/src/commitments/USE_TIMEOUT/TimeoutToolRuntimeAdapter.d.ts +0 -212
- package/esm/src/commitments/USE_TIMEOUT/USE_TIMEOUT.d.ts +0 -38
- package/esm/src/commitments/USE_TIMEOUT/USE_TIMEOUT.test.d.ts +0 -1
- package/esm/src/commitments/USE_TIMEOUT/createTimeoutSystemMessage.d.ts +0 -6
- package/esm/src/commitments/USE_TIMEOUT/createTimeoutToolFunctions.d.ts +0 -8
- package/esm/src/commitments/USE_TIMEOUT/createTimeoutTools.d.ts +0 -7
- package/esm/src/commitments/USE_TIMEOUT/getTimeoutToolRuntimeAdapterOrDisabledResult.d.ts +0 -17
- package/esm/src/commitments/USE_TIMEOUT/parseTimeoutToolArgs.d.ts +0 -78
- package/esm/src/commitments/USE_TIMEOUT/resolveTimeoutRuntimeContext.d.ts +0 -8
- package/esm/src/commitments/USE_TIMEOUT/setTimeoutToolRuntimeAdapter.d.ts +0 -13
- package/esm/src/commitments/WALLET/WALLET.d.ts +0 -21
- package/esm/src/commitments/WALLET/WALLET.test.d.ts +0 -1
- package/esm/src/commitments/WALLET/WalletToolNames.d.ts +0 -12
- package/esm/src/commitments/WALLET/WalletToolRuntimeAdapter.d.ts +0 -163
- package/esm/src/commitments/WALLET/createWalletSystemMessage.d.ts +0 -6
- package/esm/src/commitments/WALLET/createWalletToolFunctions.d.ts +0 -8
- package/esm/src/commitments/WALLET/createWalletTools.d.ts +0 -7
- package/esm/src/commitments/WALLET/getWalletCommitmentDocumentation.d.ts +0 -6
- package/esm/src/commitments/WALLET/getWalletToolRuntimeAdapterOrDisabledResult.d.ts +0 -16
- package/esm/src/commitments/WALLET/getWalletToolTitles.d.ts +0 -7
- package/esm/src/commitments/WALLET/parseWalletToolArgs.d.ts +0 -51
- package/esm/src/commitments/WALLET/resolveWalletRuntimeContext.d.ts +0 -8
- package/esm/src/commitments/WALLET/setWalletToolRuntimeAdapter.d.ts +0 -13
- package/esm/src/commitments/_common/createSerpSearchToolFunction.d.ts +0 -12
- package/src/commitments/COMPONENT/COMPONENT.ts +0 -70
- package/src/commitments/MEMORY/MEMORY.ts +0 -94
- package/src/commitments/MEMORY/MemoryToolNames.ts +0 -13
- package/src/commitments/MEMORY/MemoryToolRuntimeAdapter.ts +0 -180
- package/src/commitments/MEMORY/createMemorySystemMessage.ts +0 -27
- package/src/commitments/MEMORY/createMemoryToolFunctions.ts +0 -134
- package/src/commitments/MEMORY/createMemoryTools.ts +0 -115
- package/src/commitments/MEMORY/getMemoryCommitmentDocumentation.ts +0 -47
- package/src/commitments/MEMORY/getMemoryToolRuntimeAdapterOrDisabledResult.ts +0 -104
- package/src/commitments/MEMORY/getMemoryToolTitles.ts +0 -16
- package/src/commitments/MEMORY/parseMemoryToolArgs.ts +0 -126
- package/src/commitments/MEMORY/resolveMemoryRuntimeContext.ts +0 -23
- package/src/commitments/MEMORY/setMemoryToolRuntimeAdapter.ts +0 -26
- package/src/commitments/META/META.ts +0 -168
- package/src/commitments/USE/TODO.txt +0 -1
- package/src/commitments/USE/aggregateUseCommitmentSystemMessages.ts +0 -219
- package/src/commitments/USE_BROWSER/TODO.txt +0 -1
- package/src/commitments/USE_BROWSER/USE_BROWSER.ts +0 -257
- package/src/commitments/USE_BROWSER/fetchUrlContentViaBrowser.ts +0 -45
- package/src/commitments/USE_BROWSER/resolveRunBrowserToolForNode.ts +0 -83
- package/src/commitments/USE_DEEPSEARCH/USE_DEEPSEARCH.ts +0 -146
- package/src/commitments/USE_EMAIL/USE_EMAIL.ts +0 -201
- package/src/commitments/USE_EMAIL/parseUseEmailCommitmentContent.ts +0 -75
- package/src/commitments/USE_EMAIL/resolveSendEmailToolForNode.ts +0 -44
- package/src/commitments/USE_EMAIL/sendEmailViaBrowser.ts +0 -47
- package/src/commitments/USE_SEARCH_ENGINE/TODO.txt +0 -1
- package/src/commitments/USE_SEARCH_ENGINE/USE_SEARCH_ENGINE.ts +0 -171
- package/src/commitments/USE_SPAWN/USE_SPAWN.ts +0 -150
- package/src/commitments/USE_SPAWN/resolveSpawnAgentToolForNode.ts +0 -42
- package/src/commitments/USE_SPAWN/spawnAgentViaBrowser.ts +0 -50
- package/src/commitments/USE_TIME/USE_TIME.ts +0 -177
- package/src/commitments/USE_TIMEOUT/TimeoutToolNames.ts +0 -13
- package/src/commitments/USE_TIMEOUT/TimeoutToolRuntimeAdapter.ts +0 -255
- package/src/commitments/USE_TIMEOUT/USE_TIMEOUT.ts +0 -117
- package/src/commitments/USE_TIMEOUT/createTimeoutSystemMessage.ts +0 -22
- package/src/commitments/USE_TIMEOUT/createTimeoutToolFunctions.ts +0 -361
- package/src/commitments/USE_TIMEOUT/createTimeoutTools.ts +0 -127
- package/src/commitments/USE_TIMEOUT/getTimeoutToolRuntimeAdapterOrDisabledResult.ts +0 -67
- package/src/commitments/USE_TIMEOUT/parseTimeoutToolArgs.ts +0 -460
- package/src/commitments/USE_TIMEOUT/resolveTimeoutRuntimeContext.ts +0 -36
- package/src/commitments/USE_TIMEOUT/setTimeoutToolRuntimeAdapter.ts +0 -26
- package/src/commitments/WALLET/WALLET.ts +0 -71
- package/src/commitments/WALLET/WalletToolNames.ts +0 -14
- package/src/commitments/WALLET/WalletToolRuntimeAdapter.ts +0 -180
- package/src/commitments/WALLET/createWalletSystemMessage.ts +0 -22
- package/src/commitments/WALLET/createWalletToolFunctions.ts +0 -145
- package/src/commitments/WALLET/createWalletTools.ts +0 -129
- package/src/commitments/WALLET/getWalletCommitmentDocumentation.ts +0 -14
- package/src/commitments/WALLET/getWalletToolRuntimeAdapterOrDisabledResult.ts +0 -64
- package/src/commitments/WALLET/getWalletToolTitles.ts +0 -17
- package/src/commitments/WALLET/parseWalletToolArgs.ts +0 -231
- package/src/commitments/WALLET/resolveWalletRuntimeContext.ts +0 -23
- package/src/commitments/WALLET/setWalletToolRuntimeAdapter.ts +0 -26
- package/src/commitments/_common/createSerpSearchToolFunction.ts +0 -46
- package/umd/scripts/run-codex-prompts/prompts/replacePromptTodoStatusLine.d.ts +0 -7
- package/umd/src/book-2.0/agent-source/createAgentModelRequirements.useCommitmentAggregation.test.d.ts +0 -1
- package/umd/src/commitments/MEMORY/MEMORY.d.ts +0 -48
- package/umd/src/commitments/MEMORY/MEMORY.test.d.ts +0 -1
- package/umd/src/commitments/MEMORY/MemoryToolNames.d.ts +0 -11
- package/umd/src/commitments/MEMORY/MemoryToolRuntimeAdapter.d.ts +0 -149
- package/umd/src/commitments/MEMORY/createMemorySystemMessage.d.ts +0 -6
- package/umd/src/commitments/MEMORY/createMemoryToolFunctions.d.ts +0 -8
- package/umd/src/commitments/MEMORY/createMemoryTools.d.ts +0 -14
- package/umd/src/commitments/MEMORY/getMemoryCommitmentDocumentation.d.ts +0 -6
- package/umd/src/commitments/MEMORY/getMemoryToolRuntimeAdapterOrDisabledResult.d.ts +0 -17
- package/umd/src/commitments/MEMORY/getMemoryToolTitles.d.ts +0 -7
- package/umd/src/commitments/MEMORY/parseMemoryToolArgs.d.ts +0 -61
- package/umd/src/commitments/MEMORY/resolveMemoryRuntimeContext.d.ts +0 -8
- package/umd/src/commitments/MEMORY/setMemoryToolRuntimeAdapter.d.ts +0 -13
- package/umd/src/commitments/META/META.d.ts +0 -65
- package/umd/src/commitments/USE/aggregateUseCommitmentSystemMessages.d.ts +0 -32
- package/umd/src/commitments/USE_BROWSER/USE_BROWSER.d.ts +0 -58
- package/umd/src/commitments/USE_BROWSER/USE_BROWSER.test.d.ts +0 -1
- package/umd/src/commitments/USE_BROWSER/fetchUrlContentViaBrowser.d.ts +0 -13
- package/umd/src/commitments/USE_BROWSER/resolveRunBrowserToolForNode.d.ts +0 -10
- package/umd/src/commitments/USE_BROWSER/resolveRunBrowserToolForNode.test.d.ts +0 -1
- package/umd/src/commitments/USE_DEEPSEARCH/USE_DEEPSEARCH.d.ts +0 -47
- package/umd/src/commitments/USE_DEEPSEARCH/USE_DEEPSEARCH.test.d.ts +0 -1
- package/umd/src/commitments/USE_EMAIL/USE_EMAIL.d.ts +0 -38
- package/umd/src/commitments/USE_EMAIL/USE_EMAIL.test.d.ts +0 -1
- package/umd/src/commitments/USE_EMAIL/parseUseEmailCommitmentContent.d.ts +0 -21
- package/umd/src/commitments/USE_EMAIL/parseUseEmailCommitmentContent.test.d.ts +0 -1
- package/umd/src/commitments/USE_EMAIL/resolveSendEmailToolForNode.d.ts +0 -11
- package/umd/src/commitments/USE_EMAIL/sendEmailViaBrowser.d.ts +0 -13
- package/umd/src/commitments/USE_SEARCH_ENGINE/USE_SEARCH_ENGINE.d.ts +0 -46
- package/umd/src/commitments/USE_SEARCH_ENGINE/USE_SEARCH_ENGINE.test.d.ts +0 -1
- package/umd/src/commitments/USE_SPAWN/USE_SPAWN.d.ts +0 -38
- package/umd/src/commitments/USE_SPAWN/USE_SPAWN.test.d.ts +0 -1
- package/umd/src/commitments/USE_SPAWN/resolveSpawnAgentToolForNode.d.ts +0 -9
- package/umd/src/commitments/USE_SPAWN/spawnAgentViaBrowser.d.ts +0 -12
- package/umd/src/commitments/USE_TIME/USE_TIME.d.ts +0 -43
- package/umd/src/commitments/USE_TIME/USE_TIME.test.d.ts +0 -1
- package/umd/src/commitments/USE_TIMEOUT/TimeoutToolNames.d.ts +0 -11
- package/umd/src/commitments/USE_TIMEOUT/TimeoutToolRuntimeAdapter.d.ts +0 -212
- package/umd/src/commitments/USE_TIMEOUT/USE_TIMEOUT.d.ts +0 -38
- package/umd/src/commitments/USE_TIMEOUT/USE_TIMEOUT.test.d.ts +0 -1
- package/umd/src/commitments/USE_TIMEOUT/createTimeoutSystemMessage.d.ts +0 -6
- package/umd/src/commitments/USE_TIMEOUT/createTimeoutToolFunctions.d.ts +0 -8
- package/umd/src/commitments/USE_TIMEOUT/createTimeoutTools.d.ts +0 -7
- package/umd/src/commitments/USE_TIMEOUT/getTimeoutToolRuntimeAdapterOrDisabledResult.d.ts +0 -17
- package/umd/src/commitments/USE_TIMEOUT/parseTimeoutToolArgs.d.ts +0 -78
- package/umd/src/commitments/USE_TIMEOUT/resolveTimeoutRuntimeContext.d.ts +0 -8
- package/umd/src/commitments/USE_TIMEOUT/setTimeoutToolRuntimeAdapter.d.ts +0 -13
- package/umd/src/commitments/WALLET/WALLET.d.ts +0 -21
- package/umd/src/commitments/WALLET/WALLET.test.d.ts +0 -1
- package/umd/src/commitments/WALLET/WalletToolNames.d.ts +0 -12
- package/umd/src/commitments/WALLET/WalletToolRuntimeAdapter.d.ts +0 -163
- package/umd/src/commitments/WALLET/createWalletSystemMessage.d.ts +0 -6
- package/umd/src/commitments/WALLET/createWalletToolFunctions.d.ts +0 -8
- package/umd/src/commitments/WALLET/createWalletTools.d.ts +0 -7
- package/umd/src/commitments/WALLET/getWalletCommitmentDocumentation.d.ts +0 -6
- package/umd/src/commitments/WALLET/getWalletToolRuntimeAdapterOrDisabledResult.d.ts +0 -16
- package/umd/src/commitments/WALLET/getWalletToolTitles.d.ts +0 -7
- package/umd/src/commitments/WALLET/parseWalletToolArgs.d.ts +0 -51
- package/umd/src/commitments/WALLET/resolveWalletRuntimeContext.d.ts +0 -8
- package/umd/src/commitments/WALLET/setWalletToolRuntimeAdapter.d.ts +0 -13
- package/umd/src/commitments/_common/createSerpSearchToolFunction.d.ts +0 -12
- /package/esm/src/book-2.0/agent-source/{createAgentModelRequirements.useCommitmentAggregation.test.d.ts → createAgentModelRequirements.commitmentAggregation.test.d.ts} +0 -0
- /package/esm/src/{commitments/MEMORY/MEMORY.test.d.ts → cli/cli-commands/coder/boilerplateCount.test.d.ts} +0 -0
- /package/esm/src/{commitments/USE_BROWSER/USE_BROWSER.test.d.ts → cli/cli-commands/coder/generate-boilerplates.test.d.ts} +0 -0
- /package/esm/src/commitments/{META → META_DESCRIPTION}/META_DESCRIPTION.d.ts +0 -0
- /package/{esm/src/commitments/USE_BROWSER/resolveRunBrowserToolForNode.test.d.ts → umd/src/book-2.0/agent-source/createAgentModelRequirements.commitmentAggregation.test.d.ts} +0 -0
- /package/{esm/src/commitments/USE_DEEPSEARCH/USE_DEEPSEARCH.test.d.ts → umd/src/cli/cli-commands/coder/boilerplateCount.test.d.ts} +0 -0
- /package/{esm/src/commitments/USE_EMAIL/USE_EMAIL.test.d.ts → umd/src/cli/cli-commands/coder/generate-boilerplates.test.d.ts} +0 -0
- /package/umd/src/commitments/{META → META_DESCRIPTION}/META_DESCRIPTION.d.ts +0 -0
package/README.md
CHANGED
|
@@ -215,8 +215,6 @@ Respond to incoming legal inquiries via email and keep the company website updat
|
|
|
215
215
|
**KNOWLEDGE** https://company.com/company-policies.pdf<br/>
|
|
216
216
|
**KNOWLEDGE** https://company.com/internal-documents/employee-handbook.docx<br/>
|
|
217
217
|
<br/>
|
|
218
|
-
USE EMAIL<br/>
|
|
219
|
-
USE BROWSER<br/>
|
|
220
218
|
<br/>
|
|
221
219
|
TEAM You are part of the legal team of Paul Smith & Associés, you discuss with {Emily White}, the head of the compliance department. {George Brown} is expert in corporate law and {Sophia Black} is expert in labor law.<br/>
|
|
222
220
|
|
|
@@ -305,7 +303,7 @@ GOAL Keep the company website updated with the latest legal policies and complia
|
|
|
305
303
|
|
|
306
304
|
#### `Use` commitments
|
|
307
305
|
|
|
308
|
-
Use commitments grant the agent real capabilities - tools it can use to interact with the outside world. `USE
|
|
306
|
+
Use commitments grant the agent real capabilities - tools it can use to interact with the outside world. `USE CALENDAR` lets the agent work with a calendar, `USE PROJECT` gives it access to a code repository, `USE MCP` connects any external Model Context Protocol server, and many more.
|
|
309
307
|
|
|
310
308
|
These are what turn a chatbot into a persistent agent that actually does work.
|
|
311
309
|
|
|
@@ -322,9 +320,6 @@ GOAL Keep the company website updated with the latest legal policies and complia
|
|
|
322
320
|
**RULE** Never provide legal advice about criminal law.<br/>
|
|
323
321
|
**KNOWLEDGE** https://company.com/company-policies.pdf<br/>
|
|
324
322
|
**KNOWLEDGE** https://company.com/internal-documents/employee-handbook.docx<br/>
|
|
325
|
-
USE EMAIL<br/>
|
|
326
|
-
USE BROWSER<br/>
|
|
327
|
-
USE SEARCH ENGINE<br/>
|
|
328
323
|
|
|
329
324
|
</td></tr></table>
|
|
330
325
|
|
|
@@ -345,9 +340,6 @@ GOAL Keep the company website updated with the latest legal policies and complia
|
|
|
345
340
|
**RULE** Never provide legal advice about criminal law.<br/>
|
|
346
341
|
**KNOWLEDGE** https://company.com/company-policies.pdf<br/>
|
|
347
342
|
**KNOWLEDGE** https://company.com/internal-documents/employee-handbook.docx<br/>
|
|
348
|
-
USE EMAIL<br/>
|
|
349
|
-
USE BROWSER<br/>
|
|
350
|
-
USE SEARCH ENGINE<br/>
|
|
351
343
|
TEAM You are part of the legal team of Paul Smith & Associés, you discuss with {Emily White}, the head of the compliance department. {George Brown} is expert in corporate law and {Sophia Black} is expert in labor law.<br/>
|
|
352
344
|
|
|
353
345
|
</td></tr></table>
|
|
@@ -534,7 +526,7 @@ Or you can install them separately:
|
|
|
534
526
|
|
|
535
527
|
Promptbook Coder is **not another standalone coding model**. It is an orchestration layer over coding agents such as **GitHub Copilot**, **OpenAI Codex**, **Claude Code**, **Opencode**, **Cline**, and **Gemini CLI**. The difference is that Promptbook Coder adds a repeatable repository workflow on top of them:
|
|
536
528
|
|
|
537
|
-
- prompt files with explicit statuses like `[ ]`, `[x]`, and `[-]`
|
|
529
|
+
- prompt files with explicit statuses like `[ ]`, `[^]`, `[x]`, and `[-]`
|
|
538
530
|
- automatic selection of the next runnable task, including priority support
|
|
539
531
|
- optional shared repo context loaded from a file such as `AGENTS.md`
|
|
540
532
|
- automatic `git add`, commit, and push after each successful prompt
|
|
@@ -549,11 +541,11 @@ In short: tools like Claude Code, Codex, or GitHub Copilot are the **engines**;
|
|
|
549
541
|
1. `ptbk coder init` prepares the project for the coder workflow, seeds project-owned generic templates in `prompts/templates/`, creates a starter `AGENTS.md` context file, adds helper `npm run coder:*` scripts, ensures `.gitignore` ignores `/.promptbook`, and configures VS Code prompt screenshots in `prompts/screenshots/`.
|
|
550
542
|
2. `ptbk coder generate-boilerplates` creates prompt files in `prompts/`.
|
|
551
543
|
3. You replace placeholder `@@@` sections with real coding tasks.
|
|
552
|
-
4. `ptbk coder run` sends the next ready `[ ]` prompt to the selected coding agent.
|
|
544
|
+
4. `ptbk coder run` sends the next ready `[ ]` prompt to the selected coding agent and immediately marks it as in progress `[^]`, naming the harness, the model and the step which is running.
|
|
553
545
|
5. Promptbook Coder marks the prompt as done `[x]`, records runner metadata, then stages, commits, and pushes the resulting changes.
|
|
554
546
|
6. `ptbk coder verify` reviews completed prompts, archives finished files to `prompts/done/`, and appends a repair prompt when more work is needed.
|
|
555
547
|
|
|
556
|
-
Prompts marked with `[-]` are not ready yet, prompts containing `@@@` are treated as not fully written, and prompts with more `!` markers have higher priority.
|
|
548
|
+
Prompts marked with `[-]` are not ready yet, prompts containing `@@@` are treated as not fully written, and prompts with more `!` markers have higher priority. A prompt left as `[^]` was interrupted in the middle of its implementation — the in-progress status is never reverted, so a killed or crashed coder always leaves that signal behind.
|
|
557
549
|
|
|
558
550
|
#### Features
|
|
559
551
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Timeout Chip QA
|
|
2
2
|
|
|
3
3
|
- Friendly default popup:
|
|
4
4
|
Trigger a `set_timeout` tool call in an agent chat, click the timeout chip under the assistant message, and confirm the first view shows friendly copy (for example `Will retry in ...`) plus local time, relative time, and timezone.
|
package/apps/agents-server/src/app/agents/[agentName]/api/chat/resolveAgentChatRouteContext.ts
CHANGED
|
@@ -25,7 +25,6 @@ import {
|
|
|
25
25
|
} from '@/src/utils/metaDisclaimer';
|
|
26
26
|
import { composePromptParametersWithMemoryContext } from '@/src/utils/memoryRuntimeContext';
|
|
27
27
|
import { extractUseCalendarConnectionsFromAgentSource } from '@/src/utils/calendars/extractUseCalendarConnectionsFromAgentSource';
|
|
28
|
-
import { extractUseEmailConfigurationFromAgentSource } from '@/src/utils/emails/extractUseEmailConfigurationFromAgentSource';
|
|
29
28
|
import { extractProjectRepositoriesFromAgentSource } from '@/src/utils/projects/extractProjectRepositoriesFromAgentSource';
|
|
30
29
|
import { resolveUseCalendarGoogleToken } from '@/src/utils/resolveUseCalendarGoogleToken';
|
|
31
30
|
import { resolveUseEmailSmtpCredential } from '@/src/utils/resolveUseEmailSmtpCredential';
|
|
@@ -141,7 +140,6 @@ export async function resolveAgentChatRouteContext(
|
|
|
141
140
|
const resolvedAgentName = resolvedAgentContext.resolvedAgentName;
|
|
142
141
|
const projectRepositories = extractProjectRepositoriesFromAgentSource(agentSource);
|
|
143
142
|
const calendarConnections = extractUseCalendarConnectionsFromAgentSource(agentSource);
|
|
144
|
-
const useEmailConfiguration = extractUseEmailConfigurationFromAgentSource(agentSource);
|
|
145
143
|
const messageSuffix = resolveMessageSuffixFromAgentSource(agentSource);
|
|
146
144
|
const incomingParameters = normalizeAgentChatIncomingParameters(rawParameters);
|
|
147
145
|
const [preparedAgentModelRequirements, requestIdentities] = await Promise.all([
|
|
@@ -166,7 +164,6 @@ export async function resolveAgentChatRouteContext(
|
|
|
166
164
|
currentUserId: currentUserIdentity?.userId,
|
|
167
165
|
agentId,
|
|
168
166
|
calendarConnections,
|
|
169
|
-
useEmailConfiguration,
|
|
170
167
|
});
|
|
171
168
|
const runtimeTools = createAgentProgressTools(createChatAttachmentTools([], attachments));
|
|
172
169
|
const promptParameters = composePromptParametersWithMemoryContext({
|
|
@@ -178,7 +175,6 @@ export async function resolveAgentChatRouteContext(
|
|
|
178
175
|
projectRepositories,
|
|
179
176
|
projectGithubToken,
|
|
180
177
|
emailSmtpCredential,
|
|
181
|
-
emailFromAddress: useEmailConfiguration.senderEmail,
|
|
182
178
|
calendarGoogleAccessToken,
|
|
183
179
|
calendarConnections,
|
|
184
180
|
chatAttachments: attachments,
|
|
@@ -288,9 +284,8 @@ async function resolveAgentChatCredentials(options: {
|
|
|
288
284
|
currentUserId: number | undefined;
|
|
289
285
|
agentId: string;
|
|
290
286
|
calendarConnections: ReturnType<typeof extractUseCalendarConnectionsFromAgentSource>;
|
|
291
|
-
useEmailConfiguration: ReturnType<typeof extractUseEmailConfigurationFromAgentSource>;
|
|
292
287
|
}): Promise<AgentChatCredentials> {
|
|
293
|
-
const { currentUserId, agentId, calendarConnections
|
|
288
|
+
const { currentUserId, agentId, calendarConnections } = options;
|
|
294
289
|
const [projectGithubToken, calendarGoogleAccessToken, emailSmtpCredential] = await Promise.all([
|
|
295
290
|
resolveUseProjectGithubToken({
|
|
296
291
|
userId: currentUserId,
|
|
@@ -302,12 +297,10 @@ async function resolveAgentChatCredentials(options: {
|
|
|
302
297
|
agentPermanentId: agentId,
|
|
303
298
|
})
|
|
304
299
|
: Promise.resolve(undefined),
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
})
|
|
310
|
-
: Promise.resolve(undefined),
|
|
300
|
+
resolveUseEmailSmtpCredential({
|
|
301
|
+
userId: currentUserId,
|
|
302
|
+
agentPermanentId: agentId,
|
|
303
|
+
}),
|
|
311
304
|
]);
|
|
312
305
|
|
|
313
306
|
return {
|
|
@@ -9,7 +9,6 @@ import {
|
|
|
9
9
|
resolveMetaDisclaimerMarkdownFromAgentSource,
|
|
10
10
|
resolveMetaDisclaimerStatusForUser,
|
|
11
11
|
} from '@/src/utils/metaDisclaimer';
|
|
12
|
-
import { extractUseEmailConfigurationFromAgentSource } from '@/src/utils/emails/extractUseEmailConfigurationFromAgentSource';
|
|
13
12
|
import { extractProjectRepositoriesFromAgentSource } from '@/src/utils/projects/extractProjectRepositoriesFromAgentSource';
|
|
14
13
|
import { extractUseCalendarConnectionsFromAgentSource } from '@/src/utils/calendars/extractUseCalendarConnectionsFromAgentSource';
|
|
15
14
|
import { logCalendarToolCallsActivity } from '@/src/utils/calendars/logCalendarToolCallsActivity';
|
|
@@ -122,7 +121,6 @@ export async function POST(request: Request, { params }: { params: Promise<{ age
|
|
|
122
121
|
const unresolvedAgentSource = resolvedAgentContext.unresolvedAgentSource;
|
|
123
122
|
const projectRepositories = extractProjectRepositoriesFromAgentSource(agentSource);
|
|
124
123
|
const calendarConnections = extractUseCalendarConnectionsFromAgentSource(agentSource);
|
|
125
|
-
const useEmailConfiguration = extractUseEmailConfigurationFromAgentSource(agentSource);
|
|
126
124
|
const projectGithubToken = await resolveUseProjectGithubToken({
|
|
127
125
|
userId: currentUserIdentity?.userId,
|
|
128
126
|
agentPermanentId,
|
|
@@ -134,12 +132,10 @@ export async function POST(request: Request, { params }: { params: Promise<{ age
|
|
|
134
132
|
agentPermanentId,
|
|
135
133
|
})
|
|
136
134
|
: undefined;
|
|
137
|
-
const emailSmtpCredential =
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
})
|
|
142
|
-
: undefined;
|
|
135
|
+
const emailSmtpCredential = await resolveUseEmailSmtpCredential({
|
|
136
|
+
userId: currentUserIdentity?.userId,
|
|
137
|
+
agentPermanentId,
|
|
138
|
+
});
|
|
143
139
|
const disclaimerMarkdown = resolveMetaDisclaimerMarkdownFromAgentSource(agentSource);
|
|
144
140
|
|
|
145
141
|
if (disclaimerMarkdown) {
|
|
@@ -183,7 +179,6 @@ export async function POST(request: Request, { params }: { params: Promise<{ age
|
|
|
183
179
|
projectRepositories,
|
|
184
180
|
projectGithubToken,
|
|
185
181
|
emailSmtpCredential,
|
|
186
|
-
emailFromAddress: useEmailConfiguration.senderEmail,
|
|
187
182
|
calendarGoogleAccessToken,
|
|
188
183
|
calendarConnections,
|
|
189
184
|
localServerUrl,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { serializeError } from '@promptbook-local/utils';
|
|
2
2
|
import { NextRequest, NextResponse } from 'next/server';
|
|
3
|
-
import { fetchUrlContent } from '../../../../../../src/
|
|
3
|
+
import { fetchUrlContent } from '../../../../../../src/scrapers/_common/utils/fetchUrlContent';
|
|
4
4
|
import { assertsError } from '../../../../../../src/errors/assertsError';
|
|
5
5
|
import { getCurrentUser } from '../../../utils/getCurrentUser';
|
|
6
6
|
import { assertSafeUrl } from '../../../utils/assertSafeUrl';
|
|
@@ -73,6 +73,8 @@ import {
|
|
|
73
73
|
readStalwartEmailSnapshot,
|
|
74
74
|
} from '../utils/stalwart/readStalwartEmailSnapshot';
|
|
75
75
|
import { readStalwartConfiguration } from '../utils/stalwart/StalwartConfiguration';
|
|
76
|
+
import { isVpsSelfUpdateJobRunning } from '../utils/vpsSelfUpdate/isVpsSelfUpdateJobRunning';
|
|
77
|
+
import { readVpsSelfUpdateJobSnapshot } from '../utils/vpsSelfUpdate/readPersistedVpsSelfUpdateJob';
|
|
76
78
|
import { readAgentsServerFooterVersion } from '../utils/vpsSelfUpdate/readAgentsServerFooterVersion';
|
|
77
79
|
import '@prisma/studio-core/ui/index.css';
|
|
78
80
|
import './globals.css';
|
|
@@ -280,6 +282,25 @@ async function resolveInternalS3WarningStatus(isGlobalAdmin: boolean): Promise<b
|
|
|
280
282
|
}
|
|
281
283
|
}
|
|
282
284
|
|
|
285
|
+
/**
|
|
286
|
+
* Resolves whether a standalone VPS self-update is running right now.
|
|
287
|
+
*
|
|
288
|
+
* @param isGlobalAdmin - Whether the current viewer may see VPS-wide operational details.
|
|
289
|
+
* @returns `true` when a self-update job is in progress.
|
|
290
|
+
*/
|
|
291
|
+
async function resolveSelfUpdateRunningStatus(isGlobalAdmin: boolean): Promise<boolean> {
|
|
292
|
+
if (!isGlobalAdmin) {
|
|
293
|
+
return false;
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
try {
|
|
297
|
+
return isVpsSelfUpdateJobRunning(await readVpsSelfUpdateJobSnapshot());
|
|
298
|
+
} catch (error) {
|
|
299
|
+
console.error('Failed to resolve self-update running status:', error);
|
|
300
|
+
return false;
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
|
|
283
304
|
/**
|
|
284
305
|
* Generates metadata.
|
|
285
306
|
*/
|
|
@@ -400,6 +421,7 @@ export default async function RootLayout({
|
|
|
400
421
|
const vpsEmailServerWarningPromise = isGlobalAdminPromise.then(resolveVpsEmailServerWarningStatus);
|
|
401
422
|
const serversDnsWarningPromise = isGlobalAdminPromise.then(resolveServersDnsWarningStatus);
|
|
402
423
|
const internalS3WarningPromise = isGlobalAdminPromise.then(resolveInternalS3WarningStatus);
|
|
424
|
+
const selfUpdateRunningPromise = isGlobalAdminPromise.then(resolveSelfUpdateRunningStatus);
|
|
403
425
|
const serverVisibilityPromise = getServerVisibility();
|
|
404
426
|
const agentNamingPromise = getAgentNaming();
|
|
405
427
|
const organizationStatePromise = isAdminPromise.then((isAdmin) =>
|
|
@@ -500,6 +522,7 @@ export default async function RootLayout({
|
|
|
500
522
|
isVpsEmailServerWarningShown,
|
|
501
523
|
isServersDnsWarningShown,
|
|
502
524
|
isInternalS3WarningShown,
|
|
525
|
+
isSelfUpdateRunning,
|
|
503
526
|
] = await Promise.all([
|
|
504
527
|
isAdminPromise,
|
|
505
528
|
isGlobalAdminPromise,
|
|
@@ -526,6 +549,7 @@ export default async function RootLayout({
|
|
|
526
549
|
vpsEmailServerWarningPromise,
|
|
527
550
|
serversDnsWarningPromise,
|
|
528
551
|
internalS3WarningPromise,
|
|
552
|
+
selfUpdateRunningPromise,
|
|
529
553
|
]);
|
|
530
554
|
|
|
531
555
|
const serverName = layoutMetadata.SERVER_NAME || 'Promptbook Agents Server';
|
|
@@ -625,6 +649,7 @@ export default async function RootLayout({
|
|
|
625
649
|
isVpsEmailServerWarningShown={isVpsEmailServerWarningShown}
|
|
626
650
|
isServersDnsWarningShown={isServersDnsWarningShown}
|
|
627
651
|
isInternalS3WarningShown={isInternalS3WarningShown}
|
|
652
|
+
isSelfUpdateRunning={isSelfUpdateRunning}
|
|
628
653
|
isExperimentalPwaAppEnabled={isExperimentalPwaAppEnabled}
|
|
629
654
|
controlPanelOptionAvailability={controlPanelOptionAvailability}
|
|
630
655
|
defaultServerLanguage={serverLanguage}
|
|
@@ -56,7 +56,7 @@ type UserWalletRecordRequestPayload = Omit<CreateUserWalletRecordOptions, 'userI
|
|
|
56
56
|
const USE_EMAIL_SMTP_WALLET_SCHEMA_TEXT = formatWalletJsonSchemaForTextarea(USE_EMAIL_SMTP_WALLET_SECRET_JSON_SCHEMA);
|
|
57
57
|
|
|
58
58
|
/**
|
|
59
|
-
* Returns true when record identity matches
|
|
59
|
+
* Returns true when record identity matches the agent email SMTP credentials.
|
|
60
60
|
*
|
|
61
61
|
* @private function of UserWalletClient
|
|
62
62
|
*/
|
|
@@ -219,7 +219,7 @@ export function clearSensitiveUserWalletDraftFields(draft: UserWalletDraft): Use
|
|
|
219
219
|
}
|
|
220
220
|
|
|
221
221
|
/**
|
|
222
|
-
* Applies SMTP defaults to simplify
|
|
222
|
+
* Applies SMTP defaults to simplify agent email setup.
|
|
223
223
|
*
|
|
224
224
|
* @private function of UserWalletClient
|
|
225
225
|
*/
|
|
@@ -3,13 +3,10 @@ import {
|
|
|
3
3
|
Book,
|
|
4
4
|
Calendar,
|
|
5
5
|
Code,
|
|
6
|
-
Clock8Icon,
|
|
7
6
|
ExternalLink,
|
|
8
7
|
FileText,
|
|
9
|
-
Globe,
|
|
10
8
|
Link,
|
|
11
9
|
MapPin,
|
|
12
|
-
Search,
|
|
13
10
|
Shield,
|
|
14
11
|
ShieldAlert,
|
|
15
12
|
ShieldQuestionMarkIcon,
|
|
@@ -33,11 +30,6 @@ export const HOMEPAGE_CAPABILITY_CHIPS_LIMIT = 3;
|
|
|
33
30
|
*/
|
|
34
31
|
export const AGENT_PROFILE_CAPABILITY_CHIPS_LIMIT = 7;
|
|
35
32
|
|
|
36
|
-
/**
|
|
37
|
-
* Capability types omitted from homepage agent cards.
|
|
38
|
-
*/
|
|
39
|
-
export const AGENT_CARD_HIDDEN_CAPABILITY_TYPES: ReadonlyArray<AgentCapability['type']> = ['time'];
|
|
40
|
-
|
|
41
33
|
/**
|
|
42
34
|
* Constant for max individual knowledge chips.
|
|
43
35
|
*/
|
|
@@ -49,19 +41,7 @@ const MAX_INDIVIDUAL_KNOWLEDGE_CHIPS = 2;
|
|
|
49
41
|
const CAPABILITY_PRIORITY_BUCKETS: ReadonlyArray<ReadonlyArray<AgentCapability['type']>> = [
|
|
50
42
|
['team'],
|
|
51
43
|
['inheritance', 'import'],
|
|
52
|
-
[
|
|
53
|
-
'browser',
|
|
54
|
-
'search-engine',
|
|
55
|
-
'timeout',
|
|
56
|
-
'time',
|
|
57
|
-
'user-location',
|
|
58
|
-
'image-generator',
|
|
59
|
-
'email',
|
|
60
|
-
'privacy',
|
|
61
|
-
'project',
|
|
62
|
-
'calendar',
|
|
63
|
-
'wallet',
|
|
64
|
-
],
|
|
44
|
+
['user-location', 'image-generator', 'privacy', 'project', 'calendar'],
|
|
65
45
|
['knowledge'],
|
|
66
46
|
];
|
|
67
47
|
|
|
@@ -188,11 +168,8 @@ export function AgentCapabilityChips({
|
|
|
188
168
|
|
|
189
169
|
const Icon =
|
|
190
170
|
{
|
|
191
|
-
Globe,
|
|
192
|
-
Search,
|
|
193
171
|
Book,
|
|
194
172
|
FileText,
|
|
195
|
-
Clock: Clock8Icon,
|
|
196
173
|
SquareArrowOutUpRight,
|
|
197
174
|
SquareArrowUpRight,
|
|
198
175
|
ShieldAlert,
|
|
@@ -20,6 +20,7 @@ import { buildDocumentationDropdownItems } from './buildDocumentationDropdownIte
|
|
|
20
20
|
import { buildFederatedDropdownItems } from './buildFederatedDropdownItems';
|
|
21
21
|
import { buildHeaderMenuItems } from './buildHeaderMenuItems';
|
|
22
22
|
import { buildHeaderSystemMenuItems } from './buildHeaderSystemMenuItems';
|
|
23
|
+
import { resolveHeaderSystemActivities } from './resolveHeaderSystemActivities';
|
|
23
24
|
import { resolveHeaderSystemWarnings } from './resolveHeaderSystemWarnings';
|
|
24
25
|
import { HeaderControlPanelDropdown } from './ControlPanel/ControlPanel';
|
|
25
26
|
import { HeaderDesktopContextNavigation } from './HeaderDesktopContextNavigation';
|
|
@@ -65,6 +66,7 @@ export function Header(props: HeaderProps) {
|
|
|
65
66
|
isVpsEmailServerWarningShown = false,
|
|
66
67
|
isServersDnsWarningShown = false,
|
|
67
68
|
isInternalS3WarningShown = false,
|
|
69
|
+
isSelfUpdateRunning = false,
|
|
68
70
|
} = props;
|
|
69
71
|
const [isChangePasswordOpen, setIsChangePasswordOpen] = useState(false);
|
|
70
72
|
const router = useRouter();
|
|
@@ -276,6 +278,10 @@ export function Header(props: HeaderProps) {
|
|
|
276
278
|
isInternalS3WarningShown,
|
|
277
279
|
],
|
|
278
280
|
);
|
|
281
|
+
const systemActivities = useMemo(
|
|
282
|
+
() => resolveHeaderSystemActivities({ isGlobalAdmin, isSelfUpdateRunning }),
|
|
283
|
+
[isGlobalAdmin, isSelfUpdateRunning],
|
|
284
|
+
);
|
|
279
285
|
const systemMenuEntries = useMemo(
|
|
280
286
|
() =>
|
|
281
287
|
buildHeaderSystemMenuItems({
|
|
@@ -287,6 +293,7 @@ export function Header(props: HeaderProps) {
|
|
|
287
293
|
feedbackMode,
|
|
288
294
|
shibbolethAuthenticationStatus,
|
|
289
295
|
systemWarnings,
|
|
296
|
+
systemActivities,
|
|
290
297
|
}),
|
|
291
298
|
[
|
|
292
299
|
currentUser,
|
|
@@ -295,6 +302,7 @@ export function Header(props: HeaderProps) {
|
|
|
295
302
|
isExperimental,
|
|
296
303
|
isGlobalAdmin,
|
|
297
304
|
shibbolethAuthenticationStatus,
|
|
305
|
+
systemActivities,
|
|
298
306
|
systemWarnings,
|
|
299
307
|
t,
|
|
300
308
|
],
|
|
@@ -99,6 +99,11 @@ export type HeaderProps = {
|
|
|
99
99
|
* Whether the active self-contained S3 storage needs super-admin attention.
|
|
100
100
|
*/
|
|
101
101
|
isInternalS3WarningShown?: boolean;
|
|
102
|
+
|
|
103
|
+
/**
|
|
104
|
+
* Whether a standalone VPS self-update is running right now (super-admin-only activity).
|
|
105
|
+
*/
|
|
106
|
+
isSelfUpdateRunning?: boolean;
|
|
102
107
|
};
|
|
103
108
|
|
|
104
109
|
/**
|
|
@@ -37,6 +37,7 @@ import {
|
|
|
37
37
|
MousePointerClick,
|
|
38
38
|
Paintbrush,
|
|
39
39
|
PlugZap,
|
|
40
|
+
RefreshCcw,
|
|
40
41
|
RefreshCw,
|
|
41
42
|
Scale,
|
|
42
43
|
ScrollText,
|
|
@@ -63,6 +64,7 @@ import type { ServerTranslationKey } from '../../languages/ServerTranslationKeys
|
|
|
63
64
|
import type { ShibbolethAuthenticationMenuStatus } from '../../constants/shibbolethAuth';
|
|
64
65
|
import type { ChatFeedbackMode } from '../../utils/chatFeedbackMode';
|
|
65
66
|
import type { UserInfo } from '../../utils/getCurrentUser';
|
|
67
|
+
import { isHeaderSystemActivityShownForHref, type HeaderSystemActivities } from './resolveHeaderSystemActivities';
|
|
66
68
|
import {
|
|
67
69
|
isHeaderSystemWarningShownForCategory,
|
|
68
70
|
isHeaderSystemWarningShownForHref,
|
|
@@ -160,6 +162,7 @@ type BuildHeaderSystemMenuItemsOptions = {
|
|
|
160
162
|
readonly feedbackMode: ChatFeedbackMode;
|
|
161
163
|
readonly shibbolethAuthenticationStatus?: ShibbolethAuthenticationMenuStatus;
|
|
162
164
|
readonly systemWarnings?: HeaderSystemWarnings;
|
|
165
|
+
readonly systemActivities?: HeaderSystemActivities;
|
|
163
166
|
};
|
|
164
167
|
|
|
165
168
|
/**
|
|
@@ -172,6 +175,15 @@ const EMPTY_HEADER_SYSTEM_WARNINGS: HeaderSystemWarnings = {
|
|
|
172
175
|
isSystemWarningShown: false,
|
|
173
176
|
};
|
|
174
177
|
|
|
178
|
+
/**
|
|
179
|
+
* Shared activity-free fallback for callers that only need the static System menu structure.
|
|
180
|
+
*
|
|
181
|
+
* @private constant of Header
|
|
182
|
+
*/
|
|
183
|
+
const EMPTY_HEADER_SYSTEM_ACTIVITIES: HeaderSystemActivities = {
|
|
184
|
+
activities: [],
|
|
185
|
+
};
|
|
186
|
+
|
|
175
187
|
/**
|
|
176
188
|
* Default icon used for each System dropdown category.
|
|
177
189
|
*/
|
|
@@ -297,42 +309,104 @@ function applySystemSubMenuIcons(
|
|
|
297
309
|
}
|
|
298
310
|
|
|
299
311
|
/**
|
|
300
|
-
*
|
|
312
|
+
* Kinds of status indicator that can decorate a System menu label.
|
|
313
|
+
*
|
|
314
|
+
* @private type of Header
|
|
315
|
+
*/
|
|
316
|
+
type SystemMenuIndicatorKind = 'warning' | 'activity';
|
|
317
|
+
|
|
318
|
+
/**
|
|
319
|
+
* Visual definition of one System menu status indicator.
|
|
320
|
+
*
|
|
321
|
+
* @private type of Header
|
|
322
|
+
*/
|
|
323
|
+
type SystemMenuIndicatorDefinition = {
|
|
324
|
+
/**
|
|
325
|
+
* Icon rendered after the menu label.
|
|
326
|
+
*/
|
|
327
|
+
readonly icon: LucideIcon;
|
|
328
|
+
|
|
329
|
+
/**
|
|
330
|
+
* Utility classes applied to the indicator icon.
|
|
331
|
+
*/
|
|
332
|
+
readonly className: string;
|
|
333
|
+
|
|
334
|
+
/**
|
|
335
|
+
* Accessible description of the indicated state.
|
|
336
|
+
*/
|
|
337
|
+
readonly ariaLabel: string;
|
|
338
|
+
};
|
|
339
|
+
|
|
340
|
+
/**
|
|
341
|
+
* Look of every System menu status indicator, kept in one place so labels never style icons themselves.
|
|
342
|
+
*
|
|
343
|
+
* @private constant of Header
|
|
344
|
+
*/
|
|
345
|
+
const SYSTEM_MENU_INDICATOR_DEFINITIONS: Record<SystemMenuIndicatorKind, SystemMenuIndicatorDefinition> = {
|
|
346
|
+
warning: {
|
|
347
|
+
icon: TriangleAlert,
|
|
348
|
+
className: 'h-4 w-4 text-amber-500',
|
|
349
|
+
ariaLabel: 'Warning',
|
|
350
|
+
},
|
|
351
|
+
activity: {
|
|
352
|
+
icon: RefreshCcw,
|
|
353
|
+
className: 'h-4 w-4 animate-spin text-blue-500',
|
|
354
|
+
ariaLabel: 'Running',
|
|
355
|
+
},
|
|
356
|
+
};
|
|
357
|
+
|
|
358
|
+
/**
|
|
359
|
+
* Resolves which indicator, if any, one System menu destination currently shows.
|
|
360
|
+
*
|
|
361
|
+
* @private type of Header
|
|
362
|
+
*/
|
|
363
|
+
type SystemMenuIndicatorResolver = (href: string) => SystemMenuIndicatorKind | null;
|
|
364
|
+
|
|
365
|
+
/**
|
|
366
|
+
* Decorates a System menu label with one shared status indicator.
|
|
301
367
|
*
|
|
302
368
|
* @private function of Header
|
|
303
369
|
*/
|
|
304
|
-
function
|
|
370
|
+
function createIndicatorMenuLabel(label: string, indicatorKind: SystemMenuIndicatorKind) {
|
|
371
|
+
const indicator = SYSTEM_MENU_INDICATOR_DEFINITIONS[indicatorKind];
|
|
372
|
+
|
|
305
373
|
return createElement(
|
|
306
374
|
'span',
|
|
307
375
|
{ className: 'inline-flex items-center gap-2' },
|
|
308
376
|
label,
|
|
309
|
-
createElement(
|
|
310
|
-
className:
|
|
311
|
-
'aria-label':
|
|
377
|
+
createElement(indicator.icon, {
|
|
378
|
+
className: indicator.className,
|
|
379
|
+
'aria-label': indicator.ariaLabel,
|
|
312
380
|
}),
|
|
313
381
|
);
|
|
314
382
|
}
|
|
315
383
|
|
|
316
384
|
/**
|
|
317
|
-
* Decorates every System menu entry whose destination currently has a visible
|
|
385
|
+
* Decorates every System menu entry whose destination currently has a visible status indicator.
|
|
318
386
|
*
|
|
319
|
-
* The warning
|
|
320
|
-
* does not require scattered leaf-label conditionals throughout this menu tree.
|
|
387
|
+
* The warning and activity registries own the route-to-indicator mapping, so adding another
|
|
388
|
+
* operational state does not require scattered leaf-label conditionals throughout this menu tree.
|
|
321
389
|
*
|
|
322
390
|
* @private function of Header
|
|
323
391
|
*/
|
|
324
|
-
function
|
|
392
|
+
function applySystemSubMenuIndicators(
|
|
325
393
|
items: ReadonlyArray<SubMenuItem>,
|
|
326
|
-
|
|
394
|
+
resolveIndicatorKind: SystemMenuIndicatorResolver,
|
|
327
395
|
): SubMenuItem[] {
|
|
328
|
-
return items.map((item) =>
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
396
|
+
return items.map((item) => {
|
|
397
|
+
const decoratedItems = item.items ? applySystemSubMenuIndicators(item.items, resolveIndicatorKind) : item.items;
|
|
398
|
+
|
|
399
|
+
if (!item.href || typeof item.label !== 'string') {
|
|
400
|
+
return { ...item, items: decoratedItems };
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
const indicatorKind = resolveIndicatorKind(item.href);
|
|
404
|
+
return {
|
|
405
|
+
...item,
|
|
406
|
+
label: indicatorKind ? createIndicatorMenuLabel(item.label, indicatorKind) : item.label,
|
|
407
|
+
items: decoratedItems,
|
|
408
|
+
};
|
|
409
|
+
});
|
|
336
410
|
}
|
|
337
411
|
|
|
338
412
|
/**
|
|
@@ -354,7 +428,7 @@ function createSystemCategory(
|
|
|
354
428
|
return [
|
|
355
429
|
{
|
|
356
430
|
label: isWarningShown
|
|
357
|
-
?
|
|
431
|
+
? createIndicatorMenuLabel(translate(SYSTEM_CATEGORY_TRANSLATION_KEY_MAP[label]), 'warning')
|
|
358
432
|
: translate(SYSTEM_CATEGORY_TRANSLATION_KEY_MAP[label]),
|
|
359
433
|
icon: categoryIcon,
|
|
360
434
|
items: applySystemSubMenuIcons(items, categoryIcon),
|
|
@@ -376,6 +450,7 @@ export function buildHeaderSystemMenuItems({
|
|
|
376
450
|
feedbackMode,
|
|
377
451
|
shibbolethAuthenticationStatus,
|
|
378
452
|
systemWarnings = EMPTY_HEADER_SYSTEM_WARNINGS,
|
|
453
|
+
systemActivities = EMPTY_HEADER_SYSTEM_ACTIVITIES,
|
|
379
454
|
}: BuildHeaderSystemMenuItemsOptions): SubMenuItem[] {
|
|
380
455
|
const userAccountSystemItems: SubMenuItem[] = [
|
|
381
456
|
{
|
|
@@ -629,33 +704,46 @@ export function buildHeaderSystemMenuItems({
|
|
|
629
704
|
: []),
|
|
630
705
|
];
|
|
631
706
|
|
|
632
|
-
|
|
633
|
-
|
|
707
|
+
// Note: A warning always wins over a running activity, so a menu entry which needs administrator
|
|
708
|
+
// attention is never hidden behind the progress of a background job.
|
|
709
|
+
const resolveIndicatorKind: SystemMenuIndicatorResolver = (href) => {
|
|
710
|
+
if (isHeaderSystemWarningShownForHref(systemWarnings, href)) {
|
|
711
|
+
return 'warning';
|
|
712
|
+
}
|
|
713
|
+
|
|
714
|
+
if (isHeaderSystemActivityShownForHref(systemActivities, href)) {
|
|
715
|
+
return 'activity';
|
|
716
|
+
}
|
|
717
|
+
|
|
718
|
+
return null;
|
|
719
|
+
};
|
|
720
|
+
const applyIndicators = (items: ReadonlyArray<SubMenuItem>): SubMenuItem[] =>
|
|
721
|
+
applySystemSubMenuIndicators(items, resolveIndicatorKind);
|
|
634
722
|
|
|
635
723
|
return [
|
|
636
|
-
...createSystemCategory('My Account',
|
|
637
|
-
...createSystemCategory('Utilities',
|
|
724
|
+
...createSystemCategory('My Account', applyIndicators(userAccountSystemItems), translate),
|
|
725
|
+
...createSystemCategory('Utilities', applyIndicators(utilitiesSystemItems), translate),
|
|
638
726
|
...createSystemCategory(
|
|
639
727
|
'Super Admin',
|
|
640
|
-
|
|
728
|
+
applyIndicators(superAdminSystemItems),
|
|
641
729
|
translate,
|
|
642
730
|
isHeaderSystemWarningShownForCategory(systemWarnings, 'Super Admin'),
|
|
643
731
|
),
|
|
644
732
|
...createSystemCategory(
|
|
645
733
|
'Administration',
|
|
646
|
-
|
|
734
|
+
applyIndicators(administrationSystemItems),
|
|
647
735
|
translate,
|
|
648
736
|
isHeaderSystemWarningShownForCategory(systemWarnings, 'Administration'),
|
|
649
737
|
),
|
|
650
738
|
...createSystemCategory(
|
|
651
739
|
'Login Methods',
|
|
652
|
-
|
|
740
|
+
applyIndicators(loginMethodsSystemItems),
|
|
653
741
|
translate,
|
|
654
742
|
isHeaderSystemWarningShownForCategory(systemWarnings, 'Login Methods'),
|
|
655
743
|
),
|
|
656
|
-
...createSystemCategory('Monitoring & Usage',
|
|
657
|
-
...createSystemCategory('Integrations & Keys',
|
|
658
|
-
...createSystemCategory('Developer / Debug',
|
|
659
|
-
...createSystemCategory('Legal & About',
|
|
744
|
+
...createSystemCategory('Monitoring & Usage', applyIndicators(monitoringAndUsageSystemItems), translate),
|
|
745
|
+
...createSystemCategory('Integrations & Keys', applyIndicators(integrationsAndKeysSystemItems), translate),
|
|
746
|
+
...createSystemCategory('Developer / Debug', applyIndicators(developerDebugSystemItems), translate),
|
|
747
|
+
...createSystemCategory('Legal & About', applyIndicators(legalAndAboutSystemItems), translate),
|
|
660
748
|
];
|
|
661
749
|
}
|