FAF: A Feature-Adaptive Framework for Few-Shot Time Series Forecasting

P. R. Ouyang, Chen Dong, Tong Yang, Shuo Feng, Jin Zhao, Mingliang XuarXiv 2025 · DOI

Abstract

Multi-task and few-shot time series forecasting tasks are commonly encountered in scenarios such as the launch of new products in different cities. However, traditional time series forecasting methods suffer from insufficient historical data, which stems from a disregard for the generalized and specific features among different tasks. For the aforementioned challenges, we propose the Feature-Adaptive Time Series Forecasting Framework (FAF), which consists of three key components: the Generalized Knowledge Module (GKM), the Task-Specific Module (TSM), and the Rank Module (RM). During training phase, the GKM is updated through a meta-learning mechanism that enables the model to extract generalized features across related tasks. Meanwhile, the TSM is trained to capture diverse local dynamics through multiple functional regions, each of which learns specific features from individual tasks. During testing phase, the RM dynamically selects the most relevant functional region from the TSM based on input sequence features, which is then combined with the generalized knowledge learned by the GKM to generate accurate forecasts. This design enables FAF to achieve robust and personalized forecasting even with sparse historical observations. We evaluate FAF on five diverse real-world datasets under few-shot time series forecasting settings. Experimental results demonstrate that FAF consistently outperforms baselines that include three categories of time series forecasting methods. In particular, FAF achieves a 41.81% improvement over the best baseline, iTransformer, on the CO$_2$ emissions dataset.

1. Introduction

Time series forecasting is a critical component in various domains, ranging from electricity demand prediction to retail sales management. However, deep learning models typically require large volumes of data to perform effectively. In many real-world applications, such as launching a new product or expanding into a new geographic market, practitioners face a "few-shot" scenario where only a limited number of historical observations are available.

Traditional statistical methods like ARIMA or Prophet often struggle with high error rates in these data-scarce environments. Conversely, modern neural networks frequently encounter "feature conflict." This occurs when a model attempts to learn global trends (e.g., seasonal cycles) and local task-specific variations (e.g., unique regional events) simultaneously using the same parameters. These conflicting gradients can lead to poor generalization and overfitting, particularly when data is sparse.

2. Methodology: The Feature-Adaptive Framework

To address these challenges, we propose the Feature-Adaptive Framework (FAF). FAF utilizes a modular architecture to disentangle global patterns from local dynamics, effectively mitigating feature conflict through a "divide and conquer" strategy.

The FAF architecture consists of three specialized modules: the Rank Module (RM), the Generalized Knowledge Module (GKM), and the Task-Specific Module (TSM).

The architecture is composed of three primary components:

  1. Generalized Knowledge Module (GKM): This module serves as the global component of the model. It is trained using a meta-learning mechanism to extract high-level, shared features across all tasks, providing a robust foundation for forecasting in data-scarce scenarios.
  2. Task-Specific Module (TSM): The TSM is partitioned into multiple functional regions. Each region is designed to specialize in specific types of local dynamics. This modularity allows the framework to capture diverse patterns without them interfering with the global signal.
  3. Rank Module (RM): Acting as a dynamic gatekeeper, the RM analyzes the input sequence during inference to identify and weight the most relevant functional regions from the TSM. This enables the model to synthesize a personalized forecast tailored to the specific characteristics of the task at hand.

3. Experimental Setup

We evaluated FAF across five diverse real-world datasets to demonstrate its generalizability:

  • Electricity Load: Monthly consumption data from eight zones.
  • Walmart Sales: Weekly sales from 45 U.S. stores.
  • CO2 Emissions: Daily records from 84 departments across 14 countries.
  • GDP Growth: Annual growth rates from 18 European countries.
  • Temperature Forecasting: Daily readings from eight Indian cities.

To simulate the few-shot challenge, models were provided with only 16 to 24 historical time steps to adapt and predict the subsequent 8 steps.

4. Results and Discussion

FAF was benchmarked against 14 baseline models, including classical deep learning (LSTM, GRU), Transformer-based architectures (Informer, PatchTST, iTransformer), and specialized forecasting models (N-BEATS, TimesNet).

Performance comparison of FAF against standard deep learning baselines across five datasets. FAF consistently achieves the lowest error rates across RMSE, MAE, and MAPE metrics.

Key Findings:

  • Superior Performance: FAF outperformed all baselines on four out of the five datasets. Notably, on the highly variable CO2 emissions dataset, FAF achieved a 41.81% improvement in accuracy over the state-of-the-art iTransformer model.
  • Robustness to Data Scarcity: While Transformer-based models often showed inconsistent performance in few-shot settings, FAF maintained high accuracy and stability.
  • Computational Efficiency: Due to its modular design and sparse activation (activating only a subset of parameters during inference), FAF is significantly more efficient than dense models like N-BEATS or Autoformer.

5. Conclusion

The FAF framework demonstrates that decoupling global trends from local variations is essential for effective few-shot time series forecasting. By using a meta-learning approach for generalized knowledge and a dynamically ranked task-specific module, FAF overcomes the gradient inconsistency problem. Future work will focus on extending this framework to multivariate data and incorporating multi-modal inputs to further enhance the Rank Module's selection process.

Summary updated

BibTeX
@misc{ouyang2025faf,
  author = {P. R. Ouyang and Chen Dong and Tong Yang and Shuo Feng and Jin Zhao and Mingliang Xu},
  title = {{FAF: A Feature-Adaptive Framework for Few-Shot Time Series Forecasting}},
  year = {2025},
  eprint = {2506.19567},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2506.19567},
  howpublished = {arXiv},
}
Figure