@promptbook/wizard 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 +7 -2
- package/esm/index.es.js.map +1 -1
- package/esm/typings/src/book-2.0/agent-source/createAgentModelRequirementsWithCommitments.closed.test.d.ts +1 -0
- package/esm/typings/src/book-2.0/utils/generatePlaceholderAgentProfileImageUrl.d.ts +2 -2
- package/esm/typings/src/collection/agent-collection/constructors/agent-collection-in-supabase/AgentCollectionInSupabase.d.ts +10 -6
- package/esm/typings/src/collection/agent-collection/constructors/agent-collection-in-supabase/AgentsDatabaseSchema.d.ts +6 -3
- package/esm/typings/src/utils/color/utils/colorToDataUrl.d.ts +2 -1
- package/esm/typings/src/version.d.ts +1 -1
- package/package.json +2 -2
- package/umd/index.umd.js +7 -2
- package/umd/index.umd.js.map +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -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
|
-
|
|
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(
|
|
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(
|
|
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(
|
|
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(
|
|
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: '
|
|
102
|
-
columns: ['
|
|
104
|
+
foreignKeyName: 'AgentHistory_permanentId_fkey';
|
|
105
|
+
columns: ['permanentId'];
|
|
103
106
|
referencedRelation: 'Agent';
|
|
104
|
-
referencedColumns: ['
|
|
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):
|
|
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-
|
|
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/wizard",
|
|
3
|
-
"version": "0.104.0-
|
|
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,
|
|
@@ -95,7 +95,7 @@
|
|
|
95
95
|
"module": "./esm/index.es.js",
|
|
96
96
|
"typings": "./esm/typings/src/_packages/wizard.index.d.ts",
|
|
97
97
|
"peerDependencies": {
|
|
98
|
-
"@promptbook/core": "0.104.0-
|
|
98
|
+
"@promptbook/core": "0.104.0-9"
|
|
99
99
|
},
|
|
100
100
|
"dependencies": {
|
|
101
101
|
"@ai-sdk/deepseek": "0.1.17",
|
package/umd/index.umd.js
CHANGED
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
* @generated
|
|
49
49
|
* @see https://github.com/webgptorg/promptbook
|
|
50
50
|
*/
|
|
51
|
-
const PROMPTBOOK_ENGINE_VERSION = '0.104.0-
|
|
51
|
+
const PROMPTBOOK_ENGINE_VERSION = '0.104.0-9';
|
|
52
52
|
/**
|
|
53
53
|
* TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
|
|
54
54
|
* Note: [๐] Ignore a discrepancy between file name and entity name
|
|
@@ -17451,7 +17451,12 @@
|
|
|
17451
17451
|
};
|
|
17452
17452
|
}
|
|
17453
17453
|
// Apply each commitment in order using reduce-like pattern
|
|
17454
|
-
for (
|
|
17454
|
+
for (let i = 0; i < filteredCommitments.length; i++) {
|
|
17455
|
+
const commitment = filteredCommitments[i];
|
|
17456
|
+
// CLOSED commitment should work only if its the last commitment in the book
|
|
17457
|
+
if (commitment.type === 'CLOSED' && i !== filteredCommitments.length - 1) {
|
|
17458
|
+
continue;
|
|
17459
|
+
}
|
|
17455
17460
|
const definition = getCommitmentDefinition(commitment.type);
|
|
17456
17461
|
if (definition) {
|
|
17457
17462
|
try {
|