SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2206.03200 · 2022

FairVFL: A Fair Vertical Federated Learning Framework with Contrastive Adversarial Learning

arXiv · PDF · Open in the Atlas

Code that ran

3 of 11 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 3 have no contract verdict; 0 failures of our instrument; 8 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.03200.json · badge: /api/ran/2206.03200.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
taoqi98/fairvfl canonical (classifier label)
classifier basis not recorded on the link
3 ran · 8 no recorded run
FunctionStatusWhere it lives
ZipImages Ran
ran on a synthesized input
taoqi98/fairvfl/CelebA/raw_data_process.py
code served (permissive licence) · get_code("056528ae1a7e37bf")
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 4, dtype family int, shape (2, 54, 44, 3) 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 small batch of images with shape (batch_size, height, width, channels)
# The function expects images with height=218 and width=178
batch_size = 2
images = np.random.randint(0, 256, size=(batch_size, 218, 178, 3), dtype='uint8')

# Define arguments for ZipImages function
ARGS = {
    'images': images,
    'zip_ratio': 4
}
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 4, dtype family int, shape (2, 54, 44, 3) — shape (2, 54, 44, 3) 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
evaluate_performance Ran
ran on a synthesized input
taoqi98/fairvfl/Adult/evaluation.py
code served (permissive licence) · get_code("66e15f4aa7e87d58")
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 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 torch
import numpy as np
from sklearn.metrics import f1_score

torch.manual_seed(0)

# Create a mock model with a predict method
class MockModel:
    def predict(self, features):
        # Return a tuple where first element is predictions
        # predictions should have shape (batch_size, num_classes)
        batch_size = features.shape[0]
        predictions = np.random.rand(batch_size, 2)
        return (predictions,)

model = MockModel()

# LabelWeights: a threshold value used for binary classification
LabelWeights = [0.5]

# TestFeatures: input features for prediction
# Shape (2, 4) - 2 samples, 4 features
TestFeatures = np.random.rand(2, 4).astype(np.float32)

# TestLabels: ground truth labels
# Shape (2, 2) - 2 samples, 2 classes (for binary classification)
TestLabels = np.array([[1, 0], [0, 1]], dtype=np.int32)

# TestAttri: additional attributes (not used in function body but in signature)
TestAttri = np.random.rand(2, 3)

ARGS = {
    "model": model,
    "LabelWeights": LabelWeights,
    "TestFeatures": TestFeatures,
    "TestLabels": TestLabels,
    "TestAttri": TestAttri
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, sklearn, torch — 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
load_data Ran
ran on a synthesized input
taoqi98/fairvfl/CelebA/preprocessing.py
code served (permissive licence) · get_code("37a129fb2fcab303")
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 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 os
import numpy as np
import tempfile
import shutil

# Create a temporary directory with the required files
temp_dir = tempfile.mkdtemp()

# Create a small zipped_images_4.npy file
images_data = np.random.randint(0, 256, size=(2, 4, 4), dtype=np.uint8)
np.save(os.path.join(temp_dir, 'zipped_images_4.npy'), images_data)

# Create attribute.txt file with proper format
attribute_content = """image_id
age gender
1 1 1
2 -1 1
3 1 -1
"""
with open(os.path.join(temp_dir, 'attribute.txt'), 'w') as f:
    f.write(attribute_content)

ARGS = {
    'data_root_path': temp_dir,
    'filename': 'zipped_images_4.npy'
}
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 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
get_behavior_classifier Not yet run
unverified (harvested, no recorded run)
taoqi98/fairvfl/CelebA/models.py
code served (permissive licence) · get_code("3c2a7d667723ed8b")
How it ran

no invocation recorded.

get_contrastive_scorer Not yet run
unverified (harvested, no recorded run)
taoqi98/fairvfl/Adult/models.py
code served (permissive licence) · get_code("183905474d688b9a")
How it ran

no invocation recorded.

get_data_flow Not yet run
unverified (harvested, no recorded run)
taoqi98/fairvfl/CelebA/models.py
code served (permissive licence) · get_code("330bd3d3891e8e89")
How it ran

no invocation recorded.

get_mapper Not yet run
unverified (harvested, no recorded run)
taoqi98/fairvfl/Adult/models.py
code served (permissive licence) · get_code("d393197c1300c3a2")
How it ran

no invocation recorded.

get_mapper_discrimator Not yet run
unverified (harvested, no recorded run)
taoqi98/fairvfl/Adult/models.py
code served (permissive licence) · get_code("b2ea0d61d0a4abc8")
How it ran

no invocation recorded.

get_user_info_classifier Not yet run
unverified (harvested, no recorded run)
taoqi98/fairvfl/CelebA/models.py
code served (permissive licence) · get_code("ad05a74e231521c8")
How it ran

no invocation recorded.

load_data Not yet run
unverified (harvested, no recorded run)
taoqi98/fairvfl/Adult/preprocessing.py
code served (permissive licence) · get_code("579466b24ba469d9")
How it ran

no invocation recorded.

load_data Not yet run
unverified (harvested, no recorded run)
taoqi98/fairvfl/CelebA/raw_data_process.py
code served (permissive licence) · get_code("abbf0d8c243d107c")
How it ran

no invocation recorded.

Also present in other papers' code

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

Vertical federated learning (VFL) is a privacy-preserving machine learning paradigm that can learn models from features distributed on different platforms in a privacy-preserving way. Since in real-world applications the data may contain bias on fairness-sensitive features (e.g., gender), VFL models may inherit bias from training data and become unfair for some user groups. However, existing fair machine learning methods usually rely on the centralized storage of fairness-sensitive features to achieve model fairness, which are usually inapplicable in federated scenarios. In this paper, we propose a fair vertical federated learning framework (FairVFL), which can improve the fairness of VFL models. The core idea of FairVFL is to learn unified and fair representations of samples based on the decentralized feature fields in a privacy-preserving way. Specifically, each platform with fairness-insensitive features first learns local data representations from local features. Then, these local representations are uploaded to a server and aggregated into a unified representation for the target task. In order to learn a fair unified representation, we send it to each platform storing fairness-sensitive features and apply adversarial learning to remove bias from the unified representation inherited from the biased data. Moreover, for protecting user privacy, we further propose a contrastive adversarial learning method to remove private information from the unified representation in server before sending it to the platforms keeping fairness-sensitive features. Experiments on three real-world datasets validate that our method can effectively improve model fairness with user privacy well-protected.

For agents

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

get_harvested_code_for_paper("2206.03200")
get_code_for_paper("2206.03200")
have("2206.03200")

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

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

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

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

Connect an agent — have() is free.