Querying NBA stats with GPT-3 + Statmuse + Langchain
Imagine you got the smartest person in the world, locked them in a room without internet, and asked them to answer a bunch of random trivia questions, with only a few seconds for each one. Now imagine the same test, but this time you give the person access to a smartphone with Google and a calculator. Which test would go better?
This seems to be the essential logic behind recent techniques for improving the accuracy of large language models. LLMs locked in a room tend to make things up; why not let them use Google and a calculator too?
In this post, I show how I composed a simple AI program that can answer multi-part questions about NBA statistics. It uses GPT-3 as a general-purpose LLM “agent”, and calls out to Statmuse, a specialized natural-language search engine for sports statistics. The interaction between the two is orchestrated by Langchain, a Python library that helps compose “chains” of LLM behavior.
ChatGPT has taken the world by storm. Millions are using it. But while it’s great for general purpose knowledge, it only knows information about what it has been trained on, which is pre-2021 generally available internet data. It doesn’t know about your private data, it doesn’t know about recent sources of data. Wouldn’t it be […]
Simplifies using new libraries/frameworks for devs. Assists in answering support questions for Library maintainers.
Help us find great AI content
Never miss a thing! Sign up for our AI Hackr newsletter to stay updated.
AI curated tools and resources. Find the best AI tools, reports, research entries, writing assistants, chrome extensions and GPT tools.