Documentation Index
Fetch the complete documentation index at: https://docs.praison.ai/llms.txt
Use this file to discover all available pages before exploring further.
PlanStep
Defined in the planning module.
Rust AI Agent SDK
A single step in a plan.
Fields
| Name | Type | Description |
|---|
id | String | Step ID |
description | String | Step description |
status | StepStatus | Step status |
dependencies | Vec<String> | Dependencies (step IDs) |
output | Option<String> | Output from this step |
error | Option<String> | Error message if failed |
estimated_duration | Option<u64> | Estimated duration in seconds |
actual_duration | Option<u64> | Actual duration in seconds |
Methods
new
fn new(description: impl Into<String>) -> Self
Create a new plan step.
Parameters:
| Name | Type |
|---|
description | impl Into<String> |
depends_on
fn depends_on(mut self, step_id: impl Into<String>) -> Self
Add a dependency.
Parameters:
| Name | Type |
|---|
step_id | impl Into<String> |
estimated
fn estimated(mut self, seconds: u64) -> Self
Set estimated duration.
Parameters:
start
fn start(&mut self) -> ()
Mark as in progress.
complete
fn complete(&mut self, output: Option<String>) -> ()
Mark as completed.
Parameters:
| Name | Type |
|---|
output | Option<String> |
fail
fn fail(&mut self, error: impl Into<String>) -> ()
Mark as failed.
Parameters:
| Name | Type |
|---|
error | impl Into<String> |
skip
Mark as skipped.
is_ready
fn is_ready(&self, completed_steps: &[String]) -> bool
Check if step is ready to execute.
Parameters:
| Name | Type |
|---|
completed_steps | &[String] |
Source
View on GitHub
praisonai/src/planning/mod.rs at line 46