DEV Community

Gabriel Anhaia profile picture

Gabriel Anhaia

Senior Software Engineer @ Monta · 10+ years in backend, distributed systems & AI agents · Creator of Hermes IDE (AI-native terminal) & Neural Playground · Author of 2 books · Open-source enthusiast

Location Berlin, Germany Joined Joined on  Personal website https://xgabriel.com github website

Work

Software Engineer and Book Author

Six Year Club
Top 7
Writing Debut
Five Year Club
Four Year Club
Three Year Club
Two Year Club
One Year Club
Your AI Is Retrieving Documents You Already Deleted

Your AI Is Retrieving Documents You Already Deleted

2
Comments 1
5 min read
Sub-Agents in TypeScript: When to Spawn One, When to Inline It

Sub-Agents in TypeScript: When to Spawn One, When to Inline It

2
Comments
5 min read
When Your AI Returns Markdown and Your TypeScript App Expected JSON

When Your AI Returns Markdown and Your TypeScript App Expected JSON

1
Comments
5 min read
How to Know Your AI Agent Got Worse Before Your Users Tell You

How to Know Your AI Agent Got Worse Before Your Users Tell You

1
Comments
5 min read
Giving an AI Agent Database Access Without Giving It Your Database

Giving an AI Agent Database Access Without Giving It Your Database

1
Comments 1
5 min read
How to Tell Whether Your AI Actually Read the Document

How to Tell Whether Your AI Actually Read the Document

1
Comments
5 min read
Why the Same AI Request Costs 10 More Some Days (Seeing It in Node)

Why the Same AI Request Costs 10 More Some Days (Seeing It in Node)

Comments
5 min read
AI Agents That Ask Before They Act: Approval Gates in TypeScript

AI Agents That Ask Before They Act: Approval Gates in TypeScript

Comments
5 min read
Testing AI Agents in TypeScript Without Calling the Model

Testing AI Agents in TypeScript Without Calling the Model

Comments
5 min read
AI Agent Incident Response: What to Capture Before It Scrolls Away

AI Agent Incident Response: What to Capture Before It Scrolls Away

Comments
5 min read
AI Agent Tool Timeouts in Node: What the Model Should See When a Tool Hangs

AI Agent Tool Timeouts in Node: What the Model Should See When a Tool Hangs

Comments
5 min read
Why Your AI Assistant Answers From the Wrong Document

Why Your AI Assistant Answers From the Wrong Document

Comments
5 min read
The Unit Economics of an AI Agent Feature, Measured in TypeScript

The Unit Economics of an AI Agent Feature, Measured in TypeScript

2
Comments 1
5 min read
Your AI Agent's Context Window Is Full — What Should It Forget?

Your AI Agent's Context Window Is Full — What Should It Forget?

1
Comments
5 min read
Versioning Your System Prompt: The AI Config Change Nobody Logs

Versioning Your System Prompt: The AI Config Change Nobody Logs

1
Comments
5 min read
Shipping an AI Agent Behind a Feature Flag Without Flying Blind

Shipping an AI Agent Behind a Feature Flag Without Flying Blind

1
Comments
5 min read
The AI Agent Permission Model You Need Before Production

The AI Agent Permission Model You Need Before Production

Comments
5 min read
Your First AI Feature Will Break on Retries — the TypeScript Fix

Your First AI Feature Will Break on Retries — the TypeScript Fix

Comments
5 min read
Hybrid Search for AI Retrieval in Node: When Keywords Beat Embeddings

Hybrid Search for AI Retrieval in Node: When Keywords Beat Embeddings

Comments
5 min read
Resuming an AI Agent After a Deploy Killed It Mid-Task

Resuming an AI Agent After a Deploy Killed It Mid-Task

Comments
5 min read
Making AI Output Reproducible in Node Tests: Seeds, Temperature, Top-P

Making AI Output Reproducible in Node Tests: Seeds, Temperature, Top-P

Comments
5 min read
Time-Travel Debugging for AI Agents with LangGraph.js Checkpoints

Time-Travel Debugging for AI Agents with LangGraph.js Checkpoints

Comments
5 min read
Your AI Agent Called the Same Tool 40 Times — Detecting Loops in TypeScript

Your AI Agent Called the Same Tool 40 Times — Detecting Loops in TypeScript

1
Comments
5 min read
Rate Limiting AI Agent Endpoints in Node When One Request Costs €2

Rate Limiting AI Agent Endpoints in Node When One Request Costs €2

1
Comments
5 min read
Multi-Tenant RAG in TypeScript: Keeping One Customer's AI Out of Another's Data

Multi-Tenant RAG in TypeScript: Keeping One Customer's AI Out of Another's Data

1
Comments 1
5 min read
Debugging a Stuck AI Agent: Reading Graph State in LangGraph.js

Debugging a Stuck AI Agent: Reading Graph State in LangGraph.js

1
Comments
5 min read
Re-Indexing a Live RAG System Without Breaking Your AI Assistant

Re-Indexing a Live RAG System Without Breaking Your AI Assistant

Comments 1
5 min read
Red-Teaming Your Own AI Agent: A TypeScript Test Suite

Red-Teaming Your Own AI Agent: A TypeScript Test Suite

Comments
5 min read
Multi-Turn AI Conversations in TypeScript: What to Keep, What to Drop

Multi-Turn AI Conversations in TypeScript: What to Keep, What to Drop

Comments
5 min read
Streaming an AI Agent's Progress to the Browser in TypeScript

Streaming an AI Agent's Progress to the Browser in TypeScript

Comments
5 min read
Deploying an AI Agent on Node.js: Timeouts, Streams, Cold Starts

Deploying an AI Agent on Node.js: Timeouts, Streams, Cold Starts

Comments
5 min read
Multi-Agent Teams in TypeScript: Supervisor, Workers, Who Owns State

Multi-Agent Teams in TypeScript: Supervisor, Workers, Who Owns State

Comments
5 min read
Tool Calling in TypeScript: Zod Schema to Working Function in 40 Lines

Tool Calling in TypeScript: Zod Schema to Working Function in 40 Lines

Comments
5 min read
Ranking in TypeScript RAG: Why Cosine Similarity Alone Fails

Ranking in TypeScript RAG: Why Cosine Similarity Alone Fails

Comments
5 min read
7 Prompt Mistakes That Only Show Up in Production TypeScript Apps

7 Prompt Mistakes That Only Show Up in Production TypeScript Apps

Comments
5 min read
Prompt-Injection Defense in a TypeScript Agent: 4 Layers That Compose

Prompt-Injection Defense in a TypeScript Agent: 4 Layers That Compose

Comments
6 min read
Human-in-the-Loop with LangGraph.js: Pausing a Graph for Approval

Human-in-the-Loop with LangGraph.js: Pausing a Graph for Approval

Comments
5 min read
The Tool-Call Argument Your Model Gets Wrong — and the Validator That Catches It

The Tool-Call Argument Your Model Gets Wrong — and the Validator That Catches It

Comments
5 min read
Embeddings in TypeScript: Batching, Rate Limits, and the Retry That Corrupts Your Index

Embeddings in TypeScript: Batching, Rate Limits, and the Retry That Corrupts Your Index

1
Comments
5 min read
Your First LLM Call in TypeScript Is Untyped — Here's the Fix

Your First LLM Call in TypeScript Is Untyped — Here's the Fix

5
Comments
6 min read
The Observability You Need Before Your First 1,000 AI Users

The Observability You Need Before Your First 1,000 AI Users

Comments
5 min read
LangGraph.js vs a While Loop: When the Graph Earns Its Complexity

LangGraph.js vs a While Loop: When the Graph Earns Its Complexity

Comments
5 min read
Parallel Tool Calls in Node: Promise.all, Rate Limits, Partial Failure

Parallel Tool Calls in Node: Promise.all, Rate Limits, Partial Failure

Comments
5 min read
Chunking Markdown in TypeScript: 5 Strategies and What Each Breaks

Chunking Markdown in TypeScript: 5 Strategies and What Each Breaks

Comments
6 min read
Type Every LLM Response with Zod and 4 Classes of Bug Disappear

Type Every LLM Response with Zod and 4 Classes of Bug Disappear

Comments
5 min read
Your First Eval Suite in TypeScript (Vitest, Not a Notebook)

Your First Eval Suite in TypeScript (Vitest, Not a Notebook)

Comments
5 min read
Checkpointing Multi-Step Agents in Node So a Crash Doesn't Cost You

Checkpointing Multi-Step Agents in Node So a Crash Doesn't Cost You

Comments
5 min read
6 Tool-Design Mistakes That Make an LLM Call the Wrong Function

6 Tool-Design Mistakes That Make an LLM Call the Wrong Function

Comments
6 min read
pgvector from Node.js: Indexes, Pools, and the Query That Times Out

pgvector from Node.js: Indexes, Pools, and the Query That Times Out

Comments
6 min read
Streaming LLM Responses in Node Without Breaking Backpressure

Streaming LLM Responses in Node Without Breaking Backpressure

Comments
5 min read
Cost Ceilings in Node: Killing an Agent Loop Before It Kills the Budget

Cost Ceilings in Node: Killing an Agent Loop Before It Kills the Budget

Comments
5 min read
Agent Memory in TypeScript: Short-Term, Long-Term, and What to Throw Away

Agent Memory in TypeScript: Short-Term, Long-Term, and What to Throw Away

Comments
5 min read
Your First AI Agent in TypeScript Without a Framework

Your First AI Agent in TypeScript Without a Framework

Comments
5 min read
Citations That Survive a TypeScript Refactor

Citations That Survive a TypeScript Refactor

5
Comments
6 min read
JSON Mode vs Structured Output vs Zod Parsing: Which Guarantees Shape

JSON Mode vs Structured Output vs Zod Parsing: Which Guarantees Shape

Comments
5 min read
Guardrails in TypeScript: Input Validation, Output Filters, Refusal Paths

Guardrails in TypeScript: Input Validation, Output Filters, Refusal Paths

Comments
5 min read
LangGraph.js in Practice: Nodes, Edges, and State That Actually Persists

LangGraph.js in Practice: Nodes, Edges, and State That Actually Persists

Comments
5 min read
Idempotent Tools in Node: Safe Retries When the Model Calls Twice

Idempotent Tools in Node: Safe Retries When the Model Calls Twice

Comments
6 min read
Caching Embeddings in Node: A 60-Line Layer That Cuts the Bill

Caching Embeddings in Node: A 60-Line Layer That Cuts the Bill

Comments
5 min read
What One Token Actually Costs in a Node App (and 3 Lines That Show You)

What One Token Actually Costs in a Node App (and 3 Lines That Show You)

Comments
5 min read
loading...