StyDeco: Unsupervised Style Transfer with Distilling Priors and Semantic Decoupling [Official Code of PyTorch]
• 2025.08: 🔥 The official code of StyDeco has been released. • 2025.08: 🔥 The paper of StyDeco has been submitted to arXiv.
In this paper, we propose StyDeco, an unsupervised framework that resolves this limitation by learning text representations specifically tailored for the style transfer task. Our framework first employs Prior-Guided Data Distillation (PGD), a strategy designed to distill stylistic knowledge without human supervision. It leverages a powerful frozen generative model to automatically synthesize pseudopaired data. Subsequently, we introduce Contrastive Semantic Decoupling (CSD), a task-specific objective that adapts a text encoder using domain-specific weights. CSD performs a twoclass clustering in the semantic space, encouraging source and target representations to form distinct clusters. The overall framework is illustrated as follows:
git clone https://github.com/QuanjianSong/StyDeco.git
# Installation with the requirement.txt
conda create -n StyDeco python=3.10
conda activate StyDeco
pip install -r requirements.txt
# Or installation with environment.yaml
conda env create -f environment.yaml
bash train_StyDeco.sh
bash start_StyDeco.sh
🤗 If you find this code helpful for your research, please cite:
@article{yang2025stydeco,
title={StyDeco: Unsupervised Style Transfer with Distilling Priors and Semantic Decoupling},
author={Yang, Yuanlin and Song, Quanjian and Gao, Zhexian and Wang, Ge and Li, Shanshan and Zhang, Xiaoyan},
journal={arXiv preprint arXiv:2508.01215},
year={2025}
}