@promptbook/cli 0.113.0-5 → 0.113.0-6
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/src/app/agents/[agentName]/api/book/route.ts +13 -1
- package/apps/agents-server/src/search/createDefaultServerSearchProviders/loadLocalOrganizationSearchDataset.ts +12 -1
- package/apps/agents-server/src/utils/agentOrganization/loadAgentOrganizationState.ts +13 -1
- package/apps/agents-server/src/utils/createLocalAgentSourceImporter.ts +159 -0
- package/apps/agents-server/src/utils/createMissingImportedAgentFallback.ts +60 -0
- package/apps/agents-server/src/utils/customDomainRouting.ts +157 -12
- package/apps/agents-server/src/utils/externalChatRunner/processExternalUserChatJob.ts +1 -1
- package/apps/agents-server/src/utils/importAgentWithFallback.ts +1 -58
- package/apps/agents-server/src/utils/localAgentRouteReferences.ts +167 -0
- package/apps/agents-server/src/utils/localChatRunner/processLocalUserChatJob.ts +1 -1
- package/apps/agents-server/src/utils/managementApi/managementApiAgents.ts +17 -3
- package/apps/agents-server/src/utils/resolveAgentStateFromSource.ts +7 -1
- package/apps/agents-server/src/utils/resolveInheritedAgentSource.ts +54 -5
- package/apps/agents-server/src/utils/resolveServerAgentContext.ts +12 -1
- package/apps/agents-server/src/utils/resolveStoredAgentState.ts +2 -1
- package/apps/agents-server/src/utils/userChat/userChatMessageLifecycle.ts +39 -9
- package/apps/agents-server/tests/e2e/support/ChatHistoryNavigationSupport.ts +5 -0
- package/esm/index.es.js +24 -36
- package/esm/index.es.js.map +1 -1
- package/esm/src/version.d.ts +1 -1
- package/package.json +1 -1
- package/src/avatars/avatarAnimationScheduler.ts +2 -1
- package/src/avatars/visuals/octopus3d3AvatarVisual.ts +6 -2
- package/src/avatars/visuals/octopus3d4AvatarVisual.ts +14 -18
- package/src/cli/cli-commands/agents-server/buildAgentsServer.ts +3 -1
- package/src/cli/cli-commands/coder/boilerplateTemplates.ts +14 -21
- package/src/cli/cli-commands/coder/initializeCoderProjectConfiguration.ts +1 -4
- package/src/cli/cli-commands/coder/run.ts +2 -9
- package/src/commitments/TEAM/TEAM.ts +5 -5
- package/src/other/templates/getTemplatesPipelineCollection.ts +845 -662
- package/src/utils/ascii-art/convertImageDataToAsciiArt.ts +1 -4
- package/src/version.ts +2 -2
- package/src/versions.txt +1 -0
- package/umd/index.umd.js +24 -36
- package/umd/index.umd.js.map +1 -1
- package/umd/src/version.d.ts +1 -1
|
@@ -385,10 +385,7 @@ function mapColorToAnsi256(color: HalfCellColor): number {
|
|
|
385
385
|
if (gray > ANSI_256_NEAR_WHITE_GRAY_LEVEL) {
|
|
386
386
|
return ANSI_256_WHITE_INDEX; // <- Note: Pure white lives in the color cube
|
|
387
387
|
}
|
|
388
|
-
return (
|
|
389
|
-
232 +
|
|
390
|
-
Math.round(((gray - 8) / ANSI_256_GRAYSCALE_RAMP_MAX_LEVEL) * ANSI_256_GRAYSCALE_RAMP_INDEX_SPAN)
|
|
391
|
-
);
|
|
388
|
+
return 232 + Math.round(((gray - 8) / ANSI_256_GRAYSCALE_RAMP_MAX_LEVEL) * ANSI_256_GRAYSCALE_RAMP_INDEX_SPAN);
|
|
392
389
|
}
|
|
393
390
|
|
|
394
391
|
const redIndex = Math.round((red / 255) * 5);
|
package/src/version.ts
CHANGED
|
@@ -16,11 +16,11 @@ export const BOOK_LANGUAGE_VERSION: string_semantic_version = '2.0.0';
|
|
|
16
16
|
* @generated
|
|
17
17
|
* @see https://github.com/webgptorg/promptbook
|
|
18
18
|
*/
|
|
19
|
-
export const PROMPTBOOK_ENGINE_VERSION: string_promptbook_version = '0.113.0-
|
|
19
|
+
export const PROMPTBOOK_ENGINE_VERSION: string_promptbook_version = '0.113.0-6';
|
|
20
20
|
|
|
21
21
|
/**
|
|
22
22
|
* Represents the version string of the Promptbook engine.
|
|
23
|
-
* It follows semantic versioning (e.g., `0.113.0-
|
|
23
|
+
* It follows semantic versioning (e.g., `0.113.0-5`).
|
|
24
24
|
*
|
|
25
25
|
* @generated
|
|
26
26
|
*/
|
package/src/versions.txt
CHANGED
package/umd/index.umd.js
CHANGED
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
* @generated
|
|
64
64
|
* @see https://github.com/webgptorg/promptbook
|
|
65
65
|
*/
|
|
66
|
-
const PROMPTBOOK_ENGINE_VERSION = '0.113.0-
|
|
66
|
+
const PROMPTBOOK_ENGINE_VERSION = '0.113.0-6';
|
|
67
67
|
/**
|
|
68
68
|
* TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
|
|
69
69
|
* Note: [💞] Ignore a discrepancy between file name and entity name
|
|
@@ -14668,7 +14668,7 @@
|
|
|
14668
14668
|
isAnimated: true,
|
|
14669
14669
|
supportsPointerTracking: true,
|
|
14670
14670
|
render({ context, size, palette, createRandom, timeMs, interaction }) {
|
|
14671
|
-
const { morphologyProfile, animationPhase, leftEyePhaseOffset, rightEyePhaseOffset, tentacleProfiles, skinSpots } = getOctopus3d4StableState(createRandom);
|
|
14671
|
+
const { morphologyProfile, animationPhase, leftEyePhaseOffset, rightEyePhaseOffset, tentacleProfiles, skinSpots, } = getOctopus3d4StableState(createRandom);
|
|
14672
14672
|
const sceneCenterX = size * 0.5;
|
|
14673
14673
|
const sceneCenterY = size * 0.535;
|
|
14674
14674
|
const bob = Math.sin(timeMs / 980 + animationPhase) * size * 0.013;
|
|
@@ -15016,10 +15016,7 @@
|
|
|
15016
15016
|
Math.max(0, Math.cos(effectiveLongitude)) * 0.12 +
|
|
15017
15017
|
lowerBlend * tentacleInfluence.core * (0.12 + tentacleInfluence.depthScale * 0.07) -
|
|
15018
15018
|
Math.max(0, -Math.cos(effectiveLongitude)) * 0.05;
|
|
15019
|
-
const tentacleTubeRadius = lowerBlend *
|
|
15020
|
-
tentacleInfluence.core *
|
|
15021
|
-
(0.12 + tipBlend * 0.07 + tentacleInfluence.widthScale * 0.028) *
|
|
15022
|
-
radiusX;
|
|
15019
|
+
const tentacleTubeRadius = lowerBlend * tentacleInfluence.core * (0.12 + tipBlend * 0.07 + tentacleInfluence.widthScale * 0.028) * radiusX;
|
|
15023
15020
|
const planarRadiusX = cosineLatitude * radiusX * horizontalScale + tentacleTubeRadius;
|
|
15024
15021
|
const planarRadiusZ = cosineLatitude * radiusZ * depthScale + tentacleTubeRadius * 0.74;
|
|
15025
15022
|
const lowerDrop = lowerBlend *
|
|
@@ -15031,9 +15028,7 @@
|
|
|
15031
15028
|
(morphologyProfile.tentacles.flowLengthScale - 1) * 0.1));
|
|
15032
15029
|
const combinedTentacleSway = (primaryTentacleWave + secondaryTentacleWave) * radiusX * (0.06 + tipBlend * 0.06);
|
|
15033
15030
|
return {
|
|
15034
|
-
x: Math.sin(effectiveLongitude) * planarRadiusX +
|
|
15035
|
-
combinedTentacleSway +
|
|
15036
|
-
tentacleCurl * radiusX * 0.18,
|
|
15031
|
+
x: Math.sin(effectiveLongitude) * planarRadiusX + combinedTentacleSway + tentacleCurl * radiusX * 0.18,
|
|
15037
15032
|
y: Math.sin(latitude) * radiusY * (1 + upperBlend * 0.14) -
|
|
15038
15033
|
upperBlend * radiusY * 0.12 +
|
|
15039
15034
|
lowerDrop +
|
|
@@ -18292,10 +18287,10 @@
|
|
|
18292
18287
|
*
|
|
18293
18288
|
* @private
|
|
18294
18289
|
*/
|
|
18295
|
-
const
|
|
18296
|
-
|
|
18297
|
-
|
|
18298
|
-
|
|
18290
|
+
const TEAM_SYSTEM_MESSAGE_GUIDANCE = _spaceTrim.spaceTrim(`
|
|
18291
|
+
- If a teammate is relevant to the request, consult that teammate using the matching tool.
|
|
18292
|
+
- Do not ask the user for information that a listed teammate can provide directly.
|
|
18293
|
+
`);
|
|
18299
18294
|
/**
|
|
18300
18295
|
* Constant for remote agents by Url.
|
|
18301
18296
|
*/
|
|
@@ -18477,7 +18472,7 @@
|
|
|
18477
18472
|
`);
|
|
18478
18473
|
});
|
|
18479
18474
|
return _spaceTrim.spaceTrim((block) => `
|
|
18480
|
-
${block(
|
|
18475
|
+
${block(TEAM_SYSTEM_MESSAGE_GUIDANCE)}
|
|
18481
18476
|
|
|
18482
18477
|
${block(teammateSections.join('\n\n'))}
|
|
18483
18478
|
`);
|
|
@@ -40404,26 +40399,26 @@
|
|
|
40404
40399
|
id: 'common',
|
|
40405
40400
|
relativeFilePath: path.join(PROMPTS_TEMPLATES_DIRECTORY_PATH, 'common.md'),
|
|
40406
40401
|
slugPrefix: null,
|
|
40407
|
-
content:
|
|
40408
|
-
|
|
40409
|
-
|
|
40410
|
-
|
|
40411
|
-
|
|
40412
|
-
|
|
40402
|
+
content: _spaceTrim.spaceTrim(`
|
|
40403
|
+
- @@@
|
|
40404
|
+
- Keep in mind the DRY _(don't repeat yourself)_ principle.
|
|
40405
|
+
- Do a proper analysis of the current functionality before you start implementing.
|
|
40406
|
+
- Add the changes into the [changelog](changelog/_current-preversion.md)
|
|
40407
|
+
`),
|
|
40413
40408
|
isDefaultProjectTemplate: true,
|
|
40414
40409
|
},
|
|
40415
40410
|
{
|
|
40416
40411
|
id: 'agents-server',
|
|
40417
40412
|
relativeFilePath: path.join(PROMPTS_TEMPLATES_DIRECTORY_PATH, 'agents-server.md'),
|
|
40418
40413
|
slugPrefix: 'agents-server',
|
|
40419
|
-
content:
|
|
40420
|
-
|
|
40421
|
-
|
|
40422
|
-
|
|
40423
|
-
|
|
40424
|
-
|
|
40425
|
-
|
|
40426
|
-
|
|
40414
|
+
content: _spaceTrim.spaceTrim(`
|
|
40415
|
+
- @@@
|
|
40416
|
+
- Keep in mind the DRY _(don't repeat yourself)_ principle.
|
|
40417
|
+
- Do a proper analysis of the current functionality before you start implementing.
|
|
40418
|
+
- You are working with the [Agents Server](apps/agents-server)
|
|
40419
|
+
- If you need to do the database migration, do it
|
|
40420
|
+
- Add the changes into the [changelog](changelog/_current-preversion.md)
|
|
40421
|
+
`),
|
|
40427
40422
|
isDefaultProjectTemplate: false,
|
|
40428
40423
|
},
|
|
40429
40424
|
];
|
|
@@ -40543,12 +40538,6 @@
|
|
|
40543
40538
|
function getDefaultCoderPromptTemplateDefinitionOrUndefined(template) {
|
|
40544
40539
|
return DEFAULT_CODER_PROMPT_TEMPLATE_DEFINITIONS.find((definition) => definition.id === template);
|
|
40545
40540
|
}
|
|
40546
|
-
/**
|
|
40547
|
-
* Builds stable markdown content for one coder prompt template without indentation drift.
|
|
40548
|
-
*/
|
|
40549
|
-
function buildCoderPromptTemplateContent(lines) {
|
|
40550
|
-
return lines.join('\n');
|
|
40551
|
-
}
|
|
40552
40541
|
/**
|
|
40553
40542
|
* Creates a fully resolved template payload from one built-in definition.
|
|
40554
40543
|
*/
|
|
@@ -71942,8 +71931,7 @@
|
|
|
71942
71931
|
if (gray > ANSI_256_NEAR_WHITE_GRAY_LEVEL) {
|
|
71943
71932
|
return ANSI_256_WHITE_INDEX; // <- Note: Pure white lives in the color cube
|
|
71944
71933
|
}
|
|
71945
|
-
return
|
|
71946
|
-
Math.round(((gray - 8) / ANSI_256_GRAYSCALE_RAMP_MAX_LEVEL) * ANSI_256_GRAYSCALE_RAMP_INDEX_SPAN));
|
|
71934
|
+
return 232 + Math.round(((gray - 8) / ANSI_256_GRAYSCALE_RAMP_MAX_LEVEL) * ANSI_256_GRAYSCALE_RAMP_INDEX_SPAN);
|
|
71947
71935
|
}
|
|
71948
71936
|
const redIndex = Math.round((red / 255) * 5);
|
|
71949
71937
|
const greenIndex = Math.round((green / 255) * 5);
|