pub struct WorkerDecisionSequenceLearn { /* private fields */ }Expand description
Implementations§
Source§impl WorkerDecisionSequenceLearn
impl WorkerDecisionSequenceLearn
pub fn new() -> Self
Sourcepub fn with_system_prompt(self, prompt: impl Into<String>) -> Self
pub fn with_system_prompt(self, prompt: impl Into<String>) -> Self
システムプロンプトを設定
Sourcepub fn with_min_actions(self, min: usize) -> Self
pub fn with_min_actions(self, min: usize) -> Self
最小アクション数を設定
Sourcepub fn with_available_actions(self, actions: Vec<String>) -> Self
pub fn with_available_actions(self, actions: Vec<String>) -> Self
利用可能なアクション一覧を設定
Sourcepub fn with_system_event(self, event: impl Into<String>) -> Self
pub fn with_system_event(self, event: impl Into<String>) -> Self
システムイベント(フィルタ対象)を追加
Trait Implementations§
Source§impl LearnModel for WorkerDecisionSequenceLearn
impl LearnModel for WorkerDecisionSequenceLearn
Source§fn evaluate(&self, context: &EpisodeContext) -> Outcome
fn evaluate(&self, context: &EpisodeContext) -> Outcome
Records から Success/Failure を判定 Read more
Source§fn build_episodes(&self, records: &[Record]) -> Vec<Episode>
fn build_episodes(&self, records: &[Record]) -> Vec<Episode>
Record のストリームから Episode を構築 Read more
Source§fn convert(&self, episode: &Episode) -> Result<TrainingData, LearnError>
fn convert(&self, episode: &Episode) -> Result<TrainingData, LearnError>
Episode を TrainingData に変換
Source§fn convert_batch(&self, episodes: &[Episode]) -> Vec<TrainingData>
fn convert_batch(&self, episodes: &[Episode]) -> Vec<TrainingData>
複数 Episode を一括変換(デフォルト実装)
Source§fn build_episodes_from_actions(&self, actions: &[ActionEvent]) -> Vec<Episode>
fn build_episodes_from_actions(&self, actions: &[ActionEvent]) -> Vec<Episode>
便利メソッド: ActionEvent[] から直接変換
Auto Trait Implementations§
impl Freeze for WorkerDecisionSequenceLearn
impl RefUnwindSafe for WorkerDecisionSequenceLearn
impl Send for WorkerDecisionSequenceLearn
impl Sync for WorkerDecisionSequenceLearn
impl Unpin for WorkerDecisionSequenceLearn
impl UnwindSafe for WorkerDecisionSequenceLearn
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 more