@promptbook/documents 0.86.0-8 → 0.86.5
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 +48 -58
- package/esm/index.es.js +2 -2
- package/esm/index.es.js.map +1 -1
- package/esm/typings/src/cli/test/ptbk2.d.ts +5 -0
- package/esm/typings/src/conversion/compilePipeline.d.ts +1 -1
- package/esm/typings/src/conversion/compilePipelineOnRemoteServer.d.ts +1 -1
- package/esm/typings/src/conversion/parsePipeline.d.ts +1 -1
- package/esm/typings/src/conversion/pipelineJsonToString.d.ts +1 -1
- package/esm/typings/src/conversion/validation/_importPipeline.d.ts +6 -6
- package/esm/typings/src/pipeline/PipelineJson/PreparationJson.d.ts +1 -1
- package/package.json +2 -2
- package/umd/index.umd.js +2 -2
- package/umd/index.umd.js.map +1 -1
package/README.md
CHANGED
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
[ Promptbook](https://badge.fury.io/js/promptbook.svg)](https://www.npmjs.com/package/promptbook)
|
|
9
|
+
[ Promptbook](https://packagequality.com/shield/promptbook.svg)](https://packagequality.com/#?package=promptbook)
|
|
10
10
|
[](https://snyk.io/test/github/webgptorg/promptbook)
|
|
11
11
|
[](https://github.com/webgptorg/promptbook/issues)
|
|
12
12
|
|
|
@@ -17,18 +17,12 @@
|
|
|
17
17
|
## 🌟 New Features
|
|
18
18
|
|
|
19
19
|
- 📂 We have plugin for [VSCode](https://github.com/webgptorg/book-extension) to support `.book` file extension
|
|
20
|
+
- 🐳 Available [Docker image](https://hub.docker.com/r/hejny/promptbook/)
|
|
20
21
|
- 💫 Support of [`o3-mini` model by OpenAI](https://openai.com/index/openai-o3-mini/)
|
|
21
22
|
- 🐋 **Support of [DeepSeek models](https://www.npmjs.com/package/@promptbook/deepseek)**
|
|
22
|
-
- 💙 Working [the **Book** language v1.0.0](https://github.com/webgptorg/book)
|
|
23
|
-
- 🖤 Run books from CLI - `npx ptbk run path/to/your/book`
|
|
24
|
-
- 📚 Support of `.docx`, `.doc` and `.pdf` documents as knowledge
|
|
25
23
|
|
|
26
24
|
|
|
27
25
|
|
|
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
26
|
## 📦 Package `@promptbook/documents`
|
|
33
27
|
|
|
34
28
|
- Promptbooks are [divided into several](#-packages) packages, all are published from [single monorepo](https://github.com/webgptorg/promptbook).
|
|
@@ -63,6 +57,8 @@ Rest of the documentation is common for **entire promptbook ecosystem**:
|
|
|
63
57
|
|
|
64
58
|
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**!
|
|
65
59
|
|
|
60
|
+
|
|
61
|
+
|
|
66
62
|
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!
|
|
67
63
|
|
|
68
64
|
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.
|
|
@@ -120,34 +116,41 @@ We also have a community of developers and users of **Promptbook**:
|
|
|
120
116
|
- [Landing page `ptbk.io`](https://ptbk.io)
|
|
121
117
|
- [Github discussions](https://github.com/webgptorg/promptbook/discussions)
|
|
122
118
|
- [LinkedIn `Promptbook`](https://linkedin.com/company/promptbook)
|
|
123
|
-
- [Facebook `Promptbook`](https://www.facebook.com/61560776453536)
|
|
119
|
+
- [Facebook `Promptbook`](https://www.facebook.com/61560776453536)
|
|
124
120
|
|
|
125
121
|
And **Promptbook.studio** branded socials:
|
|
126
122
|
|
|
123
|
+
|
|
124
|
+
|
|
127
125
|
- [Instagram `@promptbook.studio`](https://www.instagram.com/promptbook.studio/)
|
|
128
126
|
|
|
127
|
+
|
|
128
|
+
|
|
129
129
|
And **Promptujeme** sub-brand:
|
|
130
130
|
|
|
131
|
-
|
|
131
|
+
*/Subbrand for Czech clients/*
|
|
132
|
+
|
|
133
|
+
|
|
132
134
|
|
|
133
135
|
- [Promptujeme.cz](https://www.promptujeme.cz/)
|
|
134
136
|
- [Facebook `Promptujeme`](https://www.facebook.com/promptujeme/)
|
|
135
137
|
|
|
138
|
+
|
|
136
139
|
And **Promptbook.city** branded socials:
|
|
137
140
|
|
|
138
|
-
|
|
141
|
+
*/Sub-brand for images and graphics generated via Promptbook prompting/*
|
|
139
142
|
|
|
140
143
|
- [Instagram `@promptbook.city`](https://www.instagram.com/promptbook.city/)
|
|
141
|
-
- [Facebook `Promptbook City`](https://www.facebook.com/61565718625569)
|
|
144
|
+
- [Facebook `Promptbook City`](https://www.facebook.com/61565718625569)
|
|
142
145
|
|
|
143
146
|
|
|
144
147
|
|
|
145
|
-
## 💙 Book language _(for prompt-engineer)_
|
|
146
148
|
|
|
147
149
|
|
|
148
150
|
|
|
151
|
+
## 💙 The Book language
|
|
152
|
+
|
|
149
153
|
|
|
150
|
-
## 💙 The blueprint of book language
|
|
151
154
|
|
|
152
155
|
Following is the documentation and blueprint of the Book language.
|
|
153
156
|
|
|
@@ -156,6 +159,11 @@ Following is the documentation and blueprint of the Book language.
|
|
|
156
159
|
```markdown
|
|
157
160
|
# 🌟 My first Book
|
|
158
161
|
|
|
162
|
+
- BOOK VERSION 1.0.0
|
|
163
|
+
- URL https://promptbook.studio/my-first-book/
|
|
164
|
+
|
|
165
|
+
# Write an article
|
|
166
|
+
|
|
159
167
|
- PERSONA Jane, marketing specialist with prior experience in writing articles about technology and artificial intelligence
|
|
160
168
|
- KNOWLEDGE https://ptbk.io
|
|
161
169
|
- KNOWLEDGE ./promptbook.pdf
|
|
@@ -168,59 +176,31 @@ Following is the documentation and blueprint of the Book language.
|
|
|
168
176
|
-> {article}
|
|
169
177
|
```
|
|
170
178
|
|
|
171
|
-
###
|
|
172
|
-
|
|
173
|
-
File is designed to be easy to read and write. It is strict subset of markdown. It is designed to be understandable by both humans and machines and without specific knowledge of the language.
|
|
174
|
-
|
|
175
|
-
It has file with `.book.md` or `.book` extension with `UTF-8` non BOM encoding.
|
|
176
|
-
|
|
177
|
-
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.
|
|
178
|
-
|
|
179
|
-
But unlike programming languages, it is designed to be understandable by non-programmers and non-technical people.
|
|
180
|
-
|
|
181
|
-
### Structure
|
|
182
|
-
|
|
183
|
-
Book is divided into sections. Each section starts with heading. The language itself is not sensitive to the type of heading _(`h1`, `h2`, `h3`, ...)_ but it is recommended to use `h1` for header section and `h2` for other sections.
|
|
184
|
-
|
|
185
|
-
### Header
|
|
186
|
-
|
|
187
|
-
Header is the first section of the book. It contains metadata about the pipeline. It is recommended to use `h1` heading for header section but it is not required.
|
|
188
|
-
|
|
189
|
-
### Parameter
|
|
179
|
+
### **What:** Workflows, Tasks and Parameters
|
|
190
180
|
|
|
191
|
-
|
|
181
|
+
- [PARAMETER](https://github.com/webgptorg/promptbook/blob/main/documents/commands/PARAMETER.md)
|
|
192
182
|
|
|
193
|
-
|
|
183
|
+
### **Who:** Personas
|
|
194
184
|
|
|
195
|
-
|
|
185
|
+
- [PERSONA](https://github.com/webgptorg/promptbook/blob/main/documents/commands/PERSONA.md)
|
|
196
186
|
|
|
197
|
-
|
|
198
|
-
- `content`
|
|
199
|
-
- `context`
|
|
200
|
-
- `knowledge`
|
|
201
|
-
- `examples`
|
|
202
|
-
- `modelName`
|
|
203
|
-
- `currentDate`
|
|
187
|
+
### **How:** Knowledge, Instruments and Actions
|
|
204
188
|
|
|
205
|
-
|
|
189
|
+
- [KNOWLEDGE](https://github.com/webgptorg/promptbook/blob/main/documents/commands/KNOWLEDGE.md)
|
|
190
|
+
- [INSTRUMENT](https://github.com/webgptorg/promptbook/blob/main/documents/commands/INSTRUMENT.md)
|
|
191
|
+
- [ACTION](https://github.com/webgptorg/promptbook/blob/main/documents/commands/ACTION.md)
|
|
206
192
|
|
|
207
|
-
###
|
|
193
|
+
### General principles of book language
|
|
208
194
|
|
|
209
|
-
|
|
195
|
+
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.
|
|
210
196
|
|
|
211
|
-
|
|
197
|
+
The file has `.book` extension. It uses `UTF-8` non BOM encoding.
|
|
212
198
|
|
|
213
|
-
|
|
199
|
+
Book has two variants: flat - which is just a prompt with no structure, and full - which has a structure with tasks, commands and prompts.
|
|
214
200
|
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
### Block
|
|
218
|
-
|
|
219
|
-
Todo todo
|
|
220
|
-
|
|
221
|
-
### Return parameter
|
|
201
|
+
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.
|
|
222
202
|
|
|
223
|
-
|
|
203
|
+
But unlike programming languages, it is designed to be understandable by non-programmers and non-technical people.
|
|
224
204
|
|
|
225
205
|
|
|
226
206
|
|
|
@@ -266,6 +246,7 @@ Or you can install them separately:
|
|
|
266
246
|
- **[@promptbook/templates](https://www.npmjs.com/package/@promptbook/templates)** - Usefull templates and examples of books which can be used as a starting point
|
|
267
247
|
- **[@promptbook/types](https://www.npmjs.com/package/@promptbook/types)** - Just typescript types used in the library
|
|
268
248
|
- ⭐ **[@promptbook/cli](https://www.npmjs.com/package/@promptbook/cli)** - Command line interface utilities for promptbooks
|
|
249
|
+
- 🐋 **[Docker image](https://hub.docker.com/r/hejny/promptbook/)** - Promptbook server
|
|
269
250
|
|
|
270
251
|
|
|
271
252
|
|
|
@@ -274,6 +255,11 @@ Or you can install them separately:
|
|
|
274
255
|
|
|
275
256
|
## 📚 Dictionary
|
|
276
257
|
|
|
258
|
+
|
|
259
|
+
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
|
|
277
263
|
### 📚 Dictionary
|
|
278
264
|
|
|
279
265
|
The following glossary is used to clarify certain concepts:
|
|
@@ -289,6 +275,8 @@ The following glossary is used to clarify certain concepts:
|
|
|
289
275
|
- **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.
|
|
290
276
|
- **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.
|
|
291
277
|
|
|
278
|
+
|
|
279
|
+
|
|
292
280
|
_Note: Thos section is not complete dictionary, more list of general AI / LLM terms that has connection with Promptbook_
|
|
293
281
|
|
|
294
282
|
#### Promptbook core
|
|
@@ -349,6 +337,8 @@ _Note: Thos section is not complete dictionary, more list of general AI / LLM te
|
|
|
349
337
|
- [👮 Agent adversary expectations](https://github.com/webgptorg/promptbook/discussions/39)
|
|
350
338
|
- [view more](https://github.com/webgptorg/promptbook/discussions/categories/concepts)
|
|
351
339
|
|
|
340
|
+
|
|
341
|
+
|
|
352
342
|
### Terms specific to Promptbook TypeScript implementation
|
|
353
343
|
|
|
354
344
|
- Anonymous mode
|
|
@@ -428,7 +418,7 @@ See [TODO.md](./TODO.md)
|
|
|
428
418
|
<div style="display: flex; align-items: center; gap: 20px;">
|
|
429
419
|
|
|
430
420
|
<a href="https://promptbook.studio/">
|
|
431
|
-
<img src="./
|
|
421
|
+
<img src="./design/promptbook-studio-logo.png" alt="Partner 3" height="100">
|
|
432
422
|
</a>
|
|
433
423
|
|
|
434
424
|
<a href="https://technologickainkubace.org/en/about-technology-incubation/about-the-project/">
|
package/esm/index.es.js
CHANGED
|
@@ -28,7 +28,7 @@ var BOOK_LANGUAGE_VERSION = '1.0.0';
|
|
|
28
28
|
* @generated
|
|
29
29
|
* @see https://github.com/webgptorg/promptbook
|
|
30
30
|
*/
|
|
31
|
-
var PROMPTBOOK_ENGINE_VERSION = '0.86.
|
|
31
|
+
var PROMPTBOOK_ENGINE_VERSION = '0.86.5';
|
|
32
32
|
/**
|
|
33
33
|
* TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
|
|
34
34
|
* Note: [💞] Ignore a discrepancy between file name and entity name
|
|
@@ -1274,7 +1274,7 @@ function capitalize(word) {
|
|
|
1274
1274
|
* Converts promptbook in JSON format to string format
|
|
1275
1275
|
*
|
|
1276
1276
|
* @deprecated TODO: [🥍][🧠] Backup original files in `PipelineJson` same as in Promptbook.studio
|
|
1277
|
-
* @param pipelineJson Promptbook in JSON format (.
|
|
1277
|
+
* @param pipelineJson Promptbook in JSON format (.bookc)
|
|
1278
1278
|
* @returns Promptbook in string format (.book.md)
|
|
1279
1279
|
* @public exported from `@promptbook/core`
|
|
1280
1280
|
*/
|