Skip to content

@codesoul-co/hypha-tools / execution-adapter

模块用法

用于把外部或本地 Provider 绑定到 Hypha Port。Execution adapter 模块公开 2 类、1 常量、3 函数、10 接口、2 类型。

从包入口导入

ts
import {
  ExecutionToolAdapter,
  ExecutionToolTerminalError,
  EXECUTION_TOOL_TERMINAL_STATES,
  hashExecutionToolInput,
  normalizeExecutionToolInput,
  validateExecutionToolRuntimeRequest,
} from '@codesoul-co/hypha-tools';

import type {
  ExecutionToolAdapterOptions,
  ExecutionToolDispatchFactoryRequest,
  ExecutionToolDispatchPlan,
  ExecutionToolEvidence,
  ExecutionToolObservation,
  ExecutionToolProvenance,
  ExecutionToolRuntimePort,
  ExecutionToolRuntimeRequest,
} from '@codesoul-co/hypha-tools';

// 完整导出列表见下方。

使用要点

  • 12 个类型/接口用于应用代码、Adapter 或测试中的静态契约;请使用 import type,运行时不应依赖它们。
  • 2 个类提供可实例化的运行时实现;构造参数与公开方法在各自条目中完整列出。
  • 3 个函数是该模块的直接操作入口;每个 overload 的必需/可选参数与返回类型均在下方列出。
  • 1 个常量/枚举提供稳定值、Schema、Definition 或默认配置;应复用这些导出,避免在应用中复制内部值。

公共导出

Symbol种类签名说明
ExecutionToolAdapternew ExecutionToolAdapter<TInput = unknown>(id: string, port: ExecutionToolRuntimePort, createDispatch: ExecutionToolDispatchFactory<TInput>, options: ExecutionToolAdapterOptions): ExecutionToolAdapter<TInput>Execution Tool Adapter 类,共公开 8 个构造函数或成员;精确签名见本条目的声明与成员表。
ExecutionToolTerminalErrornew ExecutionToolTerminalError(observation: ExecutionToolObservation): ExecutionToolTerminalErrorExecution Tool Terminal Error 类,共公开 13 个构造函数或成员;精确签名见本条目的声明与成员表。
EXECUTION_TOOL_TERMINAL_STATES常量const EXECUTION_TOOL_TERMINAL_STATES: readonly ["completed", "failed", "timed_out", "cancelled", "unknown", "quarantined"]execution-adapter 模块导出的 EXECUTION TOOL TERMINAL STATES 常量。
hashExecutionToolInput函数hashExecutionToolInput(input: unknown): stringHash Execution Tool Input 函数,提供 1 个公开调用签名;参数与返回类型见下表。
normalizeExecutionToolInput函数normalizeExecutionToolInput<TInput>(input: TInput): TInputNormalize Execution Tool Input 函数,提供 1 个公开调用签名;参数与返回类型见下表。
validateExecutionToolRuntimeRequest函数validateExecutionToolRuntimeRequest<TInput>(input: ExecutionToolRuntimeRequest<TInput>): ExecutionToolRuntimeRequest<TInput>Recomputes the normalized input digest at the Execution boundary. Runtime-port implementations must call this validator before delegating to a provider.
ExecutionToolAdapterOptions接口interface ExecutionToolAdapterOptionsExecution Tool Adapter Options 接口,共包含 6 个公开字段或方法。
ExecutionToolDispatchFactoryRequest接口interface ExecutionToolDispatchFactoryRequest extends AdapterExecutionRequest<TInput>Execution Tool Dispatch Factory Request 接口,共包含 6 个公开字段或方法。
ExecutionToolDispatchPlan接口interface ExecutionToolDispatchPlanExecution Tool Dispatch Plan 接口,共包含 3 个公开字段或方法。
ExecutionToolEvidence接口interface ExecutionToolEvidenceExecution Tool Evidence 接口,共包含 4 个公开字段或方法。
ExecutionToolObservation接口interface ExecutionToolObservation extends ExecutionToolRuntimeResultExecution Tool Observation 接口,共包含 14 个公开字段或方法。
ExecutionToolProvenance接口interface ExecutionToolProvenanceExecution Tool Provenance 接口,共包含 7 个公开字段或方法。
ExecutionToolRuntimePort接口interface ExecutionToolRuntimePortExecution Tool Runtime Port 接口,共包含 3 个公开字段或方法。
ExecutionToolRuntimeRequest接口interface ExecutionToolRuntimeRequestExecution Tool Runtime Request 接口,共包含 4 个公开字段或方法。
ExecutionToolRuntimeResult接口interface ExecutionToolRuntimeResultExecution Tool Runtime Result 接口,共包含 13 个公开字段或方法。
ExecutionToolRuntimeScope接口interface ExecutionToolRuntimeScopeExecution Tool Runtime Scope 接口,共包含 6 个公开字段或方法。
ExecutionToolDispatchFactory类型type ExecutionToolDispatchFactory = (request: ExecutionToolDispatchFactoryRequest<TInput>) => Promise<ExecutionToolDispatchPlan> | ExecutionToolDispatchPlanExecution Tool Dispatch Factory 公共类型别名;完整类型表达式见声明。
ExecutionToolTerminalState类型type ExecutionToolTerminalState = (typeof EXECUTION_TOOL_TERMINAL_STATES)[number]Execution Tool Terminal State 公共类型别名;完整类型表达式见声明。

ExecutionToolAdapter

Execution Tool Adapter 类,共公开 8 个构造函数或成员;精确签名见本条目的声明与成员表。

  • 种类: 类
  • 导入: import { ExecutionToolAdapter } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export declare class ExecutionToolAdapter<TInput = unknown> implements ToolAdapter<TInput, ExecutionToolObservation> {
    readonly id: string;
    readonly source: ToolSource;
    constructor(id: string, port: ExecutionToolRuntimePort, createDispatch: ExecutionToolDispatchFactory<TInput>, options: ExecutionToolAdapterOptions);
    capabilities(): Promise<ToolAdapterCapabilities>;
    execute(request: AdapterExecutionRequest<TInput>): Promise<ToolExecutionEnvelope<ExecutionToolObservation>>;
    cancel(request: AdapterCancellationRequest): Promise<void>;
    health(): Promise<ProviderHealth>;
    close(): Promise<void>;
}

公开成员

成员种类签名说明
cancel方法cancel(request: AdapterCancellationRequest): Promise<void>公开方法;参数与返回类型以签名列为准。
capabilities方法capabilities(): Promise<ToolAdapterCapabilities>公开方法;参数与返回类型以签名列为准。
close方法close(): Promise<void>公开方法;参数与返回类型以签名列为准。
constructor构造函数<TInput = unknown>(id: string, port: ExecutionToolRuntimePort, createDispatch: ExecutionToolDispatchFactory<TInput>, options: ExecutionToolAdapterOptions): ExecutionToolAdapter<TInput>创建该类的实例。
execute方法execute(request: AdapterExecutionRequest<TInput>): Promise<ToolExecutionEnvelope<ExecutionToolObservation>>公开方法;参数与返回类型以签名列为准。
health方法health(): Promise<ProviderHealth>公开方法;参数与返回类型以签名列为准。
id属性readonly id: string公开属性;类型、只读和可选状态以签名列为准。
source属性readonly source: ToolSource公开属性;类型、只读和可选状态以签名列为准。

ExecutionToolTerminalError

Execution Tool Terminal Error 类,共公开 13 个构造函数或成员;精确签名见本条目的声明与成员表。

  • 种类: 类
  • 导入: import { ExecutionToolTerminalError } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export declare class ExecutionToolTerminalError extends FrameworkError {
    readonly terminalState: Exclude<ExecutionToolTerminalState, 'completed'>;
    readonly executionError: NormalizedExecutionError;
    readonly observation: ExecutionToolObservation;
    constructor(observation: ExecutionToolObservation);
}

公开成员

成员种类签名说明
cause属性readonly cause?: unknown公开属性;类型、只读和可选状态以签名列为准。
code属性readonly code: string公开属性;类型、只读和可选状态以签名列为准。
constructor构造函数(observation: ExecutionToolObservation): ExecutionToolTerminalError创建该类的实例。
context属性readonly context?: Record<string, unknown>公开属性;类型、只读和可选状态以签名列为准。
executionError属性readonly executionError: NormalizedExecutionError公开属性;类型、只读和可选状态以签名列为准。
message属性message: string公开属性;类型、只读和可选状态以签名列为准。
name属性name: string公开属性;类型、只读和可选状态以签名列为准。
observation属性readonly observation: ExecutionToolObservation公开属性;类型、只读和可选状态以签名列为准。
stack属性stack?: string公开属性;类型、只读和可选状态以签名列为准。
static captureStackTrace方法static captureStackTrace(targetObject: object, constructorOpt?: Function): voidCreates a .stack property on targetObject, which when accessed returns a string representing the location in the code at which Error.captureStackTrace() was called. js const myObject = {}; Error.captureStackTrace(myObject); myObject.stack; // Similar to `new Error().stack` The first line of the trace will be prefixed with ${myObject.name}: ${myObject.message}. The optional constructorOpt argument accepts a function. If given, all frames above constructorOpt, including constructorOpt, will be omitted from the generated stack trace. The constructorOpt argument is useful for hiding implementation details of error generation from the user. For instance: js function a() { b(); } function b() { c(); } function c() { // Create an error without stack trace to avoid calculating the stack trace twice. const { stackTraceLimit } = Error; Error.stackTraceLimit = 0; const error = new Error(); Error.stackTraceLimit = stackTraceLimit; // Capture the stack trace above function b Error.captureStackTrace(error, b); // Neither function c, nor b is included in the stack trace throw error; } a();
static prepareStackTrace方法static prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any公开方法;参数与返回类型以签名列为准。
static stackTraceLimit属性static stackTraceLimit: numberThe Error.stackTraceLimit property specifies the number of stack frames collected by a stack trace (whether generated by new Error().stack or Error.captureStackTrace(obj)). The default value is 10 but may be set to any valid JavaScript number. Changes will affect any stack trace captured after the value has been changed. If set to a non-number value, or set to a negative number, stack traces will not capture any frames.
terminalState属性readonly terminalState: "unknown" | "cancelled" | "failed" | "timed_out" | "quarantined"公开属性;类型、只读和可选状态以签名列为准。

EXECUTION_TOOL_TERMINAL_STATES

execution-adapter 模块导出的 EXECUTION TOOL TERMINAL STATES 常量。

  • 种类: 常量
  • 导入: import { EXECUTION_TOOL_TERMINAL_STATES } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export declare const EXECUTION_TOOL_TERMINAL_STATES: readonly ["completed", "failed", "timed_out", "cancelled", "unknown", "quarantined"];

hashExecutionToolInput

Hash Execution Tool Input 函数,提供 1 个公开调用签名;参数与返回类型见下表。

  • 种类: 函数
  • 导入: import { hashExecutionToolInput } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export declare function hashExecutionToolInput(input: unknown): string;

调用签名

text
hashExecutionToolInput(input: unknown): string

参数

参数类型必需说明
inputunknown必需参数;接受的值由类型列定义。

返回值

  • 类型: string
  • 说明: 返回值契约由上述类型定义。

normalizeExecutionToolInput

Normalize Execution Tool Input 函数,提供 1 个公开调用签名;参数与返回类型见下表。

  • 种类: 函数
  • 导入: import { normalizeExecutionToolInput } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export declare function normalizeExecutionToolInput<TInput>(input: TInput): TInput;

调用签名

text
normalizeExecutionToolInput<TInput>(input: TInput): TInput

参数

参数类型必需说明
inputTInput必需参数;接受的值由类型列定义。

返回值

  • 类型: TInput
  • 说明: 返回值契约由上述类型定义。

validateExecutionToolRuntimeRequest

Recomputes the normalized input digest at the Execution boundary. Runtime-port implementations must call this validator before delegating to a provider.

  • 种类: 函数
  • 导入: import { validateExecutionToolRuntimeRequest } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export declare function validateExecutionToolRuntimeRequest<TInput>(input: ExecutionToolRuntimeRequest<TInput>): ExecutionToolRuntimeRequest<TInput>;

调用签名

text
validateExecutionToolRuntimeRequest<TInput>(input: ExecutionToolRuntimeRequest<TInput>): ExecutionToolRuntimeRequest<TInput>

Recomputes the normalized input digest at the Execution boundary. Runtime-port implementations must call this validator before delegating to a provider.

参数

参数类型必需说明
inputExecutionToolRuntimeRequest<TInput>必需参数;接受的值由类型列定义。

返回值

  • 类型: ExecutionToolRuntimeRequest<TInput>
  • 说明: 返回值契约由上述类型定义。

ExecutionToolAdapterOptions

Execution Tool Adapter Options 接口,共包含 6 个公开字段或方法。

  • 种类: 接口
  • 导入: import type { ExecutionToolAdapterOptions } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export interface ExecutionToolAdapterOptions {
    toolRevision: string;
    binding: ExecutionToolBinding;
    providerId: string;
    healthTimeoutMs?: number;
    maxEvidenceBytes?: number;
    now?: () => string;
}

契约成员

成员种类签名说明
binding属性binding: ExecutionToolBinding公开属性;类型、只读和可选状态以签名列为准。
healthTimeoutMs属性healthTimeoutMs?: number公开属性;类型、只读和可选状态以签名列为准。
maxEvidenceBytes属性maxEvidenceBytes?: number公开属性;类型、只读和可选状态以签名列为准。
now方法now?(): string公开方法;参数与返回类型以签名列为准。
providerId属性providerId: string公开属性;类型、只读和可选状态以签名列为准。
toolRevision属性toolRevision: string公开属性;类型、只读和可选状态以签名列为准。

ExecutionToolDispatchFactoryRequest

Execution Tool Dispatch Factory Request 接口,共包含 6 个公开字段或方法。

  • 种类: 接口
  • 导入: import type { ExecutionToolDispatchFactoryRequest } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export interface ExecutionToolDispatchFactoryRequest<TInput> extends AdapterExecutionRequest<TInput> {
    normalizedInput: TInput;
    inputHash: string;
    signal: AbortSignal;
}

契约成员

成员种类签名说明
context属性context: ToolCallContext公开属性;类型、只读和可选状态以签名列为准。
input属性input: TInput公开属性;类型、只读和可选状态以签名列为准。
inputHash属性inputHash: string公开属性;类型、只读和可选状态以签名列为准。
normalizedInput属性normalizedInput: TInput公开属性;类型、只读和可选状态以签名列为准。
signal属性signal: AbortSignal公开属性;类型、只读和可选状态以签名列为准。
toolId属性toolId: string公开属性;类型、只读和可选状态以签名列为准。

ExecutionToolDispatchPlan

Execution Tool Dispatch Plan 接口,共包含 3 个公开字段或方法。

  • 种类: 接口
  • 导入: import type { ExecutionToolDispatchPlan } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export interface ExecutionToolDispatchPlan {
    dispatch: ExecutionDispatchRequest;
    expectedRevision: number;
    approvalExpiresAt?: string;
}

契约成员

成员种类签名说明
approvalExpiresAt属性approvalExpiresAt?: string公开属性;类型、只读和可选状态以签名列为准。
dispatch属性dispatch: ExecutionDispatchRequest公开属性;类型、只读和可选状态以签名列为准。
expectedRevision属性expectedRevision: number公开属性;类型、只读和可选状态以签名列为准。

ExecutionToolEvidence

Execution Tool Evidence 接口,共包含 4 个公开字段或方法。

  • 种类: 接口
  • 导入: import type { ExecutionToolEvidence } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export interface ExecutionToolEvidence {
    kind: 'authorization' | 'event' | 'receipt' | 'artifact' | 'snapshot' | 'trace';
    ref: string;
    hash?: string;
    recordedAt?: string;
}

契约成员

成员种类签名说明
hash属性hash?: string公开属性;类型、只读和可选状态以签名列为准。
kind属性kind: "artifact" | "event" | "snapshot" | "authorization" | "trace" | "receipt"公开属性;类型、只读和可选状态以签名列为准。
recordedAt属性recordedAt?: string公开属性;类型、只读和可选状态以签名列为准。
ref属性ref: string公开属性;类型、只读和可选状态以签名列为准。

ExecutionToolObservation

Execution Tool Observation 接口,共包含 14 个公开字段或方法。

  • 种类: 接口
  • 导入: import type { ExecutionToolObservation } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export interface ExecutionToolObservation extends ExecutionToolRuntimeResult {
    evidenceHash: string;
}

契约成员

成员种类签名说明
activityResult属性activityResult: ExecutionActivityResult公开属性;类型、只读和可选状态以签名列为准。
contractSnapshotRef属性contractSnapshotRef: string公开属性;类型、只读和可选状态以签名列为准。
evidence属性evidence: ExecutionToolEvidence[]公开属性;类型、只读和可选状态以签名列为准。
evidenceHash属性evidenceHash: string公开属性;类型、只读和可选状态以签名列为准。
fencingToken属性fencingToken: number公开属性;类型、只读和可选状态以签名列为准。
inputHash属性inputHash: string公开属性;类型、只读和可选状态以签名列为准。
operationId属性operationId: string公开属性;类型、只读和可选状态以签名列为准。
provenance属性provenance: ExecutionToolProvenance公开属性;类型、只读和可选状态以签名列为准。
revision属性revision: number公开属性;类型、只读和可选状态以签名列为准。
scope属性scope: ExecutionToolRuntimeScope公开属性;类型、只读和可选状态以签名列为准。
terminalState属性terminalState: "unknown" | "completed" | "cancelled" | "failed" | "timed_out" | "quarantined"公开属性;类型、只读和可选状态以签名列为准。
toolId属性toolId: string公开属性;类型、只读和可选状态以签名列为准。
toolOperation属性toolOperation: "artifact" | "command" | "file_read" | "file_write" | "sandbox"公开属性;类型、只读和可选状态以签名列为准。
toolRevision属性toolRevision: string公开属性;类型、只读和可选状态以签名列为准。

ExecutionToolProvenance

Execution Tool Provenance 接口,共包含 7 个公开字段或方法。

  • 种类: 接口
  • 导入: import type { ExecutionToolProvenance } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export interface ExecutionToolProvenance {
    providerId: string;
    authorizationEvidenceId: string;
    authorizationVerificationRef: string;
    terminalEventId: string;
    receivedAt: string;
    resultHash: string;
    receiptRef?: string;
}

契约成员

成员种类签名说明
authorizationEvidenceId属性authorizationEvidenceId: string公开属性;类型、只读和可选状态以签名列为准。
authorizationVerificationRef属性authorizationVerificationRef: string公开属性;类型、只读和可选状态以签名列为准。
providerId属性providerId: string公开属性;类型、只读和可选状态以签名列为准。
receiptRef属性receiptRef?: string公开属性;类型、只读和可选状态以签名列为准。
receivedAt属性receivedAt: string公开属性;类型、只读和可选状态以签名列为准。
resultHash属性resultHash: string公开属性;类型、只读和可选状态以签名列为准。
terminalEventId属性terminalEventId: string公开属性;类型、只读和可选状态以签名列为准。

ExecutionToolRuntimePort

Execution Tool Runtime Port 接口,共包含 3 个公开字段或方法。

  • 种类: 接口
  • 导入: import type { ExecutionToolRuntimePort } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export interface ExecutionToolRuntimePort {
    execute(request: ExecutionToolRuntimeRequest, signal: AbortSignal): Promise<unknown>;
    health(signal: AbortSignal): Promise<unknown>;
    close?(): Promise<void>;
}

契约成员

成员种类签名说明
close方法close?(): Promise<void>公开方法;参数与返回类型以签名列为准。
execute方法execute(request: ExecutionToolRuntimeRequest, signal: AbortSignal): Promise<unknown>公开方法;参数与返回类型以签名列为准。
health方法health(signal: AbortSignal): Promise<unknown>公开方法;参数与返回类型以签名列为准。

ExecutionToolRuntimeRequest

Execution Tool Runtime Request 接口,共包含 4 个公开字段或方法。

  • 种类: 接口
  • 导入: import type { ExecutionToolRuntimeRequest } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export interface ExecutionToolRuntimeRequest<TInput = unknown> {
    dispatch: ExecutionDispatchRequest;
    normalizedInput: TInput;
    inputHash: string;
    expectedRevision: number;
}

契约成员

成员种类签名说明
dispatch属性dispatch: ExecutionDispatchRequest公开属性;类型、只读和可选状态以签名列为准。
expectedRevision属性expectedRevision: number公开属性;类型、只读和可选状态以签名列为准。
inputHash属性inputHash: string公开属性;类型、只读和可选状态以签名列为准。
normalizedInput属性normalizedInput: TInput公开属性;类型、只读和可选状态以签名列为准。

ExecutionToolRuntimeResult

Execution Tool Runtime Result 接口,共包含 13 个公开字段或方法。

  • 种类: 接口
  • 导入: import type { ExecutionToolRuntimeResult } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export interface ExecutionToolRuntimeResult {
    activityResult: ExecutionActivityResult;
    scope: ExecutionToolRuntimeScope;
    toolId: string;
    toolRevision: string;
    contractSnapshotRef: string;
    toolOperation: ExecutionDispatchRequest['binding']['operation'];
    operationId: string;
    inputHash: string;
    revision: number;
    fencingToken: number;
    terminalState: ExecutionToolTerminalState;
    provenance: ExecutionToolProvenance;
    evidence: ExecutionToolEvidence[];
}

契约成员

成员种类签名说明
activityResult属性activityResult: ExecutionActivityResult公开属性;类型、只读和可选状态以签名列为准。
contractSnapshotRef属性contractSnapshotRef: string公开属性;类型、只读和可选状态以签名列为准。
evidence属性evidence: ExecutionToolEvidence[]公开属性;类型、只读和可选状态以签名列为准。
fencingToken属性fencingToken: number公开属性;类型、只读和可选状态以签名列为准。
inputHash属性inputHash: string公开属性;类型、只读和可选状态以签名列为准。
operationId属性operationId: string公开属性;类型、只读和可选状态以签名列为准。
provenance属性provenance: ExecutionToolProvenance公开属性;类型、只读和可选状态以签名列为准。
revision属性revision: number公开属性;类型、只读和可选状态以签名列为准。
scope属性scope: ExecutionToolRuntimeScope公开属性;类型、只读和可选状态以签名列为准。
terminalState属性terminalState: "unknown" | "completed" | "cancelled" | "failed" | "timed_out" | "quarantined"公开属性;类型、只读和可选状态以签名列为准。
toolId属性toolId: string公开属性;类型、只读和可选状态以签名列为准。
toolOperation属性toolOperation: "artifact" | "command" | "file_read" | "file_write" | "sandbox"公开属性;类型、只读和可选状态以签名列为准。
toolRevision属性toolRevision: string公开属性;类型、只读和可选状态以签名列为准。

ExecutionToolRuntimeScope

Execution Tool Runtime Scope 接口,共包含 6 个公开字段或方法。

  • 种类: 接口
  • 导入: import type { ExecutionToolRuntimeScope } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export interface ExecutionToolRuntimeScope {
    principalId: string;
    userId?: string;
    tenantId?: string;
    sessionId?: string;
    runId: string;
    workspaceId: string;
}

契约成员

成员种类签名说明
principalId属性principalId: string公开属性;类型、只读和可选状态以签名列为准。
runId属性runId: string公开属性;类型、只读和可选状态以签名列为准。
sessionId属性sessionId?: string公开属性;类型、只读和可选状态以签名列为准。
tenantId属性tenantId?: string公开属性;类型、只读和可选状态以签名列为准。
userId属性userId?: string公开属性;类型、只读和可选状态以签名列为准。
workspaceId属性workspaceId: string公开属性;类型、只读和可选状态以签名列为准。

ExecutionToolDispatchFactory

Execution Tool Dispatch Factory 公共类型别名;完整类型表达式见声明。

  • 种类: 类型
  • 导入: import type { ExecutionToolDispatchFactory } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export type ExecutionToolDispatchFactory<TInput = unknown> = (request: ExecutionToolDispatchFactoryRequest<TInput>) => Promise<ExecutionToolDispatchPlan> | ExecutionToolDispatchPlan;

ExecutionToolTerminalState

Execution Tool Terminal State 公共类型别名;完整类型表达式见声明。

  • 种类: 类型
  • 导入: import type { ExecutionToolTerminalState } from '@codesoul-co/hypha-tools';
  • 源码模块: execution-adapter

声明

text
export type ExecutionToolTerminalState = (typeof EXECUTION_TOOL_TERMINAL_STATES)[number];