SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1907.10902 · Knowledge Discovery and Data Mining · 2019

Optuna: A Next-generation Hyperparameter Optimization Framework

Masanori Koyama, Takuya Akiba, Shotaro Sano, Toshihiko Yanase, Takeru Ohta

arXiv · PDF · Open in the Atlas

Code that ran

14 of 20 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 13 have no contract verdict; 1 failure of our instrument; 6 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/1907.10902.json · badge: /api/ran/1907.10902.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
optuna/optuna canonical (classifier label)
classifier basis: census
3 ran · 1 no recorded run
crcrpar/benchmark-runner-ci community (classifier label)
classifier basis not recorded on the link
4 ran · 1 no recorded run
yqian4/optuna community (classifier label)
classifier basis not recorded on the link
3 ran · 1 no recorded run
rickyHong/optuna-repl community (classifier label)
classifier basis not recorded on the link
2 ran · 2 no recorded run
himkt/optuna-test-rtds community (classifier label)
classifier basis not recorded on the link
1 ran · 1 no recorded run
crcrpar/ci-example-execution community (classifier label)
classifier basis not recorded on the link
1 ran · 0 no recorded run
FunctionStatusWhere it lives
deprecated Ran
ran on a synthesized input
crcrpar/benchmark-runner-ci/optuna/_deprecated.py
code served (permissive licence) · get_code("e0f487fc31fe6108")
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 warnings

ARGS = {
    "deprecated_version": "1.5.0",
    "removed_version": "3.0.0",
    "name": "test_deprecated_function",
    "text": "Please use the new_function instead for improved performance."
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
optuna, packaging — 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
deprecated Ran
ran on a synthesized input
himkt/optuna-test-rtds/optuna/_deprecated.py
code served (permissive licence) · get_code("a4522433f0feab75")
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 functools
import inspect
import textwrap
from typing import Any
from typing import Callable
from typing import Optional
import warnings
from packaging import version

# Setup for the deprecated decorator function
ARGS = {
    "deprecated_version": "1.5.0",
    "removed_version": "3.0.0",
    "name": "my_deprecated_feature",
    "text": "This feature has been replaced by a newer API. Please use the new function instead."
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
optuna, packaging — 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
deprecated_class Ran
ran on a synthesized input
optuna/optuna/optuna/_deprecated.py
code served (permissive licence) · get_code("60cf3f75bd76f271")
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 functools
import textwrap
from typing import Any
import warnings
from packaging import version

# Mock the optuna._experimental module functions
class MockExperimental:
    @staticmethod
    def _get_docstring_indent(doc: str) -> str:
        """Extract indentation from docstring."""
        if doc is None:
            return ''
        lines = doc.split('\n')
        for line in lines[1:]:
            if line.strip():
                return line[:len(line) - len(line.lstrip())]
        return ''
    
    @staticmethod
    def _validate_version(ver: str) -> None:
        """Validate version string format."""
        try:
            version.parse(ver)
        except Exception:
            raise ValueError(f"Invalid version: {ver}")

# Inject mocks
import sys
import types
optuna_module = types.ModuleType('optuna')
optuna_experimental = types.ModuleType('optuna._experimental')
optuna_experimental._get_docstring_indent = MockExperimental._get_docstring_indent
optuna_experimental._validate_version = MockExperimental._validate_version
optuna_module._experimental = optuna_experimental
sys.modules['optuna'] = optuna_module
sys.modules['optuna._experimental'] = optuna_experimental

# Now create a simple test class to decorate
class SimpleTestClass:
    """This is a simple test class."""
    def __init__(self, value: int = 42):
        self.value = value

ARGS = {
    'deprecated_version': '1.0.0',
    'removed_version': '2.0.0',
    'name': 'SimpleTestClass',
    'text': 'Use NewClass instead.'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
optuna, packaging — 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
deprecated_func Ran
ran on a synthesized input
optuna/optuna/optuna/_deprecated.py
code served (permissive licence) · get_code("68cb51930216821b")
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 functools
import textwrap
from typing import Any, Callable
import warnings
from packaging import version


def _validate_version(ver: str) -> None:
    """Mock validator for version strings."""
    try:
        version.parse(ver)
    except Exception:
        raise ValueError(f"Invalid version: {ver}")


def _get_docstring_indent(docstring: str) -> str:
    """Mock function to get docstring indent."""
    if not docstring:
        return ""
    lines = docstring.split('\n')
    for line in lines[1:]:
        if line.strip():
            return ' ' * (len(line) - len(line.lstrip()))
    return ""


# Create a simple test function to decorate
def sample_deprecated_function(x: int, y: str = "default") -> str:
    """This is a sample function.
    
    Args:
        x: An integer parameter.
        y: A string parameter.
    
    Returns:
        A concatenated string.
    """
    return f"{x}_{y}"


ARGS = {
    "deprecated_version": "1.0.0",
    "removed_version": "2.0.0",
    "name": "sample_deprecated_function",
    "text": "Please use new_function instead."
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
optuna, packaging — 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
distribution_to_json Ran
ran on a synthesized input
optuna/optuna/optuna/distributions.py
code served (permissive licence) · get_code("300c3cdb36c77934")
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 abc
import json
from typing import Any

class BaseDistribution(abc.ABC):
    """Base class for distributions.

    Note that distribution classes are not supposed to be called by library users.
    They are used by :class:`~optuna.trial.Trial` and :class:`~optuna.samplers` internally.
    """

    def to_external_repr(self, param_value_in_internal_repr: float) -> Any:
        """Convert internal representation of a parameter value into external representation.

        Args:
            param_value_in_internal_repr:
                Optuna's internal representation of a parameter value.

        Returns:
            Optuna's external representation of a parameter value.
        """
        return param_value_in_internal_repr

    @abc.abstractmethod
    def to_internal_repr(self, param_value_in_external_repr: Any) -> float:
        """Convert external representation of a parameter value into internal representation.

        Args:
            param_value_in_external_repr:
                Optuna's external representation of a parameter value.

        Returns:
            Optuna's internal representation of a parameter value.
        """
        raise NotImplementedError

    @abc.abstractmethod
    def single(self) -> bool:
        """Test whether the range of this distribution contains just a single value.

        Returns:
            :obj:`True` if the range of this distribution contains just a single value,
            otherwise :obj:`False`.
        """
        raise NotImplementedError

    @abc.abstractmethod
    def _contains(self, param_value_in_internal_repr: float) -> bool:
        """Test if a parameter value is contained in the range of this distribution.

        Args:
            param_value_in_internal_repr:
                Optuna's internal representation of a parameter value.

        Returns:
            :obj:`True` if the parameter value is contained in the range of this distribution,
            otherwise :obj:`False`.
        """
        raise NotImplementedError

    def _asdict(self) -> dict:
        return self.__dict__

    def __eq__(self, other: Any) -> bool:
        if not isinstance(other, BaseDistribution):
            return NotImplemented
        if type(self) is not type(other):
            return False
        return self.__dict__ == other.__dict__

    def __hash__(self) -> int:
        return hash((self.__class__,) + tuple(sorted(self.__dict__.items())))

    def __repr__(self) -> str:
        kwargs = ', '.join((f'{k}={v}' for k, v in sorted(self._asdict().items())))
        return f'{self.__class__.__name__}({kwargs})'

def distribution_to_json(dist: BaseDistribution) -> str:
    """Serialize a distribution to JSON format.

    Args:
        dist: A distribution to be serialized.

    Returns:
        A JSON string of a given distribution.

    """
    return json.dumps({'name': dist.__class__.__name__, 'attributes': dist._asdict()})


class ConcreteDistribution(BaseDistribution):
    """Concrete implementation of BaseDistribution for testing."""
    
    def __init__(self, low: float = 0.0, high: float = 1.0):
        self.low = low
        self.high = high
    
    def to_internal_repr(self, param_value_in_external_repr: Any) -> float:
        return float(param_value_in_external_repr)
    
    def single(self) -> bool:
        return self.low == self.high
    
    def _contains(self, param_value_in_internal_repr: float) -> bool:
        return self.low <= param_value_in_internal_repr <= self.high


test_dist = ConcreteDistribution(low=0.0, high=10.0)

ARGS = {
    'dist': test_dist
}
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
distribution_to_json Ran
ran on a synthesized input
crcrpar/benchmark-runner-ci/optuna/distributions.py
code served (permissive licence) · get_code("66869b51e32b5239")
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 abc
import json
from typing import Any, Dict


class BaseDistribution(object, metaclass=abc.ABCMeta):
    """Base class for distributions."""

    def to_external_repr(self, param_value_in_internal_repr: float) -> Any:
        return param_value_in_internal_repr

    def to_internal_repr(self, param_value_in_external_repr: Any) -> float:
        return param_value_in_external_repr

    @abc.abstractmethod
    def single(self) -> bool:
        raise NotImplementedError

    @abc.abstractmethod
    def _contains(self, param_value_in_internal_repr: float) -> bool:
        raise NotImplementedError

    def _asdict(self) -> Dict:
        return self.__dict__

    def __eq__(self, other: Any) -> bool:
        if not isinstance(other, BaseDistribution):
            return NotImplemented
        if not type(self) is type(other):
            return False
        return self.__dict__ == other.__dict__

    def __hash__(self) -> int:
        return hash((self.__class__,) + tuple(sorted(self.__dict__.items())))

    def __repr__(self) -> str:
        kwargs = ', '.join(('{}={}'.format(k, v) for k, v in sorted(self.__dict__.items())))
        return '{}({})'.format(self.__class__.__name__, kwargs)


class ConcreteDistribution(BaseDistribution):
    """Concrete implementation of BaseDistribution for testing."""
    
    def __init__(self, low: float = 0.0, high: float = 1.0):
        self.low = low
        self.high = high
    
    def single(self) -> bool:
        return self.low == self.high
    
    def _contains(self, param_value_in_internal_repr: float) -> bool:
        return self.low <= param_value_in_internal_repr <= self.high


def distribution_to_json(dist: BaseDistribution) -> str:
    """Serialize a distribution to JSON format."""
    return json.dumps({'name': dist.__class__.__name__, 'attributes': dist._asdict()})


# Create a concrete distribution instance
test_dist = ConcreteDistribution(low=0.5, high=9.5)

ARGS = {
    'dist': test_dist
}
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
distribution_to_json Ran
ran on a synthesized input
rickyHong/optuna-repl/optuna/distributions.py
code served (permissive licence) · get_code("fb81f851b70620a5")
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 json
from collections import namedtuple

# Create a simple namedtuple-based distribution class
# that has __class__.__name__ and _asdict() method
Distribution = namedtuple('Distribution', ['mean', 'std', 'shape'])

# Create an instance of the distribution
dist = Distribution(mean=0.0, std=1.0, shape=(2, 4))

ARGS = {
    'dist': dist
}
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
experimental Ran
ran on a synthesized input
crcrpar/benchmark-runner-ci/optuna/_experimental.py
code served (permissive licence) · get_code("dd56e0858ebc9987")
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 warnings
import inspect
from typing import Optional, Any

# Test with a simple function
def sample_function():
    """Sample experimental function."""
    return "result"

# Test with a simple class
class SampleClass:
    """Sample experimental class."""
    def __init__(self):
        pass

ARGS = {
    "version": "1.0.0",
    "name": "test_feature"
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
optuna — 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
experimental Ran
ran on a synthesized input
yqian4/optuna/optuna/_experimental.py
code served (permissive licence) · get_code("e50db8e806388c8f")
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 warnings
import inspect
from typing import Any, Callable

# Mock ExperimentalWarning if needed
class ExperimentalWarning(UserWarning):
    pass

# Test function to decorate
def sample_function(x: int, y: str = "default") -> str:
    """A sample function for testing."""
    return f"{x}_{y}"

# Test class to decorate
class SampleClass:
    """A sample class for testing."""
    def __init__(self, value: int, name: str = "test"):
        self.value = value
        self.name = name

ARGS = {
    "version": "1.0.0",
    "name": "TestFeature"
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
optuna — 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_logger Ran
ran on a synthesized input
rickyHong/optuna-repl/optuna/logging.py
code served (permissive licence) · get_code("16d3274a2492ce12")
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 colorlog
import logging
import threading

_lock = threading.Lock()

_default_handler = None

def create_default_formatter():
    """Create a default formatter of log messages.

    This function is not supposed to be directly accessed by library users.
    """
    return colorlog.ColoredFormatter('%(log_color)s[%(levelname)1.1s %(asctime)s]%(reset)s %(message)s')

def _get_library_name():
    return __name__.split('.')[0]

def _get_library_root_logger():
    return logging.getLogger(_get_library_name())

def _configure_library_root_logger():
    global _default_handler
    with _lock:
        if _default_handler:
            return
        _default_handler = logging.StreamHandler()
        _default_handler.setFormatter(create_default_formatter())
        library_root_logger = _get_library_root_logger()
        library_root_logger.addHandler(_default_handler)
        library_root_logger.setLevel(logging.INFO)
        library_root_logger.propagate = False

def get_logger(name):
    """Return a logger with the specified name.

    This function is not supposed to be directly accessed by library users.
    """
    _configure_library_root_logger()
    return logging.getLogger(name)


ARGS = {
    "name": "my_test_logger"
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
colorlog — 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
get_logger Ran
ran; our contract draft was wrong, not the code
yqian4/optuna/optuna/logging.py
code served (permissive licence) · get_code("2949bcda1225868b")
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 logging
import threading
import colorlog

_lock = threading.Lock()
_default_handler = None

def create_default_formatter() -> colorlog.ColoredFormatter:
    """Create a default formatter of log messages.

    This function is not supposed to be directly accessed by library users.
    """
    return colorlog.ColoredFormatter('%(log_color)s[%(levelname)1.1s %(asctime)s]%(reset)s %(message)s')

def _get_library_name() -> str:
    return __name__.split('.')[0]

def _get_library_root_logger() -> logging.Logger:
    return logging.getLogger(_get_library_name())

def _configure_library_root_logger() -> None:
    global _default_handler
    with _lock:
        if _default_handler:
            return
        _default_handler = logging.StreamHandler()
        _default_handler.setFormatter(create_default_formatter())
        library_root_logger = _get_library_root_logger()
        library_root_logger.addHandler(_default_handler)
        library_root_logger.setLevel(logging.INFO)
        library_root_logger.propagate = False

def get_logger(name: str) -> logging.Logger:
    """Return a logger with the specified name.

    This function is not supposed to be directly accessed by library users.
    """
    _configure_library_root_logger()
    return logging.getLogger(name)

ARGS = {
    "name": "test_logger"
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
colorlog — 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
json_to_distribution Ran
ran on a synthesized input
crcrpar/benchmark-runner-ci/optuna/distributions.py
code served (permissive licence) · get_code("b62334a22f7ed6be")
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 UniformDistribution. 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
import json
from decimal import Decimal

# First, let me examine the function signature by looking at the code provided.
# The code shows BaseDistribution and its subclasses (UniformDistribution, LogUniformDistribution)
# But the function we need to construct arguments for is `json_to_distribution`
# Since the full function isn't shown, I'll infer from the context that it likely takes
# a JSON string or dict and converts it to a distribution object.

# Based on typical Optuna patterns, json_to_distribution likely has signature:
# def json_to_distribution(json_str: str) -> BaseDistribution

# Let me create valid test arguments for such a function

ARGS = {
    'json_str': json.dumps({
        'name': 'UniformDistribution',
        'attributes': {
            'low': 0.0,
            'high': 10.0
        }
    })
}
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 UniformDistribution — a UniformDistribution output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a UniformDistribution 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
json_to_distribution Ran
ran on a synthesized input
crcrpar/ci-example-execution/optuna/distributions.py
code served (permissive licence) · get_code("6ce00ad175b2cf6c")
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 UniformDistribution. 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 json
from decimal import Decimal

# The function signature appears to be json_to_distribution based on the context
# Looking at the classes defined, we need to construct test arguments

def json_to_distribution(json_str: str):
    """Mock function signature - converts JSON string to distribution object"""
    pass

# Construct valid JSON strings representing different distribution types
uniform_json = json.dumps({
    'name': 'UniformDistribution',
    'attributes': {
        'low': 1.0,
        'high': 10.0
    }
})

log_uniform_json = json.dumps({
    'name': 'LogUniformDistribution',
    'attributes': {
        'low': 0.1,
        'high': 100.0
    }
})

ARGS = {
    'json_str': uniform_json
}
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 UniformDistribution — a UniformDistribution output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a UniformDistribution 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
json_to_distribution Ran
ran on a synthesized input
yqian4/optuna/optuna/distributions.py
code served (permissive licence) · get_code("8b51061ba35119e6")
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 UniformDistribution. 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 json

# Based on the provided code, we need to construct arguments for json_to_distribution
# However, the function signature is not shown in the provided code snippet.
# Looking at the classes defined (BaseDistribution, UniformDistribution, 
# LogUniformDistribution, DiscreteUniformDistribution), this appears to be
# from optuna's distribution module.

# The most likely function signature based on context is:
# json_to_distribution(json_str) -> BaseDistribution
# which converts a JSON string representation back to a distribution object

# Let's create valid JSON representations of distributions
uniform_json = json.dumps({
    "name": "UniformDistribution",
    "attributes": {
        "low": 0.0,
        "high": 1.0
    }
})

log_uniform_json = json.dumps({
    "name": "LogUniformDistribution", 
    "attributes": {
        "low": 0.1,
        "high": 10.0
    }
})

discrete_uniform_json = json.dumps({
    "name": "DiscreteUniformDistribution",
    "attributes": {
        "low": 1,
        "high": 10,
        "q": 1
    }
})

# The ARGS dict for a json_to_distribution function
ARGS = {
    "json_str": uniform_json
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
optuna — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type UniformDistribution — a UniformDistribution output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a UniformDistribution 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_all_study_summaries Not yet run
unverified (harvested, no recorded run)
rickyHong/optuna-repl/optuna/study.py
code served (permissive licence) · get_code("e8026cbbd4877929")
How it ran

no invocation recorded.

get_all_study_summaries Not yet run
unverified (harvested, no recorded run)
yqian4/optuna/optuna/study.py
code served (permissive licence) · get_code("27ed2fee554587a5")
How it ran

no invocation recorded.

get_logger Not yet run
unverified (harvested, no recorded run)
optuna/optuna/optuna/logging.py
code served (permissive licence) · get_code("532d732793640190")
How it ran

no invocation recorded.

get_logger Not yet run
unverified (harvested, no recorded run)
crcrpar/benchmark-runner-ci/optuna/logging.py
code served (permissive licence) · get_code("81f35f190d0b3aff")
How it ran

no invocation recorded.

json_to_distribution Not yet run
unverified (harvested, no recorded run)
himkt/optuna-test-rtds/optuna/distributions.py
code served (permissive licence) · get_code("229382f84fdfc44b")
How it ran

no invocation recorded.

json_to_distribution Not yet run
unverified (harvested, no recorded run)
rickyHong/optuna-repl/optuna/distributions.py
code served (permissive licence) · get_code("79f8dae8e1591e73")
How it ran

no invocation recorded.

Also present in other papers' code

Of 20 samples lifted from this paper's linked repositories, 20 carry a function identity and 0 do not. Of the 13 distinct functions with an identity, 1 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 1 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.

FunctionAlso present inEarliest-datedOthers named
get_logger 1 other paper
1 later
2412.09805 (2024-12)
Making Classic GNNs Strong Baselines Across Varying Homophily: A Smoothness-Generalization Perspective

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

The purpose of this study is to introduce new design-criteria for next-generation hyperparameter optimization software. The criteria we propose include (1) define-by-run API that allows users to construct the parameter search space dynamically, (2) efficient implementation of both searching and pruning strategies, and (3) easy-to-setup, versatile architecture that can be deployed for various purposes, ranging from scalable distributed computing to light-weight experiment conducted via interactive interface. In order to prove our point, we will introduce Optuna, an optimization software which is a culmination of our effort in the development of a next generation optimization software. As an optimization software designed with define-by-run principle, Optuna is particularly the first of its kind. We will present the design-techniques that became necessary in the development of the software that meets the above criteria, and demonstrate the power of our new design through experimental results and real world applications. Our software is available under the MIT license (https://github.com/pfnet/optuna/).

For agents

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

get_harvested_code_for_paper("1907.10902")
get_code_for_paper("1907.10902")
have("1907.10902")

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

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

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

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

Connect an agent — have() is free.