Nine Hours of LLM Tutorials, Bottled as Python Scripts
A growing collection of self-contained Python scripts and notebooks that teach LLM patterns—from basic OpenAI calls to multi-agent guardrails—through runnable examples tied to video courses.

What it does This repository houses roughly two dozen self-contained Python scripts and Jupyter notebooks that demonstrate how to wire together popular LLM tools—LangChain, LlamaIndex, OpenAI’s Agent SDK, ChromaDB, Pinecone, and others. Each script corresponds to a video lesson (about nine hours total) and focuses on a single pattern, from querying CSVs with natural language to building multi-agent systems with guardrails. It is essentially a curated syllabus turned into runnable code.
The interesting bit Unlike static tutorial repos that fossilize, this one gets refreshed: a May 2025 update added six scripts covering modern agentic patterns using the then-latest OpenAI Agent SDK, while earlier updates tackled RAG, structured output, and conversational memory. The author treats the repo as living reference material for public courses and workshops rather than a one-off blog post.
Key highlights
- Self-contained scripts: pick any single file (e.g.,
19_agents_handsoff.py) and run it without navigating a monolithic framework. - Covers the full arc from beginner (OpenAI API basics) to specialized (ReAct agents with streaming, tool-use RAG, local offline LLMs via OPT).
- Tightly coupled to free video walkthroughs and public courses, including a multi-agent workshop and a finance-focused generative AI series.
- Recently updated for contemporary library versions (LangChain v0.3.2, LlamaIndex 0.6.31, OpenAI Agent SDK as of May 2025).
Caveats
- Many examples require API keys (OpenAI, and optionally Pinecone, HuggingFace, Cohere, or a proprietary financial data API) so “free to access” does not mean “free to run.”
- The
tritondependency is x86_64-only, which can break installation on ARM machines. - Video recordings sometimes lag behind the repo code by several library versions, so following along may require minor line-by-line adjustments.
Verdict Good for developers who want to bridge from “I read the LangChain docs” to “I built a working agent” by studying small, focused examples. Skip it if you are looking for a reusable library or a production framework; this is coursework, not infrastructure.
Frequently asked
- What is onlyphantom/llm-python?
- A growing collection of self-contained Python scripts and notebooks that teach LLM patterns—from basic OpenAI calls to multi-agent guardrails—through runnable examples tied to video courses.
- Is llm-python open source?
- Yes — onlyphantom/llm-python is open source, released under the MIT license.
- What language is llm-python written in?
- onlyphantom/llm-python is primarily written in Jupyter Notebook.
- How popular is llm-python?
- onlyphantom/llm-python has 926 stars on GitHub.
- Where can I find llm-python?
- onlyphantom/llm-python is on GitHub at https://github.com/onlyphantom/llm-python.