Papers › Diffusion Variational Autoencoder for Tackling Stochasticity in Multi-Step Regression...

Diffusion Variational Autoencoder for Tackling Stochasticity in Multi-Step Regression Stock Price Prediction

18 Aug 2023arXiv:2309.00073archive 2025-07-28

Kelvin J. L. Koa, Yunshan Ma, Ritchie Ng, Tat-Seng Chua

Multi-step stock price prediction over a long-term horizon is crucial for forecasting its volatility, allowing financial institutions to price and hedge derivatives, and banks to quantify the risk in their trading books. Additionally, most financial regulators also require a liquidity horizon of several days for institutional investors to exit their risky assets, in order to not materially affect market prices. However, the task of multi-step stock price prediction is challenging, given the highly stochastic nature of stock data. Current solutions to tackle this problem are mostly designed for single-step, classification-based predictions, and are limited to low representation expressiveness. The problem also gets progressively harder with the introduction of the target price sequence, which also contains stochastic noise and reduces generalizability at test-time. To tackle these issues, we combine a deep hierarchical variational-autoencoder (VAE) and diffusion probabilistic techniques to do seq2seq stock prediction through a stochastic generative process. The hierarchical VAE allows us to learn the complex and low-level latent variables for stock prediction, while the diffusion probabilistic model trains the predictor to handle stock price stochasticity by progressively adding random noise to the stock data. Our Diffusion-VAE (D-Va) model is shown to outperform state-of-the-art solutions in terms of its prediction accuracy and variance. More importantly, the multi-step outputs can also allow us to form a stock portfolio over the prediction length. We demonstrate the effectiveness of our model outputs in the portfolio investment task through the Sharpe ratio metric and highlight the importance of dealing with different types of prediction uncertainties.

PaperPDFCodeCode Syntology ran

In Syntology View this paper on Syntology, its page in Syntology's graph. That page adds which of its functions are also present in other papers' code Syntology holds, with dates, and its dated run record as JSON and a README badge. It also lists the repositories linked to the paper, the abstract and the calls for agents.

Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, on Syntology's MCP service (how to connect):

Code

Syntology 14 code samples harvested from 1 repository linked to this paper: 11 ran (of which 0 constructed an object rather than computing a result; 9 with no instrument failure: 2 honoured, 0 violated, 7 with no contract checked; 2 where Syntology's instrument failed) · 3 unverified. Where Syntology's instrument failed: 2 where our contract draft was wrong; failures of Syntology's instrument, not of the code.

By repository: official repository: 14 samples from 1 repository, 11 ran (9 with no instrument failure; 2 where Syntology's instrument failed). The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

Levels written between 2026-09-22 and 2026-09-24 (UTC): the dates Syntology's graph wrote each sample's verification level, not when the code executed.

koa-fin/dva officialmentioned in papermentioned on GitHubpytorchAGPL-3.0Syntology: 14 samples, 11 ran (2 instrument-failed) · 3 unverified report

Repository list and official/mentioned flags are the archive's, frozen 2025-07-28. Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

14 samples harvested: 11 ran (of which 0 constructed an object rather than computing a result; 9 with no instrument failure: 2 honoured, 0 violated, 7 with no contract checked; 2 where Syntology's instrument failed) · 3 unverified. “Where Syntology's instrument failed” counts failures of Syntology's instrument, not of the code. Syntology's record for this page has not changed since , the first build that kept a record date for it; when this build read Syntology's graph is in the build record. That date is not when the samples ran.

2ran · honoured contract
2ran · our draft was wrong
7ran
3unverified

Licence: 14 of the 14 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from koa-fin/dva. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. A line beginning “fixture:” under a sample that ran gives the arguments Syntology's fixture called the sample with, each as name:type/rank/element kind (? where none was recorded), and the type of what the fixture's run returned, exactly as the harness recorded them; the arguments and the returned type were recorded by two separate runs of the same fixture. No output value is shown, and a returned type says nothing about whether the output was right. “Level recorded” gives the UTC date when Syntology's graph wrote the sample's verification level, not when the code executed; where the level was written before Syntology's graph kept that date, the row says “level recorded, date not recorded”. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself. “Our draft was wrong” and “the contract check could not run” are failures of Syntology's instrument, not of the code: the sample ran on Syntology's synthesized input, and then the drafted contract did not describe it, or the check itself raised an error (RAISES), lacked a dependency (DEP_MISSING) or ran out of time (TIMEOUT); hover the label for which. A metamorphic tier, where shown, is evidence of the output's shape, not that the sample implements the method.

Each sample ends with its code_sha256. A sample's code_sha256 is Syntology's identity for that exact code. It is printed in full (16 hexadecimal characters for every sample in this build), and get_code(code_sha256="…") takes it exactly as printed. An agent calls it on Syntology's MCP service (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted. community: Not in the archive's code links for this paper; a community repository Syntology harvested. Samples are grouped by repository: a repository marked official first, then by how directly the repository is tied to the paper, then in the archive's order; never by how many ran. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of six reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar); this paper's copy was not located, so its licence is not recorded; or this paper's copy is cleared, but the stored copy of the same code that Syntology serves is not. Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

A function or class name links to its page when the name occurs in the harvested code of at least 5 papers; the name is a string, not an identity. A census tag appears when Syntology's census ran implementations with that name on one shared input per bucket: it gives how many were compared, from how many papers, and how many distinct outputs they produced, and names this sample's bucket when this sample was one of them.

koa-fin/dva official repository 14 samples, 11 ran (2 instrument-failed) · 3 unverified
default in 430 papers model/diffusion_process.py ran · our draft was wrong AGPL-3.0 (copyleft) · pointer only · b5c54401114d79c1 · report fixture: signature val:str/0/str, d:callable/0/? · returned str · level recorded 2026-09-22
get_arch_cells model/utils.py ran AGPL-3.0 (copyleft) · pointer only · ab2297e25cf27ba8 · report fixture: signature arch_type:str/0/str · returned dict · level recorded 2026-09-24
get_beta_schedule in 66 papers model/diffusion_process.py ran AGPL-3.0 (copyleft) · pointer only · 156c6ba7d6075f3b · report fixture: signature beta_schedule:str/0/str, beta_start:float/0/float, beta_end:float/0/float, num_diffusion_timesteps:int/0/int · returned ndarray · level recorded 2026-09-24
get_input_size in 5 papers model/utils.py ran · honoured contract AGPL-3.0 (copyleft) · pointer only · 4ca5ffe947c454b7 · report fixture: signature dataset:str/0/str · returned int · level recorded 2026-09-22
get_skip_connection model/neural_operations.py ran AGPL-3.0 (copyleft) · pointer only · 45b830116529bb03 · report fixture: signature C:int/0/int, stride:int/0/int, channel_mult:int/0/int · returned FactorizedReduce · level recorded 2026-09-24
get_stride_for_cell_type model/utils.py ran · honoured contract AGPL-3.0 (copyleft) · pointer only · 417c413f2e89d954 · report fixture: signature cell_type:str/0/str · returned int · level recorded 2026-09-22
log_density_gaussian model/encoder.py ran fingerprinted AGPL-3.0 (copyleft) · pointer only · de784879435cc93a · report fixture: signature sample:Tensor/4/float, mu:Tensor/4/float, logvar:Tensor/4/float · returned Tensor · level recorded 2026-09-24
logit in 16 papers model/neural_operations.py ran fingerprinted AGPL-3.0 (copyleft) · pointer only · d42ce56b29f68801 · report fixture: signature t:Tensor/2/float · returned Tensor · level recorded 2026-09-24
norm in 120 papers
census: 23 implementations from 26 papers, 15 distinct outputs across 6 buckets, one shared input per bucket this sample: bucket 1 of 6, arg 1: rank 2, kind float, dtype float32
model/neural_operations.py ran · our draft was wrong fingerprinted AGPL-3.0 (copyleft) · pointer only · e68ef3509ca0d2e9 · report fixture: signature t:Tensor/2/float, dim:int/0/int · returned Tensor · level recorded 2026-09-22
sample_normal_jit model/encoder.py ran fingerprinted AGPL-3.0 (copyleft) · pointer only · 8591e611b706abfe · report fixture: signature mu:Tensor/2/float, sigma:Tensor/2/float · returned tuple · level recorded 2026-09-24
soft_clamp5 in 6 papers model/encoder.py ran fingerprinted AGPL-3.0 (copyleft) · pointer only · 3c16c6b9b824b331 · report fixture: signature x:Tensor/2/float · returned Tensor · level recorded 2026-09-24
time_features in 21 papers utils/timefeatures.py unverified AGPL-3.0 (copyleft) · pointer only · d98f6c6564c7c4e1 · report
time_features_from_frequency_str in 20 papers utils/timefeatures.py unverified AGPL-3.0 (copyleft) · pointer only · f8544563682146e5 · report

Tasks

PredictionStock PredictionStock Price Predictionregression

Results from the paper archive 2025-07-28

No leaderboard rows for this paper in the archive.

Methods

DiffusionHierarchical VAELSTMSeq2SeqSigmoid ActivationTanh Activation

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections