@builder.io/ai-utils 0.4.39 → 0.5.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.4.39",
3
+ "version": "0.5.0",
4
4
  "description": "Builder.io AI utils",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
package/src/codegen.d.ts CHANGED
@@ -15,6 +15,7 @@ export interface ProjectFile {
15
15
  importance?: number;
16
16
  dropReason?: string;
17
17
  wasIncluded?: boolean;
18
+ virtual?: boolean;
18
19
  }
19
20
  export interface CustomInstruction {
20
21
  id: string;
@@ -111,6 +112,7 @@ export interface RevertToolInput {
111
112
  export interface TodoReadToolInput {
112
113
  }
113
114
  export interface TodoWriteToolInput {
115
+ mode: "replace" | "patch";
114
116
  todos: {
115
117
  content: string;
116
118
  status: "pending" | "in_progress" | "completed";
@@ -522,12 +524,19 @@ export interface UserSourceGitlab {
522
524
  role: "user" | "agent";
523
525
  principals?: string[];
524
526
  }
527
+ export interface UserSourceAzure {
528
+ source: "azure";
529
+ userName: string;
530
+ link?: string;
531
+ role: "user" | "agent";
532
+ principals?: string[];
533
+ }
525
534
  export interface UserSourceAgent {
526
535
  source: "agent";
527
536
  role: "agent";
528
537
  principals?: string[];
529
538
  }
530
- export type UserSource = UserSourceBuilder | UserSourceGithub | UserSourceGitlab | UserSourceAgent;
539
+ export type UserSource = UserSourceBuilder | UserSourceGithub | UserSourceGitlab | UserSourceAzure | UserSourceAgent;
531
540
  export interface GenerateUserMessage {
532
541
  user?: UserSource;
533
542
  userPrompt: string;
package/src/index.d.ts CHANGED
@@ -5,3 +5,4 @@ export * from "./settings.js";
5
5
  export * from "./mapping.js";
6
6
  export * from "./codegen.js";
7
7
  export * from "./projects.js";
8
+ export * from "./repo-indexing.js";
package/src/index.js CHANGED
@@ -5,3 +5,4 @@ export * from "./settings.js";
5
5
  export * from "./mapping.js";
6
6
  export * from "./codegen.js";
7
7
  export * from "./projects.js";
8
+ export * from "./repo-indexing.js";
package/src/projects.d.ts CHANGED
@@ -132,7 +132,10 @@ export interface ReadyMessage extends BaseMessage {
132
132
  url: string;
133
133
  status?: LaunchServerStatus;
134
134
  }
135
- export type EnsureContainerErrorCode = "FLY_APP_CHECK_ERROR" | "FLY_CAPACITY_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" | "ensure-checking-existing-machines" | "found-multiple-failed-machine" | "maximun-retries-machine-creation" | "git-auth-failed" | "unknown" | "project-bad-state" | "project-not-found" | "project-branch-not-found" | "project-repo-full-name-not-found" | "project-org-not-found" | "no-available-regions" | "machine-status-polling-failed" | "timeout" | "fatal:zod-validation-error" | `fatal:${string}`;
135
+ export type MachineState = "unknown" | "created" | "starting" | "started" | "stopping" | "stopped" | "suspending" | "suspended" | "replacing" | "destroying" | "destroyed" | "not-found" | "running" | "failed";
136
+ export type FlyVolumeState = "unknown" | "creating" | "created" | "extending" | "restoring" | "enabling_remote_export" | "hydrating" | "recovering" | "scheduling_destroy" | "pending_destroy" | "failed";
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";
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" | "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" | `machine-status-polling-${MachineState}` | `volume-not-found-${FlyVolumeState}` | "timeout" | "fatal:zod-validation-error" | `fatal:${string}`;
136
139
  export interface ErrorStateMessage extends BaseMessage {
137
140
  state: "error";
138
141
  message: string;
@@ -149,7 +152,7 @@ export interface CleanupCompletedMessage extends BaseMessage {
149
152
  export type ProjectsChunkMessage = InitializingMessage | FetchingGithubTokenMessage | FetchingFusionKeyMessage | CheckingAppMessage | CleaningUpAppMessage | CreatingAppMessage | CheckingIPMessage | AllocatingIPMessage | CheckingMachineMessage | CheckingVolumeMessage | ForkingVolumeMessage | RetryingWithNewRegionMessage | WaitingBeforePollingMessage | PollingMachineStatusMessage | WarningStateMessage | PingMessage | DebugMessage | ErrorMessage | InfoMessage | WarningMessage | MachineStatusMessage | LogsMessage | ConfigStatusMessage | AppCreatedMessage | MachineCreatedMessage | IpAllocatedMessage | VolumeForkedMessage | ReadyMessage | ErrorStateMessage | CleanupCompletedMessage;
150
153
  export type GitConfig = {
151
154
  url: string;
152
- provider: "github" | "bitbucket" | "gitlab";
155
+ provider: "github" | "bitbucket" | "gitlab" | "azure";
153
156
  };
154
157
  export type GitConfigs = Record<string, GitConfig>;
155
158
  export declare const EXAMPLE_REPOS: string[];
@@ -0,0 +1,11 @@
1
+ export interface StoreComponentDocsInput {
2
+ description: string;
3
+ name: string;
4
+ relatedComponents: string[];
5
+ relevantFiles: string[];
6
+ content: string;
7
+ sessionId: string;
8
+ designSystemPackage?: string;
9
+ designSystemVersion?: string;
10
+ hash?: string;
11
+ }
@@ -0,0 +1 @@
1
+ export {};