SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2205.03105 · 2022

LPGNet: Link Private Graph Networks for Node Classification

arXiv · PDF · Open in the Atlas

Code that ran

10 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 10 have no contract verdict; 0 failures of our instrument; 2 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/2205.03105.json · badge: /api/ran/2205.03105.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
ashgeek/lpgnet-prototype canonical (classifier label)
classifier basis not recorded on the link
10 ran · 2 no recorded run
FunctionStatusWhere it lives
fix Ran
ran on a synthesized input
ashgeek/lpgnet-prototype/src/run_exp.py
code served (permissive licence) · get_code("71939d0af6f5cfb4")
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 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 io

torch.manual_seed(0)

# The function fix(map_loc) returns a lambda that loads a torch object from bytes
# using torch.load with a specified map_location.
# 
# map_loc is passed directly to torch.load's map_location parameter.
# Common values are 'cpu', torch.device('cpu'), or a dict for device mapping.

# Create a simple map_location argument - 'cpu' is a valid string value
map_loc = 'cpu'

ARGS = {
    'map_loc': map_loc
}
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 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
getCommunityCounts Ran
ran on a synthesized input
ashgeek/lpgnet-prototype/src/graph_utils.py
code served (permissive licence) · get_code("469eb6e4f0820263")
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 numpy as np

# Create a simple RNG object that has the methods used by the function
class SimpleRNG:
    def __init__(self, seed=42):
        self.rng = np.random.RandomState(seed)
    
    def laplace(self, loc, scale):
        return self.rng.laplace(loc, scale)
    
    def choice(self, size, n):
        return self.rng.choice(size, n)

# Create small test data
np.random.seed(0)

# Adjacency matrix: 5 nodes, sparse connectivity
adjacency = np.array([
    [0, 1, 0, 1, 0],
    [1, 0, 1, 0, 0],
    [0, 1, 0, 1, 1],
    [1, 0, 1, 0, 1],
    [0, 0, 1, 1, 0]
], dtype=float)

# Labels: assign nodes to 3 communities
labels = np.array([0, 0, 1, 1, 2])

# RNG instance
rng = SimpleRNG(seed=42)

# Parameters for differential privacy
dp = True
eps = 2.0

ARGS = {
    "adjacency": adjacency,
    "labels": labels,
    "rng": rng,
    "dp": dp,
    "eps": eps
}
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 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
getF1Scores Ran
ran on a synthesized input
ashgeek/lpgnet-prototype/src/parser_ash.py
code served (permissive licence) · get_code("ebbb51daaf6769c3")
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 numpy as np

class MockTrackingObject:
    def __init__(self):
        # f1_scores should be a list/sequence that can be stacked along axis=1
        # The function does np.stack(tobj.f1_scores, axis=1)
        # Then accesses f1_scores[0] which means first row after stacking
        # We need at least 2 arrays to stack meaningfully
        self.f1_scores = [
            np.array([0.85, 0.90, 0.88, 0.92]),
            np.array([0.87, 0.89, 0.86, 0.91])
        ]

ARGS = {
    "tobj": MockTrackingObject()
}
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, 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
getF1Scores Ran
ran on a synthesized input
ashgeek/lpgnet-prototype/src/parser_ash_ind_utility.py
code served (permissive licence) · get_code("9cebd2aa7d189d11")
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 numpy as np

class MockTObj:
    def __init__(self):
        # f1_scores should be a list that can be stacked along axis=1
        # Each element should be array-like with shape that allows stacking
        # After stacking on axis=1, we access f1_scores[0] and compute mean/std
        # So f1_scores after stacking should be 2D, and we index [0] to get first row
        self.f1_scores = [
            np.array([0.85, 0.90, 0.88]),
            np.array([0.82, 0.87, 0.86]),
            np.array([0.88, 0.92, 0.89])
        ]
        self.rare_f1_scores = [
            np.array([0.65, 0.70, 0.68]),
            np.array([0.62, 0.67, 0.66]),
            np.array([0.68, 0.72, 0.69])
        ]

tobj = MockTObj()

ARGS = {
    "tobj": tobj,
    "rare": True
}
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, 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
get_avg_nor_given_labels Ran
ran on a synthesized input
ashgeek/lpgnet-prototype/src/plot_dvs.py
code served (permissive licence) · get_code("86bdd421bc0e192f")
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 torch
import numpy as np

torch.manual_seed(0)

# dvs: a tensor that gets normalized with p=1.0, dim=1
# Should be 2D tensor (batch_size, feature_dim)
dvs = torch.randn(2, 4)

# labels: a list/array of labels corresponding to each sample in dvs
labels = [0, 1]

# act_lables: optional list of active labels (default empty list)
act_lables = [0, 1, 2]

ARGS = {
    "dvs": dvs,
    "labels": labels,
    "act_lables": act_lables
}
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 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
get_comm_edges Ran
ran on a synthesized input
ashgeek/lpgnet-prototype/src/graph_utils.py
code served (permissive licence) · get_code("8888bc5f695d7101")
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 numpy as np

# Set seed for reproducibility
np.random.seed(0)
rng = np.random.RandomState(42)

# Define parameters for get_comm_edges
from_ind = 0
to_ind = 3

# Create a small adjacency matrix (3 rows, representing nodes)
# Each row indicates which other nodes this node is connected to
adjacency = np.array([
    [0, 1, 1, 0],
    [1, 0, 1, 1],
    [0, 1, 0, 1]
], dtype=float)

# Define communities as lists of node indices
# We have 2 communities
comms = [
    [0, 1],      # Community 1: nodes 0 and 1
    [1, 2, 3]    # Community 2: nodes 1, 2, and 3
]

# Differential privacy parameters
dp = True
eps = 1.0

# Arguments dictionary
ARGS = {
    "from_ind": from_ind,
    "to_ind": to_ind,
    "adjacency": adjacency,
    "comms": comms,
    "dp": dp,
    "eps": eps,
    "rng": rng
}
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 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
get_comms_pkl_file_name Ran
ran on a synthesized input
ashgeek/lpgnet-prototype/src/utils.py
code served (permissive licence) · get_code("2b30e2ab1196e9a7")
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 os

class MockDataset:
    def __init__(self, name):
        self.name = name

class MockRunConfig:
    def __init__(self):
        self.learning_rate = 0.001
        self.hidden_size = 64
        self.num_hidden = 2
        self.dropout = 0.5
        self.eps = 1e-8
        self.output_dir = "/tmp/output"

# Create instances
run_config = MockRunConfig()
dataset = MockDataset("cifar10")
test_dataset = MockDataset("cifar10_test")
model_name = "resnet18"
seed = 42

ARGS = {
    "model_name": model_name,
    "dataset": dataset,
    "seed": seed,
    "test_dataset": test_dataset,
    "run_config": run_config
}
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 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
get_folder_name Ran
ran on a synthesized input
ashgeek/lpgnet-prototype/src/utils.py
code served (permissive licence) · get_code("985b7c92a38b2d37")
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 torch.nn as nn

class RunConfig:
    def __init__(self):
        self.learning_rate = 0.001
        self.hidden_size = 64
        self.num_hidden = 2
        self.dropout = 0.5
        self.eps = 1e-8

class Dataset:
    def __init__(self, name):
        self.name = name

run_config = RunConfig()
dataset = Dataset("cifar10")
model_name = "resnet18"
seed = 42
test_dataset = Dataset("cifar10_test")

ARGS = {
    "run_config": run_config,
    "dataset": dataset,
    "model_name": model_name,
    "seed": seed,
    "epoch": 5,
    "test_dataset": test_dataset
}
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 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
get_seeds Ran
ran on a synthesized input
ashgeek/lpgnet-prototype/src/utils.py
code served (permissive licence) · get_code("771d81f8889f1f8e")
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 int, shape (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

ARGS = {
    'num_seeds': 3,
    'sample_seed': 42
}
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 int, shape (3,) — shape (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
read_best_config Ran
ran on a synthesized input
ashgeek/lpgnet-prototype/src/run_exp.py
code served (permissive licence) · get_code("0e7f48db5a4aaedd")
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 os
import pickle as pkl
import tempfile

# Create a temporary directory and file for testing
temp_dir = tempfile.mkdtemp()
out_path = os.path.join(temp_dir, "best_config.pkl")

# Create a sample best_config dictionary
best_config = {
    "learning_rate": 0.001,
    "batch_size": 32,
    "epochs": 10,
    "model_name": "test_model"
}

# Write the config to the pickle file
with open(out_path, 'wb') as f:
    pkl.dump(best_config, f)

ARGS = {
    "out_path": out_path
}
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
getCommunityCountsMP Not yet run
unverified (harvested, no recorded run)
ashgeek/lpgnet-prototype/src/graph_utils.py
code served (permissive licence) · get_code("bcd32869c25acc4a")
How it ran

no invocation recorded.

mapped_loads Not yet run
unverified (harvested, no recorded run)
ashgeek/lpgnet-prototype/src/run_exp.py
code served (permissive licence) · get_code("e9c2207f51abe158")
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, 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

Classification tasks on labeled graph-structured data have many important applications ranging from social recommendation to financial modeling. Deep neural networks are increasingly being used for node classification on graphs, wherein nodes with similar features have to be given the same label. Graph convolutional networks (GCNs) are one such widely studied neural network architecture that perform well on this task. However, powerful link-stealing attacks on GCNs have recently shown that even with black-box access to the trained model, inferring which links (or edges) are present in the training graph is practical. In this paper, we present a new neural network architecture called LPGNet for training on graphs with privacy-sensitive edges. LPGNet provides differential privacy (DP) guarantees for edges using a novel design for how graph edge structure is used during training. We empirically show that LPGNet models often lie in the sweet spot between providing privacy and utility: They can offer better utility than "trivially" private architectures which use no edge information (e.g., vanilla MLPs) and better resilience against existing link-stealing attacks than vanilla GCNs which use the full edge structure. LPGNet also offers consistently better privacy-utility tradeoffs than DPGCN, which is the state-of-the-art mechanism for retrofitting differential privacy into conventional GCNs, in most of our evaluated datasets.

For agents

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

get_harvested_code_for_paper("2205.03105")
get_code_for_paper("2205.03105")
have("2205.03105")

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

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

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

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

Connect an agent — have() is free.