@promptbook/anthropic-claude
Advanced tools
Comparing version 0.67.4 to 0.67.5
import { PROMPTBOOK_VERSION } from '../version'; | ||
import { extractBlock } from '../postprocessing/utils/extractBlock'; | ||
import { extractJsonBlock } from '../postprocessing/utils/extractJsonBlock'; | ||
import type { string_markdown } from '../types/typeAliases'; | ||
@@ -20,2 +22,4 @@ import type { string_markdown_section } from '../types/typeAliases'; | ||
export { PROMPTBOOK_VERSION }; | ||
export { extractBlock }; | ||
export { extractJsonBlock }; | ||
export type { string_markdown }; | ||
@@ -22,0 +26,0 @@ export type { string_markdown_section }; |
@@ -11,3 +11,2 @@ import { PROMPTBOOK_VERSION } from '../version'; | ||
import { isValidJsonString } from '../formats/json/utils/isValidJsonString'; | ||
import { extractBlock } from '../postprocessing/utils/extractBlock'; | ||
import { $currentDate } from '../utils/$currentDate'; | ||
@@ -84,3 +83,2 @@ import { $isRunningInBrowser } from '../utils/environment/$isRunningInBrowser'; | ||
export { isValidJsonString }; | ||
export { extractBlock }; | ||
export { $currentDate }; | ||
@@ -87,0 +85,0 @@ export { $isRunningInBrowser }; |
@@ -65,2 +65,3 @@ import type { string_mime_type } from '../../types/typeAliases'; | ||
/** | ||
* TODO: [β] Add some prepare hook to modify prompt according to the format | ||
* TODO: [π]`name` and `aliases` should be UPPERCASE only and interpreted as case-insensitive (via normalization) | ||
@@ -67,0 +68,0 @@ * TODO: [π][π¨ββοΈ] Compute TPartialValue dynamically - PartialString<TValue> |
@@ -5,14 +5,13 @@ import type { string_markdown } from '../../types/typeAliases'; | ||
* | ||
* Note: If there are multiple or no code blocks the function throws an error | ||
* - When there are multiple or no code blocks the function throws a `ParsingError` | ||
* | ||
* Note: There are 3 simmilar function: | ||
* Note: There are multiple simmilar function: | ||
* - `extractBlock` just extracts the content of the code block which is also used as build-in function for postprocessing | ||
* - `extractJsonBlock` extracts exactly one valid JSON code block | ||
* - `extractOneBlockFromMarkdown` extracts exactly one code block with language of the code block | ||
* - `extractAllBlocksFromMarkdown` extracts all code blocks with language of the code block | ||
* | ||
* @public exported from `@promptbook/utils` | ||
* @public exported from `@promptbook/markdown-utils` | ||
* @throws {ParsingError} if there is not exactly one code block in the markdown | ||
*/ | ||
export declare function extractBlock(markdown: string_markdown): string; | ||
/** | ||
* TODO: [π§ ][π»] Maybe export through `@promptbook/markdown-utils` not `@promptbook/utils` | ||
*/ |
@@ -22,4 +22,5 @@ import type { string_markdown } from '../../types/typeAliases'; | ||
* | ||
* Note: There are 3 simmilar function: | ||
* Note: There are multiple simmilar function: | ||
* - `extractBlock` just extracts the content of the code block which is also used as build-in function for postprocessing | ||
* - `extractJsonBlock` extracts exactly one valid JSON code block | ||
* - `extractOneBlockFromMarkdown` extracts exactly one code block with language of the code block | ||
@@ -30,2 +31,3 @@ * - `extractAllBlocksFromMarkdown` extracts all code blocks with language of the code block | ||
* @returns code blocks with language and content | ||
* @throws {ParsingError} if block is not closed properly | ||
* @public exported from `@promptbook/markdown-utils` | ||
@@ -32,0 +34,0 @@ */ |
@@ -6,6 +6,7 @@ import type { string_markdown } from '../../types/typeAliases'; | ||
* | ||
* Note: If there are multiple or no code blocks the function throws an error | ||
* - When there are multiple or no code blocks the function throws a `ParsingError` | ||
* | ||
* Note: There are 3 simmilar function: | ||
* Note: There are multiple simmilar function: | ||
* - `extractBlock` just extracts the content of the code block which is also used as build-in function for postprocessing | ||
* - `extractJsonBlock` extracts exactly one valid JSON code block | ||
* - `extractOneBlockFromMarkdown` extracts exactly one code block with language of the code block | ||
@@ -17,2 +18,3 @@ * - `extractAllBlocksFromMarkdown` extracts all code blocks with language of the code block | ||
* @public exported from `@promptbook/markdown-utils` | ||
* @throws {ParsingError} if there is not exactly one code block in the markdown | ||
*/ | ||
@@ -19,0 +21,0 @@ export declare function extractOneBlockFromMarkdown(markdown: string_markdown): CodeBlock; |
{ | ||
"name": "@promptbook/anthropic-claude", | ||
"version": "0.67.4", | ||
"version": "0.67.5", | ||
"description": "Supercharge your use of large language models", | ||
@@ -50,3 +50,3 @@ "private": false, | ||
"peerDependencies": { | ||
"@promptbook/core": "0.67.4" | ||
"@promptbook/core": "0.67.5" | ||
}, | ||
@@ -53,0 +53,0 @@ "dependencies": { |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
635631
477
11572