---
url: >-
  https://adk.nht.io/api/@nhtio/adk/batteries/llm/openai_responses/interfaces/ChatHelpersCommon.md
description: >-
  The wire-shape-agnostic subset of a Chat-family battery's translation helpers
  — every helper that produces a plain `string` (or JSON Schema /
  tool-definition wire, which is identical across the family) rather than a
  battery-specific message object.
---

# Interface: ChatHelpersCommon

Defined in: [src/batteries/llm/chat\_common/types.ts:476](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L476)

The wire-shape-agnostic subset of a Chat-family battery's translation helpers — every helper
that produces a plain `string` (or JSON Schema / tool-definition wire, which is identical across
the family) rather than a battery-specific message object.

## Remarks

Both `ChatCompletionsHelpers` (OpenAI battery) and `OllamaHelpers` (Ollama battery) extend this
contract and add their own wire-specific members (timeline-message rendering, tool-call-result
rendering, history assembly, and — for OpenAI — streaming tool-call delta accumulation). Helpers
that compose other helpers receive their dependents via explicit `deps` arguments typed against
THIS contract (never against a battery-specific bag), so the shared implementations carry no
import edge back to any individual battery.

## Extended by

* [`OpenAIResponsesHelpers`](../types/interfaces/OpenAIResponsesHelpers.md)
* [`ChatCompletionsHelpers`](../../openai_chat_completions/types/interfaces/ChatCompletionsHelpers.md)
* [`OllamaHelpers`](../../ollama/types/interfaces/OllamaHelpers.md)
* [`ClaudeCodeCliHelpers`](../../claude_code_cli/types/interfaces/ClaudeCodeCliHelpers.md)
* [`AnthropicMessagesHelpers`](../../anthropic_messages/types/interfaces/AnthropicMessagesHelpers.md)

## Properties

| Property                                                                                              | Type                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | Defined in                                                                                                                                    |
| ----------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------- |
|  `descriptionToChatCompletionsJsonSchema` | (`d`: [`DescriptionLike`](../../../interfaces/DescriptionLike.md)) => [`JsonSchema`](../../../interfaces/JsonSchema.md)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             | Converts a validator `describe()` envelope into the Chat-Completions JSON-Schema subset.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               | [src/batteries/llm/chat\_common/types.ts:478](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L478) |
|  `filterThoughts`                                                 | (`thoughts`: `Iterable`<[`Thought`](../../../../common/classes/Thought.md)>, `mode`: `"all-self"` | `"latest-self"` | `"all"`, `selfIdentity`: `string`, `replayCompatibility`: readonly `string`\[]) => [`Thought`](../../../../common/classes/Thought.md)\[]                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    | Selects which thoughts to surface, by surfacing mode, self identity, and replay compatibility.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         | [src/batteries/llm/chat\_common/types.ts:566](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L566) |
|  `renderArtifactHandleBody?`                            | (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         | Renders the directions-bearing "handle" body for a non-inlined [@nhtio/adk!SpooledArtifact](../../../../spooled_artifact/classes/SpooledArtifact.md) tool result: metadata (callId/kind/byteLength/lineCount) plus the forged `artifact_*` tools the model should call to read it incrementally. **Remarks** Optional override seam. When omitted the battery uses the shared [defaultRenderArtifactHandleBody](../../transformers_js/helpers/variables/defaultRenderArtifactHandleBody.md). A consumer overrides it to change WHICH reader the model is steered toward first — e.g. promoting the JSON content-readers (`artifact_json_get` / `artifact_json_keys`) ahead of the metadata-only `artifact_json_type` for a small model that grabs the first listed tool. The tool list itself comes from the artifact's `constructor.toolMethods`; an override typically reorders or re-annotates that list before delegating to the default renderer. | [src/batteries/llm/chat\_common/types.ts:538](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L538) |
|  `renderChatCompletionsSystemPrompt`           | (`input`: { `bucketOrder`: [`ChatCompletionsBucketOrder`](../../../type-aliases/ChatCompletionsBucketOrder.md); `memories`: `Iterable`<[`Memory`](../../../../common/classes/Memory.md)>; `renderCtx?`: `unknown`; `renderFirstPartyRetrievables`: (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`) => `Promise`<`string`>; `renderMemories`: (`items`: `Iterable`<{ `attrs`: [`MemoryAttrs`](../../../interfaces/MemoryAttrs.md); `memory`: [`Memory`](../../../../common/classes/Memory.md); }>) => `string`; `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`; `renderRetrievables`: (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `deps`: { `renderFirstPartyRetrievables`: (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`) => `Promise`<`string`>; `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`; `renderRetrievableSafetyDirective`: () => `string`; `renderThirdPartyPrivateRetrievables`: (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `deps`: { `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`; `renderUntrustedContent`: (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`; }) => `Promise`<`string`>; `renderThirdPartyPublicRetrievables`: (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `deps`: { `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`; `renderUntrustedContent`: (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`; }) => `Promise`<`string`>; `renderUntrustedContent`: (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`; }) => `Promise`<`string`>; `renderRetrievableSafetyDirective`: () => `string`; `renderStandingInstructions`: (`items`: `Iterable`<[`Tokenizable`](../../../../common/classes/Tokenizable.md)>, `attrs?`: [`StandingInstructionAttrs`](../../../interfaces/StandingInstructionAttrs.md)) => `string`; `renderThirdPartyPrivateRetrievables`: (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `deps`: { `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`; `renderUntrustedContent`: (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`; }) => `Promise`<`string`>; `renderThirdPartyPublicRetrievables`: (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `deps`: { `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`; `renderUntrustedContent`: (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`; }) => `Promise`<`string`>; `renderUntrustedContent`: (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`; `retrievables`: `Iterable`<[`Retrievable`](../../../../common/classes/Retrievable.md)>; `standingInstructions`: `Iterable`<[`Tokenizable`](../../../../common/classes/Tokenizable.md)>; `systemPrompt`: [`Tokenizable`](../../../../common/classes/Tokenizable.md); }) => `Promise`<`string`> | Assembles the system-prompt message from its constituent buckets in [ChatCompletionsBucketOrder](../../../type-aliases/ChatCompletionsBucketOrder.md).                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 | [src/batteries/llm/chat\_common/types.ts:578](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L578) |
|  `renderFirstPartyRetrievables`                     | (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`) => `Promise`<`string`>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             | Renders first-party (trusted) retrievables into a single prompt block.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 | [src/batteries/llm/chat\_common/types.ts:493](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L493) |
|  `renderMemories`                                                 | (`items`: `Iterable`<{ `attrs`: [`MemoryAttrs`](../../../interfaces/MemoryAttrs.md); `memory`: [`Memory`](../../../../common/classes/Memory.md); }>) => `string`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                | Renders memories (each with its attribute bag) into a single prompt block.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             | [src/batteries/llm/chat\_common/types.ts:489](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L489) |
|  `renderRetrievableHandleBody?`                      | (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         | Renders the directions-bearing "handle" body for a non-inlined [@nhtio/adk!Retrievable](../../../../common/classes/Retrievable.md) whose content is a [@nhtio/adk!SpooledArtifact](../../../../spooled_artifact/classes/SpooledArtifact.md): metadata (callId/kind/byteLength/lineCount) plus the forged `artifact_*` tools the model should call to read it incrementally. **Remarks** Optional override seam, the retrievable-side counterpart to [renderArtifactHandleBody](#property-renderartifacthandlebody). When omitted the battery uses the shared [defaultRenderRetrievableHandleBody](../../webllm_chat_completions/helpers/variables/defaultRenderRetrievableHandleBody.md).                                                                                                                                                                                                                                                              | [src/batteries/llm/chat\_common/types.ts:555](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L555) |
|  `renderRetrievables`                                         | (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `deps`: { `renderFirstPartyRetrievables`: (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`) => `Promise`<`string`>; `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`; `renderRetrievableSafetyDirective`: () => `string`; `renderThirdPartyPrivateRetrievables`: (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `deps`: { `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`; `renderUntrustedContent`: (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`; }) => `Promise`<`string`>; `renderThirdPartyPublicRetrievables`: (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `deps`: { `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`; `renderUntrustedContent`: (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`; }) => `Promise`<`string`>; `renderUntrustedContent`: (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`; }) => `Promise`<`string`>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       | Assembles the full retrievables block: safety directive plus the trust-tiered sub-renderers.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           | [src/batteries/llm/chat\_common/types.ts:514](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L514) |
|  `renderRetrievableSafetyDirective`             | () => `string`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      | Renders the safety directive that precedes any retrievable content.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    | [src/batteries/llm/chat\_common/types.ts:491](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L491) |
|  `renderStandingInstructions`                         | (`items`: `Iterable`<[`Tokenizable`](../../../../common/classes/Tokenizable.md)>, `attrs?`: [`StandingInstructionAttrs`](../../../interfaces/StandingInstructionAttrs.md)) => `string`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | Renders standing instructions into a single prompt block.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              | [src/batteries/llm/chat\_common/types.ts:484](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L484) |
|  `renderThirdPartyPrivateRetrievables`       | (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `deps`: { `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`; `renderUntrustedContent`: (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`; }) => `Promise`<`string`>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               | Renders third-party private retrievables, wrapping each in the untrusted-content envelope.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             | [src/batteries/llm/chat\_common/types.ts:506](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L506) |
|  `renderThirdPartyPublicRetrievables`         | (`items`: `Iterable`<{ `attrs`: [`RetrievableAttrs`](../../../interfaces/RetrievableAttrs.md); `retrievable`: [`Retrievable`](../../../../common/classes/Retrievable.md); }>, `deps`: { `renderRetrievableHandleBody?`: (`input`: { `artifact`: `unknown`; `byteLength`: `number`; `callId`: `string`; `encoding?`: `string`; `estimatedTokens?`: `number`; `lineCount`: `number`; }) => `string`; `renderUntrustedContent`: (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`; }) => `Promise`<`string`>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               | Renders third-party public retrievables, wrapping each in the untrusted-content envelope.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              | [src/batteries/llm/chat\_common/types.ts:498](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L498) |
|  `renderThought`                                                   | (`content`: `string`, `attrs`: [`ThoughtAttrs`](../../../interfaces/ThoughtAttrs.md), `payload?`: `unknown`) => `string`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | Renders a single thought into its prompt block, optionally carrying an opaque replay payload.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          | [src/batteries/llm/chat\_common/types.ts:564](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L564) |
|  `renderTrustedContent`                                     | (`content`: `string`, `attrs`: [`TrustedContentAttrs`](../../../interfaces/TrustedContentAttrs.md)) => `string`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     | Wraps trusted (first-party) text in the trusted-content trust envelope.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                | [src/batteries/llm/chat\_common/types.ts:482](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L482) |
|  `renderUntrustedContent`                                 | (`content`: `string`, `attrs`: [`UntrustedContentAttrs`](../../../interfaces/UntrustedContentAttrs.md)) => `string`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 | Wraps untrusted (third-party) text in the untrusted-content trust envelope.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | [src/batteries/llm/chat\_common/types.ts:480](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L480) |
|  `toolsToChatCompletionsTools`                       | (`tools`: readonly ( | [`Tool`](../../../../forge/classes/Tool.md)<[`SpooledArtifact`](../../../../spooled_artifact/classes/SpooledArtifact.md)> | [`ArtifactTool`](../../../../forge/classes/ArtifactTool.md))\[], `deps`: { `descriptionToChatCompletionsJsonSchema`: (`d`: [`DescriptionLike`](../../../interfaces/DescriptionLike.md)) => [`JsonSchema`](../../../interfaces/JsonSchema.md); }) => [`ChatCompletionsTool`](../../../interfaces/ChatCompletionsTool.md)\[]                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   | Translates the tool registry into the function-tool wire array advertised to the model.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                | [src/batteries/llm/chat\_common/types.ts:573](https://github.com/NHTIO/ADK/blob/v1.20260901.0/src/src/batteries/llm/chat_common/types.ts#L573) |
