Skip to content
中文

CompiledReplyFormat ​

KIT · interface · Type contract

A resolved format with its checks bound; callers only inspect replies using it.

Import ​

ts
import type { CompiledReplyFormat } from '@jangts/agent-core/kits/presentation';
js
/** @typedef {import('@jangts/agent-core/kits/presentation').CompiledReplyFormat} CompiledReplyFormat */

Other public entry points:@jangts/agent-core/types, @jangts/agent-core/kits/presentation, @jangts/agent-core/kits.

Definition ​

ts
interface CompiledReplyFormat

Field structure ​

FieldTypeRequiredDescription
idstringRequiredRead-only. See the type definition and usage context.
descriptionstringRequiredRead-only. See the type definition and usage context.
checksreadonly string[]RequiredRead-only. See the type definition and usage context.
inspect(bubbles: readonly string[]) => readonly ReplyFormatCheck[]RequiredRead-only. Checks the reply fails; empty means the template format is satisfied.

Member index ​

MemberPurpose
inspectChecks the reply fails; empty means the template format is satisfied.

Member details ​

inspect ​

Checks the reply fails; empty means the template format is satisfied.

ts
CompiledReplyFormat.inspect(bubbles: readonly string[]): readonly ReplyFormatCheck[]
ParameterTypePassingDescription
bubblesreadonly string[]Required—

Returns: readonly ReplyFormatCheck[].

Using the type ​

Read the contract at the call site ​

ts
import type { CompiledReplyFormat } from '@jangts/agent-core/kits/presentation';

// Keep the original contract at the call site; TS and JS share the same runtime behavior.
function inspect(value: CompiledReplyFormat) {
  return value.id;
}
js
/** @param {import('@jangts/agent-core/kits/presentation').CompiledReplyFormat} value */
function inspect(value) {
  return value.id;
}

API reference, usage examples and developer guides.