SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2505.05678 · 2025

InstanceGen: Image Generation with Instance-level Instructions

arXiv · PDF · Open in the Atlas

Code that ran

6 of 8 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 5 have no contract verdict; 1 failure of our instrument; 2 no recorded run), measured 2026-11-24; 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/2505.05678.json · badge: /api/ran/2505.05678.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
tsunghan-wu/SLD canonical (classifier label)
classifier basis not recorded on the link
6 ran · 2 no recorded run
FunctionStatusWhere it lives
check_same_object Ran
ran on a synthesized input
tsunghan-wu/SLD/sld/detector.py
code served (permissive licence) · get_code("84fea2eda72c2b31")
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 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

# Analyzing the function:
# - box1: tuple/list of 4 numeric values (x1, y1, w1, h1)
# - box2: tuple/list of 4 numeric values (x2, y2, w2, h2)
# - iou_threshold: float, default 0.9

# The function unpacks box1 and box2 into 4 components each
# and performs arithmetic operations (max, min, multiplication, division)
# All operations are on numeric types

# Create two bounding boxes with distinct values for clarity
box1 = (10, 20, 30, 40)  # x1, y1, w1, h1
box2 = (25, 35, 25, 35)  # x2, y2, w2, h2 - overlapping with box1

# Using default iou_threshold of 0.9
iou_threshold = 0.9

ARGS = {
    "box1": box1,
    "box2": box2,
    "iou_threshold": iou_threshold,
}
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 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
convert_box Ran
ran on a synthesized input
tsunghan-wu/SLD/sld/image_generator.py
code served (permissive licence) · get_code("91d7a81383cf3ed3")
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 int; 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

torch.manual_seed(0)

# The function convert_box takes a box parameter that is indexed with [0], [1], [2], [3]
# It performs arithmetic operations on these elements
# box should be a sequence (list, tuple, or tensor) with at least 4 elements

# Create a simple box representation: [x_min, y_min, width, height]
box = [10, 20, 30, 40]

ARGS = {
    "box": box
}
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 tuple, ndim 1, dtype family int — 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
pop_entry_via_box Ran
ran on a synthesized input
tsunghan-wu/SLD/sld/detector.py
code served (permissive licence) · get_code("fa504d3999b40860")
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 torch

torch.manual_seed(0)

# Create a sample bbox entry: (identifier, box_coordinates)
# box_coordinates format: (x, y, width, height)
bbox = (0, (10, 20, 30, 40))

# Create a detection list with multiple entries
# Each entry is (identifier, box_coordinates)
det_list = [
    (0, (10, 20, 30, 40)),  # This matches bbox exactly
    (1, (100, 100, 50, 50)),
    (2, (200, 200, 60, 60)),
]

ARGS = {
    "bbox": bbox,
    "det_list": det_list,
}
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 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
pop_entry_via_name Ran
ran on a synthesized input
tsunghan-wu/SLD/sld/detector.py
code served (permissive licence) · get_code("2eff55cf5ebd8ff3")
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

# Understanding the function:
# - obj_name: a string to search for
# - det_list: a list of tuples/objects where the first element (obj[0]) is compared with obj_name
# The function searches through det_list, finds an entry where obj[0] == obj_name,
# pops it from the list, and returns it. Returns None if not found.

# Create a simple det_list with tuples where first element is a name
det_list = [
    ("apple", 10, "fruit"),
    ("banana", 20, "fruit"),
    ("carrot", 15, "vegetable"),
    ("date", 5, "fruit"),
]

obj_name = "banana"

ARGS = {
    "obj_name": obj_name,
    "det_list": det_list,
}
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 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
process_input_embeddings Ran
ran; our contract draft was wrong, not the code
tsunghan-wu/SLD/models/models.py
pointer only (licence: MIT); the stored copy get_code serves, from ayanban011/svgcraft, is pointer only (licence: NONE) · get_code("2f1664cb838533c9")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from ayanban011/svgcraft, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

run_sam_postprocess Ran
ran on a synthesized input
tsunghan-wu/SLD/sld/utils.py
code served (permissive licence) · get_code("5a6df84d20852c60")
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 2, dtype family int, shape (16, 12) 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 cv2
import numpy as np

class ConfigStandIn:
    def __init__(self):
        self.data = {
            'SLD': {
                'SAM_refine_dilate': '3'
            }
        }
    
    def get(self, section, key):
        return self.data[section][key]

# Create a small 3-channel mask with values in range [0, 1]
remove_mask = np.random.rand(16, 16, 3).astype(np.float32)

H = 128
W = 96
config = ConfigStandIn()

ARGS = {
    'remove_mask': remove_mask,
    'H': H,
    'W': W,
    'config': config
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
cv2, numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 2, dtype family int, shape (16, 12) — shape (16, 12) 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
get_key_objects Not yet run
unverified (harvested, no recorded run)
tsunghan-wu/SLD/sld/llm_chat.py
code served (permissive licence) · get_code("d362597d148ddba7")
How it ran

no invocation recorded.

get_updated_layout Not yet run
unverified (harvested, no recorded run)
tsunghan-wu/SLD/sld/llm_chat.py
code served (permissive licence) · get_code("ba998aaa812d32a0")
How it ran

no invocation recorded.

Also present in other papers' code

Of 8 samples lifted from this paper's linked repositories, 8 carry a function identity and 0 do not. Of the 8 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, 0 later) and 7 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
process_input_embeddings 2 other papers
2 dated earlier
2310.10640 (2023-10)
LLM Blueprint: Enabling Text-to-Image Generation with Complex and Detailed Prompts
2404.00412 (2024-04)
CraftSVG: Multi-Object Text-to-SVG Synthesis via Layout Guided Diffusion

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-24.

Repositories linked to this paper

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

Abstract

Despite rapid advancements in the capabilities of generative models, pretrained text-to-image models still struggle in capturing the semantics conveyed by complex prompts that compound multiple objects and instance-level attributes. Consequently, we are witnessing growing interests in integrating additional structural constraints, typically in the form of coarse bounding boxes, to better guide the generation process in such challenging cases. In this work, we take the idea of structural guidance a step further by making the observation that contemporary image generation models can directly provide a plausible fine-grained structural initialization. We propose a technique that couples this image-based structural guidance with LLM-based instance-level instructions, yielding output images that adhere to all parts of the text prompt, including object counts, instance-level attributes, and spatial relations between instances.

For agents

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

get_harvested_code_for_paper("2505.05678")
get_code_for_paper("2505.05678")
have("2505.05678")

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

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

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

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

Connect an agent — have() is free.