@rslsp1/fa-app-tools 2.0.85 → 2.0.87
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/dist/{chunk-LFPOXNOZ.mjs → chunk-NBUS7AWR.mjs} +10 -2
- package/dist/{chunk-MILMVOK7.mjs → chunk-ZVHEHQ7A.mjs} +232 -60
- package/dist/hfEventTypes-C_PX6RFR.d.ts +241 -0
- package/dist/hfEventTypes-Dkfrcd_t.d.mts +241 -0
- package/dist/{hfStateService-PZH2IDKF.mjs → hfStateService-W7KO2FOH.mjs} +1 -1
- package/dist/index.d.mts +4 -172
- package/dist/index.d.ts +4 -172
- package/dist/index.js +170 -68
- package/dist/index.mjs +6 -74
- package/dist/szenen.d.mts +99 -5
- package/dist/szenen.d.ts +99 -5
- package/dist/szenen.js +241 -63
- package/dist/szenen.mjs +8 -2
- package/package.json +1 -1
- package/dist/flowTextGenerationPort-CeDUFutP.d.mts +0 -73
- package/dist/flowTextGenerationPort-KHjCGt_S.d.ts +0 -73
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
import { T as TextGenerationPort } from './contracts-DdYOMBl9.mjs';
|
|
2
|
+
|
|
3
|
+
interface TagOption {
|
|
4
|
+
label: string;
|
|
5
|
+
value: string;
|
|
6
|
+
is_user_created?: boolean;
|
|
7
|
+
is_deleted?: boolean;
|
|
8
|
+
}
|
|
9
|
+
interface WorkspaceTags {
|
|
10
|
+
by_category: Record<string, TagOption[]>;
|
|
11
|
+
all: Array<TagOption & {
|
|
12
|
+
category: string;
|
|
13
|
+
}>;
|
|
14
|
+
}
|
|
15
|
+
interface Generation {
|
|
16
|
+
id: string;
|
|
17
|
+
nodeId: string;
|
|
18
|
+
base64?: string;
|
|
19
|
+
fullBase64?: string;
|
|
20
|
+
mediaId?: string;
|
|
21
|
+
prompt?: string;
|
|
22
|
+
hierarchy?: string;
|
|
23
|
+
seed?: number;
|
|
24
|
+
model?: string;
|
|
25
|
+
timestamp: number;
|
|
26
|
+
status: 'processing' | 'done' | 'error';
|
|
27
|
+
step?: string;
|
|
28
|
+
tags: string[];
|
|
29
|
+
type?: 'generation' | 'import';
|
|
30
|
+
error?: {
|
|
31
|
+
message: string;
|
|
32
|
+
details?: string;
|
|
33
|
+
};
|
|
34
|
+
selectedForExport?: boolean;
|
|
35
|
+
filename?: string;
|
|
36
|
+
hasThumb?: boolean;
|
|
37
|
+
mimeType?: string;
|
|
38
|
+
titleTs?: number;
|
|
39
|
+
}
|
|
40
|
+
interface ProjectSettings {
|
|
41
|
+
aspectRatio: string;
|
|
42
|
+
selectedModel: string;
|
|
43
|
+
seed: number;
|
|
44
|
+
seedMode: 'random' | 'fixed';
|
|
45
|
+
}
|
|
46
|
+
interface ProjectMeta {
|
|
47
|
+
id: string;
|
|
48
|
+
name: string;
|
|
49
|
+
saved_at: string;
|
|
50
|
+
size: number;
|
|
51
|
+
}
|
|
52
|
+
interface SyncDiff {
|
|
53
|
+
localOnly: Generation[];
|
|
54
|
+
serverOnly: Generation[];
|
|
55
|
+
}
|
|
56
|
+
interface LabFrame {
|
|
57
|
+
id: string;
|
|
58
|
+
base64: string;
|
|
59
|
+
mediaId?: string;
|
|
60
|
+
seed?: number;
|
|
61
|
+
model?: string;
|
|
62
|
+
aspectRatio?: string;
|
|
63
|
+
width?: number;
|
|
64
|
+
height?: number;
|
|
65
|
+
source?: 'generated' | 'flow-gallery' | 'zip-import' | 'db-library';
|
|
66
|
+
}
|
|
67
|
+
interface LabItem {
|
|
68
|
+
id: string;
|
|
69
|
+
prompt: string;
|
|
70
|
+
label?: string;
|
|
71
|
+
tags?: string[];
|
|
72
|
+
frames: LabFrame[];
|
|
73
|
+
}
|
|
74
|
+
interface SelectedLabImage {
|
|
75
|
+
item: LabItem;
|
|
76
|
+
frame: LabFrame;
|
|
77
|
+
label: string;
|
|
78
|
+
roleForPrompt?: string;
|
|
79
|
+
roleForImage?: string;
|
|
80
|
+
sendToPromptAI: boolean;
|
|
81
|
+
sendToImageGen: boolean;
|
|
82
|
+
}
|
|
83
|
+
interface LabServices {
|
|
84
|
+
availableItems: LabItem[];
|
|
85
|
+
recentItems: LabItem[];
|
|
86
|
+
onItemUsed: (item: LabItem) => void;
|
|
87
|
+
generateText: (text: string, options?: {
|
|
88
|
+
images?: {
|
|
89
|
+
base64: string;
|
|
90
|
+
mimeType: string;
|
|
91
|
+
}[];
|
|
92
|
+
systemInstruction?: string;
|
|
93
|
+
}) => Promise<string>;
|
|
94
|
+
generateImage: (options: Record<string, any>) => Promise<{
|
|
95
|
+
base64: string;
|
|
96
|
+
mediaId?: string;
|
|
97
|
+
}>;
|
|
98
|
+
saveResult?: (item: LabItem) => Promise<void>;
|
|
99
|
+
workspaceTags?: WorkspaceTags;
|
|
100
|
+
}
|
|
101
|
+
interface HFMetadataEntry {
|
|
102
|
+
id: string;
|
|
103
|
+
prompt?: string;
|
|
104
|
+
seed?: number;
|
|
105
|
+
model?: string;
|
|
106
|
+
tags: string[];
|
|
107
|
+
timestamp: number;
|
|
108
|
+
mimeType: string;
|
|
109
|
+
size?: number;
|
|
110
|
+
filename?: string;
|
|
111
|
+
hasThumb?: boolean;
|
|
112
|
+
titleTs?: number;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
declare function buildGenerationPrompt(hierarchyText: string, mode?: 'literal' | 'creative'): string;
|
|
116
|
+
declare function buildFallbackPrompt(hierarchyText: string): string;
|
|
117
|
+
declare function cleanAiResponse(text: string): string;
|
|
118
|
+
declare function buildImageGenerationOptions(prompt: string, aspectRatio: string, model: string, referenceMediaId?: string): Record<string, any>;
|
|
119
|
+
interface SelectedTag {
|
|
120
|
+
label: string;
|
|
121
|
+
value: string;
|
|
122
|
+
category: string;
|
|
123
|
+
}
|
|
124
|
+
declare function buildPromptTabPayload(selectedTags: SelectedTag[], instructions: string, rules: string, treeText?: string): string;
|
|
125
|
+
declare function parsePromptResponse(raw: string): {
|
|
126
|
+
prompt: string;
|
|
127
|
+
feedback: string | null;
|
|
128
|
+
};
|
|
129
|
+
interface FlowSdkImage {
|
|
130
|
+
base64: string;
|
|
131
|
+
mimeType: string;
|
|
132
|
+
}
|
|
133
|
+
interface FlowTextGenerationOptions {
|
|
134
|
+
images?: FlowSdkImage[];
|
|
135
|
+
systemInstruction?: string;
|
|
136
|
+
responseFormat?: 'text' | 'json';
|
|
137
|
+
thinkingLevel?: 'low' | 'medium' | 'high';
|
|
138
|
+
}
|
|
139
|
+
interface FlowSdk {
|
|
140
|
+
generate: {
|
|
141
|
+
image: (options: Record<string, any>) => Promise<{
|
|
142
|
+
base64: string;
|
|
143
|
+
mediaId: string;
|
|
144
|
+
}>;
|
|
145
|
+
text: (prompt: string, options?: {
|
|
146
|
+
systemInstruction?: string;
|
|
147
|
+
thinkingLevel?: string;
|
|
148
|
+
images?: FlowSdkImage[];
|
|
149
|
+
}) => Promise<{
|
|
150
|
+
text: string;
|
|
151
|
+
}>;
|
|
152
|
+
};
|
|
153
|
+
download: (args: {
|
|
154
|
+
base64: string;
|
|
155
|
+
mimeType: string;
|
|
156
|
+
filename: string;
|
|
157
|
+
}) => Promise<void>;
|
|
158
|
+
media: {
|
|
159
|
+
selectMultiple: (args: {
|
|
160
|
+
filter: string;
|
|
161
|
+
}) => Promise<any[]>;
|
|
162
|
+
};
|
|
163
|
+
}
|
|
164
|
+
declare function createFlowServices(Flow: FlowSdk): {
|
|
165
|
+
generateImage: (options: Record<string, any>) => Promise<{
|
|
166
|
+
base64: string;
|
|
167
|
+
mediaId: string;
|
|
168
|
+
}>;
|
|
169
|
+
generateText: (text: string, options?: FlowTextGenerationOptions) => Promise<string>;
|
|
170
|
+
};
|
|
171
|
+
declare function interpretSdkError(err: any): Error;
|
|
172
|
+
|
|
173
|
+
type FlowGenerateText = (prompt: string, options?: FlowTextGenerationOptions) => Promise<string>;
|
|
174
|
+
interface CreateFlowTextGenerationPortOptions {
|
|
175
|
+
provider?: string;
|
|
176
|
+
modelId?: string;
|
|
177
|
+
}
|
|
178
|
+
/**
|
|
179
|
+
* Adapts the existing Flow SDK service to the host-neutral Szenen contract.
|
|
180
|
+
* It deliberately does not parse or validate the response: that happens once
|
|
181
|
+
* in `runPromptDerivation`, identically for every host.
|
|
182
|
+
*/
|
|
183
|
+
declare function createFlowTextGenerationPort(generateText: FlowGenerateText, options?: CreateFlowTextGenerationPortOptions): TextGenerationPort;
|
|
184
|
+
|
|
185
|
+
interface HFEventVersion {
|
|
186
|
+
major: number;
|
|
187
|
+
minor: number;
|
|
188
|
+
}
|
|
189
|
+
interface HFEvent<P = unknown> {
|
|
190
|
+
v: HFEventVersion;
|
|
191
|
+
type: string;
|
|
192
|
+
ts: number;
|
|
193
|
+
prevTs: number[];
|
|
194
|
+
clientId: string;
|
|
195
|
+
payload: P;
|
|
196
|
+
}
|
|
197
|
+
interface HFStateMeta {
|
|
198
|
+
consolidatedAt: number;
|
|
199
|
+
version: number;
|
|
200
|
+
}
|
|
201
|
+
interface HFStateSnapshot {
|
|
202
|
+
metadata: HFMetadataEntry[];
|
|
203
|
+
tags: WorkspaceTags;
|
|
204
|
+
meta: HFStateMeta;
|
|
205
|
+
openTasks?: Record<string, TaskRequestedPayload>;
|
|
206
|
+
}
|
|
207
|
+
interface HFFileInfo {
|
|
208
|
+
type: 'file' | 'directory';
|
|
209
|
+
path: string;
|
|
210
|
+
size: number;
|
|
211
|
+
}
|
|
212
|
+
interface ImageAddedPayload extends HFMetadataEntry {
|
|
213
|
+
taskId?: string;
|
|
214
|
+
}
|
|
215
|
+
interface TagUpsertedPayload {
|
|
216
|
+
category: string;
|
|
217
|
+
label: string;
|
|
218
|
+
value: string;
|
|
219
|
+
is_user_created?: boolean;
|
|
220
|
+
is_deleted?: boolean;
|
|
221
|
+
}
|
|
222
|
+
interface MetadataUpdatedPayload {
|
|
223
|
+
id: string;
|
|
224
|
+
delta: Partial<HFMetadataEntry>;
|
|
225
|
+
}
|
|
226
|
+
interface TaskRequestedPayload {
|
|
227
|
+
taskId: string;
|
|
228
|
+
taskType: string;
|
|
229
|
+
params: {
|
|
230
|
+
prompt: string;
|
|
231
|
+
tags?: string[];
|
|
232
|
+
book?: string;
|
|
233
|
+
kapitel?: string;
|
|
234
|
+
ankerId?: string;
|
|
235
|
+
promptVersion?: number;
|
|
236
|
+
[key: string]: any;
|
|
237
|
+
};
|
|
238
|
+
expiresAt?: number;
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
export { type CreateFlowTextGenerationPortOptions as C, type FlowGenerateText as F, type Generation as G, type HFEvent as H, type ImageAddedPayload as I, type LabFrame as L, type MetadataUpdatedPayload as M, type ProjectMeta as P, type SelectedLabImage as S, type TagOption as T, type WorkspaceTags as W, type FlowSdk as a, type FlowTextGenerationOptions as b, type HFEventVersion as c, type HFFileInfo as d, type HFMetadataEntry as e, type HFStateMeta as f, type HFStateSnapshot as g, type LabItem as h, type LabServices as i, type ProjectSettings as j, type SelectedTag as k, type SyncDiff as l, type TagUpsertedPayload as m, buildFallbackPrompt as n, buildGenerationPrompt as o, buildImageGenerationOptions as p, buildPromptTabPayload as q, cleanAiResponse as r, createFlowServices as s, createFlowTextGenerationPort as t, interpretSdkError as u, parsePromptResponse as v };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,127 +1,15 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import React__default, { RefObject, ReactNode } from 'react';
|
|
3
|
-
import { F as FlowGenerateText, b as FlowTextGenerationOptions,
|
|
4
|
-
export { a as FlowSdk, c as
|
|
3
|
+
import { G as Generation, W as WorkspaceTags, F as FlowGenerateText, P as ProjectMeta, b as FlowTextGenerationOptions, k as SelectedTag, l as SyncDiff, T as TagOption, i as LabServices, h as LabItem, L as LabFrame, S as SelectedLabImage, H as HFEvent, g as HFStateSnapshot } from './hfEventTypes-Dkfrcd_t.mjs';
|
|
4
|
+
export { a as FlowSdk, c as HFEventVersion, d as HFFileInfo, e as HFMetadataEntry, f as HFStateMeta, I as ImageAddedPayload, M as MetadataUpdatedPayload, j as ProjectSettings, m as TagUpsertedPayload, n as buildFallbackPrompt, o as buildGenerationPrompt, p as buildImageGenerationOptions, q as buildPromptTabPayload, r as cleanAiResponse, s as createFlowServices, u as interpretSdkError, v as parsePromptResponse } from './hfEventTypes-Dkfrcd_t.mjs';
|
|
5
5
|
import { Node, Edge } from '@xyflow/react';
|
|
6
6
|
import * as zustand_vanilla from 'zustand/vanilla';
|
|
7
7
|
import { F as FeatureSliceId, b as SliceContract, a as PersistenceDescriptor, W as WorkspacePersistence, P as PersistedSlice, L as LoadResult, f as WriteResult, e as WorkspaceTabId, C as CommandResult, R as RequestContext, Q as QueryResult } from './contracts-DdYOMBl9.mjs';
|
|
8
8
|
|
|
9
|
-
var version = "2.0.
|
|
9
|
+
var version = "2.0.87";
|
|
10
10
|
|
|
11
11
|
declare function useOnClickOutside(ref: RefObject<HTMLElement | null>, handler: (e: MouseEvent | TouchEvent) => void): void;
|
|
12
12
|
|
|
13
|
-
interface TagOption {
|
|
14
|
-
label: string;
|
|
15
|
-
value: string;
|
|
16
|
-
is_user_created?: boolean;
|
|
17
|
-
is_deleted?: boolean;
|
|
18
|
-
}
|
|
19
|
-
interface WorkspaceTags {
|
|
20
|
-
by_category: Record<string, TagOption[]>;
|
|
21
|
-
all: Array<TagOption & {
|
|
22
|
-
category: string;
|
|
23
|
-
}>;
|
|
24
|
-
}
|
|
25
|
-
interface Generation {
|
|
26
|
-
id: string;
|
|
27
|
-
nodeId: string;
|
|
28
|
-
base64?: string;
|
|
29
|
-
fullBase64?: string;
|
|
30
|
-
mediaId?: string;
|
|
31
|
-
prompt?: string;
|
|
32
|
-
hierarchy?: string;
|
|
33
|
-
seed?: number;
|
|
34
|
-
model?: string;
|
|
35
|
-
timestamp: number;
|
|
36
|
-
status: 'processing' | 'done' | 'error';
|
|
37
|
-
step?: string;
|
|
38
|
-
tags: string[];
|
|
39
|
-
type?: 'generation' | 'import';
|
|
40
|
-
error?: {
|
|
41
|
-
message: string;
|
|
42
|
-
details?: string;
|
|
43
|
-
};
|
|
44
|
-
selectedForExport?: boolean;
|
|
45
|
-
filename?: string;
|
|
46
|
-
hasThumb?: boolean;
|
|
47
|
-
mimeType?: string;
|
|
48
|
-
titleTs?: number;
|
|
49
|
-
}
|
|
50
|
-
interface ProjectSettings {
|
|
51
|
-
aspectRatio: string;
|
|
52
|
-
selectedModel: string;
|
|
53
|
-
seed: number;
|
|
54
|
-
seedMode: 'random' | 'fixed';
|
|
55
|
-
}
|
|
56
|
-
interface ProjectMeta {
|
|
57
|
-
id: string;
|
|
58
|
-
name: string;
|
|
59
|
-
saved_at: string;
|
|
60
|
-
size: number;
|
|
61
|
-
}
|
|
62
|
-
interface SyncDiff {
|
|
63
|
-
localOnly: Generation[];
|
|
64
|
-
serverOnly: Generation[];
|
|
65
|
-
}
|
|
66
|
-
interface LabFrame {
|
|
67
|
-
id: string;
|
|
68
|
-
base64: string;
|
|
69
|
-
mediaId?: string;
|
|
70
|
-
seed?: number;
|
|
71
|
-
model?: string;
|
|
72
|
-
aspectRatio?: string;
|
|
73
|
-
width?: number;
|
|
74
|
-
height?: number;
|
|
75
|
-
source?: 'generated' | 'flow-gallery' | 'zip-import' | 'db-library';
|
|
76
|
-
}
|
|
77
|
-
interface LabItem {
|
|
78
|
-
id: string;
|
|
79
|
-
prompt: string;
|
|
80
|
-
label?: string;
|
|
81
|
-
tags?: string[];
|
|
82
|
-
frames: LabFrame[];
|
|
83
|
-
}
|
|
84
|
-
interface SelectedLabImage {
|
|
85
|
-
item: LabItem;
|
|
86
|
-
frame: LabFrame;
|
|
87
|
-
label: string;
|
|
88
|
-
roleForPrompt?: string;
|
|
89
|
-
roleForImage?: string;
|
|
90
|
-
sendToPromptAI: boolean;
|
|
91
|
-
sendToImageGen: boolean;
|
|
92
|
-
}
|
|
93
|
-
interface LabServices {
|
|
94
|
-
availableItems: LabItem[];
|
|
95
|
-
recentItems: LabItem[];
|
|
96
|
-
onItemUsed: (item: LabItem) => void;
|
|
97
|
-
generateText: (text: string, options?: {
|
|
98
|
-
images?: {
|
|
99
|
-
base64: string;
|
|
100
|
-
mimeType: string;
|
|
101
|
-
}[];
|
|
102
|
-
systemInstruction?: string;
|
|
103
|
-
}) => Promise<string>;
|
|
104
|
-
generateImage: (options: Record<string, any>) => Promise<{
|
|
105
|
-
base64: string;
|
|
106
|
-
mediaId?: string;
|
|
107
|
-
}>;
|
|
108
|
-
saveResult?: (item: LabItem) => Promise<void>;
|
|
109
|
-
workspaceTags?: WorkspaceTags;
|
|
110
|
-
}
|
|
111
|
-
interface HFMetadataEntry {
|
|
112
|
-
id: string;
|
|
113
|
-
prompt?: string;
|
|
114
|
-
seed?: number;
|
|
115
|
-
model?: string;
|
|
116
|
-
tags: string[];
|
|
117
|
-
timestamp: number;
|
|
118
|
-
mimeType: string;
|
|
119
|
-
size?: number;
|
|
120
|
-
filename?: string;
|
|
121
|
-
hasThumb?: boolean;
|
|
122
|
-
titleTs?: number;
|
|
123
|
-
}
|
|
124
|
-
|
|
125
13
|
/**
|
|
126
14
|
* Hook für die Tastaturnavigation im Detailview.
|
|
127
15
|
* Rechts = Index + 1 (älter), Links = Index - 1 (neuer).
|
|
@@ -934,62 +822,6 @@ declare function buildLoopInstruction(rounds: Array<{
|
|
|
934
822
|
declare function autoLabel(index: number): string;
|
|
935
823
|
declare function buildReferenceImageMediaIds(images: SelectedLabImage[]): string[];
|
|
936
824
|
|
|
937
|
-
interface HFEventVersion {
|
|
938
|
-
major: number;
|
|
939
|
-
minor: number;
|
|
940
|
-
}
|
|
941
|
-
interface HFEvent<P = unknown> {
|
|
942
|
-
v: HFEventVersion;
|
|
943
|
-
type: string;
|
|
944
|
-
ts: number;
|
|
945
|
-
prevTs: number[];
|
|
946
|
-
clientId: string;
|
|
947
|
-
payload: P;
|
|
948
|
-
}
|
|
949
|
-
interface HFStateMeta {
|
|
950
|
-
consolidatedAt: number;
|
|
951
|
-
version: number;
|
|
952
|
-
}
|
|
953
|
-
interface HFStateSnapshot {
|
|
954
|
-
metadata: HFMetadataEntry[];
|
|
955
|
-
tags: WorkspaceTags;
|
|
956
|
-
meta: HFStateMeta;
|
|
957
|
-
openTasks?: Record<string, TaskRequestedPayload>;
|
|
958
|
-
}
|
|
959
|
-
interface HFFileInfo$1 {
|
|
960
|
-
type: 'file' | 'directory';
|
|
961
|
-
path: string;
|
|
962
|
-
size: number;
|
|
963
|
-
}
|
|
964
|
-
interface ImageAddedPayload extends HFMetadataEntry {
|
|
965
|
-
taskId?: string;
|
|
966
|
-
}
|
|
967
|
-
interface TagUpsertedPayload {
|
|
968
|
-
category: string;
|
|
969
|
-
label: string;
|
|
970
|
-
value: string;
|
|
971
|
-
is_user_created?: boolean;
|
|
972
|
-
is_deleted?: boolean;
|
|
973
|
-
}
|
|
974
|
-
interface MetadataUpdatedPayload {
|
|
975
|
-
id: string;
|
|
976
|
-
delta: Partial<HFMetadataEntry>;
|
|
977
|
-
}
|
|
978
|
-
interface TaskRequestedPayload {
|
|
979
|
-
taskId: string;
|
|
980
|
-
taskType: string;
|
|
981
|
-
params: {
|
|
982
|
-
prompt: string;
|
|
983
|
-
tags?: string[];
|
|
984
|
-
book?: string;
|
|
985
|
-
kapitel?: string;
|
|
986
|
-
ankerId?: string;
|
|
987
|
-
promptVersion?: number;
|
|
988
|
-
[key: string]: any;
|
|
989
|
-
};
|
|
990
|
-
expiresAt?: number;
|
|
991
|
-
}
|
|
992
|
-
|
|
993
825
|
interface HFFileInfo {
|
|
994
826
|
type: 'file' | 'directory';
|
|
995
827
|
path: string;
|
|
@@ -1080,4 +912,4 @@ interface UseTagBaseResult {
|
|
|
1080
912
|
}
|
|
1081
913
|
declare function useTagBase(token: string, namespace: string): UseTagBaseResult;
|
|
1082
914
|
|
|
1083
|
-
export { AvatarArchitectApp, type AvatarArchitectAppProps, CURRENT_TAG_EVENT_VERSION, CollapsibleCard, CommandResult, CompactDropdown, type CreateFaStoreOptions, type CreatePersistenceCoordinatorOptions, type ExtractedCharacter, FaApp, type FaAppProps, type FaStore, type FaStoreState, FaToolsBadge, FeatureSliceId, FlowTextGenerationOptions, FlowWorkspacePicker, type FlowWorkspacePickerProps, GLOBAL_STYLES,
|
|
915
|
+
export { AvatarArchitectApp, type AvatarArchitectAppProps, CURRENT_TAG_EVENT_VERSION, CollapsibleCard, CommandResult, CompactDropdown, type CreateFaStoreOptions, type CreatePersistenceCoordinatorOptions, type ExtractedCharacter, FaApp, type FaAppProps, type FaStore, type FaStoreState, FaToolsBadge, FeatureSliceId, FlowTextGenerationOptions, FlowWorkspacePicker, type FlowWorkspacePickerProps, GLOBAL_STYLES, Generation, HFEvent, type HFStateResult, HFStateSnapshot, HistoryPanel, type InMemoryWorkspacePersistence, InspectPanel, LIBRARY_CUTOVER_MARKER, LIBRARY_SLICE_SCHEMA_VERSION, version as LIB_VERSION, LabBlend, LabCompare, LabFrame, LabFrameExtractor, type LabFrameExtractorProps, LabImagePicker, LabItem, LabLoop, LabRemix, LabServices, type LabSlotId, LabsTab, type LegacyMigrationOptions, type LegacyMigrationResult, type LegacyRecentTagRef, type LegacySourceResult, type LibraryCommandName, type LibraryCommands, type LibraryDataSource, type LibraryLegacySource, type LibraryListQuery, type LibraryPage, LibraryView, type LibraryViewItem, type LibraryViewProps, type LibraryViewTag, type LibraryWorkspaceState, ListView, LoadResult, type MediaItem, MediaLibrary, PersistedSlice, type PersistenceCoordinator, PersistenceDescriptor, PillButton, ProjectMeta, ProjectSyncTab, PromptTab, QueryResult, RequestContext, type RunLibraryLegacyImportOptions, type RunTagsLegacyImportOptions, SCOPE_MAP, type SaveState, SectionLabel, SelectedLabImage, SelectedTag, type SelectionValidation, ServerTab, SetupPanel, SliceContract, type SliceMeta, SyncDiff, TAGS_CUTOVER_MARKER, TAGS_SLICE_SCHEMA_VERSION, type TagBase, type TagBaseContext, type TagBaseEvent, type TagBaseMeta, TagBaseSection, type TagBaseSectionProps, type TagBaseTagEntry, type TagBaseTagOption, type TagBaseUser, type TagBaseWorkspaceTags, type TagCommandName, type TagCommands, type TagCreatedEvent, type TagCreatedPayload, type TagEntry, type TagEntryInput, TagManager, TagManagerPanel, type TagManagerProps, type TagManagerSelection, TagOption, type TagQueries, type TagUpdateDelta, type TagUpdatedDelta, type TagUpdatedEvent, type TagUpdatedPayload, type TagViewCategory, type TagViewModel, type TagViewOption, type TagViewScope, type TagsWorkspaceState, type UseTagBaseResult, WorkspacePersistence, WorkspaceTabId, WorkspaceTags, WriteResult, autoLabel, buildBlendInstruction, buildCompareInstruction, buildLoopInstruction, buildReferenceImageMediaIds, buildRemixInstruction, buildScanInstruction, createFaStore, createInMemoryLibraryDataSource, createInMemoryWorkspacePersistence, createLibraryDefault, createPersistenceCoordinator, createTagCreatedEvent, createTagUpdatedEvent, createTagsDefault, deriveTagBaseWorkspaceTags, deriveTagViewModel, exportProjectToZip, formatTreeToMarkdown, frameToGeneration, getFormattedTimestamp, getHFToken, getSessionClientId, groupGenerationsToLabItems, hfBatchArchive, hfBootstrapFromLegacy, hfDeleteProject, hfDownloadProject, hfListDir, hfListProjects, hfLoadImageAsBase64, hfUploadImage, hfUploadProjectForm, hfUploadSmallFile, importProjectFromZip, injectXMPMetadata, libraryContract, libraryReactDescriptor, listCategories, loadHFState, loadPendingEvents, loadTagBase, parseLegacyLibraryFilters, parseLegacyRecentTags, parsePromptFile, runLegacyMigration, runLibraryLegacyImport, runTagsLegacyImport, setHFToken, tagsContract, tagsReactDescriptor, tsFromEventPath, useFaSlice, useFaSliceMeta, useHFState, useKeyboardNavigation, useOnClickOutside, useTagBase, validateTagBaseSelection, writeHFEvent, writeTagEvent };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,127 +1,15 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import React__default, { RefObject, ReactNode } from 'react';
|
|
3
|
-
import { F as FlowGenerateText, b as FlowTextGenerationOptions,
|
|
4
|
-
export { a as FlowSdk, c as
|
|
3
|
+
import { G as Generation, W as WorkspaceTags, F as FlowGenerateText, P as ProjectMeta, b as FlowTextGenerationOptions, k as SelectedTag, l as SyncDiff, T as TagOption, i as LabServices, h as LabItem, L as LabFrame, S as SelectedLabImage, H as HFEvent, g as HFStateSnapshot } from './hfEventTypes-C_PX6RFR.js';
|
|
4
|
+
export { a as FlowSdk, c as HFEventVersion, d as HFFileInfo, e as HFMetadataEntry, f as HFStateMeta, I as ImageAddedPayload, M as MetadataUpdatedPayload, j as ProjectSettings, m as TagUpsertedPayload, n as buildFallbackPrompt, o as buildGenerationPrompt, p as buildImageGenerationOptions, q as buildPromptTabPayload, r as cleanAiResponse, s as createFlowServices, u as interpretSdkError, v as parsePromptResponse } from './hfEventTypes-C_PX6RFR.js';
|
|
5
5
|
import { Node, Edge } from '@xyflow/react';
|
|
6
6
|
import * as zustand_vanilla from 'zustand/vanilla';
|
|
7
7
|
import { F as FeatureSliceId, b as SliceContract, a as PersistenceDescriptor, W as WorkspacePersistence, P as PersistedSlice, L as LoadResult, f as WriteResult, e as WorkspaceTabId, C as CommandResult, R as RequestContext, Q as QueryResult } from './contracts-DdYOMBl9.js';
|
|
8
8
|
|
|
9
|
-
var version = "2.0.
|
|
9
|
+
var version = "2.0.87";
|
|
10
10
|
|
|
11
11
|
declare function useOnClickOutside(ref: RefObject<HTMLElement | null>, handler: (e: MouseEvent | TouchEvent) => void): void;
|
|
12
12
|
|
|
13
|
-
interface TagOption {
|
|
14
|
-
label: string;
|
|
15
|
-
value: string;
|
|
16
|
-
is_user_created?: boolean;
|
|
17
|
-
is_deleted?: boolean;
|
|
18
|
-
}
|
|
19
|
-
interface WorkspaceTags {
|
|
20
|
-
by_category: Record<string, TagOption[]>;
|
|
21
|
-
all: Array<TagOption & {
|
|
22
|
-
category: string;
|
|
23
|
-
}>;
|
|
24
|
-
}
|
|
25
|
-
interface Generation {
|
|
26
|
-
id: string;
|
|
27
|
-
nodeId: string;
|
|
28
|
-
base64?: string;
|
|
29
|
-
fullBase64?: string;
|
|
30
|
-
mediaId?: string;
|
|
31
|
-
prompt?: string;
|
|
32
|
-
hierarchy?: string;
|
|
33
|
-
seed?: number;
|
|
34
|
-
model?: string;
|
|
35
|
-
timestamp: number;
|
|
36
|
-
status: 'processing' | 'done' | 'error';
|
|
37
|
-
step?: string;
|
|
38
|
-
tags: string[];
|
|
39
|
-
type?: 'generation' | 'import';
|
|
40
|
-
error?: {
|
|
41
|
-
message: string;
|
|
42
|
-
details?: string;
|
|
43
|
-
};
|
|
44
|
-
selectedForExport?: boolean;
|
|
45
|
-
filename?: string;
|
|
46
|
-
hasThumb?: boolean;
|
|
47
|
-
mimeType?: string;
|
|
48
|
-
titleTs?: number;
|
|
49
|
-
}
|
|
50
|
-
interface ProjectSettings {
|
|
51
|
-
aspectRatio: string;
|
|
52
|
-
selectedModel: string;
|
|
53
|
-
seed: number;
|
|
54
|
-
seedMode: 'random' | 'fixed';
|
|
55
|
-
}
|
|
56
|
-
interface ProjectMeta {
|
|
57
|
-
id: string;
|
|
58
|
-
name: string;
|
|
59
|
-
saved_at: string;
|
|
60
|
-
size: number;
|
|
61
|
-
}
|
|
62
|
-
interface SyncDiff {
|
|
63
|
-
localOnly: Generation[];
|
|
64
|
-
serverOnly: Generation[];
|
|
65
|
-
}
|
|
66
|
-
interface LabFrame {
|
|
67
|
-
id: string;
|
|
68
|
-
base64: string;
|
|
69
|
-
mediaId?: string;
|
|
70
|
-
seed?: number;
|
|
71
|
-
model?: string;
|
|
72
|
-
aspectRatio?: string;
|
|
73
|
-
width?: number;
|
|
74
|
-
height?: number;
|
|
75
|
-
source?: 'generated' | 'flow-gallery' | 'zip-import' | 'db-library';
|
|
76
|
-
}
|
|
77
|
-
interface LabItem {
|
|
78
|
-
id: string;
|
|
79
|
-
prompt: string;
|
|
80
|
-
label?: string;
|
|
81
|
-
tags?: string[];
|
|
82
|
-
frames: LabFrame[];
|
|
83
|
-
}
|
|
84
|
-
interface SelectedLabImage {
|
|
85
|
-
item: LabItem;
|
|
86
|
-
frame: LabFrame;
|
|
87
|
-
label: string;
|
|
88
|
-
roleForPrompt?: string;
|
|
89
|
-
roleForImage?: string;
|
|
90
|
-
sendToPromptAI: boolean;
|
|
91
|
-
sendToImageGen: boolean;
|
|
92
|
-
}
|
|
93
|
-
interface LabServices {
|
|
94
|
-
availableItems: LabItem[];
|
|
95
|
-
recentItems: LabItem[];
|
|
96
|
-
onItemUsed: (item: LabItem) => void;
|
|
97
|
-
generateText: (text: string, options?: {
|
|
98
|
-
images?: {
|
|
99
|
-
base64: string;
|
|
100
|
-
mimeType: string;
|
|
101
|
-
}[];
|
|
102
|
-
systemInstruction?: string;
|
|
103
|
-
}) => Promise<string>;
|
|
104
|
-
generateImage: (options: Record<string, any>) => Promise<{
|
|
105
|
-
base64: string;
|
|
106
|
-
mediaId?: string;
|
|
107
|
-
}>;
|
|
108
|
-
saveResult?: (item: LabItem) => Promise<void>;
|
|
109
|
-
workspaceTags?: WorkspaceTags;
|
|
110
|
-
}
|
|
111
|
-
interface HFMetadataEntry {
|
|
112
|
-
id: string;
|
|
113
|
-
prompt?: string;
|
|
114
|
-
seed?: number;
|
|
115
|
-
model?: string;
|
|
116
|
-
tags: string[];
|
|
117
|
-
timestamp: number;
|
|
118
|
-
mimeType: string;
|
|
119
|
-
size?: number;
|
|
120
|
-
filename?: string;
|
|
121
|
-
hasThumb?: boolean;
|
|
122
|
-
titleTs?: number;
|
|
123
|
-
}
|
|
124
|
-
|
|
125
13
|
/**
|
|
126
14
|
* Hook für die Tastaturnavigation im Detailview.
|
|
127
15
|
* Rechts = Index + 1 (älter), Links = Index - 1 (neuer).
|
|
@@ -934,62 +822,6 @@ declare function buildLoopInstruction(rounds: Array<{
|
|
|
934
822
|
declare function autoLabel(index: number): string;
|
|
935
823
|
declare function buildReferenceImageMediaIds(images: SelectedLabImage[]): string[];
|
|
936
824
|
|
|
937
|
-
interface HFEventVersion {
|
|
938
|
-
major: number;
|
|
939
|
-
minor: number;
|
|
940
|
-
}
|
|
941
|
-
interface HFEvent<P = unknown> {
|
|
942
|
-
v: HFEventVersion;
|
|
943
|
-
type: string;
|
|
944
|
-
ts: number;
|
|
945
|
-
prevTs: number[];
|
|
946
|
-
clientId: string;
|
|
947
|
-
payload: P;
|
|
948
|
-
}
|
|
949
|
-
interface HFStateMeta {
|
|
950
|
-
consolidatedAt: number;
|
|
951
|
-
version: number;
|
|
952
|
-
}
|
|
953
|
-
interface HFStateSnapshot {
|
|
954
|
-
metadata: HFMetadataEntry[];
|
|
955
|
-
tags: WorkspaceTags;
|
|
956
|
-
meta: HFStateMeta;
|
|
957
|
-
openTasks?: Record<string, TaskRequestedPayload>;
|
|
958
|
-
}
|
|
959
|
-
interface HFFileInfo$1 {
|
|
960
|
-
type: 'file' | 'directory';
|
|
961
|
-
path: string;
|
|
962
|
-
size: number;
|
|
963
|
-
}
|
|
964
|
-
interface ImageAddedPayload extends HFMetadataEntry {
|
|
965
|
-
taskId?: string;
|
|
966
|
-
}
|
|
967
|
-
interface TagUpsertedPayload {
|
|
968
|
-
category: string;
|
|
969
|
-
label: string;
|
|
970
|
-
value: string;
|
|
971
|
-
is_user_created?: boolean;
|
|
972
|
-
is_deleted?: boolean;
|
|
973
|
-
}
|
|
974
|
-
interface MetadataUpdatedPayload {
|
|
975
|
-
id: string;
|
|
976
|
-
delta: Partial<HFMetadataEntry>;
|
|
977
|
-
}
|
|
978
|
-
interface TaskRequestedPayload {
|
|
979
|
-
taskId: string;
|
|
980
|
-
taskType: string;
|
|
981
|
-
params: {
|
|
982
|
-
prompt: string;
|
|
983
|
-
tags?: string[];
|
|
984
|
-
book?: string;
|
|
985
|
-
kapitel?: string;
|
|
986
|
-
ankerId?: string;
|
|
987
|
-
promptVersion?: number;
|
|
988
|
-
[key: string]: any;
|
|
989
|
-
};
|
|
990
|
-
expiresAt?: number;
|
|
991
|
-
}
|
|
992
|
-
|
|
993
825
|
interface HFFileInfo {
|
|
994
826
|
type: 'file' | 'directory';
|
|
995
827
|
path: string;
|
|
@@ -1080,4 +912,4 @@ interface UseTagBaseResult {
|
|
|
1080
912
|
}
|
|
1081
913
|
declare function useTagBase(token: string, namespace: string): UseTagBaseResult;
|
|
1082
914
|
|
|
1083
|
-
export { AvatarArchitectApp, type AvatarArchitectAppProps, CURRENT_TAG_EVENT_VERSION, CollapsibleCard, CommandResult, CompactDropdown, type CreateFaStoreOptions, type CreatePersistenceCoordinatorOptions, type ExtractedCharacter, FaApp, type FaAppProps, type FaStore, type FaStoreState, FaToolsBadge, FeatureSliceId, FlowTextGenerationOptions, FlowWorkspacePicker, type FlowWorkspacePickerProps, GLOBAL_STYLES,
|
|
915
|
+
export { AvatarArchitectApp, type AvatarArchitectAppProps, CURRENT_TAG_EVENT_VERSION, CollapsibleCard, CommandResult, CompactDropdown, type CreateFaStoreOptions, type CreatePersistenceCoordinatorOptions, type ExtractedCharacter, FaApp, type FaAppProps, type FaStore, type FaStoreState, FaToolsBadge, FeatureSliceId, FlowTextGenerationOptions, FlowWorkspacePicker, type FlowWorkspacePickerProps, GLOBAL_STYLES, Generation, HFEvent, type HFStateResult, HFStateSnapshot, HistoryPanel, type InMemoryWorkspacePersistence, InspectPanel, LIBRARY_CUTOVER_MARKER, LIBRARY_SLICE_SCHEMA_VERSION, version as LIB_VERSION, LabBlend, LabCompare, LabFrame, LabFrameExtractor, type LabFrameExtractorProps, LabImagePicker, LabItem, LabLoop, LabRemix, LabServices, type LabSlotId, LabsTab, type LegacyMigrationOptions, type LegacyMigrationResult, type LegacyRecentTagRef, type LegacySourceResult, type LibraryCommandName, type LibraryCommands, type LibraryDataSource, type LibraryLegacySource, type LibraryListQuery, type LibraryPage, LibraryView, type LibraryViewItem, type LibraryViewProps, type LibraryViewTag, type LibraryWorkspaceState, ListView, LoadResult, type MediaItem, MediaLibrary, PersistedSlice, type PersistenceCoordinator, PersistenceDescriptor, PillButton, ProjectMeta, ProjectSyncTab, PromptTab, QueryResult, RequestContext, type RunLibraryLegacyImportOptions, type RunTagsLegacyImportOptions, SCOPE_MAP, type SaveState, SectionLabel, SelectedLabImage, SelectedTag, type SelectionValidation, ServerTab, SetupPanel, SliceContract, type SliceMeta, SyncDiff, TAGS_CUTOVER_MARKER, TAGS_SLICE_SCHEMA_VERSION, type TagBase, type TagBaseContext, type TagBaseEvent, type TagBaseMeta, TagBaseSection, type TagBaseSectionProps, type TagBaseTagEntry, type TagBaseTagOption, type TagBaseUser, type TagBaseWorkspaceTags, type TagCommandName, type TagCommands, type TagCreatedEvent, type TagCreatedPayload, type TagEntry, type TagEntryInput, TagManager, TagManagerPanel, type TagManagerProps, type TagManagerSelection, TagOption, type TagQueries, type TagUpdateDelta, type TagUpdatedDelta, type TagUpdatedEvent, type TagUpdatedPayload, type TagViewCategory, type TagViewModel, type TagViewOption, type TagViewScope, type TagsWorkspaceState, type UseTagBaseResult, WorkspacePersistence, WorkspaceTabId, WorkspaceTags, WriteResult, autoLabel, buildBlendInstruction, buildCompareInstruction, buildLoopInstruction, buildReferenceImageMediaIds, buildRemixInstruction, buildScanInstruction, createFaStore, createInMemoryLibraryDataSource, createInMemoryWorkspacePersistence, createLibraryDefault, createPersistenceCoordinator, createTagCreatedEvent, createTagUpdatedEvent, createTagsDefault, deriveTagBaseWorkspaceTags, deriveTagViewModel, exportProjectToZip, formatTreeToMarkdown, frameToGeneration, getFormattedTimestamp, getHFToken, getSessionClientId, groupGenerationsToLabItems, hfBatchArchive, hfBootstrapFromLegacy, hfDeleteProject, hfDownloadProject, hfListDir, hfListProjects, hfLoadImageAsBase64, hfUploadImage, hfUploadProjectForm, hfUploadSmallFile, importProjectFromZip, injectXMPMetadata, libraryContract, libraryReactDescriptor, listCategories, loadHFState, loadPendingEvents, loadTagBase, parseLegacyLibraryFilters, parseLegacyRecentTags, parsePromptFile, runLegacyMigration, runLibraryLegacyImport, runTagsLegacyImport, setHFToken, tagsContract, tagsReactDescriptor, tsFromEventPath, useFaSlice, useFaSliceMeta, useHFState, useKeyboardNavigation, useOnClickOutside, useTagBase, validateTagBaseSelection, writeHFEvent, writeTagEvent };
|