@promptbook/fake-llm 0.104.0-7 โ†’ 0.104.0-9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/esm/index.es.js CHANGED
@@ -20,7 +20,7 @@ const BOOK_LANGUAGE_VERSION = '2.0.0';
20
20
  * @generated
21
21
  * @see https://github.com/webgptorg/promptbook
22
22
  */
23
- const PROMPTBOOK_ENGINE_VERSION = '0.104.0-7';
23
+ const PROMPTBOOK_ENGINE_VERSION = '0.104.0-9';
24
24
  /**
25
25
  * TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
26
26
  * Note: [๐Ÿ’ž] Ignore a discrepancy between file name and entity name
@@ -1,4 +1,4 @@
1
- import type { string_agent_name, string_agent_permanent_id, string_url_image } from '../../types/typeAliases';
1
+ import type { string_agent_name, string_agent_permanent_id, string_url, string_url_image } from '../../types/typeAliases';
2
2
  /**
3
3
  * Generates an image for the agent to use as profile image
4
4
  *
@@ -7,7 +7,7 @@ import type { string_agent_name, string_agent_permanent_id, string_url_image } f
7
7
  *
8
8
  * @public exported from `@promptbook/core`
9
9
  */
10
- export declare function generatePlaceholderAgentProfileImageUrl(agentIdOrName: string_agent_permanent_id | string_agent_name, agentsServerUrl?: URL): string_url_image;
10
+ export declare function generatePlaceholderAgentProfileImageUrl(agentIdOrName: string_agent_permanent_id | string_agent_name, agentsServerUrl?: URL | string_url): string_url_image;
11
11
  /**
12
12
  * TODO: [๐Ÿคน] Figure out best placeholder image generator https://i.pravatar.cc/1000?u=568
13
13
  */
@@ -1,7 +1,7 @@
1
1
  import type { SupabaseClient } from '@supabase/supabase-js';
2
2
  import type { AgentBasicInformation } from '../../../../book-2.0/agent-source/AgentBasicInformation';
3
3
  import type { string_book } from '../../../../book-2.0/agent-source/string_book';
4
- import type { string_agent_name } from '../../../../types/typeAliases';
4
+ import type { string_agent_name, string_agent_permanent_id } from '../../../../types/typeAliases';
5
5
  import { AgentCollectionInSupabaseOptions } from './AgentCollectionInSupabaseOptions';
6
6
  import type { AgentsDatabaseSchema } from './AgentsDatabaseSchema';
7
7
  /**
@@ -28,7 +28,11 @@ export declare class AgentCollectionInSupabase {
28
28
  /**
29
29
  * [๐Ÿฑโ€๐Ÿš€]@@@
30
30
  */
31
- getAgentSource(agentName: string_agent_name): Promise<string_book>;
31
+ getAgentPermanentId(agentNameOrPermanentId: string_agent_name | string_agent_permanent_id): Promise<string_agent_permanent_id>;
32
+ /**
33
+ * [๐Ÿฑโ€๐Ÿš€]@@@
34
+ */
35
+ getAgentSource(agentNameOrPermanentId: string_agent_name | string_agent_permanent_id): Promise<string_book>;
32
36
  /**
33
37
  * Creates a new agent in the collection
34
38
  *
@@ -38,7 +42,7 @@ export declare class AgentCollectionInSupabase {
38
42
  /**
39
43
  * Updates an existing agent in the collection
40
44
  */
41
- updateAgentSource(agentName: string_agent_name, agentSource: string_book): Promise<void>;
45
+ updateAgentSource(permanentId: string_agent_permanent_id, agentSource: string_book): Promise<void>;
42
46
  /**
43
47
  * List agents that are soft deleted (deletedAt IS NOT NULL)
44
48
  */
@@ -46,7 +50,7 @@ export declare class AgentCollectionInSupabase {
46
50
  /**
47
51
  * List history of an agent
48
52
  */
49
- listAgentHistory(agentName: string_agent_name): Promise<ReadonlyArray<{
53
+ listAgentHistory(permanentId: string_agent_permanent_id): Promise<ReadonlyArray<{
50
54
  id: number;
51
55
  createdAt: string;
52
56
  agentHash: string;
@@ -55,7 +59,7 @@ export declare class AgentCollectionInSupabase {
55
59
  /**
56
60
  * Restore a soft-deleted agent by setting deletedAt to NULL
57
61
  */
58
- restoreAgent(agentIdentifier: string): Promise<void>;
62
+ restoreAgent(permanentId: string_agent_permanent_id): Promise<void>;
59
63
  /**
60
64
  * Restore an agent from a specific history entry
61
65
  *
@@ -65,7 +69,7 @@ export declare class AgentCollectionInSupabase {
65
69
  /**
66
70
  * Soft delete an agent by setting deletedAt to current timestamp
67
71
  */
68
- deleteAgent(agentIdentifier: string): Promise<void>;
72
+ deleteAgent(permanentId: string_agent_permanent_id): Promise<void>;
69
73
  /**
70
74
  * Get the Supabase table name with prefix
71
75
  *
@@ -73,6 +73,7 @@ export type AgentsDatabaseSchema = {
73
73
  id: number;
74
74
  createdAt: string;
75
75
  agentName: string;
76
+ permanentId: string;
76
77
  agentHash: string;
77
78
  previousAgentHash: string | null;
78
79
  agentSource: string;
@@ -82,6 +83,7 @@ export type AgentsDatabaseSchema = {
82
83
  id?: number;
83
84
  createdAt: string;
84
85
  agentName: string;
86
+ permanentId: string;
85
87
  agentHash: string;
86
88
  previousAgentHash?: string | null;
87
89
  agentSource: string;
@@ -91,6 +93,7 @@ export type AgentsDatabaseSchema = {
91
93
  id?: number;
92
94
  createdAt?: string;
93
95
  agentName?: string;
96
+ permanentId?: string;
94
97
  agentHash?: string;
95
98
  previousAgentHash?: string | null;
96
99
  agentSource?: string;
@@ -98,10 +101,10 @@ export type AgentsDatabaseSchema = {
98
101
  };
99
102
  Relationships: [
100
103
  {
101
- foreignKeyName: 'AgentHistory_agentName_fkey';
102
- columns: ['agentName'];
104
+ foreignKeyName: 'AgentHistory_permanentId_fkey';
105
+ columns: ['permanentId'];
103
106
  referencedRelation: 'Agent';
104
- referencedColumns: ['agentName'];
107
+ referencedColumns: ['permanentId'];
105
108
  }
106
109
  ];
107
110
  };
@@ -1,10 +1,11 @@
1
+ import { string_color, string_data_url, string_url_image } from '../../../types/typeAliases';
1
2
  import { Color } from '../Color';
2
3
  /**
3
4
  * Makes data url from color
4
5
  *
5
6
  * @public exported from `@promptbook/color`
6
7
  */
7
- export declare function colorToDataUrl(color: Color): string;
8
+ export declare function colorToDataUrl(color: Color | string_color): string_data_url & string_url_image;
8
9
  /**
9
10
  * TODO: Make as functions NOT const
10
11
  */
@@ -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.104.0-6`).
18
+ * It follows semantic versioning (e.g., `0.104.0-8`).
19
19
  *
20
20
  * @generated
21
21
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@promptbook/fake-llm",
3
- "version": "0.104.0-7",
3
+ "version": "0.104.0-9",
4
4
  "description": "Promptbook: Turn your company's scattered knowledge into AI ready books",
5
5
  "private": false,
6
6
  "sideEffects": false,
@@ -96,7 +96,7 @@
96
96
  "module": "./esm/index.es.js",
97
97
  "typings": "./esm/typings/src/_packages/fake-llm.index.d.ts",
98
98
  "peerDependencies": {
99
- "@promptbook/core": "0.104.0-7"
99
+ "@promptbook/core": "0.104.0-9"
100
100
  },
101
101
  "dependencies": {
102
102
  "crypto": "1.0.1",
package/umd/index.umd.js CHANGED
@@ -22,7 +22,7 @@
22
22
  * @generated
23
23
  * @see https://github.com/webgptorg/promptbook
24
24
  */
25
- const PROMPTBOOK_ENGINE_VERSION = '0.104.0-7';
25
+ const PROMPTBOOK_ENGINE_VERSION = '0.104.0-9';
26
26
  /**
27
27
  * TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
28
28
  * Note: [๐Ÿ’ž] Ignore a discrepancy between file name and entity name