> ## Documentation Index
> Fetch the complete documentation index at: https://praison.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Expression Condition • Rust AI Agent SDK

> ExpressionCondition: Simple expression-based condition. Evaluates simple expressions like 'score  80' or 'status == 'approved''.

# ExpressionCondition

> Defined in the [**conditions**](../modules/conditions) module.

<Badge color="orange">Rust AI Agent SDK</Badge>

Simple expression-based condition. Evaluates simple expressions like "score > 80" or "status == 'approved'".

## Fields

| Name         | Type     | Description                |
| ------------ | -------- | -------------------------- |
| `expression` | `String` | The expression to evaluate |

## Methods

### `new`

```rust theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
fn new(expression: impl Into<String>) -> Self
```

Create a new expression condition.

**Parameters:**

| Name         | Type                      |
| ------------ | ------------------------- |
| `expression` | `impl Into&lt;String&gt;` |

## Source

<Card title="View on GitHub" icon="github" href="https://github.com/MervinPraison/PraisonAI/blob/main/src/praisonai-rust/praisonai/src/conditions/mod.rs#L66">
  `praisonai/src/conditions/mod.rs` at line 66
</Card>

***

## Related Documentation

<CardGroup cols={2}>
  <Card title="Rust Conditions" icon="code-branch" href="/docs/rust/conditions" />

  <Card title="Rust Routing" icon="route" href="/docs/rust/routing" />
</CardGroup>
