Engineering Insights.Shared for Growth.
In-depth articles, tutorials and insights on system design, architecture, coding and everything in between.
System Design: Designing a Financial Ledger with Double-Entry Constraints
TLDR: Designing a financial ledger requires strict double-entry compliance, high consistency, and complete auditability. Unlike traditional databases where records are updated in-place, a financial le
PagedAttention & KV-Cache Optimization: How vLLM Handles Large Scale Inference
TLDR: Large Language Model (LLM) serving is heavily bound by GPU memory capacity due to the Key-Value (KV) cache. Traditional serving frameworks allocate contiguous memory based on maximum sequence le
CPython Internals: Reference Counting, Cycle Detection, and Memory Profiling
TLDR: CPython manages memory using a two-tier system: Reference Counting (for immediate deallocation) and a Generational Cyclic Garbage Collector (to identify and collect isolated reference cycles). T
Concurrency Models: Actor Model vs. Communicating Sequential Processes (CSP)
TLDR: Shared-memory multithreading using manual locks is notoriously difficult to scale and debug. To avoid race conditions and deadlocks, modern platforms use message-passing concurrency models. This
Spark 101: Installing, Configuring, and Running Your First PySpark App Locally
TLDR: Learning Apache Spark usually starts with understanding how to set up a local development environment. This guide outlines the differences between local and cluster execution modes, details how
Deep Learning Optimizers: Deriving Momentum, RMSProp, and AdamW mathematically
TLDR: Optimizers determine how we update neural network weights during training. While Stochastic Gradient Descent (SGD) updates parameters along the negative gradient direction, modern models use ada
Cell-Based Architectures: Designing Fault Isolation Boundaries for Million-User Apps
TLDR: As microservice architectures scale, a single outage in a core service can cascade across the entire system. Cell-Based Architecture mitigates this by partitioning the entire system into small,
Tarjanβs Algorithm: Finding Strongly Connected Components (SCC) step-by-step
TLDR: In directed graphs, a Strongly Connected Component (SCC) is a maximal subset of vertices where every vertex is reachable from any other vertex in the subset. Finding these components is crucial
Python Metaprogramming: Creating Custom Metaclasses and Attribute Descriptors
TLDR: Metaprogramming is the art of writing code that manipulates, generates, or validates other code at runtime. In Python, this is achieved using Metaclasses (which customize class creation) and Des