Changelog¶
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
[0.14.1] - 2025-10-01¶
Added¶
to_jsonandfrom_jsonmethods now also natively support (de)serialization to/from files and file-like objects
Changed¶
Instead of requiring already read string representations of json files,
.from_jsonnow also supports file paths as argument and will read the file itselffrom_jsonnow strictly expects the source as a positional argumentto_jsonnow acceptskwargsand passes them tojson.dumps
Fixed¶
Crash in
simulate_experimentwhen calculating cumulative best values forbatch_size>1Campaign.allow_*flags now properly take into account recommendation cachingThe campaign recommendation cache is now properly invalidated during context changes
[0.14.0] - 2025-09-10¶
Added¶
transformationssubpackageNew
NumericalTargetinterface, including advanced machinery for defining and manipulating target transformations based on the newTransformationclass hierarchymatch_bellandmatch_triangularconvenience constructors toNumericalTargetfor reproducing the legacyMATCHmodesnormalized_rampconvenience constructor toNumericalTargetfor reproducing the legacy behavior when imposing bounds onMIN/MAXtargetsnormalized_sigmoid,match_absolute,match_quadraticandmatch_powerconvenience constructors toNumericalTargetenabling additional matching/normalizing behaviorsFull support for accessing posterior information of
NumericalTarget, i.e. now including settings consideredMATCHmode in the legacy interface, as well as targets used inDesirabilityObjectiveas_pre_transformationflag toDesirabilityObjectivefor controlling whether the desirability transformation is applied before or after model fittingsupports_partial_measurementsproperty toObjectiveis_normalizedproperty toNumericalTargetnegate,normalize,abs,clamp,log,expandpowermethods toNumericalTargetfor easy creation of transformed targets from existing onesAddition and multiplication dunder methods (for scalar values) to
NumericalTargetget_imagemethod toNumericalTargetfor computing the images of transformed target value rangesSupport for non-normalized targets in
DesirabilityObjectiveObjective.to_botorchmethod for converting objectives to BoTorchqEHVIandqLogEHVIacquisition functions (in addition to their noisy variants)Tests for migrating to new
NumericalTargetinterfaceAPI diagram in user guide
MetadataandMeasurableMetadataclasses providing optional information for BayBE objectsObjectivenow has ametadataattribute as well as adescriptionpropertyTargetandParameternow have ametadataattribute as well asdescriptionandunitpropertiesFPSRecommendernow optionally uses the fpsample library (if installed) with fallback to internal implementation. The use offpsamplecan be deactivated by setting the environment variableBAYBE_USE_FPSAMPLEfarthest_point_samplingnow also supports a collection of integers forinitialization, using them for pre-selecting pointsBenchmarks can now run in different modes, store detailed machine information, and local usage got new file naming and execution options
Changed¶
The behavior of
NumericalTargetis no longer defined via amode(i.e.MIN,MAX,MATCHin legacy interface) but controlled using a minimization flag and corresponding target transformations. This allows for more flexible target definitions, makes invalid target configurations unrepresentable, and is in line with the definition of mathematical optimization problems. Also, it avoids the need to explicitly specify an irrelevant optimization direction in the context of active learning.By default,
DesirabilityObjectivenow fits separate models for each target, rather than modeling only the scalarized desirability value (see newDesirabilityObjective.as_pre_transformationflag). As a result, posterior evaluations now return information for each target individually, instead of just for the desirability value.Objective transformations (both tensor and dataframe based) now always use the Torch computation route, avoiding the need for duplicated transformation logic
Specifying bounds for
Intervalis now optionalunstructure_baseandget_base_structure_hook(de-)serialization utilities have been replaced withunstructure_with_typeandmake_base_structure_hook
Fixed¶
It is no longer possible to use identical names between parameters and targets
Random seed context is correctly set within benchmarks
Measurement input validation now respects typical tolerances associated with floating point representation inaccuracy
Exotic serialization issues with constraints and conditions arising from missing converters for floats
MetaRecommender’s no longer expose their private attributes via the constructor
Removed¶
Telemetry
Option to specify reference values for
add_fake_measurementsconvert_boundsutility (since now equivalent toInterval.create)geom_meanutility
Deprecations¶
Creating
NumericalTargets using amodeargumentTargetModeandTargetTransformationenumslinear_transform,triangular_transformandbell_transformfunctions
Expired Deprecations (from 0.10.*)¶
SequentialGreedyRecommenderclassSubspaceContinuous.samples_randommethodSubspaceContinuous.samples_full_factorialmethoddataargument totransformmethod of search space classesAutomatically setting
allow_extra=Trueintransformmethods of search space classes when left unspecified
[0.13.2] - 2025-07-09¶
Changed¶
Lockfiles are now generated using
uv lockand consumed usinguv sync
Fixed¶
The Python version specifier now also allows patch versions of Python 3.13
[0.13.1] - 2025-06-06¶
Support for Python 3.13
random_tie_breakflag tofarthest_point_samplingto toggle between random or deterministic sampling for equidistant casesrandom_tie_breakandinitializationattributes toFPSRecommenderto control sampling infarthest_point_samplingFlag for toggling parallel computation in
simulate_scenariosAdditional transfer learning and synthetic benchmarks
Utility
normalize_input_dtypesfor ensuring all input dataframe columns have the expected dtypesCompositeSurrogatenow has a_posterior_compmethod similar toSurrogateSHAPInsight.explain_targetmethod for computing explanations for only a specific target
Changed¶
CategoricalParameterandTaskParameternow also allow Boolean entries asvaluesandactive_valuesSubspaceDiscrete.from_dataframenow handles purely Boolean columns differently, inferring aCategoricalParameterwithINTencoding for themSHAPInsight.explainnow returns a tuple of explanations that contains one explanation for each surrogate model used by the (possibly multi-output) objectiveSHAPInsight.plotnow has the optionaltarget_indexargument, enabling users to select for which target they want to plot the shap assessment (default is the first target)add_measurements,update_measurements,fuzzy_row_matchand some.recommendcalls now operate on dtype-normalized copies of the input if it contained unexpected dtypes for a parameter or targetscikit-learnandscipyare now lazy-loadedValidity of optional
model_paramsattribute ofRandomForestSurrogate,NGBoostSurrogateandBayesianLinearSurrogateis now checked via a hardcodedTypedDictinstead of dynamically retrieved specifications, required for lazy-loading related packagesCustomONNXSurrogate.onnx_stris no longer validated before being used
Fixed¶
Using
PosteriorStandardDeviationwithMINtargets no longer results in minimization of the acquisition functionAdded missing garbage collection call to
pareto.py, potentially solving serialization issues in certain casescatch_constant_targetsdecorator is now properly typedIncorrect normalization of explanation shapes for
SHAPInsight
Removed¶
SHAPInsight.uses_shap_explainer
[0.13.0] - 2025-04-16¶
Added¶
extrasgroup for installing all dependencies required for optional featuresSupport for NumPy 2.0+
ParetoObjectiveclass for Pareto optimization of multiple targets and correspondingqNoisyExpectedHypervolumeImprovement/qLogNoisyExpectedHypervolumeImprovement/qLogNParEGOacquisition functionsComposite surrogates now drop rows containing NaNs (separately for each target), effectively enabling partial measurements
SubstanceParameter,CustomDiscreteParameterandCategoricalParameternow also support restricting the search space viaactive_values, whilevaluescontinue to identify allowed measurement inputsCampaign.posterior_statsandSurrogate.posterior_statsas convenience methods for providing statistical measures about the target predictions of a given set of candidatesacquisition_valuesandjoint_acquisition_valueconvenience methods toCampaignandBayesianRecommenderfor computing acquisition valuesCampaign.get_acquisition_functionandBayesianRecommender.get_acquisition_functionconvenience methods for retrieving the underlying acquisition functionAcquisitionFunction.evaluateconvenience method for computing acquisition values from candidates in experimental representationqPSTDacquisition functionBCUT2Dencoding forSubstanceParameterSHAPInsightnow supports thewaterfallplot typeCardinality constraints sections to the user guide
ContinuousCardinalityConstraintis now compatible withBotorchRecommenderAttribute
max_n_subspacestoBotorchRecommender, allowing to control optimization behavior in the presence of cardinality constraintsSurrogate.replicatemethod for making single-target surrogate models multi-target compatibleCompositeSurrogateclass for composing multi-target surrogates from single-target surrogatesis_multi_outputattribute toObjectivesupports_multi_outputattribute/property toSurrogate/AcquisitionFunctionn_outputsproperty toObjectiveAttribute
relative_thresholdand methodget_absolute_thresholdstoContinuousCardinalityConstraintfor handling inactivity rangesUtilities
inactive_parameter_combinationsandn_inactive_parameter_combinationsto bothContinuousCardinalityConstraintandSubspaceContinuousfor iterating over cardinality-constrained parameter setsUtilities
activate_parameterandis_cardinality_fulfilledfor enforcing and validating cardinality constraintsUtility
is_inactivefor determining if parameters are inactiveA
MinimumCardinalityViolatedWarningis triggered when minimum cardinality constraints are violatedStored benchmarking results now include the Python environment and version
Changed¶
Targets are now allowed to contain NaN, deferring potential failure to attempted recommendation instead of data ingestion
For label-like parameters,
SubspaceDiscretenow only includes parameter values that are inactive_valuesThe default value for
sequential_continuousinBotorchRecommenderhas been changed toTrueSHAPInsightnow allows explanation input that has additional columns compared to the background data (will be ignored)Acquisition function indicator
is_mchas been removed in favor of new indicatorssupports_batchingandsupports_pending_experimentsfuzzy_row_matchnow uses vectorized operations, resulting in a speedup of matching measurements to the search space between 4x and 40xModel scaling now uses the parameter bounds instead of the search space bounds
benchmarksmodule now accepts a list of domains to be executedConstruction of BoTorch acquisition functions has been redesigned from ground up
ngboostis now an optional dependencysetuptools-scmis now an optional dependency, used for improved version inferencecreate_example_plots,to_stringandindenthave been relocated within utils
Fixed¶
Incorrect optimization direction with
PSTDwith a single minimization targetProvide version fallback in case scm fails to infer version during installation
Removed¶
fuzzy_row_matchwill no longer warn about entries not matching to the search spacefuncydependencyscikit-learn-extradependency by integrating relevant code parts intobaybe
Expired Deprecations (from 0.9.*)¶
baybe.objectivenamespaceacquisition_function_clsconstructor parameter forBayesianRecommenderVarUCBandqVarUCBacquisition functions
[0.12.2] - 2025-01-31¶
Changed¶
More robust settings for the GP fitting
The
betaparameter ofUCBandqUCBcan now also take negative values
[0.12.1] - 2025-01-29¶
Changed¶
Default of
allow_recommending_already_recommendedis changed back toFalseto avoid exploitation cycles (#468)
[0.12.0] - 2025-01-28¶
Breaking Changes¶
Lookup callables for simulation are now expected to accept/return dataframes with the corresponding parameter/target column labels
Added¶
SHAP explanations via the new
SHAPInsightclassOptional
insightsdependency groupInsights user guide
Example for a traditional mixture
allow_missingandallow_extrakeyword arguments toObjective.transformadd_noise_to_perturb_degenerate_rowsutilitybenchmarkssubpackage for defining and running performance tests –Campaign.toggle_discrete_candidatesto dynamically in-/exclude discrete candidatesfilter_dfutility for filtering dataframe contentarrays_to_dataframesdecorator to create lookups from array-based callablesDiscreteConstraint.get_validto conveniently access valid candidatesFunctionality for persisting benchmarking results on S3 from a manual pipeline run
remain_switchedoption toTwoPhaseMetaRecommenderis_statefulclass variable toMetaRecommenderget_non_meta_recommendermethod toMetaRecommender
Changed¶
SubstanceParameterencodings are now computed exclusively with thescikit-fingerprintspackage, granting access to all fingerprints available thereinExample for slot-based mixtures has been revised and grouped together with the new traditional mixture example
Memory caching is now non-verbose
CustomDiscreteParameterdoes not allow duplicated rows indataanymoreDe-/activating Polars via
BAYBE_DEACTIVATE_POLARSnow requires passing values compatible withstrtoboolAll arguments to
MetaRecommender.select_recommenderare now optionalMetaRecommenders can now be composed of otherMetaRecommendersFor performance reasons, search space manipulation using
polarsis no longer guaranteed to produce the same row order as the correspondingpandasoperationsallow_repeated_recommendationshas been renamed toallow_recommending_already_recommendedand is nowTrueby default
Fixed¶
Rare bug arising from degenerate
SubstanceParameter.comp_dfrows that caused wrong number of recommendations being returnedContinuousConstraints can now be used in single point precisionSearch spaces are now stateless, preventing unintended side effects that could lead to incorrect candidate sets when reused in different optimization contexts
qNIPVnot working with singleMINtargetsPassing a
TargetTransformationwithout passingboundswhen creating aNumericalTargetnow raises an errorCrash when using
ContinuousCardinalityConstraintcaused by an unintended interplay between constraints and dropped parameters yielding empty parameter setsMinimizing a single
NumericalTargetwith specified bounds/transformation viaSingleTargetObjectiveno longer erroneously maximizes itallow_*flags are now context-aware, i.e. setting them in a context where they are irrelevant now raises an error instead of passing silently
Removed¶
botorch_function_wrapperutility for creating lookup callables
Deprecations¶
Passing a dataframe via the
dataargument toObjective.transformis no longer possible. The dataframe must now be passed as positional argument.The new
allow_extraflag is automatically set toTrueinObjective.transformwhen left unspecifiedget_transform_parametershas been replaced withget_transform_objectsPassing a dataframe via the
dataargument toTarget.transformis no longer possible. The data must now be passed as a series as first positional argument.SubstanceEncodingvalueMORGAN_FP. As a replacement,ECFPwith 1024 bits and radius of 4 can be used.SubstanceEncodingvalueRDKIT. As a replacement,RDKIT2DDESCRIPTORScan be used.The
metadataattribute ofSubspaceDiscreteno longer exists. Metadata is now exclusively handled by theCampaignclass.get_current_recommenderandget_next_recommenderofMetaRecommenderhave become obsolete and calling them is no longer possiblePassing
allow_*flags to recommenders is no longer supported since the necessary metadata required for the flags is no longer available at that level. The functionality has been taken over byCampaign.
[0.11.4] - 2025-01-27¶
Changed¶
Polars lazy streaming has been deactivated due to instabilities
Fixed¶
Improvement-based Monte Carlo acquisition functions now use the correct reference value for single-target minimization
[0.11.3] - 2024-11-06¶
Fixed¶
protobufdependency issue, version pin was removed
[0.11.2] - 2024-10-11¶
Added¶
n_restartsandn_raw_sampleskeywords to configure continuous optimization behavior forBotorchRecommenderUser guide for utilities
mypyrule expecting explicitoverridemarkers for method overrides
Changed¶
Utility
add_fake_resultsrenamed toadd_fake_measurementsUtilities
add_fake_measurementsandadd_parameter_noisenow also return the dataframe they modified in-place
Fixed¶
Leftover attrs-decorated classes are garbage collected before the subclass tree is traversed, avoiding sporadic serialization problems
[0.11.1] - 2024-10-01¶
Added¶
Continuous linear constraints have been consolidated in the new
ContinuousLinearConstraintclass
Changed¶
get_surrogatenow also returns the model for transformed single targets or desirability objectives
Fixed¶
Unsafe name-based matching of columns in
get_comp_rep_parameter_indices
Deprecations¶
ContinuousLinearEqualityConstraintandContinuousLinearInequalityConstraintreplaced byContinuousLinearConstraintwith the correspondingoperatorkeyword
[0.11.0] - 2024-09-09¶
Breaking Changes¶
The public methods of
Surrogatemodels now operate on dataframes in experimental representation instead of tensors in computational representationSurrogate.posteriormodels now returns aPosteriorobjectparam_bounds_compofSearchSpace,SubspaceDiscreteandSubspaceContinuoushas been replaced withcomp_rep_bounds, which returns a dataframe
Added¶
py.typedfile to enable the use of type checkers on the user sideIndependentGaussianSurrogatebase class for surrogate models providing independent Gaussian posteriors for all candidates (cannot be used for batch prediction)comp_rep_columnsproperty forParameter,SearchSpace,SubspaceDiscreteandSubspaceContinuousclassesNew mechanisms for surrogate input/output scaling configurable per class
SurrogateProtocolas an interface for user-defined surrogate architecturesSupport for binary targets via
BinaryTargetclassSupport for bandit optimization via
BetaBernoulliMultiArmedBanditSurrogateclassBandit optimization example
qThompsonSamplingacquisition functionBetaPriorclassrecommendnow accepts thepending_experimentsargument, informing the algorithm about points that were already selected for evaluationPure recommenders now have the
allow_recommending_pending_experimentsflag, controlling whether pending experiments are excluded from candidates in purely discrete search spacesget_surrogateandposteriormethods toCampaigntenacitytest dependencyMulti-version documentation
Changed¶
The transition from experimental to computational representation no longer happens in the recommender but in the surrogate
Fallback models created by
catch_constant_targetsare stored outside the surrogateto_tensornow also handlesnumpyarraysMINmode ofNumericalTargetis now implemented via the acquisition function instead of negating the computational representationSearch spaces now store their parameters in alphabetical order by name
Improvement-based acquisition functions now consider the maximum posterior mean instead of the maximum noisy measurement as reference value
Iteration tests now attempt up to 5 repeated executions if they fail due to numerical reasons
Fixed¶
CategoricalParameterandTaskParameterno longer incorrectly coerce a single string input to categories/tasksfarthest_point_samplingno longer depends on the provided point orderBatch predictions for
RandomForestSurrogateSurrogates providing only marginal posterior information can no longer be used for batch recommendation
SearchSpace.from_dataframenow creates a proper empty discrete subspace without index when called with continuous parameters onlyMetadata updates are now only triggered when a discrete subspace is present
Unintended reordering of discrete search space parts for recommendations obtained with
BotorchRecommender
Removed¶
register_custom_architecturedecoratorScalarandDefaultScalerclasses
Deprecations¶
The role of
register_custom_architecturehas been taken over bybaybe.surrogates.base.SurrogateProtocolBayesianRecommender.surrogate_modelhas been replaced withget_surrogate
[0.10.0] - 2024-08-02¶
Breaking Changes¶
Providing an explicit
batch_sizeis now mandatory when asking for recommendationsRecommenderProtocol.recommendnow accepts an optionalObjectiveRecommenderProtocol.recommendnow expects training data to be provided as a single dataframe in experimental representation instead of two separate dataframes in computational representationParameter.is_numerichas been replaced withParameter.is_numericalDiscreteParameter.transform_rep_exp2comphas been replaced withDiscreteParameter.transformfilter_attributeshas been replaced withmatch_attributes
Added¶
Surrogatebase class now exposes ato_botorchmethodSubspaceDiscrete.to_searchspaceandSubspaceContinuous.to_searchspaceconvenience constructorValidators for
Campaignattributes_optionalsubpackage for managing optional dependenciesNew acquisition functions for active learning:
qNIPV(negative integrated posterior variance) andPSTD(posterior standard deviation)Acquisition function:
qKG(knowledge gradient)Abstract
ContinuousNonlinearConstraintclassAbstract
CardinalityConstraintclass andDiscreteCardinalityConstraint/ContinuousCardinalityConstraintsubclassesUniform sampling mechanism for continuous spaces with cardinality constraints
register_hooksutility enabling user-defined augmentation of arbitrary callablestransformmethods ofSearchSpace,SubspaceDiscreteandSubspaceContinuousnow take additionalallow_missingandallow_extrakeyword argumentsMore details to the transfer learning user guide
Activated doctests
SubspaceDiscrete.from_parameter,SubspaceContinuous.from_parameter,SubspaceContinuous.from_productandSearchSpace.from_parameterconvenience constructorsDiscreteParameter.to_subspace,ContinuousParameter.to_subspaceandParameter.to_searchspaceconvenience constructorsUtilities for permutation and dependency data augmentation
Validation and translation tests for kernels
BasicKernelandCompositeKernelbase classesActivated
pre-commit.ciwith auto-updateUser guide for active learning
Polars expressions for
DiscreteSumConstraint,DiscreteProductConstraint,DiscreteExcludeConstraint,DiscreteLinkedParametersConstraintandDiscreteNoLabelDuplicatesConstraintDiscrete search space Cartesian product can be created lazily via Polars
Examples demonstrating the
register_hooksutility: basic registration mechanism, monitoring the probability of improvement, and automatic campaign stoppingDocumentation building now uses a lockfile to fix the exact environment
Changed¶
Passing an
ObjectivetoCampaignis now optionalGaussianProcessSurrogatemodels are no longer wrapped when cast to BoTorchRestrict upper versions of main dependencies, motivated by major
numpyreleaseSampling methods in
qNIPVandBotorchRecommenderare now specified viaDiscreteSamplingMethodenumIntervalclass now supports degenerate intervals containing only one elementadd_fake_resultsnow directly processesTargetobjects instead of aCampaignpathargument in plotting utility is now optional and defaults toPath(".")UnusedObjectWarningby non-predictive recommenders is now ignored during simulationsThe default kernel factory now avoids strong jumps by linearly interpolating between two fixed low and high dimensional prior regimes
The previous default kernel factory has been renamed to
EDBOKernelFactoryand now fully reflects the original logicThe default acquisition function has been changed from
qEItoqLogEIfor improved numerical stability
Removed¶
Support for Python 3.9 removed due to new BoTorch requirements and guidelines from Scientific Python
Linter
typosfor spellchecking
Fixed¶
sequentialflag ofSequentialGreedyRecommenderis now set toTrueSerialization bug related to class layout of
SKLearnClusteringRecommenderMetaRecommenders no longer trigger warnings about non-empty objectives or measurements when calling aNonPredictiveRecommenderBug introduced in 0.9.0 (PR #221, commit 3078f3), where arguments to
to_gpytorchare not passed on to the GPyTorch kernelsPositive-valued kernel attributes are now correctly handled by validators and hypothesis strategies
As a temporary workaround to compensate for missing
IndexKernelpriors,fit_gpytorch_mll_torchis used instead offit_gpytorch_mllwhen aTaskParameteris present, which acts as regularization via early stopping during model fitting
Deprecations¶
SequentialGreedyRecommenderclass replaced withBotorchRecommenderSubspaceContinuous.samples_randomhas been replaced withSubspaceContinuous.sample_uniformSubspaceContinuous.samples_full_factorialhas been replaced withSubspaceContinuous.sample_from_full_factorialPassing a dataframe via the
dataargument to thetransformmethods ofSearchSpace,SubspaceDiscreteandSubspaceContinuousis no longer possible. The dataframe must now be passed as positional argument.The new
allow_extraflag is automatically set toTrueintransformmethods of search space classes when left unspecified
Expired Deprecations (from 0.7.*)¶
Interval.is_finitepropertySpecifying target configs without type information
Specifying parameters/constraints at the top level of a campaign configs
Passing
numerical_measurements_must_be_within_tolerancetoCampaignbatch_quantityargumentPassing
allow_repeated_recommendationsorallow_recommending_already_measuredtoMetaRecommender(or formerStrategy)*Strategyclasses andbaybe.strategiessubpackageSpecifying
MetaRecommender(or formerStrategy) configs without type information
[0.9.1] - 2024-06-04¶
Changed¶
Discrete searchspace memory estimate is now natively represented in bytes
Fixed¶
Non-GP surrogates not working with
deepcopyand the simulation package due to slotted base classDatatype inconsistencies for various parameters’
valuesandcomp_dfandSubSelectionCondition’sselectionrelated to floating point precision
[0.9.0] - 2024-05-21¶
Added¶
Class hierarchy for objectives
AdditiveKernel,LinearKernel,MaternKernel,PeriodicKernel,PiecewisePolynomialKernel,PolynomialKernel,ProductKernel,RBFKernel,RFFKernel,RQKernel,ScaleKernelclassesKernelFactoryprotocol enabling context-dependent construction of kernelsPreset mechanism for
GaussianProcessSurrogatehypothesisstrategies and roundtrip test for kernels, constraints, objectives, priors and acquisition functionsNew acquisition functions:
qSR,qNEI,LogEI,qLogEI,qLogNEIGammaPrior,HalfCauchyPrior,NormalPrior,HalfNormalPrior,LogNormalPriorandSmoothedBoxPriorclassesPossibility to deserialize classes from optional class name abbreviations
Basic deserialization tests using different class type specifiers
Serialization user guide
Environment variables user guide
Utility for estimating memory requirements of discrete product search space
mypyfor search space and objectives
Changed¶
Reorganized acquisition.py into
acquisitionsubpackageReorganized simulation.py into
simulationsubpackageReorganized gaussian_process.py into
gaussian_processsubpackageAcquisition functions are now their own objects
acquisition_function_clsconstructor parameter renamed toacquisition_functionUser guide now explains the new objective classes
Telemetry deactivation warning is only shown to developers
torch,gpytorchandbotorchare lazy-loaded for improved startup timeIf an exception is encountered during simulation, incomplete results are returned with a warning instead of passing through the uncaught exception
Environment variables
BAYBE_NUMPY_USE_SINGLE_PRECISIONandBAYBE_TORCH_USE_SINGLE_PRECISIONto enforce single point precision usage
Removed¶
model_paramsattribute fromSurrogatebase class,GaussianProcessSurrogateandCustomONNXSurrogateDependency on
requestspackage
Fixed¶
n_task_paramsnow evaluates to 1 iftask_idx == 0Simulation no longer fails in
ignoremode when lookup dataframe contains duplicate parameter configurationsSimulation no longer fails for targets in
MATCHmodeclosest_elementnow works for array-like input of all kindsStructuring concrete subclasses no longer requires providing an explicit
typefield_target(s)attributes ofObjectivesare now (de-)serialized without leading underscore to support user-friendly serialization stringsTelemetry does not execute any code if it was disabled
Running simulations no longer alters the states of the global random number generators
Deprecations¶
The former
baybe.objective.Objectiveclass has been replaced withSingleTargetObjectiveandDesirabilityObjectiveacquisition_function_clsconstructor parameter forBayesianRecommenderVarUCBandqVarUCBacquisition functions
Expired Deprecations (from 0.6.*)¶
BayBEclassbaybe.surrogatemodulebaybe.targets.Objectiveclassbaybe.strategies.Strategyclass
[0.8.2] - 2024-03-27¶
Added¶
Simulation user guide
Example for transfer learning backtesting utility
pyupgradepre-commit hookBetter human readable
__str__representation of objective and targetsAlternative dataframe deserialization from
pd.DataFrameconstructors
Changed¶
More detailed and sophisticated search space user guide
Support for Python 3.12
Upgraded syntax to Python 3.9
Bumped
onnxversion to fix vulnerabilityIncreased threshold for low-dimensional GP priors
Replaced
fit_gpytorch_mll_torchwithfit_gpytorch_mllUse
tox-uvin pipelines
Fixed¶
telemetrydependency is no longer a group (enables Poetry installation)
[0.8.1] - 2024-03-11¶
Added¶
Better human readable
__str__representation of campaignREADME now contains an example on substance encoding results
Transfer learning user guide
from_simplexconstructor now also takes and applies optional constraints
Changed¶
Full lookup backtesting example now tests different substance encodings
Replaced unmaintained
mordreddependency bymordredcommunitySearchSpaces now usendarrayinstead ofTensor
Fixed¶
from_simplexnow efficiently validated inCampaign.validate_config
[0.8.0] - 2024-02-29¶
Changed¶
BoTorch dependency bumped to
>=0.9.3
Removed¶
Workaround for BoTorch hybrid recommender data type
Support for Python 3.8
[0.7.4] - 2024-02-28¶
Added¶
Subpackages for the available recommender types
Multi-style plotting capabilities for generated example plots
JSON file for plotting themes
Smoke testing in relevant tox environments
ContinuousParameterbase classNew environment variable
BAYBE_CACHE_DIRthat can customize the disk cache directory or turn off disk caching entirelyOptions to control the number of nonzero parameters in
SubspaceDiscrete.from_simplexTemporarily ignore ONNX vulnerabilities
Better human readable
__str__representation of search spacespretty_print_dffunction for printing shortened versions of dataframesBasic Transfer Learning example
Repo now has reminders (https://github.com/marketplace/actions/issue-reminder) enabled
mypyfor recommenders
Changed¶
Recommenders now share their core logic via their base classRemove progress bars in examples
Strategies are now called
MetaRecommender’s and part of therecommenders.metamoduleRecommender’s are now calledPureRecommender’s and part of therecommenders.puremodulestrategykeyword ofCampaignrenamed torecommenderNaiveHybridRecommenderrenamed toNaiveHybridSpaceRecommender
Fixed¶
Unhandled exception in telemetry when username could not be inferred on Windows
Metadata is now correctly updated for hybrid spaces
Unintended deactivation of telemetry due to import problem
Line wrapping in examples
Deprecations¶
TwoPhaseStrategy,SequentialStrategyandStreamingSequentialStrategyhave been replaced with their newMetaRecommenderversions
[0.7.3] - 2024-02-09¶
Added¶
Copy button for code blocks in documentation
mypyfor campaign, constraints and telemetryTop-level example summaries
RecommenderProtocolas common interface forStrategyandRecommenderSubspaceDiscrete.from_simplexconvenience constructor
Changed¶
Order of README sections
Imports from top level
baybe.utilsno longer possibleRenamed
utils.numerictoutils.numericalOptional
chemdependencies are lazily imported, improving startup time
Fixed¶
Several minor issues in documentation
Visibility and constructor exposure of
Campaignattributes that should be privateTaskParameters no longer disappear from computational representation when the search space contains only one task parameter valueFailing
baybeimport from environments containing only core dependencies caused by eagerly loadingchemdependenciestoxcoretestnow uses correct environment and skips unavailable testsBasic serialization example no longer requires optional
chemdependencies
Removed¶
Detailed headings in table of contents of examples
Deprecations¶
Passing
numerical_measurements_must_be_within_toleranceto theCampaignconstructor is no longer supported. Instead,Campaign.add_measurementsnow takes an additional parameter to control the behavior.batch_quantityreplaced withbatch_sizeallow_repeated_recommendationsandallow_recommending_already_measuredare now attributes ofRecommenderand no longer attributes ofStrategy
[0.7.2] - 2024-01-24¶
Added¶
Target enums
mypyfor targets and intervalsTests for code blocks in README and user guides
hypothesisstrategies and roundtrip tests for targets, intervals, and dataframes(De-)serialization of target subclasses via base class
Docs building check now part of CI
Automatic formatting checks for code examples in documentation
Deserialization of classes with classmethod constructors can now be customized by providing an optional
constructorfieldSearchSpace.from_dataframeconvenience constructor
Changed¶
Renamed
bounds_transform_functarget attribute totransformationInterval.is_boundednow implements the mathematical definition of boundednessMoved and renamed target transform utility functions
Examples have two levels of headings in the table of content
Fix orders of examples in table of content
DiscreteCustomConstraintvalidator now expects dataframe instead of seriesignore_exampleflag builds but does not execute examples when building documentationNew user guide versions for campaigns, targets and objectives
Binarization of dataframes now happens via pickling
Fixed¶
Wrong use of
toleranceargument in constraints user guideErrors with generics and type aliases in documentation
Deduplication bug in substance_data
hypothesisstrategyUse pydoclint as flake8 plugin and not as a stand-alone linter
Margins in documentation for desktop and mobile version
Intervals can now also be deserialized from a bounds iterableSubspaceDiscreteandSubspaceContinuousnow have (de-)serialization methods
Removed¶
Conda install instructions and version badge
Early fail for different Python versions in regular pipeline
Deprecations¶
Interval.is_finitereplaced withInterval.is_boundedSpecifying target configs without explicit type information is deprecated
Specifying parameters/constraints at the top level of a campaign configuration JSON is deprecated. Instead, an explicit
searchspacefield must be provided with an optionalconstructorentry
[0.7.1] - 2023-12-07¶
Added¶
Release pipeline now also publishes source distributions
hypothesisstrategies and tests for parameters package
Changed¶
Reworked validation tests for parameters package
SubstanceParameternow collects inconsistent user input in anExceptionGroup
Fixed¶
Link handling in documentation
[0.7.0] - 2023-12-04¶
Added¶
GitHub CI pipelines
GitHub documentation pipeline
Optional
--forceoption for building the documentation despite errorsEnabled passing optional arguments to
tox -e docscallsLogo and banner images
Project metadata for pyproject.toml
PyPI release pipeline
Favicon for homepage
More literature references
First drafts of first user guides
Changed¶
Reworked README for GitHub landing page
Now has concise contribution guidelines
Use Furo theme for documentation
Removed¶
--debugflag for documentation building
[0.6.1] - 2023-11-27¶
Added¶
Script for building HTML documentation and corresponding
toxenvironmentLinter
typosfor spellcheckingParameter encoding enums
mypyfor parameters packagetoxenvironments formypy
Changed¶
Replacing
pylint,flake8,µfmtandusortwithruffMarkdown based documentation replaced with HTML based documentation
Fixed¶
encodingis no longer a class variableNow installed with correct
pandasdependency flagcomp_dfcolumn names forCustomDiscreteParameterare now safe
[0.6.0] - 2023-11-17¶
Added¶
Raisessection for validators and corresponding contributing guidelineBring your own model: surrogate classes for custom model architectures and pre-trained ONNX models
Test module for deprecation warnings
Option to control the switching point of
TwoPhaseStrategy(formerStrategy)SequentialStrategyandStreamingSequentialStrategyclassesTelemetry env variable
BAYBE_TELEMETRY_VPN_CHECKturning the initial connectivity check on/offTelemetry env variable
BAYBE_TELEMETRY_VPN_CHECK_TIMEOUTfor setting the connectivity check timeout
Changed¶
Reorganized modules into subpackages
Serialization no longer relies on cattrs’ global converter
Refined (un-)structuring logic
Telemetry env variable
BAYBE_TELEMETRY_HOSTrenamed toBAYBE_TELEMETRY_ENDPOINTTelemetry env variable
BAYBE_DEBUG_FAKE_USERHASHrenamed toBAYBE_TELEMETRY_USERNAMETelemetry env variable
BAYBE_DEBUG_FAKE_HOSTHASHrenamed toBAYBE_TELEMETRY_HOSTNAMEBumped cattrs version
Fixed¶
Now supports Python 3.11
Removed
pyarrowversion pinTaskParameteradded to serialization testDeserialization (e.g. from config) no longer silently drops unknown arguments
Deprecations¶
BayBEclass replaced withCampaignbaybe.surrogatereplaced withbaybe.surrogatesbaybe.targets.Objectivereplaced withbaybe.objective.Objectivebaybe.strategies.Strategyreplaced withbaybe.strategies.TwoPhaseStrategy
[0.5.1] - 2023-10-19¶
Added¶
Linear in-/equality constraints over continuous parameters
Constrained optimization for
SequentialGreedyRecommenderRandomRecommendernow supports linear in-/equality constraints via polytope sampling
Changed¶
Include linting for all functions
Rewrite functions to distinguish between private and public ones
Unreachable telemetry endpoints now automatically disables telemetry and no longer cause any data submission loops
add_fake_resultsutility now considers potential target boundsConstraint names have been refactored to indicate whether they operate on discrete or continuous parameters
Fixed¶
Random recommendation failing for small discrete (sub-)spaces
Deserialization issue with
TaskParameter
[0.5.0] - 2023-09-15¶
Added¶
TaskParameterfor multitask modellingBasic transfer learning capability using multitask kernels
Advanced simulation mechanisms for transfer learning and search space partitioning
Extensive docstring documentation in all files
Autodoc using sphinx
Script for automatic code documentation
New
toxenvironments for a full and a core-only pytest run
Changed¶
Discrete subspaces require unique indices
Simulation function signatures are redesigned (but largely backwards compatible)
Docstring contents and style (numpy -> google)
Regrouped additional dependencies
[0.4.2] - 2023-08-29¶
Added¶
Test environments for multiple Python versions via
tox
Changed¶
Removed
environment.ymlTelemetry host endpoint is now flexible via the environment variable
BAYBE_TELEMETRY_HOST
Fixed¶
Inference for
__version__
[0.4.1] - 2023-08-23¶
Added¶
Vulnerability check via
pip-audittestsdependency group
Changed¶
Removed no longer required
fsspecdependency
Fixed¶
Scipy vulnerability by bumping version to 1.10.1
Missing
pyarrowdependency
[0.4.0] - 2023-08-16¶
Added¶
from_dataframeconvenience constructors for discrete and continuous subspacesfrom_boundsconvenience constructor for continuous subspacesemptyconvenience constructors discrete and continuous subspacesbaybe,strategiesandutilsnamespace for convenient importsSimple test for config validation
VarUCBandqVarUCBacquisition functions emulating maximum variance for active learningSurrogate model serialization
Surrogate model parameter passing
Changed¶
Renamed
createconstructors tofrom_productRenamed
emptychecks for subspaces tois_emptyFixed inconsistent class names in surrogate.py
Fixed inconsistent class names in parameters.py
Cached recommendations are now private
Parameters, targets and objectives are now immutable
Adjusted comments in example files
Accelerated the slowest tests
Removed try blocks from config examples
Upgraded numpy requirement to >= 1.24.1
Requires
protobuf<=3.20.3SearchSpaceparameters in surrogate models are now handled infitDataframes are encoded in binary for serialization
comp_repis loaded directly from the serialization string
Fixed¶
Include scaling in FPS recommender
Support for pandas>=2.0.0
[0.3.2] - 2023-07-24¶
Added¶
Constraints serialization
Changed¶
A maximum of one
DependenciesConstraintis allowedBumped numpy and matplotlib versions
[0.3.1] - 2023-07-17¶
Added¶
Code coverage check with pytest-cov
Hybrid mode for
SequentialGreedyRecommender
Changed¶
Removed support for infinite parameter bounds
Removed not yet implemented MULTI objective mode
Fixed¶
Changelog assert in Azure pipeline
Bug: telemetry could not be fully deactivated
[0.3.0] - 2023-06-27¶
Added¶
Intervalclass for representing parameter/target boundsActivated mypy for the first few modules and fixed their type issues
Automatic (de-)serialization and
SerialMixinclassBasic serialization example, demo and tests
Mechanisms for loading and validating config files
Telemetry via OpenTelemetry
More detailed package installation info
Fallback mechanism for
NonPredictiveRecommenderIntroduce naive hybrid recommender
Changed¶
Switched from pydantic to attrs in all modules except constraints.py
Removed subclass initialization hooks and
typeattributeRefactored class attributes and their conversion/validation/initialization
Removed no longer needed
HashableDictclassRefactored strategy and recommendation module structures
Replaced dict-based configuration logic with object-based logic
Overall versioning scheme and version inference for telemetry
No longer using private telemetry imports
Fixed package versions for dev tools
Revised “Getting Started” section in README.md
Revised examples
Fixed¶
Telemetry no longer crashing when package was not installed
[0.2.4] - 2023-03-24¶
Added¶
Tests for different search space types and their compatible recommenders
Changed¶
Initial strategies converted to recommenders
Config keyword
initial_strategyreplaced byinitial_recommender_clsConfig keywords for the clustering recommenders changed from
xtoCLUSTERING_xskicit-learn-extra is now optional dependency in the [extra] group
Type identifiers of greedy recommenders changed to ‘SEQUENTIAL_GREEDY_x’
Fixed¶
Parameter bounds now only contain dimensions that actually appear in the search space
[0.2.3] - 2023-03-14¶
Added¶
Parsing for continuous parameters
Caching of recommendations to avoid unnecessary computations
Strategy support for hybrid spaces
Custom discrete constraint with user-provided validator
Changed¶
Parameter class hierarchy
SearchSpacehas now a discrete and continuous subspaceModel fit now done upon requesting recommendations
Fixed¶
Updated BoTorch and GPyTorch versions are also used in pyproject.toml
[0.2.2] - 2023-01-13¶
Added¶
SearchSpaceclassCode testing with pytest
Option to specify initial data for backtesting simulations
SequentialGreedyRecommender class
Changed¶
Switched from miniconda to micromamba in Azure pipeline
Fixed¶
BoTorch version upgrade to fix critical bug (https://github.com/pytorch/botorch/pull/1454)
[0.2.1] - 2022-12-01¶
Fixed¶
Parameters cannot be initialized with duplicate values
[0.2.0] - 2022-11-10¶
Added¶
Initial strategy: Farthest Point Sampling
Initial strategy: Partitioning Around Medoids
Initial strategy: K-means
Initial strategy: Gaussian Mixture Model
Constraints and conditions for discrete parameters
Data scaling functionality
Decorator for automatic model scaling
Decorator for handling constant targets
Decorator for handling batched model input
Surrogate model: Mean prediction
Surrogate model: Random forrest
Surrogate model: NGBoost
Surrogate model: Bayesian linear
Save/load functionality for BayBE objects
Fixed¶
UCB now usable as acquisition function, hard-set beta parameter to 1.0
Temporary GP priors now exactly reproduce EDBO setting
[0.1.0] - 2022-10-01¶
Added¶
Code skeleton with a central object to access functionality
Basic parser for categorical parameters with one-hot encoding
Basic parser for discrete numerical parameters
Azure pipeline for code formatting and linting
Single-task Gaussian process strategy
Streamlit dashboard for comparing single-task strategies
Input functionality to read measurements including automatic matching to search space
Integer encoding for categorical parameters
Parser for numerical discrete parameters
Single numerical target with Min and Max mode
Recommendation functionality
Parameter scaling depending on parameter types and user-chosen scalers
Noise and fake-measurement utilities
Internal metadata storing various info about datapoints in the search space
BayBE options controlling recommendation and data addition behavior
Config parsing and validation using pydantic
Global random seed control
Strategy connection with BayBE object
Custom parameters as labels with user-provided encodings
Substance parameters which are encoded via cheminformatics descriptors
Data cleaning utilities useful for descriptors
Simulation capabilities for testing the package on existing data
Parsing and preprocessing for multiple targets / desirability ansatz
Basic README file
Automatic publishing of tagged versions
Caching of experimental parameters and chemical descriptors
Choices for acquisition functions and their usage with arbitrary surrogate models
Temporary logic for selecting GP priors