About a-team Marketing Services
The knowledge platform for the financial technology industry
The knowledge platform for the financial technology industry

A-Team Insight Blogs

How Should Stock Analysts Use Prompts for ChatGPT?

Subscribe to our newsletter

Daniel Philps, Head of Rothko Investment Strategies and Co-Leader of Machine Learning at the Gillmore Centre for Financial Technology at Warwick Business School.

2023, termed Generative AI’s ‘breakout year,’ has seen generative AI techniques continually advancing, researchers are exploring new applications and pushing the boundaries of what can be generated.

The latest annual McKinsey Global Survey shows that less than a year after these tools debuted, one-third of organisations are using AI regularly in at least one business function.

We have now reached a point where large language models (LLMs) such as ChatGPT can be used to assist with investment management and finance industry tasks. Although we haven’t reached a point of automation yet, for many tasks that is coming, and in the meantime LLMs have become an invaluable tool in a stock analyst’s repertoire.

How can the research-driven fundamental analysts and tech-savvy quant analysts effectively utilise LLMs like ChatGPT? Can these technologies serve as adept co-pilots or assistants?

The key lies mainly in the practice of ‘prompt engineering’. To make the most of ChatGPT and similar LLMs, equity analysts must concentrate on crafting well-structured prompts; in fact, prompt engineering has emerged as a crucial discipline.

The quality of the question posed to ChatGPT directly influences the quality of its response. The system performs optimally when presented with keywords, phrases, bullet points, task trees, and well-sequenced follow-up inquiries.

Utilising ChatGPT as a quant analyst

As for the technical and quantitative aspect, ChatGPT can be employed to generate basic code snippets and provide explanations of complex code. Notably, GPT codex, a GPT-3 trained on programming code, already serves as a beneficial code completion tool in AI programmer GitHub Copilot and has now been absorbed into GPT-4, while GPT-4 is set to form the foundation of the more comprehensive GitHub Copilot X.

However, unless the code required is fairly standardised, code produced by ChatGPT often necessitates adjustments and refinements for accuracy and optimisation. As such, it is most effective as a template. Presently, it seems improbable that LLM autopilots will replace quantitative coders in the near future. However, they will be able to significantly boost their productivity, accuracy and code quality.

For instance, quant analysts can make use of ChatGPT for the following three tasks, by prompting ChatGPT. In practice, the approach would involve accessing specialised codex LLMs and integrating additional tools to prompt for highly reliable code semi-automatically.

Developing an entire investment pipeline:

ChatGPT can execute complex programming instructions to some extent, such as generating Python functions for driving quantitative equity investment strategies.

However, significant editing and refining of the generated code is usually required. The challenge lies in getting code from ChatGPT that closely resembles the final product. This can be achieved by providing a bulletised list of instructions with crucial details for each item.

Creating a machine-learning alpha-forecasting function:

By posing follow-up questions, we can obtain a basic machine-learning function or template for predicting stock returns.

ChatGPT performs reasonably well in this context, delivering a function that can be adjusted, along with guidance on its application, including a recommendation for cross-validation using a random forest algorithm.

Crafting a useful function: target shuffling:

Subsequently, we tasked ChatGPT with generating a helpful and moderately complex function for conducting target shuffling—a technique to validate outcomes of an investment model.

A simple request for “Python code for a target shuffling function” yielded limited results. Once again, providing a comprehensive list of requirements was necessary for ChatGPT to produce a viable template.

The road ahead

With carefully managed prompts, LLMs can now help fundamental analysts quickly acquire basic knowledge about many companies at once and help quant analysts to develop and debug code.

While the examples above are simply ChatGPT prompts, developers and managers with class-leading technology are already working to apply LLMs to investment management workflows.

Even in their current form, effectively integrated LLMs can yield significant efficiencies if applied in the correct way. They also provide a glimpse into the immense capabilities of this technology.

In its next generation, LLM technology will evolve into an essential tool for investment management. Through automating tasks like information acquisition, human analysts will be afforded additional time and cognitive resources to concentrate on the critical aspects of reasoning and decision-making within the investment workflow.

Subscribe to our newsletter

Related content

WEBINAR

Recorded Webinar: Unlock the Future of European Equities & Trading Technology: 2024 and Beyond!

In a world where the financial landscape is perpetually evolving, 2023 has brought widespread discussions around liquidity, regulatory shifts in the EU and UK, and advancements like the consolidated tape in Europe. For the year ahead in 2024, the European market is poised for transformative changes that will influence the future of trading technology and...

BLOG

Xceptor and Delta Capita Unite to Streamline T+1 Settlement

Data automation platform provider Xceptor has announced a partnership with Delta Capita, a global provider of managed services, technology solutions, and consulting to the financial services industry, aimed at helping financial institutions prepare for the T+1 settlement deadline of 28th May 2024. The partnership, which will leverage Xceptor’s data automation platform and Delta Capita’s expertise,...

EVENT

AI in Capital Markets Summit London

The AI in Capital Markets Summit will explore current and emerging trends in AI, the potential of Generative AI and LLMs and how AI can be applied for efficiencies and business value across a number of use cases, in the front and back office of financial institutions. The agenda will explore the risks and challenges of adopting AI and the foundational technologies and data management capabilities that underpin successful deployment.

GUIDE

Regulatory Data Handbook 2022/2023 – Tenth Edition

Welcome to the tenth edition of A-Team Group’s Regulatory Data Handbook, a publication that has tracked new regulations, amendments, implementation and data management requirements as regulatory change has impacted global capital markets participants over the past 10 years. This edition of the handbook includes new regulations and highlights some of the major regulatory interventions challenging...