All bites
The whole library, newest first. Filter by what you are here for, or pick a topic if you already know.
8668 bites
Page 150
Validation loss increases while training loss decreases: what is this?
This tests recognition of overfitting and regularization. A strong answer names it, offers early stopping, dropout or weight decay, and data augmentation or more data. A red flag is suggesting longer training or more parameters without fixing generalization.
Explain word embeddings and why they beat one-hot encoding for large vocabularies
Embeddings cluster similar meanings in low-dimensional space, while one-hot vectors are orthogonal, huge, and semantically blank.
State-Space Models Replace Quadratic Attention
State-space models replace attention with recurrent linear dynamics, scaling linearly with sequence length. They excel at long DNA, audio, and video modeling. The footgun is naive discretization, which collapses stability on long sequences.
NIST AI RMF for LLM Deployment
The NIST AI RMF is a pre-flight checklist for organizational AI risk, not just code bugs. Teams use it to justify LLM deployment across legal, security, and fairness dimensions.
Data Poisoning: Corrupting Models at the Source
Data poisoning is slipping lies into a textbook that a model memorizes forever. It shows up when you train on scraped web data or open fine-tuning sets. The footgun is assuming clean benchmarks mean clean weights; poison can hide until a trigger appears.
HHH: The Three-Way Tug-of-War in LLMs
HHH frames LLM alignment as a three-way tug-of-war: helpful, harmless, honest. It governs RLHF reward models and safety filters, where maximizing one axis weakens the others. The footgun is optimizing helpfulness, producing sycophants or dangerous compliance.
ROUGE Score: Recall Overlap for Generation
ROUGE measures text generation recall by counting overlapping words and phrases against a reference. It is the default metric for summarization benchmarks. Perfect paraphrases score poorly while keyword-stuffed nonsense can score high.
Tool Definition Schema: Contracts for LLM Actions
A tool schema is JSON that tells an LLM what actions it can take. Use it when you want the model to call APIs instead of just chatting. The model only emits arguments; it never runs the tool, and vague descriptions cause silent failures.
Function Calling: LLMs Using Tools
Function calling turns an LLM into an API translator: it reads input and emits JSON telling your code which tool to run. Use it when the model needs live data it cannot store in weights. The model never executes the call and can hallucinate arguments.
Masked Language Modeling: Fill-in-the-Blank Pretraining
MLM hides random tokens and trains the model to reconstruct them from context. It powers BERT-style encoders for classification and search. The catch is that it never learns left-to-right generation, so it needs extra machinery for open-ended text.
Masked Multi-Head Attention in Decoders
Masked multi-head attention runs parallel detectors over past tokens only, stopping a decoder from peeking ahead. It powers autoregressive models like GPT. The footgun is using the causal mask in bidirectional encoders, which silently destroys context.
Transformer Encoder Block
A Transformer encoder block mixes full sequence context in parallel: every token attends to all others to refine its vector. It drives bidirectional models like BERT. The footgun is using it unmasked for generation, which leaks future information.
Position-wise FFN: Each Token's Private Workshop
Think of the position-wise FFN as each token's private gym after attention: it bulks up features and stores facts, but never shares between seats. Cutting it to save parameters starves the model because attention cannot do this alone.
Tokenization and Input Embeddings in LLMs
Tokenization splits language into tokens, and embeddings map token IDs into vectors with meaning. Every transformer does this first. The footgun is assuming one token equals one word—token counts behave unpredictably when words merge or split.
AWS Inferentia and Annapurna Labs
AWS Inferentia is an AWS chip product line. Annapurna Labs, Amazon's semiconductor division acquired in 2015, builds Nitro, Graviton, and Trainium and ranks among TSMC's top five fabless customers. Do not assume Annapurna designs every AWS accelerator.
Google TPU: Built for Matrix Math
A TPU is a specialist ASIC, not a faster GPU; it trades graphics flexibility for matrix-math throughput per watt. Google deploys them for TensorFlow, JAX, and PyTorch at scale. They excel at CNNs but can lag on tasks needing rasterization or recurrent logic.
Few-Shot Prompting
Few-shot prompting embeds task examples directly in the prompt to guide output format without retraining. It excels at niche tasks and consistent formatting, but mismatched examples degrade performance more than no examples at all.
LLM Scaling Laws: Match Parameters to Tokens
For a fixed compute budget, model size and training data must grow equally. When choosing between a larger model or more tokens for the same FLOPs, more data usually wins. The footgun is scaling parameters alone, which undertrains the model and wastes compute.

Describe lightweight vs heavyweight Core Data migration and a heavyweight example
This tests inferred versus manual Core Data migrations. Contrast lightweight additive changes with heavyweight transforms like entity splits, citing promoting a string to a new entity. A red flag is claiming renames always need custom mapping.

Describe a pattern for background Core Data fetches and UI updates
This tests NSManagedObjectContext concurrency and queue confinement. Strong answer: create a background context, fetch, pass objectIDs or structs to main, then main context fetches by ID to update UI. Red flag: passing NSManagedObjects across threads.