@promptbook/browser 0.103.0-47 → 0.103.0-49

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 (55) hide show
  1. package/esm/index.es.js +2193 -1882
  2. package/esm/index.es.js.map +1 -1
  3. package/esm/typings/servers.d.ts +1 -0
  4. package/esm/typings/src/_packages/core.index.d.ts +6 -0
  5. package/esm/typings/src/_packages/types.index.d.ts +4 -0
  6. package/esm/typings/src/_packages/utils.index.d.ts +2 -0
  7. package/esm/typings/src/book-2.0/agent-source/AgentBasicInformation.d.ts +17 -3
  8. package/esm/typings/src/book-2.0/agent-source/AgentSourceParseResult.d.ts +2 -1
  9. package/esm/typings/src/book-2.0/agent-source/computeAgentHash.d.ts +8 -0
  10. package/esm/typings/src/book-2.0/agent-source/computeAgentHash.test.d.ts +1 -0
  11. package/esm/typings/src/book-2.0/agent-source/createDefaultAgentName.d.ts +8 -0
  12. package/esm/typings/src/book-2.0/agent-source/normalizeAgentName.d.ts +9 -0
  13. package/esm/typings/src/book-2.0/agent-source/normalizeAgentName.test.d.ts +1 -0
  14. package/esm/typings/src/book-2.0/agent-source/parseAgentSourceWithCommitments.d.ts +1 -1
  15. package/esm/typings/src/collection/agent-collection/constructors/agent-collection-in-supabase/AgentCollectionInSupabase.d.ts +14 -8
  16. package/esm/typings/src/collection/agent-collection/constructors/agent-collection-in-supabase/AgentCollectionInSupabaseOptions.d.ts +10 -0
  17. package/esm/typings/src/collection/agent-collection/constructors/agent-collection-in-supabase/AgentsDatabaseSchema.d.ts +57 -32
  18. package/esm/typings/src/commitments/MESSAGE/InitialMessageCommitmentDefinition.d.ts +28 -0
  19. package/esm/typings/src/commitments/index.d.ts +2 -1
  20. package/esm/typings/src/config.d.ts +1 -0
  21. package/esm/typings/src/errors/DatabaseError.d.ts +2 -2
  22. package/esm/typings/src/errors/WrappedError.d.ts +2 -2
  23. package/esm/typings/src/execution/ExecutionTask.d.ts +2 -2
  24. package/esm/typings/src/execution/LlmExecutionTools.d.ts +6 -1
  25. package/esm/typings/src/llm-providers/_common/register/$provideLlmToolsForWizardOrCli.d.ts +2 -2
  26. package/esm/typings/src/llm-providers/_common/utils/assertUniqueModels.d.ts +12 -0
  27. package/esm/typings/src/llm-providers/agent/Agent.d.ts +17 -4
  28. package/esm/typings/src/llm-providers/agent/AgentLlmExecutionTools.d.ts +10 -1
  29. package/esm/typings/src/llm-providers/agent/RemoteAgent.d.ts +6 -2
  30. package/esm/typings/src/llm-providers/openai/OpenAiAssistantExecutionTools.d.ts +30 -4
  31. package/esm/typings/src/llm-providers/openai/openai-models.test.d.ts +4 -0
  32. package/esm/typings/src/remote-server/startAgentServer.d.ts +2 -2
  33. package/esm/typings/src/remote-server/startRemoteServer.d.ts +1 -2
  34. package/esm/typings/src/transpilers/openai-sdk/register.d.ts +1 -1
  35. package/esm/typings/src/types/typeAliases.d.ts +6 -0
  36. package/esm/typings/src/utils/color/Color.d.ts +7 -0
  37. package/esm/typings/src/utils/color/Color.test.d.ts +1 -0
  38. package/esm/typings/src/utils/environment/$getGlobalScope.d.ts +2 -2
  39. package/esm/typings/src/utils/misc/computeHash.d.ts +11 -0
  40. package/esm/typings/src/utils/misc/computeHash.test.d.ts +1 -0
  41. package/esm/typings/src/utils/normalization/normalize-to-kebab-case.d.ts +2 -0
  42. package/esm/typings/src/utils/normalization/normalizeTo_PascalCase.d.ts +3 -0
  43. package/esm/typings/src/utils/normalization/normalizeTo_camelCase.d.ts +2 -0
  44. package/esm/typings/src/utils/normalization/titleToName.d.ts +2 -0
  45. package/esm/typings/src/utils/organization/$sideEffect.d.ts +2 -2
  46. package/esm/typings/src/utils/organization/$side_effect.d.ts +2 -2
  47. package/esm/typings/src/utils/organization/TODO_USE.d.ts +2 -2
  48. package/esm/typings/src/utils/organization/keepUnused.d.ts +2 -2
  49. package/esm/typings/src/utils/organization/preserve.d.ts +3 -3
  50. package/esm/typings/src/utils/organization/really_any.d.ts +7 -0
  51. package/esm/typings/src/utils/serialization/asSerializable.d.ts +2 -2
  52. package/esm/typings/src/version.d.ts +1 -1
  53. package/package.json +3 -2
  54. package/umd/index.umd.js +2196 -1886
  55. package/umd/index.umd.js.map +1 -1
@@ -9,6 +9,8 @@ export type string_kebab_case = string;
9
9
  /**
10
10
  * Converts a given text to kebab-case format.
11
11
  *
12
+ * Note: [🔂] This function is idempotent.
13
+ *
12
14
  * @param text The text to be converted.
13
15
  * @returns The kebab-case formatted string.
14
16
  * @example 'hello-world'
@@ -7,6 +7,9 @@
7
7
  */
8
8
  export type string_PascalCase = string;
9
9
  /**
10
+ * Normalizes a given text to PascalCase format.
11
+ *
12
+ * Note: [🔂] This function is idempotent.
10
13
  *
11
14
  * @param text @public exported from `@promptbook/utils`
12
15
  * @returns
@@ -9,6 +9,8 @@ export type string_camelCase = string;
9
9
  /**
10
10
  * Normalizes a given text to camelCase format.
11
11
  *
12
+ * Note: [🔂] This function is idempotent.
13
+ *
12
14
  * @param text The text to be normalized.
13
15
  * @param _isFirstLetterCapital Whether the first letter should be capitalized.
14
16
  * @returns The camelCase formatted string.
@@ -1,6 +1,8 @@
1
1
  /**
2
2
  * Converts a title string into a normalized name.
3
3
  *
4
+ * Note: [🔂] This function is idempotent.
5
+ *
4
6
  * @param value The title string to be converted to a name.
5
7
  * @returns A normalized name derived from the input title.
6
8
  * @example 'Hello World!' -> 'hello-world'
@@ -1,4 +1,4 @@
1
- import type { really_any } from './really_any';
1
+ import type { chococake } from './really_any';
2
2
  /**
3
3
  * Just says that the variable is not used directlys but should be kept because the existence of the variable is important
4
4
  *
@@ -6,4 +6,4 @@ import type { really_any } from './really_any';
6
6
  * @returns void
7
7
  * @private within the repository
8
8
  */
9
- export declare function $sideEffect(...sideEffectSubjects: ReadonlyArray<really_any>): void;
9
+ export declare function $sideEffect(...sideEffectSubjects: ReadonlyArray<chococake>): void;
@@ -1,7 +1,7 @@
1
- import type { really_any } from './really_any';
1
+ import type { chococake } from './really_any';
2
2
  /**
3
3
  * Organizational helper to mark a function that produces side effects
4
4
  *
5
5
  * @private within the repository
6
6
  */
7
- export type $side_effect = void | really_any;
7
+ export type $side_effect = void | chococake;
@@ -1,4 +1,4 @@
1
- import type { really_any } from './really_any';
1
+ import type { chococake } from './really_any';
2
2
  /**
3
3
  * Just marks a place of place where should be something implemented
4
4
  * No side effects.
@@ -9,4 +9,4 @@ import type { really_any } from './really_any';
9
9
  * @returns void
10
10
  * @private within the repository
11
11
  */
12
- export declare function TODO_USE(...value: ReadonlyArray<really_any>): void;
12
+ export declare function TODO_USE(...value: ReadonlyArray<chococake>): void;
@@ -1,4 +1,4 @@
1
- import type { really_any } from './really_any';
1
+ import type { chococake } from './really_any';
2
2
  /**
3
3
  * Just says that the variable is not used but should be kept
4
4
  * No side effects.
@@ -13,4 +13,4 @@ import type { really_any } from './really_any';
13
13
  * @returns void
14
14
  * @private within the repository
15
15
  */
16
- export declare function keepUnused<TTypeToKeep1 = really_any, TTypeToKeep2 = really_any, TTypeToKeep3 = really_any>(...valuesToKeep: ReadonlyArray<really_any>): void;
16
+ export declare function keepUnused<TTypeToKeep1 = chococake, TTypeToKeep2 = chococake, TTypeToKeep3 = chococake>(...valuesToKeep: ReadonlyArray<chococake>): void;
@@ -1,4 +1,4 @@
1
- import type { really_any } from './really_any';
1
+ import type { chococake } from './really_any';
2
2
  /**
3
3
  * Does nothing, but preserves the function in the bundle
4
4
  * Compiler is tricked into thinking the function is used
@@ -7,7 +7,7 @@ import type { really_any } from './really_any';
7
7
  * @returns nothing
8
8
  * @private within the repository
9
9
  */
10
- export declare function $preserve(...value: Array<really_any>): void;
10
+ export declare function $preserve(...value: Array<chococake>): void;
11
11
  /**
12
12
  * DO NOT USE THIS FUNCTION
13
13
  * Only purpose of this function is to trick the compiler and javascript engine
@@ -15,7 +15,7 @@ export declare function $preserve(...value: Array<really_any>): void;
15
15
  *
16
16
  * @private internal for `preserve`
17
17
  */
18
- export declare function __DO_NOT_USE_getPreserved(): Array<really_any>;
18
+ export declare function __DO_NOT_USE_getPreserved(): Array<chococake>;
19
19
  /**
20
20
  * Note: [💞] Ignore a discrepancy between file name and entity name
21
21
  */
@@ -1,3 +1,10 @@
1
+ /**
2
+ * Organizational helper to tell to use intentionally `any`
3
+ *
4
+ * @alias really_any
5
+ * @private within the repository
6
+ */
7
+ export type chococake = really_any;
1
8
  /**
2
9
  * Organizational helper to mark a place where to really use `any`
3
10
  *
@@ -1,4 +1,4 @@
1
- import type { really_any } from '../organization/really_any';
1
+ import type { chococake } from '../organization/really_any';
2
2
  /**
3
3
  * Function `asSerializable` will convert values which are not serializable to serializable values
4
4
  * It walks deeply through the object and converts all values
@@ -12,4 +12,4 @@ import type { really_any } from '../organization/really_any';
12
12
  *
13
13
  * @private Internal helper function
14
14
  */
15
- export declare function asSerializable(value: really_any): really_any;
15
+ export declare function asSerializable(value: chococake): chococake;
@@ -15,7 +15,7 @@ export declare const BOOK_LANGUAGE_VERSION: string_semantic_version;
15
15
  export declare const PROMPTBOOK_ENGINE_VERSION: string_promptbook_version;
16
16
  /**
17
17
  * Represents the version string of the Promptbook engine.
18
- * It follows semantic versioning (e.g., `0.103.0-46`).
18
+ * It follows semantic versioning (e.g., `0.103.0-48`).
19
19
  *
20
20
  * @generated
21
21
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@promptbook/browser",
3
- "version": "0.103.0-47",
3
+ "version": "0.103.0-49",
4
4
  "description": "Promptbook: Turn your company's scattered knowledge into AI ready books",
5
5
  "private": false,
6
6
  "sideEffects": false,
@@ -94,10 +94,11 @@
94
94
  "module": "./esm/index.es.js",
95
95
  "typings": "./esm/typings/src/_packages/browser.index.d.ts",
96
96
  "peerDependencies": {
97
- "@promptbook/core": "0.103.0-47"
97
+ "@promptbook/core": "0.103.0-49"
98
98
  },
99
99
  "dependencies": {
100
100
  "crypto": "1.0.1",
101
+ "crypto-js": "4.2.0",
101
102
  "destroyable": "0.12.141",
102
103
  "spacetrim": "0.11.60",
103
104
  "type-fest": "4.5.0"