SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2104.09715 · 2021

AdaSpeech 2: Adaptive Text to Speech with Untranscribed Data

arXiv · PDF · Open in the Atlas

Code that ran

4 of 4 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; 1 failure 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/2104.09715.json · badge: /api/ran/2104.09715.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
rishikksh20/AdaSpeech2 community (classifier label)
classifier basis not recorded on the link
3 ran · 0 no recorded run
copy not recorded community
not in the paper's declared repositories
1 ran · 0 no recorded run
FunctionStatusWhere it lives
evaluate Ran
ran on a synthesized input
rishikksh20/AdaSpeech2/evaluation.py
code served (permissive licence) · get_code("644e4bb8a34cbee8")
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. The code mentions cuda, and the harness aliases cuda to the CPU for every sample; whether this run needed that is 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 torch.nn as nn
import numpy as np

torch.manual_seed(0)

class DummyModel(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(4, 4)
    
    def _forward(self, x, ilens, out_length, dur, es, ps, is_inference=False):
        # x: [batch, seq_len, dim]
        # Return: (dummy, after_outs, d_outs, e_outs, p_outs)
        batch_size = x.shape[0]
        max_out_len = out_length.max().item() if out_length.numel() > 0 else 5
        
        after_outs = torch.randn(batch_size, max_out_len, 4)
        d_outs = dur.float()
        e_outs = es.float()
        p_outs = ps.float()
        
        return None, after_outs, d_outs, e_outs, p_outs

class DummyConfig:
    def __init__(self):
        self.data = type('obj', (object,), {
            'wav_dir': '/tmp/wavs/',
            'data_dir': '/tmp/data/'
        })()
        self.audio = type('obj', (object,), {
            'sample_rate': 22050
        })()

# Build a minimal valid batch
# valid = (x_, input_length_, y_, _, out_length_, ids_, dur_, e_, p_)
def create_batch():
    batch_size = 2
    seq_len = 5
    dim = 4
    
    x_ = torch.randn(batch_size, seq_len, dim)
    input_length_ = torch.tensor([seq_len, seq_len], dtype=torch.long)
    y_ = torch.randn(batch_size, seq_len, dim)
    _ = None  # placeholder
    out_length_ = torch.tensor([seq_len, seq_len], dtype=torch.long)
    ids_ = ["id_0", "id_1"]
    dur_ = torch.randn(batch_size, seq_len)
    e_ = torch.randn(batch_size, seq_len)
    p_ = torch.randn(batch_size, seq_len)
    
    return (x_, input_length_, y_, _, out_length_, ids_, dur_, e_, p_)

# Create validloader with 2 batches
validloader = [create_batch(), create_batch()]

# Create model
model = DummyModel()

# Create hyperparameter config
hp = DummyConfig()

ARGS = {
    "hp": hp,
    "validloader": validloader,
    "model": model
}
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
get_std_opt Ran
ran on a synthesized input
rishikksh20/AdaSpeech2/core/optimizer.py
code served (permissive licence) · get_code("09d756d182147053")
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 NoamOpt. 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

torch.manual_seed(0)

# Create a minimal model with parameters that the optimizer can work with
class SimpleModel(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear1 = nn.Linear(4, 3)
        self.linear2 = nn.Linear(3, 2)
    
    def forward(self, x):
        x = self.linear1(x)
        x = self.linear2(x)
        return x

model = SimpleModel()
d_model = 512
warmup = 4000
factor = 1.0

ARGS = {
    'model': model,
    'd_model': d_model,
    'warmup': warmup,
    'factor': factor
}
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 NoamOpt — a NoamOpt output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a NoamOpt 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
process_paragraph Ran
ran; our contract draft was wrong, not the code
this paper's copy was not recorded; identical code first harvested from rishikksh20/LightSpeech
pointer only · get_code("141ed5512c50d7db")
How it ran

The body of this sample is withheld: this paper's copy of the code was not recorded (its link names no repository or source path), so no licence was read for it. 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.

repeat Ran
ran on a synthesized input
rishikksh20/AdaSpeech2/core/modules.py
code served (permissive licence) · get_code("c6691c20de5ab4d1")
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 MultiSequential. 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

torch.manual_seed(0)

class SimpleModule(nn.Module):
    """A simple module that takes multiple inputs and returns them unchanged"""
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(4, 4)
    
    def forward(self, *args):
        # Process each input through the linear layer and return as tuple
        return tuple(self.linear(arg) if isinstance(arg, torch.Tensor) else arg for arg in args)

def module_factory():
    """Factory function to create SimpleModule instances"""
    return SimpleModule()

ARGS = {
    'N': 3,
    'fn': module_factory
}
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 MultiSequential — a MultiSequential output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a MultiSequential output the recorded ndim 1 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 4 samples lifted from this paper's linked repositories, 4 carry a function identity and 0 do not. Of the 4 distinct functions with an identity, 4 are also present in other papers whose code we hold (4 with at least one paper dated earlier, 0 the same month, 0 later) and 0 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_paragraph 3 other papers
3 dated earlier
1905.09263 (2019-05)
FastSpeech: Fast, Robust and Controllable Text to Speech
2006.04558 (2020-06)
FastSpeech 2: Fast and High-Quality End-to-End Text to Speech
2102.04040 (2021-02)
LightSpeech: Lightweight and Fast Text to Speech with Neural Architecture Search
evaluate 1 other paper
1 dated earlier
2006.04558 (2020-06)
FastSpeech 2: Fast and High-Quality End-to-End Text to Speech
get_std_opt 1 other paper
1 dated earlier
2006.04558 (2020-06)
FastSpeech 2: Fast and High-Quality End-to-End Text to Speech
repeat 1 other paper
1 dated earlier
2006.04558 (2020-06)
FastSpeech 2: Fast and High-Quality End-to-End Text to Speech

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

Text to speech (TTS) is widely used to synthesize personal voice for a target speaker, where a well-trained source TTS model is fine-tuned with few paired adaptation data (speech and its transcripts) on this target speaker. However, in many scenarios, only untranscribed speech data is available for adaptation, which brings challenges to the previous TTS adaptation pipelines (e.g., AdaSpeech). In this paper, we develop AdaSpeech 2, an adaptive TTS system that only leverages untranscribed speech data for adaptation. Specifically, we introduce a mel-spectrogram encoder to a well-trained TTS model to conduct speech reconstruction, and at the same time constrain the output sequence of the mel-spectrogram encoder to be close to that of the original phoneme encoder. In adaptation, we use untranscribed speech data for speech reconstruction and only fine-tune the TTS decoder. AdaSpeech 2 has two advantages: 1) Pluggable: our system can be easily applied to existing trained TTS models without re-training. 2) Effective: our system achieves on-par voice quality with the transcribed TTS adaptation (e.g., AdaSpeech) with the same amount of untranscribed data, and achieves better voice quality than previous untranscribed adaptation methods. Synthesized speech samples can be found at https://speechresearch.github.io/adaspeech2/.

For agents

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

get_harvested_code_for_paper("2104.09715")
get_code_for_paper("2104.09715")
have("2104.09715")

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

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

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

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

Connect an agent — have() is free.