Python Classroom notes 09/Sep/2026

Python Python Design idea one language independent of solution type Things to Know Zen of python New features in python are introduced as PEP (Python enhancement Proposal) Python has many distributions Cpython: One which we use IronPython Jython Two types of languages based on types Static typed languages Dynamic typed languages Python: Dynamically typed language… Continue reading Python Classroom notes 09/Sep/2026

Gen-AI Developer Classroom notes 09/Sep/2026

Basics of Langchain Langchain built a interface which abstracts the model Interaction with llm generally involves prompt model output structure Langchain did simply this with chaining prompt | model | parser Lets try this Runnable in langchain (Base class for many langchain objects) PromptTemplates Refer Here for basic langchain chains with model interaction.

Python Classroom notes 07/Sep/2026

How do programs work program is executed on os. To make the program work we have 3 options Compiler Interpreter Hybrid OS’s create a process and each process gets its own cpu and memory program is loaded into process in the case of python with python executable.

Gen-AI Developer Classroom notes 07/Sep/2026

Lets look into what agent is ? Agent (created from create_agent) is a graph at its core Langgraph is what makes this graphs possible Langgraph helps in creating custom agents with your workflows. Langgraph terminology Graph is a collection of nodes connected with each other Langraph uses the same terms Nodes (where processing happens) Edges… Continue reading Gen-AI Developer Classroom notes 07/Sep/2026

Gen-AI Developer Classroom notes 03/Sep/2026

Long term memory Refer Here for longterm memory Longterm memory spans across converstaions (sessions) Langchain uses store Lets play with InMemoryStore (ideally longterm ends in persistent store) MemoryStore is a Key Value Storage which is namespaced key is string and value is dictionary Longterm memory by types episodic semantic procedural Refer Here for sample code… Continue reading Gen-AI Developer Classroom notes 03/Sep/2026

Gen-AI Developer Classroom notes 02/Sep/2026

using agents and init chat models To create a model object just pass the string provider:model in init_chat_model create_agent Memory by scope Scope: current session/chat => short-term (checkpointer) across sessions => long term => store scratch pad (current task) => todo_list Create an agent invoke with interaction 1: tell your name interaction 2: ask your… Continue reading Gen-AI Developer Classroom notes 02/Sep/2026

Gen-AI Developer Classroom notes 01/Sep/2026

Prompt Engineering Core Principles => Garbage in and Garbage out In our case we create an agent which has model tools Every request to model will carry tools schema system prompt human message optionally tool responses previous messages or previous messages summary Anatomy of a good prompt Role Action Context Format Constraints Sample prompt You… Continue reading Gen-AI Developer Classroom notes 01/Sep/2026

Gen-AI Developer Classroom notes 31/Aug/2026

Messages in langchain when we are interacting with model we have following options system prompt: This sets the system instructions for a model human prompt: This is users question llm response: This is response from llm tool message: This represents tool response. According to langchain terminology System Prompt => SystemMessage HumanPrompt => HumanMessage LLM Response… Continue reading Gen-AI Developer Classroom notes 31/Aug/2026

Gen-AI Developer Classroom notes 27/Aug/2026

Developer Environment Setup for Agents Python windows winget install –id Python.Python.3.13 mac brew install python@3.13 UV Windows winget install -e –id astral-sh.uv mac brew install uv Visual Studio Code with necessary extensions Windows winget install Microsoft.VisualStudioCode Mac brew install –cask visual-studio-code Google AI Studio API Key Note: For vscode extensions Python (Microsoft) Jupyter (Microsoft) Windows… Continue reading Gen-AI Developer Classroom notes 27/Aug/2026

Python Classroom notes 22/Aug/2026

Threads, Thread pool, Concurrency and Async CPU Intensive activities use multiprocessing IO intensive activities: (async) Calls are blocked Lets create a simple python module which demonstrates the async We are supposed to download files from internet we have a python function python def download_file(url:str): pass When we are downloding multiple files (blocking style) for url… Continue reading Python Classroom notes 22/Aug/2026

Python Classroom notes 20/Aug/2026

Adding persistence layer (storing into databases) From python to interact with relational databases we have two apporaches Write sql queries and code around for your business logic. ORM (Object Relational Mapping): we deal with python objects and ORM translates that into SQL Queries depending on db. ORM would require a db driver package Concepts Connection… Continue reading Python Classroom notes 20/Aug/2026