pub struct OllamaProvider { /* private fields */ }Implementations§
Source§impl OllamaProvider
impl OllamaProvider
pub fn new(config: &Config) -> Result<Self>
Sourcepub fn from_account(
account: &AccountConfig,
_api_key: &str,
config: &Config,
) -> Result<Self>
pub fn from_account( account: &AccountConfig, _api_key: &str, config: &Config, ) -> Result<Self>
Create provider from account configuration
Trait Implementations§
Source§impl AIProvider for OllamaProvider
impl AIProvider for OllamaProvider
fn generate_commit_message<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
diff: &'life1 str,
context: Option<&'life2 str>,
full_gitmoji: bool,
config: &'life3 Config,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Source§fn generate_commit_messages<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
diff: &'life1 str,
context: Option<&'life2 str>,
full_gitmoji: bool,
config: &'life3 Config,
count: u8,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn generate_commit_messages<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
diff: &'life1 str,
context: Option<&'life2 str>,
full_gitmoji: bool,
config: &'life3 Config,
count: u8,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Generate multiple commit message variations
Source§fn generate_pr_description<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
commits: &'life1 [String],
diff: &'life2 str,
config: &'life3 Config,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn generate_pr_description<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
commits: &'life1 [String],
diff: &'life2 str,
config: &'life3 Config,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Generate a PR description from commits
Auto Trait Implementations§
impl Freeze for OllamaProvider
impl !RefUnwindSafe for OllamaProvider
impl Send for OllamaProvider
impl Sync for OllamaProvider
impl Unpin for OllamaProvider
impl !UnwindSafe for OllamaProvider
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreCreates a shared type from an unshared type.