![Samuel Chan](/img/default-banner.jpg)
- Видео 107
- Просмотров 603 941
Samuel Chan
Сингапур
Добавлен 22 июн 2017
Co-founder of Algoritma (algorit.ma), Supertype (supertype.ai), HyperGrowth (exited), GrowthBot (exited). I teach software engineering in the following domains:
- Python, R programming
- LLMs (OpenAI's gpt3, llamaindex, langchain etc)
- Data Science & Machine Learning
- JavaScript, ES6, React
- Solidity, web3 programming
- Computer Vision
- DevOps, MLOps, Docker
I'm very new and very late to RUclips (started "doing youtube" only in April 2022) and still learning the ropes around me. If you find the content helpful, consider subscribing -- early enough for the bragging rights that you did it before it was cool ❤️. I am not a professional RUclipsr, and can allocate only so much time between my other commitments and existing projects.
To learn more about my work or discuss 1-on-1 mentorship / tutoring / code review sessions, send me an email.
If you'd like to financially support my social initiatives, you can do so at: github.com/sponsors/onlyphantom/
- Python, R programming
- LLMs (OpenAI's gpt3, llamaindex, langchain etc)
- Data Science & Machine Learning
- JavaScript, ES6, React
- Solidity, web3 programming
- Computer Vision
- DevOps, MLOps, Docker
I'm very new and very late to RUclips (started "doing youtube" only in April 2022) and still learning the ropes around me. If you find the content helpful, consider subscribing -- early enough for the bragging rights that you did it before it was cool ❤️. I am not a professional RUclipsr, and can allocate only so much time between my other commitments and existing projects.
To learn more about my work or discuss 1-on-1 mentorship / tutoring / code review sessions, send me an email.
If you'd like to financially support my social initiatives, you can do so at: github.com/sponsors/onlyphantom/
Build Chat AI apps w/ Streamlit + LangChain
Langchain's Agent is the powerhouse to LLM (large language models), as it "delegates" to specialized tools ("experts") like calculator, web browser, translators etc among a wide suite of tools, determining at each step the best specialized tool, or combination of tools, to use. All powered by #langchain tools and action agents.
Action agents: at each timestep, decide on the next action using the outputs of all previous actions
Plan-and-execute agents: decide on the full sequence of actions up front, then execute them all without updating the plan
We combine this with Streamlit, a python based web app framework popular among machine learning engineers to build an AI web application powered by...
Action agents: at each timestep, decide on the next action using the outputs of all previous actions
Plan-and-execute agents: decide on the full sequence of actions up front, then execute them all without updating the plan
We combine this with Streamlit, a python based web app framework popular among machine learning engineers to build an AI web application powered by...
Просмотров: 18 441
Видео
You should use LangChain's Caching!
Просмотров 7 тыс.Год назад
LangChain provides a caching mechanism for LLMs (large language models). The benefits of caching in your LLM development are: 1. Save you money by reducing the number of API calls you make to the LLM provider (like OpenAI, Cohere etc), if you're often requesting the same completion multiple times 2. Speeds up your application by reducing the number of API calls you make to the LLM provider. We ...
A language for LLM prompt design | Guidance
Просмотров 10 тыс.Год назад
Guidance calls itself "a guidance language for controlling large language models", and is an open source project by Microsoft that "enables [prompt designers] to control modern language models more effectively and efficiently than traditional prompting or chaining". This is a tutorial on Guidance to see whether it delivers on that promise and how it fits into the LLM (large language models, lik...
GPT builds entire app from prompt (ft. SMOL Developer)
Просмотров 2,2 тыс.Год назад
We leverage on SMOL AI Developer, (~150 lines of mostly prompt engineering code) to build a party invitation web application for us using just plain text prompting, powered by GPT-3.5 / GPT-4. Smol calls itself a "Coherent Whole Program Synthesis aka your own personal junior developer" and we give this a spin to see if it lives up to its promise. Smol-ai Developer: github.com/smol-ai/developer ...
Making a Sci-Fi game w/ Cohere LLM + Stability.ai: Generative AI tutorial
Просмотров 1,5 тыс.Год назад
We use Cohere, a large language model with a free tier, along with Stability AI's text to image models to help us create a game world ("world building") unlike any others, except the 729 SciFi-themed civilization games out there. Great for diving into Cohere LLM and text-to-image models from Stability AI (makers of Stable Diffusion) - Watch PART 1 of the LangChain / LLM series: Build a GPT Q&A ...
Copilot Chat Demo | Copilot X: best AI pair programmer!
Просмотров 1,2 тыс.Год назад
A demonstration of GitHub Copilot Chat, one of the latest addition to Copilot X. What's already the best AI code assistant just got better. Powered by OpenAI's Codex model and directly integrates into Visual Studio and VS Code, this extension takes your coding productivity up a few notches. Repository for the code demonstration: github.com/onlyphantom/llm-python
Building a queryable journal 💬 w/ OpenAI, markdown & LlamaIndex 🦙
Просмотров 2,5 тыс.Год назад
We incorporate OpenAI and LlamaIndex into a markdown-based notetaking system (like Obsidian) to build a daily journal system that is remarkably query-able and very very cheap (using local storage for our vectors). I use it daily, but I never got around to explaining the build process. Here it is now! This tutorial features GPT-3, LlamaIndex, OpenAI, argparse to turn it into a command line inter...
Building an AI language tutor: Pinecone + LlamaIndex + GPT-3 + BeautifulSoup
Просмотров 5 тыс.Год назад
We train GPT-3.5 on Nietzsche's writing to build the world's best GPT-based language translation and AI language tutor. Features Pinecone, LlamaIndex, GPT3, and BeautifulSoup for web scrapping. - Watch PART 1 of the LangChain / LLM series: Build a GPT Q&A on your own data ruclips.net/video/DYOU_Z0hAwo/видео.html - Watch PART 2 of the LangChain / LLM series: LangChain OpenAI to chat w/ (query) o...
OpenAI's python QuickStart (tutorial/first look)
Просмотров 3,4 тыс.Год назад
Taking a short detour to have a closer look at OpenAI's official python library, including GPT-3 for text completion and natural language Q&A , Dall-E 2 for generative art (AI image generation), and OpenAI's Whisper for speech to text and human level transcription. In the next video, we'll continue building on LangChain, LlamaIndex other amazing LLM libraries! - Watch PART 1 of the LangChain / ...
Locally-hosted, offline LLM w/LlamaIndex + OPT (open source, instruction-tuning LLM)
Просмотров 30 тыс.Год назад
Implementing an open source LLM that runs on your machine, that you can even access in offline mode! This uses Meta's OPT model, a 175-billion-parameter that rivals GPT-3 in performance. Also interestingly, we'll use the instruction-tuned version of it, known as the OPT-IML. Mentioned in the video: - OPT (Open Pre-trained Transformers): huggingface.co/docs/transformers/model_doc/opt - OPT Paper...
GPT scrapes + answers from any sites (ft. Chromadb, Trafilatura)
Просмотров 7 тыс.Год назад
Implementing a GPT-3-powered Natural language Question Answering bot for ANY websites, featuring LlamaIndex, Trafilatura and ChromaDB. You can pass in a list of websites, then directly ask questions on it, and GPT will build the index required to help retrieve and generate answers to your questions. LlamaIndex (GPT Index) is a project that provides a central interface to connect your LLM’s with...
Understanding Embeddings in LLMs (ft LlamaIndex + Chroma db)
Просмотров 37 тыс.Год назад
We do a deep dive into one of the most important pieces of LLMs (large language models, like GPT-4, Alpaca, Llama etc): EMBEDDINGS! :) In every langchain or llamaindex tutorial you'll come across this idea, but they can feel quite "rushed" or opaque, so this video presents a deeper look into what embeddings really are, and the role it plays in a world dominated by large language models like GPT...
LangChain + HuggingFace's Inference API (no OpenAI credits required!)
Просмотров 50 тыс.Год назад
We combine LangChain with GPT-2 and HuggingFace, a platform hosting cutting-edge LLM and other deep learning AI models. This has the added benefit of not incurring any charges since we're not using OpenAI (might as well, seeing we're in a recession right about now) but instead using the GPT-2 model hosted on HuggingFace.. LangChain is a fantastic tool for developers looking to build AI systems ...
LangChain + OpenAI to chat w/ (query) own Database / CSV!
Просмотров 41 тыс.Год назад
In part 2 of this series we use natural language (english) to query our database and CSV. LangChain integrates with GPT to convert natural language to the corresponding SQL statements, or pandas command, which is then executed to return a natural language response. LangChain is a fantastic tool for developers looking to build AI systems using the variety of LLMs (large language models, like GPT...
LangChain + OpenAI tutorial: Building a Q&A system w/ own text data
Просмотров 29 тыс.Год назад
LangChain is a fantastic tool for developers looking to build AI systems using the variety of LLMs (large language models, like GPT-4, Alpaca, Llama etc), as it helps unify and standardize the developer experience in text embeddings, vector stores / databases (like Chroma), and chaining it for downstream applications through agents. In this tutorial we're using our own custom text / data and tr...
TorchVision Quick Start: Image classifier in 10 mins
Просмотров 2 тыс.Год назад
TorchVision Quick Start: Image classifier in 10 mins
Python's 3.9 "@cache" (and lru_cache) is amazing!
Просмотров 645Год назад
Python's 3.9 "@cache" (and lru_cache) is amazing!
Train a PyTorch neural network step-by-step | PyTorch deep learning (Feb 2023)
Просмотров 703Год назад
Train a PyTorch neural network step-by-step | PyTorch deep learning (Feb 2023)
Use less for-loops, use more vectorization
Просмотров 4,2 тыс.Год назад
Use less for-loops, use more vectorization
Backpropagation algorithm & gradient descent, but explain it like I'm 5
Просмотров 777Год назад
Backpropagation algorithm & gradient descent, but explain it like I'm 5
PyTorch's Computational Graph + Torchviz | PyTorch (2023)
Просмотров 2,6 тыс.Год назад
PyTorch's Computational Graph Torchviz | PyTorch (2023)
Taskwarrior is THE task management system you need
Просмотров 8 тыс.Год назад
Taskwarrior is THE task management system you need
Building neural networks with PyTorch (PyTorch w/ GPU tutorial, part 4)
Просмотров 357Год назад
Building neural networks with PyTorch (PyTorch w/ GPU tutorial, part 4)
PyTorch Datasets, DataLoaders and Transforms (PyTorch w/ GPU series, part 3)
Просмотров 739Год назад
PyTorch Datasets, DataLoaders and Transforms (PyTorch w/ GPU series, part 3)
Introduction to Tensors (PyTorch with GPU series, part 2)
Просмотров 893Год назад
Introduction to Tensors (PyTorch with GPU series, part 2)
GPU-based deep learning (2023) series 1: PyTorch & CUDA installation guide
Просмотров 4,4 тыс.Год назад
GPU-based deep learning (2023) series 1: PyTorch & CUDA installation guide
Hands on introduction to Docker Compose V2 (tutorial ft. wordpress, mysql, phpmyadmin)
Просмотров 938Год назад
Hands on introduction to Docker Compose V2 (tutorial ft. wordpress, mysql, phpmyadmin)
Hands on Introduction to Docker & Data Persistence w/ Docker Volumes
Просмотров 609Год назад
Hands on Introduction to Docker & Data Persistence w/ Docker Volumes
DuckDB: Hi-performance SQL queries on pandas dataframe (Python)
Просмотров 11 тыс.Год назад
DuckDB: Hi-performance SQL queries on pandas dataframe (Python)
thanks 🌹
comp sci sigh
Yeah! Poi :D
Please what VS Code theme are you using?
u explained gradeint descent as back propagation. but theres a diffence i m trying to figure out why need back propagation when gradient descent does the job - finind the minima. the most appropriate parameters w.r.t to cost function. what role does backprogation play in adjusting the paramters. whats the intuition
😅 the pens
thank you man
clean explanation. thx
Thanks bro
How can i get the code of this video
I've been searching how to do this... I couldn't find a solution until I stumbled across this video. Thank you :)
Hi, somehow after I'm applying the yearslider, the legend on the bottom (pop) can't fit the screen anymore at 1,200,000,000 (year 1995+). Is there something I can do about that? I have tried to change the font size (labelFontSize) but it's not working.
Thanks for this video! Quick question, Is there any risk of PII leakage in this implementation ? Asking this because we cannot see the model getting downloaded locally.
to turn off security for local dev xpack.security.enabled=false xpack.security.enrollment.enabled=false
i did the exact same thing but "workon web3" command didnt work in my vs and also it created block0 only with the contract address etc no block 1
Would you share the code of the last version of the streamlit app with more tools that you showcase on the video? the one on github seems to be the simple one. Thanks! was a great series!
Is it possible to plot charts on top of sql data ?
One question though… the “project_dir” variable - how did you add the forward slash and projectname variable without putting in quotes. Was expecting it to throw and error cause it’s like you’re dividing the path by projectname
Brilliant vid!
Samuel, thank you for the hint with threshold filter. When applied, it is much easier for OCR to see the digits with such font.
Hey how can we get tpoken usage with streaming = true
Hi, could this type of chatbot be integrated with Messenger and own website for customer support like interactions, based on own Q&A files and text?
Because SQLDatabase from langchain support only one schema.
Hi Samuel, do we have any method to connect multiple schema for database chatting?
very good video for starters 🙂
Thank You Sir
How to return SQLQuery just wanna get that :(( any idea ?
Excelente. A+1. Se puede conectar un base de datos de Foxpro + DuckDB con python
Why didnt u flip the kernel? Isnt it correlation? Even tho here its symmetric but students may misunderstand
crazy how none of these are relevant anymore; i get all sorts of errors after installing llama_index (newest version as of today) - i see many deprecations - PromptHelper and others; but this has been a nice lesson though, i'm subscribed now
Hey Sam, your series has helped me immensely. I am trying to build on the work here and add some sort of cacheing so I can continue to ask questions. Any tips you can offer to do this?
ImportError: cannot import name 'HuggingFace_Hub' from 'langchain' . how tf does it not exist anymore?
i think you should try "from langchain_community" instead?
Hey man, im getting error on your: vecstore = Chroma.from_documents(texts, embeddings) qa = RetrievalQA.from_chain_type( llm=OpenAI(), chain_type = "stuff", retriver = vecstore.as_retriever() ) ValidationError: 2 validation errors for RetrievalQA retriever field required (type=value_error.missing) retriver extra fields not permitted (type=value_error.extra) Can u help me out?
Its possible to combinate the pdf file with this one?
Great work, thank you!
Great video. I was wondering how can the openai deal when there is a typo in one of the sentences you wrote that doesn't match the entires in the database
Mantap bg, auto subscribe
Hey man would it be cool of i use firebase as my database instead of SQL?
at docker run " bootstrap checks failed"
dude sorry to say this its too confusing.
Dude, what's confusing or not depends on the level of understanding. Samuel is a better coder and data engineer as a teacher maybe but he's doing awesome; you can pick up loads here. What scares me most is that I'm pretty closed to his level =P
Hello, does this method still work? I copied your code from GitHub and when I open the HTML file in browser it says "Loading runtime... Runtime created... Initializing components..." and then never stops loading. I checked the console and it gives me many errors that I don't understand. I've replied to this comment with the errors if you're interested.
Uncaught (in promise) PythonError: Traceback (most recent call last): File "/lib/python3.10/asyncio/futures.py", line 201, in result raise self._exception File "/lib/python3.10/asyncio/tasks.py", line 234, in __step result = coro.throw(exc) File "/lib/python3.10/site-packages/micropip/_micropip.py", line 183, in install transaction = await self.gather_requirements(requirements, ctx, keep_going) File "/lib/python3.10/site-packages/micropip/_micropip.py", line 173, in gather_requirements await gather(*requirement_promises) File "/lib/python3.10/asyncio/futures.py", line 284, in __await__ yield self # This tells Task to wait for completion. File "/lib/python3.10/asyncio/tasks.py", line 304, in __wakeup future.result() File "/lib/python3.10/asyncio/futures.py", line 201, in result raise self._exception File "/lib/python3.10/asyncio/tasks.py", line 232, in __step result = coro.send(None) File "/lib/python3.10/site-packages/micropip/_micropip.py", line 291, in add_requirement await self.add_wheel( File "/lib/python3.10/site-packages/micropip/_micropip.py", line 316, in add_wheel await self.add_requirement(recurs_req, ctx, transaction) File "/lib/python3.10/site-packages/micropip/_micropip.py", line 291, in add_requirement await self.add_wheel( File "/lib/python3.10/site-packages/micropip/_micropip.py", line 316, in add_wheel await self.add_requirement(recurs_req, ctx, transaction) File "/lib/python3.10/site-packages/micropip/_micropip.py", line 286, in add_requirement raise ValueError( ValueError: Couldn't find a pure Python 3 wheel for 'tornado>=5.1'. You can use `micropip.install(..., keep_going=True)` to get a list of all packages with missing wheels. at new_error (pyodide.asm.js:14:238191) at pyodide.asm.wasm:0xedbcb at pyodide.asm.wasm:0xf1a0e at method_call_trampoline (pyodide.asm.js:14:238105) at pyodide.asm.wasm:0x134c2c at pyodide.asm.wasm:0x217a84 at pyodide.asm.wasm:0x174a14 at pyodide.asm.wasm:0x135149 at pyodide.asm.wasm:0x135243 at pyodide.asm.wasm:0x1352e6 at pyodide.asm.wasm:0x1fff83 at pyodide.asm.wasm:0x1f98b5 at pyodide.asm.wasm:0x135329 at pyodide.asm.wasm:0x201f1b at pyodide.asm.wasm:0x1ff9ff at pyodide.asm.wasm:0x1f98b5 at pyodide.asm.wasm:0x135329 at pyodide.asm.wasm:0xf16d8 at Module.callPyObjectKwargs (pyproxy.gen.ts:360:23) at Module.callPyObject (pyproxy.gen.ts:384:17) at wrapper (pyodide.asm.js:14:205222)
Bro I am unable to connect them kindly help me
I've been sloppily using Taskwarrior for a few years but hadn't delved this deeply. I've _also_ wanted to build a bridge to Remember the Milk, so I can interact with my tasks on my phone (or in a browser, but that's less necessary since I'm in the terminal a lot). So I'm looking forward to watching your video on building a Python app wrapping Taskwarrior. Cheerio!
gaussean filter
Hi how to export the results in csv file
Is there a way to delete a specific cache only in the database?
I used Silenium to collect comments
How to get geographical details about people who watched my videos ie.details about viewers country from where they watch it?
By Python how could we earn f as as freelancrer. Please share your experience.
Could you take a breath while speaking? Listening to you talk makes me feel like I'm about to suffocate.
I have a large collection of markdown files and this video is really helpful. Thank you for sharing.