Skip to content

Function: profileBlock()

ts
function profileBlock(block): BlockTokenProfile;

Defined in: packages/core/src/introspection/TokenEconomics.ts:181

Estimate tokens for a content block structure (MCP response block).

Parameters

ParameterTypeDescription
block{ text?: string; type: string; }The content block with type and text fields
block.text?string-
block.typestring-

Returns

BlockTokenProfile

Block-level token profile