<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns:yt="http://www.youtube.com/xml/schemas/2015" xmlns:media="http://search.yahoo.com/mrss/" xmlns="http://www.w3.org/2005/Atom">
 <link rel="self" href="http://www.youtube.com/feeds/videos.xml?channel_id=UCTiWgVtEGSY4cuduJbMPblA"/>
 <id>yt:channel:TiWgVtEGSY4cuduJbMPblA</id>
 <yt:channelId>TiWgVtEGSY4cuduJbMPblA</yt:channelId>
 <title>Laxmi Kant | KGP Talkie</title>
 <link rel="alternate" href="https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA"/>
 <author>
  <name>Laxmi Kant | KGP Talkie</name>
  <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
 </author>
 <published>2015-05-18T10:09:49+00:00</published>
 <entry>
  <id>yt:video:DkbmOYIbgaM</id>
  <yt:videoId>DkbmOYIbgaM</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>Hashing and Base62 IDs: How Short Links Get Their Code</title>
  <link rel="alternate" href="https://www.youtube.com/shorts/DkbmOYIbgaM"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-19T05:30:33+00:00</published>
  <updated>2026-11-19T05:30:34+00:00</updated>
  <media:group>
   <media:title>Hashing and Base62 IDs: How Short Links Get Their Code</media:title>
   <media:content url="https://www.youtube.com/v/DkbmOYIbgaM?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i1.ytimg.com/vi/DkbmOYIbgaM/hqdefault.jpg" width="480" height="360"/>
   <media:description>Trillions of codes, yet after about 2.2 million links a collision is fifty-fifty.

Short links like bit.ly end in a tiny code, about seven characters long. How do millions of links fit into such a short code, and why don't two links get the same one?

Step 1, Base62: 26 lowercase letters, 26 uppercase letters and 10 digits, 62 characters, all safe in a URL. Seven characters give 62 to the power 7 codes, about 3.5 trillion. Even six give about 57 billion.

Step 2, hashing: run MD5 or SHA-256 on the long URL, write it in Base62, take the first seven characters. The same URL always gets the same code. But two different URLs can share those seven characters, and because of the birthday problem it happens much sooner than you'd expect: after only about 2.2 million links the odds of at least one collision reach fifty-fifty. So every new code is checked in the database; on a clash, add something and hash again.

Step 3, a counter: give every new link a unique number and write it in Base62. One million is just 4c92, four characters. No collisions, no checks.

The catch: counter codes can be guessed. The next number is someone else's link, and anyone can read them one by one, private ones too. The fix: scramble the number with a secret key, reversibly, before Base62. Or use random codes and keep the collision check.

Next: in today's System Design Interview video, design a URL shortener. Comment and tell me: hash or counter? Follow for the full series.

kgptalkie.com

#shorts #SystemDesign #URLShortener #Hashing #Base62 #BirthdayProblem #Backend #DistributedSystems #SystemDesignInterview #SoftwareEngineering #SystemDesignConcepts #KGPTalkie</media:description>
   <media:community>
    <media:starRating count="3" average="5.00" min="1" max="5"/>
    <media:statistics views="31"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:ldIvqQr4DBQ</id>
  <yt:videoId>ldIvqQr4DBQ</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>Query, Key and Value in Self-Attention | LLM Interview</title>
  <link rel="alternate" href="https://www.youtube.com/shorts/ldIvqQr4DBQ"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-18T10:30:23+00:00</published>
  <updated>2026-11-18T10:30:23+00:00</updated>
  <media:group>
   <media:title>Query, Key and Value in Self-Attention | LLM Interview</media:title>
   <media:content url="https://www.youtube.com/v/ldIvqQr4DBQ?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i1.ytimg.com/vi/ldIvqQr4DBQ/hqdefault.jpg" width="480" height="360"/>
   <media:description>Keys and values get cached. The query never does. In an LLM Interview you get exactly this question: &quot;Explain query, key and value in self-attention.&quot; Most candidates say &quot;the query is what you search for, the key is what you match, the value is what comes back, like a database&quot;. It sounds right, and it gets rejected: that is an analogy, not a mechanism.

- Where they come from: every token has one vector (say 512 numbers). The model has three learned matrices, W_Q, W_K and W_V. Multiply that one vector by all three and you get a query, a key and a value. In the original Transformer's 8 heads, each is 64 numbers. One token, three roles
- The score: take the dot product of the query of &quot;it&quot; with the key of every token. A better match gives a bigger score. Softmax turns the scores into weights, say animal 0.8, street 0.1, everything else 0.1
- The output: the new vector for &quot;it&quot; is a weighted mix of the values: 0.8 times the value of animal, plus the rest. The key is only for finding, the value is what gets passed on
- Why three separate ones: with one shared matrix for query and key, the score would be the same both ways (&quot;it&quot; looks at &quot;animal&quot; exactly as much as &quot;animal&quot; looks at &quot;it&quot;). Separate matrices allow a one-way relation. The value is separate too, because what a token is found by and what it hands over can differ
- Not a database: a database returns one exact match, attention returns a soft blend of all values. And all three matrices are learned in training
- Follow-up, why not cache the query: every new token reads the keys and values of all earlier tokens, so they are reused again and again. The query is needed once, only for the new token. Caching it buys nothing

One-line answer: one vector, three learned matrices; query · key gives the score, softmax gives the weights, a weighted mix of values is the output; query and key are separate so a relation can be one-way; only keys and values are cached.

Next LLM Interview episode: why divide by the square root of d_k? Comment and tell me, which example do you use to explain query, key and value? Follow for the full LLM Interview series.

#shorts #LLM #LLMInterview #AIInterview #InterviewPrep #SelfAttention #QueryKeyValue #Transformers #KVCache #Attention #GenAI #KGPTalkie</media:description>
   <media:community>
    <media:starRating count="6" average="5.00" min="1" max="5"/>
    <media:statistics views="250"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:7Y8qIP9Et9c</id>
  <yt:videoId>7Y8qIP9Et9c</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>Self-Attention Explained: How LLMs Know What &quot;It&quot; Means</title>
  <link rel="alternate" href="https://www.youtube.com/shorts/7Y8qIP9Et9c"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-18T05:30:34+00:00</published>
  <updated>2026-11-18T05:30:35+00:00</updated>
  <media:group>
   <media:title>Self-Attention Explained: How LLMs Know What &quot;It&quot; Means</media:title>
   <media:content url="https://www.youtube.com/v/7Y8qIP9Et9c?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i4.ytimg.com/vi/7Y8qIP9Et9c/hqdefault.jpg" width="480" height="360"/>
   <media:description>&quot;The animal didn't cross the street because it was too tired.&quot; You know &quot;it&quot; is the animal. Change one word to &quot;wide&quot; and &quot;it&quot; is the street. Here is how an LLM gets that: self-attention, step by step.

- Step 1: every token starts as a vector, its embedding plus its position. On its own it has no context, so &quot;it&quot; has exactly the same vector in both sentences
- Step 2: each token looks at all the tokens, itself included, and asks which of them matter to it. Every pair gets a relevance score
- Step 3: softmax turns the scores into weights that add up to one. Say, for &quot;it&quot;: animal 0.7, street 0.2, everything else 0.1
- Step 4: the new vector for &quot;it&quot; is a weighted mix: 70% of the animal, 20% of the street, a little of the rest. The animal now sits inside &quot;it&quot;. In the &quot;wide&quot; sentence the weights flip and the street wins
- Step 5: all of this happens at once, every token with every token, in parallel, and again in every layer, so the context gets deeper
- Common confusion: these weights are not stored anywhere in the model. They are computed fresh for every sentence, in every layer. What the model learns in training is the way to score
- And attention on its own can't see word order, which is why position encoding matters
- Illustrative on screen: the attention maps and example sentences in the opening, every vector's bars, the per-token scores, the small weights of the other tokens, and the score grid. The 0.7 / 0.2 / 0.1 split is the example from the voice-over

Next in LLM Interview: how is the score actually computed, with query, key and value? And in &quot;The trophy didn't fit in the suitcase because it was too big&quot;, what does &quot;it&quot; mean? Comment below, and follow for LLM Concepts.

kgptalkie.com

#shorts #LLM #Transformers #SelfAttention #Attention #AttentionMechanism #Softmax #GenerativeAI #MachineLearning #LLMConcepts #KGPTalkie</media:description>
   <media:community>
    <media:starRating count="6" average="5.00" min="1" max="5"/>
    <media:statistics views="156"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:lEdUTqFchc8</id>
  <yt:videoId>lEdUTqFchc8</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>AWS S3 Tutorial for Beginners: Buckets, Uploads and Presigned URLs</title>
  <link rel="alternate" href="https://www.youtube.com/watch?v=lEdUTqFchc8"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-17T10:59:08+00:00</published>
  <updated>2026-11-18T12:11:03+00:00</updated>
  <media:group>
   <media:title>AWS S3 Tutorial for Beginners: Buckets, Uploads and Presigned URLs</media:title>
   <media:content url="https://www.youtube.com/v/lEdUTqFchc8?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i1.ytimg.com/vi/lEdUTqFchc8/hqdefault.jpg" width="480" height="360"/>
   <media:description>Learn Amazon S3 step by step: create a private S3 bucket, upload files and a folder, and share one file safely with a presigned URL that expires. We explain every bucket setting (region, bucket type, namespace, Object Ownership, Block Public Access, versioning, encryption), compare storage classes, show why folders are just key prefixes, see a public request get Access Denied, check the bucket permissions, and empty and delete the bucket at the end.

Full AWS course playlist: https://www.youtube.com/playlist?list=PLFZQAZyiz1Jk

AWS hands-on series | Lesson 2: Amazon S3
Previous lesson: Amazon EC2: https://youtu.be/sVZo_M7yFEs
Next lesson: AWS Lambda: https://youtu.be/lO5ZSNk-Ilg

Chapters
0:00 Introduction and what you will learn
0:45 What S3 is: buckets, objects and keys
1:46 Create a bucket: region, type and name
3:11 Ownership, Block Public Access, versioning, encryption
4:58 Upload files
5:57 Storage classes: Standard, Infrequent Access, Glacier
6:27 Create a folder and upload into it
7:44 Folders are key prefixes
8:20 Object details: key, S3 URI and URL
8:46 Public URL: Access Denied
9:06 Who can read an object
9:40 Presigned URL: share a file with an expiry
10:50 How apps share private files
11:09 Download, permissions and the expired link
12:02 Empty and delete the bucket
13:05 Recap

What you need: an AWS account and a browser. Cost: a few KB stored for under an hour, effectively zero.

Amazon S3 documentation: https://docs.aws.amazon.com/AmazonS3/latest/userguide/Welcome.html
Presigned URLs (AWS): https://docs.aws.amazon.com/AmazonS3/latest/userguide/ShareObjectPreSignedURL.html
Storage classes (AWS): https://aws.amazon.com/s3/storage-classes/

Subscribe: https://www.youtube.com/@KGPTalkie?sub_confirmation=1

#AWSS3 #AWS #CloudStorage</media:description>
   <media:community>
    <media:starRating count="2" average="5.00" min="1" max="5"/>
    <media:statistics views="202"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:UrjFw5Q1x74</id>
  <yt:videoId>UrjFw5Q1x74</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>Design Google Drive: File Sync System Design Interview</title>
  <link rel="alternate" href="https://www.youtube.com/shorts/UrjFw5Q1x74"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-17T10:30:15+00:00</published>
  <updated>2026-11-17T10:30:16+00:00</updated>
  <media:group>
   <media:title>Design Google Drive: File Sync System Design Interview</media:title>
   <media:content url="https://www.youtube.com/v/UrjFw5Q1x74?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i2.ytimg.com/vi/UrjFw5Q1x74/hqdefault.jpg" width="480" height="360"/>
   <media:description>Laptop and phone both edit version five. One commit gets rejected. In a System Design Interview you get exactly this question: &quot;Design Google Drive.&quot;

System Design Interview, Day 011. This is a standard interview design, not Google's real architecture. Most candidates say &quot;put the files in object storage like S3, and keep the name and a link in a database&quot;. Stop there, and the interviewer has already moved on. You change one line in a 1 GB file: does the whole GB upload again? The network drops halfway: do you start over? And how do the other devices find out?

- Step 1: separate data from metadata. File chunks, say 4 MB each, go into object storage, named by their hash. A database holds folders, files, versions, permissions, and the list of chunks for every version
- Step 2: the upload flow. The client cuts the file, hashes every chunk, and asks the metadata service which are new. 1 GB is about 256 chunks; after an edit only two changed, so the upload is just 8 MB. Chunks go straight into storage with signed URLs, not through the app servers, then the client commits a new version with the new chunk list
- Step 3: resumable uploads. Every chunk travels on its own. If the network drops at chunk 180, continue from 181
- Step 4: the other devices. Each keeps a connection open to a notification service, with long polling or a WebSocket. When a commit lands, a push goes out: &quot;this folder changed&quot;. The device asks what changed since its last version and fetches only the missing chunks. Offline for two days? Same question, with its last version number
- Conflicts: a commit carries a condition, &quot;update only if the current version is still five&quot;. The phone gets there first and becomes version six. The laptop's commit is rejected, and its edit is saved next to it as a conflicted copy. Nobody's work is lost

The answer that gets you selected: data and metadata apart, chunks named by hash, upload only the changed chunks, resumable transfers, a push then a version-based sync, and conditional commits for conflicts.

Next System Design Interview episode: design a URL shortener. Comment below: have you ever ended up with a conflicted copy?

kgptalkie.com

#shorts #SystemDesign #SystemDesignInterview #GoogleDrive #FileSync #ObjectStorage #Dropbox #BackendInterview #InterviewPrep #SoftwareEngineering #DistributedSystems #KGPTalkie</media:description>
   <media:community>
    <media:starRating count="22" average="5.00" min="1" max="5"/>
    <media:statistics views="496"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:y8st9meT2Tg</id>
  <yt:videoId>y8st9meT2Tg</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>File Chunking and Sync: Copy a File, 0 Chunks Upload</title>
  <link rel="alternate" href="https://www.youtube.com/shorts/y8st9meT2Tg"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-17T05:30:28+00:00</published>
  <updated>2026-11-17T05:30:28+00:00</updated>
  <media:group>
   <media:title>File Chunking and Sync: Copy a File, 0 Chunks Upload</media:title>
   <media:content url="https://www.youtube.com/v/y8st9meT2Tg?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i2.ytimg.com/vi/y8st9meT2Tg/hqdefault.jpg" width="480" height="360"/>
   <media:description>You copy a big file into another folder, and not a single chunk uploads. How?

You change one line in a 100 MB file on your laptop, and a few seconds later your phone has it. The whole 100 MB did not upload again.

Step 1, chunks: the file is split into fixed-size pieces. At 4 MB each, a 100 MB file is 25 chunks.

Step 2, hashes: every chunk gets a fingerprint, a hash such as SHA-256. Same content, same hash. Change one byte and the hash changes completely. The file becomes an ordered list of 25 hashes, called a manifest.

Step 3, send only what's new: before uploading, the client asks the server which hashes are missing. Change one paragraph and only one chunk changes, so 4 MB goes up, not 100. Copy the same file into another folder and no chunk uploads at all. That's deduplication.

Step 4, tell the other devices: the new manifest is saved on the server. Your phone keeps a connection open, the server says &quot;this file changed&quot;, the phone fetches the manifest, compares hashes and downloads only the missing chunk.

The catch: with fixed-size chunks, add one byte at the start and every boundary shifts, so all 25 hashes change and the whole file uploads again. The fix is content-defined chunking: a rolling hash scans the bytes and cuts wherever the value matches a pattern. Boundaries are set by the content, not the size, so after an insert only the nearby chunk changes.

Next: two devices change the same file while offline. That's today's System Design Interview question: design Google Drive. Comment and tell me, how many GB is your biggest synced file? Follow for the full series.

kgptalkie.com

#shorts #SystemDesign #FileSync #Chunking #Deduplication #Hashing #SHA256 #GoogleDrive #Backend #DistributedSystems #SystemDesignConcepts #KGPTalkie</media:description>
   <media:community>
    <media:starRating count="5" average="5.00" min="1" max="5"/>
    <media:statistics views="170"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:wRGJTJjKaMA</id>
  <yt:videoId>wRGJTJjKaMA</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>Sinusoidal vs Learned vs RoPE | LLM Interview</title>
  <link rel="alternate" href="https://www.youtube.com/shorts/wRGJTJjKaMA"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-16T10:30:03+00:00</published>
  <updated>2026-11-16T10:30:03+00:00</updated>
  <media:group>
   <media:title>Sinusoidal vs Learned vs RoPE | LLM Interview</media:title>
   <media:content url="https://www.youtube.com/v/wRGJTJjKaMA?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i4.ytimg.com/vi/wRGJTJjKaMA/hqdefault.jpg" width="480" height="360"/>
   <media:description>Shift two tokens a hundred positions ahead. The score doesn't change. In an LLM Interview you get exactly this question: &quot;What's the difference between sinusoidal, learned and RoPE position encoding? And why do today's models use RoPE?&quot; Most candidates say &quot;sinusoidal is fixed, learned is trained, RoPE is newer&quot;, and that won't get you selected. The interviewer wants three things: where position goes in, how long it can stretch, and whether it's absolute or relative.

- Sinusoidal: each pair of dimensions gets a sine and a cosine at its own frequency, fast to very slow. Added to the embedding at the input, zero parameters, works for any position. A shift of k positions is a rotation, but position and content get mixed into one vector, and quality still drops past the training length
- Learned: a table. BERT base has 512 positions × 768 numbers, about 400,000 parameters. Flexible, but there is no row at all for position 513
- RoPE: adds nothing to the embedding. In every layer it rotates each pair of query and key by an angle set by position. At ten degrees per position, query at 3 turns 30°, key at 7 turns 70°, and the score only sees the 40° gap. Shift both by 100 and the score is the same. Relative position goes straight into attention with no parameters, which is why Llama, Mistral and Qwen use it
- Follow-up, longer than training: not for free. The slow pairs reach angles they never saw. The fix: position interpolation (trained on 4,000, want 16,000, divide every position by 4) plus a little fine-tuning, or stretch the frequencies with NTK-aware scaling or YaRN

One-line answer: sinusoidal is fixed waves added at the input, learned is a table with a hard limit, RoPE rotates query and key so distance goes straight into the score, and it stretches with interpolation.

Next LLM Interview episode: query, key and value in self-attention. Comment and tell me, which position encoding does your favourite model use? Follow for the full LLM Interview series.

#shorts #LLM #LLMInterview #AIInterview #InterviewPrep #PositionalEncoding #RoPE #Transformers #Attention #GenAI #MachineLearning #KGPTalkie</media:description>
   <media:community>
    <media:starRating count="6" average="5.00" min="1" max="5"/>
    <media:statistics views="204"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:Ka76trq6oZc</id>
  <yt:videoId>Ka76trq6oZc</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>Position Encoding Types: Sinusoidal, Learned, ALiBi, RoPE</title>
  <link rel="alternate" href="https://www.youtube.com/shorts/Ka76trq6oZc"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-16T05:30:36+00:00</published>
  <updated>2026-11-16T05:30:37+00:00</updated>
  <media:group>
   <media:title>Position Encoding Types: Sinusoidal, Learned, ALiBi, RoPE</media:title>
   <media:content url="https://www.youtube.com/v/Ka76trq6oZc?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i4.ytimg.com/vi/Ka76trq6oZc/hqdefault.jpg" width="480" height="360"/>
   <media:description>Position 513? BERT has no row for it at all. Here are the four main ways an LLM knows where each token stands, and where each one breaks.

- Why it's needed: attention on its own can't see order, so &quot;dog bites man&quot; and &quot;man bites dog&quot; look the same until every token is told its position
- 1 Sinusoidal: the original Transformer (2017) gives each position a fixed vector built from sine and cosine waves, added to the embedding. The first dimensions spin fast, the last ones very slowly, like the hands of a clock. Wavelengths run from about 6 to about 60,000 positions, with no parameters to learn
- 2 Learned: a table with one row per position, trained just like word embeddings. BERT has 512 positions and GPT-2 has 1,024. Simple, but the limit is hard: there is no row past the last one
- Sinusoidal and learned are absolute: each token gets an address. In language, what often matters is distance
- 3 ALiBi: nothing is added to the embedding. A penalty is subtracted from each attention score, and it grows with distance, so nearby tokens get more attention and far ones less
- 4 RoPE (rotary position embedding), used by Llama and most open models: rotates the query and key by an angle set by position. Shift both tokens by the same amount and the gap stays the same, so position enters the score only as distance
- Common confusion: sinusoidal and learned are added once at the input. RoPE adds nothing: it is applied in every layer, only to queries and keys, not to values
- Illustrative on screen: the clock analogy, 10° per position (real RoPE uses a different angle per dimension pair), positions 3 and 7, the shift of 100, wave sizes and the sampled values, table cell colours, the example sentences, &quot;3 back&quot;, the score and penalty bar lengths, and the layer stack

Next in LLM Interview: how would you compare sinusoidal, learned and RoPE? What made it click for you, the clock or the rotation? Comment below, and follow for LLM Concepts.

kgptalkie.com

#shorts #LLM #Transformers #PositionalEncoding #RoPE #ALiBi #Attention #BERT #GenerativeAI #MachineLearning #LLMConcepts #KGPTalkie</media:description>
   <media:community>
    <media:starRating count="2" average="5.00" min="1" max="5"/>
    <media:statistics views="157"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:sVZo_M7yFEs</id>
  <yt:videoId>sVZo_M7yFEs</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>AWS EC2 Tutorial for Beginners: Launch a Linux Instance and SSH</title>
  <link rel="alternate" href="https://www.youtube.com/watch?v=sVZo_M7yFEs"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-15T10:30:14+00:00</published>
  <updated>2026-11-18T08:39:20+00:00</updated>
  <media:group>
   <media:title>AWS EC2 Tutorial for Beginners: Launch a Linux Instance and SSH</media:title>
   <media:content url="https://www.youtube.com/v/sVZo_M7yFEs?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i4.ytimg.com/vi/sVZo_M7yFEs/hqdefault.jpg" width="480" height="360"/>
   <media:description>Learn AWS EC2 step by step: launch a small Amazon Linux server and understand every setting (AMI, instance type, key pair, security group, 8 GB storage), connect from the browser with EC2 Instance Connect and from Windows PowerShell with SSH, fix the common unprotected private key file error, inspect the running machine, stop and start it to see the public IP change, and terminate it and delete its security group and key pair at the end.

Full AWS course playlist: https://www.youtube.com/playlist?list=PLFZQAZyiz1Jk

AWS hands-on series | Lesson 1: Amazon EC2
Next lesson: Amazon S3: https://youtu.be/lEdUTqFchc8

Chapters
0:00 Introduction: what you will build
0:35 What EC2 is and what you pick
1:02 The EC2 console and the launch form
1:51 Choose an AMI: Windows, macOS or Amazon Linux
2:56 Instance type: CPUs, memory and price
3:33 Create a key pair
4:19 Network and security group rules
6:04 Storage: the 8 GB root disk
6:27 Review, launch and instance details
8:03 Connect from the browser with Instance Connect
8:58 SSH from Windows PowerShell
9:32 Fix the Windows key permission error
10:38 Inspect the Linux machine
11:48 Stop and start: the public IP changes
12:59 Clean up: instance, security group, key pair
14:34 Recap

Commands used
ssh -i key.pem ec2-user@your-public-dns
icacls key.pem /inheritance:r /grant:r &quot;$(whoami):R&quot;

What you need: an AWS account and a browser (PowerShell on Windows for the SSH part). Cost: a t3.micro for under an hour, about one cent.

Amazon EC2 documentation: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/concepts.html
Fix SSH key permissions (AWS): https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesConnecting.html
EC2 pricing: https://aws.amazon.com/ec2/pricing/on-demand/

Subscribe: https://www.youtube.com/@KGPTalkie?sub_confirmation=1

#AWSEC2 #AWS #Linux</media:description>
   <media:community>
    <media:starRating count="4" average="5.00" min="1" max="5"/>
    <media:statistics views="267"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:EVU1wriSFI0</id>
  <yt:videoId>EVU1wriSFI0</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>Claude Usage Tracker System Design: 5-Hour + Weekly Limits</title>
  <link rel="alternate" href="https://www.youtube.com/shorts/EVU1wriSFI0"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-15T08:30:32+00:00</published>
  <updated>2026-11-15T08:30:33+00:00</updated>
  <media:group>
   <media:title>Claude Usage Tracker System Design: 5-Hour + Weekly Limits</media:title>
   <media:content url="https://www.youtube.com/v/EVU1wriSFI0?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i2.ytimg.com/vi/EVU1wriSFI0/hqdefault.jpg" width="480" height="360"/>
   <media:description>You're deep in a Claude Code session, and then: &quot;You've hit your session limit.&quot; On the Max plan there's a limit every five hours and another every week, and the Claude app eats into the same limits. In a System Design Interview, you get exactly this question: Design Claude Usage Tracker.

Most candidates say &quot;read the local logs, add up the tokens, and divide by the limit&quot;. Anthropic publishes no token number for these limits, they change, and your laptop can't see what you did on another machine or in the Claude app.

- Fix 1: don't count. Claude Code hands a status line script your percent used and the reset time for both windows. The tracker only records the official number
- Fix 2: a tiny collector. Send a sample only when the percent changes: account, window, percent, reset time. Your prompts and code never leave the machine
- Fix 3: the merge. Key each window by its reset time. Inside a window usage only goes up, so keep the highest value. Last write wins makes the bar jump backwards
- Fix 4: the forecast. At 60% with two hours left, burning 30% an hour, you hit the limit 40 minutes before the reset. Warn now
- Fix 5: alerts that fire once. Key each alert by window and threshold, and check both windows, because sometimes the weekly limit hits first
- The follow-up: Claude Code is closed and the user is in the Claude app. Samples only arrive when Claude Code replies, so show the number with its age. A timer clears the bar at the reset, and Max's separate weekly Fable limit shows as not tracked

The answer that gets you selected: read the official percent, send only numbers, merge by reset time, forecast from the burn rate, alert once per window, and always show how old the number is.

This is a standard interview design, not a claim about how Anthropic built anything. The percents in the video are examples.

Comment and tell me: which limit do you hit first, the five-hour one or the weekly one?

kgptalkie.com

#shorts #SystemDesign #SystemDesignInterview #ClaudeCode #Claude #UsageTracker #RateLimits #BackendInterview #InterviewPrep #SoftwareEngineering #AI #KGPTalkie</media:description>
   <media:community>
    <media:starRating count="12" average="5.00" min="1" max="5"/>
    <media:statistics views="715"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:Yp9oQYl2KoQ</id>
  <yt:videoId>Yp9oQYl2KoQ</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>NVIDIA NIM Free API Key: Free Models on build.nvidia.com (Nemotron, DeepSeek)</title>
  <link rel="alternate" href="https://www.youtube.com/watch?v=Yp9oQYl2KoQ"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-14T21:00:27+00:00</published>
  <updated>2026-11-17T21:45:22+00:00</updated>
  <media:group>
   <media:title>NVIDIA NIM Free API Key: Free Models on build.nvidia.com (Nemotron, DeepSeek)</media:title>
   <media:content url="https://www.youtube.com/v/Yp9oQYl2KoQ?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i2.ytimg.com/vi/Yp9oQYl2KoQ/hqdefault.jpg" width="480" height="360"/>
   <media:description>Get a free NVIDIA NIM API key on build.nvidia.com and call big open models like Nemotron 3 Super and DeepSeek V4.1 Flash for free, from curl, Python and Open WebUI. Day 14 of the Free AI Setup series: one free AI tool a day, set up step by step.

Watch the whole series in order: https://www.youtube.com/playlist?list=PLfUBzZXRNC-k
Previous, day 13, Claude Code with OpenRouter free models: https://youtu.be/LTdZ2sN1yqc
Next, day 15, Google AI Studio free API key: https://youtu.be/WNaVmcZv36o

What you need: a browser and an email address for a free NVIDIA account (NVIDIA Developer Program). No graphics card, because the models run on NVIDIA's servers. PowerShell for the curl call, and Python for the code example.

In this video:
- Find the free models: the Free Endpoint filter on build.nvidia.com/models, and the /v1/models list (no key needed)
- Two models to start with: Nemotron 3 Super (124B, NVIDIA's own) and DeepSeek V4.1 Flash (552B, only 8B active per token, reads images)
- Generate your API key from a model page and store it as NVIDIA_API_KEY
- First call with curl.exe in PowerShell
- The error messages decoded: 404 page not found, Missing request extension, 403 Authorization failed
- Python with the OpenAI SDK: base URL integrate.api.nvidia.com/v1, streaming
- Why popular models queue on the free endpoints, and which models answer in seconds
- The thinking switch (enable_thinking) for faster answers
- Image input: DeepSeek V4.1 Flash reads a chart
- Use the key in Open WebUI as an OpenAI connection
- Free limits from NVIDIA's site and three key safety rules

Chapters:
0:00 Intro: a free key for huge models
0:29 Day 14 of 30 and what NVIDIA NIM is
0:54 What you need
1:14 Step 1: Find the free models
1:42 Step 2: Choose a model
2:01 Step 3: Create your API key
2:44 Step 4: Store the key in an environment variable
3:28 Step 5: First call with curl.exe
4:43 Step 6: Fix the common errors
5:26 Step 7: Python with the OpenAI SDK
6:33 Step 8: Turn off thinking
6:54 Step 9: Send a picture
7:27 Step 10: Use the key in Open WebUI
8:30 The free limits and key safety
9:01 ChatGPT Plus vs NVIDIA free
9:21 Next: Google AI Studio

Links
NVIDIA build (models and keys): https://build.nvidia.com/models
API keys page: https://build.nvidia.com/settings/api-keys
NIM API quickstart: https://docs.api.nvidia.com/nim/docs/api-quickstart
NIM API reference: https://docs.api.nvidia.com/nim/reference/llm-apis
Open WebUI docs: https://docs.openwebui.com

Day 16 of this series uses this same key with Hermes Agent.
Tomorrow, day 15: a free Google AI Studio key for Gemini.

New free AI tool every day. Subscribe so you don't miss one: https://www.youtube.com/@KGPTalkie?sub_confirmation=1</media:description>
   <media:community>
    <media:starRating count="10" average="5.00" min="1" max="5"/>
    <media:statistics views="841"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:q0ALcNXMBPY</id>
  <yt:videoId>q0ALcNXMBPY</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>Gemini 4 Hydrogen Built 5 3D Games in One Shot. One Is Secretly Broken</title>
  <link rel="alternate" href="https://www.youtube.com/watch?v=q0ALcNXMBPY"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-14T17:54:23+00:00</published>
  <updated>2026-11-18T11:22:12+00:00</updated>
  <media:group>
   <media:title>Gemini 4 Hydrogen Built 5 3D Games in One Shot. One Is Secretly Broken</media:title>
   <media:content url="https://www.youtube.com/v/q0ALcNXMBPY?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i2.ytimg.com/vi/q0ALcNXMBPY/hqdefault.jpg" width="480" height="360"/>
   <media:description>I gave Gemini 4 Hydrogen five 3D games to build in Google Antigravity: a car racing game, a Minecraft style block world, ten pin bowling, a space shooter and a Rubik's cube that solves itself. One prompt each, no second chance, and the agent was not allowed to run or fix its own code. Four of the five really work. One looks perfect and is completely wrong. The score is at the end.

Every game was checked by my own test script, not by the model's word: race simulations, world statistics, six real bowling score sheets, autopilot space battles and twenty cube scrambles checked with my own cube simulator.

All five prompts are in the pinned comment, so you can try them yourself.

Chapters
0:00 Five games, one shot each
0:30 The setup and the rules
0:59 Test 1: car racing
1:44 Test 2: block world
2:25 Test 3: ten pin bowling
3:21 Test 4: space shooter
3:55 Test 5: self solving Rubik's cube
4:58 The score and my take

Subscribe for more AI coding tests: https://www.youtube.com/@KGPTalkie?sub_confirmation=1

#Gemini #Antigravity #AICoding</media:description>
   <media:community>
    <media:starRating count="5" average="5.00" min="1" max="5"/>
    <media:statistics views="419"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:RjuyACyMKI8</id>
  <yt:videoId>RjuyACyMKI8</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>PayPal System Design: Double-Entry Ledger and Idempotency</title>
  <link rel="alternate" href="https://www.youtube.com/shorts/RjuyACyMKI8"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-14T08:30:19+00:00</published>
  <updated>2026-11-17T21:48:26+00:00</updated>
  <media:group>
   <media:title>PayPal System Design: Double-Entry Ledger and Idempotency</media:title>
   <media:content url="https://www.youtube.com/v/RjuyACyMKI8?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i3.ytimg.com/vi/RjuyACyMKI8/hqdefault.jpg" width="480" height="360"/>
   <media:description>You send fifty dollars on PayPal. The screen hangs, so you tap Send again. Did your friend just get a hundred? PayPal handled 6.8 billion payments last quarter, and every one has to move exactly once. In a System Design Interview you get exactly this question: &quot;Design PayPal Payment System.&quot;

Most candidates say &quot;keep a balance column, subtract from the sender, add to the receiver&quot;. If the server crashes between those two updates, the money vanishes, and with only a balance nobody can prove where it went.

- Fix 1: a double-entry ledger. Every payment writes two lines, a debit and a credit. The ledger always nets to zero, and a balance is just the sum of an account's entries
- Fix 2: atomic and append-only. Both lines commit in one transaction, or neither does. Posted entries are never edited: a refund is a new entry in the opposite direction
- Fix 3: the idempotency key. One unique key per payment, the same key on every retry, saved in the same transaction as the ledger lines. Your second tap just gets the first result. PayPal's own API works like this with PayPal-Request-Id
- Fix 4: stop the double spend. Two payments of $50 hit a $60 wallet in the same millisecond. Lock the wallet row, check the balance, then write. The second payment sees $10 and fails
- Fix 5: held money. PayPal can hold a payment for up to 21 days to cover disputes, so each wallet gets two accounts, available and held, and a release is one more ledger entry
- The follow-up: a withdrawal to the bank times out. Did the money leave? You don't know. Never mark it failed, never send a fresh request. Keep it pending, retry with the same key, ask the bank for the status, and match your ledger against the bank's file every day. A mismatch gets a correcting entry, never an edit

Say this in the round and you stand out: a double-entry ledger, atomic and append-only, one idempotency key per payment, a lock on each wallet, held money as its own account, and daily reconciliation.

This is a standard interview design, not a claim about PayPal's real architecture.

Comment and tell me: has a payment of yours ever said failed, while the money still left?

kgptalkie.com

#shorts #SystemDesign #SystemDesignInterview #PayPal #PaymentSystem #DoubleEntry #Idempotency #Ledger #BackendInterview #InterviewPrep #SoftwareEngineering #KGPTalkie</media:description>
   <media:community>
    <media:starRating count="14" average="5.00" min="1" max="5"/>
    <media:statistics views="521"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:mPD1IPENsuI</id>
  <yt:videoId>mPD1IPENsuI</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>Microsoft Outage Explained: Why Every Restart Crashed</title>
  <link rel="alternate" href="https://www.youtube.com/shorts/mPD1IPENsuI"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-13T23:30:30+00:00</published>
  <updated>2026-11-18T08:09:28+00:00</updated>
  <media:group>
   <media:title>Microsoft Outage Explained: Why Every Restart Crashed</media:title>
   <media:content url="https://www.youtube.com/v/mPD1IPENsuI?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i2.ytimg.com/vi/mPD1IPENsuI/hqdefault.jpg" width="480" height="360"/>
   <media:description>On November 12th, Outlook, Teams and Copilot stopped working in offices around the world. Downdetector got about 130,000 reports for Outlook alone. Engineers restarted the servers, they came back healthy, and the moment users returned, they went down again. Why did every restart fail?

- Not a cyber attack, not a traffic spike: Microsoft found no sign of malicious activity, and the load was not caused by more traffic
- The trigger: a network change made during an earlier capacity upgrade. Servers began failing their automated health checks
- The load balancer's rule: fail the health check, leave the pool. Removed servers' work moved onto the servers that were left
- The villain: the process that sets up secure connections. A new TLS handshake needs heavy public-key math; an open connection runs on cheap symmetric encryption. Too many new connections on too few servers, and it was overwhelmed
- The twist: a restarted server looks perfect with no traffic. Open the gate, every offline app reconnects at once, each needing a fresh handshake, and it goes down again. That's a thundering herd
- The fix: revert the network change, bypass the health check on some servers, throttle traffic, rebuild some servers on an older configuration. Recovery still took more than a day

System Design Interview takeaways:
1. A health check can turn a small fault into a big outage, so cap how many servers it can remove at once
2. New TLS connections are expensive, so clients retry with backoff and random jitter, never all together
3. After an outage, bring traffic back slowly

Comment and tell me: when Outlook went down, what did your office do?

Based on Microsoft's public status updates; the final root-cause report is still to come.

kgptalkie.com

#shorts #Microsoft365 #MicrosoftOutage #OutlookDown #TeamsDown #SystemDesign #SystemDesignInterview #LoadBalancer #TLS #KGPTalkie</media:description>
   <media:community>
    <media:starRating count="108" average="5.00" min="1" max="5"/>
    <media:statistics views="3249"/>
   </media:community>
  </media:group>
 </entry>
 <entry>
  <id>yt:video:LifQshNdtDE</id>
  <yt:videoId>LifQshNdtDE</yt:videoId>
  <yt:channelId>UCTiWgVtEGSY4cuduJbMPblA</yt:channelId>
  <title>ChatGPT System Design | API Gateway, SSE Streaming, KV Cache, Admission Control</title>
  <link rel="alternate" href="https://www.youtube.com/shorts/LifQshNdtDE"/>
  <author>
   <name>Laxmi Kant | KGP Talkie</name>
   <uri>https://www.youtube.com/channel/UCTiWgVtEGSY4cuduJbMPblA</uri>
  </author>
  <published>2026-11-13T10:30:38+00:00</published>
  <updated>2026-11-16T23:28:06+00:00</updated>
  <media:group>
   <media:title>ChatGPT System Design | API Gateway, SSE Streaming, KV Cache, Admission Control</media:title>
   <media:content url="https://www.youtube.com/v/LifQshNdtDE?version=3" type="application/x-shockwave-flash" width="640" height="390"/>
   <media:thumbnail url="https://i1.ytimg.com/vi/LifQshNdtDE/hqdefault.jpg" width="480" height="360"/>
   <media:description>You hit stop. The GPU keeps writing anyway, for no one. In a System Design Interview you get exactly this question: &quot;Design ChatGPT.&quot;

System Design Interview, Day 010. Most candidates say &quot;put the model behind an API, and autoscale it&quot;. One line like that, and the round slips away. GPUs are expensive, a new GPU server takes minutes to load the model, and how many users fit depends on GPU memory, not CPU.

- Fix 1: the request path. An API gateway checks login and rate limits. The chat service loads the conversation history and trims it to the context window. A queue and a router pick a GPU replica with free capacity. The inference server generates tokens, streamed to the user over SSE, and the finished message is saved to the conversation store
- Fix 2: the GPU memory math. Say a GPU has 80 GB. The weights take 40. About 30 GB of the rest goes to the KV cache. If one long chat needs about 1 GB, that's about 30 long chats at once per GPU. Capacity comes from this memory, not from requests per second
- Fix 3: admission control and priority. When every slot is full, new requests wait in a queue instead of crashing the server, and paid users get priority. Count rate limits in tokens, not requests: one request can be 10 tokens, or 10,000
- Fix 4: prefix caching. Every request starts with the same system prompt, so build its KV cache once and reuse it. In long chats, trim the old turns or summarize them
- The follow-up: the user hits stop mid-answer, or closes the tab. In a simple design the GPU keeps generating to the end, for nobody. Catch the closed connection or the stop request at the gateway, pass the cancel to the inference server, drop the request from the batch and free its KV slot right away. Save the partial answer, so the next message has the right context

Put together, a strong answer: a clean path from the gateway to SSE, the GPU memory math, token-based rate limits and priority, prefix caching, and a cancel on stop that frees the KV slot.

Next System Design Interview episode: design Google Drive. Comment and tell me: when ChatGPT goes off track, do you hit stop?

kgptalkie.com

#shorts #SystemDesign #SystemDesignInterview #ChatGPT #LLMInference #KVCache #GPU #BackendInterview #InterviewPrep #SoftwareEngineering #DistributedSystems #KGPTalkie</media:description>
   <media:community>
    <media:starRating count="24" average="5.00" min="1" max="5"/>
    <media:statistics views="893"/>
   </media:community>
  </media:group>
 </entry>
</feed>
