# `Jidoka.Effect.OperationResult`
[🔗](https://github.com/agentjido/jidoka/blob/v0.9.0/lib/jidoka/effect/operation_result.ex#L1)

Durable operation observation stored on agent state.

This is separate from `Jidoka.Effect.Result`: the effect result records
interpreter status, while operation result records the semantic tool
observation that should survive across later turns.

# `t`

```elixir
@type t() :: %Jidoka.Effect.OperationResult{
  arguments: map(),
  content: nil | nil | binary(),
  effect_id: nil | nil | binary(),
  loop_index: integer(),
  metadata: map(),
  operation: binary(),
  output: any(),
  request_id: nil | nil | binary()
}
```

# `from_effect`

```elixir
@spec from_effect(Jidoka.Effect.Intent.t(), term()) :: {:ok, t()} | {:error, term()}
```

Builds an operation result from an operation intent and its output.

# `from_input`

```elixir
@spec from_input(t() | keyword() | map()) :: {:ok, t()} | {:error, term()}
```

Normalizes an existing operation result, keyword list, or map.

# `new`

```elixir
@spec new(keyword() | map()) :: {:ok, t()} | {:error, term()}
```

Builds an operation result from keyword or map attributes.

# `new!`

```elixir
@spec new!(keyword() | map()) :: t()
```

Builds an operation result and raises if the attributes are invalid.

# `schema`

```elixir
@spec schema() :: Zoi.schema()
```

Returns the Zoi schema for an operation result.

# `to_message`

```elixir
@spec to_message(t()) :: Jidoka.Agent.Message.t()
```

Converts an operation result to a tool message for the model.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
