@builder.io/ai-utils 0.19.1 → 0.20.0

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.19.1",
3
+ "version": "0.20.0",
4
4
  "description": "Builder.io AI utils",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
package/src/codegen.d.ts CHANGED
@@ -965,7 +965,7 @@ export interface GenerateUserMessage {
965
965
  includeRelevantMemories?: boolean;
966
966
  category?: CodeGenCategory;
967
967
  metadata?: Record<string, any>;
968
- autoPush?: "force-push" | "merge-push" | "ff-push" | "none";
968
+ autoPush?: "force-push" | "merge-push" | "ff-push" | "safe-push" | "none";
969
969
  syncChanges?: SyncChangesFromRemote;
970
970
  enabledMCPs?: string[];
971
971
  sessionMode?: SessionMode;
@@ -1601,6 +1601,10 @@ export interface PushChangesOptions {
1601
1601
  };
1602
1602
  /** If specified, only push changes for this folder (multi-repo support) */
1603
1603
  folderName?: string;
1604
+ /** If true, abort and clean up if merge conflict is detected during pull */
1605
+ abortOnMergeConflict?: boolean;
1606
+ /** If true, verify fast-forward is possible before pushing, fail if not */
1607
+ requireFastForward?: boolean;
1604
1608
  }
1605
1609
  export interface SyncChangesFromRemote {
1606
1610
  remoteBranches?: "both" | "main" | "ai";
@@ -1854,3 +1858,27 @@ export interface LaunchInitializeSessionOptions {
1854
1858
  customInstructions?: CustomInstruction[];
1855
1859
  privacyMode?: PrivacyMode;
1856
1860
  }
1861
+ /**
1862
+ * Request for generating a commit message via LLM
1863
+ */
1864
+ export interface CommitMessageRequest {
1865
+ /** Git diff from previous commit */
1866
+ diff: string;
1867
+ /** User messages sent during AI work */
1868
+ userMessages: string[];
1869
+ /** Last 10 commits from main branch for style reference */
1870
+ recentCommits: string[];
1871
+ /** Whether to generate a long commit message */
1872
+ longCommit?: boolean;
1873
+ }
1874
+ /**
1875
+ * Response from commit message generation
1876
+ */
1877
+ export interface CommitMessageResponse {
1878
+ /** Full commit message */
1879
+ message: string;
1880
+ /** First line (50-72 chars) - the commit title */
1881
+ title: string;
1882
+ /** Optional extended description */
1883
+ body?: string;
1884
+ }
package/src/projects.d.ts CHANGED
@@ -272,7 +272,7 @@ export type FusionExecutionEnvironment = "containerized" | "container-less" | "c
272
272
  export interface PartialBranchData {
273
273
  name?: string;
274
274
  createdBy: string;
275
- friendlyName: string;
275
+ friendlyName?: string;
276
276
  isDefault: boolean;
277
277
  isPublic: boolean;
278
278
  lockedFusionEnvironment?: FusionExecutionEnvironment;
@@ -323,6 +323,13 @@ export interface BranchMetadata {
323
323
  [key: string]: unknown;
324
324
  }
325
325
  export type PRStatus = "open" | "closed" | "merged" | "draft" | "approved";
326
+ export interface BranchReview {
327
+ userId: string;
328
+ status: "approved" | "changes_requested" | "commented" | "pending";
329
+ comment?: string | null;
330
+ createdAt: number;
331
+ updatedAt: number;
332
+ }
326
333
  interface BranchSharedData {
327
334
  appName?: string | null;
328
335
  prNumber?: number | null;
@@ -348,6 +355,8 @@ interface BranchSharedData {
348
355
  friendlyName?: string;
349
356
  useHomeDir?: boolean;
350
357
  useCloudHomeDir?: boolean;
358
+ reviewers?: string[] | null;
359
+ reviews?: BranchReview[] | null;
351
360
  ipv4?: {
352
361
  address: string | null;
353
362
  allocated: boolean | null;