@promptbook/core 0.112.0-24 → 0.112.0-26
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/esm/index.es.js +5 -13
- package/esm/index.es.js.map +1 -1
- package/esm/src/book-components/_common/MenuHoisting/MenuHoistingContext.d.ts +47 -0
- package/esm/src/version.d.ts +1 -1
- package/package.json +1 -1
- package/umd/index.umd.js +5 -13
- package/umd/index.umd.js.map +1 -1
- package/umd/src/book-components/_common/MenuHoisting/MenuHoistingContext.d.ts +47 -0
- package/umd/src/version.d.ts +1 -1
package/esm/index.es.js
CHANGED
|
@@ -28,7 +28,7 @@ const BOOK_LANGUAGE_VERSION = '2.0.0';
|
|
|
28
28
|
* @generated
|
|
29
29
|
* @see https://github.com/webgptorg/promptbook
|
|
30
30
|
*/
|
|
31
|
-
const PROMPTBOOK_ENGINE_VERSION = '0.112.0-
|
|
31
|
+
const PROMPTBOOK_ENGINE_VERSION = '0.112.0-26';
|
|
32
32
|
/**
|
|
33
33
|
* TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
|
|
34
34
|
* Note: [💞] Ignore a discrepancy between file name and entity name
|
|
@@ -11302,10 +11302,10 @@ class GoalCommitmentDefinition extends BaseCommitmentDefinition {
|
|
|
11302
11302
|
if (!trimmedContent) {
|
|
11303
11303
|
return requirements;
|
|
11304
11304
|
}
|
|
11305
|
-
//
|
|
11305
|
+
// Add goal to the system message
|
|
11306
11306
|
const goalSection = `Goal: ${trimmedContent}`;
|
|
11307
|
-
|
|
11308
|
-
return this.
|
|
11307
|
+
const requirementsWithGoal = this.appendToSystemMessage(requirements, goalSection, '\n\n');
|
|
11308
|
+
return this.appendToPromptSuffix(requirementsWithGoal, goalSection);
|
|
11309
11309
|
}
|
|
11310
11310
|
}
|
|
11311
11311
|
/**
|
|
@@ -14337,15 +14337,7 @@ class RuleCommitmentDefinition extends BaseCommitmentDefinition {
|
|
|
14337
14337
|
// Add rule to the system message
|
|
14338
14338
|
const ruleSection = `Rule: ${trimmedContent}`;
|
|
14339
14339
|
const requirementsWithRule = this.appendToSystemMessage(requirements, ruleSection, '\n\n');
|
|
14340
|
-
|
|
14341
|
-
.split(/\r?\n/)
|
|
14342
|
-
.map((line) => line.trim())
|
|
14343
|
-
.filter(Boolean)
|
|
14344
|
-
.map((line) => `- ${line}`);
|
|
14345
|
-
if (ruleLines.length === 0) {
|
|
14346
|
-
return requirementsWithRule;
|
|
14347
|
-
}
|
|
14348
|
-
return this.appendToPromptSuffix(requirementsWithRule, ruleLines.join('\n'));
|
|
14340
|
+
return this.appendToPromptSuffix(requirementsWithRule, ruleSection);
|
|
14349
14341
|
}
|
|
14350
14342
|
}
|
|
14351
14343
|
/**
|