pub struct PromptContribution {
pub slot: PromptSlot,
pub title: Option<Arc<str>>,
pub priority: i32,
pub gate: PromptContributionGate,
pub content: Arc<str>,
}Fields§
§slot: PromptSlot§title: Option<Arc<str>>§priority: i32§gate: PromptContributionGate§content: Arc<str>Implementations§
Source§impl PromptContribution
impl PromptContribution
pub fn new( slot: PromptSlot, title: impl Into<Arc<str>>, content: impl Into<Arc<str>>, ) -> PromptContribution
pub fn with_priority(self, priority: i32) -> PromptContribution
pub fn requires_tool( self, tool_name: impl Into<String>, minimum_availability: ToolAvailability, ) -> PromptContribution
pub fn requires_any_tool( self, tool_names: impl IntoIterator<Item = impl Into<String>>, minimum_availability: ToolAvailability, ) -> PromptContribution
pub fn intro( title: impl Into<Arc<str>>, content: impl Into<Arc<str>>, ) -> PromptContribution
pub fn execution( title: impl Into<Arc<str>>, content: impl Into<Arc<str>>, ) -> PromptContribution
pub fn guidance( title: impl Into<Arc<str>>, content: impl Into<Arc<str>>, ) -> PromptContribution
pub fn project_instructions(content: impl Into<Arc<str>>) -> PromptContribution
pub fn runtime_context(content: impl Into<Arc<str>>) -> PromptContribution
pub fn environment( title: impl Into<Arc<str>>, content: impl Into<Arc<str>>, ) -> PromptContribution
Trait Implementations§
Source§impl Clone for PromptContribution
impl Clone for PromptContribution
Source§fn clone(&self) -> PromptContribution
fn clone(&self) -> PromptContribution
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 PromptContribution
impl Debug for PromptContribution
Source§impl<'de> Deserialize<'de> for PromptContribution
impl<'de> Deserialize<'de> for PromptContribution
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<PromptContribution, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<PromptContribution, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for PromptContribution
Source§impl PartialEq for PromptContribution
impl PartialEq for PromptContribution
Source§fn eq(&self, other: &PromptContribution) -> bool
fn eq(&self, other: &PromptContribution) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for PromptContribution
impl Serialize for PromptContribution
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 PromptContribution
Auto Trait Implementations§
impl Freeze for PromptContribution
impl RefUnwindSafe for PromptContribution
impl Send for PromptContribution
impl Sync for PromptContribution
impl Unpin for PromptContribution
impl UnsafeUnpin for PromptContribution
impl UnwindSafe for PromptContribution
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