@builder.io/ai-utils 0.5.13 → 0.5.15

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@builder.io/ai-utils",
3
- "version": "0.5.13",
3
+ "version": "0.5.15",
4
4
  "description": "Builder.io AI utils",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
package/src/codegen.d.ts CHANGED
@@ -2,12 +2,6 @@ import type { Attachment, ContentMessageItemToolResult } from "./messages";
2
2
  import type { BuilderContent } from "./completion";
3
3
  import type { Options as PrettierOptions } from "prettier";
4
4
  import type { UserContext } from "./mapping";
5
- export interface LoadingState {
6
- type: "tool_start" | "tool_end";
7
- toolName?: string;
8
- toolId?: string;
9
- description?: string;
10
- }
11
5
  export type ImportType = "named" | "default";
12
6
  export interface ESMImport {
13
7
  importName: string;
@@ -596,6 +590,7 @@ export interface UserInput {
596
590
  mostRelevantFile: string | null;
597
591
  toolResults: ContentMessageItemToolResult[];
598
592
  user: UserSource;
593
+ patchFusionConfig?: Partial<FusionConfig> | undefined;
599
594
  }
600
595
  export interface CodegenTurn {
601
596
  state: "running" | "done" | "error";
@@ -700,21 +695,12 @@ export interface GenerateCodeEventMCPStatus {
700
695
  type: "mcp-status";
701
696
  status: Record<string, MCPClientStatus>;
702
697
  }
703
- export type GenerateCodeEvent = ActionItem | GenerateCodeEventDone | GenerateCodeEventContinue | GenerateCodeEventPagination | GenerateCodeEventDelta | GenerateCodeEventError | GenerateCodeEventPing | GenerateCodeEventMCPStatus | GenerateCodeEventUser | GenerateCodeEventEditorAILoadingState;
704
- export interface GenerateCodeEventEditorAILoadingState {
705
- type: "loading_state";
706
- loadingState: LoadingState;
707
- content?: string;
708
- actionTitle?: string;
709
- artifactTitle?: string;
710
- filePath?: string;
711
- }
698
+ export type GenerateCodeEvent = ActionItem | GenerateCodeEventDone | GenerateCodeEventContinue | GenerateCodeEventPagination | GenerateCodeEventDelta | GenerateCodeEventError | GenerateCodeEventPing | GenerateCodeEventMCPStatus | GenerateCodeEventUser;
712
699
  export type CommitMode = "commits" | "draft-prs" | "prs";
713
700
  export interface GitBackupDownloadUrlResult {
714
701
  signedUrl: string;
715
702
  filePath: string;
716
703
  expiresAt: string;
717
- exists: boolean;
718
704
  partial: boolean;
719
705
  }
720
706
  export interface BranchBackup {
@@ -725,7 +711,8 @@ export interface BranchBackup {
725
711
  lastCommitHash: string;
726
712
  partial: boolean;
727
713
  status: "initiated" | "completed";
728
- contentMd5: string;
714
+ contentMd5?: string;
715
+ empty?: boolean;
729
716
  }
730
717
  export interface CheckBackupDataResultValid {
731
718
  hasValidBackup: true;
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" | "update-branch-info-in-firebase" | "update-branch-app-name-in-firebase" | `machine-status-polling-${MachineState}` | `volume-not-found-${FlyVolumeState}` | "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-repo-full-name-not-found" | "project-org-not-found" | "no-available-regions" | "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}` | "timeout" | "fatal:zod-validation-error" | `fatal:${string}`;
139
139
  export interface ErrorStateMessage extends BaseMessage {
140
140
  state: "error";
141
141
  message: string;
@@ -185,8 +185,9 @@ export interface GitBackupRecordOptions {
185
185
  initialCommitHash: string;
186
186
  lastCommitHash: string;
187
187
  partial: boolean;
188
- status: "initiated" | "completed";
189
- contentMd5: string;
188
+ empty: boolean;
189
+ status: "completed";
190
+ contentMd5?: string;
190
191
  }
191
192
  export interface GitBackupRecordResult {
192
193
  success: boolean;