@promptbook/azure-openai 0.94.0-7 → 0.95.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +10 -23
- package/esm/index.es.js +39 -44
- package/esm/index.es.js.map +1 -1
- package/esm/typings/src/_packages/types.index.d.ts +2 -2
- package/esm/typings/src/_packages/{wizzard.index.d.ts → wizard.index.d.ts} +2 -2
- package/esm/typings/src/cli/cli-commands/prettify.d.ts +1 -1
- package/esm/typings/src/cli/cli-commands/test-command.d.ts +1 -1
- package/esm/typings/src/conversion/archive/loadArchive.d.ts +1 -1
- package/esm/typings/src/conversion/archive/saveArchive.d.ts +2 -2
- package/esm/typings/src/conversion/prettify/renderPipelineMermaidOptions.d.ts +1 -1
- package/esm/typings/src/dialogs/callback/CallbackInterfaceTools.d.ts +1 -1
- package/esm/typings/src/execution/AbstractTaskResult.d.ts +2 -2
- package/esm/typings/src/execution/createPipelineExecutor/00-CreatePipelineExecutorOptions.d.ts +1 -1
- package/esm/typings/src/execution/execution-report/ExecutionPromptReportJson.d.ts +2 -2
- package/esm/typings/src/execution/translation/automatic-translate/translateMessages.d.ts +1 -1
- package/esm/typings/src/llm-providers/_common/register/{$provideLlmToolsForWizzardOrCli.d.ts → $provideLlmToolsForWizardOrCli.d.ts} +2 -2
- package/esm/typings/src/llm-providers/anthropic-claude/register-configuration.d.ts +1 -1
- package/esm/typings/src/llm-providers/anthropic-claude/register-constructor.d.ts +1 -1
- package/esm/typings/src/llm-providers/azure-openai/register-configuration.d.ts +1 -1
- package/esm/typings/src/llm-providers/azure-openai/register-constructor.d.ts +1 -1
- package/esm/typings/src/llm-providers/deepseek/register-configuration.d.ts +1 -1
- package/esm/typings/src/llm-providers/deepseek/register-constructor.d.ts +1 -1
- package/esm/typings/src/llm-providers/google/register-configuration.d.ts +1 -1
- package/esm/typings/src/llm-providers/google/register-constructor.d.ts +1 -1
- package/esm/typings/src/llm-providers/ollama/register-configuration.d.ts +1 -1
- package/esm/typings/src/llm-providers/ollama/register-constructor.d.ts +1 -1
- package/esm/typings/src/llm-providers/openai/OpenAiAssistantExecutionTools.d.ts +1 -1
- package/esm/typings/src/llm-providers/openai/register-configuration.d.ts +2 -2
- package/esm/typings/src/llm-providers/openai/register-constructor.d.ts +2 -2
- package/esm/typings/src/remote-server/socket-types/listModels/PromptbookServer_ListModels_Request.d.ts +1 -1
- package/esm/typings/src/scrapers/_boilerplate/createBoilerplateScraper.d.ts +1 -1
- package/esm/typings/src/scrapers/_boilerplate/register-constructor.d.ts +1 -1
- package/esm/typings/src/scrapers/_boilerplate/register-metadata.d.ts +2 -2
- package/esm/typings/src/scrapers/_common/prepareKnowledgePieces.d.ts +1 -1
- package/esm/typings/src/scrapers/_common/register/ScraperAndConverterMetadata.d.ts +1 -1
- package/esm/typings/src/scrapers/document/createDocumentScraper.d.ts +1 -1
- package/esm/typings/src/scrapers/document/register-constructor.d.ts +1 -1
- package/esm/typings/src/scrapers/document/register-metadata.d.ts +2 -2
- package/esm/typings/src/scrapers/document-legacy/createLegacyDocumentScraper.d.ts +1 -1
- package/esm/typings/src/scrapers/document-legacy/register-constructor.d.ts +1 -1
- package/esm/typings/src/scrapers/document-legacy/register-metadata.d.ts +2 -2
- package/esm/typings/src/scrapers/markdown/createMarkdownScraper.d.ts +1 -4
- package/esm/typings/src/scrapers/markdown/register-constructor.d.ts +1 -1
- package/esm/typings/src/scrapers/markdown/register-metadata.d.ts +2 -2
- package/esm/typings/src/scrapers/markitdown/createMarkitdownScraper.d.ts +1 -1
- package/esm/typings/src/scrapers/markitdown/register-constructor.d.ts +1 -1
- package/esm/typings/src/scrapers/markitdown/register-metadata.d.ts +2 -2
- package/esm/typings/src/scrapers/pdf/createPdfScraper.d.ts +1 -1
- package/esm/typings/src/scrapers/pdf/register-constructor.d.ts +1 -1
- package/esm/typings/src/scrapers/pdf/register-metadata.d.ts +2 -2
- package/esm/typings/src/scrapers/website/createWebsiteScraper.d.ts +1 -1
- package/esm/typings/src/scrapers/website/register-constructor.d.ts +1 -1
- package/esm/typings/src/scrapers/website/register-metadata.d.ts +2 -2
- package/esm/typings/src/types/typeAliases.d.ts +1 -1
- package/esm/typings/src/utils/files/listAllFiles.d.ts +1 -1
- package/esm/typings/src/version.d.ts +1 -1
- package/esm/typings/src/{wizzard → wizard}/$getCompiledBook.d.ts +2 -2
- package/esm/typings/src/{wizzard/wizzard.d.ts → wizard/wizard.d.ts} +6 -6
- package/package.json +25 -14
- package/umd/index.umd.js +39 -44
- package/umd/index.umd.js.map +1 -1
package/README.md
CHANGED
|
@@ -25,10 +25,6 @@ Write AI applications using plain human language across multiple models and plat
|
|
|
25
25
|
|
|
26
26
|
|
|
27
27
|
|
|
28
|
-
<blockquote style="color: #ff8811">
|
|
29
|
-
<b>⚠ Warning:</b> This is a pre-release version of the library. It is not yet ready for production use. Please look at <a href="https://www.npmjs.com/package/@promptbook/core?activeTab=versions">latest stable release</a>.
|
|
30
|
-
</blockquote>
|
|
31
|
-
|
|
32
28
|
## 📦 Package `@promptbook/azure-openai`
|
|
33
29
|
|
|
34
30
|
- Promptbooks are [divided into several](#-packages) packages, all are published from [single monorepo](https://github.com/webgptorg/promptbook).
|
|
@@ -110,11 +106,11 @@ console.info(outputParameters);
|
|
|
110
106
|
Run books without any settings, boilerplate or struggle in Node.js:
|
|
111
107
|
|
|
112
108
|
```typescript
|
|
113
|
-
import {
|
|
109
|
+
import { wizard } from '@promptbook/wizard';
|
|
114
110
|
|
|
115
111
|
const {
|
|
116
112
|
outputParameters: { joke },
|
|
117
|
-
} = await
|
|
113
|
+
} = await wizard.execute(`https://github.com/webgptorg/book/blob/main/books/templates/generic.book`, {
|
|
118
114
|
topic: 'Prague',
|
|
119
115
|
});
|
|
120
116
|
|
|
@@ -257,17 +253,15 @@ Rest of the documentation is common for **entire promptbook ecosystem**:
|
|
|
257
253
|
|
|
258
254
|
## 🤍 The Book Abstract
|
|
259
255
|
|
|
260
|
-
**It's time for a paradigm shift! The future of software is in plain English, French or Latin.**
|
|
256
|
+
**It's time for a paradigm shift! The future of software is written in plain English, French, or Latin.**
|
|
261
257
|
|
|
262
258
|
During the computer revolution, we have seen [multiple generations of computer languages](https://github.com/webgptorg/promptbook/discussions/180), from the physical rewiring of the vacuum tubes through low-level machine code to the high-level languages like Python or JavaScript. And now, we're on the edge of the **next revolution**!
|
|
263
259
|
|
|
264
|
-
|
|
265
|
-
|
|
266
260
|
It's a revolution of writing software in **plain human language** that is understandable and executable by both humans and machines – and it's going to change everything!
|
|
267
261
|
|
|
268
262
|
The incredible growth in power of microprocessors and the Moore's Law have been the driving force behind the ever-more powerful languages, and it's been an amazing journey! Similarly, the large language models (like GPT or Claude) are the next big thing in language technology, and they're set to transform the way we interact with computers.
|
|
269
263
|
|
|
270
|
-
This shift
|
|
264
|
+
This shift will happen whether we're ready or not. Our mission is to make it excellent, not just good.
|
|
271
265
|
|
|
272
266
|
**Join us in this journey!**
|
|
273
267
|
|
|
@@ -388,9 +382,6 @@ Join our growing community of developers and users:
|
|
|
388
382
|
|
|
389
383
|
_A concise, Markdown-based DSL for crafting AI workflows and automations._
|
|
390
384
|
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
385
|
### Introduction
|
|
395
386
|
|
|
396
387
|
Book is a Markdown-based language that simplifies the creation of AI applications, workflows, and automations. With human-readable commands, you can define inputs, outputs, personas, knowledge sources, and actions—without needing model-specific details.
|
|
@@ -418,7 +409,7 @@ Book is a Markdown-based language that simplifies the creation of AI application
|
|
|
418
409
|
→ {article}
|
|
419
410
|
```
|
|
420
411
|
|
|
421
|
-
Each part of the book defines one of
|
|
412
|
+
Each part of the book defines one of three circles:
|
|
422
413
|
|
|
423
414
|
### **1. What:** Workflows, Tasks and Parameters
|
|
424
415
|
|
|
@@ -440,8 +431,6 @@ Personas can have access to different knowledge, tools and actions. They can als
|
|
|
440
431
|
|
|
441
432
|
- [PERSONA](https://github.com/webgptorg/promptbook/blob/main/documents/commands/PERSONA.md)
|
|
442
433
|
|
|
443
|
-
|
|
444
|
-
|
|
445
434
|
### **3. How:** Knowledge, Instruments and Actions
|
|
446
435
|
|
|
447
436
|
The resources used by the personas are used to do the work.
|
|
@@ -456,9 +445,9 @@ The resources used by the personas are used to do the work.
|
|
|
456
445
|
|
|
457
446
|
Book language is based on markdown. It is subset of markdown. It is designed to be easy to read and write. It is designed to be understandable by both humans and machines and without specific knowledge of the language.
|
|
458
447
|
|
|
459
|
-
The file has `.book` extension
|
|
448
|
+
The file has a `.book` extension and uses UTF-8 encoding without BOM.
|
|
460
449
|
|
|
461
|
-
|
|
450
|
+
Books have two variants: flat — just a prompt without structure, and full — with tasks, commands, and prompts.
|
|
462
451
|
|
|
463
452
|
As it is source code, it can leverage all the features of version control systems like git and does not suffer from the problems of binary formats, proprietary formats, or no-code solutions.
|
|
464
453
|
|
|
@@ -489,13 +478,13 @@ Or you can install them separately:
|
|
|
489
478
|
|
|
490
479
|
- ⭐ **[ptbk](https://www.npmjs.com/package/ptbk)** - Bundle of all packages, when you want to install everything and you don't care about the size
|
|
491
480
|
- **[promptbook](https://www.npmjs.com/package/promptbook)** - Same as `ptbk`
|
|
492
|
-
- ⭐🧙♂️ **[@promptbook/
|
|
481
|
+
- ⭐🧙♂️ **[@promptbook/wizard](https://www.npmjs.com/package/@promptbook/wizard)** - Wizard to just run the books in node without any struggle
|
|
493
482
|
- **[@promptbook/core](https://www.npmjs.com/package/@promptbook/core)** - Core of the library, it contains the main logic for promptbooks
|
|
494
483
|
- **[@promptbook/node](https://www.npmjs.com/package/@promptbook/node)** - Core of the library for Node.js environment
|
|
495
484
|
- **[@promptbook/browser](https://www.npmjs.com/package/@promptbook/browser)** - Core of the library for browser environment
|
|
496
485
|
- ⭐ **[@promptbook/utils](https://www.npmjs.com/package/@promptbook/utils)** - Utility functions used in the library but also useful for individual use in preprocessing and postprocessing LLM inputs and outputs
|
|
497
486
|
- **[@promptbook/markdown-utils](https://www.npmjs.com/package/@promptbook/markdown-utils)** - Utility functions used for processing markdown
|
|
498
|
-
- _(Not finished)_ **[@promptbook/
|
|
487
|
+
- _(Not finished)_ **[@promptbook/wizard](https://www.npmjs.com/package/@promptbook/wizard)** - Wizard for creating+running promptbooks in single line
|
|
499
488
|
- **[@promptbook/javascript](https://www.npmjs.com/package/@promptbook/javascript)** - Execution tools for javascript inside promptbooks
|
|
500
489
|
- **[@promptbook/openai](https://www.npmjs.com/package/@promptbook/openai)** - Execution tools for OpenAI API, wrapper around OpenAI SDK
|
|
501
490
|
- **[@promptbook/anthropic-claude](https://www.npmjs.com/package/@promptbook/anthropic-claude)** - Execution tools for Anthropic Claude API, wrapper around Anthropic Claude SDK
|
|
@@ -539,9 +528,7 @@ The following glossary is used to clarify certain concepts:
|
|
|
539
528
|
- **Retrieval-augmented generation** is a machine learning paradigm where a model generates text by retrieving relevant information from a large database of text. This approach combines the benefits of generative models and retrieval models.
|
|
540
529
|
- **Longtail** refers to non-common or rare events, items, or entities that are not well-represented in the training data of machine learning models. Longtail items are often challenging for models to predict accurately.
|
|
541
530
|
|
|
542
|
-
_Note: This section is not complete dictionary, more list of general AI / LLM terms that has connection with Promptbook_
|
|
543
|
-
|
|
544
|
-
|
|
531
|
+
_Note: This section is not a complete dictionary, more list of general AI / LLM terms that has connection with Promptbook_
|
|
545
532
|
|
|
546
533
|
### 💯 Core concepts
|
|
547
534
|
|
package/esm/index.es.js
CHANGED
|
@@ -18,7 +18,7 @@ const BOOK_LANGUAGE_VERSION = '1.0.0';
|
|
|
18
18
|
* @generated
|
|
19
19
|
* @see https://github.com/webgptorg/promptbook
|
|
20
20
|
*/
|
|
21
|
-
const PROMPTBOOK_ENGINE_VERSION = '0.
|
|
21
|
+
const PROMPTBOOK_ENGINE_VERSION = '0.95.0';
|
|
22
22
|
/**
|
|
23
23
|
* TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
|
|
24
24
|
* Note: [💞] Ignore a discrepancy between file name and entity name
|
|
@@ -869,7 +869,7 @@ function checkSerializableAsJson(options) {
|
|
|
869
869
|
else {
|
|
870
870
|
for (const [subName, subValue] of Object.entries(value)) {
|
|
871
871
|
if (subValue === undefined) {
|
|
872
|
-
// Note: undefined in object is serializable - it is just
|
|
872
|
+
// Note: undefined in object is serializable - it is just omitted
|
|
873
873
|
continue;
|
|
874
874
|
}
|
|
875
875
|
checkSerializableAsJson({ name: `${name}.${subName}`, value: subValue, message });
|
|
@@ -1232,7 +1232,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1232
1232
|
modelVariant: 'COMPLETION',
|
|
1233
1233
|
modelTitle: 'davinci-002',
|
|
1234
1234
|
modelName: 'davinci-002',
|
|
1235
|
-
modelDescription: 'Legacy completion model with
|
|
1235
|
+
modelDescription: 'Legacy completion model with 4K token context window. Excels at complex text generation, creative writing, and detailed content creation with strong contextual understanding. Optimized for instructions requiring nuanced outputs and extended reasoning. Suitable for applications needing high-quality text generation without conversation management.',
|
|
1236
1236
|
pricing: {
|
|
1237
1237
|
prompt: pricing(`$2.00 / 1M tokens`),
|
|
1238
1238
|
output: pricing(`$2.00 / 1M tokens`),
|
|
@@ -1250,7 +1250,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1250
1250
|
modelVariant: 'CHAT',
|
|
1251
1251
|
modelTitle: 'gpt-3.5-turbo-16k',
|
|
1252
1252
|
modelName: 'gpt-3.5-turbo-16k',
|
|
1253
|
-
modelDescription: 'GPT-3.5 Turbo with
|
|
1253
|
+
modelDescription: 'Extended context GPT-3.5 Turbo with 16K token window. Maintains core capabilities of standard 3.5 Turbo while supporting longer conversations and documents. Features good balance of performance and cost for applications requiring more context than standard 4K models. Effective for document analysis, extended conversations, and multi-step reasoning tasks.',
|
|
1254
1254
|
pricing: {
|
|
1255
1255
|
prompt: pricing(`$3.00 / 1M tokens`),
|
|
1256
1256
|
output: pricing(`$4.00 / 1M tokens`),
|
|
@@ -1274,7 +1274,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1274
1274
|
modelVariant: 'CHAT',
|
|
1275
1275
|
modelTitle: 'gpt-4',
|
|
1276
1276
|
modelName: 'gpt-4',
|
|
1277
|
-
modelDescription: '
|
|
1277
|
+
modelDescription: 'Powerful language model with 8K context window featuring sophisticated reasoning, instruction-following, and knowledge capabilities. Demonstrates strong performance on complex tasks requiring deep understanding and multi-step reasoning. Excels at code generation, logical analysis, and nuanced content creation. Suitable for advanced applications requiring high-quality outputs.',
|
|
1278
1278
|
pricing: {
|
|
1279
1279
|
prompt: pricing(`$30.00 / 1M tokens`),
|
|
1280
1280
|
output: pricing(`$60.00 / 1M tokens`),
|
|
@@ -1286,7 +1286,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1286
1286
|
modelVariant: 'CHAT',
|
|
1287
1287
|
modelTitle: 'gpt-4-32k',
|
|
1288
1288
|
modelName: 'gpt-4-32k',
|
|
1289
|
-
modelDescription: 'Extended context version of GPT-4 with
|
|
1289
|
+
modelDescription: 'Extended context version of GPT-4 with 32K token window. Maintains all capabilities of standard GPT-4 while supporting analysis of very lengthy documents, code bases, and conversations. Features enhanced ability to maintain context over long interactions and process detailed information from large inputs. Ideal for document analysis, legal review, and complex problem-solving.',
|
|
1290
1290
|
pricing: {
|
|
1291
1291
|
prompt: pricing(`$60.00 / 1M tokens`),
|
|
1292
1292
|
output: pricing(`$120.00 / 1M tokens`),
|
|
@@ -1309,7 +1309,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1309
1309
|
modelVariant: 'CHAT',
|
|
1310
1310
|
modelTitle: 'gpt-4-turbo-2024-04-09',
|
|
1311
1311
|
modelName: 'gpt-4-turbo-2024-04-09',
|
|
1312
|
-
modelDescription: 'Latest stable GPT-4 Turbo
|
|
1312
|
+
modelDescription: 'Latest stable GPT-4 Turbo from April 2024 with 128K context window. Features enhanced reasoning chains, improved factual accuracy with 40% reduction in hallucinations, and better instruction following compared to earlier versions. Includes advanced function calling capabilities and knowledge up to April 2024. Provides optimal performance for enterprise applications requiring reliability.',
|
|
1313
1313
|
pricing: {
|
|
1314
1314
|
prompt: pricing(`$10.00 / 1M tokens`),
|
|
1315
1315
|
output: pricing(`$30.00 / 1M tokens`),
|
|
@@ -1321,7 +1321,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1321
1321
|
modelVariant: 'CHAT',
|
|
1322
1322
|
modelTitle: 'gpt-3.5-turbo-1106',
|
|
1323
1323
|
modelName: 'gpt-3.5-turbo-1106',
|
|
1324
|
-
modelDescription: 'November 2023 version of GPT-3.5 Turbo with improved instruction following and
|
|
1324
|
+
modelDescription: 'November 2023 version of GPT-3.5 Turbo with 16K token context window. Features improved instruction following, more consistent output formatting, and enhanced function calling capabilities. Includes knowledge cutoff from April 2023. Suitable for applications requiring good performance at lower cost than GPT-4 models.',
|
|
1325
1325
|
pricing: {
|
|
1326
1326
|
prompt: pricing(`$1.00 / 1M tokens`),
|
|
1327
1327
|
output: pricing(`$2.00 / 1M tokens`),
|
|
@@ -1333,7 +1333,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1333
1333
|
modelVariant: 'CHAT',
|
|
1334
1334
|
modelTitle: 'gpt-4-turbo',
|
|
1335
1335
|
modelName: 'gpt-4-turbo',
|
|
1336
|
-
modelDescription: 'More capable
|
|
1336
|
+
modelDescription: 'More capable and cost-efficient version of GPT-4 with 128K token context window. Features improved instruction following, advanced function calling capabilities, and better performance on coding tasks. Maintains superior reasoning and knowledge while offering substantial cost reduction compared to base GPT-4. Ideal for complex applications requiring extensive context processing.',
|
|
1337
1337
|
pricing: {
|
|
1338
1338
|
prompt: pricing(`$10.00 / 1M tokens`),
|
|
1339
1339
|
output: pricing(`$30.00 / 1M tokens`),
|
|
@@ -1345,10 +1345,10 @@ const OPENAI_MODELS = exportJson({
|
|
|
1345
1345
|
modelVariant: 'COMPLETION',
|
|
1346
1346
|
modelTitle: 'gpt-3.5-turbo-instruct-0914',
|
|
1347
1347
|
modelName: 'gpt-3.5-turbo-instruct-0914',
|
|
1348
|
-
modelDescription: 'September 2023 version of GPT-3.5 Turbo
|
|
1348
|
+
modelDescription: 'September 2023 version of GPT-3.5 Turbo Instruct with 4K context window. Optimized for completion-style instruction following with deterministic responses. Better suited than chat models for applications requiring specific formatted outputs without conversation management. Knowledge cutoff from September 2021.',
|
|
1349
1349
|
pricing: {
|
|
1350
1350
|
prompt: pricing(`$1.50 / 1M tokens`),
|
|
1351
|
-
output: pricing(`$2.00 / 1M tokens`),
|
|
1351
|
+
output: pricing(`$2.00 / 1M tokens`),
|
|
1352
1352
|
},
|
|
1353
1353
|
},
|
|
1354
1354
|
/**/
|
|
@@ -1357,7 +1357,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1357
1357
|
modelVariant: 'COMPLETION',
|
|
1358
1358
|
modelTitle: 'gpt-3.5-turbo-instruct',
|
|
1359
1359
|
modelName: 'gpt-3.5-turbo-instruct',
|
|
1360
|
-
modelDescription: 'Optimized version of GPT-3.5 for completion-style API with
|
|
1360
|
+
modelDescription: 'Optimized version of GPT-3.5 for completion-style API with 4K token context window. Features strong instruction following with single-turn design rather than multi-turn conversation. Provides more consistent, deterministic outputs compared to chat models. Well-suited for templated content generation and structured text transformation tasks.',
|
|
1361
1361
|
pricing: {
|
|
1362
1362
|
prompt: pricing(`$1.50 / 1M tokens`),
|
|
1363
1363
|
output: pricing(`$2.00 / 1M tokens`),
|
|
@@ -1375,7 +1375,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1375
1375
|
modelVariant: 'CHAT',
|
|
1376
1376
|
modelTitle: 'gpt-3.5-turbo',
|
|
1377
1377
|
modelName: 'gpt-3.5-turbo',
|
|
1378
|
-
modelDescription: 'Latest version of GPT-3.5 Turbo with improved performance
|
|
1378
|
+
modelDescription: 'Latest version of GPT-3.5 Turbo with 4K token default context window (16K available). Features continually improved performance with enhanced instruction following and reduced hallucinations. Offers excellent balance between capability and cost efficiency. Suitable for most general-purpose applications requiring good AI capabilities at reasonable cost.',
|
|
1379
1379
|
pricing: {
|
|
1380
1380
|
prompt: pricing(`$0.50 / 1M tokens`),
|
|
1381
1381
|
output: pricing(`$1.50 / 1M tokens`),
|
|
@@ -1387,7 +1387,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1387
1387
|
modelVariant: 'CHAT',
|
|
1388
1388
|
modelTitle: 'gpt-3.5-turbo-0301',
|
|
1389
1389
|
modelName: 'gpt-3.5-turbo-0301',
|
|
1390
|
-
modelDescription: 'March 2023 version of GPT-3.5 Turbo with
|
|
1390
|
+
modelDescription: 'March 2023 version of GPT-3.5 Turbo with 4K token context window. Legacy model maintained for backward compatibility with specific application behaviors. Features solid conversational abilities and basic instruction following. Knowledge cutoff from September 2021. Suitable for applications explicitly designed for this version.',
|
|
1391
1391
|
pricing: {
|
|
1392
1392
|
prompt: pricing(`$1.50 / 1M tokens`),
|
|
1393
1393
|
output: pricing(`$2.00 / 1M tokens`),
|
|
@@ -1399,7 +1399,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1399
1399
|
modelVariant: 'COMPLETION',
|
|
1400
1400
|
modelTitle: 'babbage-002',
|
|
1401
1401
|
modelName: 'babbage-002',
|
|
1402
|
-
modelDescription: 'Efficient legacy completion model with
|
|
1402
|
+
modelDescription: 'Efficient legacy completion model with 4K context window balancing performance and speed. Features moderate reasoning capabilities with focus on straightforward text generation tasks. Significantly more efficient than davinci models while maintaining adequate quality for many applications. Suitable for high-volume, cost-sensitive text generation needs.',
|
|
1403
1403
|
pricing: {
|
|
1404
1404
|
prompt: pricing(`$0.40 / 1M tokens`),
|
|
1405
1405
|
output: pricing(`$0.40 / 1M tokens`),
|
|
@@ -1411,7 +1411,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1411
1411
|
modelVariant: 'CHAT',
|
|
1412
1412
|
modelTitle: 'gpt-4-1106-preview',
|
|
1413
1413
|
modelName: 'gpt-4-1106-preview',
|
|
1414
|
-
modelDescription: 'November 2023 preview version of GPT-4 Turbo with improved instruction following and
|
|
1414
|
+
modelDescription: 'November 2023 preview version of GPT-4 Turbo with 128K token context window. Features improved instruction following, better function calling capabilities, and enhanced reasoning. Includes knowledge cutoff from April 2023. Suitable for complex applications requiring extensive document understanding and sophisticated interactions.',
|
|
1415
1415
|
pricing: {
|
|
1416
1416
|
prompt: pricing(`$10.00 / 1M tokens`),
|
|
1417
1417
|
output: pricing(`$30.00 / 1M tokens`),
|
|
@@ -1423,7 +1423,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1423
1423
|
modelVariant: 'CHAT',
|
|
1424
1424
|
modelTitle: 'gpt-4-0125-preview',
|
|
1425
1425
|
modelName: 'gpt-4-0125-preview',
|
|
1426
|
-
modelDescription: 'January 2024 preview version of GPT-4 Turbo with improved reasoning capabilities and
|
|
1426
|
+
modelDescription: 'January 2024 preview version of GPT-4 Turbo with 128K token context window. Features improved reasoning capabilities, enhanced tool use, and more reliable function calling. Includes knowledge cutoff from October 2023. Offers better performance on complex logical tasks and more consistent outputs than previous preview versions.',
|
|
1427
1427
|
pricing: {
|
|
1428
1428
|
prompt: pricing(`$10.00 / 1M tokens`),
|
|
1429
1429
|
output: pricing(`$30.00 / 1M tokens`),
|
|
@@ -1441,7 +1441,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1441
1441
|
modelVariant: 'CHAT',
|
|
1442
1442
|
modelTitle: 'gpt-3.5-turbo-0125',
|
|
1443
1443
|
modelName: 'gpt-3.5-turbo-0125',
|
|
1444
|
-
modelDescription: 'January 2024 version of GPT-3.5 Turbo with improved reasoning capabilities and
|
|
1444
|
+
modelDescription: 'January 2024 version of GPT-3.5 Turbo with 16K token context window. Features improved reasoning capabilities, better instruction adherence, and reduced hallucinations compared to previous versions. Includes knowledge cutoff from September 2021. Provides good performance for most general applications at reasonable cost.',
|
|
1445
1445
|
pricing: {
|
|
1446
1446
|
prompt: pricing(`$0.50 / 1M tokens`),
|
|
1447
1447
|
output: pricing(`$1.50 / 1M tokens`),
|
|
@@ -1453,7 +1453,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1453
1453
|
modelVariant: 'CHAT',
|
|
1454
1454
|
modelTitle: 'gpt-4-turbo-preview',
|
|
1455
1455
|
modelName: 'gpt-4-turbo-preview',
|
|
1456
|
-
modelDescription: 'Preview version of GPT-4 Turbo that points to the latest model
|
|
1456
|
+
modelDescription: 'Preview version of GPT-4 Turbo with 128K token context window that points to the latest development model. Features cutting-edge improvements to instruction following, knowledge representation, and tool use capabilities. Provides access to newest features but may have occasional behavior changes. Best for non-critical applications wanting latest capabilities.',
|
|
1457
1457
|
pricing: {
|
|
1458
1458
|
prompt: pricing(`$10.00 / 1M tokens`),
|
|
1459
1459
|
output: pricing(`$30.00 / 1M tokens`),
|
|
@@ -1465,11 +1465,10 @@ const OPENAI_MODELS = exportJson({
|
|
|
1465
1465
|
modelVariant: 'EMBEDDING',
|
|
1466
1466
|
modelTitle: 'text-embedding-3-large',
|
|
1467
1467
|
modelName: 'text-embedding-3-large',
|
|
1468
|
-
modelDescription: "OpenAI's most capable text embedding model
|
|
1468
|
+
modelDescription: "OpenAI's most capable text embedding model generating 3072-dimensional vectors. Designed for high-quality embeddings for complex similarity tasks, clustering, and information retrieval. Features enhanced cross-lingual capabilities and significantly improved performance on retrieval and classification benchmarks. Ideal for sophisticated RAG systems and semantic search applications.",
|
|
1469
1469
|
pricing: {
|
|
1470
1470
|
prompt: pricing(`$0.13 / 1M tokens`),
|
|
1471
|
-
|
|
1472
|
-
output: 0, // <- Note: [🆖] In Embedding models you dont pay for output
|
|
1471
|
+
output: 0,
|
|
1473
1472
|
},
|
|
1474
1473
|
},
|
|
1475
1474
|
/**/
|
|
@@ -1478,11 +1477,10 @@ const OPENAI_MODELS = exportJson({
|
|
|
1478
1477
|
modelVariant: 'EMBEDDING',
|
|
1479
1478
|
modelTitle: 'text-embedding-3-small',
|
|
1480
1479
|
modelName: 'text-embedding-3-small',
|
|
1481
|
-
modelDescription: 'Cost-effective embedding model
|
|
1480
|
+
modelDescription: 'Cost-effective embedding model generating 1536-dimensional vectors. Balances quality and efficiency for simpler tasks while maintaining good performance on text similarity and retrieval applications. Offers 20% better quality than ada-002 at significantly lower cost. Ideal for production embedding applications with cost constraints.',
|
|
1482
1481
|
pricing: {
|
|
1483
1482
|
prompt: pricing(`$0.02 / 1M tokens`),
|
|
1484
|
-
|
|
1485
|
-
output: 0, // <- Note: [🆖] In Embedding models you dont pay for output
|
|
1483
|
+
output: 0,
|
|
1486
1484
|
},
|
|
1487
1485
|
},
|
|
1488
1486
|
/**/
|
|
@@ -1491,7 +1489,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1491
1489
|
modelVariant: 'CHAT',
|
|
1492
1490
|
modelTitle: 'gpt-3.5-turbo-0613',
|
|
1493
1491
|
modelName: 'gpt-3.5-turbo-0613',
|
|
1494
|
-
modelDescription:
|
|
1492
|
+
modelDescription: "June 2023 version of GPT-3.5 Turbo with 4K token context window. Features function calling capabilities for structured data extraction and API interaction. Includes knowledge cutoff from September 2021. Maintained for applications specifically designed for this version's behaviors and capabilities.",
|
|
1495
1493
|
pricing: {
|
|
1496
1494
|
prompt: pricing(`$1.50 / 1M tokens`),
|
|
1497
1495
|
output: pricing(`$2.00 / 1M tokens`),
|
|
@@ -1503,11 +1501,10 @@ const OPENAI_MODELS = exportJson({
|
|
|
1503
1501
|
modelVariant: 'EMBEDDING',
|
|
1504
1502
|
modelTitle: 'text-embedding-ada-002',
|
|
1505
1503
|
modelName: 'text-embedding-ada-002',
|
|
1506
|
-
modelDescription: 'Legacy text embedding model suitable for text similarity and retrieval
|
|
1504
|
+
modelDescription: 'Legacy text embedding model generating 1536-dimensional vectors suitable for text similarity and retrieval applications. Processes up to 8K tokens per request with consistent embedding quality. While superseded by newer embedding-3 models, still maintains adequate performance for many semantic search and classification tasks.',
|
|
1507
1505
|
pricing: {
|
|
1508
1506
|
prompt: pricing(`$0.1 / 1M tokens`),
|
|
1509
|
-
|
|
1510
|
-
output: 0, // <- Note: [🆖] In Embedding models you dont pay for output
|
|
1507
|
+
output: 0,
|
|
1511
1508
|
},
|
|
1512
1509
|
},
|
|
1513
1510
|
/**/
|
|
@@ -1534,7 +1531,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1534
1531
|
modelVariant: 'CHAT',
|
|
1535
1532
|
modelTitle: 'gpt-4o-2024-05-13',
|
|
1536
1533
|
modelName: 'gpt-4o-2024-05-13',
|
|
1537
|
-
modelDescription: 'May 2024 version of GPT-4o with enhanced multimodal capabilities
|
|
1534
|
+
modelDescription: 'May 2024 version of GPT-4o with 128K context window. Features enhanced multimodal capabilities including superior image understanding (up to 20MP), audio processing, and improved reasoning. Optimized for 2x lower latency than GPT-4 Turbo while maintaining high performance. Includes knowledge up to October 2023. Ideal for production applications requiring reliable multimodal capabilities.',
|
|
1538
1535
|
pricing: {
|
|
1539
1536
|
prompt: pricing(`$5.00 / 1M tokens`),
|
|
1540
1537
|
output: pricing(`$15.00 / 1M tokens`),
|
|
@@ -1546,7 +1543,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1546
1543
|
modelVariant: 'CHAT',
|
|
1547
1544
|
modelTitle: 'gpt-4o',
|
|
1548
1545
|
modelName: 'gpt-4o',
|
|
1549
|
-
modelDescription: "OpenAI's most advanced multimodal model
|
|
1546
|
+
modelDescription: "OpenAI's most advanced general-purpose multimodal model with 128K context window. Optimized for balanced performance, speed, and cost with 2x faster responses than GPT-4 Turbo. Features excellent vision processing, audio understanding, reasoning, and text generation quality. Represents optimal balance of capability and efficiency for most advanced applications.",
|
|
1550
1547
|
pricing: {
|
|
1551
1548
|
prompt: pricing(`$5.00 / 1M tokens`),
|
|
1552
1549
|
output: pricing(`$15.00 / 1M tokens`),
|
|
@@ -1558,7 +1555,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1558
1555
|
modelVariant: 'CHAT',
|
|
1559
1556
|
modelTitle: 'gpt-4o-mini',
|
|
1560
1557
|
modelName: 'gpt-4o-mini',
|
|
1561
|
-
modelDescription: 'Smaller, more cost-effective version of GPT-4o with
|
|
1558
|
+
modelDescription: 'Smaller, more cost-effective version of GPT-4o with 128K context window. Maintains impressive capabilities across text, vision, and audio tasks while operating at significantly lower cost. Features 3x faster inference than GPT-4o with good performance on general tasks. Excellent for applications requiring good quality multimodal capabilities at scale.',
|
|
1562
1559
|
pricing: {
|
|
1563
1560
|
prompt: pricing(`$0.15 / 1M tokens`),
|
|
1564
1561
|
output: pricing(`$0.60 / 1M tokens`),
|
|
@@ -1570,7 +1567,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1570
1567
|
modelVariant: 'CHAT',
|
|
1571
1568
|
modelTitle: 'o1-preview',
|
|
1572
1569
|
modelName: 'o1-preview',
|
|
1573
|
-
modelDescription: 'Advanced reasoning model with
|
|
1570
|
+
modelDescription: 'Advanced reasoning model with 128K context window specializing in complex logical, mathematical, and analytical tasks. Features exceptional step-by-step problem-solving capabilities, advanced mathematical and scientific reasoning, and superior performance on STEM-focused problems. Significantly outperforms GPT-4 on quantitative reasoning benchmarks. Ideal for professional and specialized applications.',
|
|
1574
1571
|
pricing: {
|
|
1575
1572
|
prompt: pricing(`$15.00 / 1M tokens`),
|
|
1576
1573
|
output: pricing(`$60.00 / 1M tokens`),
|
|
@@ -1582,8 +1579,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1582
1579
|
modelVariant: 'CHAT',
|
|
1583
1580
|
modelTitle: 'o1-preview-2024-09-12',
|
|
1584
1581
|
modelName: 'o1-preview-2024-09-12',
|
|
1585
|
-
modelDescription: 'September 2024 version of O1 preview with specialized reasoning capabilities for
|
|
1586
|
-
// <- TODO: [💩] Some better system to organize these date suffixes and versions
|
|
1582
|
+
modelDescription: 'September 2024 version of O1 preview with 128K context window. Features specialized reasoning capabilities with 30% improvement on mathematical and scientific accuracy over previous versions. Includes enhanced support for formal logic, statistical analysis, and technical domains. Optimized for professional applications requiring precise analytical thinking and rigorous methodologies.',
|
|
1587
1583
|
pricing: {
|
|
1588
1584
|
prompt: pricing(`$15.00 / 1M tokens`),
|
|
1589
1585
|
output: pricing(`$60.00 / 1M tokens`),
|
|
@@ -1595,7 +1591,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1595
1591
|
modelVariant: 'CHAT',
|
|
1596
1592
|
modelTitle: 'o1-mini',
|
|
1597
1593
|
modelName: 'o1-mini',
|
|
1598
|
-
modelDescription: 'Smaller, cost-effective version of the O1 model with good performance on
|
|
1594
|
+
modelDescription: 'Smaller, cost-effective version of the O1 model with 128K context window. Maintains strong analytical reasoning abilities while reducing computational requirements by 70%. Features good performance on mathematical, logical, and scientific tasks at significantly lower cost than full O1. Excellent for everyday analytical applications that benefit from reasoning focus.',
|
|
1599
1595
|
pricing: {
|
|
1600
1596
|
prompt: pricing(`$3.00 / 1M tokens`),
|
|
1601
1597
|
output: pricing(`$12.00 / 1M tokens`),
|
|
@@ -1607,7 +1603,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1607
1603
|
modelVariant: 'CHAT',
|
|
1608
1604
|
modelTitle: 'o1',
|
|
1609
1605
|
modelName: 'o1',
|
|
1610
|
-
modelDescription: "OpenAI's advanced reasoning model
|
|
1606
|
+
modelDescription: "OpenAI's advanced reasoning model with 128K context window focusing on logical problem-solving and analytical thinking. Features exceptional performance on quantitative tasks, step-by-step deduction, and complex technical problems. Maintains 95%+ of o1-preview capabilities with production-ready stability. Ideal for scientific computing, financial analysis, and professional applications.",
|
|
1611
1607
|
pricing: {
|
|
1612
1608
|
prompt: pricing(`$15.00 / 1M tokens`),
|
|
1613
1609
|
output: pricing(`$60.00 / 1M tokens`),
|
|
@@ -1619,11 +1615,10 @@ const OPENAI_MODELS = exportJson({
|
|
|
1619
1615
|
modelVariant: 'CHAT',
|
|
1620
1616
|
modelTitle: 'o3-mini',
|
|
1621
1617
|
modelName: 'o3-mini',
|
|
1622
|
-
modelDescription: 'Cost-effective reasoning model optimized for academic and scientific problem-solving.
|
|
1618
|
+
modelDescription: 'Cost-effective reasoning model with 128K context window optimized for academic and scientific problem-solving. Features efficient performance on STEM tasks with specialized capabilities in mathematics, physics, chemistry, and computer science. Offers 80% of O1 performance on technical domains at significantly lower cost. Ideal for educational applications and research support.',
|
|
1623
1619
|
pricing: {
|
|
1624
1620
|
prompt: pricing(`$3.00 / 1M tokens`),
|
|
1625
1621
|
output: pricing(`$12.00 / 1M tokens`),
|
|
1626
|
-
// <- TODO: !! Unsure, check the pricing
|
|
1627
1622
|
},
|
|
1628
1623
|
},
|
|
1629
1624
|
/**/
|
|
@@ -1632,7 +1627,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1632
1627
|
modelVariant: 'CHAT',
|
|
1633
1628
|
modelTitle: 'o1-mini-2024-09-12',
|
|
1634
1629
|
modelName: 'o1-mini-2024-09-12',
|
|
1635
|
-
modelDescription: "September 2024 version of O1-mini with balanced reasoning capabilities and cost-efficiency.
|
|
1630
|
+
modelDescription: "September 2024 version of O1-mini with 128K context window featuring balanced reasoning capabilities and cost-efficiency. Includes 25% improvement in mathematical accuracy and enhanced performance on coding tasks compared to previous versions. Maintains efficient resource utilization while delivering improved results for analytical applications that don't require the full O1 model.",
|
|
1636
1631
|
pricing: {
|
|
1637
1632
|
prompt: pricing(`$3.00 / 1M tokens`),
|
|
1638
1633
|
output: pricing(`$12.00 / 1M tokens`),
|
|
@@ -1644,7 +1639,7 @@ const OPENAI_MODELS = exportJson({
|
|
|
1644
1639
|
modelVariant: 'CHAT',
|
|
1645
1640
|
modelTitle: 'gpt-3.5-turbo-16k-0613',
|
|
1646
1641
|
modelName: 'gpt-3.5-turbo-16k-0613',
|
|
1647
|
-
modelDescription:
|
|
1642
|
+
modelDescription: "June 2023 version of GPT-3.5 Turbo with extended 16K token context window. Features good handling of longer conversations and documents with improved memory management across extended contexts. Includes knowledge cutoff from September 2021. Maintained for applications specifically designed for this version's behaviors and capabilities.",
|
|
1648
1643
|
pricing: {
|
|
1649
1644
|
prompt: pricing(`$3.00 / 1M tokens`),
|
|
1650
1645
|
output: pricing(`$4.00 / 1M tokens`),
|
|
@@ -1819,7 +1814,7 @@ class AzureOpenAiExecutionTools {
|
|
|
1819
1814
|
rawResponse: {
|
|
1820
1815
|
...rawResponse,
|
|
1821
1816
|
created: rawResponse.created.toISOString(),
|
|
1822
|
-
// <- TODO: Put `created` at
|
|
1817
|
+
// <- TODO: Put `created` at beginning
|
|
1823
1818
|
},
|
|
1824
1819
|
// <- [🗯]
|
|
1825
1820
|
},
|
|
@@ -1914,7 +1909,7 @@ class AzureOpenAiExecutionTools {
|
|
|
1914
1909
|
rawResponse: {
|
|
1915
1910
|
...rawResponse,
|
|
1916
1911
|
created: rawResponse.created.toISOString(),
|
|
1917
|
-
// <- TODO: Put `created` at
|
|
1912
|
+
// <- TODO: Put `created` at beginning
|
|
1918
1913
|
},
|
|
1919
1914
|
// <- [🗯]
|
|
1920
1915
|
},
|
|
@@ -2147,7 +2142,7 @@ const $llmToolsRegister = new $Register('llm_execution_tools_constructors');
|
|
|
2147
2142
|
* Warning: This is not useful for the end user, it is just a side effect of the mechanism that handles all available LLM tools
|
|
2148
2143
|
*
|
|
2149
2144
|
* @public exported from `@promptbook/azure-openai`
|
|
2150
|
-
* @public exported from `@promptbook/
|
|
2145
|
+
* @public exported from `@promptbook/wizard`
|
|
2151
2146
|
* @public exported from `@promptbook/cli`
|
|
2152
2147
|
*/
|
|
2153
2148
|
const _AzureOpenAiRegistration = $llmToolsRegister.register(createAzureOpenAiExecutionTools);
|