cascade-ai 0.2.2 → 0.2.12
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/README.md +33 -0
- package/dist/cli.cjs +1222 -375
- package/dist/cli.cjs.map +1 -1
- package/dist/cli.js +1222 -375
- package/dist/cli.js.map +1 -1
- package/dist/index.cjs +1100 -332
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +72 -5
- package/dist/index.d.ts +72 -5
- package/dist/index.js +1099 -333
- package/dist/index.js.map +1 -1
- package/package.json +9 -6
package/dist/index.d.cts
CHANGED
|
@@ -84,6 +84,12 @@ interface ToolDefinition {
|
|
|
84
84
|
description: string;
|
|
85
85
|
inputSchema: Record<string, unknown>;
|
|
86
86
|
}
|
|
87
|
+
interface WebSearchConfig {
|
|
88
|
+
searxngUrl?: string;
|
|
89
|
+
braveApiKey?: string;
|
|
90
|
+
tavilyApiKey?: string;
|
|
91
|
+
maxResults?: number;
|
|
92
|
+
}
|
|
87
93
|
interface Message {
|
|
88
94
|
id: string;
|
|
89
95
|
role: 'user' | 'assistant' | 'error' | 'system';
|
|
@@ -141,6 +147,7 @@ interface T1ToT2Assignment {
|
|
|
141
147
|
constraints: string[];
|
|
142
148
|
t3Subtasks: T3SubtaskSpec[];
|
|
143
149
|
executionMode?: 'parallel' | 'sequential';
|
|
150
|
+
dependsOn?: string[];
|
|
144
151
|
peerT2Ids?: string[];
|
|
145
152
|
}
|
|
146
153
|
interface T3SubtaskSpec {
|
|
@@ -346,6 +353,8 @@ interface ToolsConfig {
|
|
|
346
353
|
* approval before they are spawned.
|
|
347
354
|
*/
|
|
348
355
|
mcpTrusted?: string[];
|
|
356
|
+
/** Web search backends — at least one should be configured for best results */
|
|
357
|
+
webSearch?: WebSearchConfig;
|
|
349
358
|
}
|
|
350
359
|
interface HooksConfig {
|
|
351
360
|
preToolUse?: HookDefinition[];
|
|
@@ -512,6 +521,19 @@ interface CascadeRunOptions {
|
|
|
512
521
|
approved: boolean;
|
|
513
522
|
always: boolean;
|
|
514
523
|
}>;
|
|
524
|
+
/**
|
|
525
|
+
* An optional `AbortSignal` to cancel the run mid-execution.
|
|
526
|
+
* When aborted, all tiers (T1 → T2 → T3) stop at the next safe checkpoint
|
|
527
|
+
* and a `run:cancelled` event is emitted on the Cascade instance.
|
|
528
|
+
* The `run()` call resolves (not rejects) with a partial result.
|
|
529
|
+
*
|
|
530
|
+
* @example
|
|
531
|
+
* const controller = new AbortController();
|
|
532
|
+
* cascade.run({ prompt: '...', signal: controller.signal });
|
|
533
|
+
* // later:
|
|
534
|
+
* controller.abort();
|
|
535
|
+
*/
|
|
536
|
+
signal?: AbortSignal;
|
|
515
537
|
}
|
|
516
538
|
interface CascadeRunResult {
|
|
517
539
|
output: string;
|
|
@@ -698,7 +720,14 @@ interface McpClientOptions {
|
|
|
698
720
|
approvalCallback?: McpApprovalCallback;
|
|
699
721
|
}
|
|
700
722
|
declare class McpClient {
|
|
723
|
+
private static activeProcessPids;
|
|
724
|
+
/**
|
|
725
|
+
* Forcefully kills all known MCP child processes.
|
|
726
|
+
* Call this from global process exit handlers to prevent zombie processes.
|
|
727
|
+
*/
|
|
728
|
+
static killAllProcesses(): void;
|
|
701
729
|
private clients;
|
|
730
|
+
private transports;
|
|
702
731
|
private tools;
|
|
703
732
|
private trustedServers;
|
|
704
733
|
private approvalCallback;
|
|
@@ -709,6 +738,7 @@ declare class McpClient {
|
|
|
709
738
|
callTool(serverName: string, toolName: string, input: Record<string, unknown>): Promise<string>;
|
|
710
739
|
getToolDefinitions(): ToolDefinition[];
|
|
711
740
|
getConnectedServers(): string[];
|
|
741
|
+
getActivePids(): number[];
|
|
712
742
|
isConnected(serverName: string): boolean;
|
|
713
743
|
}
|
|
714
744
|
|
|
@@ -772,6 +802,10 @@ declare class ToolRegistry {
|
|
|
772
802
|
declare class MemoryStore {
|
|
773
803
|
private db;
|
|
774
804
|
constructor(dbPath: string);
|
|
805
|
+
private writeQueue;
|
|
806
|
+
private isProcessingQueue;
|
|
807
|
+
private processQueue;
|
|
808
|
+
private enqueueWrite;
|
|
775
809
|
createSession(session: Session): void;
|
|
776
810
|
updateSession(id: string, updates: Partial<Session>): void;
|
|
777
811
|
getSession(id: string): Session | null;
|
|
@@ -881,6 +915,8 @@ declare abstract class BaseTier extends EventEmitter {
|
|
|
881
915
|
protected label: string;
|
|
882
916
|
protected systemPromptOverride: string;
|
|
883
917
|
protected hierarchyContext: string;
|
|
918
|
+
/** Propagated AbortSignal — set by the tier's `execute()` before work begins. */
|
|
919
|
+
protected signal?: AbortSignal;
|
|
884
920
|
constructor(role: TierRole, id?: string, parentId?: string);
|
|
885
921
|
getStatus(): TierStatus;
|
|
886
922
|
protected setStatus(status: TierStatus): void;
|
|
@@ -890,6 +926,12 @@ declare abstract class BaseTier extends EventEmitter {
|
|
|
890
926
|
protected sendStatusUpdate(update: StatusUpdate): void;
|
|
891
927
|
protected buildMessage(type: CascadeMessage['type'], to: string, payload: Record<string, unknown>): CascadeMessage;
|
|
892
928
|
protected log(message: string, data?: unknown): void;
|
|
929
|
+
/**
|
|
930
|
+
* Throws `CascadeCancelledError` if the run's `AbortSignal` has fired.
|
|
931
|
+
* Call this at safe checkpoints (before LLM calls, between T3 dispatches)
|
|
932
|
+
* to provide a fast, clean cancellation path.
|
|
933
|
+
*/
|
|
934
|
+
protected throwIfCancelled(): void;
|
|
893
935
|
}
|
|
894
936
|
|
|
895
937
|
type T2Evaluator = (req: PermissionRequest) => Promise<PermissionDecision | null>;
|
|
@@ -968,17 +1010,22 @@ declare class T1Administrator extends BaseTier {
|
|
|
968
1010
|
*/
|
|
969
1011
|
setPermissionEscalator(escalator: PermissionEscalator): void;
|
|
970
1012
|
setToolCreator(creator: ToolCreator): void;
|
|
971
|
-
execute(userPrompt: string, images?: ImageAttachment[], systemContext?: string): Promise<{
|
|
1013
|
+
execute(userPrompt: string, images?: ImageAttachment[], systemContext?: string, signal?: AbortSignal): Promise<{
|
|
972
1014
|
output: string;
|
|
973
1015
|
t2Results: T2Result[];
|
|
974
1016
|
taskId: string;
|
|
975
1017
|
complexity: TaskComplexity;
|
|
976
1018
|
}>;
|
|
977
1019
|
getEscalations(): EscalationPayload[];
|
|
1020
|
+
private reviewT2Outputs;
|
|
978
1021
|
private analyzeImages;
|
|
979
1022
|
private decomposeTask;
|
|
980
1023
|
private validatePlan;
|
|
981
1024
|
private dispatchT2Managers;
|
|
1025
|
+
/**
|
|
1026
|
+
* Runs T2 managers respecting dependsOn declarations using Kahn's algorithm.
|
|
1027
|
+
*/
|
|
1028
|
+
private runT2sWithDependencies;
|
|
982
1029
|
private compileFinalOutput;
|
|
983
1030
|
/**
|
|
984
1031
|
* T1-level permission evaluator.
|
|
@@ -1104,7 +1151,7 @@ declare class T2Manager extends BaseTier {
|
|
|
1104
1151
|
shareCompletedOutput(sectionId: string, output: string): void;
|
|
1105
1152
|
private extractKeywords;
|
|
1106
1153
|
receivePeerSync(fromId: string, content: unknown): void;
|
|
1107
|
-
execute(assignment: T1ToT2Assignment, taskId: string): Promise<T2Result>;
|
|
1154
|
+
execute(assignment: T1ToT2Assignment, taskId: string, signal?: AbortSignal): Promise<T2Result>;
|
|
1108
1155
|
private decomposeSection;
|
|
1109
1156
|
private executeSubtasks;
|
|
1110
1157
|
/**
|
|
@@ -1158,7 +1205,7 @@ declare class T3Worker extends BaseTier {
|
|
|
1158
1205
|
setToolCreator(creator: ToolCreator): void;
|
|
1159
1206
|
constructor(router: CascadeRouter, toolRegistry: ToolRegistry, parentId: string);
|
|
1160
1207
|
setStore(store: MemoryStore, sessionId: string): void;
|
|
1161
|
-
execute(assignment: T2ToT3Assignment, taskId: string): Promise<T3Result>;
|
|
1208
|
+
execute(assignment: T2ToT3Assignment, taskId: string, signal?: AbortSignal): Promise<T3Result>;
|
|
1162
1209
|
sendToPeer(toId: string, content: unknown): void;
|
|
1163
1210
|
requestFromPeer(peerId: string, subtaskId: string): Promise<string>;
|
|
1164
1211
|
syncWithPeers(barrierName: string): Promise<void>;
|
|
@@ -1534,7 +1581,7 @@ declare class Telemetry {
|
|
|
1534
1581
|
shutdown(): Promise<void>;
|
|
1535
1582
|
}
|
|
1536
1583
|
|
|
1537
|
-
declare const CASCADE_VERSION = "0.2.
|
|
1584
|
+
declare const CASCADE_VERSION = "0.2.12";
|
|
1538
1585
|
declare const CASCADE_CONFIG_DIR = ".cascade";
|
|
1539
1586
|
declare const CASCADE_MD_FILE = "CASCADE.md";
|
|
1540
1587
|
declare const CASCADE_IGNORE_FILE = ".cascadeignore";
|
|
@@ -1578,8 +1625,28 @@ declare const TOOL_NAMES: {
|
|
|
1578
1625
|
readonly PDF_CREATE: "pdf_create";
|
|
1579
1626
|
readonly RUN_CODE: "run_code";
|
|
1580
1627
|
readonly PEER_MESSAGE: "peer_message";
|
|
1628
|
+
readonly WEB_SEARCH: "web_search";
|
|
1581
1629
|
};
|
|
1582
1630
|
declare const DEFAULT_APPROVAL_REQUIRED: string[];
|
|
1583
1631
|
declare const PROVIDER_DISPLAY_NAMES: Record<ProviderType, string>;
|
|
1584
1632
|
|
|
1585
|
-
|
|
1633
|
+
/**
|
|
1634
|
+
* Thrown when a Cascade run is aborted via `AbortSignal`.
|
|
1635
|
+
* Caught at the `Cascade.run()` boundary — does NOT propagate as an
|
|
1636
|
+
* unhandled rejection. Callers receive a partial result instead.
|
|
1637
|
+
*/
|
|
1638
|
+
declare class CascadeCancelledError extends Error {
|
|
1639
|
+
constructor(reason?: string);
|
|
1640
|
+
}
|
|
1641
|
+
/**
|
|
1642
|
+
* A retryable error that carries a `.userMessage` for display.
|
|
1643
|
+
*/
|
|
1644
|
+
declare class CascadeToolError extends Error {
|
|
1645
|
+
/** A friendly message to show the user / T3 */
|
|
1646
|
+
readonly userMessage: string;
|
|
1647
|
+
/** Whether this error class is retryable by default */
|
|
1648
|
+
readonly retryable: boolean;
|
|
1649
|
+
constructor(userMessage: string, cause?: unknown, retryable?: boolean);
|
|
1650
|
+
}
|
|
1651
|
+
|
|
1652
|
+
export { AZURE_BASE_URL_TEMPLATE, type ApprovalRequest, type ApprovalResponse, type AuditEntry, AuditLogger, type BudgetConfig, CASCADE_AUDIT_FILE, CASCADE_CONFIG_DIR, CASCADE_CONFIG_FILE, CASCADE_DASHBOARD_SECRET_FILE, CASCADE_DB_FILE, CASCADE_IGNORE_FILE, CASCADE_KEYSTORE_FILE, CASCADE_MD_FILE, CASCADE_VERSION, COMPLEXITY_T2_COUNT, Cascade, CascadeCancelledError, type CascadeConfig, type CascadeEvent, type CascadeEventType, CascadeIgnore, type CascadeMessage, CascadeRouter, type CascadeRunOptions, type CascadeRunResult, CascadeToolError, ConfigManager, type ConversationMessage, DEFAULT_API_PORT, DEFAULT_APPROVAL_REQUIRED, DEFAULT_AUTO_SUMMARIZE_AT, DEFAULT_CONTEXT_LIMIT, DEFAULT_DASHBOARD_PORT, DEFAULT_MAX_SESSION_MESSAGES, DEFAULT_RETENTION_DAYS, DEFAULT_THEME, type DashboardConfig, DashboardServer, type EscalationPayload, GLOBAL_CONFIG_DIR, GLOBAL_DB_FILE, GLOBAL_KEYSTORE_FILE, GLOBAL_RUNTIME_DB_FILE, type GenerateOptions, type GenerateResult, type HookDefinition, type HooksConfig, HooksRunner, type Identity, type ImageAttachment, Keystore, LM_STUDIO_BASE_URL, MODELS, McpClient, type McpServerConfig$1 as McpServerConfig, type MemoryConfig, MemoryStore, type Message, type MessageContent, type MessagePayload, type MessageStatus, type MessageType, type ModelInfo, type ModelOverrides, OLLAMA_BASE_URL, PROVIDER_DISPLAY_NAMES, type PeerMessage, type PeerSyncPayload, type PeerSyncType, type PermissionDecision, type PermissionDecisionPayload, type PermissionRequest, type ProviderConfig, type ProviderType, type RuntimeNode, type RuntimeNodeLog, type RuntimeRefreshPayload, type RuntimeScope, type RuntimeSession, type RuntimeSnapshotPayload, type ScheduledTask, type Session, type SessionCheckpoint, type SessionMetadata, type SessionSubscriptionPayload, type StatusUpdate, type StoredMessage, type StreamChunk, T1Administrator, type T1ToT2Assignment, T1_MODEL_PRIORITY, T2Manager, type T2Result, type T2ToT3Assignment, T2_MODEL_PRIORITY, type T3Result, type T3ResultPayload, type T3SubtaskSpec, T3Worker, T3_MODEL_PRIORITY, THEME_NAMES, TOOL_NAMES, type TaskComplexity, TaskScheduler, Telemetry, type TelemetryConfig, type Theme, type ThemeColors, type ThemeName, type TierConfig, type TierLimits, type TierRole, type TierStatus, type TokenUsage, type ToolCall, type ToolDefinition, type ToolExecuteOptions, ToolRegistry, type ToolResult, type ToolsConfig, VISION_MODEL_PRIORITY, type WebSearchConfig, type WebhookConfig, type WorkspaceConfig, createCascade, runCascade, streamCascade };
|
package/dist/index.d.ts
CHANGED
|
@@ -84,6 +84,12 @@ interface ToolDefinition {
|
|
|
84
84
|
description: string;
|
|
85
85
|
inputSchema: Record<string, unknown>;
|
|
86
86
|
}
|
|
87
|
+
interface WebSearchConfig {
|
|
88
|
+
searxngUrl?: string;
|
|
89
|
+
braveApiKey?: string;
|
|
90
|
+
tavilyApiKey?: string;
|
|
91
|
+
maxResults?: number;
|
|
92
|
+
}
|
|
87
93
|
interface Message {
|
|
88
94
|
id: string;
|
|
89
95
|
role: 'user' | 'assistant' | 'error' | 'system';
|
|
@@ -141,6 +147,7 @@ interface T1ToT2Assignment {
|
|
|
141
147
|
constraints: string[];
|
|
142
148
|
t3Subtasks: T3SubtaskSpec[];
|
|
143
149
|
executionMode?: 'parallel' | 'sequential';
|
|
150
|
+
dependsOn?: string[];
|
|
144
151
|
peerT2Ids?: string[];
|
|
145
152
|
}
|
|
146
153
|
interface T3SubtaskSpec {
|
|
@@ -346,6 +353,8 @@ interface ToolsConfig {
|
|
|
346
353
|
* approval before they are spawned.
|
|
347
354
|
*/
|
|
348
355
|
mcpTrusted?: string[];
|
|
356
|
+
/** Web search backends — at least one should be configured for best results */
|
|
357
|
+
webSearch?: WebSearchConfig;
|
|
349
358
|
}
|
|
350
359
|
interface HooksConfig {
|
|
351
360
|
preToolUse?: HookDefinition[];
|
|
@@ -512,6 +521,19 @@ interface CascadeRunOptions {
|
|
|
512
521
|
approved: boolean;
|
|
513
522
|
always: boolean;
|
|
514
523
|
}>;
|
|
524
|
+
/**
|
|
525
|
+
* An optional `AbortSignal` to cancel the run mid-execution.
|
|
526
|
+
* When aborted, all tiers (T1 → T2 → T3) stop at the next safe checkpoint
|
|
527
|
+
* and a `run:cancelled` event is emitted on the Cascade instance.
|
|
528
|
+
* The `run()` call resolves (not rejects) with a partial result.
|
|
529
|
+
*
|
|
530
|
+
* @example
|
|
531
|
+
* const controller = new AbortController();
|
|
532
|
+
* cascade.run({ prompt: '...', signal: controller.signal });
|
|
533
|
+
* // later:
|
|
534
|
+
* controller.abort();
|
|
535
|
+
*/
|
|
536
|
+
signal?: AbortSignal;
|
|
515
537
|
}
|
|
516
538
|
interface CascadeRunResult {
|
|
517
539
|
output: string;
|
|
@@ -698,7 +720,14 @@ interface McpClientOptions {
|
|
|
698
720
|
approvalCallback?: McpApprovalCallback;
|
|
699
721
|
}
|
|
700
722
|
declare class McpClient {
|
|
723
|
+
private static activeProcessPids;
|
|
724
|
+
/**
|
|
725
|
+
* Forcefully kills all known MCP child processes.
|
|
726
|
+
* Call this from global process exit handlers to prevent zombie processes.
|
|
727
|
+
*/
|
|
728
|
+
static killAllProcesses(): void;
|
|
701
729
|
private clients;
|
|
730
|
+
private transports;
|
|
702
731
|
private tools;
|
|
703
732
|
private trustedServers;
|
|
704
733
|
private approvalCallback;
|
|
@@ -709,6 +738,7 @@ declare class McpClient {
|
|
|
709
738
|
callTool(serverName: string, toolName: string, input: Record<string, unknown>): Promise<string>;
|
|
710
739
|
getToolDefinitions(): ToolDefinition[];
|
|
711
740
|
getConnectedServers(): string[];
|
|
741
|
+
getActivePids(): number[];
|
|
712
742
|
isConnected(serverName: string): boolean;
|
|
713
743
|
}
|
|
714
744
|
|
|
@@ -772,6 +802,10 @@ declare class ToolRegistry {
|
|
|
772
802
|
declare class MemoryStore {
|
|
773
803
|
private db;
|
|
774
804
|
constructor(dbPath: string);
|
|
805
|
+
private writeQueue;
|
|
806
|
+
private isProcessingQueue;
|
|
807
|
+
private processQueue;
|
|
808
|
+
private enqueueWrite;
|
|
775
809
|
createSession(session: Session): void;
|
|
776
810
|
updateSession(id: string, updates: Partial<Session>): void;
|
|
777
811
|
getSession(id: string): Session | null;
|
|
@@ -881,6 +915,8 @@ declare abstract class BaseTier extends EventEmitter {
|
|
|
881
915
|
protected label: string;
|
|
882
916
|
protected systemPromptOverride: string;
|
|
883
917
|
protected hierarchyContext: string;
|
|
918
|
+
/** Propagated AbortSignal — set by the tier's `execute()` before work begins. */
|
|
919
|
+
protected signal?: AbortSignal;
|
|
884
920
|
constructor(role: TierRole, id?: string, parentId?: string);
|
|
885
921
|
getStatus(): TierStatus;
|
|
886
922
|
protected setStatus(status: TierStatus): void;
|
|
@@ -890,6 +926,12 @@ declare abstract class BaseTier extends EventEmitter {
|
|
|
890
926
|
protected sendStatusUpdate(update: StatusUpdate): void;
|
|
891
927
|
protected buildMessage(type: CascadeMessage['type'], to: string, payload: Record<string, unknown>): CascadeMessage;
|
|
892
928
|
protected log(message: string, data?: unknown): void;
|
|
929
|
+
/**
|
|
930
|
+
* Throws `CascadeCancelledError` if the run's `AbortSignal` has fired.
|
|
931
|
+
* Call this at safe checkpoints (before LLM calls, between T3 dispatches)
|
|
932
|
+
* to provide a fast, clean cancellation path.
|
|
933
|
+
*/
|
|
934
|
+
protected throwIfCancelled(): void;
|
|
893
935
|
}
|
|
894
936
|
|
|
895
937
|
type T2Evaluator = (req: PermissionRequest) => Promise<PermissionDecision | null>;
|
|
@@ -968,17 +1010,22 @@ declare class T1Administrator extends BaseTier {
|
|
|
968
1010
|
*/
|
|
969
1011
|
setPermissionEscalator(escalator: PermissionEscalator): void;
|
|
970
1012
|
setToolCreator(creator: ToolCreator): void;
|
|
971
|
-
execute(userPrompt: string, images?: ImageAttachment[], systemContext?: string): Promise<{
|
|
1013
|
+
execute(userPrompt: string, images?: ImageAttachment[], systemContext?: string, signal?: AbortSignal): Promise<{
|
|
972
1014
|
output: string;
|
|
973
1015
|
t2Results: T2Result[];
|
|
974
1016
|
taskId: string;
|
|
975
1017
|
complexity: TaskComplexity;
|
|
976
1018
|
}>;
|
|
977
1019
|
getEscalations(): EscalationPayload[];
|
|
1020
|
+
private reviewT2Outputs;
|
|
978
1021
|
private analyzeImages;
|
|
979
1022
|
private decomposeTask;
|
|
980
1023
|
private validatePlan;
|
|
981
1024
|
private dispatchT2Managers;
|
|
1025
|
+
/**
|
|
1026
|
+
* Runs T2 managers respecting dependsOn declarations using Kahn's algorithm.
|
|
1027
|
+
*/
|
|
1028
|
+
private runT2sWithDependencies;
|
|
982
1029
|
private compileFinalOutput;
|
|
983
1030
|
/**
|
|
984
1031
|
* T1-level permission evaluator.
|
|
@@ -1104,7 +1151,7 @@ declare class T2Manager extends BaseTier {
|
|
|
1104
1151
|
shareCompletedOutput(sectionId: string, output: string): void;
|
|
1105
1152
|
private extractKeywords;
|
|
1106
1153
|
receivePeerSync(fromId: string, content: unknown): void;
|
|
1107
|
-
execute(assignment: T1ToT2Assignment, taskId: string): Promise<T2Result>;
|
|
1154
|
+
execute(assignment: T1ToT2Assignment, taskId: string, signal?: AbortSignal): Promise<T2Result>;
|
|
1108
1155
|
private decomposeSection;
|
|
1109
1156
|
private executeSubtasks;
|
|
1110
1157
|
/**
|
|
@@ -1158,7 +1205,7 @@ declare class T3Worker extends BaseTier {
|
|
|
1158
1205
|
setToolCreator(creator: ToolCreator): void;
|
|
1159
1206
|
constructor(router: CascadeRouter, toolRegistry: ToolRegistry, parentId: string);
|
|
1160
1207
|
setStore(store: MemoryStore, sessionId: string): void;
|
|
1161
|
-
execute(assignment: T2ToT3Assignment, taskId: string): Promise<T3Result>;
|
|
1208
|
+
execute(assignment: T2ToT3Assignment, taskId: string, signal?: AbortSignal): Promise<T3Result>;
|
|
1162
1209
|
sendToPeer(toId: string, content: unknown): void;
|
|
1163
1210
|
requestFromPeer(peerId: string, subtaskId: string): Promise<string>;
|
|
1164
1211
|
syncWithPeers(barrierName: string): Promise<void>;
|
|
@@ -1534,7 +1581,7 @@ declare class Telemetry {
|
|
|
1534
1581
|
shutdown(): Promise<void>;
|
|
1535
1582
|
}
|
|
1536
1583
|
|
|
1537
|
-
declare const CASCADE_VERSION = "0.2.
|
|
1584
|
+
declare const CASCADE_VERSION = "0.2.12";
|
|
1538
1585
|
declare const CASCADE_CONFIG_DIR = ".cascade";
|
|
1539
1586
|
declare const CASCADE_MD_FILE = "CASCADE.md";
|
|
1540
1587
|
declare const CASCADE_IGNORE_FILE = ".cascadeignore";
|
|
@@ -1578,8 +1625,28 @@ declare const TOOL_NAMES: {
|
|
|
1578
1625
|
readonly PDF_CREATE: "pdf_create";
|
|
1579
1626
|
readonly RUN_CODE: "run_code";
|
|
1580
1627
|
readonly PEER_MESSAGE: "peer_message";
|
|
1628
|
+
readonly WEB_SEARCH: "web_search";
|
|
1581
1629
|
};
|
|
1582
1630
|
declare const DEFAULT_APPROVAL_REQUIRED: string[];
|
|
1583
1631
|
declare const PROVIDER_DISPLAY_NAMES: Record<ProviderType, string>;
|
|
1584
1632
|
|
|
1585
|
-
|
|
1633
|
+
/**
|
|
1634
|
+
* Thrown when a Cascade run is aborted via `AbortSignal`.
|
|
1635
|
+
* Caught at the `Cascade.run()` boundary — does NOT propagate as an
|
|
1636
|
+
* unhandled rejection. Callers receive a partial result instead.
|
|
1637
|
+
*/
|
|
1638
|
+
declare class CascadeCancelledError extends Error {
|
|
1639
|
+
constructor(reason?: string);
|
|
1640
|
+
}
|
|
1641
|
+
/**
|
|
1642
|
+
* A retryable error that carries a `.userMessage` for display.
|
|
1643
|
+
*/
|
|
1644
|
+
declare class CascadeToolError extends Error {
|
|
1645
|
+
/** A friendly message to show the user / T3 */
|
|
1646
|
+
readonly userMessage: string;
|
|
1647
|
+
/** Whether this error class is retryable by default */
|
|
1648
|
+
readonly retryable: boolean;
|
|
1649
|
+
constructor(userMessage: string, cause?: unknown, retryable?: boolean);
|
|
1650
|
+
}
|
|
1651
|
+
|
|
1652
|
+
export { AZURE_BASE_URL_TEMPLATE, type ApprovalRequest, type ApprovalResponse, type AuditEntry, AuditLogger, type BudgetConfig, CASCADE_AUDIT_FILE, CASCADE_CONFIG_DIR, CASCADE_CONFIG_FILE, CASCADE_DASHBOARD_SECRET_FILE, CASCADE_DB_FILE, CASCADE_IGNORE_FILE, CASCADE_KEYSTORE_FILE, CASCADE_MD_FILE, CASCADE_VERSION, COMPLEXITY_T2_COUNT, Cascade, CascadeCancelledError, type CascadeConfig, type CascadeEvent, type CascadeEventType, CascadeIgnore, type CascadeMessage, CascadeRouter, type CascadeRunOptions, type CascadeRunResult, CascadeToolError, ConfigManager, type ConversationMessage, DEFAULT_API_PORT, DEFAULT_APPROVAL_REQUIRED, DEFAULT_AUTO_SUMMARIZE_AT, DEFAULT_CONTEXT_LIMIT, DEFAULT_DASHBOARD_PORT, DEFAULT_MAX_SESSION_MESSAGES, DEFAULT_RETENTION_DAYS, DEFAULT_THEME, type DashboardConfig, DashboardServer, type EscalationPayload, GLOBAL_CONFIG_DIR, GLOBAL_DB_FILE, GLOBAL_KEYSTORE_FILE, GLOBAL_RUNTIME_DB_FILE, type GenerateOptions, type GenerateResult, type HookDefinition, type HooksConfig, HooksRunner, type Identity, type ImageAttachment, Keystore, LM_STUDIO_BASE_URL, MODELS, McpClient, type McpServerConfig$1 as McpServerConfig, type MemoryConfig, MemoryStore, type Message, type MessageContent, type MessagePayload, type MessageStatus, type MessageType, type ModelInfo, type ModelOverrides, OLLAMA_BASE_URL, PROVIDER_DISPLAY_NAMES, type PeerMessage, type PeerSyncPayload, type PeerSyncType, type PermissionDecision, type PermissionDecisionPayload, type PermissionRequest, type ProviderConfig, type ProviderType, type RuntimeNode, type RuntimeNodeLog, type RuntimeRefreshPayload, type RuntimeScope, type RuntimeSession, type RuntimeSnapshotPayload, type ScheduledTask, type Session, type SessionCheckpoint, type SessionMetadata, type SessionSubscriptionPayload, type StatusUpdate, type StoredMessage, type StreamChunk, T1Administrator, type T1ToT2Assignment, T1_MODEL_PRIORITY, T2Manager, type T2Result, type T2ToT3Assignment, T2_MODEL_PRIORITY, type T3Result, type T3ResultPayload, type T3SubtaskSpec, T3Worker, T3_MODEL_PRIORITY, THEME_NAMES, TOOL_NAMES, type TaskComplexity, TaskScheduler, Telemetry, type TelemetryConfig, type Theme, type ThemeColors, type ThemeName, type TierConfig, type TierLimits, type TierRole, type TierStatus, type TokenUsage, type ToolCall, type ToolDefinition, type ToolExecuteOptions, ToolRegistry, type ToolResult, type ToolsConfig, VISION_MODEL_PRIORITY, type WebSearchConfig, type WebhookConfig, type WorkspaceConfig, createCascade, runCascade, streamCascade };
|