SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2304.00902 · AAAI · 2023

FinalMLP: An Enhanced Two-Stream MLP Model for CTR Prediction

Zhenhua Dong, Jieming Zhu, Guohao Cai, Liangcai Su, Kelong Mao, Yuru Li

arXiv · PDF · Open in the Atlas

Code that ran

13 of 16 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (4 of them constructed an object rather than computing a result; 1 honoured the contract we drafted, 1 violated it and 6 have no contract verdict; 5 failures of our instrument; 3 no recorded run), measured 2026-11-22; 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/2304.00902.json · badge: /api/ran/2304.00902.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
reczoo/FuxiCTR community
Papers with Code archive
9 ran · 3 no recorded run
clabrugere/final-mlp community
Papers with Code archive
4 ran · 0 no recorded run
FunctionStatusWhere it lives
Aggregation Ran
ran on a synthesized input · constructed an object; no result was computed
clabrugere/final-mlp/model/pytorch/final_mlp.py
code served (permissive licence) · get_code("d5e892b1d0d28990")
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 an instance of its own class, Aggregation: the run constructed the object and did not call it, so no result was computed. 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
from torch import nn

torch.manual_seed(0)

# Parameters for Aggregation.__init__
dim_inputs_1 = 8
dim_inputs_2 = 6
num_heads = 2

# Create the model instance
model = nn.Module()

# Create sample inputs for forward pass
# inputs_1 should have shape that flattens to (-1, num_heads, dim_head_1)
# where dim_head_1 = dim_inputs_1 // num_heads = 8 // 2 = 4
# So inputs_1 shape: (batch_size, dim_inputs_1) = (2, 8)
inputs_1 = torch.randn(2, dim_inputs_1)

# inputs_2 should have shape (batch_size, dim_inputs_2) = (2, 6)
# which flattens to (-1, num_heads, dim_head_2) where dim_head_2 = 6 // 2 = 3
inputs_2 = torch.randn(2, dim_inputs_2)

ARGS = {
    'dim_inputs_1': dim_inputs_1,
    'dim_inputs_2': dim_inputs_2,
    'num_heads': num_heads,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Aggregation — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a Aggregation 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
FeatureSelection Ran
ran on a synthesized input · constructed an object; no result was computed
clabrugere/final-mlp/model/pytorch/final_mlp.py
code served (permissive licence) · get_code("07f45f16e61c0ae2")
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 an instance of its own class, FeatureSelection: the run constructed the object and did not call it, so no result was computed. 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 torch.nn as nn
from torch.nn import functional as F

torch.manual_seed(0)

# Define the MLP and FeatureSelection classes
class MLP(nn.Sequential):

    def __init__(self, dim_in, num_hidden, dim_hidden, dim_out=None, batch_norm=True, dropout=0.0):
        layers = []
        for _ in range(num_hidden - 1):
            layers.append(nn.Linear(dim_in, dim_hidden))
            if batch_norm:
                layers.append(nn.BatchNorm1d(dim_hidden))
            layers.append(nn.ReLU())
            layers.append(nn.Dropout(dropout))
            dim_in = dim_hidden
        if dim_out:
            layers.append(nn.Linear(dim_in, dim_out))
        else:
            layers.append(nn.Linear(dim_in, dim_hidden))
        super().__init__(*layers)

class FeatureSelection(nn.Module):

    def __init__(self, dim_input, num_hidden=1, dim_hidden=64, dropout=0.0):
        super().__init__()
        self.gate_1 = MLP(dim_in=dim_input, num_hidden=num_hidden, dim_hidden=dim_hidden, dim_out=dim_input, dropout=dropout, batch_norm=False)
        self.gate_2 = MLP(dim_in=dim_input, num_hidden=num_hidden, dim_hidden=dim_hidden, dim_out=dim_input, dropout=dropout, batch_norm=False)

    def forward(self, inputs):
        gate_score_1 = self.gate_1(inputs)
        out_1 = 2.0 * F.sigmoid(gate_score_1) * inputs
        gate_score_2 = self.gate_2(inputs)
        out_2 = 2.0 * F.sigmoid(gate_score_2) * inputs
        return (out_1, out_2)

# Create test inputs
dim_input = 4
num_hidden = 2
dim_hidden = 8
dropout = 0.1

ARGS = {
    "dim_input": dim_input,
    "num_hidden": num_hidden,
    "dim_hidden": dim_hidden,
    "dropout": dropout,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type FeatureSelection — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a FeatureSelection 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
FinalMLP Ran
ran on a synthesized input · constructed an object; no result was computed
clabrugere/final-mlp/model/pytorch/final_mlp.py
code served (permissive licence) · get_code("0a00a4a1ea6c8870")
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 an instance of its own class, FinalMLP: the run constructed the object and did not call it, so no result was computed. 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
from torch import nn

torch.manual_seed(0)

ARGS = {
    'dim_input': 4,
    'num_embedding': 10,
    'dim_embedding': 3,
    'dim_hidden_fs': 16,
    'num_hidden_1': 2,
    'dim_hidden_1': 8,
    'num_hidden_2': 2,
    'dim_hidden_2': 8,
    'num_heads': 2,
    'dropout': 0.1,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type FinalMLP — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a FinalMLP 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
InteractionAggregation Ran
ran on a synthesized input
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("0ab1e9e21b122c6e")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, class construct-then-call prompt, model not recorded) and returned Tensor, ndim 2, dtype family float, shape (2, 2) 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
from torch import nn

class InteractionAggregation(nn.Module):
    """Interaction aggregation module for fusing two MLP outputs.

    Args:
        x_dim (int): Dimension of the first input.
        y_dim (int): Dimension of the second input.
        output_dim (int): Output dimension. Default: ``1``.
        num_heads (int): Number of attention heads. Default: ``1``.
    """

    def __init__(self, x_dim, y_dim, output_dim=1, num_heads=1):
        super(InteractionAggregation, self).__init__()
        assert x_dim % num_heads == 0 and y_dim % num_heads == 0, 'Input dim must be divisible by num_heads!'
        self.num_heads = num_heads
        self.output_dim = output_dim
        self.head_x_dim = x_dim // num_heads
        self.head_y_dim = y_dim // num_heads
        self.w_x = nn.Linear(x_dim, output_dim)
        self.w_y = nn.Linear(y_dim, output_dim)
        self.w_xy = nn.Parameter(torch.Tensor(num_heads * self.head_x_dim * self.head_y_dim, output_dim))
        nn.init.xavier_normal_(self.w_xy)

    def forward(self, x, y):
        """Forward pass of InteractionAggregation.

        Args:
            x: First input tensor.
            y: Second input tensor.

        Returns:
            torch.Tensor: Aggregated output tensor.
        """
        output = self.w_x(x) + self.w_y(y)
        head_x = x.view(-1, self.num_heads, self.head_x_dim)
        head_y = y.view(-1, self.num_heads, self.head_y_dim)
        xy = torch.matmul(torch.matmul(head_x.unsqueeze(2), self.w_xy.view(self.num_heads, self.head_x_dim, -1)).view(-1, self.num_heads, self.output_dim, self.head_y_dim), head_y.unsqueeze(-1)).squeeze(-1)
        output += xy.sum(dim=1)
        return output


INIT_ARGS = {
    'x_dim': 4,
    'y_dim': 6,
    'output_dim': 2,
    'num_heads': 2,
}

ARGS = {
    'x': torch.randn(2, 4),
    'y': torch.randn(2, 6),
}

if __name__ == '__main__':
    module = InteractionAggregation(**INIT_ARGS)
    result = module(**ARGS)
    print(f"Output shape: {result.shape}")
    print(f"Output: {result}")
Setup block drafted by
a language model, class construct-then-call prompt, model not recorded
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 2) — shape (2, 2) 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: torch and numpy seeded to 0 by the harness immediately before the class was constructed from INIT_ARGS (fixture_check.py)
MLP Ran
ran on a synthesized input · constructed an object; no result was computed
clabrugere/final-mlp/model/pytorch/final_mlp.py
code served (permissive licence) · get_code("51a52dde5114fedf")
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 an instance of its own class, MLP: the run constructed the object and did not call it, so no result was computed. 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 torch.nn as nn

torch.manual_seed(0)

ARGS = {
    "dim_in": 4,
    "num_hidden": 3,
    "dim_hidden": 8,
    "dim_out": 2,
    "batch_norm": True,
    "dropout": 0.1,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type MLP — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a MLP output the recorded ndim 1 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
Monitor Ran
ran on a synthesized input
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("499d39b01f527cf2")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, class construct-then-call prompt, model not recorded) and returned float, 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 numpy as np

INIT_ARGS = {
    "kv": {"AUC": 1.0, "logloss": -1.0, "accuracy": 0.5}
}

ARGS = {
    "logs": {"AUC": 0.8, "logloss": 0.4, "accuracy": 0.9}
}

METHOD = "get_value"


class Monitor(object):
    """Monitor a weighted combination of metrics for early stopping.

    Tracks one or more metric names, each with an optional weight.
    If a single string is passed, it is treated as a metric with weight 1.

    Args:
        kv (str or dict): Metric name(s) and their weights.

    Example::

        monitor = Monitor({"AUC": 1.0, "logloss": -1.0})
        score = monitor.get_value({"AUC": 0.8, "logloss": 0.4})
    """

    def __init__(self, kv):
        if isinstance(kv, str):
            kv = {kv: 1}
        self.kv_pairs = kv

    def get_value(self, logs):
        """Compute the weighted sum of monitored metrics.

        Args:
            logs (dict): Dictionary of metric names to values.

        Returns:
            float: Weighted sum of metric values.
        """
        value = 0
        for k, v in self.kv_pairs.items():
            value += logs.get(k, 0) * v
        return value

    def get_metrics(self):
        """Get the list of monitored metric names.

        Returns:
            list: List of metric name strings.
        """
        return list(self.kv_pairs.keys())


if __name__ == "__main__":
    monitor = Monitor(**INIT_ARGS)
    result = monitor.get_value(**ARGS)
    print(f"Weighted score: {result}")
    print(f"Monitored metrics: {monitor.get_metrics()}")
Setup block drafted by
a language model, class construct-then-call prompt, model not recorded
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float, 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: torch and numpy seeded to 0 by the harness immediately before the class was constructed from INIT_ARGS (fixture_check.py)
evaluate_block Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("3bdff5f3c936a29e")
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 2, 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 polars as pl
import numpy as np

# Create a small polars DataFrame with y_true and y_pred columns
df = pl.DataFrame({
    'y_true': np.array([0, 1, 1, 0]),
    'y_pred': np.array([0.1, 0.9, 0.8, 0.2])
})

# Define some simple metric functions
def accuracy_metric(y_true, y_pred):
    """Returns accuracy as a single value."""
    pred_binary = (y_pred > 0.5).astype(int)
    return np.mean(y_true == pred_binary)

def precision_with_weight(y_true, y_pred):
    """Returns precision as a tuple with weight."""
    pred_binary = (y_pred > 0.5).astype(int)
    tp = np.sum((pred_binary == 1) & (y_true == 1))
    fp = np.sum((pred_binary == 1) & (y_true == 0))
    precision = tp / (tp + fp) if (tp + fp) > 0 else 0.0
    return (precision, 2)

def mse_metric(y_true, y_pred):
    """Returns MSE as a single value."""
    return np.mean((y_true - y_pred) ** 2)

metric_funcs = [accuracy_metric, precision_with_weight, mse_metric]

ARGS = {
    'df': df,
    'metric_funcs': metric_funcs
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, polars — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 2, 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
evaluate_metrics Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("35e81e110e77d460")
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 OrderedDict. 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 numpy as np
import polars as pl
from collections import OrderedDict

# Define some simple metric functions that will be used
def AUC(y_true, y_pred):
    from sklearn.metrics import roc_auc_score
    return roc_auc_score(y_true, y_pred)

def gAUC(y_true, y_pred):
    # Simple stub returning a tuple (value, weight)
    return (0.85, 1)

def avgAUC(y_true, y_pred):
    return (0.82, 1)

def MRR(y_true, y_pred):
    return (0.75, 1)

def NDCG(y_true, y_pred):
    return (0.80, 1)

# Setup for evaluate_metrics function
y_true = np.array([0, 1, 1, 0, 1, 0])
y_pred = np.array([0.1, 0.9, 0.8, 0.2, 0.85, 0.15])
metrics = ['logloss', 'AUC']
group_id = None

ARGS = {
    'y_true': y_true,
    'y_pred': y_pred,
    'metrics': metrics,
    'group_id': group_id,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, polars, sklearn — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type OrderedDict — a OrderedDict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a OrderedDict 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
get_device Ran
ran; our contract draft was wrong, not the code
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("d84794ade6798b01")
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 device. The image it ran in was not recorded. The code mentions cuda, and the harness aliases cuda to the CPU for every sample; whether this run needed that is 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

torch.manual_seed(0)

# The function get_device takes a single parameter: gpu (int)
# It checks if gpu >= 0 and torch.cuda.is_available()
# Since we're CPU-only, we should test both cases:
# 1. gpu < 0 (should return CPU device)
# 2. gpu >= 0 but CUDA unavailable (should also return CPU device)

ARGS = {
    'gpu': -1
}
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 device — a device output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a device 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
get_loss Ran
ran; our contract draft was wrong, not the code
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("ea1739926fa16075")
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 function. 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 torch.nn.functional as F

torch.manual_seed(0)

# Test with a string loss function name
ARGS = {
    'loss': 'binary_cross_entropy'
}
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 function — a function output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a function 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
get_optimizer Ran
ran; our contract draft was wrong, not the code
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("f4900d192f5425d4")
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 Adam. 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 torch.nn as nn

torch.manual_seed(0)

# Create a simple model with parameters
model = nn.Linear(4, 3)
params = model.parameters()

# Define arguments for get_optimizer
ARGS = {
    'optimizer': 'Adam',
    'params': params,
    'lr': 0.001
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Adam — a Adam output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Adam 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
get_regularizer Ran
ran, honoured the contract we drafted
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("9bc88c320ce26df9")
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 list, ndim 2, 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

torch.manual_seed(0)

# Test cases for get_regularizer function
# The function takes a regularization specification (float or str) and returns list of (p_norm, weight) tuples

ARGS = {
    "reg": 0.01  # float case: L2 regularization with weight 0.01
}

# Additional test cases to verify the function works:
# - float: 0.5 -> [(2, 0.5)]
# - "l1(0.1)" -> [(1, 0.1)]
# - "l2(0.05)" -> [(2, 0.05)]
# - "l1_l2(0.1,0.05)" -> [(1, 0.1), (2, 0.05)]
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
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 2, 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
not_in_whitelist Ran
ran, violated the contract we drafted
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("c8d2350eac52fbd6")
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 numpy as np

# Test case 1: element not in list whitelist
element_1 = "apple"
whitelist_1 = ["banana", "orange", "grape"]

# Test case 2: element in list whitelist
element_2 = "banana"
whitelist_2 = ["banana", "orange", "grape"]

# Test case 3: empty whitelist
element_3 = "apple"
whitelist_3 = []

# Test case 4: scalar whitelist (non-list)
element_4 = 5
whitelist_4 = 5

# Test case 5: scalar whitelist with non-matching element
element_5 = 3
whitelist_5 = 5

# Use the first test case for ARGS
ARGS = {
    "element": element_1,
    "whitelist": whitelist_1
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
numpy, 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
BaseModel Not yet run
unverified (harvested, no recorded run)
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("50a4a3e87fa74c6f")
How it ran

no invocation recorded.

FeatureSelection Not yet run
unverified (harvested, no recorded run)
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("fd88018841000e9e")
How it ran

no invocation recorded.

FinalMLP Not yet run
unverified (harvested, no recorded run)
reczoo/FuxiCTR/model_zoo/FinalMLP/src/FinalMLP.py
code served (permissive licence) · get_code("443355df7a417c7f")
How it ran

no invocation recorded.

Also present in other papers' code

Of 16 samples lifted from this paper's linked repositories, 16 carry a function identity and 0 do not. Of the 16 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 16 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-22.

Repositories linked to this paper

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

Abstract

Click-through rate (CTR) prediction is one of the fundamental tasks for online advertising and recommendation. While multi-layer perceptron (MLP) serves as a core component in many deep CTR prediction models, it has been widely recognized that applying a vanilla MLP network alone is inefficient in learning multiplicative feature interactions. As such, many two-stream interaction models (e.g., DeepFM and DCN) have been proposed by integrating an MLP network with another dedicated network for enhanced CTR prediction. As the MLP stream learns feature interactions implicitly, existing research focuses mainly on enhancing explicit feature interactions in the complementary stream. In contrast, our empirical study shows that a well-tuned two-stream MLP model that simply combines two MLPs can even achieve surprisingly good performance, which has never been reported before by existing work. Based on this observation, we further propose feature selection and interaction aggregation layers that can be easily plugged to make an enhanced two-stream MLP model, FinalMLP. In this way, it not only enables differentiated feature inputs but also effectively fuses stream-level interactions across two streams. Our evaluation results on four open benchmark datasets as well as an online A/B test in our industrial system show that FinalMLP achieves better performance than many sophisticated two-stream CTR models. Our source code will be available at MindSpore/models and Fux-iCTR/model zoo.

For agents

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

get_harvested_code_for_paper("2304.00902")
get_code_for_paper("2304.00902")
have("2304.00902")

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

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

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

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

Connect an agent — have() is free.