Skip to content

BaseConfig

evotoolkit.core.BaseConfig

Base configuration class for evolutionary methods.

Note: task is accessed via interface.task to avoid data redundancy.

Source code in src/evotoolkit/core/base_config.py
class BaseConfig:
    """
    Base configuration class for evolutionary methods.

    Note: task is accessed via interface.task to avoid data redundancy.
    """

    def __init__(self, interface: "BaseMethodInterface", output_path: str, verbose: bool = True):
        self.interface = interface
        self.output_path = output_path
        self.verbose = verbose

    @property
    def task(self) -> "BaseTask":
        """Access task through interface to avoid redundancy."""
        return self.interface.task

task property

task: BaseTask

Access task through interface to avoid redundancy.


Common parameters include:

  • interface (BaseMethodInterface): Task interface
  • output_path (str): Where to save results
  • running_llm (HttpsApi): LLM API instance
  • max_generations (int): Maximum generations
  • pop_size (int): Population size