Monday, March 18, 2024

Mastering Langchain course by Sharath Raju

https://learning.oreilly.com/course/langchain-masterclass/9781835464427/

https://github.com/PacktPublishing/LangChain-MasterClass---Build-15-OpenAI-and-LLAMA-2-LLM-Apps-using-Python/tree/main

Topics covered:

Streamlit:
For quick web UI prototyping

OpenAI LLM, audio transcription.
HuggingFace hosted models

Google Colab - for using huggingface transformers which download the model locally.

Running Llama 2 locally via CTransformers or via Replicate API

DuckduckGo search

Prompt Templates:
FewShotPromptTemplate, Length based example selector


Splitters:
RecursiveCharacterTextSplitter
CharacterTextSplitter


Embeddings:
SentenceTransformerEmbeddings
OpenAIEmbeddings
similarity_search

Response formatter/output parser:
csv
json

Vector DBs:
Pinecone - hosted
Chroma - local
FAISS(not typically used as vector db, but for similarity search etc)

Memory:
ConversationSummaryMemory
TokenBuffer
WindowBuffer
ConversationBuffer

Agents:
Pandas dataframe agent - to run some python code to analyze csv data

Chains:
Utility Chains:
Load_Summarize_Chain - load and summarize docs
LLMRequestsChain - to fetch a url


Others:
SequentialChain
chain_type=stuff/map_reduce

No comments:

Blog Archive