Latest writings
Notes on AI agents, Salesforce, automation, micro-SaaS, and engineering.

Building Long-Term Memory: Setting Up Vector Databases for Semantic Search in LangChain
LLMs have a context limit; your data doesn't. Learn how to implement vector databases in LangChain to enable semantic search and build robust RAG pipelines.

Unmasking the Black Box: Mastering LangChain Callbacks for Debugging
Master LangChain callbacks to debug AI agents. Learn to build custom handlers, trace execution flows, and fix 'black box' LLM issues.

Best Practices for Deploying LangChain Apps to Production
Serving, streaming, per-user state, caching, tracing, evals, secrets and timeouts: a checklist for moving a LangChain 1.x agent out of the notebook, checked against the current docs.

Structured JSON Output from LLMs: Schema Injection, Pydantic and Retry Loops
Why LLM output breaks JSON parsers, and three patterns that fix it in AI agents: schema injection with TypeScript types, Pydantic validation and a self-healing retry loop.

Beyond Built-ins: Architecting Custom Tools in LangChain
Standard LangChain tools handle the basics, but production agents need to touch internal APIs and proprietary logic. Here is a deep dive into building robust, Pydantic-validated custom tools.

Architecting Autonomous Agents: A Builder’s Guide to Complex Workflows
Moving beyond simple chatbots requires a shift in architecture. Here is how to engineer autonomous agents using ReAct loops, tool usage, and state management to handle complex, multi-step objectives.

Building State: A Deep Dive into LangChain Memory for Conversational AI
LLMs are stateless by default. To build a conversational agent that actually remembers, you need to manage context effectively. This guide covers implementing various memory types in LangChain, from basic buffers to summary-based retention.

Building Robust RAG Pipelines: A Deep Dive into LangChain Document Loaders
RAG systems live or die by the quality of their data ingestion. This guide covers how to architect a robust document loading pipeline using LangChain to handle PDFs, CSVs, and Web data effectively.

What Is LangChain? When to Use It and When to Write Your Own Code
What LangChain 1.x actually gives you today (create_agent, middleware, a standard model interface) and a plain framework for deciding between it and your own orchestration code.

Building Your First LLM Chain: A Developer's Guide to Sequential Logic
LLMs are powerful, but they are stateless. To build real applications, you need to connect outputs to inputs. Here is a practical, code-first guide to building your first chain using Python and LCEL.

From Chatbot to Agent: The Engineer's Guide to LLM Memory Systems
Stateless LLMs are just goldfish. To build true agents, you need persistence. We break down memory architectures, implementation patterns, and the hidden pitfalls of context poisoning.

LangChain vs. LlamaIndex vs. Vanilla: The Builder's Stack Selection Matrix
Stop agonizing over the perfect LLM framework. A pragmatic guide comparing LangChain, LlamaIndex, and Vanilla implementations with decision charts and folder structures for shipping production AI apps.

Building a Deep Research Agent: An End-to-End Walkthrough
LLMs are terrible researchers out of the box. In this technical walkthrough, I break down how to build an autonomous research agent that searches the web, verifies sources, and generates structured briefs without hallucinating.

Engineering a Personal Prompt System: Library, Versioning, and Automated Tests
Stop guessing with your prompts. Learn how to build a centralized prompt library, version control your system instructions, and write a simple Python test harness to evaluate output quality scientifically.

Building an AI Agent That Writes to Notion: Schema Design & API Logic
Stop pasting LLM outputs manually. Learn how to architect a Notion database schema and build a Python-based agent that autonomously writes, formats, and updates status fields via the Notion API.

Building an Automated AI Daily Brief: My Morning Workflow
Stop checking five different apps to start your day. Here’s how I built a Python-based system that fetches tasks, prioritizes them with GPT-4, and emails me a strategic briefing every morning at 7 AM. We cover API integration, prompt engineering for planning, and robust scheduling.

Building Your First RAG Pipeline: A Developer’s Guide to Context-Aware AI
LLMs hallucinate. RAG fixes that. This guide walks through building a retrieval pipeline from scratch, covering ingestion, chunking strategies, and how to evaluate your system.

Building AI Agents from Scratch: A Practical Guide
Build an AI agent in plain Python: a tool-calling loop on the Claude API, a custom tool, memory, guardrails, and when LangChain, LangGraph or n8n is the better choice.
