@builder.io/ai-utils 0.52.0 → 0.53.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 +4 -1
- package/src/codegen.d.ts +30 -1
- package/src/codegen.js +5 -0
- package/src/organization.d.ts +2 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@builder.io/ai-utils",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.53.0",
|
|
4
4
|
"description": "Builder.io AI utils",
|
|
5
5
|
"files": [
|
|
6
6
|
"src"
|
|
@@ -21,5 +21,8 @@
|
|
|
21
21
|
"types": "./src/connectivity/browser.d.ts",
|
|
22
22
|
"import": "./src/connectivity/browser.js"
|
|
23
23
|
}
|
|
24
|
+
},
|
|
25
|
+
"dependencies": {
|
|
26
|
+
"zod": "^4.4.3"
|
|
24
27
|
}
|
|
25
28
|
}
|
package/src/codegen.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
1
2
|
import type { Attachment, ContentMessageItemToolResult } from "./messages";
|
|
2
3
|
import type { BuilderContent } from "./completion";
|
|
3
4
|
import type { Options as PrettierOptions } from "prettier";
|
|
@@ -36,7 +37,13 @@ export interface CustomInstruction {
|
|
|
36
37
|
userInvocable?: boolean;
|
|
37
38
|
}
|
|
38
39
|
/** Reasoning effort level for LLM completions. */
|
|
39
|
-
export
|
|
40
|
+
export declare const ReasoningEffortSchema: z.ZodEnum<{
|
|
41
|
+
low: "low";
|
|
42
|
+
medium: "medium";
|
|
43
|
+
high: "high";
|
|
44
|
+
minimal: "minimal";
|
|
45
|
+
}>;
|
|
46
|
+
export type ReasoningEffort = z.infer<typeof ReasoningEffortSchema>;
|
|
40
47
|
export interface CustomAgentInfo {
|
|
41
48
|
name: string;
|
|
42
49
|
description?: string;
|
|
@@ -652,6 +659,16 @@ export interface SendMessageToolInput {
|
|
|
652
659
|
* Default to false (text) for all text-originated messages.
|
|
653
660
|
*/
|
|
654
661
|
voice_response?: boolean;
|
|
662
|
+
/**
|
|
663
|
+
* Builder.io user ID this message is from / should be attributed to. Only
|
|
664
|
+
* allowed when channel_id is 'builder/branch/{project_id}/{branch_name}'.
|
|
665
|
+
* When set, the message is delivered to the target branch as coming from
|
|
666
|
+
* this user (role 'user') instead of from the agent. Use whenever the
|
|
667
|
+
* message represents user feedback/intent that should be assigned to
|
|
668
|
+
* someone — even if it was composed, summarized, or merged from multiple
|
|
669
|
+
* people.
|
|
670
|
+
*/
|
|
671
|
+
from_user_id?: string;
|
|
655
672
|
}
|
|
656
673
|
export interface SpawnBranchToolInput {
|
|
657
674
|
project_id: string;
|
|
@@ -662,6 +679,7 @@ export interface SpawnBranchToolInput {
|
|
|
662
679
|
session_mode?: "normal" | "planning" | "deep-research";
|
|
663
680
|
model?: "auto" | "opus" | "sonnet" | "haiku";
|
|
664
681
|
attachment_urls?: string[];
|
|
682
|
+
git_base_branch?: string;
|
|
665
683
|
}
|
|
666
684
|
export interface CreateProjectToolInput {
|
|
667
685
|
repo_url: string;
|
|
@@ -2077,6 +2095,7 @@ export interface InitState {
|
|
|
2077
2095
|
}[];
|
|
2078
2096
|
}
|
|
2079
2097
|
export type LaunchServerState = "initial" | "init-running" | "init-complete" | "ready" | "active-session" | "init-error" | "session-error" | "error" | "closing";
|
|
2098
|
+
export type LaunchServerPhase = "state-created" | "server-starting" | "server-error" | "server-listening" | "dev-server-configured" | "dev-server-error" | "setup-command-waiting" | "setup-command-error" | "launch-server-setup" | "websocket-ready" | "state-ready" | "editor-url-building" | "editor-url-ready" | "editor-ready" | "launch-error";
|
|
2080
2099
|
export interface LaunchServerStatus {
|
|
2081
2100
|
status: "ok";
|
|
2082
2101
|
state: LaunchServerState;
|
|
@@ -2085,12 +2104,17 @@ export interface LaunchServerStatus {
|
|
|
2085
2104
|
isFinalState: boolean;
|
|
2086
2105
|
httpServerState?: HttpServerState;
|
|
2087
2106
|
editorReady: boolean;
|
|
2107
|
+
editorReadyAt?: number;
|
|
2108
|
+
editorReadySource?: string;
|
|
2088
2109
|
initState?: InitState;
|
|
2089
2110
|
initStatusLogs?: InitStatusLog[];
|
|
2090
2111
|
errorMessage?: string;
|
|
2091
2112
|
devToolsVersion: string;
|
|
2092
2113
|
lastRequestTime: number;
|
|
2093
2114
|
startTime: number;
|
|
2115
|
+
processId: number;
|
|
2116
|
+
launchPhase?: LaunchServerPhase;
|
|
2117
|
+
launchPhaseUpdatedAt?: number;
|
|
2094
2118
|
machine?: MachineConfig;
|
|
2095
2119
|
projectId?: string;
|
|
2096
2120
|
detectedServerUrl?: string;
|
|
@@ -2126,12 +2150,17 @@ export interface FusionStatus {
|
|
|
2126
2150
|
setupState: SetupCommandState | undefined;
|
|
2127
2151
|
devState: DevCommandState | undefined;
|
|
2128
2152
|
editorReady: boolean;
|
|
2153
|
+
editorReadyAt: number | undefined;
|
|
2154
|
+
editorReadySource: string | undefined;
|
|
2129
2155
|
httpServerState: HttpServerState | undefined;
|
|
2130
2156
|
initState: InitState | undefined;
|
|
2131
2157
|
errorMessage: string | undefined;
|
|
2132
2158
|
devToolsVersion: string;
|
|
2133
2159
|
idleTime: number;
|
|
2134
2160
|
upTime: number;
|
|
2161
|
+
processId: number;
|
|
2162
|
+
launchPhase: LaunchServerPhase | undefined;
|
|
2163
|
+
launchPhaseUpdatedAt: number | undefined;
|
|
2135
2164
|
machine: MachineConfig | undefined;
|
|
2136
2165
|
projectId: string | undefined;
|
|
2137
2166
|
detectedServerUrl: string | undefined;
|
package/src/codegen.js
CHANGED
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
/** Reasoning effort level for LLM completions. */
|
|
3
|
+
export const ReasoningEffortSchema = z
|
|
4
|
+
.enum(["low", "medium", "high", "minimal"])
|
|
5
|
+
.meta({ title: "ReasoningEffort" });
|
|
1
6
|
export const BASE_CODEGEN_POSITIONS = [
|
|
2
7
|
"fusion",
|
|
3
8
|
"editor-ai",
|
package/src/organization.d.ts
CHANGED
|
@@ -84,6 +84,8 @@ interface OrganizationSettings {
|
|
|
84
84
|
fusionShareableUrlSuffix?: string;
|
|
85
85
|
autoDetectDevServerPatterns?: string[];
|
|
86
86
|
environmentVariables?: EnvironmentVariable[];
|
|
87
|
+
projectsUseGithubServerToken?: boolean;
|
|
88
|
+
prAuthoringMode?: "" | "prefer-user" | "always-bot" | "always-user";
|
|
87
89
|
fusionPrLabel?: string;
|
|
88
90
|
fusionPrQuietMode?: boolean;
|
|
89
91
|
runInPty?: boolean;
|