@promptbook/templates 0.100.0-46 → 0.100.0-47

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/esm/index.es.js CHANGED
@@ -17,7 +17,7 @@ const BOOK_LANGUAGE_VERSION = '1.0.0';
17
17
  * @generated
18
18
  * @see https://github.com/webgptorg/promptbook
19
19
  */
20
- const PROMPTBOOK_ENGINE_VERSION = '0.100.0-46';
20
+ const PROMPTBOOK_ENGINE_VERSION = '0.100.0-47';
21
21
  /**
22
22
  * TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
23
23
  * Note: [💞] Ignore a discrepancy between file name and entity name
@@ -1597,7 +1597,7 @@ function getTemplatesPipelineCollection() {
1597
1597
  "preparations": [
1598
1598
  {
1599
1599
  "id": 1,
1600
- "promptbookVersion": "0.100.0-45",
1600
+ "promptbookVersion": "0.100.0-46",
1601
1601
  "usage": {
1602
1602
  "price": {
1603
1603
  "value": 0.040614
@@ -2180,7 +2180,7 @@ function getTemplatesPipelineCollection() {
2180
2180
  "preparations": [
2181
2181
  {
2182
2182
  "id": 1,
2183
- "promptbookVersion": "0.100.0-45",
2183
+ "promptbookVersion": "0.100.0-46",
2184
2184
  "usage": {
2185
2185
  "price": {
2186
2186
  "value": 0.040614
@@ -2886,7 +2886,7 @@ function getTemplatesPipelineCollection() {
2886
2886
  "preparations": [
2887
2887
  {
2888
2888
  "id": 1,
2889
- "promptbookVersion": "0.100.0-45",
2889
+ "promptbookVersion": "0.100.0-46",
2890
2890
  "usage": {
2891
2891
  "price": {
2892
2892
  "value": 0.038256
@@ -3034,7 +3034,7 @@ function getTemplatesPipelineCollection() {
3034
3034
  "preparations": [
3035
3035
  {
3036
3036
  "id": 1,
3037
- "promptbookVersion": "0.100.0-45",
3037
+ "promptbookVersion": "0.100.0-46",
3038
3038
  "usage": {
3039
3039
  "price": {
3040
3040
  "value": 0.038181
@@ -3130,7 +3130,7 @@ function getTemplatesPipelineCollection() {
3130
3130
  "preparations": [
3131
3131
  {
3132
3132
  "id": 1,
3133
- "promptbookVersion": "0.100.0-45",
3133
+ "promptbookVersion": "0.100.0-46",
3134
3134
  "usage": {
3135
3135
  "price": {
3136
3136
  "value": 0
@@ -3279,7 +3279,7 @@ function getTemplatesPipelineCollection() {
3279
3279
  "preparations": [
3280
3280
  {
3281
3281
  "id": 1,
3282
- "promptbookVersion": "0.100.0-45",
3282
+ "promptbookVersion": "0.100.0-46",
3283
3283
  "usage": {
3284
3284
  "price": {
3285
3285
  "value": 0.038508
@@ -3429,7 +3429,7 @@ function getTemplatesPipelineCollection() {
3429
3429
  "preparations": [
3430
3430
  {
3431
3431
  "id": 1,
3432
- "promptbookVersion": "0.100.0-45",
3432
+ "promptbookVersion": "0.100.0-46",
3433
3433
  "usage": {
3434
3434
  "price": {
3435
3435
  "value": 0.036648
@@ -3762,7 +3762,7 @@ function getTemplatesPipelineCollection() {
3762
3762
  "preparations": [
3763
3763
  {
3764
3764
  "id": 1,
3765
- "promptbookVersion": "0.100.0-45",
3765
+ "promptbookVersion": "0.100.0-46",
3766
3766
  "usage": {
3767
3767
  "price": {
3768
3768
  "value": 0.039036
@@ -3909,7 +3909,7 @@ function getTemplatesPipelineCollection() {
3909
3909
  "preparations": [
3910
3910
  {
3911
3911
  "id": 1,
3912
- "promptbookVersion": "0.100.0-45",
3912
+ "promptbookVersion": "0.100.0-46",
3913
3913
  "usage": {
3914
3914
  "price": {
3915
3915
  "value": 0.038313
@@ -1,4 +1,5 @@
1
1
  import type { string_name } from '../../../types/typeAliases';
2
+ import type { string_person_fullname } from '../../../types/typeAliases';
2
3
  import type { string_url_image } from '../../../types/typeAliases';
3
4
  /**
4
5
  * A participant in the chat
@@ -6,7 +7,24 @@ import type { string_url_image } from '../../../types/typeAliases';
6
7
  * @public exported from `@promptbook/components`
7
8
  */
8
9
  export type ChatParticipant = {
10
+ /**
11
+ * Identifies the participant by their name, same as `message.from`
12
+ */
9
13
  name: string_name;
10
- avatarUrl?: string_url_image;
14
+ /**
15
+ * Full name of the participant
16
+ */
17
+ fullname: string_person_fullname;
18
+ /**
19
+ * Am I the participant? (i.e. is this the user)
20
+ */
21
+ isMe?: boolean;
22
+ /**
23
+ * Profile picture
24
+ */
25
+ avatarSrc?: string_url_image;
26
+ /**
27
+ * Color associated with the participant
28
+ */
11
29
  color: string;
12
30
  };
@@ -1,11 +1,9 @@
1
1
  import type { ChatMessage } from '../interfaces/ChatMessage';
2
+ import type { ChatParticipant } from '../interfaces/ChatParticipant';
2
3
  import type { ExportFormat } from './ExportFormat';
3
4
  /**
4
5
  * Exports chat messages in the specified format
5
6
  *
6
7
  * @private utility of `<Chat/>` component
7
8
  */
8
- export declare function exportChatHistory(messages: ChatMessage[], format: ExportFormat, headerMarkdown?: string, participants?: Record<string, {
9
- name: string;
10
- avatarUrl?: string;
11
- }>): Promise<void>;
9
+ export declare function exportChatHistory(messages: ChatMessage[], format: ExportFormat, headerMarkdown?: string, participants?: ReadonlyArray<ChatParticipant>): Promise<void>;
@@ -1,10 +1,8 @@
1
1
  import type { ChatMessage } from '../interfaces/ChatMessage';
2
+ import type { ChatParticipant } from '../interfaces/ChatParticipant';
2
3
  /**
3
4
  * Generates PDF content using HTML and triggers print dialog
4
5
  *
5
6
  * @private utility of `<Chat/>` component
6
7
  */
7
- export declare function generatePdfContent(messages: ChatMessage[], shareUrl: string, qrDataUrl?: string | null, headerMarkdown?: string, participants?: Record<string, {
8
- name: string;
9
- avatarUrl?: string;
10
- }>): void;
8
+ export declare function generatePdfContent(messages: ChatMessage[], shareUrl: string, qrDataUrl?: string | null, headerMarkdown?: string, participants?: ReadonlyArray<ChatParticipant>): void;
@@ -1,10 +1,8 @@
1
1
  import type { ChatMessage } from '../interfaces/ChatMessage';
2
+ import type { ChatParticipant } from '../interfaces/ChatParticipant';
2
3
  /**
3
4
  * Converts chat messages to HTML format
4
5
  *
5
6
  * @private utility of `<Chat/>` component
6
7
  */
7
- export declare function messagesToHtml(messages: ChatMessage[], shareUrl: string, qrDataUrl?: string | null, headerMarkdown?: string, participants?: Record<string, {
8
- name: string;
9
- avatarUrl?: string;
10
- }>): string;
8
+ export declare function messagesToHtml(messages: ChatMessage[], shareUrl: string, qrDataUrl?: string | null, headerMarkdown?: string, participants?: ReadonlyArray<ChatParticipant>): string;
@@ -1,10 +1,8 @@
1
1
  import type { ChatMessage } from '../interfaces/ChatMessage';
2
+ import type { ChatParticipant } from '../interfaces/ChatParticipant';
2
3
  /**
3
4
  * Converts chat messages to Markdown format
4
5
  *
5
6
  * @private utility of `<Chat/>` component
6
7
  */
7
- export declare function messagesToMarkdown(messages: ChatMessage[], shareUrl: string, qrDataUrl?: string | null, headerMarkdown?: string, participants?: Record<string, {
8
- name: string;
9
- avatarUrl?: string;
10
- }>): string;
8
+ export declare function messagesToMarkdown(messages: ChatMessage[], shareUrl: string, qrDataUrl?: string | null, headerMarkdown?: string, participants?: ReadonlyArray<ChatParticipant>): string;
@@ -1,10 +1,8 @@
1
1
  import type { ChatMessage } from '../interfaces/ChatMessage';
2
+ import type { ChatParticipant } from '../interfaces/ChatParticipant';
2
3
  /**
3
4
  * Converts chat messages to plain text format
4
5
  *
5
6
  * @private utility of `<Chat/>` component
6
7
  */
7
- export declare function messagesToText(messages: ChatMessage[], shareUrl: string, headerMarkdown?: string, participants?: Record<string, {
8
- name: string;
9
- avatarUrl?: string;
10
- }>): string;
8
+ export declare function messagesToText(messages: ChatMessage[], shareUrl: string, headerMarkdown?: string, participants?: ReadonlyArray<ChatParticipant>): string;
@@ -15,7 +15,7 @@ export declare const BOOK_LANGUAGE_VERSION: string_semantic_version;
15
15
  export declare const PROMPTBOOK_ENGINE_VERSION: string_promptbook_version;
16
16
  /**
17
17
  * Represents the version string of the Promptbook engine.
18
- * It follows semantic versioning (e.g., `0.100.0-45`).
18
+ * It follows semantic versioning (e.g., `0.100.0-46`).
19
19
  *
20
20
  * @generated
21
21
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@promptbook/templates",
3
- "version": "0.100.0-46",
3
+ "version": "0.100.0-47",
4
4
  "description": "Promptbook: Run AI apps in plain human language across multiple models and platforms",
5
5
  "private": false,
6
6
  "sideEffects": false,
@@ -95,7 +95,7 @@
95
95
  "module": "./esm/index.es.js",
96
96
  "typings": "./esm/typings/src/_packages/templates.index.d.ts",
97
97
  "peerDependencies": {
98
- "@promptbook/core": "0.100.0-46"
98
+ "@promptbook/core": "0.100.0-47"
99
99
  },
100
100
  "dependencies": {
101
101
  "spacetrim": "0.11.59"
package/umd/index.umd.js CHANGED
@@ -24,7 +24,7 @@
24
24
  * @generated
25
25
  * @see https://github.com/webgptorg/promptbook
26
26
  */
27
- const PROMPTBOOK_ENGINE_VERSION = '0.100.0-46';
27
+ const PROMPTBOOK_ENGINE_VERSION = '0.100.0-47';
28
28
  /**
29
29
  * TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
30
30
  * Note: [💞] Ignore a discrepancy between file name and entity name
@@ -1604,7 +1604,7 @@
1604
1604
  "preparations": [
1605
1605
  {
1606
1606
  "id": 1,
1607
- "promptbookVersion": "0.100.0-45",
1607
+ "promptbookVersion": "0.100.0-46",
1608
1608
  "usage": {
1609
1609
  "price": {
1610
1610
  "value": 0.040614
@@ -2187,7 +2187,7 @@
2187
2187
  "preparations": [
2188
2188
  {
2189
2189
  "id": 1,
2190
- "promptbookVersion": "0.100.0-45",
2190
+ "promptbookVersion": "0.100.0-46",
2191
2191
  "usage": {
2192
2192
  "price": {
2193
2193
  "value": 0.040614
@@ -2893,7 +2893,7 @@
2893
2893
  "preparations": [
2894
2894
  {
2895
2895
  "id": 1,
2896
- "promptbookVersion": "0.100.0-45",
2896
+ "promptbookVersion": "0.100.0-46",
2897
2897
  "usage": {
2898
2898
  "price": {
2899
2899
  "value": 0.038256
@@ -3041,7 +3041,7 @@
3041
3041
  "preparations": [
3042
3042
  {
3043
3043
  "id": 1,
3044
- "promptbookVersion": "0.100.0-45",
3044
+ "promptbookVersion": "0.100.0-46",
3045
3045
  "usage": {
3046
3046
  "price": {
3047
3047
  "value": 0.038181
@@ -3137,7 +3137,7 @@
3137
3137
  "preparations": [
3138
3138
  {
3139
3139
  "id": 1,
3140
- "promptbookVersion": "0.100.0-45",
3140
+ "promptbookVersion": "0.100.0-46",
3141
3141
  "usage": {
3142
3142
  "price": {
3143
3143
  "value": 0
@@ -3286,7 +3286,7 @@
3286
3286
  "preparations": [
3287
3287
  {
3288
3288
  "id": 1,
3289
- "promptbookVersion": "0.100.0-45",
3289
+ "promptbookVersion": "0.100.0-46",
3290
3290
  "usage": {
3291
3291
  "price": {
3292
3292
  "value": 0.038508
@@ -3436,7 +3436,7 @@
3436
3436
  "preparations": [
3437
3437
  {
3438
3438
  "id": 1,
3439
- "promptbookVersion": "0.100.0-45",
3439
+ "promptbookVersion": "0.100.0-46",
3440
3440
  "usage": {
3441
3441
  "price": {
3442
3442
  "value": 0.036648
@@ -3769,7 +3769,7 @@
3769
3769
  "preparations": [
3770
3770
  {
3771
3771
  "id": 1,
3772
- "promptbookVersion": "0.100.0-45",
3772
+ "promptbookVersion": "0.100.0-46",
3773
3773
  "usage": {
3774
3774
  "price": {
3775
3775
  "value": 0.039036
@@ -3916,7 +3916,7 @@
3916
3916
  "preparations": [
3917
3917
  {
3918
3918
  "id": 1,
3919
- "promptbookVersion": "0.100.0-45",
3919
+ "promptbookVersion": "0.100.0-46",
3920
3920
  "usage": {
3921
3921
  "price": {
3922
3922
  "value": 0.038313