SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2206.00093 · ICML · 2022

Easy Variational Inference for Categorical Models via an Independent Binary Approximation

Shuchin Aeron, Michael Hughes, Eric Miller, Michael Wojnowicz

arXiv · PDF · Open in the Atlas

Code that ran

12 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, 0 violated it and 12 have no contract verdict; 0 failures of our instrument; 0 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/2206.00093.json · badge: /api/ran/2206.00093.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
tufts-ml/categorical-from-binary canonical (classifier label)
classifier basis not recorded on the link
12 ran · 0 no recorded run
FunctionStatusWhere it lives
filter_df_rows_by_column_value_starts Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/pandas_helpers.py
code served (permissive licence) · get_code("71d333b70be0ccdd")
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, through the batch API) and returned DataFrame. 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 pandas as pd
from pandas.core.frame import DataFrame

# Create a small DataFrame with string values in a column
df = pd.DataFrame({
    'name': ['apple', 'apricot', 'banana', 'blueberry', 'cherry'],
    'price': [1.0, 1.5, 0.5, 2.0, 3.0]
})

col = 'name'
start = 'ap'

ARGS = {
    'df': df,
    'col': col,
    'start': start
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
pandas — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type DataFrame — a DataFrame output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a DataFrame output the recorded ndim 2 and dtype family float describe that coercion, not the output, and are not 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
filter_df_rows_by_column_values Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/pandas_helpers.py
code served (permissive licence) · get_code("0f26726e6c96d6a0")
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, through the batch API) and returned DataFrame. 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 pandas as pd
from typing import List, Union

# Create a sample DataFrame with some data
df = pd.DataFrame({
    'name': ['Alice', 'Bob', 'Charlie', 'Diana', 'Eve'],
    'department': ['Sales', 'Engineering', 'Sales', 'HR', 'Engineering'],
    'salary': [50000, 75000, 55000, 60000, 80000]
})

# Define ARGS dict with all parameters
ARGS = {
    'df': df,
    'col': 'department',
    'values': ['Sales', 'HR']
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
pandas — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type DataFrame — a DataFrame output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a DataFrame output the recorded ndim 2 and dtype family float describe that coercion, not the output, and are not 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
get_num_parameters_from_num_covariates_and_num_categories Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/data_generation_configs.py
code served (permissive licence) · get_code("c974930c753cdc8c")
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, through the batch API) and returned int, ndim 0, dtype family int, 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 numpy as np

torch.manual_seed(0)

# The function takes two parameters: num_categories and num_covariates
# Both are integers used in a simple arithmetic computation
# K * (M + 1) where K = num_categories and M = num_covariates

ARGS = {
    "num_categories": 5,
    "num_covariates": 3,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type int, ndim 0, dtype family int, 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
keep_df_rows_by_column_values Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/pandas_helpers.py
code served (permissive licence) · get_code("0db50263e8ae0301")
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, through the batch API) and returned DataFrame. 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 pandas as pd
from typing import List, Union

# Create a sample dataframe
df = pd.DataFrame({
    'category': ['A', 'B', 'C', 'A', 'B', 'D'],
    'value': [10, 20, 30, 40, 50, 60],
    'name': ['x', 'y', 'z', 'w', 'v', 'u']
})

# Test with single string value
col = 'category'
values_single = 'A'

# Test with list of values
values_list = ['A', 'B']

# Define ARGS for the function call
ARGS = {
    'df': df,
    'col': col,
    'values': values_list
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
pandas — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type DataFrame — a DataFrame output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a DataFrame output the recorded ndim 2 and dtype family float describe that coercion, not the output, and are not 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
log1mexp Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/math.py
code served (permissive licence) · get_code("3ab47a237d19109f")
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, through the batch API) and returned ndarray, ndim 1, dtype family float, shape (4,) 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 numpy as np

# The function log1mexp takes a single parameter 'x' which should be:
# - A negative array/value (all components must be <= 0)
# - Will be converted to numpy array with dtype='float'

# Create a small negative array to test the function
x = np.array([-0.5, -1.0, -2.0, -0.1], dtype='float')

ARGS = {
    'x': x
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 1, dtype family float, shape (4,) — shape (4,) 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
logdiffexp Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/math.py
code served (permissive licence) · get_code("dfddd8469d3cd0db")
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, through the batch API) and returned ndarray, ndim 1, dtype family float, shape (4,) 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 numpy as np

# Create simple numpy arrays as arguments
# The function expects two arguments: a and b
# Both should be numpy arrays or array-like
# According to the function, they should work with log and exp operations

# Create valid inputs - negative values work well since log1mexp expects negative inputs
a = np.array([-1.0, -2.0, -0.5, -3.0])
b = np.array([-2.0, -3.0, -1.0, -4.0])

# Ensure b < a so that b - a is negative (required by log1mexp)
b = b - 1.0  # Make b more negative than a

ARGS = {
    'a': a,
    'b': b
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 1, dtype family float, shape (4,) — shape (4,) 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
make_data_generation_configs Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/data_generation_configs.py
code served (permissive licence) · get_code("fc11b46107b382aa")
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, through the batch API) and returned list, 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 torch
import numpy as np
from dataclasses import dataclass
from typing import List

torch.manual_seed(0)

@dataclass
class DataGenerationConfig:
    seed: int
    n_categories: int
    n_features: int
    n_samples: int
    scale_for_predictive_categories: float

def get_num_parameters_from_num_covariates_and_num_categories(num_categories: int, num_covariates: int):
    K, M = (num_categories, num_covariates)
    return K * (M + 1)

def make_data_generation_configs(list_of_n_categories: List[int], multipliers_on_n_categories_to_create_n_covariates: List[int], multipliers_on_n_parameters_to_create_n_samples: List[int], list_of_scales_for_predictive_categories: List[float], seed: int=1) -> List[DataGenerationConfig]:
    data_generation_configs = []
    for K in list_of_n_categories:
        for multiplier_to_create_n_covariates in multipliers_on_n_categories_to_create_n_covariates:
            M = K * multiplier_to_create_n_covariates
            P = get_num_parameters_from_num_covariates_and_num_categories(K, M)
            for multiplier_to_create_n_samples in multipliers_on_n_parameters_to_create_n_samples:
                N = P * multiplier_to_create_n_samples
                for scale in list_of_scales_for_predictive_categories:
                    data_generation_config = DataGenerationConfig(seed, K, M, N, scale)
                    data_generation_configs.append(data_generation_config)
    return data_generation_configs

ARGS = {
    "list_of_n_categories": [2, 3],
    "multipliers_on_n_categories_to_create_n_covariates": [1, 2],
    "multipliers_on_n_parameters_to_create_n_samples": [2],
    "list_of_scales_for_predictive_categories": [0.5, 1.0],
    "seed": 42
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list 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
read_json Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/io.py
code served (permissive licence) · get_code("4111075441a4120b")
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, through the batch API) and returned dict. 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 json
import tempfile
import os

# Create a temporary JSON file with test data
temp_dir = tempfile.mkdtemp()
test_file = os.path.join(temp_dir, "test.json")

test_data = {
    "key1": "value1",
    "key2": [1, 2, 3],
    "key3": {"nested": "object"}
}

with open(test_file, 'w') as f:
    json.dump(test_data, f)

ARGS = {
    "filename": test_file
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not 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
sample_from_categorical Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/dists.py
code served (permissive licence) · get_code("da18b79a24971fb3")
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, through the batch API) and returned int64, ndim 0, dtype family int, 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 numpy as np

# Create a valid probability distribution
# The function expects a numpy array that sums to approximately 1.0
# We'll create a simple categorical distribution over 3 categories
probs = np.array([0.5, 0.3, 0.2])

ARGS = {
    "probs": probs,
    "one_indexed": False
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type int64, ndim 0, dtype family int, 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
sigmoid Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/kl.py
code served (permissive licence) · get_code("d66872774634bad5")
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, through the batch API) and returned float64, ndim 0, 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 numpy as np

def sigmoid(x: float) -> float:
    return 1 / (1 + np.exp(-x))

ARGS = {
    "x": 0.5
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float64, ndim 0, dtype family float — no output shape is stated: observe_signature.py recorded float ndim 0, which disagrees with the fixture run
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
sorted_covariate_names_from_covariate_dict Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/covariate_dict.py
code served (permissive licence) · get_code("2c3961e53bd7a402")
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, through the batch API) and returned list, 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.

from dataclasses import dataclass
from enum import Enum
from typing import Dict, List, Optional

class VariableType(Enum):
    BINARY = 1
    CONTINUOUS = 2

@dataclass
class VariableInfo:
    type: VariableType
    index: int
    raw_mean: Optional[float] = None
    raw_std: Optional[float] = None
    raw_min: Optional[float] = None
    raw_max: Optional[float] = None

covariate_dict = {
    "age": VariableInfo(
        type=VariableType.CONTINUOUS,
        index=0,
        raw_mean=45.2,
        raw_std=15.3,
        raw_min=18.0,
        raw_max=80.0
    ),
    "gender": VariableInfo(
        type=VariableType.BINARY,
        index=1
    ),
    "blood_pressure": VariableInfo(
        type=VariableType.CONTINUOUS,
        index=2,
        raw_mean=120.5,
        raw_std=10.2,
        raw_min=90.0,
        raw_max=180.0
    ),
    "smoker": VariableInfo(
        type=VariableType.BINARY,
        index=3
    )
}

ARGS = {
    "covariate_dict": covariate_dict
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list 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
str_from_mamr Ran
ran on a synthesized input
tufts-ml/categorical-from-binary/src/categorical_from_binary/model_algo_meta_results.py
code served (permissive licence) · get_code("d946b4dba60a2282")
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, through the batch API) and returned str. 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 torch
import numpy as np
from dataclasses import dataclass, field
from enum import Enum
from typing import List, Optional
from pandas.core.frame import DataFrame

class Model(Enum):
    TRUE_MODEL = 1
    SOFTMAX = 2
    CB_PROBIT = 3
    CB_LOGIT = 4

class Algo(Enum):
    NOT_APPLICABLE = 1
    IB_CAVI = 1
    HMC = 2
    ADVI = 3
    PGA_GIBBS = 4

@dataclass
class ModelAlgoMetaResults:
    model: Model
    algo: Algo
    meta_str: Optional[str] = None
    results: List[DataFrame] = field(default_factory=list)

def str_from_mamr(mamr: ModelAlgoMetaResults):
    return f'{mamr.model.name}+{mamr.algo.name}+{mamr.meta_str}'

# Create a valid ModelAlgoMetaResults instance
mamr_instance = ModelAlgoMetaResults(
    model=Model.SOFTMAX,
    algo=Algo.HMC,
    meta_str="test_meta",
    results=[]
)

ARGS = {
    "mamr": mamr_instance
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, pandas, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not 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

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, 0 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 0 later) and 12 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.

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

We pursue tractable Bayesian analysis of generalized linear models (GLMs) for categorical data. Thus far, GLMs are difficult to scale to more than a few dozen categories due to non-conjugacy or strong posterior dependencies when using conjugate auxiliary variable methods. We define a new class of GLMs for categorical data called categorical-from-binary (CB) models. Each CB model has a likelihood that is bounded by the product of binary likelihoods, suggesting a natural posterior approximation. This approximation makes inference straightforward and fast; using well-known auxiliary variables for probit or logistic regression, the product of binary models admits conjugate closedform variational inference that is embarrassingly parallel across categories and invariant to category ordering. Moreover, an independent binary model simultaneously approximates multiple CB models. Bayesian model averaging over these can improve the quality of the approximation for any given dataset. We show that our approach scales to thousands of categories, outperforming posterior estimation competitors like Automatic Differentiation Variational Inference (ADVI) and No U-Turn Sampling (NUTS) in the time required to achieve fixed prediction quality.

For agents

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

get_harvested_code_for_paper("2206.00093")
get_code_for_paper("2206.00093")
have("2206.00093")

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

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

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

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

Connect an agent — have() is free.