@flutchai/flutch-sdk 0.1.5 → 0.1.6

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.cts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { JSONSchema7 } from 'json-schema';
2
2
  import * as _nestjs_common from '@nestjs/common';
3
- import { Logger, Type, CanActivate, ExecutionContext, DynamicModule } from '@nestjs/common';
3
+ import { OnModuleInit, Logger, Type, CanActivate, ExecutionContext, DynamicModule } from '@nestjs/common';
4
4
  import { ConfigService } from '@nestjs/config';
5
5
  import { HumanMessage } from '@langchain/core/messages';
6
6
  import { BaseChannel, CompiledStateGraph, LangGraphRunnableConfig } from '@langchain/langgraph';
@@ -95,12 +95,13 @@ declare function getUIEndpointMethodsMetadata(constructor: any): UIEndpointMetho
95
95
  declare function hasUIEndpoints(constructor: any): boolean;
96
96
  declare function registerUIEndpointsFromClass(endpointRegistry: any, EndpointClass: any, instance?: any): void;
97
97
 
98
- declare class UIEndpointsDiscoveryService {
98
+ declare class UIEndpointsDiscoveryService implements OnModuleInit {
99
99
  private readonly discoveryService;
100
100
  private readonly metadataScanner;
101
101
  private readonly endpointRegistry;
102
102
  private readonly logger;
103
103
  constructor(discoveryService: DiscoveryService, metadataScanner: MetadataScanner, endpointRegistry: EndpointRegistry);
104
+ onModuleInit(): Promise<void>;
104
105
  discoverUIEndpoints(): Promise<void>;
105
106
  private getUIEndpointMethodsCount;
106
107
  }
@@ -579,8 +580,6 @@ interface IGraphCompiler {
579
580
  }
580
581
  type BaseGraphState = {};
581
582
  interface IGraphMetadata {
582
- userId: string;
583
- applicationId: string;
584
583
  workflowType: string;
585
584
  version: string;
586
585
  }
@@ -588,6 +587,8 @@ interface IGraphConfigurable<TGraphSettings = any> {
588
587
  thread_id?: string;
589
588
  metadata?: IGraphMetadata;
590
589
  graphSettings: TGraphSettings;
590
+ userId?: string;
591
+ agentId?: string;
591
592
  }
592
593
  type IGraphRunnableConfig<TGraphSettings = any> = LangGraphRunnableConfig<IGraphConfigurable<TGraphSettings>> & {
593
594
  configurable: IGraphConfigurable<TGraphSettings>;
@@ -1089,6 +1090,20 @@ declare function bootstrap(AppModule: any, options?: {
1089
1090
  globalPrefix?: string;
1090
1091
  }): Promise<_nestjs_common.INestApplication<any>>;
1091
1092
 
1093
+ interface ApiCallTracerOptions {
1094
+ maxStringLength?: number;
1095
+ maxDepth?: number;
1096
+ }
1097
+ declare const DEFAULT_TRACER_OPTIONS: Required<ApiCallTracerOptions>;
1098
+ interface TraceApiCallResult<TResult> {
1099
+ result: TResult;
1100
+ startedAt: number;
1101
+ completedAt: number;
1102
+ durationMs: number;
1103
+ }
1104
+ declare function traceApiCall<TResult>(execute: () => Promise<TResult>, options?: ApiCallTracerOptions): Promise<TraceApiCallResult<TResult>>;
1105
+ declare function sanitizeTraceData(value: unknown, depth?: number, seen?: WeakSet<object>, options?: ApiCallTracerOptions): unknown;
1106
+
1092
1107
  interface LLMCallRecord {
1093
1108
  modelId: string;
1094
1109
  promptTokens: number;
@@ -1169,20 +1184,6 @@ declare class UniversalGraphModule {
1169
1184
  static forRoot(options: UniversalGraphModuleOptions): DynamicModule;
1170
1185
  }
1171
1186
 
1172
- interface ApiCallTracerOptions {
1173
- maxStringLength?: number;
1174
- maxDepth?: number;
1175
- }
1176
- declare const DEFAULT_TRACER_OPTIONS: Required<ApiCallTracerOptions>;
1177
- interface TraceApiCallResult<TResult> {
1178
- result: TResult;
1179
- startedAt: number;
1180
- completedAt: number;
1181
- durationMs: number;
1182
- }
1183
- declare function traceApiCall<TResult>(execute: () => Promise<TResult>, options?: ApiCallTracerOptions): Promise<TraceApiCallResult<TResult>>;
1184
- declare function sanitizeTraceData(value: unknown, depth?: number, seen?: WeakSet<object>, options?: ApiCallTracerOptions): unknown;
1185
-
1186
1187
  declare enum ModelProvider {
1187
1188
  FLUTCH = "flutch",
1188
1189
  FLUTCH_MISTRAL = "flutch-mistral",
@@ -1428,6 +1429,17 @@ declare class McpToolFilter {
1428
1429
  getAvailableToolNames(): Promise<string[]>;
1429
1430
  }
1430
1431
 
1432
+ declare class McpRuntimeHttpClient implements McpRuntimeClient {
1433
+ private readonly logger;
1434
+ private readonly httpClient;
1435
+ private readonly baseUrl;
1436
+ constructor(mcpRuntimeUrl?: string);
1437
+ getTools(): Promise<McpTool[]>;
1438
+ executeTool(name: string, args: any, context?: any): Promise<ToolExecutionResult>;
1439
+ getToolStats(): Promise<any>;
1440
+ isHealthy(): Promise<boolean>;
1441
+ }
1442
+
1431
1443
  declare enum RetrieverSearchType {
1432
1444
  Search = "search",
1433
1445
  MMR = "mmr",
@@ -1496,4 +1508,53 @@ declare class GraphTypeUtils {
1496
1508
  static compareVersions(a: string, b: string): number;
1497
1509
  }
1498
1510
 
1499
- export { type ACLValidationResult, AbstractGraphBuilder, type ApiCallTracerOptions, AttachmentType, type AuditEntry, GraphController as BaseGraphServiceController, UniversalGraphModule as BaseGraphServiceModule, type BaseGraphState, BuilderRegistryService, Callback, CallbackACL, CallbackAuditAction, CallbackAuditor, type CallbackContext, CallbackController, type CallbackEntry, type CallbackHandler, type CallbackMetadata, CallbackMetrics, type CallbackPatch, type CallbackPatchHandler, CallbackPatchService, CallbackRateLimiter, type CallbackRecord, CallbackRegistry, type CallbackRequest, type CallbackResult, CallbackStore, CallbackTokenGuard, type CallbackUser, type ChartType, ChatFeature, type ChatModelCreator, type CitationValue, type CompiledGraphFor, type ConcreteModels, type CustomDocument, DEFAULT_TRACER_OPTIONS, type DataEnvelope, ENDPOINT_METADATA_KEY, type EmbeddingModelCreator, Endpoint, type EndpointDescriptor, type EndpointHandler, type EndpointMetadata, type EndpointOptions, EndpointRegistry, EventProcessor, type ExtendedCallbackContext, type ExtendedCallbackHandler, GraphController, GraphEngineFactory, GraphEngineType, GraphManifestSchema, GraphManifestValidator, GraphServiceTokens, GraphTypeUtils, type IAgentToolConfig, type IAgentToolConfiguration, type IAttachment, type IBaseEntity, type IChartDataPoint, type IChartDataset, type IChartValue, type IDeletionInfo, type IGenericGraphType, type IGraphBuilder, type IGraphCompiler, type IGraphConfigurable, type IGraphEngine, type IGraphManifest, type IGraphMetadata, type IGraphMetadataRegistry, type IGraphRequestPayload, type IGraphResponsePayload, type IGraphRunnableConfig, type IGraphService, type IGraphServiceRegistry, type IGraphSettingsRepository, type IGraphTraceEvent, type IGraphTracer, type IGraphTypeMetadata, type IGraphTypeRegistry, type IModelInitializer, type IReasoningChain, type IReasoningStep, type IStoredMessageContent, type ISystemToolCredentials, type IToolCall, type IToolCatalog, type IToolConfigOption, type IToolExecutionContext, type ITracingEvent, type IUsageMetrics, type IUsageRecorder, type IdempotencyConfig, type IdempotencyEntry, IdempotencyManager, IdempotencyStatus, type KnowledgeBaseInfo, type LLMCallRecord, type LLMConfig, type LLModel, LangGraphEngine, type MappedChannels, McpConverter, type McpRuntimeClient, type McpTool, McpToolFilter, type Model, type ModelByIdConfig, type ModelByIdWithTypeConfig, type ModelConfig, type ModelConfigFetcher, type ModelConfigWithToken, type ModelConfigWithTokenAndType, type ModelCreator, type ModelCreators, ModelInitializer, ModelProvider, ModelType, type RateLimitConfig, type RateLimitResult, type RequestContext, type RerankModelCreator, type RetrieveQueryOptions, type RetrieverConfig, RetrieverSearchType, RetrieverService, type RouterConfig, SmartCallbackRouter, type StreamAccumulator, StreamChannel, type StrictGraphRunnableConfig, TelegramPatchHandler, type ToolExecutionResult, type TraceApiCallResult, type TracingLevel, UIDispatchController, type UIDispatchDto, UIEndpoint, type UIEndpointClassMetadata, type UIEndpointMethodMetadata, UIEndpointsDiscoveryService, UniversalCallbackService, UniversalGraphModule, type UniversalGraphModuleOptions, UniversalGraphService, type VersionResolution, type VersionResolutionOptions, type VersionRoute, VersionedGraphService, type VersioningConfig, VoyageAIRerank, type VoyageAIRerankConfig, WebPatchHandler, WithCallbacks, WithEndpoints, WithUIEndpoints, bootstrap, createEndpointDescriptors, findCallbackMethod, findEndpointMethod, getCallbackMetadata, getEndpointMetadata, getUIEndpointClassMetadata, getUIEndpointMethodsMetadata, hasCallbacks, hasUIEndpoints, prepareModelWithTools, registerFinanceExampleCallback, registerUIEndpointsFromClass, sanitizeTraceData, traceApiCall };
1511
+ interface ServiceDiscoveryProvider {
1512
+ getServices(category: string): Promise<Array<{
1513
+ name: string;
1514
+ address: string;
1515
+ port: number;
1516
+ metadata: Record<string, any>;
1517
+ }>>;
1518
+ }
1519
+
1520
+ declare class FileBasedDiscovery implements ServiceDiscoveryProvider {
1521
+ private readonly logger;
1522
+ private readonly servicesDir;
1523
+ constructor();
1524
+ registerService(name: string, address: string, port: number, metadata: Record<string, any>, graphTypes?: string[]): Promise<void>;
1525
+ unregisterService(name: string): Promise<void>;
1526
+ getServices(graphType: string): Promise<Array<{
1527
+ name: string;
1528
+ address: string;
1529
+ port: number;
1530
+ metadata: Record<string, any>;
1531
+ }>>;
1532
+ findServiceByName(serviceName: string): Promise<{
1533
+ name: string;
1534
+ address: string;
1535
+ port: number;
1536
+ metadata: Record<string, any>;
1537
+ } | null>;
1538
+ private ensureServicesDirectory;
1539
+ private cleanupStaleServices;
1540
+ private isProcessAlive;
1541
+ }
1542
+
1543
+ declare class StaticDiscovery implements ServiceDiscoveryProvider {
1544
+ private readonly services;
1545
+ constructor(services: Array<{
1546
+ name: string;
1547
+ address: string;
1548
+ port: number;
1549
+ metadata: Record<string, any>;
1550
+ category?: string;
1551
+ }>);
1552
+ getServices(category: string): Promise<Array<{
1553
+ name: string;
1554
+ address: string;
1555
+ port: number;
1556
+ metadata: Record<string, any>;
1557
+ }>>;
1558
+ }
1559
+
1560
+ export { type ACLValidationResult, AbstractGraphBuilder, type ApiCallTracerOptions, AttachmentType, type AuditEntry, GraphController as BaseGraphServiceController, UniversalGraphModule as BaseGraphServiceModule, type BaseGraphState, BuilderRegistryService, Callback, CallbackACL, CallbackAuditAction, CallbackAuditor, type CallbackContext, CallbackController, type CallbackEntry, type CallbackHandler, type CallbackMetadata, CallbackMetrics, type CallbackPatch, type CallbackPatchHandler, CallbackPatchService, CallbackRateLimiter, type CallbackRecord, CallbackRegistry, type CallbackRequest, type CallbackResult, CallbackStore, CallbackTokenGuard, type CallbackUser, type ChartType, ChatFeature, type ChatModelCreator, type CitationValue, type CompiledGraphFor, type ConcreteModels, type CustomDocument, DEFAULT_TRACER_OPTIONS, type DataEnvelope, ENDPOINT_METADATA_KEY, type EmbeddingModelCreator, Endpoint, type EndpointDescriptor, type EndpointHandler, type EndpointMetadata, type EndpointOptions, EndpointRegistry, EventProcessor, type ExtendedCallbackContext, type ExtendedCallbackHandler, FileBasedDiscovery, GraphController, GraphEngineFactory, GraphEngineType, GraphManifestSchema, GraphManifestValidator, GraphServiceTokens, GraphTypeUtils, type IAgentToolConfig, type IAgentToolConfiguration, type IAttachment, type IBaseEntity, type IChartDataPoint, type IChartDataset, type IChartValue, type IDeletionInfo, type IGenericGraphType, type IGraphBuilder, type IGraphCompiler, type IGraphConfigurable, type IGraphEngine, type IGraphManifest, type IGraphMetadata, type IGraphMetadataRegistry, type IGraphRequestPayload, type IGraphResponsePayload, type IGraphRunnableConfig, type IGraphService, type IGraphServiceRegistry, type IGraphSettingsRepository, type IGraphTraceEvent, type IGraphTracer, type IGraphTypeMetadata, type IGraphTypeRegistry, type IModelInitializer, type IReasoningChain, type IReasoningStep, type IStoredMessageContent, type ISystemToolCredentials, type IToolCall, type IToolCatalog, type IToolConfigOption, type IToolExecutionContext, type ITracingEvent, type IUsageMetrics, type IUsageRecorder, type IdempotencyConfig, type IdempotencyEntry, IdempotencyManager, IdempotencyStatus, type KnowledgeBaseInfo, type LLMCallRecord, type LLMConfig, type LLModel, LangGraphEngine, type MappedChannels, McpConverter, type McpRuntimeClient, McpRuntimeHttpClient, type McpTool, McpToolFilter, type Model, type ModelByIdConfig, type ModelByIdWithTypeConfig, type ModelConfig, type ModelConfigFetcher, type ModelConfigWithToken, type ModelConfigWithTokenAndType, type ModelCreator, type ModelCreators, ModelInitializer, ModelProvider, ModelType, type RateLimitConfig, type RateLimitResult, type RequestContext, type RerankModelCreator, type RetrieveQueryOptions, type RetrieverConfig, RetrieverSearchType, RetrieverService, type RouterConfig, type ServiceDiscoveryProvider, SmartCallbackRouter, StaticDiscovery, type StreamAccumulator, StreamChannel, type StrictGraphRunnableConfig, TelegramPatchHandler, type ToolExecutionResult, type TraceApiCallResult, type TracingLevel, UIDispatchController, type UIDispatchDto, UIEndpoint, type UIEndpointClassMetadata, type UIEndpointMethodMetadata, UIEndpointsDiscoveryService, UniversalCallbackService, UniversalGraphModule, type UniversalGraphModuleOptions, UniversalGraphService, type VersionResolution, type VersionResolutionOptions, type VersionRoute, VersionedGraphService, type VersioningConfig, VoyageAIRerank, type VoyageAIRerankConfig, WebPatchHandler, WithCallbacks, WithEndpoints, WithUIEndpoints, bootstrap, createEndpointDescriptors, findCallbackMethod, findEndpointMethod, getCallbackMetadata, getEndpointMetadata, getUIEndpointClassMetadata, getUIEndpointMethodsMetadata, hasCallbacks, hasUIEndpoints, prepareModelWithTools, registerFinanceExampleCallback, registerUIEndpointsFromClass, sanitizeTraceData, traceApiCall };
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { JSONSchema7 } from 'json-schema';
2
2
  import * as _nestjs_common from '@nestjs/common';
3
- import { Logger, Type, CanActivate, ExecutionContext, DynamicModule } from '@nestjs/common';
3
+ import { OnModuleInit, Logger, Type, CanActivate, ExecutionContext, DynamicModule } from '@nestjs/common';
4
4
  import { ConfigService } from '@nestjs/config';
5
5
  import { HumanMessage } from '@langchain/core/messages';
6
6
  import { BaseChannel, CompiledStateGraph, LangGraphRunnableConfig } from '@langchain/langgraph';
@@ -95,12 +95,13 @@ declare function getUIEndpointMethodsMetadata(constructor: any): UIEndpointMetho
95
95
  declare function hasUIEndpoints(constructor: any): boolean;
96
96
  declare function registerUIEndpointsFromClass(endpointRegistry: any, EndpointClass: any, instance?: any): void;
97
97
 
98
- declare class UIEndpointsDiscoveryService {
98
+ declare class UIEndpointsDiscoveryService implements OnModuleInit {
99
99
  private readonly discoveryService;
100
100
  private readonly metadataScanner;
101
101
  private readonly endpointRegistry;
102
102
  private readonly logger;
103
103
  constructor(discoveryService: DiscoveryService, metadataScanner: MetadataScanner, endpointRegistry: EndpointRegistry);
104
+ onModuleInit(): Promise<void>;
104
105
  discoverUIEndpoints(): Promise<void>;
105
106
  private getUIEndpointMethodsCount;
106
107
  }
@@ -579,8 +580,6 @@ interface IGraphCompiler {
579
580
  }
580
581
  type BaseGraphState = {};
581
582
  interface IGraphMetadata {
582
- userId: string;
583
- applicationId: string;
584
583
  workflowType: string;
585
584
  version: string;
586
585
  }
@@ -588,6 +587,8 @@ interface IGraphConfigurable<TGraphSettings = any> {
588
587
  thread_id?: string;
589
588
  metadata?: IGraphMetadata;
590
589
  graphSettings: TGraphSettings;
590
+ userId?: string;
591
+ agentId?: string;
591
592
  }
592
593
  type IGraphRunnableConfig<TGraphSettings = any> = LangGraphRunnableConfig<IGraphConfigurable<TGraphSettings>> & {
593
594
  configurable: IGraphConfigurable<TGraphSettings>;
@@ -1089,6 +1090,20 @@ declare function bootstrap(AppModule: any, options?: {
1089
1090
  globalPrefix?: string;
1090
1091
  }): Promise<_nestjs_common.INestApplication<any>>;
1091
1092
 
1093
+ interface ApiCallTracerOptions {
1094
+ maxStringLength?: number;
1095
+ maxDepth?: number;
1096
+ }
1097
+ declare const DEFAULT_TRACER_OPTIONS: Required<ApiCallTracerOptions>;
1098
+ interface TraceApiCallResult<TResult> {
1099
+ result: TResult;
1100
+ startedAt: number;
1101
+ completedAt: number;
1102
+ durationMs: number;
1103
+ }
1104
+ declare function traceApiCall<TResult>(execute: () => Promise<TResult>, options?: ApiCallTracerOptions): Promise<TraceApiCallResult<TResult>>;
1105
+ declare function sanitizeTraceData(value: unknown, depth?: number, seen?: WeakSet<object>, options?: ApiCallTracerOptions): unknown;
1106
+
1092
1107
  interface LLMCallRecord {
1093
1108
  modelId: string;
1094
1109
  promptTokens: number;
@@ -1169,20 +1184,6 @@ declare class UniversalGraphModule {
1169
1184
  static forRoot(options: UniversalGraphModuleOptions): DynamicModule;
1170
1185
  }
1171
1186
 
1172
- interface ApiCallTracerOptions {
1173
- maxStringLength?: number;
1174
- maxDepth?: number;
1175
- }
1176
- declare const DEFAULT_TRACER_OPTIONS: Required<ApiCallTracerOptions>;
1177
- interface TraceApiCallResult<TResult> {
1178
- result: TResult;
1179
- startedAt: number;
1180
- completedAt: number;
1181
- durationMs: number;
1182
- }
1183
- declare function traceApiCall<TResult>(execute: () => Promise<TResult>, options?: ApiCallTracerOptions): Promise<TraceApiCallResult<TResult>>;
1184
- declare function sanitizeTraceData(value: unknown, depth?: number, seen?: WeakSet<object>, options?: ApiCallTracerOptions): unknown;
1185
-
1186
1187
  declare enum ModelProvider {
1187
1188
  FLUTCH = "flutch",
1188
1189
  FLUTCH_MISTRAL = "flutch-mistral",
@@ -1428,6 +1429,17 @@ declare class McpToolFilter {
1428
1429
  getAvailableToolNames(): Promise<string[]>;
1429
1430
  }
1430
1431
 
1432
+ declare class McpRuntimeHttpClient implements McpRuntimeClient {
1433
+ private readonly logger;
1434
+ private readonly httpClient;
1435
+ private readonly baseUrl;
1436
+ constructor(mcpRuntimeUrl?: string);
1437
+ getTools(): Promise<McpTool[]>;
1438
+ executeTool(name: string, args: any, context?: any): Promise<ToolExecutionResult>;
1439
+ getToolStats(): Promise<any>;
1440
+ isHealthy(): Promise<boolean>;
1441
+ }
1442
+
1431
1443
  declare enum RetrieverSearchType {
1432
1444
  Search = "search",
1433
1445
  MMR = "mmr",
@@ -1496,4 +1508,53 @@ declare class GraphTypeUtils {
1496
1508
  static compareVersions(a: string, b: string): number;
1497
1509
  }
1498
1510
 
1499
- export { type ACLValidationResult, AbstractGraphBuilder, type ApiCallTracerOptions, AttachmentType, type AuditEntry, GraphController as BaseGraphServiceController, UniversalGraphModule as BaseGraphServiceModule, type BaseGraphState, BuilderRegistryService, Callback, CallbackACL, CallbackAuditAction, CallbackAuditor, type CallbackContext, CallbackController, type CallbackEntry, type CallbackHandler, type CallbackMetadata, CallbackMetrics, type CallbackPatch, type CallbackPatchHandler, CallbackPatchService, CallbackRateLimiter, type CallbackRecord, CallbackRegistry, type CallbackRequest, type CallbackResult, CallbackStore, CallbackTokenGuard, type CallbackUser, type ChartType, ChatFeature, type ChatModelCreator, type CitationValue, type CompiledGraphFor, type ConcreteModels, type CustomDocument, DEFAULT_TRACER_OPTIONS, type DataEnvelope, ENDPOINT_METADATA_KEY, type EmbeddingModelCreator, Endpoint, type EndpointDescriptor, type EndpointHandler, type EndpointMetadata, type EndpointOptions, EndpointRegistry, EventProcessor, type ExtendedCallbackContext, type ExtendedCallbackHandler, GraphController, GraphEngineFactory, GraphEngineType, GraphManifestSchema, GraphManifestValidator, GraphServiceTokens, GraphTypeUtils, type IAgentToolConfig, type IAgentToolConfiguration, type IAttachment, type IBaseEntity, type IChartDataPoint, type IChartDataset, type IChartValue, type IDeletionInfo, type IGenericGraphType, type IGraphBuilder, type IGraphCompiler, type IGraphConfigurable, type IGraphEngine, type IGraphManifest, type IGraphMetadata, type IGraphMetadataRegistry, type IGraphRequestPayload, type IGraphResponsePayload, type IGraphRunnableConfig, type IGraphService, type IGraphServiceRegistry, type IGraphSettingsRepository, type IGraphTraceEvent, type IGraphTracer, type IGraphTypeMetadata, type IGraphTypeRegistry, type IModelInitializer, type IReasoningChain, type IReasoningStep, type IStoredMessageContent, type ISystemToolCredentials, type IToolCall, type IToolCatalog, type IToolConfigOption, type IToolExecutionContext, type ITracingEvent, type IUsageMetrics, type IUsageRecorder, type IdempotencyConfig, type IdempotencyEntry, IdempotencyManager, IdempotencyStatus, type KnowledgeBaseInfo, type LLMCallRecord, type LLMConfig, type LLModel, LangGraphEngine, type MappedChannels, McpConverter, type McpRuntimeClient, type McpTool, McpToolFilter, type Model, type ModelByIdConfig, type ModelByIdWithTypeConfig, type ModelConfig, type ModelConfigFetcher, type ModelConfigWithToken, type ModelConfigWithTokenAndType, type ModelCreator, type ModelCreators, ModelInitializer, ModelProvider, ModelType, type RateLimitConfig, type RateLimitResult, type RequestContext, type RerankModelCreator, type RetrieveQueryOptions, type RetrieverConfig, RetrieverSearchType, RetrieverService, type RouterConfig, SmartCallbackRouter, type StreamAccumulator, StreamChannel, type StrictGraphRunnableConfig, TelegramPatchHandler, type ToolExecutionResult, type TraceApiCallResult, type TracingLevel, UIDispatchController, type UIDispatchDto, UIEndpoint, type UIEndpointClassMetadata, type UIEndpointMethodMetadata, UIEndpointsDiscoveryService, UniversalCallbackService, UniversalGraphModule, type UniversalGraphModuleOptions, UniversalGraphService, type VersionResolution, type VersionResolutionOptions, type VersionRoute, VersionedGraphService, type VersioningConfig, VoyageAIRerank, type VoyageAIRerankConfig, WebPatchHandler, WithCallbacks, WithEndpoints, WithUIEndpoints, bootstrap, createEndpointDescriptors, findCallbackMethod, findEndpointMethod, getCallbackMetadata, getEndpointMetadata, getUIEndpointClassMetadata, getUIEndpointMethodsMetadata, hasCallbacks, hasUIEndpoints, prepareModelWithTools, registerFinanceExampleCallback, registerUIEndpointsFromClass, sanitizeTraceData, traceApiCall };
1511
+ interface ServiceDiscoveryProvider {
1512
+ getServices(category: string): Promise<Array<{
1513
+ name: string;
1514
+ address: string;
1515
+ port: number;
1516
+ metadata: Record<string, any>;
1517
+ }>>;
1518
+ }
1519
+
1520
+ declare class FileBasedDiscovery implements ServiceDiscoveryProvider {
1521
+ private readonly logger;
1522
+ private readonly servicesDir;
1523
+ constructor();
1524
+ registerService(name: string, address: string, port: number, metadata: Record<string, any>, graphTypes?: string[]): Promise<void>;
1525
+ unregisterService(name: string): Promise<void>;
1526
+ getServices(graphType: string): Promise<Array<{
1527
+ name: string;
1528
+ address: string;
1529
+ port: number;
1530
+ metadata: Record<string, any>;
1531
+ }>>;
1532
+ findServiceByName(serviceName: string): Promise<{
1533
+ name: string;
1534
+ address: string;
1535
+ port: number;
1536
+ metadata: Record<string, any>;
1537
+ } | null>;
1538
+ private ensureServicesDirectory;
1539
+ private cleanupStaleServices;
1540
+ private isProcessAlive;
1541
+ }
1542
+
1543
+ declare class StaticDiscovery implements ServiceDiscoveryProvider {
1544
+ private readonly services;
1545
+ constructor(services: Array<{
1546
+ name: string;
1547
+ address: string;
1548
+ port: number;
1549
+ metadata: Record<string, any>;
1550
+ category?: string;
1551
+ }>);
1552
+ getServices(category: string): Promise<Array<{
1553
+ name: string;
1554
+ address: string;
1555
+ port: number;
1556
+ metadata: Record<string, any>;
1557
+ }>>;
1558
+ }
1559
+
1560
+ export { type ACLValidationResult, AbstractGraphBuilder, type ApiCallTracerOptions, AttachmentType, type AuditEntry, GraphController as BaseGraphServiceController, UniversalGraphModule as BaseGraphServiceModule, type BaseGraphState, BuilderRegistryService, Callback, CallbackACL, CallbackAuditAction, CallbackAuditor, type CallbackContext, CallbackController, type CallbackEntry, type CallbackHandler, type CallbackMetadata, CallbackMetrics, type CallbackPatch, type CallbackPatchHandler, CallbackPatchService, CallbackRateLimiter, type CallbackRecord, CallbackRegistry, type CallbackRequest, type CallbackResult, CallbackStore, CallbackTokenGuard, type CallbackUser, type ChartType, ChatFeature, type ChatModelCreator, type CitationValue, type CompiledGraphFor, type ConcreteModels, type CustomDocument, DEFAULT_TRACER_OPTIONS, type DataEnvelope, ENDPOINT_METADATA_KEY, type EmbeddingModelCreator, Endpoint, type EndpointDescriptor, type EndpointHandler, type EndpointMetadata, type EndpointOptions, EndpointRegistry, EventProcessor, type ExtendedCallbackContext, type ExtendedCallbackHandler, FileBasedDiscovery, GraphController, GraphEngineFactory, GraphEngineType, GraphManifestSchema, GraphManifestValidator, GraphServiceTokens, GraphTypeUtils, type IAgentToolConfig, type IAgentToolConfiguration, type IAttachment, type IBaseEntity, type IChartDataPoint, type IChartDataset, type IChartValue, type IDeletionInfo, type IGenericGraphType, type IGraphBuilder, type IGraphCompiler, type IGraphConfigurable, type IGraphEngine, type IGraphManifest, type IGraphMetadata, type IGraphMetadataRegistry, type IGraphRequestPayload, type IGraphResponsePayload, type IGraphRunnableConfig, type IGraphService, type IGraphServiceRegistry, type IGraphSettingsRepository, type IGraphTraceEvent, type IGraphTracer, type IGraphTypeMetadata, type IGraphTypeRegistry, type IModelInitializer, type IReasoningChain, type IReasoningStep, type IStoredMessageContent, type ISystemToolCredentials, type IToolCall, type IToolCatalog, type IToolConfigOption, type IToolExecutionContext, type ITracingEvent, type IUsageMetrics, type IUsageRecorder, type IdempotencyConfig, type IdempotencyEntry, IdempotencyManager, IdempotencyStatus, type KnowledgeBaseInfo, type LLMCallRecord, type LLMConfig, type LLModel, LangGraphEngine, type MappedChannels, McpConverter, type McpRuntimeClient, McpRuntimeHttpClient, type McpTool, McpToolFilter, type Model, type ModelByIdConfig, type ModelByIdWithTypeConfig, type ModelConfig, type ModelConfigFetcher, type ModelConfigWithToken, type ModelConfigWithTokenAndType, type ModelCreator, type ModelCreators, ModelInitializer, ModelProvider, ModelType, type RateLimitConfig, type RateLimitResult, type RequestContext, type RerankModelCreator, type RetrieveQueryOptions, type RetrieverConfig, RetrieverSearchType, RetrieverService, type RouterConfig, type ServiceDiscoveryProvider, SmartCallbackRouter, StaticDiscovery, type StreamAccumulator, StreamChannel, type StrictGraphRunnableConfig, TelegramPatchHandler, type ToolExecutionResult, type TraceApiCallResult, type TracingLevel, UIDispatchController, type UIDispatchDto, UIEndpoint, type UIEndpointClassMetadata, type UIEndpointMethodMetadata, UIEndpointsDiscoveryService, UniversalCallbackService, UniversalGraphModule, type UniversalGraphModuleOptions, UniversalGraphService, type VersionResolution, type VersionResolutionOptions, type VersionRoute, VersionedGraphService, type VersioningConfig, VoyageAIRerank, type VoyageAIRerankConfig, WebPatchHandler, WithCallbacks, WithEndpoints, WithUIEndpoints, bootstrap, createEndpointDescriptors, findCallbackMethod, findEndpointMethod, getCallbackMetadata, getEndpointMetadata, getUIEndpointClassMetadata, getUIEndpointMethodsMetadata, hasCallbacks, hasUIEndpoints, prepareModelWithTools, registerFinanceExampleCallback, registerUIEndpointsFromClass, sanitizeTraceData, traceApiCall };