@promptbook/remote-server 0.20.6 → 0.21.0
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/typings/_packages/utils.index.d.ts +2 -1
- package/esm/typings/config.d.ts +1 -0
- package/esm/typings/utils/trimEndOfCodeBlock.d.ts +6 -0
- package/esm/typings/utils/trimEndOfCodeBlock.test.d.ts +1 -0
- package/package.json +2 -2
- package/umd/typings/_packages/utils.index.d.ts +2 -1
- package/umd/typings/config.d.ts +1 -0
- package/umd/typings/utils/trimEndOfCodeBlock.d.ts +6 -0
- package/umd/typings/utils/trimEndOfCodeBlock.test.d.ts +1 -0
|
@@ -7,5 +7,6 @@ import { removeMarkdownFormatting } from '../utils/markdown/removeMarkdownFormat
|
|
|
7
7
|
import { removeEmojis } from '../utils/removeEmojis';
|
|
8
8
|
import { removeQuotes } from '../utils/removeQuotes';
|
|
9
9
|
import { replaceParameters } from '../utils/replaceParameters';
|
|
10
|
+
import { trimEndOfCodeBlock } from '../utils/trimEndOfCodeBlock';
|
|
10
11
|
import { unwrapResult } from '../utils/unwrapResult';
|
|
11
|
-
export { EMOJIS, EMOJIS_IN_CATEGORIES, extractAllListItemsFromMarkdown, extractBlocksFromMarkdown, extractOneBlockFromMarkdown, removeContentComments, removeEmojis, removeMarkdownFormatting, removeQuotes, replaceParameters, unwrapResult, };
|
|
12
|
+
export { EMOJIS, EMOJIS_IN_CATEGORIES, extractAllListItemsFromMarkdown, extractBlocksFromMarkdown, extractOneBlockFromMarkdown, removeContentComments, removeEmojis, removeMarkdownFormatting, removeQuotes, replaceParameters, trimEndOfCodeBlock, unwrapResult, };
|
package/esm/typings/config.d.ts
CHANGED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Function trimEndOfCodeBlock will remove ending code block from the string if it is present.
|
|
3
|
+
*
|
|
4
|
+
* This is usefull for post-processing of the result of the completion LLM model if you want to start code block in the prompt but you don't want to end it in the result.
|
|
5
|
+
*/
|
|
6
|
+
export declare function trimEndOfCodeBlock(value: string): string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@promptbook/remote-server",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.21.0",
|
|
4
4
|
"description": "Library to supercharge your use of large language models",
|
|
5
5
|
"private": false,
|
|
6
6
|
"sideEffects": false,
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"spacetrim": "0.9.14"
|
|
39
39
|
},
|
|
40
40
|
"peerDependencies": {
|
|
41
|
-
"@promptbook/core": "0.
|
|
41
|
+
"@promptbook/core": "0.21.0"
|
|
42
42
|
},
|
|
43
43
|
"main": "./umd/index.umd.js",
|
|
44
44
|
"module": "./esm/index.es.js",
|
|
@@ -7,5 +7,6 @@ import { removeMarkdownFormatting } from '../utils/markdown/removeMarkdownFormat
|
|
|
7
7
|
import { removeEmojis } from '../utils/removeEmojis';
|
|
8
8
|
import { removeQuotes } from '../utils/removeQuotes';
|
|
9
9
|
import { replaceParameters } from '../utils/replaceParameters';
|
|
10
|
+
import { trimEndOfCodeBlock } from '../utils/trimEndOfCodeBlock';
|
|
10
11
|
import { unwrapResult } from '../utils/unwrapResult';
|
|
11
|
-
export { EMOJIS, EMOJIS_IN_CATEGORIES, extractAllListItemsFromMarkdown, extractBlocksFromMarkdown, extractOneBlockFromMarkdown, removeContentComments, removeEmojis, removeMarkdownFormatting, removeQuotes, replaceParameters, unwrapResult, };
|
|
12
|
+
export { EMOJIS, EMOJIS_IN_CATEGORIES, extractAllListItemsFromMarkdown, extractBlocksFromMarkdown, extractOneBlockFromMarkdown, removeContentComments, removeEmojis, removeMarkdownFormatting, removeQuotes, replaceParameters, trimEndOfCodeBlock, unwrapResult, };
|
package/umd/typings/config.d.ts
CHANGED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Function trimEndOfCodeBlock will remove ending code block from the string if it is present.
|
|
3
|
+
*
|
|
4
|
+
* This is usefull for post-processing of the result of the completion LLM model if you want to start code block in the prompt but you don't want to end it in the result.
|
|
5
|
+
*/
|
|
6
|
+
export declare function trimEndOfCodeBlock(value: string): string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|