pub struct Goal {
pub session: String,
pub text: String,
pub gate: Option<String>,
pub budget: u32,
pub turns: u32,
pub state: State,
pub note: Option<String>,
pub garbage: bool,
pub created_ms: i64,
pub updated_ms: i64,
}Expand description
One session’s goal, as the store keeps it.
Fields§
§session: String§text: StringWhat the work is for, in the person’s own words.
gate: Option<String>A shell command that must exit 0 before “done” is accepted. Optional.
budget: u32How many judged turns it may use.
turns: u32How many it has used.
state: State§note: Option<String>The one line the last judgement produced, or why the goal ended. Shown, not parsed.
garbage: boolSet when the last judgement was unreadable. A run of two ends the goal; any real answer clears it, and it is stored so a restart does not reset the count.
created_ms: i64§updated_ms: i64Implementations§
Source§impl Goal
impl Goal
Sourcepub fn new(
session: &str,
text: &str,
gate: Option<String>,
budget: Option<u32>,
now_ms: i64,
) -> Goal
pub fn new( session: &str, text: &str, gate: Option<String>, budget: Option<u32>, now_ms: i64, ) -> Goal
A fresh goal, active, with nothing used yet.
Sourcepub fn wants_turn(&self) -> bool
pub fn wants_turn(&self) -> bool
Whether another turn is owed: active, and under the budget.
Sourcepub fn continuation_prompt(&self) -> String
pub fn continuation_prompt(&self) -> String
The prompt the next turn is given. It is deliberately short: the work so far is in the transcript the run is continuing, and a second copy of it here would be a summary the model treats as authoritative.
Trait Implementations§
impl Eq for Goal
impl StructuralPartialEq for Goal
Auto Trait Implementations§
impl Forget for Goal
impl Freeze for Goal
impl Move for Goal
impl RefUnwindSafe for Goal
impl Send for Goalwhere
RawVecInner: Send,
impl Sync for Goalwhere
RawVecInner: Sync,
impl Unpin for Goal
impl UnsafeUnpin for Goal
impl UnwindSafe for Goalwhere
RawVecInner: UnwindSafe,
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.