@promptbook/remote-client 0.46.0-0 → 0.46.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 (2) hide show
  1. package/README.md +20 -91
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -2,15 +2,15 @@
2
2
 
3
3
  Library to supercharge your use of large language models
4
4
 
5
- <!--Badges-->
6
- <!--⚠️WARNING: This section was generated by https://github.com/hejny/batch-project-editor/blob/main/src/workflows/800-badges/badges.ts so every manual change will be overwritten.-->
5
+
6
+
7
7
 
8
8
  [![License of 📖 Prompt book](https://img.shields.io/github/license/webgptorg/promptbook.svg?style=flat)](https://github.com/webgptorg/promptbook/blob/main/LICENSE)
9
9
  [![Known Vulnerabilities](https://snyk.io/test/github/webgptorg/promptbook/badge.svg)](https://snyk.io/test/github/webgptorg/promptbook)
10
10
  [![Issues](https://img.shields.io/github/issues/webgptorg/promptbook.svg?style=flat)](https://github.com/webgptorg/promptbook/issues)
11
11
  [![Socket Badge](https://socket.dev/api/badge/npm/package/@promptbook/remote-client)](https://socket.dev/npm/package/@promptbook/remote-client)
12
12
 
13
- <!--/Badges-->
13
+
14
14
 
15
15
  ## 📦 Package `@promptbook/remote-client`
16
16
 
@@ -23,16 +23,13 @@ To install this package, run:
23
23
  npm i @promptbook/remote-client
24
24
  ```
25
25
 
26
- <!-- TODO: Sample of use + interlink server and client -->
26
+
27
27
 
28
28
  ---
29
29
 
30
30
  Rest of the documentation is common for **entire promptbook ecosystem**:
31
31
 
32
- <!--
33
- TODO: Probbably remove this section only in packages
34
- > ⚠ Warning: This library is still in early development.
35
- -->
32
+
36
33
 
37
34
  ## 🤍 Whitepaper
38
35
 
@@ -75,13 +72,13 @@ In any of these situations, but especially in (3), the Promptbook library can ma
75
72
  - Multiple promptbooks forms a library which will become a **part of your application codebase**.
76
73
  - Theese promptbooks are designed such as they **can be written by non-programmers**.
77
74
 
78
- <!-- TODO: [🧠] Make some more clear escaping -->
75
+
79
76
 
80
77
  ### Sample:
81
78
 
82
79
  File `write-website-content.ptbk.md`:
83
80
 
84
- <!------------------------[ Sample: ]------------------------>
81
+
85
82
 
86
83
  > # 🌍 Create website content
87
84
  >
@@ -252,7 +249,7 @@ File `write-website-content.ptbk.md`:
252
249
  >
253
250
  > `-> {content}`
254
251
 
255
- <!------------------------[ /Sample ]------------------------>
252
+
256
253
 
257
254
  Following is the scheme how the promptbook above is executed:
258
255
 
@@ -314,10 +311,12 @@ npm i ptbk
314
311
 
315
312
  Or you can install them separately:
316
313
 
317
- <!--[🔠]-->
314
+ > ⭐ Marked packages are worth to try first
318
315
 
319
- <!-- Add all new -->
320
316
 
317
+
318
+ - ⭐ **[ptbk](https://www.npmjs.com/package/ptbk)** - Bundle of all packages, when you want to install everything and you don't care about the size
319
+ - **[promptbook](https://www.npmjs.com/package/promptbook)** - Same as `ptbk`
321
320
  - **[@promptbook/core](https://www.npmjs.com/package/@promptbook/core)** - Core of the library, it contains the main logic for promptbooks
322
321
  - ⭐ **[@promptbook/utils](https://www.npmjs.com/package/@promptbook/utils)** - Utility functions used in the library but also useful for individual use in preprocessing and postprocessing LLM inputs and outputs
323
322
  - _(Not finished)_ **[@promptbook/wizzard](https://www.npmjs.com/package/@promptbook/wizzard)** - Wizard for creating+running promptbooks in single line
@@ -496,7 +495,7 @@ There are [postprocessing functions](#postprocessing-functions) that can be used
496
495
 
497
496
  - _(Not implemented yet)_ `ConsoleInterfaceTools` is a wrapper around `readline` module that interacts with the user via console.
498
497
  - `SimplePromptInterfaceTools` is a wrapper around `window.prompt` synchronous function that interacts with the user via browser prompt. It is used for testing and mocking **NOT intended to use in the production** due to its synchronous nature.
499
- - `CallbackInterfaceTools` delagates the user interaction to a async callback function. You need to provide your own implementation of this callback function and its bind to UI. <!-- <- TODO: Provide here a way how to do it with some our plugin -->
498
+ - `CallbackInterfaceTools` delagates the user interaction to a async callback function. You need to provide your own implementation of this callback function and its bind to UI.
500
499
 
501
500
  ### Executor
502
501
 
@@ -566,10 +565,7 @@ There are two types of expectations which are not strictly symmetrical:
566
565
 
567
566
  Look at [expectations.ptbk.md](samples/templates/45-expectations.ptbk.md) and [expect-json.ptbk.md](samples/templates/45-expect-json.ptbk.md) samples for more.
568
567
 
569
- <!--
570
- ### New
571
- [🥻] Insert here when making new command
572
- -->
568
+
573
569
 
574
570
  ### Execution report
575
571
 
@@ -577,7 +573,7 @@ Execution report is a simple object or markdown that contains information about
577
573
 
578
574
  [See the example of such a report](/samples/templates/50-advanced.report.md)
579
575
 
580
- <!-- TODO: Write more -->
576
+
581
577
 
582
578
  ### Remote server
583
579
 
@@ -588,23 +584,7 @@ This is useful to make all logic on browser side but not expose your API keys or
588
584
 
589
585
  ## 👨‍💻 Usage and integration _(for developers)_
590
586
 
591
- <!--
592
-
593
- TODO: [🧙‍♂️]
594
-
595
- ### 🧙‍♂️ Using wizzard
596
-
597
- First you need to install this library:
598
-
599
- ```bash
600
- npm install --save @promptbook/wizzard
601
- ```
602
-
603
- > TODO: !! Write the Wizzard sample
604
-
605
- [Usage samples](./samples/usage/)
606
587
 
607
- -->
608
588
 
609
589
  ### 🔌 Usage in Typescript / Javascript
610
590
 
@@ -629,11 +609,11 @@ npm install --save @promptbook/wizzard
629
609
 
630
610
  ## 🐜 Known issues
631
611
 
632
- <!-- TODO: -->
612
+
633
613
 
634
614
  ## 🧼 Intentionally not implemented features
635
615
 
636
- <!-- TODO: -->
616
+
637
617
 
638
618
  ## ❔ FAQ
639
619
 
@@ -649,42 +629,17 @@ Langchain is primarily aimed at ML developers working in Python. This library is
649
629
 
650
630
  We are considering creating a bridge/converter between these two libraries.
651
631
 
652
- <!--
653
632
 
654
- ==========
655
- Include:
656
- - Langchain is the python library and JavaScript is on second place
657
- - Langchain primarily focused on making templates, not on combining templates into larger structures
658
- - at the language level it distinguishes between chat and completion, I need to mix the two into one template pipeline
659
- - for a non-programmer it's quite hard to work with such a thing and write templates - I would much prefer a system that allows non-technical people to write templates (of which there are many more on the market than free pythonists)
660
- - The focus of promptbooks is primarily on building user applications, not the data processing, training or autogpt.
661
- -->
662
633
 
663
634
  ### Promptbooks vs. OpenAI`s GPTs
664
635
 
665
636
  GPTs are chat assistants that can be assigned to specific tasks and materials. But they are still chat assistants. Promptbooks are a way to orchestrate many more predefined tasks to have much tighter control over the process. Promptbooks are not a good technology for creating human-like chatbots, GPTs are not a good technology for creating outputs with specific requirements.
666
637
 
667
- <!--
668
- TODO:
669
- ### Promptbooks vs. Semantic Kernel
670
-
671
-
672
- -->
673
-
674
- <!--
675
- TODO: !
676
- ### Promptbooks vs. Langtail
677
638
 
678
639
 
679
- -->
680
640
 
681
- <!--
682
- TODO:
683
- ### Promptbooks vs. Evidentally AI
684
641
 
685
- Logging and monitoring
686
642
 
687
- -->
688
643
 
689
644
  ### Where should I store my promptbooks?
690
645
 
@@ -706,33 +661,9 @@ In large language models, you will get better results if you have prompts in the
706
661
 
707
662
  The best way to manage this is to have suffixed promptbooks like `write-website-content.en.ptbk.md` and `write-website-content.cs.ptbk.md` for each supported language.
708
663
 
709
- <!--
710
- TODO: (Maybe)
711
- ### Why you need to explicitly specify input and output parameters?
712
- -->
713
-
714
- <!--
715
-
716
-
717
-
718
- !
719
664
 
720
665
 
721
666
 
722
- unit testing
723
-
724
- escaping
725
-
726
- how i get block into prompt
727
-
728
-
729
- ## 🚷 Limitations
730
-
731
- function calling
732
- system message
733
- iterations
734
-
735
- -->
736
667
 
737
668
  ## ⌚ Changelog
738
669
 
@@ -742,13 +673,11 @@ See [CHANGELOG.md](./CHANGELOG.md)
742
673
 
743
674
  <p xmlns:cc="http://creativecommons.org/ns#" xmlns:dct="http://purl.org/dc/terms/"><a property="dct:title" rel="cc:attributionURL" href="https://github.com/webgptorg/promptbook">Promptbook</a> by <a rel="cc:attributionURL dct:creator" property="cc:attributionName" href="https://github.com/hejny/">Pavol Hejný</a> is licensed under <a href="https://creativecommons.org/licenses/by/4.0/?ref=chooser-v1" target="_blank" rel="license noopener noreferrer" style="display:inline-block;">CC BY 4.0</a></p>
744
675
 
745
- <!--Contributing-->
746
- <!--⚠️WARNING: This section was generated by https://github.com/hejny/batch-project-editor/blob/main/src/workflows/810-contributing/contributing.ts so every manual change will be overwritten.-->
676
+
677
+
747
678
 
748
679
  ## 🖋️ Contributing
749
680
 
750
681
  I am open to pull requests, feedback, and suggestions. Or if you like this utility, you can [☕ buy me a coffee](https://www.buymeacoffee.com/hejny) or [donate via cryptocurrencies](https://github.com/hejny/hejny/blob/main/documents/crypto.md).
751
682
 
752
- You can also ⭐ star the promptbook package, [follow me on GitHub](https://github.com/hejny) or [various other social networks](https://www.pavolhejny.com/contact/).
753
-
754
- <!--/Contributing-->
683
+ You can also ⭐ star the promptbook package, [follow me on GitHub](https://github.com/hejny) or [various other social networks](https://www.pavolhejny.com/contact/).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@promptbook/remote-client",
3
- "version": "0.46.0-0",
3
+ "version": "0.46.0-2",
4
4
  "description": "Library to supercharge your use of large language models",
5
5
  "private": false,
6
6
  "sideEffects": false,
@@ -37,7 +37,7 @@
37
37
  "socket.io-client": "4.7.2"
38
38
  },
39
39
  "peerDependencies": {
40
- "@promptbook/core": "0.46.0-0"
40
+ "@promptbook/core": "0.46.0-2"
41
41
  },
42
42
  "main": "./umd/index.umd.js",
43
43
  "module": "./esm/index.es.js",