SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2312.02554 · 2023

ULMA: Unified Language Model Alignment with Human Demonstration and Point-wise Preference

arXiv · PDF · Open in the Atlas

Code that ran

2 of 2 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 0 have no contract verdict; 2 failures of our instrument; 0 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/2312.02554.json · badge: /api/ran/2312.02554.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
unified-language-model-alignment/src canonical (classifier label)
classifier basis: census
2 ran · 0 no recorded run
FunctionStatusWhere it lives
get_logger Ran
ran; our contract draft was wrong, not the code
unified-language-model-alignment/src/src/llmtuner/extras/logging.py
code served (permissive licence) · get_code("56faa444d1b260c6")
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 Logger. 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 sys
import logging

# The function get_logger takes a single parameter: name (a string)
# Reading the function body:
# - It creates a formatter with a format string and date format
# - It creates a StreamHandler pointing to sys.stdout
# - It sets the formatter on the handler
# - It gets a logger by name
# - It sets the logger level to INFO
# - It adds the handler to the logger
# - It returns the logger
#
# The only parameter needed is 'name', which should be a string identifier for the logger

ARGS = {
    "name": "test_logger"
}
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 Logger — a Logger output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Logger 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
split_dataset Ran
ran; our contract draft was wrong, not the code
unified-language-model-alignment/src/src/llmtuner/dsets/utils.py
code served (permissive licence) · get_code("fa0e41311e2cae40")
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 torch
import numpy as np
from typing import Dict, List
from unittest.mock import MagicMock

torch.manual_seed(0)

# Create a mock Dataset class that behaves like a HuggingFace Dataset
class MockDataset:
    def __init__(self, size=100):
        self.size = size
        self.data = [{"text": f"sample_{i}"} for i in range(size)]
    
    def train_test_split(self, test_size=0.1, seed=42):
        """Split dataset into train and test sets"""
        if isinstance(test_size, float):
            split_idx = int(len(self.data) * (1 - test_size))
        else:
            split_idx = len(self.data) - test_size
        
        train_data = self.data[:split_idx]
        test_data = self.data[split_idx:]
        
        train_ds = MockDataset(size=0)
        train_ds.data = train_data
        train_ds.size = len(train_data)
        
        test_ds = MockDataset(size=0)
        test_ds.data = test_data
        test_ds.size = len(test_data)
        
        return {'train': train_ds, 'test': test_ds}
    
    def shuffle(self, buffer_size=100, seed=42):
        """Shuffle the dataset"""
        shuffled_ds = MockDataset(size=0)
        shuffled_ds.data = self.data.copy()
        np.random.seed(seed)
        np.random.shuffle(shuffled_ds.data)
        shuffled_ds.size = len(shuffled_ds.data)
        return shuffled_ds
    
    def take(self, n):
        """Take first n elements (for streaming)"""
        taken_ds = MockDataset(size=0)
        taken_ds.data = self.data[:n]
        taken_ds.size = len(taken_ds.data)
        return taken_ds
    
    def skip(self, n):
        """Skip first n elements (for streaming)"""
        skipped_ds = MockDataset(size=0)
        skipped_ds.data = self.data[n:]
        skipped_ds.size = len(skipped_ds.data)
        return skipped_ds

# Create mock DataArguments class
class DataArguments:
    def __init__(self, val_size=0.1, streaming=False, buffer_size=1000):
        self.val_size = val_size
        self.streaming = streaming
        self.buffer_size = buffer_size

# Create mock TrainingArguments class
class TrainingArguments:
    def __init__(self, do_train=True, seed=42):
        self.do_train = do_train
        self.seed = seed

# Create dataset and arguments
dataset = MockDataset(size=100)
data_args = DataArguments(val_size=0.2, streaming=False, buffer_size=1000)
training_args = TrainingArguments(do_train=True, seed=42)

ARGS = {
    'dataset': dataset,
    'data_args': data_args,
    'training_args': training_args
}
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 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

Also present in other papers' code

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

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

FunctionAlso present inEarliest-datedOthers named
get_logger 8 other papers
1 dated earlier, 7 later
2311.13246 (2023-11)
CoachLM: Automatic Instruction Revisions Improve the Data Quality in LLM Instruction Tuning
2403.13786 (2024-03)
Chain-of-Interaction: Enhancing Large Language Models for Psychiatric Behavior Understanding by Dyadic Contexts
2405.19266 (2024-05)
PediatricsGPT: Large Language Models as Chinese Medical Assistants for Pediatric Applications
and 5 more not named here

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

Aligning language models to human expectations, e.g., being helpful and harmless, has become a pressing challenge for large language models. A typical alignment procedure consists of supervised fine-tuning and preference learning. Most preference learning methods, such as RLHF and DPO, depend on pairwise preference data, which inadequately address scenarios where human feedback is point-wise, leading to potential information loss and suboptimal performance. Addressing this gap, we introduce Point-wise Direct Preference Optimization, a novel preference learning method designed to harness point-wise feedback effectively. Our work also uncovers a novel connection between supervised fine-tuning and point-wise preference learning, culminating in Unified Language Model Alignment, a single-step method that unifies the alignment with human demonstrations and point-wise preferences. Extensive experiments on point-wise preference datasets with binary or continuous labels validate the effectiveness of our methods. Our code and a new dataset with high-quality demonstration samples on harmlessness are released.

For agents

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

get_harvested_code_for_paper("2312.02554")
get_code_for_paper("2312.02554")
have("2312.02554")

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

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

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

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

Connect an agent — have() is free.