# Enhancing Cross-Sectional Currency Strategies by Context-Aware Learning to Rank with Self-Attention

arXiv: https://arxiv.org/abs/2105.10019 · HTML: https://mlsanity.com/paper/2105.10019/

## Key facts

- Cited by 5 papers in the map (data through 14 Oct 2026).
- Builds on 11 of its 62 references that are in the map.
- First posted on arXiv 20 May 2021.

## Builds on (most cited first, 11 of 11)

- [Attention Is All You Need](https://mlsanity.com/paper/1706.03762/) (2017)
- [XGBoost: A Scalable Tree Boosting System](https://mlsanity.com/paper/1603.02754/) (2016)
- [Neural Machine Translation by Jointly Learning to Align and Translate](https://mlsanity.com/paper/1409.0473/) (2014)
- [Effective Approaches to Attention-based Neural Machine Translation](https://mlsanity.com/paper/1508.04025/) (2015)
- [Learning a Deep Listwise Context Model for Ranking Refinement](https://mlsanity.com/paper/1804.05936/) (2018)
- [Seq2Slate: Re-ranking and Slate Optimization with RNNs](https://mlsanity.com/paper/1810.02019/) (2018)
- [On Application of Learning to Rank for E-Commerce Search](https://mlsanity.com/paper/1903.04263/) (2019)
- [Learning Groupwise Multivariate Scoring Functions Using Deep Neural Networks](https://mlsanity.com/paper/1811.04415/) (2018)
- [Context-Aware Learning to Rank with Self-Attention](https://mlsanity.com/paper/2005.10084/) (2020)
- [Globally Optimized Mutual Influence Aware Ranking in E-Commerce Search](https://mlsanity.com/paper/1805.08524/) (2018)
- [Building Cross-Sectional Systematic Strategies By Learning to Rank](https://mlsanity.com/paper/2012.07149/) (2020)

## Built on by (most cited first, 5 of 5)

- [Spatio-Temporal Momentum: Jointly Learning Time-Series and Cross-Sectional Strategies](https://mlsanity.com/paper/2302.10175/) (2023)
- [Deep Learning for Options Trading: An End-To-End Approach](https://mlsanity.com/paper/2407.21791/) (2024)
- [Transfer Ranking in Finance: Applications to Cross-Sectional Momentum with Data Scarcity](https://mlsanity.com/paper/2208.09968/) (2022)
- [The cross-sectional stock return predictions via quantum neural network and tensor network](https://mlsanity.com/paper/2304.12501/) (2023)
- [Sequential asset ranking in nonstationary time series](https://mlsanity.com/paper/2202.12186/) (2022)

## Abstract (arXiv)

The performance of a cross-sectional currency strategy depends crucially on accurately ranking instruments prior to portfolio construction. While this ranking step is traditionally performed using heuristics, or by sorting the outputs produced by pointwise regression or classification techniques, strategies using Learning to Rank algorithms have recently presented themselves as competitive and viable alternatives. Although the rankers at the core of these strategies are learned globally and improve ranking accuracy on average, they ignore the differences between the distributions of asset features over the times when the portfolio is rebalanced. This flaw renders them susceptible to producing sub-optimal rankings, possibly at important periods when accuracy is actually needed the most. For example, this might happen during critical risk-off episodes, which consequently exposes the portfolio to substantial, unwanted drawdowns. We tackle this shortcoming with an analogous idea from information retrieval: that a query's top retrieved documents or the local ranking context provide vital information about the query's own characteristics, which can then be used to refine the initial ranked list. In this work, we use a context-aware Learning-to-rank model that is based on the Transformer architecture to encode top/bottom ranked assets, learn the context and exploit this information to re-rank the initial results. Backtesting on a slate of 31 currencies, our proposed methodology increases the Sharpe ratio by around 30% and significantly enhances various performance metrics. Additionally, this approach also improves the Sharpe ratio when separately conditioning on normal and risk-off market states.
