QDpy
Loading...
Searching...
No Matches
qdpy.algorithms.qdaif.QDAIF Class Reference

Evolve text under a fixed qualitative rubric. More...

Public Member Functions

 stats (self)
 best (self)
 run (self, propose, judge, *, proposal_budget, judgment_budget, initial=())
 Spend additional proposal and judgment call budgets.

Detailed Description

Evolve text under a fixed qualitative rubric.

QDAIF with caller-supplied generation and grading.

Use a one-elite Grid or CVTGrid with one maximized objective. Each
archived individual contains one string. Propose receives a tuple
of parent texts and this search's NumPy generator. Judge returns a
scalar quality and a descriptor vector. Exact text matches reuse
the first successful judgment. Keep the rubric fixed across calls.

Set parent_count to zero for independent sampling. Otherwise
parents are sampled uniformly from occupied cells without
replacement, up to the requested number.

Definition at line 31 of file qdaif.py.

Member Function Documentation

◆ best()

qdpy.algorithms.qdaif.QDAIF.best ( self)
Return the best archived text, or None for an empty archive.

Definition at line 74 of file qdaif.py.

◆ run()

qdpy.algorithms.qdaif.QDAIF.run ( self,
propose,
judge,
* ,
proposal_budget,
judgment_budget,
initial = () )

Spend additional proposal and judgment call budgets.

Evaluate seed texts first, then propose and judge new texts.

Seeds spend judgment calls only. Duplicate proposals still
spend proposal calls. Stop when either call budget is exhausted.
Malformed feedback or a callback error propagates to the caller.

Definition at line 98 of file qdaif.py.

◆ stats()

qdpy.algorithms.qdaif.QDAIF.stats ( self)
Return immutable accounting through the latest callback.

Definition at line 69 of file qdaif.py.


The documentation for this class was generated from the following file: