optimize() API GEPA optimizer, Pareto, artifact, and evaluation APIs. cpp api api/optimize packages/cpp/axir-api.json api optimize() API

optimize() API

GEPA, Pareto, artifact, and optimizer APIs.

Most Used

axllm::optimize

Convenience optimizer helper that composes AxBootstrapFewShot before AxGEPA and returns an artifact without applying final component changes.

FieldValue
Kindfunction
Ax conceptoptimize
API sectionOptimizers
Formaxllm::optimize(program, student, examples, options, teacher)
Returnsoptimized artifact

Important Options

  • student/client
  • teacher/reflection client
  • metric budget
  • bootstrap

Examples

C++
auto artifact = axllm::optimize(qa, client, train, axllm::object({}), &reflection);

Full reference

axllm::AxBootstrapFewShot

Few-shot demonstration optimizer that selects successful evaluator rollouts before prompt/component evolution.

FieldValue
Kindtype
Ax conceptAxBootstrapFewShot
API sectionOptimizers
Formaxllm::AxBootstrapFewShot(options)
Returnsoptimizer engine

Important Options

  • quality threshold
  • max demos
  • max rounds
  • batch size

Examples

C++
axllm::AxBootstrapFewShot bootstrap(axllm::object({{"qualityThreshold", 0.7}}));

Full reference

axllm::AxGEPA

Generated GEPA optimizer engine with Core-owned reflection, Pareto, bootstrap, and selector-state behavior.

FieldValue
Kindtype
Ax conceptAxGEPA
API sectionOptimizers
Formaxllm::AxGEPA(reflection, options)
Returnsoptimizer engine

Important Options

  • reflection client
  • budget
  • metric
  • candidate count

Examples

C++
axllm::AxGEPA engine(reflection_client);

Full reference

axllm::OptimizerEngine

Optimizer boundary consumed by AxGen, AxAgent, and AxFlow optimization helpers.

FieldValue
Kindinterface
Ax conceptOptimizerEngine
API sectionOptimizers
Formaxllm::OptimizerEngine::optimize(request, evaluator)
Returnsoptimized artifact

Important Options

  • request
  • evaluator

Full reference

axllm::OptimizerEvaluator

Evaluator callback boundary used by generated optimizers.

FieldValue
Kindinterface
Ax conceptOptimizerEvaluator
API sectionOptimizers
Formaxllm::OptimizerEvaluator::evaluate(request)
Returnsscore/evidence result

Important Options

  • dataset rows
  • candidate map
  • evidence

Full reference

Full Reference

Open the full C++ reference. This page highlights the optimize symbols most relevant to everyday use.

Docs