@promptbook/openai 0.103.0-4 → 0.103.0-41

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.
Files changed (145) hide show
  1. package/README.md +64 -30
  2. package/esm/index.es.js +166 -8
  3. package/esm/index.es.js.map +1 -1
  4. package/esm/typings/books/index.d.ts +0 -81
  5. package/esm/typings/src/_packages/browser.index.d.ts +6 -0
  6. package/esm/typings/src/_packages/cli.index.d.ts +4 -0
  7. package/esm/typings/src/_packages/components.index.d.ts +12 -8
  8. package/esm/typings/src/_packages/core.index.d.ts +30 -10
  9. package/esm/typings/src/_packages/node.index.d.ts +4 -2
  10. package/esm/typings/src/_packages/remote-server.index.d.ts +2 -0
  11. package/esm/typings/src/_packages/types.index.d.ts +18 -2
  12. package/esm/typings/src/_packages/wizard.index.d.ts +4 -0
  13. package/esm/typings/src/book-2.0/agent-source/AgentBasicInformation.d.ts +1 -0
  14. package/esm/typings/src/book-2.0/agent-source/padBook.d.ts +16 -0
  15. package/esm/typings/src/book-components/BookEditor/BookEditor.d.ts +76 -15
  16. package/esm/typings/src/book-components/BookEditor/BookEditorActionbar.d.ts +14 -0
  17. package/esm/typings/src/book-components/BookEditor/BookEditorMonaco.d.ts +5 -0
  18. package/esm/typings/src/book-components/Chat/MarkdownContent/MarkdownContent.d.ts +15 -0
  19. package/esm/typings/src/book-components/Chat/MockedChat/MockedChat.d.ts +5 -0
  20. package/esm/typings/src/book-components/Chat/save/html/htmlSaveFormatDefinition.d.ts +1 -0
  21. package/esm/typings/src/book-components/Chat/save/pdf/pdfSaveFormatDefinition.d.ts +4 -0
  22. package/esm/typings/src/book-components/Qr/BrandedQrCode.d.ts +18 -0
  23. package/esm/typings/src/book-components/Qr/GenericQrCode.d.ts +10 -0
  24. package/esm/typings/src/book-components/Qr/PromptbookQrCode.d.ts +18 -0
  25. package/esm/typings/src/book-components/Qr/useQrCode.d.ts +15 -0
  26. package/esm/typings/src/book-components/_common/Dropdown/Dropdown.d.ts +15 -0
  27. package/esm/typings/src/book-components/_common/Modal/Modal.d.ts +2 -2
  28. package/esm/typings/src/book-components/_common/Tooltip/Tooltip.d.ts +47 -0
  29. package/esm/typings/src/book-components/_common/react-utils/classNames.d.ts +1 -1
  30. package/esm/typings/src/book-components/icons/AboutIcon.d.ts +9 -0
  31. package/esm/typings/src/book-components/icons/CloseIcon.d.ts +4 -8
  32. package/esm/typings/src/book-components/icons/DownloadIcon.d.ts +9 -0
  33. package/esm/typings/src/book-components/icons/ExitFullscreenIcon.d.ts +7 -0
  34. package/esm/typings/src/book-components/icons/FullscreenIcon.d.ts +7 -0
  35. package/esm/typings/src/book-components/icons/MenuIcon.d.ts +12 -0
  36. package/esm/typings/src/cli/cli-commands/_boilerplate.d.ts +2 -1
  37. package/esm/typings/src/cli/cli-commands/about.d.ts +3 -1
  38. package/esm/typings/src/cli/cli-commands/hello.d.ts +2 -1
  39. package/esm/typings/src/cli/cli-commands/list-models.d.ts +2 -1
  40. package/esm/typings/src/cli/cli-commands/list-scrapers.d.ts +2 -1
  41. package/esm/typings/src/cli/cli-commands/login.d.ts +2 -1
  42. package/esm/typings/src/cli/cli-commands/make.d.ts +2 -1
  43. package/esm/typings/src/cli/cli-commands/prettify.d.ts +2 -1
  44. package/esm/typings/src/cli/cli-commands/run.d.ts +2 -1
  45. package/esm/typings/src/cli/cli-commands/{start-server.d.ts → start-agents-server.d.ts} +3 -2
  46. package/esm/typings/src/cli/cli-commands/start-pipelines-server.d.ts +15 -0
  47. package/esm/typings/src/cli/cli-commands/test-command.d.ts +2 -1
  48. package/esm/typings/src/cli/common/$addGlobalOptionsToCommand.d.ts +2 -1
  49. package/esm/typings/src/collection/agent-collection/AgentCollection.d.ts +36 -0
  50. package/esm/typings/src/collection/agent-collection/constructors/AgentCollectionInDirectory.d.ts +88 -0
  51. package/esm/typings/src/collection/{PipelineCollection.d.ts → pipeline-collection/PipelineCollection.d.ts} +7 -3
  52. package/esm/typings/src/collection/{SimplePipelineCollection.d.ts → pipeline-collection/SimplePipelineCollection.d.ts} +5 -5
  53. package/esm/typings/src/collection/{constructors/createCollectionFromDirectory.d.ts → pipeline-collection/constructors/createPipelineCollectionFromDirectory.d.ts} +8 -11
  54. package/esm/typings/src/collection/pipeline-collection/constructors/createPipelineCollectionFromJson.d.ts +13 -0
  55. package/esm/typings/src/collection/{constructors/createCollectionFromPromise.d.ts → pipeline-collection/constructors/createPipelineCollectionFromPromise.d.ts} +6 -5
  56. package/esm/typings/src/collection/{constructors/createCollectionFromUrl.d.ts → pipeline-collection/constructors/createPipelineCollectionFromUrl.d.ts} +3 -3
  57. package/esm/typings/src/collection/{constructors/createSubcollection.d.ts → pipeline-collection/constructors/createPipelineSubcollection.d.ts} +3 -3
  58. package/esm/typings/src/collection/pipeline-collection/pipelineCollectionToJson.d.ts +13 -0
  59. package/esm/typings/src/commands/_common/types/CommandParser.d.ts +4 -5
  60. package/esm/typings/src/config.d.ts +22 -2
  61. package/esm/typings/src/errors/0-index.d.ts +3 -0
  62. package/esm/typings/src/errors/NotAllowed.d.ts +9 -0
  63. package/esm/typings/src/execution/AvailableModel.d.ts +1 -0
  64. package/esm/typings/src/execution/Executables.d.ts +3 -0
  65. package/esm/typings/src/execution/ExecutionTask.d.ts +12 -3
  66. package/esm/typings/src/execution/ExecutionTools.d.ts +5 -0
  67. package/esm/typings/src/execution/FilesystemTools.d.ts +1 -1
  68. package/esm/typings/src/execution/LlmExecutionTools.d.ts +7 -1
  69. package/esm/typings/src/execution/createPipelineExecutor/10-executePipeline.d.ts +5 -0
  70. package/esm/typings/src/execution/createPipelineExecutor/20-executeTask.d.ts +5 -0
  71. package/esm/typings/src/execution/createPipelineExecutor/30-executeFormatSubvalues.d.ts +5 -0
  72. package/esm/typings/src/execution/createPipelineExecutor/40-executeAttempts.d.ts +5 -0
  73. package/esm/typings/src/execution/utils/logLlmCall.d.ts +8 -0
  74. package/esm/typings/src/execution/utils/usage-constants.d.ts +4 -124
  75. package/esm/typings/src/high-level-abstractions/_common/HighLevelAbstraction.d.ts +2 -1
  76. package/esm/typings/src/llm-providers/_common/register/$registeredLlmToolsMessage.d.ts +2 -1
  77. package/esm/typings/src/llm-providers/agent/Agent.d.ts +49 -0
  78. package/esm/typings/src/llm-providers/agent/AgentLlmExecutionTools.d.ts +9 -4
  79. package/esm/typings/src/llm-providers/agent/AgentOptions.d.ts +17 -0
  80. package/esm/typings/src/llm-providers/agent/CreateAgentLlmExecutionToolsOptions.d.ts +16 -0
  81. package/esm/typings/src/llm-providers/agent/createAgentLlmExecutionTools.d.ts +1 -19
  82. package/esm/typings/src/llm-providers/openai/OpenAiAssistantExecutionTools.d.ts +28 -0
  83. package/esm/typings/src/llm-providers/openai/OpenAiAssistantExecutionToolsOptions.d.ts +7 -1
  84. package/esm/typings/src/other/templates/getTemplatesPipelineCollection.d.ts +1 -1
  85. package/esm/typings/src/playground/permanent/_boilerplate.d.ts +5 -0
  86. package/esm/typings/src/playground/permanent/agent-with-browser-playground.d.ts +5 -0
  87. package/esm/typings/src/playground/playground.d.ts +0 -3
  88. package/esm/typings/src/playground/playground1.d.ts +2 -0
  89. package/esm/typings/src/remote-server/startAgentServer.d.ts +23 -0
  90. package/esm/typings/src/remote-server/startRemoteServer.d.ts +4 -1
  91. package/esm/typings/src/remote-server/types/RemoteServerOptions.d.ts +22 -8
  92. package/esm/typings/src/scrapers/_boilerplate/createBoilerplateScraper.d.ts +1 -12
  93. package/esm/typings/src/scrapers/_boilerplate/register-metadata.d.ts +1 -9
  94. package/esm/typings/src/scrapers/document/createDocumentScraper.d.ts +1 -12
  95. package/esm/typings/src/scrapers/document/register-metadata.d.ts +1 -9
  96. package/esm/typings/src/scrapers/document-legacy/createLegacyDocumentScraper.d.ts +1 -12
  97. package/esm/typings/src/scrapers/document-legacy/register-metadata.d.ts +1 -9
  98. package/esm/typings/src/scrapers/markdown/createMarkdownScraper.d.ts +1 -12
  99. package/esm/typings/src/scrapers/markdown/register-metadata.d.ts +1 -9
  100. package/esm/typings/src/scrapers/markitdown/createMarkitdownScraper.d.ts +1 -12
  101. package/esm/typings/src/scrapers/markitdown/register-metadata.d.ts +1 -9
  102. package/esm/typings/src/scrapers/pdf/createPdfScraper.d.ts +1 -12
  103. package/esm/typings/src/scrapers/pdf/register-metadata.d.ts +1 -9
  104. package/esm/typings/src/scrapers/website/createWebsiteScraper.d.ts +1 -12
  105. package/esm/typings/src/scrapers/website/register-metadata.d.ts +1 -9
  106. package/esm/typings/src/storage/env-storage/$EnvStorage.d.ts +2 -1
  107. package/esm/typings/src/transpilers/_common/BookTranspiler.d.ts +29 -0
  108. package/esm/typings/src/transpilers/_common/BookTranspilerOptions.d.ts +18 -0
  109. package/esm/typings/src/transpilers/_common/register/$bookTranspilersRegister.d.ts +15 -0
  110. package/esm/typings/src/transpilers/formatted-book-in-markdown/FormattedBookInMarkdownTranspiler.d.ts +13 -0
  111. package/esm/typings/src/transpilers/formatted-book-in-markdown/register.d.ts +15 -0
  112. package/esm/typings/src/transpilers/openai-sdk/OpenAiSdkTranspiler.d.ts +13 -0
  113. package/esm/typings/src/transpilers/openai-sdk/OpenAiSdkTranspiler.test.d.ts +1 -0
  114. package/esm/typings/src/transpilers/openai-sdk/playground/playground.d.ts +5 -0
  115. package/esm/typings/src/transpilers/openai-sdk/register.d.ts +15 -0
  116. package/esm/typings/src/types/LlmCall.d.ts +20 -0
  117. package/esm/typings/src/types/Updatable.d.ts +19 -0
  118. package/esm/typings/src/types/typeAliases.d.ts +1 -1
  119. package/esm/typings/src/utils/execCommand/$execCommand.d.ts +2 -1
  120. package/esm/typings/src/utils/execCommand/$execCommands.d.ts +2 -1
  121. package/esm/typings/src/utils/files/$induceBookDownload.d.ts +13 -0
  122. package/esm/typings/src/utils/files/$induceFileDownload.d.ts +13 -0
  123. package/esm/typings/src/utils/files/ObjectUrl.d.ts +46 -0
  124. package/esm/typings/src/utils/files/listAllFiles.d.ts +2 -3
  125. package/esm/typings/src/utils/misc/aboutPromptbookInformation.d.ts +21 -0
  126. package/esm/typings/src/utils/misc/injectCssModuleIntoShadowRoot.d.ts +1 -0
  127. package/esm/typings/src/utils/misc/xAboutPromptbookInformation.d.ts +13 -0
  128. package/esm/typings/src/utils/organization/$side_effect.d.ts +7 -0
  129. package/esm/typings/src/utils/serialization/$deepFreeze.d.ts +2 -1
  130. package/esm/typings/src/version.d.ts +1 -1
  131. package/esm/typings/src/wizard/$getCompiledBook.d.ts +1 -2
  132. package/package.json +7 -6
  133. package/umd/index.umd.js +169 -12
  134. package/umd/index.umd.js.map +1 -1
  135. package/esm/typings/src/book-components/BookEditor/BookEditorInner.d.ts +0 -5
  136. package/esm/typings/src/book-components/BookEditor/BookEditorWrapper.d.ts +0 -9
  137. package/esm/typings/src/book-components/BookEditor/config.d.ts +0 -10
  138. package/esm/typings/src/book-components/Chat/utils/renderMarkdown.d.ts +0 -21
  139. package/esm/typings/src/collection/collectionToJson.d.ts +0 -13
  140. package/esm/typings/src/collection/constructors/createCollectionFromJson.d.ts +0 -13
  141. /package/esm/typings/src/{book-components/Chat/utils/renderMarkdown.test.d.ts → collection/agent-collection/constructors/AgentCollectionInDirectory.test.d.ts} +0 -0
  142. /package/esm/typings/src/collection/{constructors/createCollectionFromDirectory.test.d.ts → pipeline-collection/constructors/createPipelineCollectionFromDirectory.test.d.ts} +0 -0
  143. /package/esm/typings/src/collection/{constructors/createCollectionFromJson.test.d.ts → pipeline-collection/constructors/createPipelineCollectionFromJson.test.d.ts} +0 -0
  144. /package/esm/typings/src/collection/{constructors/createCollectionFromPromise.test.d.ts → pipeline-collection/constructors/createPipelineCollectionFromPromise.test.d.ts} +0 -0
  145. /package/esm/typings/src/collection/{collectionToJson.test.d.ts → pipeline-collection/pipelineCollectionToJson.test.d.ts} +0 -0
@@ -30,6 +30,8 @@ import { _PdfScraperRegistration } from '../scrapers/pdf/register-constructor';
30
30
  import { _PdfScraperMetadataRegistration } from '../scrapers/pdf/register-metadata';
31
31
  import { _WebsiteScraperRegistration } from '../scrapers/website/register-constructor';
32
32
  import { _WebsiteScraperMetadataRegistration } from '../scrapers/website/register-metadata';
33
+ import { _FormattedBookInMarkdownTranspilerRegistration } from '../transpilers/formatted-book-in-markdown/register';
34
+ import { _OpenAiSdkTranspilerRegistration } from '../transpilers/openai-sdk/register';
33
35
  export { BOOK_LANGUAGE_VERSION, PROMPTBOOK_ENGINE_VERSION };
34
36
  export { _CLI };
35
37
  export { _AnthropicClaudeMetadataRegistration };
@@ -62,3 +64,5 @@ export { _PdfScraperRegistration };
62
64
  export { _PdfScraperMetadataRegistration };
63
65
  export { _WebsiteScraperRegistration };
64
66
  export { _WebsiteScraperMetadataRegistration };
67
+ export { _FormattedBookInMarkdownTranspilerRegistration };
68
+ export { _OpenAiSdkTranspilerRegistration };
@@ -7,9 +7,9 @@ import type { AvatarProfileProps } from '../book-components/AvatarProfile/Avatar
7
7
  import { AvatarProfile } from '../book-components/AvatarProfile/AvatarProfile/AvatarProfile';
8
8
  import type { AvatarProfileFromSourceProps } from '../book-components/AvatarProfile/AvatarProfile/AvatarProfileFromSource';
9
9
  import { AvatarProfileFromSource } from '../book-components/AvatarProfile/AvatarProfile/AvatarProfileFromSource';
10
+ import { DEFAULT_BOOK_EDITOR_HEIGHT } from '../book-components/BookEditor/BookEditor';
10
11
  import type { BookEditorProps } from '../book-components/BookEditor/BookEditor';
11
12
  import { BookEditor } from '../book-components/BookEditor/BookEditor';
12
- import { DEFAULT_BOOK_FONT_CLASS } from '../book-components/BookEditor/config';
13
13
  import { Chat } from '../book-components/Chat/Chat/Chat';
14
14
  import type { ChatProps } from '../book-components/Chat/Chat/ChatProps';
15
15
  import { useChatAutoScroll } from '../book-components/Chat/hooks/useChatAutoScroll';
@@ -17,6 +17,7 @@ import type { SendMessageToLlmChatFunction } from '../book-components/Chat/hooks
17
17
  import { useSendMessageToLlmChat } from '../book-components/Chat/hooks/useSendMessageToLlmChat';
18
18
  import { LlmChat } from '../book-components/Chat/LlmChat/LlmChat';
19
19
  import type { LlmChatProps } from '../book-components/Chat/LlmChat/LlmChatProps';
20
+ import { MarkdownContent } from '../book-components/Chat/MarkdownContent/MarkdownContent';
20
21
  import { NORMAL_FLOW } from '../book-components/Chat/MockedChat/constants';
21
22
  import { FAST_FLOW } from '../book-components/Chat/MockedChat/constants';
22
23
  import { SLOW_FLOW } from '../book-components/Chat/MockedChat/constants';
@@ -40,18 +41,19 @@ import type { ChatMessage } from '../book-components/Chat/types/ChatMessage';
40
41
  import type { ChatParticipant } from '../book-components/Chat/types/ChatParticipant';
41
42
  import type { MessageButton } from '../book-components/Chat/utils/parseMessageButtons';
42
43
  import { parseMessageButtons } from '../book-components/Chat/utils/parseMessageButtons';
43
- import { renderMarkdown } from '../book-components/Chat/utils/renderMarkdown';
44
- import { isMarkdownContent } from '../book-components/Chat/utils/renderMarkdown';
45
44
  import { ArrowIcon } from '../book-components/icons/ArrowIcon';
46
45
  import { AttachmentIcon } from '../book-components/icons/AttachmentIcon';
47
- import { CloseIcon } from '../book-components/icons/CloseIcon';
48
46
  import { PauseIcon } from '../book-components/icons/PauseIcon';
49
47
  import { PlayIcon } from '../book-components/icons/PlayIcon';
50
48
  import { ResetIcon } from '../book-components/icons/ResetIcon';
51
49
  import { SaveIcon } from '../book-components/icons/SaveIcon';
52
50
  import { SendIcon } from '../book-components/icons/SendIcon';
53
51
  import { TemplateIcon } from '../book-components/icons/TemplateIcon';
52
+ import { BrandedQrCode } from '../book-components/Qr/BrandedQrCode';
53
+ import { GenericQrCode } from '../book-components/Qr/GenericQrCode';
54
+ import { PromptbookQrCode } from '../book-components/Qr/PromptbookQrCode';
54
55
  import { injectCssModuleIntoShadowRoot } from '../utils/misc/injectCssModuleIntoShadowRoot';
56
+ import { AboutPromptbookInformation } from '../utils/misc/xAboutPromptbookInformation';
55
57
  export { BOOK_LANGUAGE_VERSION, PROMPTBOOK_ENGINE_VERSION };
56
58
  export type { AvatarChipProps };
57
59
  export { AvatarChip };
@@ -61,9 +63,9 @@ export type { AvatarProfileProps };
61
63
  export { AvatarProfile };
62
64
  export type { AvatarProfileFromSourceProps };
63
65
  export { AvatarProfileFromSource };
66
+ export { DEFAULT_BOOK_EDITOR_HEIGHT };
64
67
  export type { BookEditorProps };
65
68
  export { BookEditor };
66
- export { DEFAULT_BOOK_FONT_CLASS };
67
69
  export { Chat };
68
70
  export type { ChatProps };
69
71
  export { useChatAutoScroll };
@@ -71,6 +73,7 @@ export type { SendMessageToLlmChatFunction };
71
73
  export { useSendMessageToLlmChat };
72
74
  export { LlmChat };
73
75
  export type { LlmChatProps };
76
+ export { MarkdownContent };
74
77
  export { NORMAL_FLOW };
75
78
  export { FAST_FLOW };
76
79
  export { SLOW_FLOW };
@@ -94,15 +97,16 @@ export type { ChatMessage };
94
97
  export type { ChatParticipant };
95
98
  export type { MessageButton };
96
99
  export { parseMessageButtons };
97
- export { renderMarkdown };
98
- export { isMarkdownContent };
99
100
  export { ArrowIcon };
100
101
  export { AttachmentIcon };
101
- export { CloseIcon };
102
102
  export { PauseIcon };
103
103
  export { PlayIcon };
104
104
  export { ResetIcon };
105
105
  export { SaveIcon };
106
106
  export { SendIcon };
107
107
  export { TemplateIcon };
108
+ export { BrandedQrCode };
109
+ export { GenericQrCode };
110
+ export { PromptbookQrCode };
108
111
  export { injectCssModuleIntoShadowRoot };
112
+ export { AboutPromptbookInformation };
@@ -1,6 +1,8 @@
1
1
  import { BOOK_LANGUAGE_VERSION, PROMPTBOOK_ENGINE_VERSION } from '../version';
2
2
  import { createAgentModelRequirements } from '../book-2.0/agent-source/createAgentModelRequirements';
3
3
  import { createAgentModelRequirementsWithCommitments } from '../book-2.0/agent-source/createAgentModelRequirementsWithCommitments';
4
+ import { PADDING_LINES } from '../book-2.0/agent-source/padBook';
5
+ import { padBook } from '../book-2.0/agent-source/padBook';
4
6
  import { parseAgentSource } from '../book-2.0/agent-source/parseAgentSource';
5
7
  import { parseParameters } from '../book-2.0/agent-source/parseParameters';
6
8
  import { isValidBook } from '../book-2.0/agent-source/string_book';
@@ -14,16 +16,17 @@ import { getAllCommitmentDefinitions } from '../book-2.0/commitments/index';
14
16
  import { getAllCommitmentTypes } from '../book-2.0/commitments/index';
15
17
  import { isCommitmentSupported } from '../book-2.0/commitments/index';
16
18
  import { generatePlaceholderAgentProfileImageUrl } from '../book-2.0/utils/generatePlaceholderAgentProfileImageUrl';
17
- import { collectionToJson } from '../collection/collectionToJson';
18
- import { createCollectionFromJson } from '../collection/constructors/createCollectionFromJson';
19
- import { createCollectionFromPromise } from '../collection/constructors/createCollectionFromPromise';
20
- import { createCollectionFromUrl } from '../collection/constructors/createCollectionFromUrl';
21
- import { createSubcollection } from '../collection/constructors/createSubcollection';
19
+ import { createPipelineCollectionFromJson } from '../collection/pipeline-collection/constructors/createPipelineCollectionFromJson';
20
+ import { createPipelineCollectionFromPromise } from '../collection/pipeline-collection/constructors/createPipelineCollectionFromPromise';
21
+ import { createPipelineCollectionFromUrl } from '../collection/pipeline-collection/constructors/createPipelineCollectionFromUrl';
22
+ import { createPipelineSubcollection } from '../collection/pipeline-collection/constructors/createPipelineSubcollection';
23
+ import { pipelineCollectionToJson } from '../collection/pipeline-collection/pipelineCollectionToJson';
22
24
  import { NAME } from '../config';
23
25
  import { ADMIN_EMAIL } from '../config';
24
26
  import { ADMIN_GITHUB_NAME } from '../config';
25
27
  import { CLAIM } from '../config';
26
28
  import { PROMPTBOOK_COLOR } from '../config';
29
+ import { PROMPTBOOK_SYNTAX_COLORS } from '../config';
27
30
  import { PROMPTBOOK_CHAT_COLOR } from '../config';
28
31
  import { USER_CHAT_COLOR } from '../config';
29
32
  import { DEFAULT_BOOK_TITLE } from '../config';
@@ -41,6 +44,7 @@ import { DEFAULT_MAX_EXECUTION_ATTEMPTS } from '../config';
41
44
  import { DEFAULT_MAX_KNOWLEDGE_SOURCES_SCRAPING_DEPTH } from '../config';
42
45
  import { DEFAULT_MAX_KNOWLEDGE_SOURCES_SCRAPING_TOTAL } from '../config';
43
46
  import { DEFAULT_BOOKS_DIRNAME } from '../config';
47
+ import { DEFAULT_AGENTS_DIRNAME } from '../config';
44
48
  import { DEFAULT_DOWNLOAD_CACHE_DIRNAME } from '../config';
45
49
  import { DEFAULT_EXECUTION_CACHE_DIRNAME } from '../config';
46
50
  import { DEFAULT_SCRAPE_CACHE_DIRNAME } from '../config';
@@ -79,6 +83,7 @@ import { ExpectError } from '../errors/ExpectError';
79
83
  import { KnowledgeScrapeError } from '../errors/KnowledgeScrapeError';
80
84
  import { LimitReachedError } from '../errors/LimitReachedError';
81
85
  import { MissingToolsError } from '../errors/MissingToolsError';
86
+ import { NotAllowed } from '../errors/NotAllowed';
82
87
  import { NotFoundError } from '../errors/NotFoundError';
83
88
  import { NotYetImplementedError } from '../errors/NotYetImplementedError';
84
89
  import { ParseError } from '../errors/ParseError';
@@ -126,6 +131,7 @@ import { limitTotalUsage } from '../llm-providers/_common/utils/count-total-usag
126
131
  import { getSingleLlmExecutionTools } from '../llm-providers/_multiple/getSingleLlmExecutionTools';
127
132
  import { joinLlmExecutionTools } from '../llm-providers/_multiple/joinLlmExecutionTools';
128
133
  import { MultipleLlmExecutionTools } from '../llm-providers/_multiple/MultipleLlmExecutionTools';
134
+ import { Agent } from '../llm-providers/agent/Agent';
129
135
  import { AgentLlmExecutionTools } from '../llm-providers/agent/AgentLlmExecutionTools';
130
136
  import { createAgentLlmExecutionTools } from '../llm-providers/agent/createAgentLlmExecutionTools';
131
137
  import { _AgentMetadata } from '../llm-providers/agent/register-configuration';
@@ -168,14 +174,20 @@ import { _WebsiteScraperMetadataRegistration } from '../scrapers/website/registe
168
174
  import { BlackholeStorage } from '../storage/blackhole/BlackholeStorage';
169
175
  import { MemoryStorage } from '../storage/memory/MemoryStorage';
170
176
  import { PrefixStorage } from '../storage/utils/PrefixStorage';
177
+ import { $bookTranspilersRegister } from '../transpilers/_common/register/$bookTranspilersRegister';
178
+ import { FormattedBookInMarkdownTranspiler } from '../transpilers/formatted-book-in-markdown/FormattedBookInMarkdownTranspiler';
179
+ import { OpenAiSdkTranspiler } from '../transpilers/openai-sdk/OpenAiSdkTranspiler';
171
180
  import { MODEL_VARIANTS } from '../types/ModelVariant';
172
181
  import { NonTaskSectionTypes } from '../types/SectionType';
173
182
  import { SectionTypes } from '../types/SectionType';
174
183
  import { TaskTypes } from '../types/TaskType';
184
+ import { aboutPromptbookInformation } from '../utils/misc/aboutPromptbookInformation';
175
185
  import { REMOTE_SERVER_URLS } from '../../servers';
176
186
  export { BOOK_LANGUAGE_VERSION, PROMPTBOOK_ENGINE_VERSION };
177
187
  export { createAgentModelRequirements };
178
188
  export { createAgentModelRequirementsWithCommitments };
189
+ export { PADDING_LINES };
190
+ export { padBook };
179
191
  export { parseAgentSource };
180
192
  export { parseParameters };
181
193
  export { isValidBook };
@@ -189,16 +201,17 @@ export { getAllCommitmentDefinitions };
189
201
  export { getAllCommitmentTypes };
190
202
  export { isCommitmentSupported };
191
203
  export { generatePlaceholderAgentProfileImageUrl };
192
- export { collectionToJson };
193
- export { createCollectionFromJson };
194
- export { createCollectionFromPromise };
195
- export { createCollectionFromUrl };
196
- export { createSubcollection };
204
+ export { createPipelineCollectionFromJson };
205
+ export { createPipelineCollectionFromPromise };
206
+ export { createPipelineCollectionFromUrl };
207
+ export { createPipelineSubcollection };
208
+ export { pipelineCollectionToJson };
197
209
  export { NAME };
198
210
  export { ADMIN_EMAIL };
199
211
  export { ADMIN_GITHUB_NAME };
200
212
  export { CLAIM };
201
213
  export { PROMPTBOOK_COLOR };
214
+ export { PROMPTBOOK_SYNTAX_COLORS };
202
215
  export { PROMPTBOOK_CHAT_COLOR };
203
216
  export { USER_CHAT_COLOR };
204
217
  export { DEFAULT_BOOK_TITLE };
@@ -216,6 +229,7 @@ export { DEFAULT_MAX_EXECUTION_ATTEMPTS };
216
229
  export { DEFAULT_MAX_KNOWLEDGE_SOURCES_SCRAPING_DEPTH };
217
230
  export { DEFAULT_MAX_KNOWLEDGE_SOURCES_SCRAPING_TOTAL };
218
231
  export { DEFAULT_BOOKS_DIRNAME };
232
+ export { DEFAULT_AGENTS_DIRNAME };
219
233
  export { DEFAULT_DOWNLOAD_CACHE_DIRNAME };
220
234
  export { DEFAULT_EXECUTION_CACHE_DIRNAME };
221
235
  export { DEFAULT_SCRAPE_CACHE_DIRNAME };
@@ -254,6 +268,7 @@ export { ExpectError };
254
268
  export { KnowledgeScrapeError };
255
269
  export { LimitReachedError };
256
270
  export { MissingToolsError };
271
+ export { NotAllowed };
257
272
  export { NotFoundError };
258
273
  export { NotYetImplementedError };
259
274
  export { ParseError };
@@ -301,6 +316,7 @@ export { limitTotalUsage };
301
316
  export { getSingleLlmExecutionTools };
302
317
  export { joinLlmExecutionTools };
303
318
  export { MultipleLlmExecutionTools };
319
+ export { Agent };
304
320
  export { AgentLlmExecutionTools };
305
321
  export { createAgentLlmExecutionTools };
306
322
  export { _AgentMetadata };
@@ -343,8 +359,12 @@ export { _WebsiteScraperMetadataRegistration };
343
359
  export { BlackholeStorage };
344
360
  export { MemoryStorage };
345
361
  export { PrefixStorage };
362
+ export { $bookTranspilersRegister };
363
+ export { FormattedBookInMarkdownTranspiler };
364
+ export { OpenAiSdkTranspiler };
346
365
  export { MODEL_VARIANTS };
347
366
  export { NonTaskSectionTypes };
348
367
  export { SectionTypes };
349
368
  export { TaskTypes };
369
+ export { aboutPromptbookInformation };
350
370
  export { REMOTE_SERVER_URLS };
@@ -1,5 +1,6 @@
1
1
  import { BOOK_LANGUAGE_VERSION, PROMPTBOOK_ENGINE_VERSION } from '../version';
2
- import { createCollectionFromDirectory } from '../collection/constructors/createCollectionFromDirectory';
2
+ import { AgentCollectionInDirectory } from '../collection/agent-collection/constructors/AgentCollectionInDirectory';
3
+ import { createPipelineCollectionFromDirectory } from '../collection/pipeline-collection/constructors/createPipelineCollectionFromDirectory';
3
4
  import { $provideExecutablesForNode } from '../executables/$provideExecutablesForNode';
4
5
  import { $provideExecutionToolsForNode } from '../execution/utils/$provideExecutionToolsForNode';
5
6
  import { $provideLlmToolsConfigurationFromEnv } from '../llm-providers/_common/register/$provideLlmToolsConfigurationFromEnv';
@@ -11,7 +12,8 @@ import { FileCacheStorage } from '../storage/file-cache-storage/FileCacheStorage
11
12
  import { $execCommand } from '../utils/execCommand/$execCommand';
12
13
  import { $execCommands } from '../utils/execCommand/$execCommands';
13
14
  export { BOOK_LANGUAGE_VERSION, PROMPTBOOK_ENGINE_VERSION };
14
- export { createCollectionFromDirectory };
15
+ export { AgentCollectionInDirectory };
16
+ export { createPipelineCollectionFromDirectory };
15
17
  export { $provideExecutablesForNode };
16
18
  export { $provideExecutionToolsForNode };
17
19
  export { $provideLlmToolsConfigurationFromEnv };
@@ -2,11 +2,13 @@ import { BOOK_LANGUAGE_VERSION, PROMPTBOOK_ENGINE_VERSION } from '../version';
2
2
  import type { Identification } from '../remote-server/socket-types/_subtypes/Identification';
3
3
  import type { ApplicationModeIdentification } from '../remote-server/socket-types/_subtypes/Identification';
4
4
  import type { AnonymousModeIdentification } from '../remote-server/socket-types/_subtypes/Identification';
5
+ import { startAgentServer } from '../remote-server/startAgentServer';
5
6
  import { startRemoteServer } from '../remote-server/startRemoteServer';
6
7
  import type { RemoteServerOptions } from '../remote-server/types/RemoteServerOptions';
7
8
  export { BOOK_LANGUAGE_VERSION, PROMPTBOOK_ENGINE_VERSION };
8
9
  export type { Identification };
9
10
  export type { ApplicationModeIdentification };
10
11
  export type { AnonymousModeIdentification };
12
+ export { startAgentServer };
11
13
  export { startRemoteServer };
12
14
  export type { RemoteServerOptions };
@@ -21,7 +21,9 @@ import type { string_chat_format_name } from '../book-components/Chat/save/_comm
21
21
  import type { ChatMessage } from '../book-components/Chat/types/ChatMessage';
22
22
  import type { ChatParticipant } from '../book-components/Chat/types/ChatParticipant';
23
23
  import type { MessageButton } from '../book-components/Chat/utils/parseMessageButtons';
24
- import type { PipelineCollection } from '../collection/PipelineCollection';
24
+ import type { QrCodeOptions } from '../book-components/Qr/useQrCode';
25
+ import type { AgentCollection } from '../collection/agent-collection/AgentCollection';
26
+ import type { PipelineCollection } from '../collection/pipeline-collection/PipelineCollection';
25
27
  import type { Command } from '../commands/_common/types/Command';
26
28
  import type { CommandParser } from '../commands/_common/types/CommandParser';
27
29
  import type { PipelineBothCommandParser } from '../commands/_common/types/CommandParser';
@@ -98,7 +100,8 @@ import type { LlmToolsOptions } from '../llm-providers/_common/register/LlmTools
98
100
  import type { CacheItem } from '../llm-providers/_common/utils/cache/CacheItem';
99
101
  import type { CacheLlmToolsOptions } from '../llm-providers/_common/utils/cache/CacheLlmToolsOptions';
100
102
  import type { LlmExecutionToolsWithTotalUsage } from '../llm-providers/_common/utils/count-total-usage/LlmExecutionToolsWithTotalUsage';
101
- import type { CreateAgentLlmExecutionToolsOptions } from '../llm-providers/agent/createAgentLlmExecutionTools';
103
+ import type { AgentOptions } from '../llm-providers/agent/AgentOptions';
104
+ import type { CreateAgentLlmExecutionToolsOptions } from '../llm-providers/agent/CreateAgentLlmExecutionToolsOptions';
102
105
  import type { AnthropicClaudeExecutionToolsOptions } from '../llm-providers/anthropic-claude/AnthropicClaudeExecutionToolsOptions';
103
106
  import type { AnthropicClaudeExecutionToolsNonProxiedOptions } from '../llm-providers/anthropic-claude/AnthropicClaudeExecutionToolsOptions';
104
107
  import type { AnthropicClaudeExecutionToolsProxiedOptions } from '../llm-providers/anthropic-claude/AnthropicClaudeExecutionToolsOptions';
@@ -166,7 +169,10 @@ import type { PostprocessingFunction } from '../scripting/javascript/JavascriptE
166
169
  import type { PromptbookStorage } from '../storage/_common/PromptbookStorage';
167
170
  import type { FileCacheStorageOptions } from '../storage/file-cache-storage/FileCacheStorageOptions';
168
171
  import type { IndexedDbStorageOptions } from '../storage/local-storage/utils/IndexedDbStorageOptions';
172
+ import type { BookTranspiler } from '../transpilers/_common/BookTranspiler';
173
+ import type { BookTranspilerOptions } from '../transpilers/_common/BookTranspilerOptions';
169
174
  import type { IntermediateFilesStrategy } from '../types/IntermediateFilesStrategy';
175
+ import type { LlmCall } from '../types/LlmCall';
170
176
  import type { ModelRequirements } from '../types/ModelRequirements';
171
177
  import type { CompletionModelRequirements } from '../types/ModelRequirements';
172
178
  import type { ChatModelRequirements } from '../types/ModelRequirements';
@@ -306,6 +312,7 @@ import type { number_kilobytes } from '../types/typeAliases';
306
312
  import type { number_megabytes } from '../types/typeAliases';
307
313
  import type { number_gigabytes } from '../types/typeAliases';
308
314
  import type { number_terabytes } from '../types/typeAliases';
315
+ import type { Updatable } from '../types/Updatable';
309
316
  import type { ColorTransformer } from '../utils/color/operators/ColorTransformer';
310
317
  import type { PipelineEditableSerialized } from '../utils/editable/types/PipelineEditableSerialized';
311
318
  import type { ExecCommandOptions } from '../utils/execCommand/ExecCommandOptions';
@@ -314,6 +321,7 @@ import type { CodeBlock } from '../utils/markdown/extractAllBlocksFromMarkdown';
314
321
  import type { MarkdownSection } from '../utils/markdown/parseMarkdownSection';
315
322
  import type { Registered } from '../utils/misc/$Register';
316
323
  import type { Registration } from '../utils/misc/$Register';
324
+ import type { AboutPromptbookInformationOptions } from '../utils/misc/aboutPromptbookInformation';
317
325
  import type { FromtoItems } from '../utils/misc/FromtoItems';
318
326
  import type { InjectCssModuleIntoShadowRootOptions } from '../utils/misc/injectCssModuleIntoShadowRoot';
319
327
  import type { string_keyword } from '../utils/normalization/IKeywords';
@@ -354,6 +362,8 @@ export type { string_chat_format_name };
354
362
  export type { ChatMessage };
355
363
  export type { ChatParticipant };
356
364
  export type { MessageButton };
365
+ export type { QrCodeOptions };
366
+ export type { AgentCollection };
357
367
  export type { PipelineCollection };
358
368
  export type { Command };
359
369
  export type { CommandParser };
@@ -431,6 +441,7 @@ export type { LlmToolsOptions };
431
441
  export type { CacheItem };
432
442
  export type { CacheLlmToolsOptions };
433
443
  export type { LlmExecutionToolsWithTotalUsage };
444
+ export type { AgentOptions };
434
445
  export type { CreateAgentLlmExecutionToolsOptions };
435
446
  export type { AnthropicClaudeExecutionToolsOptions };
436
447
  export type { AnthropicClaudeExecutionToolsNonProxiedOptions };
@@ -499,7 +510,10 @@ export type { PostprocessingFunction };
499
510
  export type { PromptbookStorage };
500
511
  export type { FileCacheStorageOptions };
501
512
  export type { IndexedDbStorageOptions };
513
+ export type { BookTranspiler };
514
+ export type { BookTranspilerOptions };
502
515
  export type { IntermediateFilesStrategy };
516
+ export type { LlmCall };
503
517
  export type { ModelRequirements };
504
518
  export type { CompletionModelRequirements };
505
519
  export type { ChatModelRequirements };
@@ -639,6 +653,7 @@ export type { number_kilobytes };
639
653
  export type { number_megabytes };
640
654
  export type { number_gigabytes };
641
655
  export type { number_terabytes };
656
+ export type { Updatable };
642
657
  export type { ColorTransformer };
643
658
  export type { PipelineEditableSerialized };
644
659
  export type { ExecCommandOptions };
@@ -647,6 +662,7 @@ export type { CodeBlock };
647
662
  export type { MarkdownSection };
648
663
  export type { Registered };
649
664
  export type { Registration };
665
+ export type { AboutPromptbookInformationOptions };
650
666
  export type { FromtoItems };
651
667
  export type { InjectCssModuleIntoShadowRootOptions };
652
668
  export type { string_keyword };
@@ -29,6 +29,8 @@ import { _PdfScraperRegistration } from '../scrapers/pdf/register-constructor';
29
29
  import { _PdfScraperMetadataRegistration } from '../scrapers/pdf/register-metadata';
30
30
  import { _WebsiteScraperRegistration } from '../scrapers/website/register-constructor';
31
31
  import { _WebsiteScraperMetadataRegistration } from '../scrapers/website/register-metadata';
32
+ import { _FormattedBookInMarkdownTranspilerRegistration } from '../transpilers/formatted-book-in-markdown/register';
33
+ import { _OpenAiSdkTranspilerRegistration } from '../transpilers/openai-sdk/register';
32
34
  import { wizard } from '../wizard/wizard';
33
35
  export { BOOK_LANGUAGE_VERSION, PROMPTBOOK_ENGINE_VERSION };
34
36
  export { _AnthropicClaudeMetadataRegistration };
@@ -61,4 +63,6 @@ export { _PdfScraperRegistration };
61
63
  export { _PdfScraperMetadataRegistration };
62
64
  export { _WebsiteScraperRegistration };
63
65
  export { _WebsiteScraperMetadataRegistration };
66
+ export { _FormattedBookInMarkdownTranspilerRegistration };
67
+ export { _OpenAiSdkTranspilerRegistration };
64
68
  export { wizard };
@@ -55,5 +55,6 @@ export type AgentBasicInformation = {
55
55
  parameters: BookParameter[];
56
56
  };
57
57
  /**
58
+ * TODO: All readonly
58
59
  * TODO: [🕛] Unite `AgentBasicInformation`, `ChatParticipant`, `LlmExecutionTools` + `LlmToolsMetadata`
59
60
  */
@@ -0,0 +1,16 @@
1
+ import { string_book } from './string_book';
2
+ /**
3
+ * Number of padding lines to add at the end of the book content
4
+ *
5
+ * @public exported from `@promptbook/core`
6
+ */
7
+ export declare const PADDING_LINES = 11;
8
+ /**
9
+ * A function that adds padding to the book content
10
+ *
11
+ * @public exported from `@promptbook/core`
12
+ */
13
+ export declare function padBook(content: string_book): string_book;
14
+ /**
15
+ * TODO: [🧠] Maybe export
16
+ */
@@ -1,7 +1,15 @@
1
- import type { CSSProperties } from 'react';
1
+ import { CSSProperties } from 'react';
2
2
  import type { Promisable } from 'type-fest';
3
- import type { string_book } from '../../book-2.0/agent-source/string_book';
4
- import type { string_knowledge_source_content } from '../../types/typeAliases';
3
+ import { type string_book } from '../../book-2.0/agent-source/string_book';
4
+ import type { number_percent, number_positive, string_css_value, string_knowledge_source_content } from '../../types/typeAliases';
5
+ /**
6
+ * Default height of the book editor
7
+ *
8
+ * Note: This height is computed based on the number of lines in the default book + padding multiplied by an estimated line height.
9
+ *
10
+ * @public exported from `@promptbook/components`
11
+ */
12
+ export declare const DEFAULT_BOOK_EDITOR_HEIGHT: number;
5
13
  /**
6
14
  * Props of `BookEditor`
7
15
  *
@@ -12,10 +20,6 @@ export type BookEditorProps = {
12
20
  * The source of the agent to be displayed in the editor.
13
21
  */
14
22
  readonly agentSource?: string_book;
15
- /**
16
- * Callback function to be called when the editor is closed.
17
- */
18
- onClose?(): void;
19
23
  /**
20
24
  * Additional CSS classes to apply to the editor container.
21
25
  */
@@ -25,10 +29,21 @@ export type BookEditorProps = {
25
29
  */
26
30
  readonly style?: CSSProperties;
27
31
  /**
28
- * CSS className for a font (e.g. from next/font) to style the editor text.
29
- * If omitted, defaults to system serif fonts.
32
+ * Height of the `BookEditor` component
33
+ *
34
+ * - You can use any valid CSS value, e.g., `500px`, `100%`, `50vh`, etc.
35
+ * - If not set, the default height is `DEFAULT_BOOK_EDITOR_HEIGHT`.
36
+ * - If set to `null`, the height should be controlled entirely via `className` or `style`, otherwise the editor will have zero height.
37
+ *
38
+ * @default `DEFAULT_BOOK_EDITOR_HEIGHT`
30
39
  */
31
- readonly fontClassName?: string;
40
+ readonly height?: string_css_value | null;
41
+ /**
42
+ * Zoom level of the editor
43
+ *
44
+ * @default 1 (100%)
45
+ */
46
+ readonly zoom?: number_percent & number_positive;
32
47
  /**
33
48
  * The book which is being edited.
34
49
  */
@@ -49,17 +64,63 @@ export type BookEditorProps = {
49
64
  * If true, disables border radius making the editor have sharp corners
50
65
  */
51
66
  readonly isBorderRadiusDisabled?: boolean;
52
- /**
53
- * If true, shows the footer with book title and version information.
54
- * By default, the footer is hidden.
55
- */
56
- readonly isFooterShown?: boolean;
57
67
  /**
58
68
  * If true, the editor is in read-only mode
59
69
  *
60
70
  * @default false
61
71
  */
62
72
  readonly isReadonly?: boolean;
73
+ /**
74
+ * Optional translations for the component
75
+ */
76
+ readonly translations?: {
77
+ /**
78
+ * Message to show when trying to edit a readonly editor
79
+ *
80
+ * @default "You cannot edit this book"
81
+ */
82
+ readonly readonlyMessage?: string;
83
+ };
84
+ /**
85
+ * If true, shows the download button in the action bar.
86
+ * By default, the download button is shown.
87
+ */
88
+ readonly isDownloadButtonShown?: boolean;
89
+ /**
90
+ * If true, shows the about button in the action bar.
91
+ * By default, the about button is shown.
92
+ */
93
+ readonly isAboutButtonShown?: boolean;
94
+ /**
95
+ * If true, shows the fullscreen button in the action bar.
96
+ * By default, the fullscreen button is shown.
97
+ */
98
+ readonly isFullscreenButtonShown?: boolean;
99
+ /**
100
+ * Callback function to handle fullscreen button click.
101
+ * Note: This is for internal use between BookEditor and BookEditorMonaco
102
+ * @private
103
+ */
104
+ onFullscreenClick?(): void;
105
+ /**
106
+ * If true, the editor is in fullscreen mode.
107
+ * Note: This is for internal use between BookEditor and BookEditorMonaco
108
+ * @private
109
+ */
110
+ readonly isFullscreen?: boolean;
111
+ /**
112
+ * If defined, the editor will be synced with other editors with the same sync configuration.
113
+ */
114
+ readonly sync?: {
115
+ /**
116
+ * The URL of the y-websocket server.
117
+ */
118
+ readonly serverUrl: string;
119
+ /**
120
+ * The name of the room to join.
121
+ */
122
+ readonly roomName: string;
123
+ };
63
124
  };
64
125
  /**
65
126
  * Renders a book editor
@@ -0,0 +1,14 @@
1
+ type BookEditorActionbarProps = {
2
+ value: string | undefined;
3
+ isDownloadButtonShown?: boolean;
4
+ isAboutButtonShown?: boolean;
5
+ isFullscreenButtonShown?: boolean;
6
+ onFullscreenClick?: () => void;
7
+ isFullscreen?: boolean;
8
+ };
9
+ /**
10
+ *
11
+ * @private Internal component used by `BookEditor`
12
+ */
13
+ export declare function BookEditorActionbar(props: BookEditorActionbarProps): import("react/jsx-runtime").JSX.Element;
14
+ export {};
@@ -0,0 +1,5 @@
1
+ import type { BookEditorProps } from './BookEditor';
2
+ /**
3
+ * @private Internal component used by `BookEditor`
4
+ */
5
+ export declare function BookEditorMonaco(props: BookEditorProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,15 @@
1
+ import type { string_markdown } from '../../../types/typeAliases';
2
+ type MarkdownContentProps = {
3
+ content: string_markdown;
4
+ className?: string;
5
+ };
6
+ /**
7
+ * Renders markdown content with support for code highlighting, math, and tables.
8
+ *
9
+ * @public exported from `@promptbook/components`
10
+ */
11
+ export declare function MarkdownContent(props: MarkdownContentProps): import("react/jsx-runtime").JSX.Element;
12
+ export {};
13
+ /**
14
+ * TODO: !!! Split into multiple files
15
+ */
@@ -42,6 +42,11 @@ export type MockedChatDelayConfig = {
42
42
  * If true, disables typing effect and shows full message at once (BLOCKY_FLOW)
43
43
  */
44
44
  blocky?: boolean;
45
+ /**
46
+ * This prop will allow to show N first messages immediately, while the rest will be typed out with delays
47
+ * @default 0
48
+ */
49
+ showIntermediateMessages?: number;
45
50
  };
46
51
  /**
47
52
  * Props for MockedChat component
@@ -15,5 +15,6 @@ export declare const htmlSaveFormatDefinition: {
15
15
  readonly fileExtension: "html";
16
16
  };
17
17
  /**
18
+ * TODO: !!! Add QR code with branding to the footer
18
19
  * TODO: [😬] Take chat save to HTML from existing parallel implementation
19
20
  */
@@ -14,3 +14,7 @@ export declare const pdfSaveFormatDefinition: {
14
14
  readonly mimeType: "application/pdf";
15
15
  readonly fileExtension: "pdf";
16
16
  };
17
+ /**
18
+ * TODO: !!! Add QR code with branding to the footer
19
+ * TODO: !!! Add print option
20
+ */
@@ -0,0 +1,18 @@
1
+ import { QrCodeOptions } from './useQrCode';
2
+ type BrandedQrCodeProps = QrCodeOptions & {
3
+ /**
4
+ * Width and height of the QR code canvas
5
+ *
6
+ * @default 250
7
+ */
8
+ size?: number;
9
+ /**
10
+ * Additional CSS class names to apply to the container div
11
+ */
12
+ className?: string;
13
+ };
14
+ /**
15
+ * @public exported from `@promptbook/components`
16
+ */
17
+ export declare function BrandedQrCode(props: BrandedQrCodeProps): import("react/jsx-runtime").JSX.Element;
18
+ export {};
@@ -0,0 +1,10 @@
1
+ type GenericQrCodeProps = {
2
+ value: string | number;
3
+ size?: number;
4
+ className?: string;
5
+ };
6
+ /**
7
+ * @public exported from `@promptbook/components`
8
+ */
9
+ export declare function GenericQrCode({ value, size, className }: GenericQrCodeProps): import("react/jsx-runtime").JSX.Element;
10
+ export {};
@@ -0,0 +1,18 @@
1
+ type PromptbookQrCodeProps = {
2
+ value: string | number;
3
+ /**
4
+ * Width and height of the QR code canvas
5
+ *
6
+ * @default 250
7
+ */
8
+ size?: number;
9
+ /**
10
+ * Additional CSS class names to apply to the container div
11
+ */
12
+ className?: string;
13
+ };
14
+ /**
15
+ * @public exported from `@promptbook/components`
16
+ */
17
+ export declare function PromptbookQrCode(props: PromptbookQrCodeProps): import("react/jsx-runtime").JSX.Element;
18
+ export {};