@promptbook/remote-server 0.75.0-1 → 0.75.0-2

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 (156) hide show
  1. package/README.md +1 -0
  2. package/esm/index.es.js +6 -1
  3. package/esm/index.es.js.map +1 -1
  4. package/esm/typings/promptbook-collection/index.d.ts +6 -6
  5. package/esm/typings/src/_packages/core.index.d.ts +22 -20
  6. package/esm/typings/src/_packages/types.index.d.ts +58 -50
  7. package/esm/typings/src/_packages/utils.index.d.ts +2 -2
  8. package/esm/typings/src/cli/cli-commands/about.d.ts +1 -0
  9. package/esm/typings/src/cli/cli-commands/hello.d.ts +1 -0
  10. package/esm/typings/src/cli/cli-commands/make.d.ts +1 -0
  11. package/esm/typings/src/cli/cli-commands/prettify.d.ts +1 -0
  12. package/esm/typings/src/cli/cli-commands/run.d.ts +1 -0
  13. package/esm/typings/src/cli/cli-commands/test-command.d.ts +1 -0
  14. package/esm/typings/src/cli/main.d.ts +1 -0
  15. package/esm/typings/src/collection/PipelineCollection.d.ts +1 -1
  16. package/esm/typings/src/collection/SimplePipelineCollection.d.ts +1 -1
  17. package/esm/typings/src/collection/collectionToJson.d.ts +1 -1
  18. package/esm/typings/src/collection/constructors/createCollectionFromJson.d.ts +1 -1
  19. package/esm/typings/src/collection/constructors/createCollectionFromPromise.d.ts +1 -1
  20. package/esm/typings/src/commands/EXPECT/ExpectCommand.d.ts +2 -2
  21. package/esm/typings/src/commands/EXPECT/expectCommandParser.d.ts +2 -2
  22. package/esm/typings/src/commands/FOREACH/foreachCommandParser.d.ts +2 -2
  23. package/esm/typings/src/commands/FORMAT/formatCommandParser.d.ts +2 -2
  24. package/esm/typings/src/commands/JOKER/jokerCommandParser.d.ts +2 -2
  25. package/esm/typings/src/commands/POSTPROCESS/postprocessCommandParser.d.ts +2 -2
  26. package/esm/typings/src/commands/SECTION/SectionCommand.d.ts +11 -0
  27. package/esm/typings/src/commands/SECTION/SectionType.d.ts +13 -0
  28. package/esm/typings/src/commands/{TEMPLATE/templateCommandParser.d.ts → SECTION/sectionCommandParser.d.ts} +6 -6
  29. package/esm/typings/src/commands/_common/types/Command.d.ts +1 -1
  30. package/esm/typings/src/commands/_common/types/CommandParser.d.ts +17 -17
  31. package/esm/typings/src/commands/_common/types/CommandUsagePlaces.d.ts +1 -1
  32. package/esm/typings/src/commands/index.d.ts +4 -1
  33. package/esm/typings/src/config.d.ts +2 -1
  34. package/esm/typings/src/conversion/pipelineJsonToString.d.ts +2 -2
  35. package/esm/typings/src/conversion/pipelineStringToJson.d.ts +2 -2
  36. package/esm/typings/src/conversion/pipelineStringToJsonSync.d.ts +3 -3
  37. package/esm/typings/src/conversion/prettify/prettifyPipelineString.d.ts +1 -1
  38. package/esm/typings/src/conversion/prettify/renderPipelineMermaidOptions.d.ts +3 -3
  39. package/esm/typings/src/conversion/utils/{extractParameterNamesFromTemplate.d.ts → extractParameterNamesFromTask.d.ts} +2 -2
  40. package/esm/typings/src/conversion/utils/renameParameter.d.ts +1 -1
  41. package/esm/typings/src/conversion/validation/_importPipeline.d.ts +3 -2
  42. package/esm/typings/src/conversion/validation/validatePipeline.d.ts +1 -1
  43. package/esm/typings/src/errors/index.d.ts +3 -0
  44. package/esm/typings/src/execution/PipelineExecutorResult.d.ts +2 -2
  45. package/esm/typings/src/execution/PromptResultUsage.d.ts +1 -1
  46. package/esm/typings/src/execution/createPipelineExecutor/{$OngoingTemplateResult.d.ts → $OngoingTaskResult.d.ts} +1 -1
  47. package/esm/typings/src/execution/createPipelineExecutor/00-CreatePipelineExecutorOptions.d.ts +1 -1
  48. package/esm/typings/src/execution/createPipelineExecutor/10-executePipeline.d.ts +1 -1
  49. package/esm/typings/src/execution/createPipelineExecutor/{20-executeTemplate.d.ts → 20-executeTask.d.ts} +7 -7
  50. package/esm/typings/src/execution/createPipelineExecutor/40-executeAttempts.d.ts +5 -5
  51. package/esm/typings/src/execution/createPipelineExecutor/filterJustOutputParameters.d.ts +1 -1
  52. package/esm/typings/src/execution/createPipelineExecutor/{getContextForTemplate.d.ts → getContextForTask.d.ts} +2 -2
  53. package/esm/typings/src/execution/createPipelineExecutor/{getExamplesForTemplate.d.ts → getExamplesForTask.d.ts} +2 -2
  54. package/esm/typings/src/execution/createPipelineExecutor/getKnowledgeForTask.d.ts +27 -0
  55. package/esm/typings/src/execution/createPipelineExecutor/getReservedParametersForTask.d.ts +30 -0
  56. package/esm/typings/src/{types → execution}/execution-report/ExecutionPromptReportJson.d.ts +2 -2
  57. package/esm/typings/src/{types → execution}/execution-report/ExecutionReportJson.d.ts +4 -4
  58. package/esm/typings/src/{types → execution}/execution-report/ExecutionReportStringOptions.d.ts +1 -1
  59. package/esm/typings/src/execution/utils/checkExpectations.d.ts +1 -1
  60. package/esm/typings/src/execution/utils/usage-constants.d.ts +3 -0
  61. package/esm/typings/src/formats/index.d.ts +3 -0
  62. package/esm/typings/src/formfactors/_common/AbstractFormfactorDefinition.d.ts +4 -1
  63. package/esm/typings/src/formfactors/_common/FormfactorDefinition.d.ts +3 -0
  64. package/esm/typings/src/formfactors/{chat/ChatFormfactorDefinition.d.ts → chatbot/ChatbotFormfactorDefinition.d.ts} +2 -2
  65. package/esm/typings/src/formfactors/generic/GenericFormfactorDefinition.d.ts +1 -1
  66. package/esm/typings/src/formfactors/index.d.ts +15 -4
  67. package/esm/typings/src/formfactors/matcher/MatcherFormfactorDefinition.d.ts +14 -0
  68. package/esm/typings/src/formfactors/sheets/SheetsFormfactorDefinition.d.ts +1 -1
  69. package/esm/typings/src/formfactors/translator/TranslatorFormfactorDefinition.d.ts +1 -1
  70. package/esm/typings/src/llm-providers/anthropic-claude/anthropic-claude-models.d.ts +1 -0
  71. package/esm/typings/src/llm-providers/anthropic-claude/register-configuration.d.ts +3 -0
  72. package/esm/typings/src/llm-providers/anthropic-claude/register-constructor.d.ts +1 -0
  73. package/esm/typings/src/llm-providers/azure-openai/register-configuration.d.ts +3 -0
  74. package/esm/typings/src/llm-providers/azure-openai/register-constructor.d.ts +1 -0
  75. package/esm/typings/src/llm-providers/mocked/$fakeTextToExpectations.d.ts +1 -1
  76. package/esm/typings/src/llm-providers/openai/openai-models.d.ts +1 -0
  77. package/esm/typings/src/llm-providers/openai/register-configuration.d.ts +3 -0
  78. package/esm/typings/src/llm-providers/openai/register-constructor.d.ts +1 -0
  79. package/esm/typings/src/personas/preparePersona.d.ts +1 -1
  80. package/esm/typings/src/pipeline/{pipeline-interface → PipelineInterface}/PipelineInterface.d.ts +3 -0
  81. package/esm/typings/src/pipeline/{pipeline-interface → PipelineInterface}/constants.d.ts +5 -0
  82. package/esm/typings/src/pipeline/{pipeline-interface → PipelineInterface}/getPipelineInterface.d.ts +3 -1
  83. package/esm/typings/src/pipeline/{pipeline-interface → PipelineInterface}/isPipelineImplementingInterface.d.ts +5 -1
  84. package/esm/typings/src/pipeline/{pipeline-interface → PipelineInterface}/isPipelineInterfacesEqual.d.ts +2 -0
  85. package/esm/typings/src/pipeline/PipelineJson/DialogTaskJson.d.ts +13 -0
  86. package/esm/typings/src/{types → pipeline}/PipelineJson/Expectations.d.ts +2 -2
  87. package/esm/typings/src/{types → pipeline}/PipelineJson/KnowledgePieceJson.d.ts +7 -6
  88. package/esm/typings/src/{types → pipeline}/PipelineJson/KnowledgeSourceJson.d.ts +3 -3
  89. package/esm/typings/src/pipeline/PipelineJson/ParameterJson.d.ts +96 -0
  90. package/esm/typings/src/{types → pipeline}/PipelineJson/PersonaJson.d.ts +4 -4
  91. package/esm/typings/src/{types → pipeline}/PipelineJson/PipelineJson.d.ts +10 -10
  92. package/esm/typings/src/{types → pipeline}/PipelineJson/PreparationJson.d.ts +1 -1
  93. package/esm/typings/src/{types/PipelineJson/PromptTemplateJson.d.ts → pipeline/PipelineJson/PromptTaskJson.d.ts} +8 -8
  94. package/esm/typings/src/pipeline/PipelineJson/ScriptTaskJson.d.ts +20 -0
  95. package/esm/typings/src/pipeline/PipelineJson/SimpleTaskJson.d.ts +13 -0
  96. package/esm/typings/src/pipeline/PipelineJson/TaskJson.d.ts +11 -0
  97. package/esm/typings/src/{types/PipelineJson/TemplateJsonCommon.d.ts → pipeline/PipelineJson/TaskJsonCommon.d.ts} +13 -13
  98. package/esm/typings/src/{types → pipeline}/PipelineString.d.ts +1 -1
  99. package/esm/typings/src/prepare/isPipelinePrepared.d.ts +2 -2
  100. package/esm/typings/src/prepare/preparePipeline.d.ts +1 -1
  101. package/esm/typings/src/prepare/{prepareTemplates.d.ts → prepareTasks.d.ts} +7 -7
  102. package/esm/typings/src/prepare/unpreparePipeline.d.ts +1 -1
  103. package/esm/typings/src/scrapers/_common/Scraper.d.ts +1 -1
  104. package/esm/typings/src/scrapers/_common/prepareKnowledgePieces.d.ts +2 -2
  105. package/esm/typings/src/scrapers/_common/utils/makeKnowledgeSourceHandler.d.ts +1 -1
  106. package/esm/typings/src/scrapers/document/DocumentScraper.d.ts +1 -1
  107. package/esm/typings/src/scrapers/document/register-constructor.d.ts +1 -0
  108. package/esm/typings/src/scrapers/document/register-metadata.d.ts +3 -0
  109. package/esm/typings/src/scrapers/document-legacy/LegacyDocumentScraper.d.ts +1 -1
  110. package/esm/typings/src/scrapers/document-legacy/register-constructor.d.ts +1 -0
  111. package/esm/typings/src/scrapers/document-legacy/register-metadata.d.ts +3 -0
  112. package/esm/typings/src/scrapers/markdown/MarkdownScraper.d.ts +1 -1
  113. package/esm/typings/src/scrapers/markdown/register-constructor.d.ts +1 -0
  114. package/esm/typings/src/scrapers/markdown/register-metadata.d.ts +3 -0
  115. package/esm/typings/src/scrapers/pdf/PdfScraper.d.ts +1 -1
  116. package/esm/typings/src/scrapers/pdf/register-constructor.d.ts +1 -0
  117. package/esm/typings/src/scrapers/pdf/register-metadata.d.ts +3 -0
  118. package/esm/typings/src/scrapers/website/WebsiteScraper.d.ts +1 -1
  119. package/esm/typings/src/scrapers/website/register-constructor.d.ts +1 -0
  120. package/esm/typings/src/scrapers/website/register-metadata.d.ts +3 -0
  121. package/esm/typings/src/scripting/javascript/postprocessing-functions.d.ts +1 -0
  122. package/esm/typings/src/types/Prompt.d.ts +1 -1
  123. package/esm/typings/src/types/TaskProgress.d.ts +2 -2
  124. package/esm/typings/src/types/typeAliasEmoji.d.ts +3 -0
  125. package/esm/typings/src/types/typeAliases.d.ts +1 -0
  126. package/esm/typings/src/utils/emojis.d.ts +1 -0
  127. package/esm/typings/src/utils/expectation-counters/constants.d.ts +1 -0
  128. package/esm/typings/src/utils/expectation-counters/countCharacters.d.ts +1 -1
  129. package/esm/typings/src/utils/expectation-counters/countLines.d.ts +1 -1
  130. package/esm/typings/src/utils/expectation-counters/countPages.d.ts +1 -1
  131. package/esm/typings/src/utils/expectation-counters/countParagraphs.d.ts +1 -1
  132. package/esm/typings/src/utils/expectation-counters/countSentences.d.ts +1 -1
  133. package/esm/typings/src/utils/expectation-counters/countWords.d.ts +1 -1
  134. package/esm/typings/src/utils/expectation-counters/index.d.ts +3 -2
  135. package/esm/typings/src/utils/normalization/normalize-to-kebab-case.d.ts +3 -0
  136. package/esm/typings/src/utils/parameters/extractParameterNames.d.ts +2 -2
  137. package/esm/typings/src/utils/serialization/clonePipeline.d.ts +1 -1
  138. package/esm/typings/src/version.d.ts +2 -1
  139. package/package.json +5 -4
  140. package/umd/index.umd.js +6 -1
  141. package/umd/index.umd.js.map +1 -1
  142. package/esm/typings/src/commands/TEMPLATE/TemplateCommand.d.ts +0 -11
  143. package/esm/typings/src/commands/TEMPLATE/TemplateTypes.d.ts +0 -15
  144. package/esm/typings/src/execution/createPipelineExecutor/getKnowledgeForTemplate.d.ts +0 -27
  145. package/esm/typings/src/execution/createPipelineExecutor/getReservedParametersForTemplate.d.ts +0 -30
  146. package/esm/typings/src/types/PipelineJson/DialogTemplateJson.d.ts +0 -13
  147. package/esm/typings/src/types/PipelineJson/ParameterJson.d.ts +0 -39
  148. package/esm/typings/src/types/PipelineJson/ScriptTemplateJson.d.ts +0 -20
  149. package/esm/typings/src/types/PipelineJson/SimpleTemplateJson.d.ts +0 -13
  150. package/esm/typings/src/types/PipelineJson/TemplateJson.d.ts +0 -11
  151. /package/esm/typings/src/commands/{TEMPLATE/templateCommand.test.d.ts → SECTION/sectionCommand.test.d.ts} +0 -0
  152. /package/esm/typings/src/conversion/utils/{extractParameterNamesFromTemplate.test.d.ts → extractParameterNamesFromTask.test.d.ts} +0 -0
  153. /package/esm/typings/src/{types → execution}/execution-report/ExecutionReportString.d.ts +0 -0
  154. /package/esm/typings/src/{types → execution}/execution-report/countWorkingDuration.d.ts +0 -0
  155. /package/esm/typings/src/{types → execution}/execution-report/countWorkingDuration.test.d.ts +0 -0
  156. /package/esm/typings/src/{types → execution}/execution-report/executionReportJsonToString.d.ts +0 -0
@@ -1,10 +1,10 @@
1
1
  import type { ReadonlyDeep, WritableDeep } from 'type-fest';
2
- import type { ExecutionReportJson } from '../../types/execution-report/ExecutionReportJson';
3
- import type { PipelineJson } from '../../types/PipelineJson/PipelineJson';
4
- import type { TemplateJson } from '../../types/PipelineJson/TemplateJson';
2
+ import type { PipelineJson } from '../../pipeline/PipelineJson/PipelineJson';
3
+ import type { TaskJson } from '../../pipeline/PipelineJson/TaskJson';
5
4
  import type { Parameters } from '../../types/typeAliases';
6
5
  import type { string_parameter_name } from '../../types/typeAliases';
7
6
  import type { TODO_string } from '../../utils/organization/TODO_string';
7
+ import type { ExecutionReportJson } from '../execution-report/ExecutionReportJson';
8
8
  import type { CreatePipelineExecutorOptions } from './00-CreatePipelineExecutorOptions';
9
9
  /**
10
10
  * @@@
@@ -25,7 +25,7 @@ export type ExecuteAttemptsOptions = Omit<CreatePipelineExecutorOptions, 'pipeli
25
25
  *
26
26
  * Note: [💂] There are two distinct variabiles
27
27
  * 1) `maxExecutionAttempts` - the amount of attempts LLM model
28
- * 2) `maxAttempts` - the amount of attempts for any template - LLM, SCRIPT, DIALOG, etc.
28
+ * 2) `maxAttempts` - the amount of attempts for any task - LLM, SCRIPT, DIALOG, etc.
29
29
  */
30
30
  readonly maxAttempts: number;
31
31
  /**
@@ -39,7 +39,7 @@ export type ExecuteAttemptsOptions = Omit<CreatePipelineExecutorOptions, 'pipeli
39
39
  /**
40
40
  * @@@
41
41
  */
42
- readonly template: ReadonlyDeep<TemplateJson>;
42
+ readonly task: ReadonlyDeep<TaskJson>;
43
43
  /**
44
44
  * @@@
45
45
  */
@@ -1,6 +1,6 @@
1
1
  import type { ReadonlyDeep } from 'type-fest';
2
2
  import { PipelineExecutionError } from '../../errors/PipelineExecutionError';
3
- import type { PipelineJson } from '../../types/PipelineJson/PipelineJson';
3
+ import type { PipelineJson } from '../../pipeline/PipelineJson/PipelineJson';
4
4
  import type { Parameters } from '../../types/typeAliases';
5
5
  /**
6
6
  * @@@
@@ -1,5 +1,5 @@
1
1
  import type { ReadonlyDeep } from 'type-fest';
2
- import type { TemplateJson } from '../../types/PipelineJson/TemplateJson';
2
+ import type { TaskJson } from '../../pipeline/PipelineJson/TaskJson';
3
3
  import type { string_markdown } from '../../types/typeAliases';
4
4
  import type { string_parameter_value } from '../../types/typeAliases';
5
5
  /**
@@ -7,4 +7,4 @@ import type { string_parameter_value } from '../../types/typeAliases';
7
7
  *
8
8
  * @private internal utility of `createPipelineExecutor`
9
9
  */
10
- export declare function getContextForTemplate(template: ReadonlyDeep<TemplateJson>): Promise<string_parameter_value & string_markdown>;
10
+ export declare function getContextForTask(task: ReadonlyDeep<TaskJson>): Promise<string_parameter_value & string_markdown>;
@@ -1,5 +1,5 @@
1
1
  import type { ReadonlyDeep } from 'type-fest';
2
- import type { TemplateJson } from '../../types/PipelineJson/TemplateJson';
2
+ import type { TaskJson } from '../../pipeline/PipelineJson/TaskJson';
3
3
  import type { string_markdown } from '../../types/typeAliases';
4
4
  import type { string_parameter_value } from '../../types/typeAliases';
5
5
  /**
@@ -7,4 +7,4 @@ import type { string_parameter_value } from '../../types/typeAliases';
7
7
  *
8
8
  * @private internal utility of `createPipelineExecutor`
9
9
  */
10
- export declare function getExamplesForTemplate(template: ReadonlyDeep<TemplateJson>): Promise<string_parameter_value & string_markdown>;
10
+ export declare function getExamplesForTask(task: ReadonlyDeep<TaskJson>): Promise<string_parameter_value & string_markdown>;
@@ -0,0 +1,27 @@
1
+ import type { ReadonlyDeep } from 'type-fest';
2
+ import type { PipelineJson } from '../../pipeline/PipelineJson/PipelineJson';
3
+ import type { TaskJson } from '../../pipeline/PipelineJson/TaskJson';
4
+ import type { string_markdown } from '../../types/typeAliases';
5
+ import type { string_parameter_value } from '../../types/typeAliases';
6
+ /**
7
+ * @@@
8
+ *
9
+ * @private internal type of `getKnowledgeFoTask`
10
+ */
11
+ type GetKnowledgeForTaskOptions = {
12
+ /**
13
+ * @@@
14
+ */
15
+ readonly preparedPipeline: ReadonlyDeep<PipelineJson>;
16
+ /**
17
+ * @@@
18
+ */
19
+ readonly task: ReadonlyDeep<TaskJson>;
20
+ };
21
+ /**
22
+ * @@@
23
+ *
24
+ * @private internal utility of `createPipelineExecutor`
25
+ */
26
+ export declare function getKnowledgeForTask(options: GetKnowledgeForTaskOptions): Promise<string_parameter_value & string_markdown>;
27
+ export {};
@@ -0,0 +1,30 @@
1
+ import type { ReadonlyDeep } from 'type-fest';
2
+ import type { PipelineJson } from '../../pipeline/PipelineJson/PipelineJson';
3
+ import type { TaskJson } from '../../pipeline/PipelineJson/TaskJson';
4
+ import type { ReservedParameters } from '../../types/typeAliases';
5
+ /**
6
+ * @@@
7
+ *
8
+ * @private internal type of `getReservedParametersForTask`
9
+ */
10
+ type GetReservedParametersForTaskOptions = {
11
+ /**
12
+ * @@@
13
+ */
14
+ readonly preparedPipeline: ReadonlyDeep<PipelineJson>;
15
+ /**
16
+ * @@@
17
+ */
18
+ readonly task: ReadonlyDeep<TaskJson>;
19
+ /**
20
+ * @@@
21
+ */
22
+ readonly pipelineIdentification: string;
23
+ };
24
+ /**
25
+ * @@@
26
+ *
27
+ * @private internal utility of `createPipelineExecutor`
28
+ */
29
+ export declare function getReservedParametersForTask(options: GetReservedParametersForTaskOptions): Promise<Readonly<ReservedParameters>>;
30
+ export {};
@@ -1,6 +1,6 @@
1
1
  import type { ErrorJson } from '../../errors/utils/ErrorJson';
2
- import type { PromptResult } from '../../execution/PromptResult';
3
- import type { Prompt } from '../Prompt';
2
+ import type { Prompt } from '../../types/Prompt';
3
+ import type { PromptResult } from '../PromptResult';
4
4
  /**
5
5
  * Report of single prompt execution
6
6
  *
@@ -1,6 +1,6 @@
1
- import type { string_markdown_text } from '../typeAliases';
2
- import type { string_pipeline_url } from '../typeAliases';
3
- import type { string_semantic_version } from '../typeAliases';
1
+ import type { string_markdown_text } from '../../types/typeAliases';
2
+ import type { string_pipeline_url } from '../../types/typeAliases';
3
+ import type { string_semantic_version } from '../../types/typeAliases';
4
4
  import type { ExecutionPromptReportJson } from './ExecutionPromptReportJson';
5
5
  /**
6
6
  * ExecutionReport is result of executing one promptbook
@@ -35,7 +35,7 @@ export type ExecutionReportJson = {
35
35
  */
36
36
  readonly description?: string_markdown_text;
37
37
  /**
38
- * Sequence of templates in order which were executed
38
+ * Sequence of tasks in order which were executed
39
39
  */
40
40
  readonly promptExecutions: ReadonlyArray<ExecutionPromptReportJson>;
41
41
  };
@@ -1,4 +1,4 @@
1
- import type { number_percent } from '../typeAliases';
1
+ import type { number_percent } from '../../types/typeAliases';
2
2
  /**
3
3
  * Options for `executionReportJsonToString`
4
4
  *
@@ -1,4 +1,4 @@
1
- import type { Expectations } from '../../types/PipelineJson/Expectations';
1
+ import type { Expectations } from '../../pipeline/PipelineJson/Expectations';
2
2
  /**
3
3
  * Function checkExpectations will check if the expectations on given value are met
4
4
  *
@@ -125,3 +125,6 @@ export declare const UNCERTAIN_USAGE: import("type-fest/source/readonly-deep").R
125
125
  };
126
126
  };
127
127
  }>;
128
+ /**
129
+ * Note: [💞] Ignore a discrepancy between file name and entity name
130
+ */
@@ -4,3 +4,6 @@
4
4
  * @private internal index of `...` <- TODO [🏢]
5
5
  */
6
6
  export declare const FORMAT_DEFINITIONS: readonly [import("./_common/FormatDefinition").FormatDefinition<string, string, any, any>, import("./_common/FormatDefinition").FormatDefinition<string, string, any, any>, import("./_common/FormatDefinition").FormatDefinition<string, string, any, any>, import("./_common/FormatDefinition").FormatDefinition<string, string, import("./csv/CsvSettings").CsvSettings, any>];
7
+ /**
8
+ * Note: [💞] Ignore a discrepancy between file name and entity name
9
+ */
@@ -1,10 +1,13 @@
1
- import type { PipelineInterface } from '../../pipeline/pipeline-interface/PipelineInterface';
1
+ import type { PipelineInterface } from '../../pipeline/PipelineInterface/PipelineInterface';
2
2
  import type { string_markdown_text } from '../../types/typeAliases';
3
3
  import type { string_name } from '../../types/typeAliases';
4
4
  import type { string_promptbook_documentation_url } from '../../types/typeAliases';
5
5
  import type { string_SCREAMING_CASE } from '../../utils/normalization/normalizeTo_SCREAMING_CASE';
6
6
  /**
7
7
  * @@@
8
+ *
9
+ * Note: [🚉] This is fully serializable as JSON
10
+ * @see https://github.com/webgptorg/promptbook/discussions/172
8
11
  */
9
12
  export type AbstractFormfactorDefinition = {
10
13
  /**
@@ -1,5 +1,8 @@
1
1
  import { FORMFACTOR_DEFINITIONS } from '../index';
2
2
  /**
3
3
  * @@@
4
+ *
5
+ * Note: [🚉] This is fully serializable as JSON
6
+ * @see https://github.com/webgptorg/promptbook/discussions/172
4
7
  */
5
8
  export type FormfactorDefinition = typeof FORMFACTOR_DEFINITIONS[number];
@@ -3,11 +3,11 @@
3
3
  *
4
4
  * @public exported from `@promptbook/core`
5
5
  */
6
- export declare const ChatFormfactorDefinition: {
6
+ export declare const ChatbotFormfactorDefinition: {
7
7
  readonly name: "CHATBOT";
8
8
  readonly aliasNames: readonly ["CHAT"];
9
9
  readonly description: "@@@";
10
- readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/@@";
10
+ readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/174";
11
11
  readonly pipelineInterface: {
12
12
  readonly inputParameterNames: readonly ["previousTitle", "previousConversationSummary", "userMessage"];
13
13
  readonly outputParameterNames: readonly ["title", "conversationSummary", "chatbotResponse"];
@@ -6,7 +6,7 @@
6
6
  export declare const GenericFormfactorDefinition: {
7
7
  readonly name: "GENERIC";
8
8
  readonly description: "@@@";
9
- readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/@@";
9
+ readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/173";
10
10
  readonly pipelineInterface: {
11
11
  readonly inputParameterNames: readonly [];
12
12
  readonly outputParameterNames: readonly [];
@@ -6,7 +6,7 @@
6
6
  export declare const FORMFACTOR_DEFINITIONS: readonly [{
7
7
  readonly name: "GENERIC";
8
8
  readonly description: "@@@";
9
- readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/@@";
9
+ readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/173";
10
10
  readonly pipelineInterface: {
11
11
  readonly inputParameterNames: readonly [];
12
12
  readonly outputParameterNames: readonly [];
@@ -15,7 +15,7 @@ export declare const FORMFACTOR_DEFINITIONS: readonly [{
15
15
  readonly name: "CHATBOT";
16
16
  readonly aliasNames: readonly ["CHAT"];
17
17
  readonly description: "@@@";
18
- readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/@@";
18
+ readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/174";
19
19
  readonly pipelineInterface: {
20
20
  readonly inputParameterNames: readonly ["previousTitle", "previousConversationSummary", "userMessage"];
21
21
  readonly outputParameterNames: readonly ["title", "conversationSummary", "chatbotResponse"];
@@ -23,7 +23,7 @@ export declare const FORMFACTOR_DEFINITIONS: readonly [{
23
23
  }, {
24
24
  readonly name: "TRANSLATOR";
25
25
  readonly description: "@@@";
26
- readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/@@";
26
+ readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/175";
27
27
  readonly pipelineInterface: {
28
28
  readonly inputParameterNames: readonly ["inputMessage"];
29
29
  readonly outputParameterNames: readonly ["outputMessage"];
@@ -31,9 +31,20 @@ export declare const FORMFACTOR_DEFINITIONS: readonly [{
31
31
  }, {
32
32
  readonly name: "SHEETS";
33
33
  readonly description: "@@@";
34
- readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/@@";
34
+ readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/176";
35
35
  readonly pipelineInterface: {
36
36
  readonly inputParameterNames: readonly ["inputSheet"];
37
37
  readonly outputParameterNames: readonly ["outputSheet"];
38
38
  };
39
+ }, {
40
+ readonly name: "EXPERIMENTAL_MATCHER";
41
+ readonly description: "@@@";
42
+ readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/177";
43
+ readonly pipelineInterface: {
44
+ readonly inputParameterNames: readonly [];
45
+ readonly outputParameterNames: readonly [];
46
+ };
39
47
  }];
48
+ /**
49
+ * Note: [💞] Ignore a discrepancy between file name and entity name
50
+ */
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Matcher is form of app that @@@
3
+ *
4
+ * @public exported from `@promptbook/core`
5
+ */
6
+ export declare const MatcherFormfactorDefinition: {
7
+ readonly name: "EXPERIMENTAL_MATCHER";
8
+ readonly description: "@@@";
9
+ readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/177";
10
+ readonly pipelineInterface: {
11
+ readonly inputParameterNames: readonly [];
12
+ readonly outputParameterNames: readonly [];
13
+ };
14
+ };
@@ -6,7 +6,7 @@
6
6
  export declare const SheetsFormfactorDefinition: {
7
7
  readonly name: "SHEETS";
8
8
  readonly description: "@@@";
9
- readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/@@";
9
+ readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/176";
10
10
  readonly pipelineInterface: {
11
11
  readonly inputParameterNames: readonly ["inputSheet"];
12
12
  readonly outputParameterNames: readonly ["outputSheet"];
@@ -6,7 +6,7 @@
6
6
  export declare const TranslatorFormfactorDefinition: {
7
7
  readonly name: "TRANSLATOR";
8
8
  readonly description: "@@@";
9
- readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/@@";
9
+ readonly documentationUrl: "https://github.com/webgptorg/promptbook/discussions/175";
10
10
  readonly pipelineInterface: {
11
11
  readonly inputParameterNames: readonly ["inputMessage"];
12
12
  readonly outputParameterNames: readonly ["outputMessage"];
@@ -20,4 +20,5 @@ export declare const ANTHROPIC_CLAUDE_MODELS: ReadonlyArray<AvailableModel & {
20
20
  * TODO: [🧠] Some mechanism to propagate unsureness
21
21
  * TODO: [🧠][👮‍♀️] Put here more info like description, isVision, trainingDateCutoff, languages, strengths ( Top-level performance, intelligence, fluency, and understanding), contextWindow,...
22
22
  * TODO: [🎰] Some mechanism to auto-update available models
23
+ * Note: [💞] Ignore a discrepancy between file name and entity name
23
24
  */
@@ -8,3 +8,6 @@ import type { Registration } from '../../utils/$Register';
8
8
  * @public exported from `@promptbook/cli`
9
9
  */
10
10
  export declare const _AnthropicClaudeMetadataRegistration: Registration;
11
+ /**
12
+ * Note: [💞] Ignore a discrepancy between file name and entity name
13
+ */
@@ -10,4 +10,5 @@ import type { Registration } from '../../utils/$Register';
10
10
  export declare const _AnthropicClaudeRegistration: Registration;
11
11
  /**
12
12
  * TODO: [🎶] Naming "constructor" vs "creator" vs "factory"
13
+ * Note: [💞] Ignore a discrepancy between file name and entity name
13
14
  */
@@ -8,3 +8,6 @@ import type { Registration } from '../../utils/$Register';
8
8
  * @public exported from `@promptbook/cli`
9
9
  */
10
10
  export declare const _AzureOpenAiMetadataRegistration: Registration;
11
+ /**
12
+ * Note: [💞] Ignore a discrepancy between file name and entity name
13
+ */
@@ -10,4 +10,5 @@ import type { Registration } from '../../utils/$Register';
10
10
  export declare const _AzureOpenAiRegistration: Registration;
11
11
  /**
12
12
  * TODO: [🎶] Naming "constructor" vs "creator" vs "factory"
13
+ * Note: [💞] Ignore a discrepancy between file name and entity name
13
14
  */
@@ -1,4 +1,4 @@
1
- import type { Expectations } from '../../types/PipelineJson/Expectations';
1
+ import type { Expectations } from '../../pipeline/PipelineJson/Expectations';
2
2
  import type { string_postprocessing_function_name } from '../../types/typeAliases';
3
3
  /**
4
4
  * Gets the expectations and creates a fake text that meets the expectations
@@ -27,4 +27,5 @@ export declare const OPENAI_MODELS: ReadonlyArray<AvailableModel & {
27
27
  * TODO: [🍓] Make better
28
28
  * TODO: Change model titles to human eg: "gpt-4-turbo-2024-04-09" -> "GPT-4 Turbo (2024-04-09)"
29
29
  * TODO: [🚸] Not all models are compatible with JSON mode, add this information here and use it
30
+ * Note: [💞] Ignore a discrepancy between file name and entity name
30
31
  */
@@ -17,3 +17,6 @@ export declare const _OpenAiMetadataRegistration: Registration;
17
17
  * @public exported from `@promptbook/cli`
18
18
  */
19
19
  export declare const _OpenAiAssistantMetadataRegistration: Registration;
20
+ /**
21
+ * Note: [💞] Ignore a discrepancy between file name and entity name
22
+ */
@@ -19,4 +19,5 @@ export declare const _OpenAiRegistration: Registration;
19
19
  export declare const _OpenAiAssistantRegistration: Registration;
20
20
  /**
21
21
  * TODO: [🎶] Naming "constructor" vs "creator" vs "factory"
22
+ * Note: [💞] Ignore a discrepancy between file name and entity name
22
23
  */
@@ -1,6 +1,6 @@
1
1
  import type { ExecutionTools } from '../execution/ExecutionTools';
2
+ import type { PersonaPreparedJson } from '../pipeline/PipelineJson/PersonaJson';
2
3
  import type { PrepareAndScrapeOptions } from '../prepare/PrepareAndScrapeOptions';
3
- import type { PersonaPreparedJson } from '../types/PipelineJson/PersonaJson';
4
4
  import type { string_persona_description } from '../types/typeAliases';
5
5
  /**
6
6
  * Prepares the persona for the pipeline
@@ -1,6 +1,9 @@
1
1
  import type { string_parameter_name } from '../../types/typeAliases';
2
2
  /**
3
3
  * @@@
4
+ *
5
+ * Note: [🚉] This is fully serializable as JSON
6
+ * @see https://github.com/webgptorg/promptbook/discussions/171
4
7
  */
5
8
  export type PipelineInterface = {
6
9
  /**
@@ -1,9 +1,14 @@
1
1
  /**
2
2
  * @@@
3
3
  *
4
+ * @see https://github.com/webgptorg/promptbook/discussions/171
5
+ *
4
6
  * @public exported from `@promptbook/core`
5
7
  */
6
8
  export declare const GENERIC_PIPELINE_INTERFACE: {
7
9
  readonly inputParameterNames: readonly [];
8
10
  readonly outputParameterNames: readonly [];
9
11
  };
12
+ /**
13
+ * Note: [💞] Ignore a discrepancy between file name and entity name
14
+ */
@@ -1,8 +1,10 @@
1
- import type { PipelineJson } from '../../types/PipelineJson/PipelineJson';
1
+ import type { PipelineJson } from '../PipelineJson/PipelineJson';
2
2
  import type { PipelineInterface } from './PipelineInterface';
3
3
  /**
4
4
  * @@@
5
5
  *
6
+ * @see https://github.com/webgptorg/promptbook/discussions/171
7
+ *
6
8
  * @public exported from `@promptbook/core`
7
9
  */
8
10
  export declare function getPipelineInterface(pipeline: PipelineJson): PipelineInterface;
@@ -1,7 +1,9 @@
1
- import type { PipelineJson } from '../../types/PipelineJson/PipelineJson';
1
+ import type { PipelineJson } from '../PipelineJson/PipelineJson';
2
2
  import type { PipelineInterface } from './PipelineInterface';
3
3
  /**
4
4
  * @@@
5
+ *
6
+ * @see https://github.com/webgptorg/promptbook/discussions/171
5
7
  */
6
8
  export type IsPipelineImplementingInterfaceOptions = {
7
9
  /**
@@ -16,6 +18,8 @@ export type IsPipelineImplementingInterfaceOptions = {
16
18
  /**
17
19
  * @@@
18
20
  *
21
+ * @see https://github.com/webgptorg/promptbook/discussions/171
22
+ *
19
23
  * @public exported from `@promptbook/core`
20
24
  */
21
25
  export declare function isPipelineImplementingInterface(options: IsPipelineImplementingInterfaceOptions): boolean;
@@ -2,6 +2,8 @@ import type { PipelineInterface } from './PipelineInterface';
2
2
  /**
3
3
  * @@@
4
4
  *
5
+ * @see https://github.com/webgptorg/promptbook/discussions/171
6
+ *
5
7
  * @public exported from `@promptbook/core`
6
8
  */
7
9
  export declare function isPipelineInterfacesEqual(pipelineInterface1: PipelineInterface, pipelineInterface2: PipelineInterface): boolean;
@@ -0,0 +1,13 @@
1
+ import type { TaskJsonCommon } from './TaskJsonCommon';
2
+ /**
3
+ * Task for prompt to user
4
+ *
5
+ * Note: [🚉] This is fully serializable as JSON
6
+ * @see https://github.com/webgptorg/promptbook/discussions/76
7
+ */
8
+ export type DialogTaskJson = TaskJsonCommon & {
9
+ readonly taskType: 'DIALOG_TASK';
10
+ };
11
+ /**
12
+ * TODO: [🍙] Make some standard order of json properties
13
+ */
@@ -1,6 +1,6 @@
1
1
  import type { TupleToUnion } from 'type-fest';
2
- import type { number_integer } from '../typeAliases';
3
- import type { number_positive } from '../typeAliases';
2
+ import type { number_integer } from '../../types/typeAliases';
3
+ import type { number_positive } from '../../types/typeAliases';
4
4
  /**
5
5
  * Expect this amount of each unit in the answer
6
6
  *
@@ -1,11 +1,11 @@
1
1
  import type { EmbeddingVector } from '../../execution/EmbeddingVector';
2
+ import type { number_id } from '../../types/typeAliases';
3
+ import type { number_linecol_number } from '../../types/typeAliases';
4
+ import type { string_markdown } from '../../types/typeAliases';
5
+ import type { string_markdown_text } from '../../types/typeAliases';
6
+ import type { string_model_name } from '../../types/typeAliases';
7
+ import type { string_name } from '../../types/typeAliases';
2
8
  import type { string_keyword } from '../../utils/normalization/IKeywords';
3
- import type { number_id } from '../typeAliases';
4
- import type { number_linecol_number } from '../typeAliases';
5
- import type { string_markdown } from '../typeAliases';
6
- import type { string_markdown_text } from '../typeAliases';
7
- import type { string_model_name } from '../typeAliases';
8
- import type { string_name } from '../typeAliases';
9
9
  /**
10
10
  * Defines one piece of knowledge in the pipeline
11
11
  *
@@ -69,4 +69,5 @@ export type KnowledgePiecePreparedJson = {
69
69
  };
70
70
  /**
71
71
  * TODO: [🍙] Make some standard order of json properties
72
+ * Note: [💞] Ignore a discrepancy between file name and entity name
72
73
  */
@@ -1,6 +1,6 @@
1
- import type { number_id } from '../typeAliases';
2
- import type { string_knowledge_source_content } from '../typeAliases';
3
- import type { string_name } from '../typeAliases';
1
+ import type { number_id } from '../../types/typeAliases';
2
+ import type { string_knowledge_source_content } from '../../types/typeAliases';
3
+ import type { string_name } from '../../types/typeAliases';
4
4
  /**
5
5
  * Defines one source of knowledge in the pipeline
6
6
  * For example, a source of information, a fact, a quote, a definition, website, etc.
@@ -0,0 +1,96 @@
1
+ import type { string_markdown_text } from '../../types/typeAliases';
2
+ import type { string_parameter_name } from '../../types/typeAliases';
3
+ import type { string_parameter_value } from '../../types/typeAliases';
4
+ /**
5
+ * Describes one parameter of the pipeline
6
+ *
7
+ * Note: [🚉] This is fully serializable as JSON
8
+ */
9
+ export type ParameterJson = InputParameterJson | IntermediateParameterJson | OutputParameterJson;
10
+ /**
11
+ * Describes input parameter of the pipeline
12
+ *
13
+ * 🔴 -> ⚪ -> ⚪
14
+ *
15
+ * Note: [🚉] This is fully serializable as JSON
16
+ */
17
+ export type InputParameterJson = CommonParameterJson & {
18
+ /**
19
+ * The parameter is input of the pipeline
20
+ */
21
+ readonly isInput: true;
22
+ /**
23
+ * The parameter is NOT output of the pipeline
24
+ */
25
+ readonly isOutput: false;
26
+ };
27
+ /**
28
+ * Describes intermediate parameter of the pipeline
29
+ *
30
+ * ⚪ -> 🔴 -> ⚪
31
+ *
32
+ * Note: [🚉] This is fully serializable as JSON
33
+ */
34
+ export type IntermediateParameterJson = CommonParameterJson & {
35
+ /**
36
+ * The parameter is NOT input of the pipeline
37
+ */
38
+ readonly isInput: false;
39
+ /**
40
+ * The parameter is NOT output of the pipeline
41
+ */
42
+ readonly isOutput: false;
43
+ };
44
+ /**
45
+ * Describes output parameter of the pipeline
46
+ *
47
+ * ⚪ -> ⚪ -> 🔴
48
+ *
49
+ * Note: [🚉] This is fully serializable as JSON
50
+ */
51
+ export type OutputParameterJson = CommonParameterJson & {
52
+ /**
53
+ * The parameter is NOT input of the pipeline
54
+ */
55
+ readonly isInput: false;
56
+ /**
57
+ * The parameter is output of the pipeline
58
+ */
59
+ readonly isOutput: true;
60
+ };
61
+ /**
62
+ * Describes commons of one parameter of the pipeline
63
+ *
64
+ * Note: [🚉] This is fully serializable as JSON
65
+ */
66
+ export type CommonParameterJson = {
67
+ /**
68
+ * Name of the parameter
69
+ * - It must be unique across the pipeline
70
+ * - It should start lowercase and contain letters and numbers
71
+ */
72
+ readonly name: string_parameter_name;
73
+ /**
74
+ * The parameter is input of the pipeline
75
+ */
76
+ readonly isInput: boolean;
77
+ /**
78
+ * The parameter is output of the pipeline
79
+ */
80
+ readonly isOutput: boolean;
81
+ /**
82
+ * Description of the parameter
83
+ * - It can use simple markdown formatting like **bold**, *italic*, [link](https://example.com), ... BUT not code blocks and structure
84
+ */
85
+ readonly description?: string_markdown_text;
86
+ /**
87
+ * Example values of the parameter
88
+ * Note: This values won't be actually used as some default values, but they are just for better understanding of the parameter
89
+ */
90
+ readonly exampleValues?: Array<string_parameter_value>;
91
+ };
92
+ /**
93
+ * TODO: [🧠] Should be here registered subparameters from foreach or not?
94
+ * TODO: [♈] Probbably move expectations from tasks to parameters
95
+ * TODO: [🍙] Make some standard order of json properties
96
+ */