Skip to main content

Crate atomr_agents_context

Crate atomr_agents_context 

Source
Expand description

Context assembler.

Strategies produce ContextFragments with priorities and token estimates. The assembler orders by priority and packs greedily into the remaining TokenBudget — high-priority fragments survive; low-priority ones are dropped first under pressure.

Structs§

AssembledPrompt
Result of assembling trusted + untrusted content.
ContextAssembler
ContextFragment
One fragment contributed by a strategy.
KeywordInjectionScreen
A cheap keyword heuristic screen (case-insensitive). Not a complete defense — a first line that flags the most common override phrasings.
RenderedContext
Output of ContextAssembler::assemble.
TrustPolicy
How untrusted content is fenced when assembling a prompt.
TrustedContent
A span of content carrying its trust tag and origin.

Enums§

Trust
Whether a span of content is authoritative (instructions/system) or untrusted (retrieved/tool/ingested).

Traits§

InjectionScreen
Flags suspicious untrusted spans before they reach the model.