@promptbook/browser 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 +2 -2
- 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
|
@@ -29,7 +29,7 @@ const BOOK_LANGUAGE_VERSION = '2.0.0';
|
|
|
29
29
|
* @generated
|
|
30
30
|
* @see https://github.com/webgptorg/promptbook
|
|
31
31
|
*/
|
|
32
|
-
const PROMPTBOOK_ENGINE_VERSION = '0.112.0-
|
|
32
|
+
const PROMPTBOOK_ENGINE_VERSION = '0.112.0-26';
|
|
33
33
|
/**
|
|
34
34
|
* TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
|
|
35
35
|
* Note: [💞] Ignore a discrepancy between file name and entity name
|
|
@@ -6529,10 +6529,10 @@ class GoalCommitmentDefinition extends BaseCommitmentDefinition {
|
|
|
6529
6529
|
if (!trimmedContent) {
|
|
6530
6530
|
return requirements;
|
|
6531
6531
|
}
|
|
6532
|
-
//
|
|
6532
|
+
// Add goal to the system message
|
|
6533
6533
|
const goalSection = `Goal: ${trimmedContent}`;
|
|
6534
|
-
|
|
6535
|
-
return this.
|
|
6534
|
+
const requirementsWithGoal = this.appendToSystemMessage(requirements, goalSection, '\n\n');
|
|
6535
|
+
return this.appendToPromptSuffix(requirementsWithGoal, goalSection);
|
|
6536
6536
|
}
|
|
6537
6537
|
}
|
|
6538
6538
|
/**
|
|
@@ -9564,15 +9564,7 @@ class RuleCommitmentDefinition extends BaseCommitmentDefinition {
|
|
|
9564
9564
|
// Add rule to the system message
|
|
9565
9565
|
const ruleSection = `Rule: ${trimmedContent}`;
|
|
9566
9566
|
const requirementsWithRule = this.appendToSystemMessage(requirements, ruleSection, '\n\n');
|
|
9567
|
-
|
|
9568
|
-
.split(/\r?\n/)
|
|
9569
|
-
.map((line) => line.trim())
|
|
9570
|
-
.filter(Boolean)
|
|
9571
|
-
.map((line) => `- ${line}`);
|
|
9572
|
-
if (ruleLines.length === 0) {
|
|
9573
|
-
return requirementsWithRule;
|
|
9574
|
-
}
|
|
9575
|
-
return this.appendToPromptSuffix(requirementsWithRule, ruleLines.join('\n'));
|
|
9567
|
+
return this.appendToPromptSuffix(requirementsWithRule, ruleSection);
|
|
9576
9568
|
}
|
|
9577
9569
|
}
|
|
9578
9570
|
/**
|