@axiom-lattice/core 2.1.99 → 2.1.102

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/index.d.mts CHANGED
@@ -8,7 +8,7 @@ import { BaseLanguageModelInput, LanguageModelLike } from '@langchain/core/langu
8
8
  import { CallbackManagerForLLMRun } from '@langchain/core/callbacks/manager';
9
9
  import { ChatResult } from '@langchain/core/outputs';
10
10
  import * as _axiom_lattice_protocols from '@axiom-lattice/protocols';
11
- import { LLMConfig, SemanticMetricsServerConfig, MetricMeta, MetricQueryResult, DataSource, SemanticMetricsQueryRequest, SemanticMetricsQueryResponse, TableQueryRequest, TableQueryResponse, ExecuteSqlQueryRequest, ExecuteSqlQueryResponse, MetricsServerType, MetricsServerConfig, ToolConfig, ToolExecutor, AgentConfig, MiddlewareType, GraphBuildOptions, MessageChunk, MessageChunkType, QueueLatticeProtocol, QueueConfig, QueueClient, QueueResult, ScheduleLatticeProtocol, ScheduleConfig, ScheduleClient, ScheduleStorage, TaskHandler, ScheduleOnceOptions, ScheduleCronOptions, ScheduledTaskDefinition, ScheduledTaskStatus, ScheduleExecutionType, ThreadStore, AssistantStore, SkillStore, CollectionStore, WorkspaceStore, ProjectStore, DatabaseConfigStore, MetricsServerConfigStore, McpServerConfigStore, UserStore, TenantStore, UserTenantLinkStore, WorkflowTrackingStore, EvalStore, ChannelInstallationStore, BindingRegistry, MenuRegistry, A2AApiKeyStore, TaskStore, SharedResourceStore, ConnectionStore, VectorStoreProvider, Thread, CreateThreadRequest, Assistant, CreateAssistantRequest, Skill, CreateSkillRequest, SkillStoreContext, DatabaseConfigEntry, CreateDatabaseConfigRequest, UpdateDatabaseConfigRequest, User, CreateUserRequest, UpdateUserRequest, Tenant, CreateTenantRequest, UpdateTenantRequest, UserTenantLink, CreateUserTenantLinkRequest, UpdateUserTenantLinkRequest, ChannelInstallation, ChannelInstallationType, CreateChannelInstallationRequest, UpdateChannelInstallationRequest, Binding, CreateBindingInput, A2AApiKeyRecord, CreateA2AApiKeyInput, A2AApiKeyEntry, CreateTaskRequest, TaskItem, TaskListFilter, UpdateTaskRequest, Collection, CreateCollectionRequest, UpdateCollectionRequest, MenuItem, CreateMenuItemInput, UpdateMenuItemInput, LoggerLatticeProtocol, LoggerConfig, LoggerClient, LoggerContext, SkillConfig, SkillClient, McpTool, ResourceResolver, ResourceAddress, ShareVisibility, CreateShareRequest, ChannelAdapter, PluginMeta, Plugin, PluginMetaOutput, InternalStateField, InternalInput, InternalNode, InternalAgentNode, InternalMapNode, InternalDSL, ConnectionEntry } from '@axiom-lattice/protocols';
11
+ import { LLMConfig, SemanticMetricsServerConfig, MetricMeta, MetricQueryResult, DataSource, SemanticMetricsQueryRequest, SemanticMetricsQueryResponse, TableQueryRequest, TableQueryResponse, ExecuteSqlQueryRequest, ExecuteSqlQueryResponse, MetricsServerType, MetricsServerConfig, ToolConfig, ToolExecutor, AgentConfig, MiddlewareType, GraphBuildOptions, MessageChunk, MessageChunkType, QueueLatticeProtocol, QueueConfig, QueueClient, QueueResult, ScheduleLatticeProtocol, ScheduleConfig, ScheduleClient, ScheduleStorage, TaskHandler, ScheduleOnceOptions, ScheduleCronOptions, ScheduledTaskDefinition, ScheduledTaskStatus, ScheduleExecutionType, ThreadStore, AssistantStore, SkillStore, CollectionStore, WorkspaceStore, ProjectStore, DatabaseConfigStore, MetricsServerConfigStore, McpServerConfigStore, UserStore, TenantStore, UserTenantLinkStore, WorkflowTrackingStore, EvalStore, ChannelInstallationStore, BindingRegistry, MenuRegistry, A2AApiKeyStore, TaskStore, SharedResourceStore, ConnectionStore, TaskWorkItemStore, VectorStoreProvider, Thread, CreateThreadRequest, Assistant, CreateAssistantRequest, Skill, CreateSkillRequest, SkillStoreContext, DatabaseConfigEntry, CreateDatabaseConfigRequest, UpdateDatabaseConfigRequest, User, CreateUserRequest, UpdateUserRequest, Tenant, CreateTenantRequest, UpdateTenantRequest, UserTenantLink, CreateUserTenantLinkRequest, UpdateUserTenantLinkRequest, ChannelInstallation, ChannelInstallationType, CreateChannelInstallationRequest, UpdateChannelInstallationRequest, Binding, CreateBindingInput, A2AApiKeyRecord, CreateA2AApiKeyInput, A2AApiKeyEntry, CreateTaskRequest, TaskItem, TaskListFilter, UpdateTaskRequest, Collection, CreateCollectionRequest, UpdateCollectionRequest, MenuItem, CreateMenuItemInput, UpdateMenuItemInput, LoggerLatticeProtocol, LoggerConfig, LoggerClient, LoggerContext, SkillConfig, SkillClient, McpTool, ResourceResolver, ResourceAddress, ShareVisibility, CreateShareRequest, ChannelAdapter, PluginMeta, Plugin, PluginMetaOutput, InternalStateField, InternalInput, InternalNode, InternalAgentNode, InternalMapNode, InternalDSL, ConnectionEntry } from '@axiom-lattice/protocols';
12
12
  export { _axiom_lattice_protocols as Protocols };
13
13
  export { AgentConfig, AgentType, GraphBuildOptions, MemoryType } from '@axiom-lattice/protocols';
14
14
  import * as langchain from 'langchain';
@@ -194,6 +194,10 @@ declare class ModelLattice extends BaseChatModel {
194
194
  * @returns 聊天结果
195
195
  */
196
196
  _generate(messages: BaseMessage[], options: this["ParsedCallOptions"], runManager?: CallbackManagerForLLMRun): Promise<ChatResult>;
197
+ /**
198
+ * Whether the configured model supports vision/image inputs.
199
+ */
200
+ get supportsVision(): boolean;
197
201
  /**
198
202
  * 将工具绑定到模型
199
203
  * @param tools 工具列表
@@ -2727,6 +2731,7 @@ type StoreTypeMap = {
2727
2731
  task: TaskStore;
2728
2732
  sharedResource: SharedResourceStore;
2729
2733
  connection: ConnectionStore;
2734
+ taskWorkItem: TaskWorkItemStore;
2730
2735
  };
2731
2736
  /**
2732
2737
  * Store type keys
@@ -2823,6 +2828,18 @@ declare const getStoreLattice: <TStoreType extends StoreType>(key: string, type:
2823
2828
  interface ConfigureStoresOptions {
2824
2829
  autoDisposeStores?: boolean;
2825
2830
  customStores?: Record<string, object>;
2831
+ /**
2832
+ * Whether to auto-discover and register plugin-contributed stores.
2833
+ * When true, iterates all registered plugins and registers their `stores`
2834
+ * field into StoreLatticeManager via the customStores mechanism.
2835
+ *
2836
+ * Note: Plugin-contributed agents are NOT registered here — they are
2837
+ * registered per-tenant via ensurePluginAgentsForTenant() during agent
2838
+ * lattice initialization, following the builtin agents pattern.
2839
+ *
2840
+ * @default false
2841
+ */
2842
+ discoverPlugins?: boolean;
2826
2843
  }
2827
2844
  type Store = Partial<{
2828
2845
  [K in StoreType]: StoreTypeMap[K];
@@ -6367,6 +6384,7 @@ declare class SandboxFilesystem implements BackendProtocol {
6367
6384
  lsInfo(dirPath: string): Promise<FileInfo[]>;
6368
6385
  read(filePath: string, offset?: number, limit?: number): Promise<string>;
6369
6386
  readRaw(filePath: string): Promise<FileData>;
6387
+ readBinary(filePath: string): Promise<Buffer>;
6370
6388
  write(filePath: string, content: string): Promise<WriteResult>;
6371
6389
  edit(filePath: string, oldString: string, newString: string, replaceAll?: boolean): Promise<EditResult>;
6372
6390
  grepRaw(pattern: string, searchPath?: string | null, glob?: string | null): Promise<GrepMatch[] | string>;
@@ -7591,4 +7609,260 @@ declare class ConnectionRegistry {
7591
7609
  private static ensureStore;
7592
7610
  }
7593
7611
 
7594
- export { AGENT_TASK_EVENT, type AddMessageParams, Agent, type AgentClient, type AgentExecutor, AgentInstanceManager, type AgentLattice, AgentLatticeManager, type AgentLifecycleEventName, AgentManager, type AgentStreamExecutor, type AgentThreadInterface, BUILTIN_PLUGINS, BUILTIN_SKILLS, type BackendFactory, type BackendProtocol, type BufferStats, type CacheEntry, type CaseRunResult, type Chunk, ChunkBuffer, ChunkBufferLatticeManager, CollectionLatticeManager, type ColumnInfo, CompositeBackend, type ConnectAllChannelsOptions, ConnectionRegistry, ConsoleLoggerClient, type CreateSandboxProviderConfig, type CronFields, CustomMetricsClient, type CustomMiddlewareFactory, CustomMiddlewareRegistry, type DatabaseConfig, type DatabaseType, DaytonaInstance, DaytonaProvider, type DaytonaProviderConfig, DefaultScheduleClient, E2BInstance, E2BProvider, type E2BProviderConfig, EMPTY_CONTENT_WARNING, type EditResult, type EmbeddingsInfo, type EmbeddingsLatticeInterface, EmbeddingsLatticeManager, type EnsureMicrosandboxInput, type EvalRunService, type FileData, type FileInfo, FileSystemSkillStore, type FileSystemSkillStoreOptions, FilesystemBackend, type FsEntry, type GrepMatch, type IMessageQueueStore, type IMetricsServerClient, type ISqlDatabase, InMemoryA2AApiKeyStore, InMemoryAssistantStore, InMemoryBindingStore, InMemoryChannelInstallationStore, InMemoryChunkBuffer, InMemoryCollectionStore, InMemoryDatabaseConfigStore, InMemoryMailboxStore, InMemoryMenuStore, InMemoryTaskListStore, InMemoryTaskStore, InMemoryTenantStore, InMemoryThreadMessageQueueStore, InMemoryThreadStore, InMemoryUserStore, InMemoryUserTenantLinkStore, LINE_NUMBER_WIDTH, type LangGraphStateChecker, type LatticeAgentStepConfig, LatticeEval, type LatticeEvalBatchReport, type LatticeEvalCase, type LatticeEvalCaseType, type LatticeEvalCaseWithTemplate, type LatticeEvalConfig, type LatticeEvalLogEvent, type LatticeEvalLogLevel, LatticeEvalProject, type LatticeEvalProjectType, type LatticeEvalResult, type LatticeEvalRubric, LatticeEvalSuite, type LatticeEvalSuiteType, type LatticeEvalTemplate, LocalSandboxInstance, LocalSandboxProvider, type LocalSandboxProviderConfig, type LoggerLattice, LoggerLatticeManager, MAX_LINE_LENGTH, type MailboxMessage, type MailboxStore, type McpLatticeInterface, McpLatticeManager, type McpServerInfo, MemoryBackend, MemoryLatticeManager, MemoryQueueClient, MemoryScheduleStorage, type MessageCompletedEvent, type MessageFailedEvent, type MessageStartedEvent, MessageType, MetricsServerManager, MicrosandboxRemoteInstance, MicrosandboxRemoteProvider, type MicrosandboxRemoteProviderClient, type MicrosandboxRemoteProviderConfig, MicrosandboxServiceClient, type MicrosandboxServiceClientConfig, type MicrosandboxShellExecInput, type ModelConfig, type ModelLatticeInterface, ModelLatticeManager, MysqlDatabase, type OutputType, type PendingMessage, PersonalAssistantConfig, PinoLoggerClient, PluginRegistry, PostgresDatabase, PrometheusClient, type QueryResult, type QueueLattice, QueueLatticeManager, QueueMode, type QueuePendingEvent, RemoteSandboxInstance, RemoteSandboxProvider, type RemoteSandboxProviderConfig, type ResolveAgentFn, type ResolvedConfig, type RunSandboxConfig, type RuntimeModelConfig, type SandboxFileInfo, type SandboxFileService, SandboxFilesystem, type SandboxInstance, type SandboxIsolationLevel, SandboxLatticeManager, type SandboxManagerProtocol, type SandboxProvider, type SandboxProviderFactory, type SandboxProviderType, type SandboxShellService, SandboxSkillStore, type SandboxSkillStoreOptions, type SandboxVolumeDefinition, type ScheduleLattice, ScheduleLatticeManager, type SchedulerMiddlewareOptions, SemanticMetricsClient, type SharePayload, SimpleMemoryVectorStore, type SkillLattice, SkillLatticeManager, type SkillMeta, type SkillResource, SqlDatabaseManager, type StateAndStore, StateBackend, StoreBackend, type StoreLattice, StoreLatticeManager, type StoreType, type StoreTypeMap, TOOL_RESULT_TOKEN_LIMIT, TRUNCATION_GUIDANCE, type TableInfo, type TableSchema, type TaskEvent, type TaskListStore, type TaskSpec, TaskStatus, type TaskUpdatable, TeamAgentGraphBuilder, type TeamConfig, type TeamMiddlewareOptions, type TeamTask, type TeammateSpec, type TeammateToolsOptions, type ThreadBuffer, type ThreadBufferConfig, type ThreadBusyEvent, type ThreadIdleEvent, type ThreadInfo, type ThreadQueueConfig, type ThreadState, ThreadStatus, type ThreadStatusChangedEvent, TokenCache, type ToolDefinition, type ToolLattice, ToolLatticeManager, type UnknownToolHandlerConfig, type VectorStoreLatticeInterface, VectorStoreLatticeManager, type VectorStoreProviderLattice, VectorStoreProviderManager, VolumeFilesystem, type VolumeFsClient, type WorkflowValidationError, type WriteResult, abortWorkflowRun, agentInstanceManager, agentLatticeManager, buildGrepResultsDict, buildInput, buildNamedVolumeName, buildSandboxMetadataEnv, buildSkillFile, buildStateAnnotation, buildTableName, checkEmptyContent, clearEncryptionKeyCache, clearEvalRunService, collectionLatticeManager, compileInternal, compileWorkflow, computeSandboxName, configureStores, connectAllChannels, createAgentNode, createAgentTeam, createExecuteSqlQueryTool, createFileData, createInfoSqlTool, createListMetricsDataSourcesTool, createListMetricsServersTool, createListTablesSqlTool, createMapNode, createModelSelectorMiddleware, createNodeHandler, createQueryCheckerSqlTool, createQueryMetricDefinitionTool, createQueryMetricsListTool, createQuerySemanticMetricDataTool, createQuerySqlTool, createQueryTableDefinitionTool, createQueryTablesListTool, createResourceAddress, createSandboxProvider, createSchedulerMiddleware, createSharePayload, createTaskMiddleware, createTeamMiddleware, createTeammateTools, createUnknownToolHandlerMiddleware, createWidgetMiddleware, decrypt, describeCronExpression, embeddingsLatticeManager, encrypt, ensureBuiltinAgentsForTenant, evaluateLatticeCaseWithLogs, eventBus, eventBus as eventBusDefault, extractFetcherError, extractOutput, fileDataToString, formatContentWithLineNumbers, formatGrepMatches, formatGrepResults, formatReadResponse, generateToken, getAgentClient, getAgentConfig, getAllAgentConfigs, getAllBuiltInSkillMetas, getAllToolDefinitions, getBindingRegistry, getBuiltInSkillContent, getBuiltInSkillMeta, getBuiltInSkillNames, getCheckpointSaver, getChunkBuffer, getCollectionEntryCount, getEmbeddingsClient, getEmbeddingsLattice, getEncryptionKey, getEvalRunService, getLoggerLattice, getMenuRegistry, getModelLattice, getNextCronTime, getOrCreateCollectionVectorStore, getQueueLattice, getSandBoxManager, getScheduleLattice, getStoreLattice, getToolClient, getToolDefinition, getToolLattice, getVectorStoreClient, getVectorStoreLattice, getVectorStoreProvider, getWorkflowSignal, globSearchFiles, grepMatchesFromFiles, grepSearchFiles, hasChunkBuffer, invokeWithRetry, isBuiltInSkill, isUsingDefaultKey, isValidCronExpression, isValidSandboxName, isValidSkillName, listCollectionEntries, listSandboxProviderTypes, loggerLatticeManager, mcpManager, metricsServerManager, modelLatticeManager, normalizeSandboxName, parallelLimit, parseCronExpression, parseSkillFrontmatter, parseYaml, performStringReplacement, queueLatticeManager, registerAgentLattice, registerAgentLatticeWithTenant, registerAgentLattices, registerCheckpointSaver, registerChunkBuffer, registerEmbeddingsLattice, registerExistingTool, registerLoggerLattice, registerModelLattice, registerQueueLattice, registerSandboxProviderType, registerScheduleLattice, registerStoreLattice, registerTeammateAgent, registerToolLattice, registerVectorStoreLattice, registerVectorStoreProvider, registerWorkflowRun, removeCollectionVectorStore, renderTemplate, resolvePath, sandboxLatticeManager, sanitizeToolCallId, scheduleLatticeManager, serializePluginMeta, setBindingRegistry, setEvalRunService, setMenuRegistry, skillLatticeManager, sqlDatabaseManager, storeLatticeManager, toJsonSchema, toSafeStateExpr, toolLatticeManager, truncateIfTooLong, unregisterTeammateAgent, unregisterWorkflowRun, updateFileData, validateAgentInput, validateDSL, validateEncryptionKey, validatePath, validateSkillName, validateToolInput, vectorStoreLatticeManager, vectorStoreProviderManager };
7612
+ /**
7613
+ * Export/Import shared type definitions.
7614
+ *
7615
+ * @module @axiom-lattice/core/export_import/types
7616
+ */
7617
+ /** A single exported entity within the JSON bundle. */
7618
+ interface ExportableEntity {
7619
+ _exportId: string;
7620
+ data: Record<string, unknown>;
7621
+ }
7622
+ /** Top-level export JSON format written to file. */
7623
+ interface ExportBundle {
7624
+ version: 1;
7625
+ exportedAt: string;
7626
+ sourceTenantId: string;
7627
+ entities: Record<string, ExportableEntity[]>;
7628
+ dependencyOrder: string[];
7629
+ _warning?: string;
7630
+ }
7631
+ /** Describes a registered exportable entity type to the frontend. */
7632
+ interface ExportableTypeInfo {
7633
+ entityType: string;
7634
+ label: string;
7635
+ category: 'core' | 'plugin';
7636
+ dependsOn: string[];
7637
+ cascadeParents: string[];
7638
+ }
7639
+ /** Result of a single conflict check. */
7640
+ interface ConflictItem {
7641
+ _exportId: string;
7642
+ entityType: string;
7643
+ conflictType: 'id_exists' | 'unique_constraint';
7644
+ existingName?: string;
7645
+ existingId?: string;
7646
+ field?: string;
7647
+ }
7648
+ /** Result of a single insertion (no conflict). */
7649
+ interface InsertionItem {
7650
+ _exportId: string;
7651
+ entityType: string;
7652
+ name: string;
7653
+ }
7654
+ /** Error detected during preview. */
7655
+ interface PreviewError {
7656
+ _exportId: string;
7657
+ entityType: string;
7658
+ error: string;
7659
+ }
7660
+ /** Combined result from import preview. */
7661
+ interface ImportPreviewResult {
7662
+ conflicts: ConflictItem[];
7663
+ insertions: InsertionItem[];
7664
+ errors: PreviewError[];
7665
+ }
7666
+ /** User's resolution decision for a single conflict. */
7667
+ type ResolutionAction = 'skip' | 'overwrite' | 'rename';
7668
+ interface Resolution {
7669
+ _exportId: string;
7670
+ action: ResolutionAction;
7671
+ newId?: string;
7672
+ }
7673
+ /** Result of importing a single entity. */
7674
+ type ImportEntityStatus = 'created' | 'updated' | 'skipped' | 'failed';
7675
+ interface ImportEntityResult {
7676
+ _exportId: string;
7677
+ entityType: string;
7678
+ status: ImportEntityStatus;
7679
+ newId?: string;
7680
+ error?: string;
7681
+ }
7682
+ /** Combined result from import apply. */
7683
+ interface ImportApplyResult {
7684
+ results: ImportEntityResult[];
7685
+ idMap: Record<string, string>;
7686
+ }
7687
+ /** Export job tracking (in-memory, ephemeral). */
7688
+ interface ExportJob {
7689
+ jobId: string;
7690
+ tenantId: string;
7691
+ bundle: ExportBundle;
7692
+ createdAt: Date;
7693
+ }
7694
+ /**
7695
+ * Definition for a single exportable entity type.
7696
+ * Plugins and built-in types register through this interface.
7697
+ */
7698
+ interface ExportableEntityDefinition {
7699
+ entityType: string;
7700
+ label: string;
7701
+ category: 'core' | 'plugin';
7702
+ dependsOn: string[];
7703
+ cascadeParents: string[];
7704
+ /** List all entities of this type for the given tenant. */
7705
+ listForExport(tenantId: string): Promise<ExportableEntity[]>;
7706
+ /**
7707
+ * Map of field name → referenced entityType. During export, raw IDs in these fields
7708
+ * are replaced with @type/exportId references. During import, IdRemapper reverses this.
7709
+ */
7710
+ referenceFields?: Record<string, string>;
7711
+ /** Check for conflicts when importing into the target tenant. */
7712
+ previewImport(tenantId: string, entities: ExportableEntity[]): Promise<ImportPreviewResult>;
7713
+ /**
7714
+ * Apply a single entity import.
7715
+ * @param tenantId - Target tenant
7716
+ * @param entity - The entity data with references already remapped by the service
7717
+ * @param resolution - How to handle this entity (skip/overwrite/rename)
7718
+ * @returns The new ID created, or undefined if skipped
7719
+ */
7720
+ applyImport(tenantId: string, entity: ExportableEntity, resolution: Resolution): Promise<{
7721
+ newId?: string;
7722
+ }>;
7723
+ }
7724
+
7725
+ /**
7726
+ * Singleton registry for exportable entity type definitions.
7727
+ *
7728
+ * Plugins and built-in types register their export/import logic through this
7729
+ * registry. The export/import service discovers registered types at runtime
7730
+ * and orchestrates export, preview, and import operations.
7731
+ *
7732
+ * @example
7733
+ * ```ts
7734
+ * const registry = ExportableEntityRegistry.getInstance();
7735
+ * registry.register({
7736
+ * entityType: 'skill',
7737
+ * label: 'Skills',
7738
+ * category: 'core',
7739
+ * dependsOn: [],
7740
+ * cascadeParents: [],
7741
+ * listForExport: async (tenantId) => [...],
7742
+ * previewImport: async (tenantId, entities) => ({ conflicts: [], insertions: [], errors: [] }),
7743
+ * applyImport: async (tenantId, entity, resolution) => ({ newId: '...' }),
7744
+ * });
7745
+ * ```
7746
+ *
7747
+ * @remarks
7748
+ * - Uses the singleton pattern — there is only one registry instance.
7749
+ * - Registration order does not matter; the DependencyResolver handles ordering.
7750
+ */
7751
+ declare class ExportableEntityRegistry {
7752
+ private static instance;
7753
+ private definitions;
7754
+ /**
7755
+ * Returns the singleton registry instance, creating it if necessary.
7756
+ *
7757
+ * @returns The singleton {@link ExportableEntityRegistry} instance.
7758
+ */
7759
+ static getInstance(): ExportableEntityRegistry;
7760
+ /**
7761
+ * Registers an exportable entity type definition.
7762
+ *
7763
+ * @param def - The entity definition to register.
7764
+ *
7765
+ * @throws If an entity type with the same `entityType` is already registered.
7766
+ */
7767
+ register(def: ExportableEntityDefinition): void;
7768
+ /**
7769
+ * Retrieves a registered entity definition by type name.
7770
+ *
7771
+ * @param entityType - The entity type identifier (e.g. `'skill'`, `'agent'`).
7772
+ *
7773
+ * @returns The registered {@link ExportableEntityDefinition}.
7774
+ *
7775
+ * @throws If no definition is registered for the given type.
7776
+ */
7777
+ get(entityType: string): ExportableEntityDefinition;
7778
+ /**
7779
+ * Returns lightweight metadata for all registered types (for the frontend).
7780
+ *
7781
+ * @returns An array of {@link ExportableTypeInfo} objects.
7782
+ */
7783
+ listTypes(): ExportableTypeInfo[];
7784
+ /**
7785
+ * Returns all registered entity definitions.
7786
+ *
7787
+ * @returns An array of all registered {@link ExportableEntityDefinition} objects.
7788
+ */
7789
+ getAll(): ExportableEntityDefinition[];
7790
+ /**
7791
+ * Removes a registered entity type definition.
7792
+ *
7793
+ * @param entityType - The entity type identifier to remove.
7794
+ */
7795
+ unregister(entityType: string): void;
7796
+ }
7797
+
7798
+ /**
7799
+ * Resolves topological ordering and CASCADE dependencies across registered
7800
+ * exportable entity types.
7801
+ *
7802
+ * Used during export/import to determine the correct sequence for serialising
7803
+ * and re-creating entities (e.g. skills before agents, parent entities before
7804
+ * children in eval hierarchies).
7805
+ *
7806
+ * @example
7807
+ * ```ts
7808
+ * const defs: ExportableEntityDefinition[] = [
7809
+ * { entityType: 'agent', dependsOn: ['skill'], cascadeParents: [], ... },
7810
+ * { entityType: 'skill', dependsOn: [], cascadeParents: [], ... },
7811
+ * ];
7812
+ * const order = DependencyResolver.resolveOrder(defs);
7813
+ * // order[0] === 'skill', order[1] === 'agent'
7814
+ * ```
7815
+ */
7816
+ declare class DependencyResolver {
7817
+ /**
7818
+ * Topological sort of entity types based on their {@link ExportableEntityDefinition.dependsOn}
7819
+ * declarations. Entities with no dependencies come first.
7820
+ *
7821
+ * @param defs - All registered exportable entity definitions.
7822
+ * @returns Entity type names in dependency-first order.
7823
+ */
7824
+ static resolveOrder(defs: ExportableEntityDefinition[]): string[];
7825
+ /**
7826
+ * Given a set of selected entity types, expand to include all CASCADE
7827
+ * parents. Only walks **upward** (parents), never downward (children).
7828
+ *
7829
+ * @param defs - All registered exportable entity definitions.
7830
+ * @param selected - Entity type names the user explicitly chose.
7831
+ * @returns The original selection plus every reachable cascade parent.
7832
+ */
7833
+ static expandCascade(defs: ExportableEntityDefinition[], selected: string[]): string[];
7834
+ /**
7835
+ * Compute which required dependencies are missing from the selected types.
7836
+ *
7837
+ * Only considers dependencies that are themselves registered as exportable
7838
+ * entity types. Unregistered dependencies (e.g. `Workspace`, `Project` —
7839
+ * infrastructure types) are silently excluded.
7840
+ *
7841
+ * @param defs - All registered exportable entity definitions.
7842
+ * @param selected - Entity type names the user has selected.
7843
+ * @returns The list of entity types that must also be selected (or
7844
+ * auto-included).
7845
+ */
7846
+ static computeDependencies(defs: ExportableEntityDefinition[], selected: string[]): {
7847
+ missing: string[];
7848
+ };
7849
+ }
7850
+
7851
+ declare class IdRemapper {
7852
+ private readonly idMap;
7853
+ constructor(idMap: Record<string, string>);
7854
+ /**
7855
+ * Deep-traverse an object/array and replace all @type/exportId string values
7856
+ * with their corresponding real IDs from the idMap.
7857
+ * Values not matching the @type/exportId pattern are returned unchanged.
7858
+ */
7859
+ remapReferences(value: unknown): unknown;
7860
+ /**
7861
+ * Replace raw skill IDs in an agent's graphDefinition.skillIds array.
7862
+ * This handles the implicit agent->skill reference that uses raw skill IDs
7863
+ * (not @type/exportId format). Agents reference skills by their string ID.
7864
+ */
7865
+ remapSkillIds(graphDefinition: Record<string, unknown>, skillRemap: Record<string, string>): Record<string, unknown>;
7866
+ }
7867
+
7868
+ export { AGENT_TASK_EVENT, type AddMessageParams, Agent, type AgentClient, type AgentExecutor, AgentInstanceManager, type AgentLattice, AgentLatticeManager, type AgentLifecycleEventName, AgentManager, type AgentStreamExecutor, type AgentThreadInterface, BUILTIN_PLUGINS, BUILTIN_SKILLS, type BackendFactory, type BackendProtocol, type BufferStats, type CacheEntry, type CaseRunResult, type Chunk, ChunkBuffer, ChunkBufferLatticeManager, CollectionLatticeManager, type ColumnInfo, CompositeBackend, type ConflictItem, type ConnectAllChannelsOptions, ConnectionRegistry, ConsoleLoggerClient, type CreateSandboxProviderConfig, type CronFields, CustomMetricsClient, type CustomMiddlewareFactory, CustomMiddlewareRegistry, type DatabaseConfig, type DatabaseType, DaytonaInstance, DaytonaProvider, type DaytonaProviderConfig, DefaultScheduleClient, DependencyResolver, E2BInstance, E2BProvider, type E2BProviderConfig, EMPTY_CONTENT_WARNING, type EditResult, type EmbeddingsInfo, type EmbeddingsLatticeInterface, EmbeddingsLatticeManager, type EnsureMicrosandboxInput, type EvalRunService, type ExportBundle, type ExportJob, type ExportableEntity, type ExportableEntityDefinition, ExportableEntityRegistry, type ExportableTypeInfo, type FileData, type FileInfo, FileSystemSkillStore, type FileSystemSkillStoreOptions, FilesystemBackend, type FsEntry, type GrepMatch, type IMessageQueueStore, type IMetricsServerClient, type ISqlDatabase, IdRemapper, type ImportApplyResult, type ImportEntityResult, type ImportEntityStatus, type ImportPreviewResult, InMemoryA2AApiKeyStore, InMemoryAssistantStore, InMemoryBindingStore, InMemoryChannelInstallationStore, InMemoryChunkBuffer, InMemoryCollectionStore, InMemoryDatabaseConfigStore, InMemoryMailboxStore, InMemoryMenuStore, InMemoryTaskListStore, InMemoryTaskStore, InMemoryTenantStore, InMemoryThreadMessageQueueStore, InMemoryThreadStore, InMemoryUserStore, InMemoryUserTenantLinkStore, type InsertionItem, LINE_NUMBER_WIDTH, type LangGraphStateChecker, type LatticeAgentStepConfig, LatticeEval, type LatticeEvalBatchReport, type LatticeEvalCase, type LatticeEvalCaseType, type LatticeEvalCaseWithTemplate, type LatticeEvalConfig, type LatticeEvalLogEvent, type LatticeEvalLogLevel, LatticeEvalProject, type LatticeEvalProjectType, type LatticeEvalResult, type LatticeEvalRubric, LatticeEvalSuite, type LatticeEvalSuiteType, type LatticeEvalTemplate, LocalSandboxInstance, LocalSandboxProvider, type LocalSandboxProviderConfig, type LoggerLattice, LoggerLatticeManager, MAX_LINE_LENGTH, type MailboxMessage, type MailboxStore, type McpLatticeInterface, McpLatticeManager, type McpServerInfo, MemoryBackend, MemoryLatticeManager, MemoryQueueClient, MemoryScheduleStorage, type MessageCompletedEvent, type MessageFailedEvent, type MessageStartedEvent, MessageType, MetricsServerManager, MicrosandboxRemoteInstance, MicrosandboxRemoteProvider, type MicrosandboxRemoteProviderClient, type MicrosandboxRemoteProviderConfig, MicrosandboxServiceClient, type MicrosandboxServiceClientConfig, type MicrosandboxShellExecInput, type ModelConfig, type ModelLatticeInterface, ModelLatticeManager, MysqlDatabase, type OutputType, type PendingMessage, PersonalAssistantConfig, PinoLoggerClient, PluginRegistry, PostgresDatabase, type PreviewError, PrometheusClient, type QueryResult, type QueueLattice, QueueLatticeManager, QueueMode, type QueuePendingEvent, RemoteSandboxInstance, RemoteSandboxProvider, type RemoteSandboxProviderConfig, type Resolution, type ResolutionAction, type ResolveAgentFn, type ResolvedConfig, type RunSandboxConfig, type RuntimeModelConfig, type SandboxFileInfo, type SandboxFileService, SandboxFilesystem, type SandboxInstance, type SandboxIsolationLevel, SandboxLatticeManager, type SandboxManagerProtocol, type SandboxProvider, type SandboxProviderFactory, type SandboxProviderType, type SandboxShellService, SandboxSkillStore, type SandboxSkillStoreOptions, type SandboxVolumeDefinition, type ScheduleLattice, ScheduleLatticeManager, type SchedulerMiddlewareOptions, SemanticMetricsClient, type SharePayload, SimpleMemoryVectorStore, type SkillLattice, SkillLatticeManager, type SkillMeta, type SkillResource, SqlDatabaseManager, type StateAndStore, StateBackend, StoreBackend, type StoreLattice, StoreLatticeManager, type StoreType, type StoreTypeMap, TOOL_RESULT_TOKEN_LIMIT, TRUNCATION_GUIDANCE, type TableInfo, type TableSchema, type TaskEvent, type TaskListStore, type TaskSpec, TaskStatus, type TaskUpdatable, TeamAgentGraphBuilder, type TeamConfig, type TeamMiddlewareOptions, type TeamTask, type TeammateSpec, type TeammateToolsOptions, type ThreadBuffer, type ThreadBufferConfig, type ThreadBusyEvent, type ThreadIdleEvent, type ThreadInfo, type ThreadQueueConfig, type ThreadState, ThreadStatus, type ThreadStatusChangedEvent, TokenCache, type ToolDefinition, type ToolLattice, ToolLatticeManager, type UnknownToolHandlerConfig, type VectorStoreLatticeInterface, VectorStoreLatticeManager, type VectorStoreProviderLattice, VectorStoreProviderManager, VolumeFilesystem, type VolumeFsClient, type WorkflowValidationError, type WriteResult, abortWorkflowRun, agentInstanceManager, agentLatticeManager, buildGrepResultsDict, buildInput, buildNamedVolumeName, buildSandboxMetadataEnv, buildSkillFile, buildStateAnnotation, buildTableName, checkEmptyContent, clearEncryptionKeyCache, clearEvalRunService, collectionLatticeManager, compileInternal, compileWorkflow, computeSandboxName, configureStores, connectAllChannels, createAgentNode, createAgentTeam, createExecuteSqlQueryTool, createFileData, createInfoSqlTool, createListMetricsDataSourcesTool, createListMetricsServersTool, createListTablesSqlTool, createMapNode, createModelSelectorMiddleware, createNodeHandler, createQueryCheckerSqlTool, createQueryMetricDefinitionTool, createQueryMetricsListTool, createQuerySemanticMetricDataTool, createQuerySqlTool, createQueryTableDefinitionTool, createQueryTablesListTool, createResourceAddress, createSandboxProvider, createSchedulerMiddleware, createSharePayload, createTaskMiddleware, createTeamMiddleware, createTeammateTools, createUnknownToolHandlerMiddleware, createWidgetMiddleware, decrypt, describeCronExpression, embeddingsLatticeManager, encrypt, ensureBuiltinAgentsForTenant, evaluateLatticeCaseWithLogs, eventBus, eventBus as eventBusDefault, extractFetcherError, extractOutput, fileDataToString, formatContentWithLineNumbers, formatGrepMatches, formatGrepResults, formatReadResponse, generateToken, getAgentClient, getAgentConfig, getAllAgentConfigs, getAllBuiltInSkillMetas, getAllToolDefinitions, getBindingRegistry, getBuiltInSkillContent, getBuiltInSkillMeta, getBuiltInSkillNames, getCheckpointSaver, getChunkBuffer, getCollectionEntryCount, getEmbeddingsClient, getEmbeddingsLattice, getEncryptionKey, getEvalRunService, getLoggerLattice, getMenuRegistry, getModelLattice, getNextCronTime, getOrCreateCollectionVectorStore, getQueueLattice, getSandBoxManager, getScheduleLattice, getStoreLattice, getToolClient, getToolDefinition, getToolLattice, getVectorStoreClient, getVectorStoreLattice, getVectorStoreProvider, getWorkflowSignal, globSearchFiles, grepMatchesFromFiles, grepSearchFiles, hasChunkBuffer, invokeWithRetry, isBuiltInSkill, isUsingDefaultKey, isValidCronExpression, isValidSandboxName, isValidSkillName, listCollectionEntries, listSandboxProviderTypes, loggerLatticeManager, mcpManager, metricsServerManager, modelLatticeManager, normalizeSandboxName, parallelLimit, parseCronExpression, parseSkillFrontmatter, parseYaml, performStringReplacement, queueLatticeManager, registerAgentLattice, registerAgentLatticeWithTenant, registerAgentLattices, registerCheckpointSaver, registerChunkBuffer, registerEmbeddingsLattice, registerExistingTool, registerLoggerLattice, registerModelLattice, registerQueueLattice, registerSandboxProviderType, registerScheduleLattice, registerStoreLattice, registerTeammateAgent, registerToolLattice, registerVectorStoreLattice, registerVectorStoreProvider, registerWorkflowRun, removeCollectionVectorStore, renderTemplate, resolvePath, sandboxLatticeManager, sanitizeToolCallId, scheduleLatticeManager, serializePluginMeta, setBindingRegistry, setEvalRunService, setMenuRegistry, skillLatticeManager, sqlDatabaseManager, storeLatticeManager, toJsonSchema, toSafeStateExpr, toolLatticeManager, truncateIfTooLong, unregisterTeammateAgent, unregisterWorkflowRun, updateFileData, validateAgentInput, validateDSL, validateEncryptionKey, validatePath, validateSkillName, validateToolInput, vectorStoreLatticeManager, vectorStoreProviderManager };