@builder.io/ai-utils 0.18.1 → 0.18.2

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.18.1",
3
+ "version": "0.18.2",
4
4
  "description": "Builder.io AI utils",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
package/src/codegen.d.ts CHANGED
@@ -676,6 +676,7 @@ export interface GenerateCompletionStepDevServerState {
676
676
  }
677
677
  export interface GenerateCompletionStepGit {
678
678
  type: "git";
679
+ folderName?: string;
679
680
  isSessionDirty: boolean;
680
681
  hasGeneratingPlaceholder: boolean;
681
682
  remoteBranchExists: boolean;
@@ -1080,6 +1081,43 @@ export interface WorkspaceConfiguration {
1080
1081
  agentsMD?: string;
1081
1082
  folders: WorkspaceFolder[];
1082
1083
  }
1084
+ /**
1085
+ * Runtime context for a git-enabled repository.
1086
+ * Used to track multiple git working directories in codegen.
1087
+ */
1088
+ export interface GitRepoContext {
1089
+ /** Folder name from WorkspaceFolder */
1090
+ folderName: string;
1091
+ /** Absolute path to the repository */
1092
+ path: string;
1093
+ /** Feature branch name */
1094
+ branchName: string;
1095
+ /** Original repo URL */
1096
+ repoUrl?: string;
1097
+ /** Repo name (e.g., owner/repo) */
1098
+ repoName?: string;
1099
+ /**
1100
+ * Initial commit when first checked
1101
+ */
1102
+ initialCommit?: string;
1103
+ }
1104
+ /**
1105
+ * Result from a multi-repo git operation.
1106
+ */
1107
+ export interface MultiRepoOperationResult<T = unknown> {
1108
+ /** True if all repos succeeded */
1109
+ success: boolean;
1110
+ /** True if some succeeded and some failed */
1111
+ partialSuccess: boolean;
1112
+ /** Per-repo results */
1113
+ results: Array<{
1114
+ folderName: string;
1115
+ success: boolean;
1116
+ result?: T;
1117
+ error?: Error;
1118
+ message?: string;
1119
+ }>;
1120
+ }
1083
1121
  export type Permission = "read" | "write" | "list";
1084
1122
  export interface AclEntry {
1085
1123
  action: "allow" | "deny";
@@ -1424,6 +1462,8 @@ export interface PushChangesOptions {
1424
1462
  repoFullName: string;
1425
1463
  repoUrl: string;
1426
1464
  };
1465
+ /** If specified, only push changes for this folder (multi-repo support) */
1466
+ folderName?: string;
1427
1467
  }
1428
1468
  export interface SyncChangesFromRemote {
1429
1469
  remoteBranches?: "both" | "main" | "ai";
package/src/projects.d.ts CHANGED
@@ -292,6 +292,13 @@ export interface PartialBranchData {
292
292
  };
293
293
  }
294
294
  export type EntityState = "active" | "deleted" | "archived";
295
+ /**
296
+ * PR information for a single repository
297
+ */
298
+ export interface PrInfo {
299
+ prNumber: number;
300
+ prUrl: string;
301
+ }
295
302
  /**
296
303
  * Metadata stored in branches for integration tracking and PR description generation.
297
304
  * This type documents the integration context that can be attached to a branch.
@@ -320,6 +327,7 @@ interface BranchSharedData {
320
327
  appName?: string | null;
321
328
  prNumber?: number | null;
322
329
  prUrl?: string | null;
330
+ prInfoByFolder?: Record<string, PrInfo> | null;
323
331
  prStatus?: PRStatus;
324
332
  machineId?: string | null;
325
333
  lastMachineIdRemovedAt?: number | null;
@@ -499,6 +507,7 @@ export interface Project {
499
507
  addedBy?: string;
500
508
  repoProvider?: string;
501
509
  repoProtocol?: string;
510
+ enableGit?: boolean;
502
511
  }>;
503
512
  agentsMD?: string;
504
513
  initializationCommand?: string;