pub struct ProposedFact {
pub key: ContextKey,
pub id: String,
pub content: String,
pub confidence: f64,
pub provenance: String,
}Expand description
An unvalidated suggestion from a non-authoritative source.
Proposed facts live in ContextKey::Proposals until a ValidationAgent
promotes them to Fact. The proposal tracks its origin for audit trail.
Fields§
§key: ContextKeyThe context key this proposal targets.
id: StringUnique identifier encoding origin and target.
content: StringThe proposed content.
confidence: f64Confidence hint from the source (0.0 - 1.0).
provenance: StringProvenance information (e.g., model ID, prompt hash).
Implementations§
Source§impl ProposedFact
impl ProposedFact
Sourcepub fn new(
key: ContextKey,
id: impl Into<String>,
content: impl Into<String>,
provenance: impl Into<String>,
) -> ProposedFact
pub fn new( key: ContextKey, id: impl Into<String>, content: impl Into<String>, provenance: impl Into<String>, ) -> ProposedFact
Create a new draft proposal with explicit provenance.
Sourcepub fn with_confidence(self, confidence: f64) -> ProposedFact
pub fn with_confidence(self, confidence: f64) -> ProposedFact
Override the proposal confidence.
Trait Implementations§
Source§impl Clone for ProposedFact
impl Clone for ProposedFact
Source§fn clone(&self) -> ProposedFact
fn clone(&self) -> ProposedFact
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ProposedFact
impl Debug for ProposedFact
Source§impl<'de> Deserialize<'de> for ProposedFact
impl<'de> Deserialize<'de> for ProposedFact
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ProposedFact, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ProposedFact, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ProposedFact
impl PartialEq for ProposedFact
Source§impl Serialize for ProposedFact
impl Serialize for ProposedFact
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for ProposedFact
Auto Trait Implementations§
impl Freeze for ProposedFact
impl RefUnwindSafe for ProposedFact
impl Send for ProposedFact
impl Sync for ProposedFact
impl Unpin for ProposedFact
impl UnsafeUnpin for ProposedFact
impl UnwindSafe for ProposedFact
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more