AgentPrismContentGuardOptions
AgentPrism.Core.dllSettings for the content inspection pipeline.
public sealed class AgentPrismContentGuardOptionsInheritance
Section titled “Inheritance”object ← AgentPrismContentGuardOptions
Inherited Members
Section titled “Inherited Members”object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Remarks
Section titled “Remarks”Read from the AgentPrism:ContentGuard configuration section.
None of the settings in this class have any effect while no guard
is registered: the inspection wrapper is not added to the pipeline and
this object is never read. The the no-surprises rule (no surprises) gate is not a flag, it
is the registration itself — the built-in guard is added by an
explicit choice, either via AddPatternContentGuard or by populating
the AgentPrism:ContentGuard:Pattern section.
Constructors
Section titled “Constructors”AgentPrismContentGuardOptions()
Section titled “ AgentPrismContentGuardOptions()”public AgentPrismContentGuardOptions()Fields
Section titled “Fields”SectionName
Section titled “ SectionName”The configuration section name.
public const string SectionName = "AgentPrism:ContentGuard"Field Value
Section titled “Field Value”Properties
Section titled “Properties”BufferStreamingOutput
Section titled “ BufferStreamingOutput”While output inspection is on, the streaming response is buffered. Default true.
public bool BufferStreamingOutput { get; set; }Property Value
Section titled “Property Value”Remarks
Section titled “Remarks”A frame cannot be recalled once it has been sent to the client. A pattern
does not match on a partial piece of text: 4539- is seen and passes
through before the card number is complete. Buffering costs the
liveliness of the stream but inspects correctly.
Setting this to false leaves output inspection half done: the guard only ever sees each frame on its own. Silently doing half an inspection is worse than doing none — the user believes they are protected. That is why the choice is an explicit setting, not a hidden behavior.
InspectInput
Section titled “ InspectInput”Inspects content sent to the model. Default true.
public bool InspectInput { get; set; }Property Value
Section titled “Property Value”Remarks
Section titled “Remarks”Tool results are covered too: a tool result enters the model on the
second call and is seen because inspection sits at the
IChatClient layer.
InspectOutput
Section titled “ InspectOutput”Inspects content coming from the model. Default true.
public bool InspectOutput { get; set; }