nvalchemi.gen.ConditionFunction#
- class nvalchemi.gen.ConditionFunction(*args, **kwargs)[source]#
Translate a call’s raw request into the generating function’s working input.
Receives the raw inputs, the resolved
num_samples, and the resolvedrng; returns the conditioned value the generating function is then called with. The return type is the procedure’s own – conditioning may change the type (e.g. a SMILES string becomes aBatch). There is no default: procedures implement their own per use case.The job is preparation, not enforcement: conditioning decides what the procedure is asked to do, not what it must emit. Constraints on the output (e.g. “structures with a carboxyl group”) live elsewhere – guidance inside the generating function, rejection via hooks at
AFTER_GENERATEor a wrapper generating function, or an explicit stage in aGenerationPipeline.