No Result
View All Result
  • Login
Monday, September 15, 2025
FeeOnlyNews.com
  • Home
  • Business
  • Financial Planning
  • Personal Finance
  • Investing
  • Money
  • Economy
  • Markets
  • Stocks
  • Trading
  • Home
  • Business
  • Financial Planning
  • Personal Finance
  • Investing
  • Money
  • Economy
  • Markets
  • Stocks
  • Trading
No Result
View All Result
FeeOnlyNews.com
No Result
View All Result
Home Investing

ChatGPT and Large Language Models: Syntax and Semantics

by FeeOnlyNews.com
2 years ago
in Investing
Reading Time: 7 mins read
A A
0
ChatGPT and Large Language Models: Syntax and Semantics
Share on FacebookShare on TwitterShare on LInkedIn


For more on artificial intelligence (AI) in investment management, check out The Handbook of Artificial Intelligence and Big Data Applications in Investments, by Larry Cao, CFA, from the CFA Institute Research Foundation.

A New Frontier for Finance?

The banking and finance sectors have been among the early adopters of artificial intelligence (AI) and machine learning (ML) technology. These innovations have given us the ability to develop alternative, challenger models and improve existing models and analytics quickly and efficiently across a diverse range of functional areas, from credit and market risk management, know your customer (KYC), anti-money laundering (AML), and fraud detection to portfolio management, portfolio construction, and beyond.

ML has automated much of the model-development process while compressing and streamlining the model development cycle. Moreover, ML-driven models have performed as well as, if not better than, their traditional counterparts.

Today, ChatGPT and large language models (LLMs) more generally represent the next evolution in AI/ML technology. And that comes with a number of implications.

The finance sector’s interest in LLMs is no surprise given their vast power and broad applicability. ChatGPT can seemingly “comprehend” human language and provide coherent responses to queries on just about any topic. 

Its use cases are practically limitless. A risk analyst or bank loan officer can have it assess a borrower’s risk score and make a recommendation on a loan application. A senior risk manager or executive can use it to summarize a bank’s current capital and liquidity positions to address investor or regulatory concerns. A research and quant developer can direct it to develop a Python code that estimates the parameters of a model using a certain optimization function. A compliance or legal officer may have it review a law, regulation, or contract to determine whether it is applicable. 

But there are real limitations and hazards associated with LLMs. Early enthusiasm and rapid adoption notwithstanding, experts have sounded various alarms. Apple, Amazon, Accenture, JPMorgan Chase, and Deutsche Bank, among other companies, have banned ChatGPT in the workplace, and some local school districts have forbidden its use in the classroom, citing the attendant risks and potential for abuse. But before we can figure out how to address such concerns, we first need to understand how these technologies work in the first place.

ChatGPT and LLMs: How Do They Work?

To be sure, the precise technical details of the ChatGPT neural network and training thereof are beyond the scope of this article and, indeed, my own comprehension. Nevertheless, certain things are clear: LLMs do not understand words or sentences in the way that we humans do. For us humans, words fit together in two distinct ways.

Syntax

On one level, we examine a series of words for its syntax, attempting to understand it based on the rules of construction applicable to a particular language. After all, language is more than jumbles of words. There are definite, unambiguous grammatical rules about how words fit together to convey their meaning.

LLMs can guess the syntactic structure of a language by the regularities and patterns they recognize from all the text in their training data. It is akin to a native English speaker who may never have studied formal English in school but who knows what kinds of words are likely to follow in a series given the context and their own past experiences, even if their grasp of grammar may be far from perfect. LLMs are similar. Since they lack an algorithmic understanding of the syntactic rules, they may miss some formally correct grammatical cases, but they will have no problems communicating.

Graphic for Handbook of AI and Big data Applications in Investments

Semantics

“An evil fish orbits electronic games joyfully.”

Syntax provides one layer of constraint on language, but semantics provides an even more complex, deeper constraint. Not only do words have to fit together according to the rules of syntax, but they also have to make sense. And to make sense, they must communicate meaning. The sentence above is grammatically and syntactically sound, but if we process the words as they are defined, it is gibberish.

Semantics assumes a model of the world where logic, natural laws, and human perceptions and empirical observations play a significant role. Humans have an almost innate knowledge of this model — so innate that we just call it “common sense” — and apply it unconsciously in our everyday speech. Could ChatGPT-3, with its 175 billion parameters and 60 billion to 80 billion neurons, as compared with the human brain’s roughly 100 billion neurons and 100 trillion synaptic connections, have implicitly discovered the “Model of Language” or somehow deciphered the law of semantics by which humans create meaningful sentences? Not quite.

ChatGPT is a giant statistical engine trained on human text. There is no formal generalized semantic logic or computational framework driving it. Therefore, ChatGPT cannot always make sense. It is simply producing what “sounds right” based on what it “sounds like” according to its training data. It is pulling out coherent threads of texts from the statistical conventional wisdom accumulated in its neural net.

Data Science Certificate Tile

Key to ChatGPT: Embedding and Attention

ChatGPT is a neural network; it processes numbers not words. It transforms words or fragments of words, about 50,000 in total, into numerical values called “tokens” and embeds them into their meaning space, essentially clusters of words, to show relationships among the words. What follows is a simple visualization of embedding in three dimensions.

Three-Dimensional ChatGPT Meaning Space

Visualization of Three-Dimensional ChatGPT Meaning Space

Of course, words have many different contextual meanings and associations. In ChatGPT-3, what we see in the three dimensions above is a vector in the 12,228 dimensions required to capture all the complex nuances of words and their relationships with one another.

Besides the embedded vectors, the attention heads are also critical features in ChatGPT. If the embedding vector gives meaning to the word, the attention heads allow ChatGPT to string together words and continue the text in a reasonable way. The attention heads each examine the blocks of sequences of embedded vectors written so far. For each block of the embedded vectors, it reweighs or “transforms” them into a new vector that is then passed through the fully connected neural net layer. It does this continuously through the entire sequences of texts as new texts are added.

The attention head transformation is a way of looking back at the sequences of words thus far. It is repackaging the past string of texts so that ChatGPT can anticipate what new text might be added. It is a way for the ChatGPT to know, for instance, that a verb and adjective that have appeared or will appear after a sequence modifies the noun from a few words back. 

The best thing about ChatGPT is its ability to _________

Most ProbableNext WordProbabilitylearn4.5%predict3.5%make3.2%understand3.1%do2.9%
Source: “What Is ChatGPT Doing . . . and Why Does It Work?” Stephen Wolfram, Stephen Wolfram Writings

Once the original collection of embedded vectors has gone through the attention blocks, ChatGPT picks up the last of the collection of transformations and decodes it to produce a list of probabilities of what token should come next. Once a token is chosen in the sequence of texts, the entire process repeats.

So, ChatGPT has discovered some semblance of structure in human language, albeit in a statistical way. Is it algorithmically replicating systematic human language? Not at all. Still, the results are astounding and remarkably human-like, and make one wonder if it is possible to algorithmically replicate the systematic structure of human language.

In the next installment of this series, we will explore the potential limitations and risks of ChatGPT and other LLMs and how they may be mitigated.

If you liked this post, don’t forget to subscribe to Enterprising Investor.

All posts are the opinion of the author. As such, they should not be construed as investment advice, nor do the opinions expressed necessarily reflect the views of CFA Institute or the author’s employer.

Image credit: ©Getty Images /Yuichiro Chino

Professional Learning for CFA Institute Members

CFA Institute members are empowered to self-determine and self-report professional learning (PL) credits earned, including content on Enterprising Investor. Members can record credits easily using their online PL tracker.



Source link

Tags: ChatGPTlanguageLargeModelsSemanticsSyntax
ShareTweetShare
Previous Post

The Auto Sector’s Green Transition: Three Roads to Lower Returns?

Next Post

The Alpha Capture Ratio: Rising Interest Rates Mean Pricier Alpha

Related Posts

How to Diversify Your Rental Portfolio for Financial Freedom Faster

How to Diversify Your Rental Portfolio for Financial Freedom Faster

by FeeOnlyNews.com
September 12, 2025
0

You’ve built up (or are about to build) a rental portfolio, but something is telling you it’s time to pivot....

The T “Wealth Transfer” Coming for the Housing Market

The $84T “Wealth Transfer” Coming for the Housing Market

by FeeOnlyNews.com
September 11, 2025
0

Will the housing market surge for the next 25 years, or is the silver tsunami overblown? In this episode, the...

Book Review: Rethinking Investing: A Very Short Guide to Very Long-Term Investing

Book Review: Rethinking Investing: A Very Short Guide to Very Long-Term Investing

by FeeOnlyNews.com
September 11, 2025
0

Rethinking Investing: A Very Short Guide to Very Long-Term Investing. 2025. Charles D. Ellis. John Wiley & Sons, Inc. www.wiley.com...

Abraham Lincoln’s Playbook: A Model for Passive Investment Strategy

Abraham Lincoln’s Playbook: A Model for Passive Investment Strategy

by FeeOnlyNews.com
September 10, 2025
0

Abraham Lincoln, a lawyer and the sixteenth president of the United States, is an oft-idealized and highly quoted leader with...

10 Cheapest Dividend Aristocrats Now

10 Cheapest Dividend Aristocrats Now

by FeeOnlyNews.com
September 10, 2025
0

Published on September 10th, 2025 by Bob Ciura Income investors are likely familiar with the Dividend Aristocrats, which are some...

Rental Scams are on the Rise—Here’s How to Protect Yourself and Your Investments

Rental Scams are on the Rise—Here’s How to Protect Yourself and Your Investments

by FeeOnlyNews.com
September 9, 2025
0

In This Article It’s every landlord’s worst nightmare: being scammed by their tenant. As if there weren’t enough scams around,...

Next Post
The Alpha Capture Ratio: Rising Interest Rates Mean Pricier Alpha

The Alpha Capture Ratio: Rising Interest Rates Mean Pricier Alpha

A Mixed Outlook? The Banking Sector and Its Three Key Drivers

A Mixed Outlook? The Banking Sector and Its Three Key Drivers

  • Trending
  • Comments
  • Latest
1 Stock to Buy, 1 Stock to Sell This Week: Walmart, Target

1 Stock to Buy, 1 Stock to Sell This Week: Walmart, Target

August 17, 2025
Of Property Rights, Civil Society, and Shampoo

Of Property Rights, Civil Society, and Shampoo

September 1, 2025
Engine Capital takes a stake in Avantor. Activist sees several ways to create value

Engine Capital takes a stake in Avantor. Activist sees several ways to create value

August 16, 2025
James Galbraith: Crash in Top Economist Hiring Contradicts Elite-Favoring “Skill Biased Technical Change” Theory

James Galbraith: Crash in Top Economist Hiring Contradicts Elite-Favoring “Skill Biased Technical Change” Theory

September 2, 2025
Vanguard reaches .5M SEC settlement

Vanguard reaches $19.5M SEC settlement

August 29, 2025
RBC wealth revenue rises despite recruiting costs

RBC wealth revenue rises despite recruiting costs

August 27, 2025
Stock market risk-reward now in favour, time to deploy cash: Kotak MF’s Atul Bhole

Stock market risk-reward now in favour, time to deploy cash: Kotak MF’s Atul Bhole

0
Hoisted from Comments: “Nuclear Waste Is a Myth the US Promoted….”

Hoisted from Comments: “Nuclear Waste Is a Myth the US Promoted….”

0
UK Trade Groups Push for Blockchain Inclusion in Tech Deal With U.S.

UK Trade Groups Push for Blockchain Inclusion in Tech Deal With U.S.

0
Could a “Money Date” Save Your Marriage More Than Counseling?

Could a “Money Date” Save Your Marriage More Than Counseling?

0
Australia’s financial regulator slaps a 0 million fine on ANZ, its largest ever on a single entity

Australia’s financial regulator slaps a $160 million fine on ANZ, its largest ever on a single entity

0
Construction begins on Israel’s tallest residential tower

Construction begins on Israel’s tallest residential tower

0
Australia’s financial regulator slaps a 0 million fine on ANZ, its largest ever on a single entity

Australia’s financial regulator slaps a $160 million fine on ANZ, its largest ever on a single entity

September 15, 2025
Hoisted from Comments: “Nuclear Waste Is a Myth the US Promoted….”

Hoisted from Comments: “Nuclear Waste Is a Myth the US Promoted….”

September 15, 2025
Construction begins on Israel’s tallest residential tower

Construction begins on Israel’s tallest residential tower

September 15, 2025
Stock market risk-reward now in favour, time to deploy cash: Kotak MF’s Atul Bhole

Stock market risk-reward now in favour, time to deploy cash: Kotak MF’s Atul Bhole

September 14, 2025
Ethereum Price Pullback Limited – Support Levels Could Spark Upside Again

Ethereum Price Pullback Limited – Support Levels Could Spark Upside Again

September 14, 2025
Dollar steadies ahead of Fed meeting

Dollar steadies ahead of Fed meeting

September 14, 2025
FeeOnlyNews.com

Get the latest news and follow the coverage of Business & Financial News, Stock Market Updates, Analysis, and more from the trusted sources.

CATEGORIES

  • Business
  • Cryptocurrency
  • Economy
  • Financial Planning
  • Investing
  • Market Analysis
  • Markets
  • Money
  • Personal Finance
  • Startups
  • Stock Market
  • Trading

LATEST UPDATES

  • Australia’s financial regulator slaps a $160 million fine on ANZ, its largest ever on a single entity
  • Hoisted from Comments: “Nuclear Waste Is a Myth the US Promoted….”
  • Construction begins on Israel’s tallest residential tower
  • Our Great Privacy Policy
  • Terms of Use, Legal Notices & Disclaimers
  • About Us
  • Contact Us

Copyright © 2022-2024 All Rights Reserved
See articles for original source and related links to external sites.

Welcome Back!

Sign In with Facebook
Sign In with Google
Sign In with Linked In
OR

Login to your account below

Forgotten Password?

Retrieve your password

Please enter your username or email address to reset your password.

Log In
No Result
View All Result
  • Home
  • Business
  • Financial Planning
  • Personal Finance
  • Investing
  • Money
  • Economy
  • Markets
  • Stocks
  • Trading

Copyright © 2022-2024 All Rights Reserved
See articles for original source and related links to external sites.