As an AI engineer, please learn:
- Learn the roofline model and why decode is memory-bound
- Deploy vLLM and SGLang, then read their schedulers
- Understand paged attention from the code, not the blog post
- Build observability before you optimize anything
- Track TTFT, inter-token latency, throughput, queue depth
- Use Grafana + Prometheus for inference dashboards
- Turn on prefix caching and find which workloads it helps
- Learn continuous batching and chunked prefill
- Run load tests with 1000+ concurrent requests
- Report p50, p95, p99, never just the mean
- Master quantization tradeoffs (FP8, INT4, AWQ, GPTQ)
- Learn speculative decoding and where it stops helping
- Set up KV cache eviction for long contexts
- Try disaggregated prefill and decode serving
- Learn Kubernetes for AI workloads and autoscale on queue depth
- Learn how inference costs break unit economics
- Build your own model router by cost, latency, quality
- Create a token budgeting system per request
- Build one inference service and benchmark it publicly
- Read inference research instead of model release news
- Start sharing your optimization benchmarks
I put together a 10-week plan that covers every one of these at 30 minutes a day. It is 50 sessions, split between reading the theory and building on your own service, and all of them feed one artifact: an inference service you deploy, instrument, load test past 1000 concurrent requests, tune, and publish as a reproducible benchmark.
It is open on GitHub and contributions are welcome, especially newer sources worth adding. I am working through it myself and will share more content on this going forward, so stay tuned.
GitHub repo: https://t.co/UTxKAzhzJQ
(don't forget to star π)
12 days into grinding Neetcode 150, and Iβve finally crossed the halfway mark.
Started it to revise DSA, but ended up learning a lot of new stuff. Great sheet ngl.
How relevant is Neetcode 150 for tech interviews in India tech interview setup?
My current mental model of a transformer:
Text β tokens β token IDs β embeddings + positional information β transformer
Embedding: what the token is.
Position: where the token is.
"The dog chased the cat" and "The cat chased the dog" contain the same tokens, but mean different things.
The order changes the meaning.
That's why positional information is important: the model needs to know not only which tokens exist, but where they appear.
When generating sinusoidal positional encodings, we use different sine and cosine frequencies across the embedding dimensions.
Some dimensions change quickly, while others change slowly.
Together, these patterns give each position a unique representation of its position.
During positional encoding, we can use sinusoidal functions to represent each position.
Sine and cosine generate different patterns across the embedding dimensions.
Each position gets a distinctive pattern, giving the transformer information about where each token appears.
Positional encoding gives each token information about its position in the sequence.
So the transformer receives both:
what the token is + where it appears
This helps it understand the order and relationships between tokens.
Moving from token embeddings to positional information.
A token embedding tells the model what a token represents, but not where it appears.
Since transformers process tokens in parallel rather than sequentially, the model needs positional information to understand their order.
@taskkeapp Yeah, these 768 dimensions represent the token really well. What blew my mind was the sheer size of the embedding matrix, and the fact that the human brain does something like this so naturally. And the lookup is clever too: token ID = row. Suddenly it feels much simpler.
The embedding dimension is the number of values used to represent each token.
50,000 tokens Γ 768 dimensions
gives a 50,000 Γ 768 embedding matrix with 38,400,000 parameters.
Each row has 768 values representing the token at that token ID. The ID simply points to that row.
Moving from tokenization to embedding was interesting.
A token ID points to a row in the embedding matrix, and that row becomes the vector representation of the token.
So instead of working with cat = 42, the model works with a high-dimensional vector associated with that token
The embedding matrix it's basically:
-> vocab size Γ embedding dimension
Vocab size = the number of tokens in the tokenizer's vocabulary.
Each row corresponds to one token, and the row contains the vector representation for that token.
Learned about token IDs and what happens after tokenization.
flow : text β tokens β token IDs
A token ID isn't the meaning or representation of the token. It's basically an index that tells the model which token it is and which row to look up in the embedding matrix.
Learning about tokenization helped me understand the "strawberry" problem.
An LLM can struggle to count the "r"s because the word may be split into multiple tokens.
The model doesn't see the original word as one unit.
More of a architectural issue than the LLM being "stupid."
Spent some time learning about BPE and how tokenizers build their vocabulary by merging frequently occurring pairs.
Also played around with tokenizers to see how normal sentences, spaces, contractions, and weird strings actually get split.