Immutable result container for GEPA optimization.
Contains the final optimization state and provides convenient accessors for analysis.
Summary
Functions
Get the best candidate program.
Get the index of the best candidate by aggregate score.
Get the best score achieved.
Generate Graphviz DOT for this result's candidate lineage.
Generate a self-contained HTML visualization for this result's candidate lineage.
Rebuild a result from to_dict/1 output.
Create result from final optimization state.
Convert a result to a plain map suitable for persistence or JSON conversion.
Types
@type t() :: %GEPA.Result{ best_candidate: GEPA.Types.candidate() | term() | nil, best_idx: non_neg_integer() | nil, best_outputs_valset: %{required(GEPA.Types.data_id()) => [{GEPA.Types.program_idx(), term()}]} | nil, candidates: [GEPA.Types.candidate()], discovery_eval_counts: [non_neg_integer()], i: integer(), num_full_ds_evals: non_neg_integer(), objective_pareto_front: %{required(String.t()) => float()} | nil, parents: [[GEPA.Types.program_idx() | nil]], per_objective_best_candidates: %{required(String.t()) => MapSet.t(GEPA.Types.program_idx())} | nil, per_val_instance_best_candidates: GEPA.Types.pareto_fronts(), total_num_evals: non_neg_integer(), val_aggregate_scores: [float()], val_aggregate_subscores: [%{required(String.t()) => float()}] | nil, val_subscores: [GEPA.Types.sparse_scores()] }
Functions
@spec best_candidate(t()) :: GEPA.Types.candidate()
Get the best candidate program.
@spec best_idx(t()) :: non_neg_integer()
Get the index of the best candidate by aggregate score.
Get the best score achieved.
Generate Graphviz DOT for this result's candidate lineage.
Generate a self-contained HTML visualization for this result's candidate lineage.
Rebuild a result from to_dict/1 output.
@spec from_state(GEPA.State.t()) :: t()
Create result from final optimization state.
Convert a result to a plain map suitable for persistence or JSON conversion.