Skip to content

Index Kernel#747

Merged
AdrianSosic merged 8 commits intodev/gpfrom
feature/index_kernel
Mar 6, 2026
Merged

Index Kernel#747
AdrianSosic merged 8 commits intodev/gpfrom
feature/index_kernel

Conversation

@AdrianSosic
Copy link
Collaborator

@AdrianSosic AdrianSosic commented Feb 11, 2026

DevPR, parent is #745

Adds the IndexKernel and PositiveIndexKernel classes

The new factory design added in #746 offers full customization of the GP, following a composition approach. To reach the full potential that this offers, having BayBE IndexKernel classes to let the user to construct custom architectures is the natural next step, in particular because there other reasonable choices than just having the standard ICM product, such as:

In addition:

  • It finally provides an interface for configuring the kernel itself, e.g. its rank (which used to be a TODO for ages)
  • And it offers the new parameter-named BayBE for conveniently specifying active dimensions for the above tasks.

@AdrianSosic AdrianSosic self-assigned this Feb 11, 2026
Copilot AI review requested due to automatic review settings February 11, 2026 15:35
@AdrianSosic AdrianSosic added new feature New functionality dev labels Feb 11, 2026
@AdrianSosic AdrianSosic mentioned this pull request Feb 11, 2026
18 tasks
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds an IndexKernel and expands GaussianProcessSurrogate customization via kernel/mean/likelihood factories, including new GP presets and serialization behavior for non-BayBE GP components.

Changes:

  • Introduces IndexKernel and adds it to Hypothesis kernel strategies.
  • Refactors GP surrogate to accept kernel/mean/likelihood components (including some GPyTorch objects), adds EDBO / EDBO_SMOOTHED presets, and updates preset exports.
  • Updates serialization hooks and generic/abstract type handling; adds tests for transfer learning and GPyTorch-kernel behavior.

Reviewed changes

Copilot reviewed 23 out of 23 changed files in this pull request and generated 12 comments.

Show a summary per file
File Description
tests/test_transfer_learning.py Adds transfer-learning recommendation test coverage
tests/test_gp.py Adds tests for using GPyTorch kernels and blocking their serialization
tests/hypothesis_strategies/kernels.py Extends kernel generation strategies to include IndexKernel
baybe/utils/boolean.py Updates abstract detection to handle generics
baybe/utils/basic.py Updates subclass discovery to handle generics
baybe/surrogates/gaussian_process/presets/utils.py Adds lazy-loaded constant mean factory
baybe/surrogates/gaussian_process/presets/edbo_smoothed.py Adds “smoothed EDBO” kernel/likelihood preset implementations
baybe/surrogates/gaussian_process/presets/edbo.py Refactors EDBO preset into kernel/mean/likelihood factories
baybe/surrogates/gaussian_process/presets/default.py Repoints default preset to smoothed EDBO kernel/likelihood + lazy mean
baybe/surrogates/gaussian_process/presets/core.py Adds preset enum values and preset-based GP construction
baybe/surrogates/gaussian_process/presets/init.py Expands exported preset factories and core API
baybe/surrogates/gaussian_process/kernel_factory.py Removes old kernel factory module (replaced by components)
baybe/surrogates/gaussian_process/core.py Adds mean/likelihood factories; uses component factories and IndexKernel for multitask
baybe/surrogates/gaussian_process/components/mean.py Introduces GP mean component factory typing
baybe/surrogates/gaussian_process/components/likelihood.py Introduces GP likelihood component factory typing
baybe/surrogates/gaussian_process/components/kernel.py Introduces GP kernel component factory typing
baybe/surrogates/gaussian_process/components/generic.py Adds generic component factory + serialization blocking hook for GPyTorch kernels
baybe/surrogates/gaussian_process/components/init.py Exposes component factory types
baybe/serialization/core.py Improves base-class (un)structuring and non-BayBE type names in error messages
baybe/searchspace/core.py Refactors task-parameter lookup into a helper property
baybe/kernels/basic.py Adds IndexKernel
baybe/kernels/base.py Updates kernel factory import path and broadens active_dims type
CHANGELOG.md Documents new GP customization support, presets, and IndexKernel

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@AdrianSosic AdrianSosic changed the base branch from main to dev/gp February 15, 2026 20:41
@AdrianSosic AdrianSosic marked this pull request as draft February 25, 2026 12:58
@AdrianSosic AdrianSosic force-pushed the feature/index_kernel branch 3 times, most recently from 7268da2 to e54676d Compare March 2, 2026 17:26
@AdrianSosic AdrianSosic marked this pull request as ready for review March 3, 2026 08:27
@AdrianSosic AdrianSosic force-pushed the feature/index_kernel branch 2 times, most recently from 1b0e29f to 8d6385d Compare March 4, 2026 08:55
Copy link
Collaborator

@AVHopp AVHopp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, only one minor question regarding the design

@AdrianSosic AdrianSosic force-pushed the feature/index_kernel branch from eccb673 to feca6e0 Compare March 6, 2026 10:26
@AdrianSosic AdrianSosic force-pushed the feature/index_kernel branch from feca6e0 to 59be817 Compare March 6, 2026 15:28
@AdrianSosic AdrianSosic merged commit af70d31 into dev/gp Mar 6, 2026
12 of 13 checks passed
@AdrianSosic AdrianSosic deleted the feature/index_kernel branch March 6, 2026 16:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dev new feature New functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants