@builder.io/ai-utils 0.5.33 → 0.5.35
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/package.json +1 -1
- package/src/codegen.d.ts +36 -13
- package/src/projects.d.ts +1 -1
- package/src/repo-indexing.d.ts +3 -0
package/package.json
CHANGED
package/src/codegen.d.ts
CHANGED
|
@@ -147,6 +147,10 @@ export interface GetScreenshotToolInput {
|
|
|
147
147
|
width?: number;
|
|
148
148
|
height?: number;
|
|
149
149
|
}
|
|
150
|
+
export interface WebFetchToolInput {
|
|
151
|
+
url: string;
|
|
152
|
+
prompt: string;
|
|
153
|
+
}
|
|
150
154
|
export interface CodeGenToolMap {
|
|
151
155
|
view_path: ViewPathToolInput;
|
|
152
156
|
glob_search: GlobSearchToolInput;
|
|
@@ -182,6 +186,7 @@ export interface CodeGenToolMap {
|
|
|
182
186
|
TodoWrite: TodoWriteToolInput;
|
|
183
187
|
BuilderEdit: BuilderEditToolInput;
|
|
184
188
|
LS: ListDirToolInput;
|
|
189
|
+
WebFetch: WebFetchToolInput;
|
|
185
190
|
}
|
|
186
191
|
export type CodeGenTools = keyof CodeGenToolMap;
|
|
187
192
|
export type AllCodeGenTools = CodeGenTools | "web_search";
|
|
@@ -209,6 +214,8 @@ export interface CodeGenInputOptions {
|
|
|
209
214
|
workingDirectory?: string;
|
|
210
215
|
encryptKey?: string;
|
|
211
216
|
modelOverride?: string;
|
|
217
|
+
redactUserMessages?: boolean;
|
|
218
|
+
redactLLMMessages?: boolean;
|
|
212
219
|
builderContent?: BuilderContent;
|
|
213
220
|
framework?: CodeGenFramework;
|
|
214
221
|
styleLibrary?: CodeGenStyleLibrary;
|
|
@@ -227,6 +234,7 @@ export interface CodeGenInputOptions {
|
|
|
227
234
|
pingEvents?: boolean;
|
|
228
235
|
forceCompact?: boolean;
|
|
229
236
|
hadPagination?: boolean;
|
|
237
|
+
repair?: boolean;
|
|
230
238
|
searchResponse?: any | null;
|
|
231
239
|
prettierConfig?: PrettierOptions;
|
|
232
240
|
role?: "user" | "agent";
|
|
@@ -237,7 +245,7 @@ export interface CodeGenInputOptions {
|
|
|
237
245
|
/** @deprecated */
|
|
238
246
|
vcpId?: string;
|
|
239
247
|
}
|
|
240
|
-
export type CodeGenErrorCodes = "credits-limit-daily" | "credits-limit-monthly" | "credits-limit-other" | "cli-genetic-error" | "git-update-error" | "prompt-too-long" | "context-too-long" | "unknown" | "failed-recover-state" | "bad-initial-url" | "invalid-last-message" | "corrupted-session" | "assertion" | "rate-limit";
|
|
248
|
+
export type CodeGenErrorCodes = "credits-limit-daily" | "credits-limit-monthly" | "credits-limit-other" | "cli-genetic-error" | "git-update-error" | "prompt-too-long" | "context-too-long" | "unknown" | "failed-recover-state" | "ask-to-continue" | "bad-initial-url" | "invalid-last-message" | "corrupted-session" | "assertion" | "rate-limit";
|
|
241
249
|
export type Feature = "component-mapping";
|
|
242
250
|
export interface CodegenUsage {
|
|
243
251
|
total: number;
|
|
@@ -553,7 +561,7 @@ export interface UserSourceBuilder {
|
|
|
553
561
|
userId?: string;
|
|
554
562
|
userName?: string;
|
|
555
563
|
userEmail?: string;
|
|
556
|
-
role: "user";
|
|
564
|
+
role: "user" | "agent";
|
|
557
565
|
photoURL?: string;
|
|
558
566
|
principals?: string[];
|
|
559
567
|
}
|
|
@@ -588,7 +596,7 @@ export interface UserSourceBitbucket {
|
|
|
588
596
|
}
|
|
589
597
|
export interface UserSourceAgent {
|
|
590
598
|
source: "agent";
|
|
591
|
-
role: "agent";
|
|
599
|
+
role: "agent" | "user";
|
|
592
600
|
principals?: string[];
|
|
593
601
|
}
|
|
594
602
|
export type UserSource = UserSourceBuilder | UserSourceGithub | UserSourceGitlab | UserSourceAzure | UserSourceBitbucket | UserSourceAgent;
|
|
@@ -604,6 +612,8 @@ export interface GenerateUserMessage {
|
|
|
604
612
|
logsCheckpoint?: boolean;
|
|
605
613
|
dropAbortedPrompt?: boolean;
|
|
606
614
|
modelOverride?: string;
|
|
615
|
+
maxCompletions?: number;
|
|
616
|
+
repair?: boolean;
|
|
607
617
|
}
|
|
608
618
|
export interface UserInput {
|
|
609
619
|
userMessage: GenerateUserMessage | undefined;
|
|
@@ -808,6 +818,28 @@ export type MachineConfig = (RemoteMachineConfig & {
|
|
|
808
818
|
arch: string;
|
|
809
819
|
environment: "local";
|
|
810
820
|
};
|
|
821
|
+
export interface PrivacyMode {
|
|
822
|
+
encrypt: boolean;
|
|
823
|
+
encryptKey?: string;
|
|
824
|
+
/**
|
|
825
|
+
* If true, the user messages will be redacted from the history.
|
|
826
|
+
*
|
|
827
|
+
* @default false
|
|
828
|
+
*/
|
|
829
|
+
redactUserMessages?: boolean;
|
|
830
|
+
/**
|
|
831
|
+
* If true, all the text messages from the LLM will be redacted.
|
|
832
|
+
*
|
|
833
|
+
* @default false
|
|
834
|
+
*/
|
|
835
|
+
redactLLMMessages?: boolean;
|
|
836
|
+
/**
|
|
837
|
+
* If true, the CLI will enable MCP servers during privacy mode.
|
|
838
|
+
*
|
|
839
|
+
* @default false
|
|
840
|
+
*/
|
|
841
|
+
mcpServers?: boolean;
|
|
842
|
+
}
|
|
811
843
|
export interface FusionConfig {
|
|
812
844
|
devCommand?: string;
|
|
813
845
|
checkCommand?: string;
|
|
@@ -828,16 +860,7 @@ export interface FusionConfig {
|
|
|
828
860
|
isLocal?: boolean;
|
|
829
861
|
envVariables?: Record<string, string>;
|
|
830
862
|
accessControl?: AclPolicy;
|
|
831
|
-
privacyMode?:
|
|
832
|
-
encrypt: boolean;
|
|
833
|
-
encryptKey?: string;
|
|
834
|
-
/**
|
|
835
|
-
* If true, the CLI will enable MCP servers during privacy mode.
|
|
836
|
-
*
|
|
837
|
-
* @default false
|
|
838
|
-
*/
|
|
839
|
-
mcpServers?: boolean;
|
|
840
|
-
};
|
|
863
|
+
privacyMode?: PrivacyMode;
|
|
841
864
|
repoIndexingConfig?: RepoIndexingConfig;
|
|
842
865
|
machine?: RemoteMachineConfig;
|
|
843
866
|
_attemptDryRunBackupGit?: boolean;
|
package/src/projects.d.ts
CHANGED
|
@@ -135,7 +135,7 @@ export interface ReadyMessage extends BaseMessage {
|
|
|
135
135
|
export type MachineState = "unknown" | "created" | "starting" | "started" | "stopping" | "stopped" | "suspending" | "suspended" | "replacing" | "destroying" | "destroyed" | "not-found" | "running" | "failed";
|
|
136
136
|
export type FlyVolumeState = "unknown" | "creating" | "created" | "extending" | "restoring" | "enabling_remote_export" | "hydrating" | "recovering" | "scheduling_destroy" | "pending_destroy" | "failed";
|
|
137
137
|
export type GitAuthErrorCode = "git-auth-failed" | "git-auth-failed-root-repo" | "git-auth-failed-folder-added-by" | "git-auth-failed-folder-created-by" | "git-auth-failed-folder-server-token" | "git-auth-failed-root-repo-server-token";
|
|
138
|
-
export type EnsureContainerErrorCode = "FLY_APP_CHECK_ERROR" | "FLY_CAPACITY_ERROR" | "FLY_PERMISSIONS_TOKEN_ERROR" | "FLY_VOLUME_CREATE_ERROR" | "FLY_VOLUME_FORK_ERROR" | "FLY_VOLUME_DELETE_RECENTLY_FORKED_ERROR" | "FLY_MACHINE_CREATE_ERROR" | "FLY_VOLUME_CHECK_ERROR" | "FLY_NON_MOUNTABLE_VOLUME_ERROR" | "FLY_DEPRECATED_REGION_ERROR" | "FLY_VOLUME_NOT_FOUND" | "ensure-checking-existing-machines" | "found-multiple-failed-machine" | "maximun-retries-machine-creation" | GitAuthErrorCode | "unknown" | "project-bad-state" | "project-not-found" | "project-branch-not-found" | "project-repo-full-name-not-found" | "project-org-not-found" | "no-available-regions" | "invalid-backup-without-volume-id" | "missing-app-with-machine-or-volume" | "update-branch-info-in-firebase" | "update-branch-app-name-in-firebase" | `machine-status-polling-${MachineState}` | `volume-not-found-${FlyVolumeState}` | "trying-to-remove-used-volume" | "timeout" | "fatal:zod-validation-error" | `fatal:${string}`;
|
|
138
|
+
export type EnsureContainerErrorCode = "FLY_APP_CHECK_ERROR" | "FLY_CAPACITY_ERROR" | "FLY_PERMISSIONS_TOKEN_ERROR" | "FLY_VOLUME_CREATE_ERROR" | "FLY_VOLUME_FORK_ERROR" | "FLY_VOLUME_DELETE_RECENTLY_FORKED_ERROR" | "FLY_MACHINE_CREATE_ERROR" | "FLY_VOLUME_CHECK_ERROR" | "FLY_NON_MOUNTABLE_VOLUME_ERROR" | "FLY_DEPRECATED_REGION_ERROR" | "FLY_VOLUME_NOT_FOUND" | "ensure-checking-existing-machines" | "found-multiple-failed-machine" | "maximun-retries-machine-creation" | GitAuthErrorCode | "unknown" | "project-bad-state" | "project-not-found" | "project-branch-not-found" | "project-branch-no-session-id" | "project-repo-full-name-not-found" | "project-org-not-found" | "no-available-regions" | "invalid-backup-without-volume-id" | "missing-app-with-machine-or-volume" | "update-branch-info-in-firebase" | "update-branch-app-name-in-firebase" | `machine-status-polling-${MachineState}` | `volume-not-found-${FlyVolumeState}` | "trying-to-remove-used-volume" | "timeout" | "fatal:zod-validation-error" | `fatal:${string}`;
|
|
139
139
|
export interface ErrorStateMessage extends BaseMessage {
|
|
140
140
|
state: "error";
|
|
141
141
|
message: string;
|
package/src/repo-indexing.d.ts
CHANGED
|
@@ -36,6 +36,7 @@ interface StoreComponentDocsInputV2 {
|
|
|
36
36
|
hash?: string;
|
|
37
37
|
designSystemId?: string;
|
|
38
38
|
}
|
|
39
|
+
export type DesignSystemScope = "space" | "organization" | "global";
|
|
39
40
|
export interface AddDesignSystemInput {
|
|
40
41
|
designSystemName: string;
|
|
41
42
|
designSystemPackage?: string;
|
|
@@ -43,6 +44,7 @@ export interface AddDesignSystemInput {
|
|
|
43
44
|
status: string;
|
|
44
45
|
spaceId: string;
|
|
45
46
|
rootOrgId: string;
|
|
47
|
+
scope: DesignSystemScope;
|
|
46
48
|
}
|
|
47
49
|
export interface UpdateDesignSystemInput {
|
|
48
50
|
id: string;
|
|
@@ -63,5 +65,6 @@ export interface DesignSystem {
|
|
|
63
65
|
designSystemVersion?: string;
|
|
64
66
|
designSystemPackage?: string;
|
|
65
67
|
status: "in-progress" | "completed" | "failed";
|
|
68
|
+
scope: DesignSystemScope;
|
|
66
69
|
}
|
|
67
70
|
export {};
|