@promptbook/utils 0.52.0-0 → 0.52.0-10
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 +10 -6
- package/esm/index.es.js +464 -1614
- package/esm/index.es.js.map +1 -1
- package/esm/typings/_packages/anthropic-claude.index.d.ts +3 -0
- package/esm/typings/_packages/azure-openai.index.d.ts +3 -0
- package/esm/typings/_packages/core.index.d.ts +13 -5
- package/esm/typings/_packages/openai.index.d.ts +1 -1
- package/esm/typings/_packages/utils.index.d.ts +3 -8
- package/esm/typings/execution/PromptResult.d.ts +3 -3
- package/esm/typings/execution/plugins/llm-execution-tools/anthropic-claude/AnthropicClaudeExecutionTools.d.ts +42 -0
- package/esm/typings/execution/plugins/llm-execution-tools/anthropic-claude/AnthropicClaudeExecutionToolsOptions.d.ts +8 -0
- package/esm/typings/execution/plugins/llm-execution-tools/anthropic-claude/anthropic-claude-models.d.ts +20 -0
- package/esm/typings/execution/plugins/llm-execution-tools/anthropic-claude/playground/playground.d.ts +2 -0
- package/esm/typings/execution/plugins/llm-execution-tools/azure-openai/AzureOpenAiExecutionTools.d.ts +41 -0
- package/esm/typings/execution/plugins/llm-execution-tools/azure-openai/AzureOpenAiExecutionToolsOptions.d.ts +34 -0
- package/esm/typings/execution/plugins/llm-execution-tools/azure-openai/playground/playground.d.ts +2 -0
- package/esm/typings/execution/plugins/llm-execution-tools/langtail/playground/playground.d.ts +2 -0
- package/esm/typings/execution/plugins/llm-execution-tools/mocked/MockedEchoLlmExecutionTools.d.ts +2 -2
- package/esm/typings/execution/plugins/llm-execution-tools/mocked/MockedFackedLlmExecutionTools.d.ts +2 -2
- package/esm/typings/execution/plugins/llm-execution-tools/multiple/MultipleLlmExecutionTools.d.ts +35 -0
- package/esm/typings/execution/plugins/llm-execution-tools/multiple/MultipleLlmExecutionToolsOptions.d.ts +23 -0
- package/esm/typings/execution/plugins/llm-execution-tools/multiple/playground/playground.d.ts +2 -0
- package/esm/typings/execution/plugins/llm-execution-tools/openai/OpenAiExecutionTools.d.ts +3 -3
- package/esm/typings/execution/plugins/llm-execution-tools/openai/OpenAiExecutionToolsOptions.d.ts +3 -1
- package/esm/typings/execution/plugins/llm-execution-tools/openai/computeUsage.d.ts +6 -3
- package/esm/typings/execution/plugins/llm-execution-tools/openai/{models.d.ts → openai-models.d.ts} +2 -1
- package/esm/typings/execution/plugins/llm-execution-tools/openai/playground/playground.d.ts +2 -0
- package/esm/typings/execution/plugins/script-execution-tools/javascript/JavascriptEvalExecutionTools.d.ts +1 -1
- package/esm/typings/execution/plugins/script-execution-tools/javascript/JavascriptExecutionTools.d.ts +4 -17
- package/esm/typings/library/constructors/createPromptbookLibraryFromDirectory.d.ts +16 -1
- package/package.json +1 -3
- package/umd/index.umd.js +462 -1620
- package/umd/index.umd.js.map +1 -1
- package/umd/typings/_packages/anthropic-claude.index.d.ts +3 -0
- package/umd/typings/_packages/azure-openai.index.d.ts +3 -0
- package/umd/typings/_packages/core.index.d.ts +13 -5
- package/umd/typings/_packages/openai.index.d.ts +1 -1
- package/umd/typings/_packages/utils.index.d.ts +3 -8
- package/umd/typings/execution/PromptResult.d.ts +3 -3
- package/umd/typings/execution/plugins/llm-execution-tools/anthropic-claude/AnthropicClaudeExecutionTools.d.ts +42 -0
- package/umd/typings/execution/plugins/llm-execution-tools/anthropic-claude/AnthropicClaudeExecutionToolsOptions.d.ts +8 -0
- package/umd/typings/execution/plugins/llm-execution-tools/anthropic-claude/anthropic-claude-models.d.ts +20 -0
- package/umd/typings/execution/plugins/llm-execution-tools/anthropic-claude/playground/playground.d.ts +2 -0
- package/umd/typings/execution/plugins/llm-execution-tools/azure-openai/AzureOpenAiExecutionTools.d.ts +41 -0
- package/umd/typings/execution/plugins/llm-execution-tools/azure-openai/AzureOpenAiExecutionToolsOptions.d.ts +34 -0
- package/umd/typings/execution/plugins/llm-execution-tools/azure-openai/playground/playground.d.ts +2 -0
- package/umd/typings/execution/plugins/llm-execution-tools/langtail/playground/playground.d.ts +2 -0
- package/umd/typings/execution/plugins/llm-execution-tools/mocked/MockedEchoLlmExecutionTools.d.ts +2 -2
- package/umd/typings/execution/plugins/llm-execution-tools/mocked/MockedFackedLlmExecutionTools.d.ts +2 -2
- package/umd/typings/execution/plugins/llm-execution-tools/multiple/MultipleLlmExecutionTools.d.ts +35 -0
- package/umd/typings/execution/plugins/llm-execution-tools/multiple/MultipleLlmExecutionToolsOptions.d.ts +23 -0
- package/umd/typings/execution/plugins/llm-execution-tools/multiple/playground/playground.d.ts +2 -0
- package/umd/typings/execution/plugins/llm-execution-tools/openai/OpenAiExecutionTools.d.ts +3 -3
- package/umd/typings/execution/plugins/llm-execution-tools/openai/OpenAiExecutionToolsOptions.d.ts +3 -1
- package/umd/typings/execution/plugins/llm-execution-tools/openai/computeUsage.d.ts +6 -3
- package/umd/typings/execution/plugins/llm-execution-tools/openai/{models.d.ts → openai-models.d.ts} +2 -1
- package/umd/typings/execution/plugins/llm-execution-tools/openai/playground/playground.d.ts +2 -0
- package/umd/typings/execution/plugins/script-execution-tools/javascript/JavascriptEvalExecutionTools.d.ts +1 -1
- package/umd/typings/execution/plugins/script-execution-tools/javascript/JavascriptExecutionTools.d.ts +4 -17
- package/umd/typings/library/constructors/createPromptbookLibraryFromDirectory.d.ts +16 -1
- package/esm/typings/_packages/wizzard.index.d.ts +0 -5
- package/umd/typings/_packages/wizzard.index.d.ts +0 -5
package/README.md
CHANGED
|
@@ -451,7 +451,7 @@ Or you can install them separately:
|
|
|
451
451
|
- _(Not finished)_ **[@promptbook/wizzard](https://www.npmjs.com/package/@promptbook/wizzard)** - Wizard for creating+running promptbooks in single line
|
|
452
452
|
- **[@promptbook/execute-javascript](https://www.npmjs.com/package/@promptbook/execute-javascript)** - Execution tools for javascript inside promptbooks
|
|
453
453
|
- **[@promptbook/openai](https://www.npmjs.com/package/@promptbook/openai)** - Execution tools for OpenAI API, wrapper around OpenAI SDK
|
|
454
|
-
- **[@promptbook/anthropic-claude](https://www.npmjs.com/package/@promptbook/anthropic-claude)** - Execution tools for Anthropic Claude API, wrapper around Anthropic Claude SDK
|
|
454
|
+
- **[@promptbook/anthropic-claude](https://www.npmjs.com/package/@promptbook/anthropic-claude)** - Execution tools for Anthropic Claude API, wrapper around Anthropic Claude SDK
|
|
455
455
|
- **[@promptbook/azure-openai](https://www.npmjs.com/package/@promptbook/azure-openai)** - Execution tools for Azure OpenAI API
|
|
456
456
|
- **[@promptbook/langtail](https://www.npmjs.com/package/@promptbook/langtail)** - Execution tools for Langtail API, wrapper around Langtail SDK
|
|
457
457
|
- **[@promptbook/mock](https://www.npmjs.com/package/@promptbook/mock)** - Mocked execution tools for testing the library and saving the tokens
|
|
@@ -604,14 +604,16 @@ Internally it calls OpenAI, Azure, GPU, proxy, cache, logging,...
|
|
|
604
604
|
`LlmExecutionTools` an abstract interface that is implemented by concrete execution tools:
|
|
605
605
|
|
|
606
606
|
- `OpenAiExecutionTools`
|
|
607
|
-
-
|
|
608
|
-
-
|
|
607
|
+
- `AnthropicClaudeExecutionTools`
|
|
608
|
+
- `AzureOpenAiExecutionTools`
|
|
609
|
+
- `LangtailExecutionTools`
|
|
609
610
|
- _(Not implemented yet)_ `BardExecutionTools`
|
|
610
611
|
- _(Not implemented yet)_ `LamaExecutionTools`
|
|
611
612
|
- _(Not implemented yet)_ `GpuExecutionTools`
|
|
612
|
-
- And a special case are `
|
|
613
|
-
-
|
|
614
|
-
- The
|
|
613
|
+
- And a special case are `MultipleLlmExecutionTools` that combines multiple execution tools together and tries to execute the prompt on the best one.
|
|
614
|
+
- Another special case are `RemoteLlmExecutionTools` that connect to a remote server and run one of the above execution tools on that server.
|
|
615
|
+
- The another special case is `MockedEchoLlmExecutionTools` that is used for testing and mocking.
|
|
616
|
+
- The another special case is `LogLlmExecutionToolsWrapper` that is technically also an execution tools but it is more proxy wrapper around other execution tools that logs all calls to execution tools.
|
|
615
617
|
|
|
616
618
|
#### Script Execution Tools
|
|
617
619
|
|
|
@@ -710,6 +712,8 @@ Execution report is a simple object or markdown that contains information about
|
|
|
710
712
|
|
|
711
713
|
|
|
712
714
|
|
|
715
|
+
|
|
716
|
+
|
|
713
717
|
### Remote server
|
|
714
718
|
|
|
715
719
|
Remote server is a proxy server that uses its execution tools internally and exposes the executor interface externally.
|