> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.nvidia.com/nemo/relay/llms.txt.
> For full documentation content, see https://docs.nvidia.com/nemo/relay/llms-full.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.nvidia.com/nemo/relay/_mcp/server.

# Module prompt_ir

> Prompt Intermediate Representation (IR) types for the Adaptive Cache Governor (ACG) system.

Generated from `cargo doc --no-deps -p nemo-relay -p nemo-relay-adaptive -p nemo-relay-ffi`.

Prompt Intermediate Representation (IR) types for the Adaptive Cache Governor (ACG) system.

The Prompt IR decomposes LLM conversations into addressable blocks with structural metadata for cache analysis and prompt rewriting. This is deliberately different from the message-oriented `AnnotatedLlmRequest` in core - the IR flattens the hierarchy into a sequence of blocks, each carrying provenance, sensitivity, and stability metadata.

## Structs

* [PromptBlock](/reference/api/rust-library-reference/nemo-relay-adaptive/acg/prompt_ir/struct-promptblock): A single addressable block within the Prompt IR.
* [PromptIR](/reference/api/rust-library-reference/nemo-relay-adaptive/acg/prompt_ir/struct-promptir): Prompt Intermediate Representation - the full decomposed prompt.
* [SpanId](/reference/api/rust-library-reference/nemo-relay-adaptive/acg/prompt_ir/struct-spanid): Stable span identifier for addressable prompt blocks.
* [TokenizationMetadata](/reference/api/rust-library-reference/nemo-relay-adaptive/acg/prompt_ir/struct-tokenizationmetadata): Token count metadata for a prompt block.
* [ToolSchemaHash](/reference/api/rust-library-reference/nemo-relay-adaptive/acg/prompt_ir/struct-toolschemahash): Hash fingerprint of a tool schema definition.

## Enums

* [BlockContentType](/reference/api/rust-library-reference/nemo-relay-adaptive/acg/prompt_ir/enum-blockcontenttype): Content type discriminant for a prompt block.
* [PromptRole](/reference/api/rust-library-reference/nemo-relay-adaptive/acg/prompt_ir/enum-promptrole): Role of a prompt block within the conversation.
* [ProvenanceLabel](/reference/api/rust-library-reference/nemo-relay-adaptive/acg/prompt_ir/enum-provenancelabel): Origin label for a prompt block.
* [SensitivityLabel](/reference/api/rust-library-reference/nemo-relay-adaptive/acg/prompt_ir/enum-sensitivitylabel): Sensitivity classification for a prompt block.