Class GuardrailViolation
- Namespace
- IntentSharp.Guardrails
- Assembly
- IntentSharp.dll
A rule that failed in a check: an enforced rule's failure is a violation, a detect-only rule's a detection. Message is what may go back to the model; Detail is the full text, for results and logs.
public sealed class GuardrailViolation
- Inheritance
-
objectGuardrailViolation
- Inherited Members
-
object.Equals(object)object.Equals(object, object)object.GetHashCode()object.GetType()object.ReferenceEquals(object, object)object.ToString()
- Extension Methods
Constructors
- GuardrailViolation()
Creates a violation. The check creates these; a test or a custom kind's caller may create its own.
Properties
- Compiled
True when the rule was compiled from intent rather than written by a person.
- Detail
The full text of the failure, which may name values; for results and logs, not for the model.
- Kind
The rule's kind.
- Message
What may go back to the model: the rule's own message, else a text naming the rule and its subject. It never carries the rule's pattern or values or the subject's value.
- RuleId
The rule's id; empty for the denial of a required subject that no enforced
allowrule allows.
- Set
The name of the set holding the rule.
- Subject
The subject the rule checks.