https://arxiv.org/api/90tNAQ2TcYXCPYoew1oGtmDeOFI 2026-06-20T22:14:10Z 2263 615 15 http://arxiv.org/abs/2403.12285v1 FinLlama: Financial Sentiment Classification for Algorithmic Trading Applications 2024-03-18T22:11:00Z There are multiple sources of financial news online which influence market movements and trader's decisions. This highlights the need for accurate sentiment analysis, in addition to having appropriate algorithmic trading techniques, to arrive at better informed trading decisions. Standard lexicon based sentiment approaches have demonstrated their power in aiding financial decisions. However, they are known to suffer from issues related to context sensitivity and word ordering. Large Language Models (LLMs) can also be used in this context, but they are not finance-specific and tend to require significant computational resources. To facilitate a finance specific LLM framework, we introduce a novel approach based on the Llama 2 7B foundational model, in order to benefit from its generative nature and comprehensive language manipulation. This is achieved by fine-tuning the Llama2 7B model on a small portion of supervised financial sentiment analysis data, so as to jointly handle the complexities of financial lexicon and context, and further equipping it with a neural network based decision mechanism. Such a generator-classifier scheme, referred to as FinLlama, is trained not only to classify the sentiment valence but also quantify its strength, thus offering traders a nuanced insight into financial news articles. Complementing this, the implementation of parameter-efficient fine-tuning through LoRA optimises trainable parameters, thus minimising computational and memory requirements, without sacrificing accuracy. Simulation results demonstrate the ability of the proposed FinLlama to provide a framework for enhanced portfolio management decisions and increased market returns. These results underpin the ability of FinLlama to construct high-return portfolios which exhibit enhanced resilience, even during volatile periods and unpredictable market events. 2024-03-18T22:11:00Z Thanos Konstantinidis Giorgos Iacovides Mingxue Xu Tony G. Constantinides Danilo Mandic http://arxiv.org/abs/2306.17742v4 Blockchain scaling and liquidity concentration on decentralized exchanges 2024-03-18T19:47:09Z Liquidity providers (LPs) on decentralized exchanges (DEXs) can protect themselves from adverse selection risk by updating their positions more frequently. However, repositioning is costly, because LPs have to pay gas fees for each update. We analyze the causal relation between repositioning and liquidity concentration around the market price, using the entry of blockchain scaling solutions, Arbitrum and Polygon, as our instruments. Lower gas fees on scaling solutions allow LPs to update more frequently than on Ethereum. Our results demonstrate that higher repositioning intensity and precision lead to greater liquidity concentration, which benefits small trades by reducing their slippage. 2023-06-30T15:43:03Z Basile Caparros Amit Chaudhary Olga Klein http://arxiv.org/abs/2403.09494v2 Layer 2 be or Layer not 2 be: Scaling on Uniswap v3 2024-03-15T02:31:52Z This paper studies the market structure impact of cheaper and faster chains on the Uniswap v3 Protocol. The Uniswap Protocol is the largest decentralized application on Ethereum by both gas and blockspace used, and user behaviors of the protocol are very sensitive to fluctuations in gas prices and market structure due to the economic factors of the Protocol. We focus on the chains where Uniswap v3 has the most activity, giving us the best comparison to Ethereum mainnet. Because of cheaper gas and lower block times, we find evidence that the majority of swaps get better gas-adjusted execution on these chains, liquidity providers are more capital efficient, and liquidity providers have increased fee returns from more arbitrage. We also present evidence that two second block times may be too long for optimal liquidity provider returns, compared to first come, first served. We argue that many of the current drawbacks with AMMs may be due to chain dynamics and are vastly improved with cheaper and faster transactions 2024-03-14T15:35:30Z Austin Adams http://arxiv.org/abs/2209.10334v2 Trade Co-occurrence, Trade Flow Decomposition, and Conditional Order Imbalance in Equity Markets 2024-03-13T20:37:09Z The time proximity of high-frequency trades can contain a salient signal. In this paper, we propose a method to classify every trade, based on its proximity with other trades in the market within a short period of time, into five types. By means of a suitably defined normalized order imbalance associated to each type of trade, which we denote as conditional order imbalance (COI), we investigate the price impact of the decomposed trade flows. Our empirical findings indicate strong positive correlations between contemporaneous returns and COIs. In terms of predictability, we document that associations with future returns are positive for COIs of trades which are isolated from trades of stocks other than themselves, and negative otherwise. Furthermore, trading strategies which we develop using COIs achieve conspicuous returns and Sharpe ratios, in an extensive experimental setup on a universe of 457 stocks using daily data for a period of four years. 2022-09-21T13:06:25Z Yutong Lu Gesine Reinert Mihai Cucuringu http://arxiv.org/abs/2403.08202v1 Trading Large Orders in the Presence of Multiple High-Frequency Anticipatory Traders 2024-03-13T02:55:10Z We investigate a market with a normal-speed informed trader (IT) who may employ mixed strategy and multiple anticipatory high-frequency traders (HFTs) who are under different inventory pressures, in a three-period Kyle's model. The pure- and mixed-strategy equilibria are considered and the results provide recommendations for IT's randomization strategy with different numbers of HFTs. Some surprising results about investors' profits arise: the improvement of anticipatory traders' speed or a more precise prediction may harm themselves but help IT. 2024-03-13T02:55:10Z Ziyi Xu Xue Cheng http://arxiv.org/abs/2210.08569v2 Limited or Biased: Modeling Sub-Rational Human Investors in Financial Markets 2024-03-08T21:31:36Z Human decision-making in real-life deviates significantly from the optimal decisions made by fully rational agents, primarily due to computational limitations or psychological biases. While existing studies in behavioral finance have discovered various aspects of human sub-rationality, there lacks a comprehensive framework to transfer these findings into an adaptive human model applicable across diverse financial market scenarios. In this study, we introduce a flexible model that incorporates five different aspects of human sub-rationality using reinforcement learning. Our model is trained using a high-fidelity multi-agent market simulator, which overcomes limitations associated with the scarcity of labeled data of individual investors. We evaluate the behavior of sub-rational human investors using hand-crafted market scenarios and SHAP value analysis, showing that our model accurately reproduces the observations in the previous studies and reveals insights of the driving factors of human behavior. Finally, we explore the impact of sub-rationality on the investor's Profit and Loss (PnL) and market quality. Our experiments reveal that bounded-rational and prospect-biased human behaviors improve liquidity but diminish price efficiency, whereas human behavior influenced by myopia, optimism, and pessimism reduces market liquidity. 2022-10-16T15:50:26Z Penghang Liu Kshama Dwarakanath Svitlana S Vyetrenko Tucker Balch http://arxiv.org/abs/2210.10971v3 Optimal Settings for Cryptocurrency Trading Pairs 2024-03-06T02:15:24Z The goal of cryptocurrencies is decentralization. In principle, all currencies have equal status. Unlike traditional stock markets, there is no default currency of denomination (fiat), thus the trading pairs can be set freely. However, it is impractical to set up a trading market between every two currencies. In order to control management costs and ensure sufficient liquidity, we must give priority to covering those large-volume trading pairs and ensure that all coins are reachable. We note that this is an optimization problem. Its particularity lies in: 1) the trading volume between most (>99.5%) possible trading pairs cannot be directly observed. 2) It satisfies the connectivity constraint, that is, all currencies are guaranteed to be tradable. To solve this problem, we use a two-stage process: 1) Fill in missing values based on a regularized, truncated eigenvalue decomposition, where the regularization term is used to control what extent missing values should be limited to zero. 2) Search for the optimal trading pairs, based on a branch and bound process, with heuristic search and pruning strategies. The experimental results show that: 1) If the number of denominated coins is not limited, we will get a more decentralized trading pair settings, which advocates the establishment of trading pairs directly between large currency pairs. 2) There is a certain room for optimization in all exchanges. The setting of inappropriate trading pairs is mainly caused by subjectively setting small coins to quote, or failing to track emerging big coins in time. 3) Too few trading pairs will lead to low coverage; too many trading pairs will need to be adjusted with markets frequently. Exchanges should consider striking an appropriate balance between them. 2022-10-20T02:37:01Z Di Zhang Youzhou Zhou http://arxiv.org/abs/2402.19399v3 An Empirical Analysis of Scam Tokens on Ethereum Blockchain 2024-03-05T23:47:21Z This article presents an empirical investigation into the determinants of total revenue generated by counterfeit tokens on Uniswap. It offers a detailed overview of the counterfeit token fraud process, along with a systematic summary of characteristics associated with such fraudulent activities observed in Uniswap. The study primarily examines the relationship between revenue from counterfeit token scams and their defining characteristics, and analyzes the influence of market economic factors such as return on market capitalization and price return on Ethereum. Key findings include a significant increase in overall transactions of counterfeit tokens on their first day of fraud, and a rise in upfront fraud costs leading to corresponding increases in revenue. Furthermore, a negative correlation is identified between the total revenue of counterfeit tokens and the volatility of Ethereum market capitalization return, while price return volatility on Ethereum is found to have a positive impact on counterfeit token revenue, albeit requiring further investigation for a comprehensive understanding. Additionally, the number of subscribers for the real token correlates positively with the realized volume of scam tokens, indicating that a larger community following the legitimate token may inadvertently contribute to the visibility and success of counterfeit tokens. Conversely, the number of Telegram subscribers exhibits a negative impact on the realized volume of scam tokens, suggesting that a higher level of scrutiny or awareness within Telegram communities may act as a deterrent to fraudulent activities. Finally, the timing of when the scam token is introduced on the Ethereum blockchain may have a negative impact on its success. Notably, the cumulative amount scammed by only 42 counterfeit tokens amounted to almost 11214 Ether. 2024-02-29T17:57:05Z Vahidin Jeleskovic http://arxiv.org/abs/2402.17359v2 Limit Order Book Simulations: A Review 2024-03-01T14:10:28Z Limit Order Books (LOBs) serve as a mechanism for buyers and sellers to interact with each other in the financial markets. Modelling and simulating LOBs is quite often necessary for calibrating and fine-tuning the automated trading strategies developed in algorithmic trading research. The recent AI revolution and availability of faster and cheaper compute power has enabled the modelling and simulations to grow richer and even use modern AI techniques. In this review we examine the various kinds of LOB simulation models present in the current state of the art. We provide a classification of the models on the basis of their methodology and provide an aggregate view of the popular stylized facts used in the literature to test the models. We additionally provide a focused study of price impact's presence in the models since it is one of the more crucial phenomena to model in algorithmic trading. Finally, we conduct a comparative analysis of various qualities of fits of these models and how they perform when tested against empirical data. 2024-02-27T09:53:07Z To be submitted to Quantitative Finance Konark Jain Nick Firoozye Jonathan Kochems Philip Treleaven http://arxiv.org/abs/2311.04727v2 Forecasting Volatility with Machine Learning and Rough Volatility: Example from the Crypto-Winter 2024-02-27T14:14:46Z We extend the application and test the performance of a recently introduced volatility prediction framework encompassing LSTM and rough volatility. Our asset class of interest is cryptocurrencies, at the beginning of the "crypto-winter" in 2022. We first show that to forecast volatility, a universal LSTM approach trained on a pool of assets outperforms traditional models. We then consider a parsimonious parametric model based on rough volatility and Zumbach effect. We obtain similar prediction performances with only five parameters whose values are non-asset-dependent. Our findings provide further evidence on the universality of the mechanisms underlying the volatility formation process. 2023-11-08T14:53:05Z Siu Hin Tang Mathieu Rosenbaum Chao Zhou http://arxiv.org/abs/2402.17194v1 The Random Forest Model for Analyzing and Forecasting the US Stock Market in the Context of Smart Finance 2024-02-27T04:18:56Z The stock market is a crucial component of the financial market, playing a vital role in wealth accumulation for investors, financing costs for listed companies, and the stable development of the national macroeconomy. Significant fluctuations in the stock market can damage the interests of stock investors and cause an imbalance in the industrial structure, which can interfere with the macro level development of the national economy. The prediction of stock price trends is a popular research topic in academia. Predicting the three trends of stock pricesrising, sideways, and falling can assist investors in making informed decisions about buying, holding, or selling stocks. Establishing an effective forecasting model for predicting these trends is of substantial practical importance. This paper evaluates the predictive performance of random forest models combined with artificial intelligence on a test set of four stocks using optimal parameters. The evaluation considers both predictive accuracy and time efficiency. 2024-02-27T04:18:56Z 10 pages, 8 figures Jiajian Zheng Duan Xin Qishuo Cheng Miao Tian Le Yang http://arxiv.org/abs/2203.03179v4 Detecting data-driven robust statistical arbitrage strategies with deep neural networks 2024-02-26T13:08:03Z We present an approach, based on deep neural networks, that allows identifying robust statistical arbitrage strategies in financial markets. Robust statistical arbitrage strategies refer to trading strategies that enable profitable trading under model ambiguity. The presented novel methodology allows to consider a large amount of underlying securities simultaneously and does not depend on the identification of cointegrated pairs of assets, hence it is applicable on high-dimensional financial markets or in markets where classical pairs trading approaches fail. Moreover, we provide a method to build an ambiguity set of admissible probability measures that can be derived from observed market data. Thus, the approach can be considered as being model-free and entirely data-driven. We showcase the applicability of our method by providing empirical investigations with highly profitable trading performances even in 50 dimensions, during financial crises, and when the cointegration relationship between asset pairs stops to persist. 2022-03-07T07:23:18Z Ariel Neufeld Julian Sester Daiying Yin http://arxiv.org/abs/2304.13985v3 The Effects of High-frequency Anticipatory Trading: Small Informed Trader vs. Round-Tripper 2024-02-26T06:12:34Z In an extended Kyle's model, the interactions between a large informed trader and a high-frequency trader (HFT) who can anticipate the former's incoming order are studied. We find that, in equilibrium, HFT may play the role of Small-IT or Round-Tripper: both of them trade in the same direction as IT in advance, but when IT's order arrives, Small-IT continues to take liquidity away, while Round-Tripper supplies liquidity back. So Small-IT always harms IT, while Round-Tripper may benefit her. What's more, with an anticipatory HFT, normal-speed small uninformed traders suffer less and price discovery is accelerated. 2023-04-27T07:20:15Z Ziyi Xu Xue Cheng http://arxiv.org/abs/2403.18839v1 Long Short-Term Memory Pattern Recognition in Currency Trading 2024-02-23T12:59:49Z This study delves into the analysis of financial markets through the lens of Wyckoff Phases, a framework devised by Richard D. Wyckoff in the early 20th century. Focusing on the accumulation pattern within the Wyckoff framework, the research explores the phases of trading range and secondary test, elucidating their significance in understanding market dynamics and identifying potential trading opportunities. By dissecting the intricacies of these phases, the study sheds light on the creation of liquidity through market structure, offering insights into how traders can leverage this knowledge to anticipate price movements and make informed decisions. The effective detection and analysis of Wyckoff patterns necessitate robust computational models capable of processing complex market data, with spatial data best analyzed using Convolutional Neural Networks (CNNs) and temporal data through Long Short-Term Memory (LSTM) models. The creation of training data involves the generation of swing points, representing significant market movements, and filler points, introducing noise and enhancing model generalization. Activation functions, such as the sigmoid function, play a crucial role in determining the output behavior of neural network models. The results of the study demonstrate the remarkable efficacy of deep learning models in detecting Wyckoff patterns within financial data, underscoring their potential for enhancing pattern recognition and analysis in financial markets. In conclusion, the study highlights the transformative potential of AI-driven approaches in financial analysis and trading strategies, with the integration of AI technologies shaping the future of trading and investment practices. 2024-02-23T12:59:49Z 10 Pages, 8 Figures, 4 Listings Jai Pal http://arxiv.org/abs/2402.12049v2 Reinforcement Learning for Optimal Execution when Liquidity is Time-Varying 2024-02-20T16:06:56Z Optimal execution is an important problem faced by any trader. Most solutions are based on the assumption of constant market impact, while liquidity is known to be dynamic. Moreover, models with time-varying liquidity typically assume that it is observable, despite the fact that, in reality, it is latent and hard to measure in real time. In this paper we show that the use of Double Deep Q-learning, a form of Reinforcement Learning based on neural networks, is able to learn optimal trading policies when liquidity is time-varying. Specifically, we consider an Almgren-Chriss framework with temporary and permanent impact parameters following several deterministic and stochastic dynamics. Using extensive numerical experiments, we show that the trained algorithm learns the optimal policy when the analytical solution is available, and overcomes benchmarks and approximated solutions when the solution is not available. 2024-02-19T11:06:36Z Andrea Macrì Fabrizio Lillo