19 articles

Tech Tips

Practical guides and tutorials to boost your productivity

LangGraph: Build Durable, Stateful AI Agents in Python
Tech Tips

LangGraph: Build Durable, Stateful AI Agents in Python

A practical guide to LangGraph, the durable agent framework that hit 1.0 in October 2025 and the 1.2 line by mid-2026. It covers the three core primitives (state, nodes, edges), conditional edges for branching and loops, and checkpointer-based persistence for crash recovery and memory. It also explains the deprecation of create_react_agent in favor of LangChain's create_agent, and the rule of thumb for choosing between the high-level agent builder and low-level StateGraph.

By Marcus Rivera · 6 min · Jul 26, 2026

LiteLLM: One Unified API for Every LLM Provider in 2026
Tech Tips

LiteLLM: One Unified API for Every LLM Provider in 2026

LiteLLM is an open-source gateway that gives developers a single OpenAI-format interface to call 100+ LLM providers. This tutorial covers installing the SDK and Proxy Server, switching providers by changing a model string, unified exception handling, streaming, and adding cost tracking, observability, virtual keys, and budgets.

By Marcus Rivera · 7 min · Jul 17, 2026

Langfuse: LLM Observability That Debugs Your AI Agents
Tech Tips

Langfuse: LLM Observability That Debugs Your AI Agents

Langfuse is an open-source, MIT-licensed LLM observability platform acquired by ClickHouse in January 2026. It provides hierarchical tracing, prompt management, evaluations, and datasets. Its OpenTelemetry-based Python SDK v3 uses the @observe decorator and integrates with LangChain, the OpenAI SDK, Anthropic, and LiteLLM.

By Marcus Rivera · 6 min · Jul 16, 2026

Unsloth: Fine-Tune LLMs 2x Faster on a Single GPU
Tech Tips

Unsloth: Fine-Tune LLMs 2x Faster on a Single GPU

Unsloth is an open-source library that fine-tunes open LLMs (Llama, Qwen, Mistral, Gemma, gpt-oss) roughly 2x faster and with up to 70% less VRAM than a stock Hugging Face setup, without sacrificing accuracy. It achieves this with custom OpenAI Triton kernels and a manual backpropagation engine, and fuses LoRA with 4-bit quantization. It runs on any NVIDIA GPU with CUDA Capability 7.0+, including the free Colab T4. Install with 'pip install unsloth' and use FastLanguageModel.from_pretrained plus get_peft_model to attach LoRA adapters before training with trl's SFTTrainer.

By Marcus Rivera · 6 min · Jul 10, 2026

DSPy: Program Your LLMs Instead of Prompting Them
Tech Tips

DSPy: Program Your LLMs Instead of Prompting Them

DSPy is a Stanford NLP Python framework (v3.3, MIT-licensed, 6.4M+ monthly downloads) for programming LLMs instead of hand-writing prompts. You declare tasks as typed signatures, compose them as modules like Predict/ChainOfThought/ReAct, define a metric, then run optimizers such as GEPA or MIPROv2 to auto-tune prompts — often lifting a baseline from ~62% to ~89% on the same model. Used in production by Shopify, Databricks, Dropbox, and Replit.

By Marcus Rivera · 7 min · Jul 2, 2026

vLLM: Serve LLMs 24x Faster Than Hugging Face Transformers
Tech Tips

vLLM: Serve LLMs 24x Faster Than Hugging Face Transformers

vLLM is the default open-source LLM serving engine in 2026. PagedAttention cuts KV-cache memory waste from 60-80% to under 4%, and continuous batching keeps the GPU full, together delivering 14-24x the throughput of Hugging Face Transformers. Install with pip, launch an OpenAI-compatible server via 'vllm serve', then tune --gpu-memory-utilization, --max-num-batched-tokens, --tensor-parallel-size, and chunked prefill against real traffic.

By Marcus Rivera · 7 min · Jul 1, 2026

Ollama: Run Local LLMs Like a Pro in 2026
Tech Tips

Ollama: Run Local LLMs Like a Pro in 2026

A hands-on guide to Ollama, the default local-LLM runner in 2026 (v0.30.10). Covers install, pulling and running models, calling them from the OpenAI SDK at localhost:11434, structured JSON outputs, tool calling, and Modelfiles, plus how to size a model to your hardware.

By Marcus Rivera · 6 min · Jun 25, 2026

Structured Outputs: Force LLMs to Return Valid JSON
Tech Tips

Structured Outputs: Force LLMs to Return Valid JSON

A practical guide to OpenAI Structured Outputs: the difference from JSON mode, function calling vs response_format, strict schema rules, constrained decoding, limits, and cross-provider options.

By Marcus Rivera · 8 min · Jun 22, 2026

Context Engineering: A Practical Playbook for Reliable AI Agents
Tech Tips

Context Engineering: A Practical Playbook for Reliable AI Agents

Context engineering is the discipline of curating tools, prompts, retrieval, and memory each turn so AI agents stay reliable over long-horizon tasks.

By Marcus Rivera · 7 min · Jun 16, 2026

Prompt Caching: How to Cut LLM API Costs by Up to 90%
Tech Tips

Prompt Caching: How to Cut LLM API Costs by Up to 90%

Prompt caching stores the computed KV attention tensors for a repeated prompt prefix so the model skips recomputation, cutting input cost and latency. Anthropic (explicit cache_control, ~90% read discount), OpenAI (automatic, 50% off, 1,024-token minimum), and Google Gemini (implicit plus explicit cache objects, up to 90%) all support it. The one rule that determines hit rate: put all static content at the front of the prompt and all dynamic content at the back.

By Marcus Rivera · 7 min · Jun 12, 2026

Firecrawl: Turn Any Website Into Agent-Ready Markdown
Tech Tips

Firecrawl: Turn Any Website Into Agent-Ready Markdown

Firecrawl converts messy, JavaScript-rendered websites into clean, LLM-ready markdown for RAG and AI agents. Install with 'pip install firecrawl' and use the Firecrawl class: scrape for known URLs (1 credit), crawl for discovery (1 credit per page, always set a limit), and schema-based extraction for typed JSON. Watch Enhanced/Stealth Mode, which costs 5 credits per page on Cloudflare-protected sites, and note that credits do not roll over.

By Marcus Rivera · 5 min · Jun 10, 2026

RAG Grounding: 7 Ways to Stop LLM Hallucinations in Production
Tech Tips

RAG Grounding: 7 Ways to Stop LLM Hallucinations in Production

A practitioner's guide to grounding retrieval-augmented generation systems. Covers fixing retrieval first, hybrid dense-plus-keyword search, cross-encoder reranking, contextual compression, refusal prompting, verified citations, Chain-of-Verification, confidence-threshold abstention, and measuring faithfulness with RAGAS.

By Marcus Rivera · 6 min · Jun 9, 2026

MCP Security: A 2026 Hardening Playbook After CVE-2025-6514
Tech Tips

MCP Security: A 2026 Hardening Playbook After CVE-2025-6514

A practical 2026 security playbook for Model Context Protocol agents. It explains MCP-specific threats (prompt injection, tool poisoning, rug pulls, confused-deputy), dissects the critical CVE-2025-6514 mcp-remote RCE, and gives concrete hardening steps: patch to 0.1.16, enforce OAuth 2.1 over HTTPS, isolate servers, gate destructive actions, and audit agent activity.

By Marcus Rivera · 7 min · Jun 2, 2026

AGENTS.md: Configure AI Coding Agents That Actually Obey
Tech Tips

AGENTS.md: Configure AI Coding Agents That Actually Obey

AGENTS.md is a Linux Foundation-stewarded open standard, adopted by 60,000+ repositories and read natively by 20+ tools including Codex, Cursor, and Copilot. This guide covers the eight core sections, the phrasing patterns that change agent behavior, monorepo nesting, and how it differs from CLAUDE.md, .cursorrules, MCP, and SKILL.md.

By Marcus Rivera · 9 min · May 31, 2026

Prompt Injection: A 2026 Defense Playbook for AI Agents
Tech Tips

Prompt Injection: A 2026 Defense Playbook for AI Agents

A defense playbook for prompt injection in AI agents. It explains why the attack is unsolvable at the model layer, frames the threat with Simon Willison's lethal trifecta (private data, untrusted content, external communication), and prescribes layered controls: architectural separation, least-privilege tools, input filtering, egress allowlisting, circuit breakers, and hardened models, which can cut attack success from 73.2% to 8.7%.

By Marcus Rivera · 6 min · May 30, 2026

Gemini API Webhooks: Kill the Polling Loop on Long-Running Jobs
Tech Tips

Gemini API Webhooks: Kill the Polling Loop on Long-Running Jobs

Google's Gemini API Webhooks eliminate polling loops for long-running jobs, simplifying integration.

By Marcus Rivera · 5 min · May 6, 2026

Caveman: The Claude Code Skill That Cuts 65% of Output Tokens
Tech Tips

Caveman: The Claude Code Skill That Cuts 65% of Output Tokens

Caveman, a Claude Code skill, dramatically cuts AI output tokens by 65%, optimizing agent interactions.

By Marcus Rivera · 5 min · Apr 15, 2026

Edgee Codex Compressor: The Rust Gateway That Cuts Codex Costs 35.6%
Tech Tips

Edgee Codex Compressor: The Rust Gateway That Cuts Codex Costs 35.6%

Edgee Codex Compressor, a Rust gateway, cuts LLM costs by 35.6% by compressing tool output.

By Marcus Rivera · 4 min · Apr 12, 2026