@crewx/sdk 0.9.0-rc.180 → 0.9.0-rc.182
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/dist/agent-interceptor/schema.d.ts +12 -12
- package/dist/app/app-files/index.d.ts +3 -2
- package/dist/app/app-files/store.d.ts +1 -0
- package/dist/app/app.d.ts +1 -0
- package/dist/app/index.d.ts +1 -1
- package/dist/app/index.js +12 -12
- package/dist/config/models.generated.d.ts +2 -2
- package/dist/config/pricing.generated.d.ts +2 -2
- package/dist/esm/app/index.js +12 -12
- package/dist/esm/index.js +307 -286
- package/dist/esm/plugins/index.js +107 -106
- package/dist/esm/publish/index.js +2 -2
- package/dist/esm/repository/index.js +182 -167
- package/dist/esm/skills/index.js +2 -2
- package/dist/esm/testing/index.js +1 -1
- package/dist/events/types.d.ts +1 -0
- package/dist/index.browser.js +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.js +305 -284
- package/dist/mcp-app/agent-access.d.ts +8 -1
- package/dist/mcp-app/index.d.ts +1 -0
- package/dist/mcp-app/view-call.d.ts +7 -0
- package/dist/mcp-app/workspace-snapshot.d.ts +2 -1
- package/dist/plugins/index.js +107 -106
- package/dist/provider/bridge.browser.d.ts +2 -0
- package/dist/provider/bridge.d.ts +4 -0
- package/dist/provider/cli/adapter.types.d.ts +2 -0
- package/dist/provider/cli/adapters/antigravity-stream.d.ts +27 -0
- package/dist/publish/index.js +2 -2
- package/dist/repository/index.js +180 -165
- package/dist/repository/task.repository.d.ts +2 -0
- package/dist/repository/usage-backfill.d.ts +2 -2
- package/dist/repository/usage-from-logs.d.ts +1 -0
- package/dist/skills/index.js +2 -2
- package/dist/testing/index.js +1 -1
- package/dist/ui-instance/index.d.ts +2 -2
- package/dist/ui-instance/store.d.ts +4 -1
- package/dist/ui-instance/types.d.ts +39 -0
- package/dist/ui-plugin/app-manifest.d.ts +1 -1
- package/package.json +1 -1
|
@@ -5,6 +5,7 @@ export interface ProviderUsage {
|
|
|
5
5
|
outputTokens: number;
|
|
6
6
|
cachedInputTokens: number;
|
|
7
7
|
costUsd: number;
|
|
8
|
+
complete?: boolean;
|
|
8
9
|
}
|
|
9
10
|
export interface ProviderQueryOptions {
|
|
10
11
|
model?: string;
|
|
@@ -12,6 +13,7 @@ export interface ProviderQueryOptions {
|
|
|
12
13
|
systemPrompt?: string;
|
|
13
14
|
additionalArgs?: string[];
|
|
14
15
|
onOutput?: (line: string, level: 'stdout' | 'stderr') => void;
|
|
16
|
+
onSpawn?: () => void;
|
|
15
17
|
onPid?: (pid: number) => void;
|
|
16
18
|
onCommand?: (command: string) => void;
|
|
17
19
|
onUsage?: (usage: ProviderUsage) => void;
|
|
@@ -8,11 +8,13 @@ export interface RunCliProcessOptions {
|
|
|
8
8
|
timeoutMs?: number;
|
|
9
9
|
idleMs?: number;
|
|
10
10
|
resumeSessionId?: string;
|
|
11
|
+
onProviderSessionId?: (id: string) => void;
|
|
11
12
|
env?: Record<string, string>;
|
|
12
13
|
unsetEnv?: readonly string[];
|
|
13
14
|
cwd?: string;
|
|
14
15
|
onOutput?: (line: string, level: 'stdout' | 'stderr') => void;
|
|
15
16
|
onRateLimitObserved?: (windows: ProviderRateLimitWindows) => void;
|
|
17
|
+
onSpawn?: () => void;
|
|
16
18
|
onPid?: (pid: number) => void;
|
|
17
19
|
onExitCode?: (code: number) => void;
|
|
18
20
|
onUsage?: (usage: ProviderUsage) => void;
|
|
@@ -53,6 +55,7 @@ export interface ProviderUsage {
|
|
|
53
55
|
outputTokens: number;
|
|
54
56
|
cachedInputTokens: number;
|
|
55
57
|
costUsd: number;
|
|
58
|
+
complete?: boolean;
|
|
56
59
|
}
|
|
57
60
|
export interface ProviderQueryOptions {
|
|
58
61
|
model?: string;
|
|
@@ -65,6 +68,7 @@ export interface ProviderQueryOptions {
|
|
|
65
68
|
resumeSessionId?: string;
|
|
66
69
|
providerSessionId?: string;
|
|
67
70
|
onProviderSessionId?: (id: string) => void;
|
|
71
|
+
onSpawn?: () => void;
|
|
68
72
|
onOutput?: (line: string, level: 'stdout' | 'stderr') => void;
|
|
69
73
|
onPid?: (pid: number) => void;
|
|
70
74
|
onCommand?: (command: string) => void;
|
|
@@ -9,6 +9,7 @@ export interface ParseEventContext {
|
|
|
9
9
|
export interface CliProviderAdapter {
|
|
10
10
|
readonly command: string;
|
|
11
11
|
createSessionId?(): string;
|
|
12
|
+
extractSessionId?(line: string): string | null;
|
|
12
13
|
readonly meta?: {
|
|
13
14
|
displayName?: string;
|
|
14
15
|
models?: Array<{
|
|
@@ -30,6 +31,7 @@ export interface CliProviderAdapter {
|
|
|
30
31
|
audio?: boolean;
|
|
31
32
|
mcp?: boolean;
|
|
32
33
|
loadSession?: boolean;
|
|
34
|
+
usageCompleteness?: boolean;
|
|
33
35
|
};
|
|
34
36
|
};
|
|
35
37
|
buildArgs(message: string, options: ProviderQueryOptions, isExecute: boolean): {
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
type JsonRecord = Record<string, unknown>;
|
|
2
|
+
export type AntigravityStreamEvent = {
|
|
3
|
+
kind: 'init';
|
|
4
|
+
envelope: JsonRecord;
|
|
5
|
+
init: JsonRecord;
|
|
6
|
+
} | {
|
|
7
|
+
kind: 'step_update';
|
|
8
|
+
envelope: JsonRecord;
|
|
9
|
+
step: JsonRecord;
|
|
10
|
+
} | {
|
|
11
|
+
kind: 'result';
|
|
12
|
+
envelope: JsonRecord;
|
|
13
|
+
result: JsonRecord;
|
|
14
|
+
} | {
|
|
15
|
+
kind: 'legacy_result';
|
|
16
|
+
envelope: JsonRecord;
|
|
17
|
+
result: JsonRecord;
|
|
18
|
+
} | {
|
|
19
|
+
kind: 'agy_error';
|
|
20
|
+
envelope: JsonRecord;
|
|
21
|
+
error: unknown;
|
|
22
|
+
};
|
|
23
|
+
export declare function parseAntigravityLine(line: string): AntigravityStreamEvent | undefined;
|
|
24
|
+
export declare function isAntigravityProtocolLine(line: string): boolean;
|
|
25
|
+
export declare function isAntigravityMetadataOnlyLine(line: string): boolean;
|
|
26
|
+
export declare function parseAntigravityStream(stdout: string): AntigravityStreamEvent[];
|
|
27
|
+
export {};
|