@promptbook/remote-client 0.60.1 → 0.61.0-1
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/README.md +4 -6
- package/esm/index.es.js +30 -4
- package/esm/index.es.js.map +1 -1
- package/esm/typings/promptbook-collection/index.d.ts +61 -4
- package/esm/typings/src/_packages/core.index.d.ts +8 -8
- package/esm/typings/src/_packages/markdown-utils.d.ts +17 -0
- package/esm/typings/src/_packages/types.index.d.ts +11 -6
- package/esm/typings/src/_packages/utils.index.d.ts +23 -19
- package/esm/typings/src/cli/cli-commands/hello.d.ts +7 -0
- package/esm/typings/src/cli/cli-commands/make.d.ts +7 -0
- package/esm/typings/src/cli/cli-commands/prettify.d.ts +7 -0
- package/esm/typings/src/collection/collectionToJson.d.ts +3 -0
- package/esm/typings/src/collection/collectionToJson.test.d.ts +6 -0
- package/esm/typings/src/collection/constructors/createCollectionFromDirectory.d.ts +2 -1
- package/esm/typings/src/commands/BLOCK/BlockCommand.d.ts +11 -0
- package/esm/typings/src/commands/BLOCK/BlockTypes.d.ts +13 -0
- package/esm/typings/src/commands/BLOCK/blockCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/EXPECT/ExpectAmountCommand.d.ts +14 -0
- package/esm/typings/src/commands/EXPECT/ExpectCommand.d.ts +9 -0
- package/esm/typings/src/commands/EXPECT/ExpectFormatCommand.d.ts +7 -0
- package/esm/typings/src/commands/EXPECT/expectCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/JOKER/JokerCommand.d.ts +11 -0
- package/esm/typings/src/commands/JOKER/jokerCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/KNOWLEDGE/KnowledgeCommand.d.ts +12 -0
- package/esm/typings/src/commands/KNOWLEDGE/knowledgeCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/MODEL/ModelCommand.d.ts +13 -0
- package/esm/typings/src/commands/MODEL/modelCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/PARAMETER/ParameterCommand.d.ts +15 -0
- package/esm/typings/src/commands/PARAMETER/parameterCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/PERSONA/PersonaCommand.d.ts +11 -0
- package/esm/typings/src/commands/PERSONA/personaCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/POSTPROCESS/PostprocessCommand.d.ts +11 -0
- package/esm/typings/src/commands/POSTPROCESS/postprocessCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/PROMPTBOOK_VERSION/PromptbookVersionCommand.d.ts +11 -0
- package/esm/typings/src/commands/PROMPTBOOK_VERSION/promptbookVersionCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/URL/UrlCommand.d.ts +10 -0
- package/esm/typings/src/commands/URL/urlCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/X_ACTION/ActionCommand.d.ts +9 -0
- package/esm/typings/src/commands/X_ACTION/actionCommand.test.d.ts +1 -0
- package/esm/typings/src/commands/X_ACTION/actionCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/X_INSTRUMENT/InstrumentCommand.d.ts +9 -0
- package/esm/typings/src/commands/X_INSTRUMENT/instrumentCommand.test.d.ts +1 -0
- package/esm/typings/src/commands/X_INSTRUMENT/instrumentCommandParser.d.ts +9 -0
- package/esm/typings/src/commands/_BOILERPLATE/BoilerplateCommand.d.ts +10 -0
- package/esm/typings/src/commands/_BOILERPLATE/boilerplateCommand.test.d.ts +1 -0
- package/esm/typings/src/commands/_BOILERPLATE/boilerplateCommandParser.d.ts +12 -0
- package/esm/typings/src/commands/_common/parseCommand.d.ts +12 -0
- package/esm/typings/src/commands/_common/parseCommand.test.d.ts +1 -0
- package/esm/typings/src/commands/_common/types/Command.d.ts +6 -0
- package/esm/typings/src/commands/_common/types/CommandParser.d.ts +36 -0
- package/esm/typings/src/commands/_common/types/CommandUsagePlaces.d.ts +9 -0
- package/esm/typings/src/commands/index.d.ts +4 -0
- package/esm/typings/src/config.d.ts +4 -0
- package/esm/typings/src/conversion/pipelineJsonToString.d.ts +2 -0
- package/esm/typings/src/conversion/pipelineStringToJson.d.ts +2 -3
- package/esm/typings/src/conversion/pipelineStringToJsonSync.d.ts +4 -2
- package/esm/typings/src/conversion/utils/extractParametersFromPromptTemplate.d.ts +2 -2
- package/esm/typings/src/conversion/utils/extractVariables.d.ts +1 -1
- package/esm/typings/src/conversion/validation/validatePipeline-logicErrors.test.d.ts +3 -0
- package/esm/typings/src/errors/NotYetImplementedError.d.ts +7 -0
- package/esm/typings/src/errors/{SyntaxError.d.ts → ParsingError.d.ts} +2 -2
- package/{umd/typings/src/errors/ExecutionError.d.ts → esm/typings/src/errors/PipelineExecutionError.d.ts} +2 -2
- package/esm/typings/src/errors/_ExpectError.d.ts +2 -2
- package/esm/typings/src/execution/ExecutionTools.d.ts +4 -3
- package/esm/typings/src/execution/LlmExecutionTools.d.ts +24 -5
- package/esm/typings/src/execution/PromptResult.d.ts +2 -2
- package/esm/typings/src/execution/assertsExecutionSuccessful.d.ts +1 -1
- package/esm/typings/src/execution/translation/automatic-translate/automatic-translators/utils/extractMultiplicatedOccurrence.d.ts +1 -1
- package/esm/typings/src/execution/utils/checkExpectations.d.ts +1 -1
- package/esm/typings/src/execution/utils/replaceParameters.d.ts +1 -1
- package/esm/typings/src/knowledge/prepare-knowledge/markdown/prepareKnowledgeFromMarkdown.d.ts +5 -0
- package/esm/typings/src/llm-providers/anthropic-claude/AnthropicClaudeExecutionTools.d.ts +5 -5
- package/esm/typings/src/llm-providers/anthropic-claude/anthropic-claude-models.d.ts +1 -0
- package/esm/typings/src/llm-providers/azure-openai/AzureOpenAiExecutionTools.d.ts +5 -0
- package/esm/typings/src/llm-providers/langtail/LangtailExecutionTools.d.ts +5 -0
- package/esm/typings/src/llm-providers/mocked/MockedEchoLlmExecutionTools.d.ts +5 -0
- package/esm/typings/src/llm-providers/mocked/MockedFackedLlmExecutionTools.d.ts +10 -0
- package/esm/typings/src/llm-providers/mocked/fakeTextToExpectations.d.ts +1 -1
- package/esm/typings/src/llm-providers/mocked/test/fakeTextToExpectations.test.d.ts +1 -0
- package/esm/typings/src/llm-providers/mocked/test/faked-completion.test.d.ts +1 -0
- package/esm/typings/src/llm-providers/mocked/test/mocked-chat.test.d.ts +5 -0
- package/esm/typings/src/llm-providers/multiple/MultipleLlmExecutionTools.d.ts +14 -1
- package/esm/typings/src/llm-providers/multiple/joinLlmExecutionTools.d.ts +16 -0
- package/esm/typings/src/llm-providers/openai/OpenAiExecutionTools.d.ts +6 -1
- package/esm/typings/src/llm-providers/openai/computeOpenaiUsage.d.ts +1 -1
- package/esm/typings/src/llm-providers/openai/openai-models.d.ts +1 -0
- package/esm/typings/src/llm-providers/remote/RemoteLlmExecutionTools.d.ts +13 -3
- package/esm/typings/src/llm-providers/remote/startRemoteServer.d.ts +1 -0
- package/esm/typings/src/personas/personaToModelRequirements.d.ts +6 -0
- package/esm/typings/src/scripting/javascript/utils/preserve.d.ts +2 -1
- package/esm/typings/src/types/Arrayable.d.ts +10 -0
- package/esm/typings/src/types/PipelineJson/Expectations.d.ts +28 -0
- package/esm/typings/src/types/PipelineJson/LlmTemplateJson.d.ts +16 -0
- package/esm/typings/src/types/PipelineJson/PipelineJson.d.ts +8 -2
- package/esm/typings/src/types/PipelineJson/PromptDialogJson.d.ts +7 -0
- package/esm/typings/src/types/PipelineJson/PromptTemplateJson.d.ts +6 -142
- package/esm/typings/src/types/PipelineJson/PromptTemplateJsonCommon.d.ts +77 -0
- package/esm/typings/src/types/PipelineJson/ScriptJson.d.ts +14 -0
- package/esm/typings/src/types/PipelineJson/SimpleTemplateJson.d.ts +7 -0
- package/esm/typings/src/types/Prompt.d.ts +3 -3
- package/esm/typings/src/types/TaskProgress.d.ts +2 -2
- package/esm/typings/src/types/execution-report/ExecutionReportJson.d.ts +3 -3
- package/esm/typings/src/types/typeAliases.d.ts +50 -6
- package/esm/typings/src/utils/arrayableToArray.d.ts +11 -0
- package/esm/typings/src/utils/arrayableToArray.test.d.ts +1 -0
- package/esm/typings/src/utils/emojis.d.ts +1 -0
- package/esm/typings/src/utils/expectation-counters/countCharacters.d.ts +1 -1
- package/esm/typings/src/utils/expectation-counters/countLines.d.ts +1 -1
- package/esm/typings/src/utils/expectation-counters/countPages.d.ts +1 -1
- package/esm/typings/src/utils/expectation-counters/countParagraphs.d.ts +1 -1
- package/esm/typings/src/utils/expectation-counters/countSentences.d.ts +1 -1
- package/esm/typings/src/utils/expectation-counters/countWords.d.ts +1 -1
- package/esm/typings/src/utils/expectation-counters/index.d.ts +2 -2
- package/esm/typings/src/utils/markdown/flattenMarkdown.d.ts +14 -0
- package/esm/typings/src/utils/markdown/flattenMarkdown.test.d.ts +1 -0
- package/esm/typings/src/utils/markdown/parseMarkdownSection.d.ts +30 -0
- package/esm/typings/src/utils/markdown/parseMarkdownSection.test.d.ts +1 -0
- package/esm/typings/src/utils/markdown/prettifyMarkdown.d.ts +1 -0
- package/esm/typings/src/utils/markdown/splitMarkdownIntoSections.d.ts +12 -0
- package/esm/typings/src/utils/markdown/splitMarkdownIntoSections.test.d.ts +1 -0
- package/esm/typings/src/utils/normalization/normalize-to-kebab-case.d.ts +8 -1
- package/esm/typings/src/utils/normalization/normalizeTo_PascalCase.d.ts +8 -1
- package/esm/typings/src/utils/normalization/normalizeTo_SCREAMING_CASE.d.ts +13 -1
- package/esm/typings/src/utils/normalization/normalizeTo_camelCase.d.ts +8 -1
- package/esm/typings/src/utils/normalization/normalizeTo_snake_case.d.ts +8 -1
- package/esm/typings/src/{conversion/utils → utils}/parseNumber.d.ts +1 -1
- package/esm/typings/src/utils/parseNumber.test.d.ts +1 -0
- package/esm/typings/src/utils/sets/difference.d.ts +2 -0
- package/esm/typings/src/utils/sets/intersection.d.ts +2 -0
- package/esm/typings/src/utils/sets/union.d.ts +2 -0
- package/esm/typings/src/utils/validators/email/isValidEmail.d.ts +5 -0
- package/esm/typings/src/utils/validators/email/isValidEmail.test.d.ts +1 -0
- package/esm/typings/src/utils/validators/filePath/isValidFilePath.d.ts +7 -0
- package/esm/typings/src/utils/validators/filePath/isValidFilePath.test.d.ts +1 -0
- package/esm/typings/src/utils/validators/javascriptName/isValidJavascriptName.d.ts +2 -0
- package/esm/typings/src/utils/validators/javascriptName/isValidJavascriptName.test.d.ts +1 -0
- package/esm/typings/src/utils/validators/semanticVersion/isValidPromptbookVersion.d.ts +12 -0
- package/esm/typings/src/utils/validators/semanticVersion/isValidPromptbookVersion.test.d.ts +1 -0
- package/esm/typings/src/utils/validators/semanticVersion/isValidSemanticVersion.d.ts +9 -0
- package/esm/typings/src/utils/validators/semanticVersion/isValidSemanticVersion.test.d.ts +1 -0
- package/esm/typings/src/utils/validators/url/isHostnameOnPrivateNetwork.d.ts +9 -0
- package/esm/typings/src/utils/validators/url/isHostnameOnPrivateNetwork.test.d.ts +1 -0
- package/esm/typings/src/utils/validators/url/isUrlOnPrivateNetwork.d.ts +12 -0
- package/esm/typings/src/utils/validators/url/isUrlOnPrivateNetwork.test.d.ts +1 -0
- package/esm/typings/src/utils/validators/url/isValidPipelineUrl.d.ts +12 -0
- package/esm/typings/src/utils/validators/url/isValidPipelineUrl.test.d.ts +1 -0
- package/esm/typings/src/utils/validators/url/isValidUrl.d.ts +3 -0
- package/esm/typings/src/utils/validators/uuid/isValidUuid.d.ts +5 -0
- package/esm/typings/src/utils/validators/uuid/isValidUuid.test.d.ts +1 -0
- package/esm/typings/src/version.d.ts +3 -2
- package/package.json +2 -2
- package/umd/index.umd.js +30 -4
- package/umd/index.umd.js.map +1 -1
- package/umd/typings/promptbook-collection/index.d.ts +61 -4
- package/umd/typings/src/_packages/core.index.d.ts +8 -8
- package/umd/typings/src/_packages/markdown-utils.d.ts +17 -0
- package/umd/typings/src/_packages/types.index.d.ts +11 -6
- package/umd/typings/src/_packages/utils.index.d.ts +23 -19
- package/umd/typings/src/cli/cli-commands/hello.d.ts +7 -0
- package/umd/typings/src/cli/cli-commands/make.d.ts +7 -0
- package/umd/typings/src/cli/cli-commands/prettify.d.ts +7 -0
- package/umd/typings/src/collection/collectionToJson.d.ts +3 -0
- package/umd/typings/src/collection/collectionToJson.test.d.ts +6 -0
- package/umd/typings/src/collection/constructors/createCollectionFromDirectory.d.ts +2 -1
- package/umd/typings/src/commands/BLOCK/BlockCommand.d.ts +11 -0
- package/umd/typings/src/commands/BLOCK/BlockTypes.d.ts +13 -0
- package/umd/typings/src/commands/BLOCK/blockCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/BLOCK/blockCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/EXPECT/ExpectAmountCommand.d.ts +14 -0
- package/umd/typings/src/commands/EXPECT/ExpectCommand.d.ts +9 -0
- package/umd/typings/src/commands/EXPECT/ExpectFormatCommand.d.ts +7 -0
- package/umd/typings/src/commands/EXPECT/expectCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/EXPECT/expectCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/JOKER/JokerCommand.d.ts +11 -0
- package/umd/typings/src/commands/JOKER/jokerCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/JOKER/jokerCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/KNOWLEDGE/KnowledgeCommand.d.ts +12 -0
- package/umd/typings/src/commands/KNOWLEDGE/knowledgeCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/KNOWLEDGE/knowledgeCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/MODEL/ModelCommand.d.ts +13 -0
- package/umd/typings/src/commands/MODEL/modelCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/MODEL/modelCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/PARAMETER/ParameterCommand.d.ts +15 -0
- package/umd/typings/src/commands/PARAMETER/parameterCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/PARAMETER/parameterCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/PERSONA/PersonaCommand.d.ts +11 -0
- package/umd/typings/src/commands/PERSONA/personaCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/PERSONA/personaCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/POSTPROCESS/PostprocessCommand.d.ts +11 -0
- package/umd/typings/src/commands/POSTPROCESS/postprocessCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/POSTPROCESS/postprocessCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/PROMPTBOOK_VERSION/PromptbookVersionCommand.d.ts +11 -0
- package/umd/typings/src/commands/PROMPTBOOK_VERSION/promptbookVersionCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/PROMPTBOOK_VERSION/promptbookVersionCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/URL/UrlCommand.d.ts +10 -0
- package/umd/typings/src/commands/URL/urlCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/URL/urlCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/X_ACTION/ActionCommand.d.ts +9 -0
- package/umd/typings/src/commands/X_ACTION/actionCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/X_ACTION/actionCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/X_INSTRUMENT/InstrumentCommand.d.ts +9 -0
- package/umd/typings/src/commands/X_INSTRUMENT/instrumentCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/X_INSTRUMENT/instrumentCommandParser.d.ts +9 -0
- package/umd/typings/src/commands/_BOILERPLATE/BoilerplateCommand.d.ts +10 -0
- package/umd/typings/src/commands/_BOILERPLATE/boilerplateCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/_BOILERPLATE/boilerplateCommandParser.d.ts +12 -0
- package/umd/typings/src/commands/_common/parseCommand.d.ts +12 -0
- package/umd/typings/src/commands/_common/parseCommand.test.d.ts +1 -0
- package/umd/typings/src/commands/_common/types/Command.d.ts +6 -0
- package/umd/typings/src/commands/_common/types/CommandParser.d.ts +36 -0
- package/umd/typings/src/commands/_common/types/CommandUsagePlaces.d.ts +9 -0
- package/umd/typings/src/commands/index.d.ts +4 -0
- package/umd/typings/src/config.d.ts +4 -0
- package/umd/typings/src/conversion/pipelineJsonToString.d.ts +2 -0
- package/umd/typings/src/conversion/pipelineStringToJson.d.ts +2 -3
- package/umd/typings/src/conversion/pipelineStringToJsonSync.d.ts +4 -2
- package/umd/typings/src/conversion/utils/extractParametersFromPromptTemplate.d.ts +2 -2
- package/umd/typings/src/conversion/utils/extractVariables.d.ts +1 -1
- package/umd/typings/src/conversion/validation/validatePipeline-logicErrors.test.d.ts +3 -0
- package/umd/typings/src/errors/NotYetImplementedError.d.ts +7 -0
- package/umd/typings/src/errors/{SyntaxError.d.ts → ParsingError.d.ts} +2 -2
- package/{esm/typings/src/errors/ExecutionError.d.ts → umd/typings/src/errors/PipelineExecutionError.d.ts} +2 -2
- package/umd/typings/src/errors/_ExpectError.d.ts +2 -2
- package/umd/typings/src/execution/ExecutionTools.d.ts +4 -3
- package/umd/typings/src/execution/LlmExecutionTools.d.ts +24 -5
- package/umd/typings/src/execution/PromptResult.d.ts +2 -2
- package/umd/typings/src/execution/assertsExecutionSuccessful.d.ts +1 -1
- package/umd/typings/src/execution/translation/automatic-translate/automatic-translators/utils/extractMultiplicatedOccurrence.d.ts +1 -1
- package/umd/typings/src/execution/utils/checkExpectations.d.ts +1 -1
- package/umd/typings/src/execution/utils/replaceParameters.d.ts +1 -1
- package/umd/typings/src/knowledge/prepare-knowledge/markdown/prepareKnowledgeFromMarkdown.d.ts +5 -0
- package/umd/typings/src/llm-providers/anthropic-claude/AnthropicClaudeExecutionTools.d.ts +5 -5
- package/umd/typings/src/llm-providers/anthropic-claude/anthropic-claude-models.d.ts +1 -0
- package/umd/typings/src/llm-providers/azure-openai/AzureOpenAiExecutionTools.d.ts +5 -0
- package/umd/typings/src/llm-providers/langtail/LangtailExecutionTools.d.ts +5 -0
- package/umd/typings/src/llm-providers/mocked/MockedEchoLlmExecutionTools.d.ts +5 -0
- package/umd/typings/src/llm-providers/mocked/MockedFackedLlmExecutionTools.d.ts +10 -0
- package/umd/typings/src/llm-providers/mocked/fakeTextToExpectations.d.ts +1 -1
- package/umd/typings/src/llm-providers/mocked/test/fakeTextToExpectations.test.d.ts +1 -0
- package/umd/typings/src/llm-providers/mocked/test/faked-completion.test.d.ts +1 -0
- package/umd/typings/src/llm-providers/mocked/test/mocked-chat.test.d.ts +5 -0
- package/umd/typings/src/llm-providers/multiple/MultipleLlmExecutionTools.d.ts +14 -1
- package/umd/typings/src/llm-providers/multiple/joinLlmExecutionTools.d.ts +16 -0
- package/umd/typings/src/llm-providers/openai/OpenAiExecutionTools.d.ts +6 -1
- package/umd/typings/src/llm-providers/openai/computeOpenaiUsage.d.ts +1 -1
- package/umd/typings/src/llm-providers/openai/openai-models.d.ts +1 -0
- package/umd/typings/src/llm-providers/remote/RemoteLlmExecutionTools.d.ts +13 -3
- package/umd/typings/src/llm-providers/remote/startRemoteServer.d.ts +1 -0
- package/umd/typings/src/personas/personaToModelRequirements.d.ts +6 -0
- package/umd/typings/src/scripting/javascript/utils/preserve.d.ts +2 -1
- package/umd/typings/src/types/Arrayable.d.ts +10 -0
- package/umd/typings/src/types/PipelineJson/Expectations.d.ts +28 -0
- package/umd/typings/src/types/PipelineJson/LlmTemplateJson.d.ts +16 -0
- package/umd/typings/src/types/PipelineJson/PipelineJson.d.ts +8 -2
- package/umd/typings/src/types/PipelineJson/PromptDialogJson.d.ts +7 -0
- package/umd/typings/src/types/PipelineJson/PromptTemplateJson.d.ts +6 -142
- package/umd/typings/src/types/PipelineJson/PromptTemplateJsonCommon.d.ts +77 -0
- package/umd/typings/src/types/PipelineJson/ScriptJson.d.ts +14 -0
- package/umd/typings/src/types/PipelineJson/SimpleTemplateJson.d.ts +7 -0
- package/umd/typings/src/types/Prompt.d.ts +3 -3
- package/umd/typings/src/types/TaskProgress.d.ts +2 -2
- package/umd/typings/src/types/execution-report/ExecutionReportJson.d.ts +3 -3
- package/umd/typings/src/types/typeAliases.d.ts +50 -6
- package/umd/typings/src/utils/arrayableToArray.d.ts +11 -0
- package/umd/typings/src/utils/arrayableToArray.test.d.ts +1 -0
- package/umd/typings/src/utils/emojis.d.ts +1 -0
- package/umd/typings/src/utils/expectation-counters/countCharacters.d.ts +1 -1
- package/umd/typings/src/utils/expectation-counters/countLines.d.ts +1 -1
- package/umd/typings/src/utils/expectation-counters/countPages.d.ts +1 -1
- package/umd/typings/src/utils/expectation-counters/countParagraphs.d.ts +1 -1
- package/umd/typings/src/utils/expectation-counters/countSentences.d.ts +1 -1
- package/umd/typings/src/utils/expectation-counters/countWords.d.ts +1 -1
- package/umd/typings/src/utils/expectation-counters/index.d.ts +2 -2
- package/umd/typings/src/utils/markdown/flattenMarkdown.d.ts +14 -0
- package/umd/typings/src/utils/markdown/flattenMarkdown.test.d.ts +1 -0
- package/umd/typings/src/utils/markdown/parseMarkdownSection.d.ts +30 -0
- package/umd/typings/src/utils/markdown/parseMarkdownSection.test.d.ts +1 -0
- package/umd/typings/src/utils/markdown/prettifyMarkdown.d.ts +1 -0
- package/umd/typings/src/utils/markdown/splitMarkdownIntoSections.d.ts +12 -0
- package/umd/typings/src/utils/markdown/splitMarkdownIntoSections.test.d.ts +1 -0
- package/umd/typings/src/utils/normalization/normalize-to-kebab-case.d.ts +8 -1
- package/umd/typings/src/utils/normalization/normalizeTo_PascalCase.d.ts +8 -1
- package/umd/typings/src/utils/normalization/normalizeTo_SCREAMING_CASE.d.ts +13 -1
- package/umd/typings/src/utils/normalization/normalizeTo_camelCase.d.ts +8 -1
- package/umd/typings/src/utils/normalization/normalizeTo_snake_case.d.ts +8 -1
- package/umd/typings/src/{conversion/utils → utils}/parseNumber.d.ts +1 -1
- package/umd/typings/src/utils/parseNumber.test.d.ts +1 -0
- package/umd/typings/src/utils/sets/difference.d.ts +2 -0
- package/umd/typings/src/utils/sets/intersection.d.ts +2 -0
- package/umd/typings/src/utils/sets/union.d.ts +2 -0
- package/umd/typings/src/utils/validators/email/isValidEmail.d.ts +5 -0
- package/umd/typings/src/utils/validators/email/isValidEmail.test.d.ts +1 -0
- package/umd/typings/src/utils/validators/filePath/isValidFilePath.d.ts +7 -0
- package/umd/typings/src/utils/validators/filePath/isValidFilePath.test.d.ts +1 -0
- package/umd/typings/src/utils/validators/javascriptName/isValidJavascriptName.d.ts +2 -0
- package/umd/typings/src/utils/validators/javascriptName/isValidJavascriptName.test.d.ts +1 -0
- package/umd/typings/src/utils/validators/semanticVersion/isValidPromptbookVersion.d.ts +12 -0
- package/umd/typings/src/utils/validators/semanticVersion/isValidPromptbookVersion.test.d.ts +1 -0
- package/umd/typings/src/utils/validators/semanticVersion/isValidSemanticVersion.d.ts +9 -0
- package/umd/typings/src/utils/validators/semanticVersion/isValidSemanticVersion.test.d.ts +1 -0
- package/umd/typings/src/utils/validators/url/isHostnameOnPrivateNetwork.d.ts +9 -0
- package/umd/typings/src/utils/validators/url/isHostnameOnPrivateNetwork.test.d.ts +1 -0
- package/umd/typings/src/utils/validators/url/isUrlOnPrivateNetwork.d.ts +12 -0
- package/umd/typings/src/utils/validators/url/isUrlOnPrivateNetwork.test.d.ts +1 -0
- package/umd/typings/src/utils/validators/url/isValidPipelineUrl.d.ts +12 -0
- package/umd/typings/src/utils/validators/url/isValidPipelineUrl.test.d.ts +1 -0
- package/umd/typings/src/utils/validators/url/isValidUrl.d.ts +3 -0
- package/umd/typings/src/utils/validators/uuid/isValidUuid.d.ts +5 -0
- package/umd/typings/src/utils/validators/uuid/isValidUuid.test.d.ts +1 -0
- package/umd/typings/src/version.d.ts +3 -2
- package/esm/typings/src/cli/actions/hello.d.ts +0 -7
- package/esm/typings/src/cli/actions/make.d.ts +0 -7
- package/esm/typings/src/cli/actions/prettify.d.ts +0 -7
- package/esm/typings/src/conversion/utils/parseCommand.d.ts +0 -11
- package/esm/typings/src/conversion/utils/parseCommand.test.d.ts +0 -4
- package/esm/typings/src/errors/TemplateError.d.ts +0 -9
- package/esm/typings/src/llm-providers/mocked/mocked-chat.test.d.ts +0 -4
- package/esm/typings/src/llm-providers/multiple/MultipleLlmExecutionToolsOptions.d.ts +0 -24
- package/esm/typings/src/types/Command.d.ts +0 -101
- package/esm/typings/src/types/ExecutionTypes.d.ts +0 -13
- package/esm/typings/src/utils/markdown-json/MarkdownStructure.d.ts +0 -25
- package/esm/typings/src/utils/markdown-json/countMarkdownStructureDeepness.d.ts +0 -7
- package/esm/typings/src/utils/markdown-json/markdownToMarkdownStructure.d.ts +0 -13
- package/umd/typings/src/cli/actions/hello.d.ts +0 -7
- package/umd/typings/src/cli/actions/make.d.ts +0 -7
- package/umd/typings/src/cli/actions/prettify.d.ts +0 -7
- package/umd/typings/src/conversion/utils/parseCommand.d.ts +0 -11
- package/umd/typings/src/conversion/utils/parseCommand.test.d.ts +0 -4
- package/umd/typings/src/errors/TemplateError.d.ts +0 -9
- package/umd/typings/src/llm-providers/mocked/mocked-chat.test.d.ts +0 -4
- package/umd/typings/src/llm-providers/multiple/MultipleLlmExecutionToolsOptions.d.ts +0 -24
- package/umd/typings/src/types/Command.d.ts +0 -101
- package/umd/typings/src/types/ExecutionTypes.d.ts +0 -13
- package/umd/typings/src/utils/markdown-json/MarkdownStructure.d.ts +0 -25
- package/umd/typings/src/utils/markdown-json/countMarkdownStructureDeepness.d.ts +0 -7
- package/umd/typings/src/utils/markdown-json/markdownToMarkdownStructure.d.ts +0 -13
- /package/esm/typings/src/{conversion/utils/parseNumber.test.d.ts → commands/BLOCK/blockCommand.test.d.ts} +0 -0
- /package/esm/typings/src/{llm-providers/mocked/fakeTextToExpectations.test.d.ts → commands/EXPECT/expectCommand.test.d.ts} +0 -0
- /package/esm/typings/src/{llm-providers/mocked/faked-completion.test.d.ts → commands/JOKER/jokerCommand.test.d.ts} +0 -0
- /package/esm/typings/src/{utils/markdown-json/countMarkdownStructureDeepness.test.d.ts → commands/KNOWLEDGE/knowledgeCommand.test.d.ts} +0 -0
- /package/esm/typings/src/{utils/markdown-json/markdownToMarkdownStructure.test.d.ts → commands/MODEL/modelCommand.test.d.ts} +0 -0
- /package/{umd/typings/src/conversion/utils/parseNumber.test.d.ts → esm/typings/src/commands/PARAMETER/parameterCommand.test.d.ts} +0 -0
- /package/{umd/typings/src/llm-providers/mocked/fakeTextToExpectations.test.d.ts → esm/typings/src/commands/PERSONA/personaCommand.test.d.ts} +0 -0
- /package/{umd/typings/src/llm-providers/mocked/faked-completion.test.d.ts → esm/typings/src/commands/POSTPROCESS/postprocessCommand.test.d.ts} +0 -0
- /package/{umd/typings/src/utils/markdown-json/countMarkdownStructureDeepness.test.d.ts → esm/typings/src/commands/PROMPTBOOK_VERSION/promptbookVersionCommand.test.d.ts} +0 -0
- /package/{umd/typings/src/utils/markdown-json/markdownToMarkdownStructure.test.d.ts → esm/typings/src/commands/URL/urlCommand.test.d.ts} +0 -0
- /package/esm/typings/src/llm-providers/mocked/{joker.test.d.ts → test/joker.test.d.ts} +0 -0
- /package/esm/typings/src/llm-providers/mocked/{mocked-completion.test.d.ts → test/mocked-completion.test.d.ts} +0 -0
- /package/umd/typings/src/llm-providers/mocked/{joker.test.d.ts → test/joker.test.d.ts} +0 -0
- /package/umd/typings/src/llm-providers/mocked/{mocked-completion.test.d.ts → test/mocked-completion.test.d.ts} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { string_semantic_version } from './types/typeAliases';
|
|
2
2
|
/**
|
|
3
3
|
* The version of the Promptbook library
|
|
4
4
|
*/
|
|
5
|
-
export declare const PROMPTBOOK_VERSION:
|
|
5
|
+
export declare const PROMPTBOOK_VERSION: string_promptbook_version;
|
|
6
|
+
export type string_promptbook_version = string_semantic_version;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@promptbook/remote-client",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.61.0-1",
|
|
4
4
|
"description": "Supercharge your use of large language models",
|
|
5
5
|
"private": false,
|
|
6
6
|
"sideEffects": false,
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
}
|
|
48
48
|
],
|
|
49
49
|
"peerDependencies": {
|
|
50
|
-
"@promptbook/core": "0.
|
|
50
|
+
"@promptbook/core": "0.61.0-1"
|
|
51
51
|
},
|
|
52
52
|
"main": "./umd/index.umd.js",
|
|
53
53
|
"module": "./esm/index.es.js",
|
package/umd/index.umd.js
CHANGED
|
@@ -69,6 +69,21 @@
|
|
|
69
69
|
function RemoteLlmExecutionTools(options) {
|
|
70
70
|
this.options = options;
|
|
71
71
|
}
|
|
72
|
+
Object.defineProperty(RemoteLlmExecutionTools.prototype, "title", {
|
|
73
|
+
get: function () {
|
|
74
|
+
// TODO: [🧠] Maybe fetch title+description from the remote server (as well as if model methods are defined)
|
|
75
|
+
return 'Remote server';
|
|
76
|
+
},
|
|
77
|
+
enumerable: false,
|
|
78
|
+
configurable: true
|
|
79
|
+
});
|
|
80
|
+
Object.defineProperty(RemoteLlmExecutionTools.prototype, "description", {
|
|
81
|
+
get: function () {
|
|
82
|
+
return 'Use all models by your remote server';
|
|
83
|
+
},
|
|
84
|
+
enumerable: false,
|
|
85
|
+
configurable: true
|
|
86
|
+
});
|
|
72
87
|
/**
|
|
73
88
|
* Creates a connection to the remote proxy server.
|
|
74
89
|
*/
|
|
@@ -90,7 +105,7 @@
|
|
|
90
105
|
});
|
|
91
106
|
};
|
|
92
107
|
/**
|
|
93
|
-
* Calls remote proxy server to use a chat model
|
|
108
|
+
* Calls remote proxy server to use a chat model
|
|
94
109
|
*/
|
|
95
110
|
RemoteLlmExecutionTools.prototype.callChatModel = function (prompt) {
|
|
96
111
|
if (this.options.isVerbose) {
|
|
@@ -99,7 +114,7 @@
|
|
|
99
114
|
return /* not await */ this.callModelCommon(prompt);
|
|
100
115
|
};
|
|
101
116
|
/**
|
|
102
|
-
* Calls remote proxy server to use a completion model
|
|
117
|
+
* Calls remote proxy server to use a completion model
|
|
103
118
|
*/
|
|
104
119
|
RemoteLlmExecutionTools.prototype.callCompletionModel = function (prompt) {
|
|
105
120
|
if (this.options.isVerbose) {
|
|
@@ -108,7 +123,17 @@
|
|
|
108
123
|
return /* not await */ this.callModelCommon(prompt);
|
|
109
124
|
};
|
|
110
125
|
/**
|
|
111
|
-
* Calls remote proxy server to use
|
|
126
|
+
* Calls remote proxy server to use a embedding model
|
|
127
|
+
*/
|
|
128
|
+
RemoteLlmExecutionTools.prototype.callEmbeddingModel = function (prompt) {
|
|
129
|
+
if (this.options.isVerbose) {
|
|
130
|
+
console.info("\uD83D\uDCAC Remote callEmbeddingModel call");
|
|
131
|
+
}
|
|
132
|
+
return /* not await */ this.callModelCommon(prompt);
|
|
133
|
+
};
|
|
134
|
+
// <- Note: [🤖] callXxxModel
|
|
135
|
+
/**
|
|
136
|
+
* Calls remote proxy server to use both completion or chat model
|
|
112
137
|
*/
|
|
113
138
|
RemoteLlmExecutionTools.prototype.callModelCommon = function (prompt) {
|
|
114
139
|
return __awaiter(this, void 0, void 0, function () {
|
|
@@ -160,7 +185,8 @@
|
|
|
160
185
|
/**
|
|
161
186
|
* The version of the Promptbook library
|
|
162
187
|
*/
|
|
163
|
-
var PROMPTBOOK_VERSION = '0.
|
|
188
|
+
var PROMPTBOOK_VERSION = '0.61.0-0';
|
|
189
|
+
// TODO: !!!! List here all the versions and annotate + put into script
|
|
164
190
|
|
|
165
191
|
exports.PROMPTBOOK_VERSION = PROMPTBOOK_VERSION;
|
|
166
192
|
exports.RemoteLlmExecutionTools = RemoteLlmExecutionTools;
|
package/umd/index.umd.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.umd.js","sources":["../../../node_modules/tslib/tslib.es6.js","../../../../src/llm-providers/remote/RemoteLlmExecutionTools.ts","../../../../src/version.ts"],"sourcesContent":["/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n if (typeof b !== \"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n}\r\n\r\nexport function __spreadArray(to, from, pack) {\r\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\r\n if (ar || !(i in from)) {\r\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\r\n ar[i] = from[i];\r\n }\r\n }\r\n return to.concat(ar || Array.prototype.slice.call(from));\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\r\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\r\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\r\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\r\n}\r\n",null,null],"names":["io"],"mappings":";;;;;;IAAA;IACA;AACA;IACA;IACA;AACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;AAuDA;IACO,SAAS,SAAS,CAAC,OAAO,EAAE,UAAU,EAAE,CAAC,EAAE,SAAS,EAAE;IAC7D,IAAI,SAAS,KAAK,CAAC,KAAK,EAAE,EAAE,OAAO,KAAK,YAAY,CAAC,GAAG,KAAK,GAAG,IAAI,CAAC,CAAC,UAAU,OAAO,EAAE,EAAE,OAAO,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE;IAChH,IAAI,OAAO,KAAK,CAAC,KAAK,CAAC,GAAG,OAAO,CAAC,EAAE,UAAU,OAAO,EAAE,MAAM,EAAE;IAC/D,QAAQ,SAAS,SAAS,CAAC,KAAK,EAAE,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,OAAO,CAAC,EAAE,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,EAAE,EAAE;IACnG,QAAQ,SAAS,QAAQ,CAAC,KAAK,EAAE,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,OAAO,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ACvB,CAAC,CAAC;iCACN,CAAC,EAAA;;4BAVI,YAAY,GAAG,SAUnB;4BAEF,MAAM,CAAC,UAAU,EAAE,CAAC;4BAEpB,sBAAO,YAAY,EAAC;;;;SACvB;;;;QAKY,4CAAU,GAAvB;;;oBACI,sBAAO;;yBAEN,EAAC;;;SACL;QACL,8BAAC;IAAD,CAAC,IAAA;IAED;;;;;ICnGA;;;QAGa,kBAAkB,GAAmB;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"index.umd.js","sources":["../../../node_modules/tslib/tslib.es6.js","../../../../src/llm-providers/remote/RemoteLlmExecutionTools.ts","../../../../src/version.ts"],"sourcesContent":["/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n if (typeof b !== \"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n}\r\n\r\nexport function __spreadArray(to, from, pack) {\r\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\r\n if (ar || !(i in from)) {\r\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\r\n ar[i] = from[i];\r\n }\r\n }\r\n return to.concat(ar || Array.prototype.slice.call(from));\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\r\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\r\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\r\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\r\n}\r\n",null,null],"names":["io"],"mappings":";;;;;;IAAA;IACA;AACA;IACA;IACA;AACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;AAuDA;IACO,SAAS,SA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;;QAGa,kBAAkB,GAA8B,WAAW;IAGxE;;;;;;;;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const _default: {
|
|
1
|
+
declare const _default: ({
|
|
2
2
|
title: string;
|
|
3
3
|
pipelineUrl: string;
|
|
4
4
|
promptbookVersion: string;
|
|
@@ -12,7 +12,7 @@ declare const _default: {
|
|
|
12
12
|
name: string;
|
|
13
13
|
title: string;
|
|
14
14
|
dependentParameterNames: string[];
|
|
15
|
-
|
|
15
|
+
blockType: string;
|
|
16
16
|
modelRequirements: {
|
|
17
17
|
modelVariant: string;
|
|
18
18
|
modelName: string;
|
|
@@ -20,6 +20,63 @@ declare const _default: {
|
|
|
20
20
|
content: string;
|
|
21
21
|
resultingParameterName: string;
|
|
22
22
|
}[];
|
|
23
|
-
knowledge:
|
|
24
|
-
|
|
23
|
+
knowledge: {
|
|
24
|
+
name: string;
|
|
25
|
+
title: string;
|
|
26
|
+
content: string;
|
|
27
|
+
keywords: string[];
|
|
28
|
+
index: {
|
|
29
|
+
modelName: string;
|
|
30
|
+
position: number[];
|
|
31
|
+
}[];
|
|
32
|
+
sources: {
|
|
33
|
+
title: string;
|
|
34
|
+
href: string;
|
|
35
|
+
}[];
|
|
36
|
+
}[];
|
|
37
|
+
sourceFile: string;
|
|
38
|
+
} | {
|
|
39
|
+
title: string;
|
|
40
|
+
pipelineUrl: string;
|
|
41
|
+
promptbookVersion: string;
|
|
42
|
+
parameters: {
|
|
43
|
+
name: string;
|
|
44
|
+
description: string;
|
|
45
|
+
isInput: boolean;
|
|
46
|
+
isOutput: boolean;
|
|
47
|
+
}[];
|
|
48
|
+
promptTemplates: {
|
|
49
|
+
name: string;
|
|
50
|
+
title: string;
|
|
51
|
+
dependentParameterNames: string[];
|
|
52
|
+
blockType: string;
|
|
53
|
+
expectations: {
|
|
54
|
+
words: {
|
|
55
|
+
min: number;
|
|
56
|
+
max: number;
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
modelRequirements: {
|
|
60
|
+
modelVariant: string;
|
|
61
|
+
modelName: string;
|
|
62
|
+
};
|
|
63
|
+
content: string;
|
|
64
|
+
resultingParameterName: string;
|
|
65
|
+
}[];
|
|
66
|
+
knowledge: {
|
|
67
|
+
name: string;
|
|
68
|
+
title: string;
|
|
69
|
+
content: string;
|
|
70
|
+
keywords: string[];
|
|
71
|
+
index: {
|
|
72
|
+
modelName: string;
|
|
73
|
+
position: number[];
|
|
74
|
+
}[];
|
|
75
|
+
sources: {
|
|
76
|
+
title: string;
|
|
77
|
+
href: string;
|
|
78
|
+
}[];
|
|
79
|
+
}[];
|
|
80
|
+
sourceFile: string;
|
|
81
|
+
})[];
|
|
25
82
|
export default _default;
|
|
@@ -3,18 +3,19 @@ import { createCollectionFromJson } from '../collection/constructors/createColle
|
|
|
3
3
|
import { createCollectionFromPromise } from '../collection/constructors/createCollectionFromPromise';
|
|
4
4
|
import { createCollectionFromUrl } from '../collection/constructors/createCollectionFromUrl';
|
|
5
5
|
import { createSubcollection } from '../collection/constructors/createSubcollection';
|
|
6
|
+
import { BlockTypes } from '../commands/BLOCK/BlockTypes';
|
|
7
|
+
import { RESERVED_PARAMETER_NAMES } from '../config';
|
|
6
8
|
import { pipelineJsonToString } from '../conversion/pipelineJsonToString';
|
|
7
9
|
import { pipelineStringToJson } from '../conversion/pipelineStringToJson';
|
|
8
10
|
import { pipelineStringToJsonSync } from '../conversion/pipelineStringToJsonSync';
|
|
9
11
|
import { prettifyPipelineString } from '../conversion/prettify/prettifyPipelineString';
|
|
10
12
|
import { validatePipeline } from '../conversion/validation/validatePipeline';
|
|
11
13
|
import { CollectionError } from '../errors/CollectionError';
|
|
12
|
-
import { ExecutionError } from '../errors/ExecutionError';
|
|
13
14
|
import { NotFoundError } from '../errors/NotFoundError';
|
|
15
|
+
import { ParsingError } from '../errors/ParsingError';
|
|
16
|
+
import { PipelineExecutionError } from '../errors/PipelineExecutionError';
|
|
14
17
|
import { PipelineLogicError } from '../errors/PipelineLogicError';
|
|
15
18
|
import { ReferenceError } from '../errors/ReferenceError';
|
|
16
|
-
import { SyntaxError } from '../errors/SyntaxError';
|
|
17
|
-
import { TemplateError } from '../errors/TemplateError';
|
|
18
19
|
import { UnexpectedError } from '../errors/UnexpectedError';
|
|
19
20
|
import { ExpectError } from '../errors/_ExpectError';
|
|
20
21
|
import { assertsExecutionSuccessful } from '../execution/assertsExecutionSuccessful';
|
|
@@ -27,18 +28,17 @@ import { CallbackInterfaceTools } from '../knowledge/dialogs/callback/CallbackIn
|
|
|
27
28
|
import type { CallbackInterfaceToolsOptions } from '../knowledge/dialogs/callback/CallbackInterfaceToolsOptions';
|
|
28
29
|
import { SimplePromptInterfaceTools } from '../knowledge/dialogs/simple-prompt/SimplePromptInterfaceTools';
|
|
29
30
|
import { prepareKnowledgeFromMarkdown } from '../knowledge/prepare-knowledge/markdown/prepareKnowledgeFromMarkdown';
|
|
30
|
-
import {
|
|
31
|
-
import { ExecutionTypes } from '../types/ExecutionTypes';
|
|
31
|
+
import { joinLlmExecutionTools } from '../llm-providers/multiple/joinLlmExecutionTools';
|
|
32
32
|
import type { ExecutionReportStringOptions } from '../types/execution-report/ExecutionReportStringOptions';
|
|
33
33
|
import { ExecutionReportStringOptionsDefaults } from '../types/execution-report/ExecutionReportStringOptions';
|
|
34
34
|
import { executionReportJsonToString } from '../types/execution-report/executionReportJsonToString';
|
|
35
35
|
import { PROMPTBOOK_VERSION } from '../version';
|
|
36
36
|
export { PROMPTBOOK_VERSION };
|
|
37
|
-
export {
|
|
37
|
+
export { BlockTypes, RESERVED_PARAMETER_NAMES };
|
|
38
38
|
export { addUsage, assertsExecutionSuccessful, checkExpectations, embeddingVectorToString, executionReportJsonToString, ExecutionReportStringOptions, ExecutionReportStringOptionsDefaults, isPassingExpectations, prepareKnowledgeFromMarkdown, prettifyPipelineString, usageToWorktime, };
|
|
39
39
|
export { collectionToJson, createCollectionFromJson, createCollectionFromPromise, createCollectionFromUrl, createSubcollection, };
|
|
40
40
|
export { SimplePromptInterfaceTools };
|
|
41
41
|
export { pipelineJsonToString, pipelineStringToJson, pipelineStringToJsonSync, validatePipeline };
|
|
42
|
-
export { createPipelineExecutor,
|
|
42
|
+
export { createPipelineExecutor, joinLlmExecutionTools };
|
|
43
43
|
export { CallbackInterfaceTools, CallbackInterfaceToolsOptions };
|
|
44
|
-
export { CollectionError,
|
|
44
|
+
export { CollectionError, ExpectError, NotFoundError, ParsingError, PipelineExecutionError, PipelineLogicError, ReferenceError, UnexpectedError, };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { string_markdown_section, string_markdown_section_content, string_markdown_text } from '../types/typeAliases';
|
|
2
|
+
import { addAutoGeneratedSection } from '../utils/markdown/addAutoGeneratedSection';
|
|
3
|
+
import { createMarkdownChart } from '../utils/markdown/createMarkdownChart';
|
|
4
|
+
import { createMarkdownTable } from '../utils/markdown/createMarkdownTable';
|
|
5
|
+
import { escapeMarkdownBlock } from '../utils/markdown/escapeMarkdownBlock';
|
|
6
|
+
import { extractAllBlocksFromMarkdown } from '../utils/markdown/extractAllBlocksFromMarkdown';
|
|
7
|
+
import { extractAllListItemsFromMarkdown } from '../utils/markdown/extractAllListItemsFromMarkdown';
|
|
8
|
+
import { extractOneBlockFromMarkdown } from '../utils/markdown/extractOneBlockFromMarkdown';
|
|
9
|
+
import { flattenMarkdown } from '../utils/markdown/flattenMarkdown';
|
|
10
|
+
import type { MarkdownSection } from '../utils/markdown/parseMarkdownSection';
|
|
11
|
+
import { parseMarkdownSection } from '../utils/markdown/parseMarkdownSection';
|
|
12
|
+
import { removeContentComments } from '../utils/markdown/removeContentComments';
|
|
13
|
+
import { removeMarkdownFormatting } from '../utils/markdown/removeMarkdownFormatting';
|
|
14
|
+
import { splitMarkdownIntoSections } from '../utils/markdown/splitMarkdownIntoSections';
|
|
15
|
+
import { string_markdown } from './types.index';
|
|
16
|
+
export { addAutoGeneratedSection, createMarkdownChart, createMarkdownTable, escapeMarkdownBlock, extractAllBlocksFromMarkdown, extractAllListItemsFromMarkdown, extractOneBlockFromMarkdown, flattenMarkdown, parseMarkdownSection, removeContentComments, removeMarkdownFormatting, splitMarkdownIntoSections, };
|
|
17
|
+
export type { MarkdownSection, string_markdown, string_markdown_section, string_markdown_section_content, string_markdown_text, };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { PipelineCollection } from '../collection/PipelineCollection';
|
|
2
|
+
import type { BlockType } from '../commands/BLOCK/BlockTypes';
|
|
2
3
|
import type { CommonExecutionToolsOptions } from '../execution/CommonExecutionToolsOptions';
|
|
3
4
|
import { EmbeddingVector } from '../execution/EmbeddingVector';
|
|
4
5
|
import type { ExecutionTools } from '../execution/ExecutionTools';
|
|
@@ -7,27 +8,31 @@ import type { PipelineExecutor } from '../execution/PipelineExecutor';
|
|
|
7
8
|
import type { PromptChatResult, PromptCommonResult, PromptCompletionResult, PromptEmbeddingResult, PromptResult, PromptResultUsage, PromptResultUsageCounts, UncertainNumber } from '../execution/PromptResult';
|
|
8
9
|
import type { ScriptExecutionTools, ScriptExecutionToolsExecuteOptions } from '../execution/ScriptExecutionTools';
|
|
9
10
|
import type { UserInterfaceTools, UserInterfaceToolsPromptDialogOptions } from '../execution/UserInterfaceTools';
|
|
10
|
-
import type { ExecutionType } from '../types/ExecutionTypes';
|
|
11
11
|
import type { ModelRequirements, ModelVariant } from '../types/ModelRequirements';
|
|
12
12
|
import type { Parameters } from '../types/Parameters';
|
|
13
|
+
import type { ExpectationAmount, ExpectationUnit, Expectations } from '../types/PipelineJson/Expectations';
|
|
14
|
+
import { EXPECTATION_UNITS } from '../types/PipelineJson/Expectations';
|
|
13
15
|
import { KnowledgeJson } from '../types/PipelineJson/KnowledgeJson';
|
|
16
|
+
import type { LlmTemplateJson } from '../types/PipelineJson/LlmTemplateJson';
|
|
14
17
|
import { MaterialKnowledgePieceJson } from '../types/PipelineJson/MaterialKnowledgePieceJson';
|
|
15
18
|
import type { PipelineJson } from '../types/PipelineJson/PipelineJson';
|
|
16
|
-
import type {
|
|
17
|
-
import {
|
|
19
|
+
import type { PromptDialogJson } from '../types/PipelineJson/PromptDialogJson';
|
|
20
|
+
import type { PromptTemplateJson } from '../types/PipelineJson/PromptTemplateJson';
|
|
18
21
|
import type { PromptTemplateParameterJson } from '../types/PipelineJson/PromptTemplateParameterJson';
|
|
22
|
+
import type { ScriptJson } from '../types/PipelineJson/ScriptJson';
|
|
23
|
+
import type { SimpleTemplateJson } from '../types/PipelineJson/SimpleTemplateJson';
|
|
19
24
|
import type { PipelineString } from '../types/PipelineString';
|
|
20
25
|
import type { Prompt } from '../types/Prompt';
|
|
21
26
|
import type { ScriptLanguage } from '../types/ScriptLanguage';
|
|
22
27
|
import type { TaskProgress } from '../types/TaskProgress';
|
|
23
28
|
import type { ExecutionReportJson } from '../types/execution-report/ExecutionReportJson';
|
|
24
29
|
import type { string_char_emoji } from '../types/typeAliasEmoji';
|
|
25
|
-
import type { client_id, string_char, string_chat_prompt, string_completion_prompt, string_data_url, string_domain, string_email, string_file_absolute_path, string_file_extension, string_file_path, string_file_relative_path, string_filename, string_folder_absolute_path, string_folder_path, string_folder_relative_path, string_host, string_hostname, string_href, string_html, string_javascript, string_javascript_name, string_license, string_markdown, string_markdown_text, string_mime_type, string_mime_type_with_wildcard, string_model_name, string_name, string_person_fullname, string_pipeline_url, string_pipeline_url_with_hashtemplate, string_prompt, string_script, string_sha256, string_tdl, string_template, string_text_prompt, string_title, string_token, string_translate_language, string_uri, string_uri_part, string_url, string_url_image,
|
|
30
|
+
import type { client_id, string_char, string_chat_prompt, string_completion_prompt, string_data_url, string_domain, string_email, string_emails, string_file_absolute_path, string_file_extension, string_file_path, string_file_relative_path, string_filename, string_folder_absolute_path, string_folder_path, string_folder_relative_path, string_host, string_hostname, string_href, string_html, string_javascript, string_javascript_name, string_license, string_markdown, string_markdown_text, string_mime_type, string_mime_type_with_wildcard, string_model_name, string_name, string_person_fullname, string_pipeline_url, string_pipeline_url_with_hashtemplate, string_prompt, string_script, string_semantic_version, string_sha256, string_tdl, string_template, string_text_prompt, string_title, string_token, string_translate_language, string_uri, string_uri_part, string_url, string_url_image, string_uuid } from '../types/typeAliases';
|
|
26
31
|
import type { FromtoItems } from '../utils/FromtoItems';
|
|
27
|
-
import { PROMPTBOOK_VERSION } from '../version';
|
|
32
|
+
import { PROMPTBOOK_VERSION, string_promptbook_version } from '../version';
|
|
28
33
|
export { PROMPTBOOK_VERSION };
|
|
29
34
|
export { EXPECTATION_UNITS };
|
|
30
|
-
export type { AvailableModel, CommonExecutionToolsOptions, EmbeddingVector, ExecutionReportJson, ExecutionTools,
|
|
35
|
+
export type { AvailableModel, BlockType, CommonExecutionToolsOptions, EmbeddingVector, ExecutionReportJson, ExecutionTools, ExpectationAmount, ExpectationUnit, Expectations, FromtoItems, KnowledgeJson, LlmExecutionTools, LlmTemplateJson, MaterialKnowledgePieceJson, ModelRequirements, ModelVariant, Parameters, PipelineCollection, PipelineExecutor, PipelineJson, PipelineString, Prompt, PromptChatResult, PromptCommonResult, PromptCompletionResult, PromptDialogJson, PromptEmbeddingResult, PromptResult, PromptResultUsage, PromptResultUsageCounts, PromptTemplateJson, PromptTemplateParameterJson, ScriptExecutionTools, ScriptExecutionToolsExecuteOptions, ScriptJson, ScriptLanguage, SimpleTemplateJson, TaskProgress, UncertainNumber, UserInterfaceTools, UserInterfaceToolsPromptDialogOptions, client_id, string_char, string_char_emoji, string_chat_prompt, string_completion_prompt, string_data_url, string_domain, string_email, string_emails, string_file_absolute_path, string_file_extension, string_file_path, string_file_relative_path, string_filename, string_folder_absolute_path, string_folder_path, string_folder_relative_path, string_host, string_hostname, string_href, string_html, string_javascript, string_javascript_name, string_license, string_markdown, string_markdown_text, string_mime_type, string_mime_type_with_wildcard, string_model_name, string_name, string_person_fullname, string_pipeline_url, string_pipeline_url_with_hashtemplate, string_prompt, string_promptbook_version, string_script, string_sha256, string_tdl, string_template, string_text_prompt, string_title, string_token, string_translate_language, string_uri, string_uri_part, string_url, string_url_image, string_uuid, string_semantic_version as string_version, };
|
|
31
36
|
/**
|
|
32
37
|
* TODO: Delete type aliases (from ../types/typeAliases) that are not exported here
|
|
33
38
|
*/
|
|
@@ -2,7 +2,6 @@ import { spaceTrim } from 'spacetrim';
|
|
|
2
2
|
import { renderPromptbookMermaid } from '../conversion/prettify/renderPipelineMermaidOptions';
|
|
3
3
|
import { extractParametersFromPromptTemplate } from '../conversion/utils/extractParametersFromPromptTemplate';
|
|
4
4
|
import { extractVariables } from '../conversion/utils/extractVariables';
|
|
5
|
-
import { parseNumber } from '../conversion/utils/parseNumber';
|
|
6
5
|
import { renameParameter } from '../conversion/utils/renameParameter';
|
|
7
6
|
import { titleToName } from '../conversion/utils/titleToName';
|
|
8
7
|
import { forEachAsync } from '../execution/utils/forEachAsync';
|
|
@@ -16,11 +15,6 @@ import { countSentences, splitIntoSentences } from '../utils/expectation-counter
|
|
|
16
15
|
import { countWords } from '../utils/expectation-counters/countWords';
|
|
17
16
|
import { CountUtils } from '../utils/expectation-counters/index';
|
|
18
17
|
import { extractParameters } from '../utils/extractParameters';
|
|
19
|
-
import { extractAllBlocksFromMarkdown } from '../utils/markdown/extractAllBlocksFromMarkdown';
|
|
20
|
-
import { extractAllListItemsFromMarkdown } from '../utils/markdown/extractAllListItemsFromMarkdown';
|
|
21
|
-
import { extractOneBlockFromMarkdown } from '../utils/markdown/extractOneBlockFromMarkdown';
|
|
22
|
-
import { removeContentComments } from '../utils/markdown/removeContentComments';
|
|
23
|
-
import { removeMarkdownFormatting } from '../utils/markdown/removeMarkdownFormatting';
|
|
24
18
|
import { DIACRITIC_VARIANTS_LETTERS } from '../utils/normalization/DIACRITIC_VARIANTS_LETTERS';
|
|
25
19
|
import type { IKeywords, string_keyword } from '../utils/normalization/IKeywords';
|
|
26
20
|
import { capitalize } from '../utils/normalization/capitalize';
|
|
@@ -28,16 +22,17 @@ import { decapitalize } from '../utils/normalization/decapitalize';
|
|
|
28
22
|
import { isValidKeyword } from '../utils/normalization/isValidKeyword';
|
|
29
23
|
import { nameToUriPart } from '../utils/normalization/nameToUriPart';
|
|
30
24
|
import { nameToUriParts } from '../utils/normalization/nameToUriParts';
|
|
31
|
-
import { normalizeToKebabCase } from '../utils/normalization/normalize-to-kebab-case';
|
|
32
|
-
import { normalizeTo_PascalCase } from '../utils/normalization/normalizeTo_PascalCase';
|
|
33
|
-
import { normalizeTo_SCREAMING_CASE } from '../utils/normalization/normalizeTo_SCREAMING_CASE';
|
|
34
|
-
import { normalizeTo_camelCase } from '../utils/normalization/normalizeTo_camelCase';
|
|
35
|
-
import { normalizeTo_snake_case } from '../utils/normalization/normalizeTo_snake_case';
|
|
25
|
+
import { normalizeToKebabCase, string_kebab_case } from '../utils/normalization/normalize-to-kebab-case';
|
|
26
|
+
import { normalizeTo_PascalCase, string_PascalCase } from '../utils/normalization/normalizeTo_PascalCase';
|
|
27
|
+
import { normalizeTo_SCREAMING_CASE, string_SCREAMING_CASE } from '../utils/normalization/normalizeTo_SCREAMING_CASE';
|
|
28
|
+
import { normalizeTo_camelCase, string_camelCase } from '../utils/normalization/normalizeTo_camelCase';
|
|
29
|
+
import { normalizeTo_snake_case, string_snake_case } from '../utils/normalization/normalizeTo_snake_case';
|
|
36
30
|
import { normalizeWhitespaces } from '../utils/normalization/normalizeWhitespaces';
|
|
37
31
|
import { parseKeywords } from '../utils/normalization/parseKeywords';
|
|
38
32
|
import { parseKeywordsFromString } from '../utils/normalization/parseKeywordsFromString';
|
|
39
33
|
import { removeDiacritics } from '../utils/normalization/removeDiacritics';
|
|
40
34
|
import { searchKeywords } from '../utils/normalization/searchKeywords';
|
|
35
|
+
import { parseNumber } from '../utils/parseNumber';
|
|
41
36
|
import { extractBlock } from '../utils/postprocessing/extractBlock';
|
|
42
37
|
import { removeEmojis } from '../utils/removeEmojis';
|
|
43
38
|
import { removeQuotes } from '../utils/removeQuotes';
|
|
@@ -47,13 +42,21 @@ import { union } from '../utils/sets/union';
|
|
|
47
42
|
import { trimCodeBlock } from '../utils/trimCodeBlock';
|
|
48
43
|
import { trimEndOfCodeBlock } from '../utils/trimEndOfCodeBlock';
|
|
49
44
|
import { unwrapResult } from '../utils/unwrapResult';
|
|
45
|
+
import { isValidFilePath } from '../utils/validators/filePath/isValidFilePath';
|
|
46
|
+
import { isValidJavascriptName } from '../utils/validators/javascriptName/isValidJavascriptName';
|
|
47
|
+
import { isValidPromptbookVersion } from '../utils/validators/semanticVersion/isValidPromptbookVersion';
|
|
48
|
+
import { isValidSemanticVersion } from '../utils/validators/semanticVersion/isValidSemanticVersion';
|
|
49
|
+
import { isHostnameOnPrivateNetwork } from '../utils/validators/url/isHostnameOnPrivateNetwork';
|
|
50
|
+
import { isUrlOnPrivateNetwork } from '../utils/validators/url/isUrlOnPrivateNetwork';
|
|
51
|
+
import { isValidPipelineUrl } from '../utils/validators/url/isValidPipelineUrl';
|
|
52
|
+
import { isValidUrl } from '../utils/validators/url/isValidUrl';
|
|
53
|
+
import { isValidUuid } from '../utils/validators/uuid/isValidUuid';
|
|
50
54
|
import { PROMPTBOOK_VERSION } from '../version';
|
|
51
|
-
export {
|
|
52
|
-
export {
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
export { CountUtils, countCharacters, countLines, countPages, countParagraphs, countSentences, countWords };
|
|
55
|
+
export { forEachAsync, PROMPTBOOK_VERSION };
|
|
56
|
+
export { extractBlock, // <- [🌻] + maybe export through `@promptbook/markdown-utils`
|
|
57
|
+
extractParameters, extractVariables, isHostnameOnPrivateNetwork, isUrlOnPrivateNetwork, isValidFilePath, isValidJavascriptName, isValidJsonString, isValidPipelineUrl as isValidPipelineUrl, isValidPromptbookVersion, isValidSemanticVersion, isValidUrl, isValidUuid, parseNumber, // <- [🌻]
|
|
58
|
+
removeEmojis, removeQuotes, replaceParameters, spaceTrim, trimCodeBlock, trimEndOfCodeBlock, unwrapResult, };
|
|
59
|
+
export { countCharacters, countLines, countPages, countParagraphs, countSentences, CountUtils, countWords };
|
|
57
60
|
export { splitIntoSentences };
|
|
58
61
|
export declare const normalizeTo: {
|
|
59
62
|
camelCase: typeof normalizeTo_camelCase;
|
|
@@ -62,10 +65,11 @@ export declare const normalizeTo: {
|
|
|
62
65
|
snake_case: typeof normalizeTo_snake_case;
|
|
63
66
|
'kebab-case': typeof normalizeToKebabCase;
|
|
64
67
|
};
|
|
65
|
-
export {
|
|
68
|
+
export { capitalize, decapitalize, DIACRITIC_VARIANTS_LETTERS, IKeywords, isValidKeyword, nameToUriPart, nameToUriParts, normalizeTo_camelCase, normalizeTo_PascalCase, normalizeTo_SCREAMING_CASE, normalizeTo_snake_case, normalizeToKebabCase, normalizeWhitespaces, parseKeywords, parseKeywordsFromString, removeDiacritics, searchKeywords, string_keyword, titleToName, };
|
|
69
|
+
export type { string_camelCase, string_kebab_case, string_PascalCase, string_SCREAMING_CASE, string_snake_case };
|
|
66
70
|
export { extractParametersFromPromptTemplate, renameParameter, renderPromptbookMermaid };
|
|
67
71
|
export { difference, intersection, union };
|
|
68
72
|
/**
|
|
69
|
-
* TODO: [🧠] Maybe create some indipendent package like
|
|
73
|
+
* TODO: [🧠] Maybe create some indipendent package like `@promptbook/markdown-utils`
|
|
70
74
|
* Note: [🕙] It does not make sence to have simple lower / UPPER case normalization
|
|
71
75
|
*/
|
|
@@ -6,3 +6,6 @@ import type { PipelineCollection } from './PipelineCollection';
|
|
|
6
6
|
* Note: Functions `collectionToJson` and `createCollectionFromJson` are complementary
|
|
7
7
|
*/
|
|
8
8
|
export declare function collectionToJson(collection: PipelineCollection): Promise<Array<PipelineJson>>;
|
|
9
|
+
/**
|
|
10
|
+
* TODO: [🧠] Maybe clear `sourceFile` or clear when exposing through API or remote server
|
|
11
|
+
*/
|
|
@@ -1 +1,7 @@
|
|
|
1
1
|
export {};
|
|
2
|
+
/**
|
|
3
|
+
* Note: [🐠] For example here URL https://example.com/pipeline.ptbk.md is not valid
|
|
4
|
+
* because it is on private network BUT its very hard to debug because
|
|
5
|
+
* there is no error message and false return (the error) happen deep in:
|
|
6
|
+
* `isValidPipelineUrl` -> `isValidPipelineUrl` -> `isUrlOnPrivateNetwork`
|
|
7
|
+
*/
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
+
import type { PipelineStringToJsonOptions } from '../../conversion/pipelineStringToJson';
|
|
1
2
|
import type { string_folder_path } from '../../types/typeAliases';
|
|
2
3
|
import type { PipelineCollection } from '../PipelineCollection';
|
|
3
4
|
/**
|
|
4
5
|
* Options for `createCollectionFromDirectory` function
|
|
5
6
|
*/
|
|
6
|
-
type CreatePipelineCollectionFromDirectoryOptions = {
|
|
7
|
+
type CreatePipelineCollectionFromDirectoryOptions = PipelineStringToJsonOptions & {
|
|
7
8
|
/**
|
|
8
9
|
* If true, the directory is searched recursively for promptbooks
|
|
9
10
|
*
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { BlockType } from './BlockTypes';
|
|
2
|
+
/**
|
|
3
|
+
* Parsed BLOCK command
|
|
4
|
+
*
|
|
5
|
+
* @see ./blockCommandParser.ts for more details
|
|
6
|
+
* @private within the commands folder
|
|
7
|
+
*/
|
|
8
|
+
export type BlockCommand = {
|
|
9
|
+
readonly type: 'BLOCK';
|
|
10
|
+
readonly blockType: BlockType;
|
|
11
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { TupleToUnion } from 'type-fest';
|
|
2
|
+
/**
|
|
3
|
+
* Block type describes the way how the block is blockd
|
|
4
|
+
*
|
|
5
|
+
* @see https://github.com/webgptorg/promptbook#block-type
|
|
6
|
+
*/
|
|
7
|
+
export type BlockType = TupleToUnion<typeof BlockTypes>;
|
|
8
|
+
/**
|
|
9
|
+
* Block type describes the way how the block is blockd
|
|
10
|
+
*
|
|
11
|
+
* @see https://github.com/webgptorg/promptbook#block-type
|
|
12
|
+
*/
|
|
13
|
+
export declare const BlockTypes: readonly ["PROMPT_TEMPLATE", "SIMPLE_TEMPLATE", "SCRIPT", "PROMPT_DIALOG", "SAMPLE", "KNOWLEDGE", "INSTRUMENT", "ACTION"];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { CommandParser } from '../_common/types/CommandParser';
|
|
2
|
+
import type { BlockCommand } from './BlockCommand';
|
|
3
|
+
/**
|
|
4
|
+
* Parses the block command
|
|
5
|
+
*
|
|
6
|
+
* @see ./BLOCK-README.md for more details
|
|
7
|
+
* @private within the commands folder
|
|
8
|
+
*/
|
|
9
|
+
export declare const blockCommandParser: CommandParser<BlockCommand>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { ExpectationAmount } from '../../types/PipelineJson/Expectations';
|
|
2
|
+
import type { ExpectationUnit } from '../../types/PipelineJson/Expectations';
|
|
3
|
+
/**
|
|
4
|
+
* Expect amount command describes the desired output of the prompt template (after post-processing)
|
|
5
|
+
* It can set limits for the maximum/minimum length of the output, measured in characters, words, sentences, paragraphs,...
|
|
6
|
+
*
|
|
7
|
+
* Note: LLMs work with tokens, not characters, but in Promptbooks we want to use some human-recognisable and cross-model interoperable units.
|
|
8
|
+
*/
|
|
9
|
+
export type ExpectAmountCommand = {
|
|
10
|
+
readonly type: 'EXPECT_AMOUNT';
|
|
11
|
+
readonly sign: 'EXACTLY' | 'MINIMUM' | 'MAXIMUM';
|
|
12
|
+
readonly unit: ExpectationUnit;
|
|
13
|
+
readonly amount: ExpectationAmount;
|
|
14
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ExpectAmountCommand } from "./ExpectAmountCommand";
|
|
2
|
+
import type { ExpectFormatCommand } from "./ExpectFormatCommand";
|
|
3
|
+
/**
|
|
4
|
+
* Parsed EXPECT command
|
|
5
|
+
*
|
|
6
|
+
* @see ./expectCommandParser.ts for more details
|
|
7
|
+
* @private within the commands folder
|
|
8
|
+
*/
|
|
9
|
+
export type ExpectCommand = ExpectAmountCommand | ExpectFormatCommand;
|