SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2312.17210 · ICML · 2022

Continual Learning via Sequential Function-Space Variational Inference

Freddie Smith, Yarin Gal, Yee Whye Teh, Tim Rudner, Qixuan Feng

arXiv · PDF · Open in the Atlas

Code that ran

8 of 12 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 2 violated it and 0 have no contract verdict; 6 failures of our instrument; 4 no recorded run), measured 2026-11-23; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2312.17210.json · badge: /api/ran/2312.17210.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
timrudner/S-FSVI marked official in Papers with Code
Papers with Code archive
8 ran · 4 no recorded run
FunctionStatusWhere it lives
_slice_cov_diag Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("5b16317c03b0bd99")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned ArrayImpl, ndim 1, dtype family float, shape (5,) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import jax.numpy as jnp

# Create test covariance matrices for different dimensions
# 2D case: (batch, output_dim)
cov_2d = jnp.ones((5, 4))

# 3D case: (batch, batch, output_dim)
cov_3d = jnp.ones((5, 5, 4))

# 4D case: (batch, output_dim, batch, output_dim)
cov_4d = jnp.ones((5, 4, 5, 4))

# Index for output dimension
index = 2

ARGS = {
    "cov": cov_2d,
    "index": index
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
jax — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ArrayImpl, ndim 1, dtype family float, shape (5,) — shape (5,) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
compute_scale Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("3824b581d117e190")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned ArrayImpl, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import jax.numpy as jnp

# Create a small input array with shape (batch_size, features)
# Using distinct dimensions: 2 for batch, 4 for features
inputs = jnp.ones((2, 4), dtype=jnp.float32)

# Define arguments for all parameters
ARGS = {
    'kl_scale': 'equal',
    'inputs': inputs,
    'n_context_points': 8,
    'n_marginals': 2
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
jax — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ArrayImpl, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
kl_diag_tfd Ran
ran, violated the contract we drafted
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("503acbd8a8dd384b")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned ArrayImpl, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import jax.numpy as jnp
import numpy as np

# Set seed for reproducibility
np.random.seed(0)

# Create small test tensors
batch_size = 2
dim = 4

# mean_q: mean of distribution q, shape (dim,)
mean_q = jnp.array(np.random.randn(dim), dtype=jnp.float32)

# mean_p: mean of distribution p, shape (dim,)
mean_p = jnp.array(np.random.randn(dim), dtype=jnp.float32)

# cov_q: covariance of distribution q (diagonal), shape (dim,)
# Using positive values since they will be square-rooted
cov_q = jnp.array(np.abs(np.random.randn(dim)) + 0.1, dtype=jnp.float32)

# cov_p: covariance of distribution p (diagonal), shape (dim,)
cov_p = jnp.array(np.abs(np.random.randn(dim)) + 0.1, dtype=jnp.float32)

ARGS = {
    "mean_q": mean_q,
    "mean_p": mean_p,
    "cov_q": cov_q,
    "cov_p": cov_p,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
jax, numpy, tensorflow_probability — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ArrayImpl, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
kl_full_cov Ran
ran, violated the contract we drafted
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("51f7c9b8b5d3f076")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned ArrayImpl, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import jax.numpy as jnp
import numpy as np

# Set seed for reproducibility
np.random.seed(0)

# Define dimensions
dims = 4

# Create mean vectors
mean_q = jnp.array(np.random.randn(dims), dtype=jnp.float32)
mean_p = jnp.array(np.random.randn(dims), dtype=jnp.float32)

# Create positive definite covariance matrices
# Generate random matrices and make them positive definite via A @ A.T
A_q = np.random.randn(dims, dims)
cov_q = jnp.array(A_q @ A_q.T, dtype=jnp.float32)

A_p = np.random.randn(dims, dims)
cov_p = jnp.array(A_p @ A_p.T, dtype=jnp.float32)

ARGS = {
    "mean_q": mean_q,
    "mean_p": mean_p,
    "cov_q": cov_q,
    "cov_p": cov_p,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
jax, numpy, tensorflow_probability — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ArrayImpl, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
mc_sampling Ran
ran; our contract draft was wrong, not the code
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("c2d7c7bd970a3e6e")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned tuple. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import jax
import jax.numpy as jnp

# Define a simple function that takes a random key and returns MC samples
# The function should return logits of shape (batch_size, output_dimension)
def sample_fn(rng_key):
    """
    A deterministic function that takes a random key and returns one MC sample.
    Returns logits of shape (2, 4) - batch_size=2, output_dimension=4
    """
    # Use the random key to generate some deterministic output
    samples = jax.random.normal(rng_key, shape=(2, 4))
    return samples

# Set up the arguments
n_samples = 3
rng_key = jax.random.PRNGKey(0)

ARGS = {
    "fn": sample_fn,
    "n_samples": n_samples,
    "rng_key": rng_key,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
jax — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple — a tuple output has no array shape of its own; none is stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
partition_params Ran
ran; our contract draft was wrong, not the code
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("ec683524697b1d80")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned tuple, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import haiku as hk
from jax import jit
import jax.numpy as jnp

# Create a minimal hk.Params structure
# hk.Params is a nested dict structure: {module_name: {param_name: value}}

# Build params with the expected structure:
# - Some parameters with 'w_mu', 'b_mu' (mean parameters)
# - Some parameters with 'w_logvar', 'b_logvar' (log variance parameters)
# - Some deterministic parameters

params = {
    'layer_1': {
        'w_mu': jnp.array([[1.0, 2.0], [3.0, 4.0]]),
        'b_mu': jnp.array([0.5, 0.6]),
        'w_logvar': jnp.array([[-1.0, -0.5], [-0.8, -1.2]]),
        'b_logvar': jnp.array([-2.0, -2.5]),
    },
    'layer_2': {
        'w': jnp.array([[0.1, 0.2, 0.3], [0.4, 0.5, 0.6]]),
        'b': jnp.array([0.01, 0.02, 0.03]),
    },
    'layer_3': {
        'w_mu': jnp.array([[1.5, 2.5], [3.5, 4.5]]),
        'b_mu': jnp.array([0.7, 0.8]),
        'w_logvar': jnp.array([[-1.5, -0.7], [-0.9, -1.3]]),
        'b_logvar': jnp.array([-2.1, -2.6]),
    },
}

ARGS = {
    'params': params,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
haiku, jax — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
predicate_mean Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("5bdc5fe9c1f2ebaa")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned bool, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn

torch.manual_seed(0)

# The function predicate_mean takes three parameters:
# - module_name: str
# - name: str
# - value: Any
# 
# The function body checks if name equals 'w_mu' or 'b_mu'
# It doesn't actually use module_name or value in any way,
# so we just need to provide valid values for all three parameters.

ARGS = {
    'module_name': 'example_module',
    'name': 'w_mu',
    'value': torch.randn(4, 3)
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
predicate_var Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("0c60a5bd05dc6879")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned bool, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn

torch.manual_seed(0)

# The function predicate_var checks if a parameter name is 'w_logvar' or 'b_logvar'
# It takes:
# - module_name: str - the name of a module
# - name: str - the name of a parameter
# - value: Any - the value of the parameter (not used in the function body)

# Construct valid arguments
module_name = "linear_layer"
name = "w_logvar"
value = torch.randn(4, 3)

ARGS = {
    "module_name": module_name,
    "name": name,
    "value": value
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
Model Not yet run
unverified (harvested, no recorded run)
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("e148b71fa281c7ec")
How it ran

no invocation recorded.

Objectives_hk Not yet run
unverified (harvested, no recorded run)
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("a3bf9af5ad5221a3")
How it ran

no invocation recorded.

_check_input Not yet run
unverified (harvested, no recorded run)
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("93d046554acd6e89")
How it ran

no invocation recorded.

kl_divergence_min_max_dim Not yet run
unverified (harvested, no recorded run)
timrudner/S-FSVI/sfsvi/fsvi_utils/objectives_cl.py
code served (permissive licence) · get_code("6193e6e4eb074382")
How it ran

no invocation recorded.

Also present in other papers' code

Of 12 samples lifted from this paper's linked repositories, 12 carry a function identity and 0 do not. Of the 12 distinct functions with an identity, 2 are also present in other papers whose code we hold (2 with at least one paper dated earlier, 0 the same month, 0 later) and 10 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
kl_full_cov
brick of this paper's assembly: loss
1 other paper
1 dated earlier
2307.15073 (2023-07)
Drug Discovery under Covariate Shift with Domain-Informed Prior Distributions over Functions
mc_sampling
brick of this paper's assembly: helper
1 other paper
1 dated earlier
2307.15073 (2023-07)
Drug Discovery under Covariate Shift with Domain-Informed Prior Distributions over Functions

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-23.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

Sequential Bayesian inference over predictive functions is a natural framework for continual learning from streams of data. However, applying it to neural networks has proved challenging in practice. Addressing the drawbacks of existing techniques, we propose an optimization objective derived by formulating continual learning as sequential function-space variational inference. In contrast to existing methods that regularize neural network parameters directly, this objective allows parameters to vary widely during training, enabling better adaptation to new tasks. Compared to objectives that directly regularize neural network predictions, the proposed objective allows for more flexible variational distributions and more effective regularization. We demonstrate that, across a range of task sequences, neural networks trained via sequential function-space variational inference achieve better predictive accuracy than networks trained with related methods while depending less on maintaining a set of representative points from previous tasks.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2312.17210")
get_code_for_paper("2312.17210")
have("2312.17210")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2312.17210.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2312.17210.svg)](https://syntology.ai/paper/2312.17210)

Connect an agent — have() is free.