Engineering Notes

Engineering conversations turned into a usable knowledge base

Capturing the essence of engineering conversations into a structured knowledge base. What's needed isn't more output, but lower-cost understanding.

Featured

All topics →

Latest

置頂 tech

What Tools This Blog Is Built With

Astro handles static rendering and content management, Cloudflare Pages/Workers handle deployment and dynamic APIs, D1 provides lightweight data storage, Vectorize + Workers AI power RAG semantic search, and R2 stores OG images and TTS audio. The entire pipeline — from YouTube crawl to user search — runs inside the Cloudflare ecosystem.

Explainer

RAG's Five Stages: From Pipeline to Reasoning Retrieval, and the Naive RAG on My Own Site

Over the past two years RAG evolved from a 'linear pipeline' to 'loop-based reasoning'. It maps cleanly to five stages: Naive, Advanced, Modular, Graph, Agentic. The real inflection point is control moving from pipeline to agent — a System 1 → System 2 shift. Looking back at engineer-news's own RAG stack, it's stuck at the Naive edge — so this post also lays out what to fix next.

Deep Dive

Building a Real RAG: 5 Infra Lessons from InfiniFlow's 2024 Year-in-Review

The previous post zoomed out for a five-stage panorama of RAG. This one zooms in on the five infra lessons any real RAG has to face: document ingestion, contextualized chunking, three-lane hybrid search, tensor reranker, and GraphRAG's semantic gap. Each lesson is checked against engineer-news's current stack, ending with a priority list for a personal site.

Deep Dive

J-lens: Anthropic's New Interpretability Tool for Reading Claude's Inner Thoughts via a 'Global Workspace'

Anthropic proposes J-lens, an interpretability tool that captures the 'verbalizable' representations inside a Transformer, and uses it to show that Claude contains a privileged subspace analogous to the neuroscientific 'global workspace' — a small set of vectors that broadcast, drive reasoning, respond to external steering, and even leak signals during deception and evaluation awareness.

Harness Engineering (2): Five Engineering Answers from OpenAI's Million-Line Experiment

Three OpenAI engineers, five months, one million lines of AI-generated code, zero hand-written. The real value of this experiment isn't the numbers — it's the proof that Harness design can be engineered. Five concrete practices: making the app legible to agents, treating the repo as the source of truth, mechanizing architectural constraints, rewriting merge philosophy, and background entropy management.

Harness Engineering (3): Industry Consensus, Four Pillars, and a Three-Phase Rollout

Distilling Harness Engineering from concept and benchmark case into something you can start executing today: the four fixed failure modes of Agents, the 40% context sweet spot, the four-pillar framework the industry has converged on, and a three-phase roadmap from 'this afternoon' to 'fully automated in two weeks' — closing with six industry consensus points and three still-unsolved problems.

Research

84,395 Users, Effect Size 0.7: Why a Pretty Number Doesn't Mean a Self-Hypnosis App 'Works'

An npj Digital Medicine study analyzed 84,395 users and 282,893 sessions on the self-hypnosis app Reveri. Self-rated stress dropped with a Cohen's d of −0.71 to −0.78 (a 'large' effect). But it's a retrospective observational study with no control group and a single-item Likert measure — a great case study in why 'big N + big effect' still can't prove causation.

Deep Dive

MCP in Claude Code: How Model Context Protocol Connects AI to Your Tool Ecosystem

MCP (Model Context Protocol) is an open protocol designed by Anthropic that lets Claude Code call external tools and data sources through a standardized interface. Since its November 2024 release, it has rapidly become the de facto standard for AI agent tool integration, adopted by Cursor, Windsurf, and 40+ other editors.

Deep Dive

Engineering Lessons from Building Cursor: From VSCode Fork to $500M ARR

Cursor is an AI-powered code editor by Anysphere, built by four MIT graduates, that hit $500M ARR within two years of launch. This article distills the real engineering lessons they've shared publicly: why they forked VSCode instead of building an extension, how Tab prediction's latency engineering works, and the hard production lessons from shipping Agent Mode.

Explainer

How Does a Transformer Know Word Order? From Absolute Encoding to RoPE

Transformer self-attention is inherently orderless — positional encoding is the fix. From sinusoidal absolute encoding, to learnable absolute encoding, to relative positional encoding, to RoPE (Rotary Position Embedding): modern LLMs almost universally use RoPE because it requires no parameters, naturally encodes relative distances, and can be extended to longer sequences.

Explainer

Why PostgreSQL Is the Most Secure System in the World: Layered Defense from role and schema to GRANT and RLS

Industry security tends to get 'looser the closer you get to the database' — backends often connect directly with an admin account, bare and unguarded. PostgreSQL uses role + schema + column-level GRANT + RLS to build outside-in permissions that can go as fine-grained as a single row (or even a single cell), keeping the last lock inside the database itself.

Explainer

Harness Engineering: The Model Isn't Dumb, It Just Lacks Human Guidance

When an AI Agent performs poorly, it's not necessarily because the model is dumb. Starting from a small experiment where a Gemma 4 2B fixes a bug, this piece explains what a Harness is, how Harness Engineering differs from Prompt / Context Engineering, and how effective natural-language rules like agents.md really are.

Case Study

a920604a Labs: A Dual-Cloud Full-Stack Playground Integrating Four Tools with a pnpm Monorepo

A pnpm monorepo integrating four tool SPAs: a to-do list, a habit tracker, an ebook reader, and a resignation stamp collector. apps/root is the sole build entry point; the four modules are library-only workspace packages bundled together by root's Vite, sharing @a920604a/auth and @a920604a/ui, deployed across Firebase + Cloudflare dual cloud.

Case Study

Live English Tutor: Building a Real-Time Voice AI English Tutor with LiveKit + Gemini Native Audio

A real-time-voice-first AI English tutoring system: students converse with the AI teacher Emma via microphone (optionally with video/screen sharing), the system corrects mistakes in real time, and generates a post-class report in Chinese. The technical core is LiveKit (Self-hosted WebRTC) + Google Gemini 2.5 Flash Native Audio, with a FastAPI backend handling auth, courses, and data persistence.