@promptbook/cli 0.112.0-134 → 0.112.0-136
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/apps/agents-server/README.md +0 -1
- package/apps/agents-server/src/app/admin/chat-feedback/page.tsx +2 -4
- package/apps/agents-server/src/app/admin/chat-history/page.tsx +2 -4
- package/apps/agents-server/src/app/admin/metadata/MetadataClient.tsx +246 -15
- package/apps/agents-server/src/app/admin/update/UpdateClient.tsx +237 -4
- package/apps/agents-server/src/app/api/admin/update/log/route.ts +42 -0
- package/apps/agents-server/src/app/api/agents/[agentName]/route.ts +28 -9
- package/apps/agents-server/src/app/api/agents/export/route.ts +41 -0
- package/apps/agents-server/src/app/api/agents/import/route.ts +168 -0
- package/apps/agents-server/src/app/api/chat/route.ts +29 -7
- package/apps/agents-server/src/app/api/chat-feedback/export/route.ts +2 -2
- package/apps/agents-server/src/app/api/chat-feedback/route.ts +3 -3
- package/apps/agents-server/src/app/api/chat-history/[id]/route.ts +2 -2
- package/apps/agents-server/src/app/api/chat-history/export/route.ts +2 -2
- package/apps/agents-server/src/app/api/chat-history/route.ts +3 -3
- package/apps/agents-server/src/app/api/chat-streaming/route.ts +29 -0
- package/apps/agents-server/src/app/api/elevenlabs/tts/route.ts +60 -2
- package/apps/agents-server/src/app/api/federated-agents/route.ts +1 -1
- package/apps/agents-server/src/app/api/images/[filename]/route.ts +102 -0
- package/apps/agents-server/src/app/api/metadata/export/route.ts +34 -0
- package/apps/agents-server/src/app/api/metadata/import/route.ts +46 -0
- package/apps/agents-server/src/app/api/openai/v1/audio/transcriptions/route.ts +111 -2
- package/apps/agents-server/src/app/api/page-preview/check/route.ts +18 -0
- package/apps/agents-server/src/app/api/page-preview/screenshot/route.ts +15 -8
- package/apps/agents-server/src/app/api/team-agent-profile/route.ts +20 -0
- package/apps/agents-server/src/app/layout.tsx +1 -1
- package/apps/agents-server/src/components/AgentContextMenu/useAgentContextMenuItems.ts +27 -19
- package/apps/agents-server/src/components/Homepage/AgentsList.tsx +31 -1
- package/apps/agents-server/src/components/Homepage/AgentsListHeader.tsx +60 -1
- package/apps/agents-server/src/components/Homepage/useAgentsListImportExportState.ts +523 -0
- package/apps/agents-server/src/components/Homepage/useAgentsListState.ts +16 -0
- package/apps/agents-server/src/constants/defaultAgentAvatarVisual.ts +1 -1
- package/apps/agents-server/src/database/metadataDefaults.ts +0 -21
- package/apps/agents-server/src/database/migrations/2026-06-2700-default-agent-avatar-visual-octopus3d4.sql +16 -0
- package/apps/agents-server/src/database/seedCoreAgents.ts +235 -0
- package/apps/agents-server/src/database/seedDefaultAgents.ts +32 -1
- package/apps/agents-server/src/search/createDefaultServerSearchProviders/createFederatedAgentsSearchProvider.ts +1 -1
- package/apps/agents-server/src/tools/$provideAgentCollectionForServer.ts +2 -9
- package/apps/agents-server/src/utils/agentOwnership.ts +54 -5
- package/apps/agents-server/src/utils/agentsTransfer/createAgentsExportZipStream.ts +68 -0
- package/apps/agents-server/src/utils/agentsTransfer/importAgentsFromFiles.ts +852 -0
- package/apps/agents-server/src/utils/backup/createBooksBackupZipStream.ts +15 -2
- package/apps/agents-server/src/utils/defaultAgents/loadDefaultAgentBooks.ts +46 -4
- package/apps/agents-server/src/utils/findAgentForCallerWriteAccess.ts +36 -0
- package/apps/agents-server/src/utils/getFederatedServers.ts +3 -74
- package/apps/agents-server/src/utils/getWellKnownAgentUrl.ts +10 -4
- package/apps/agents-server/src/utils/metadataConfigurationTransfer.ts +426 -0
- package/apps/agents-server/src/utils/paidApiRequestGuard.ts +241 -0
- package/apps/agents-server/src/utils/serverManagement/createManagedServer/bootstrapManagedServer.ts +2 -5
- package/apps/agents-server/src/utils/serverManagement/createManagedServer/seedServerCoreAgents.ts +162 -0
- package/apps/agents-server/src/utils/userChat/createRunUserChatJobExecutionContext.ts +36 -8
- package/apps/agents-server/src/utils/userChat/persistUserChatJobProgressCard.ts +11 -2
- package/apps/agents-server/src/utils/userChat/resolveUserChatProgressToolHighlights.ts +100 -0
- package/apps/agents-server/src/utils/userChat/runUserChatJob.ts +4 -3
- package/apps/agents-server/src/utils/userChat/userChatProgressCard.ts +272 -27
- package/apps/agents-server/src/utils/validateApiKey.ts +7 -3
- package/apps/agents-server/src/utils/vpsSelfUpdate.ts +110 -0
- package/esm/index.es.js +795 -39
- package/esm/index.es.js.map +1 -1
- package/esm/src/_packages/core.index.d.ts +0 -2
- package/esm/src/avatars/types/AvatarVisualDefinition.d.ts +1 -1
- package/esm/src/avatars/visuals/octopus3d4AvatarVisual.d.ts +7 -0
- package/esm/src/utils/validators/url/isValidAgentUrl.d.ts +5 -0
- package/esm/src/version.d.ts +1 -1
- package/package.json +1 -1
- package/servers.ts +1 -16
- package/src/_packages/core.index.ts +0 -2
- package/src/avatars/types/AvatarVisualDefinition.ts +1 -0
- package/src/avatars/visuals/avatarVisualRegistry.ts +2 -0
- package/src/avatars/visuals/octopus3d4AvatarVisual.ts +1295 -0
- package/src/other/templates/getTemplatesPipelineCollection.ts +762 -883
- package/src/utils/agents/resolveAgentAvatarImageUrl.ts +1 -1
- package/src/utils/validators/url/isValidAgentUrl.ts +5 -7
- package/src/version.ts +2 -2
- package/src/versions.txt +2 -1
- package/umd/index.umd.js +795 -39
- package/umd/index.umd.js.map +1 -1
- package/umd/src/_packages/core.index.d.ts +0 -2
- package/umd/src/avatars/types/AvatarVisualDefinition.d.ts +1 -1
- package/umd/src/avatars/visuals/octopus3d4AvatarVisual.d.ts +7 -0
- package/umd/src/utils/validators/url/isValidAgentUrl.d.ts +5 -0
- package/umd/src/version.d.ts +1 -1
- package/apps/agents-server/src/utils/defaultFederatedAgents/DefaultFederatedAgentsSyncOptions.ts +0 -9
- package/apps/agents-server/src/utils/defaultFederatedAgents/ensureDefaultFederatedAgentExists.ts +0 -277
- package/apps/agents-server/src/utils/defaultFederatedAgents/fetchCoreOrganizationPayload.ts +0 -39
- package/apps/agents-server/src/utils/defaultFederatedAgents/fetchFederatedAgentBook.ts +0 -43
- package/apps/agents-server/src/utils/defaultFederatedAgents/fetchWithDefaultFederatedAgentTimeout.ts +0 -28
- package/apps/agents-server/src/utils/defaultFederatedAgents/getDefaultFederatedAgentSyncPool.ts +0 -38
- package/apps/agents-server/src/utils/defaultFederatedAgents/loadActiveLocalAgentIdsByNormalizedName.ts +0 -41
- package/apps/agents-server/src/utils/defaultFederatedAgents/loadDefaultFederatedAgentSyncMetadata.ts +0 -76
- package/apps/agents-server/src/utils/defaultFederatedAgents/quoteIdentifier.ts +0 -11
- package/apps/agents-server/src/utils/defaultFederatedAgents/scheduleDefaultFederatedAgentsSync.ts +0 -88
- package/apps/agents-server/src/utils/defaultFederatedAgents/selectDefaultFederatedAgentsFromOrganizationPayload.ts +0 -181
- package/apps/agents-server/src/utils/defaultFederatedAgents/synchronizeDefaultFederatedAgents.ts +0 -77
|
@@ -221,7 +221,6 @@ import { normalizeChatAttachments } from '../utils/chat/chatAttachments/normaliz
|
|
|
221
221
|
import { resolveChatAttachmentContents } from '../utils/chat/chatAttachments/resolveChatAttachmentContents';
|
|
222
222
|
import { aboutPromptbookInformation } from '../utils/misc/aboutPromptbookInformation';
|
|
223
223
|
import { $generateBookBoilerplate } from '../utils/random/$generateBookBoilerplate';
|
|
224
|
-
import { CORE_AGENTS_SERVER } from '../../servers';
|
|
225
224
|
import { CORE_AGENTS_SERVER_WELL_KNOWN_AGENT_NAMES } from '../../servers';
|
|
226
225
|
import { PUBLIC_AGENTS_SERVERS } from '../../servers';
|
|
227
226
|
export { BOOK_LANGUAGE_VERSION, PROMPTBOOK_ENGINE_VERSION };
|
|
@@ -447,6 +446,5 @@ export { normalizeChatAttachments };
|
|
|
447
446
|
export { resolveChatAttachmentContents };
|
|
448
447
|
export { aboutPromptbookInformation };
|
|
449
448
|
export { $generateBookBoilerplate };
|
|
450
|
-
export { CORE_AGENTS_SERVER };
|
|
451
449
|
export { CORE_AGENTS_SERVER_WELL_KNOWN_AGENT_NAMES };
|
|
452
450
|
export { PUBLIC_AGENTS_SERVERS };
|
|
@@ -7,7 +7,7 @@ import type { AvatarDefinition } from './AvatarDefinition';
|
|
|
7
7
|
*
|
|
8
8
|
* @private shared contract for the avatar rendering system
|
|
9
9
|
*/
|
|
10
|
-
export type AvatarVisualId = 'pixel-art' | 'octopus' | 'octopus2' | 'octopus3' | 'octopus3d' | 'octopus3d2' | 'octopus3d3' | 'ascii-octopus' | 'minecraft' | 'minecraft2' | 'fractal' | 'orb';
|
|
10
|
+
export type AvatarVisualId = 'pixel-art' | 'octopus' | 'octopus2' | 'octopus3' | 'octopus3d' | 'octopus3d2' | 'octopus3d3' | 'octopus3d4' | 'ascii-octopus' | 'minecraft' | 'minecraft2' | 'fractal' | 'orb';
|
|
11
11
|
/**
|
|
12
12
|
* Derived color palette used by avatar visuals.
|
|
13
13
|
*
|
|
@@ -8,6 +8,11 @@ import type { really_unknown } from '../../organization/really_unknown';
|
|
|
8
8
|
* - `isValidAgentUrl` *(this one)* which tests just agent URL
|
|
9
9
|
* - `isValidPipelineUrl` which tests just pipeline URL
|
|
10
10
|
*
|
|
11
|
+
* Note: This is a pure structural validator and does not block private/internal network
|
|
12
|
+
* addresses. Callers that fetch the URL server-side from an untrusted network context must
|
|
13
|
+
* additionally apply the `assertSafeUrl` SSRF guard from the Agents Server before any
|
|
14
|
+
* outbound request.
|
|
15
|
+
*
|
|
11
16
|
* @public exported from `@promptbook/utils`
|
|
12
17
|
*/
|
|
13
18
|
export declare function isValidAgentUrl(url: really_unknown): url is string_agent_url;
|
package/esm/src/version.d.ts
CHANGED
|
@@ -15,7 +15,7 @@ export declare const BOOK_LANGUAGE_VERSION: string_semantic_version;
|
|
|
15
15
|
export declare const PROMPTBOOK_ENGINE_VERSION: string_promptbook_version;
|
|
16
16
|
/**
|
|
17
17
|
* Represents the version string of the Promptbook engine.
|
|
18
|
-
* It follows semantic versioning (e.g., `0.112.0-
|
|
18
|
+
* It follows semantic versioning (e.g., `0.112.0-135`).
|
|
19
19
|
*
|
|
20
20
|
* @generated
|
|
21
21
|
*/
|
package/package.json
CHANGED
package/servers.ts
CHANGED
|
@@ -32,21 +32,7 @@ type ServerConfiguration = {
|
|
|
32
32
|
};
|
|
33
33
|
|
|
34
34
|
/**
|
|
35
|
-
*
|
|
36
|
-
*
|
|
37
|
-
* Used for "Adam" agent which is built in as default ancestor for new agents and other well known agents
|
|
38
|
-
*
|
|
39
|
-
* @public exported from `@promptbook/core`
|
|
40
|
-
*/
|
|
41
|
-
export const CORE_AGENTS_SERVER: ServerConfiguration = {
|
|
42
|
-
title: 'Promptbook Core',
|
|
43
|
-
description: `Core Promptbook server used for Adam agent which is built in as default ancestor for new agents and other well known agents.`,
|
|
44
|
-
owner: PROMPTBOOK_LEGAL_ENTITY,
|
|
45
|
-
url: 'https://core.ptbk.io/',
|
|
46
|
-
};
|
|
47
|
-
|
|
48
|
-
/**
|
|
49
|
-
* Names of well known agents hosted on Core Promptbook server
|
|
35
|
+
* Names of well known agents bundled in the local `.core` folder of every Agents Server
|
|
50
36
|
*
|
|
51
37
|
* - `Adam`: The default ancestor agent for new agents
|
|
52
38
|
* - `Teacher`: Agent that knows book syntax and can help with self-learning
|
|
@@ -74,7 +60,6 @@ export const CORE_AGENTS_SERVER_WELL_KNOWN_AGENT_NAMES = {
|
|
|
74
60
|
* @public exported from `@promptbook/core`
|
|
75
61
|
*/
|
|
76
62
|
export const PUBLIC_AGENTS_SERVERS: Array<ServerConfiguration> = [
|
|
77
|
-
CORE_AGENTS_SERVER,
|
|
78
63
|
{
|
|
79
64
|
title: 'Promptbook Gallery',
|
|
80
65
|
description: `Gallery of ideas, AI professions,... like AI Agenta photobank.`,
|
|
@@ -224,7 +224,6 @@ import { normalizeChatAttachments } from '../utils/chat/chatAttachments/normaliz
|
|
|
224
224
|
import { resolveChatAttachmentContents } from '../utils/chat/chatAttachments/resolveChatAttachmentContents';
|
|
225
225
|
import { aboutPromptbookInformation } from '../utils/misc/aboutPromptbookInformation';
|
|
226
226
|
import { $generateBookBoilerplate } from '../utils/random/$generateBookBoilerplate';
|
|
227
|
-
import { CORE_AGENTS_SERVER } from '../../servers';
|
|
228
227
|
import { CORE_AGENTS_SERVER_WELL_KNOWN_AGENT_NAMES } from '../../servers';
|
|
229
228
|
import { PUBLIC_AGENTS_SERVERS } from '../../servers';
|
|
230
229
|
|
|
@@ -456,6 +455,5 @@ export { normalizeChatAttachments };
|
|
|
456
455
|
export { resolveChatAttachmentContents };
|
|
457
456
|
export { aboutPromptbookInformation };
|
|
458
457
|
export { $generateBookBoilerplate };
|
|
459
|
-
export { CORE_AGENTS_SERVER };
|
|
460
458
|
export { CORE_AGENTS_SERVER_WELL_KNOWN_AGENT_NAMES };
|
|
461
459
|
export { PUBLIC_AGENTS_SERVERS };
|
|
@@ -8,6 +8,7 @@ import { octopus3AvatarVisual } from './octopus3AvatarVisual';
|
|
|
8
8
|
import { octopus3dAvatarVisual } from './octopus3dAvatarVisual';
|
|
9
9
|
import { octopus3d2AvatarVisual } from './octopus3d2AvatarVisual';
|
|
10
10
|
import { octopus3d3AvatarVisual } from './octopus3d3AvatarVisual';
|
|
11
|
+
import { octopus3d4AvatarVisual } from './octopus3d4AvatarVisual';
|
|
11
12
|
import { octopusAvatarVisual } from './octopusAvatarVisual';
|
|
12
13
|
import { orbAvatarVisual } from './orbAvatarVisual';
|
|
13
14
|
import { pixelArtAvatarVisual } from './pixelArtAvatarVisual';
|
|
@@ -27,6 +28,7 @@ export const AVATAR_VISUALS: ReadonlyArray<AvatarVisualDefinition> = [
|
|
|
27
28
|
octopus3dAvatarVisual,
|
|
28
29
|
octopus3d2AvatarVisual,
|
|
29
30
|
octopus3d3AvatarVisual,
|
|
31
|
+
octopus3d4AvatarVisual,
|
|
30
32
|
asciiOctopusAvatarVisual,
|
|
31
33
|
minecraftAvatarVisual,
|
|
32
34
|
minecraft2AvatarVisual,
|