<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" xmlns:googleplay="http://www.google.com/schemas/play-podcasts/1.0"><channel><title><![CDATA[The Palindrome]]></title><description><![CDATA[mathematics ∪ machine learning]]></description><link>https://thepalindrome.org</link><image><url>https://substackcdn.com/image/fetch/$s_!5Jm3!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff8b68cf8-d3f4-42f6-b8dd-cccde036005f_720x720.png</url><title>The Palindrome</title><link>https://thepalindrome.org</link></image><generator>Substack</generator><lastBuildDate>Tue, 12 May 2026 16:42:37 GMT</lastBuildDate><atom:link href="https://thepalindrome.org/feed" rel="self" type="application/rss+xml"/><copyright><![CDATA[Tivadar Danka]]></copyright><language><![CDATA[en]]></language><webMaster><![CDATA[thepalindrome@substack.com]]></webMaster><itunes:owner><itunes:email><![CDATA[thepalindrome@substack.com]]></itunes:email><itunes:name><![CDATA[Tivadar Danka]]></itunes:name></itunes:owner><itunes:author><![CDATA[Tivadar Danka]]></itunes:author><googleplay:owner><![CDATA[thepalindrome@substack.com]]></googleplay:owner><googleplay:email><![CDATA[thepalindrome@substack.com]]></googleplay:email><googleplay:author><![CDATA[Tivadar Danka]]></googleplay:author><itunes:block><![CDATA[Yes]]></itunes:block><item><title><![CDATA[Introduction to Object-Oriented Programming in Python]]></title><description><![CDATA[The true way of doing stuff with data]]></description><link>https://thepalindrome.org/p/introduction-to-object-oriented-programming</link><guid isPermaLink="false">https://thepalindrome.org/p/introduction-to-object-oriented-programming</guid><dc:creator><![CDATA[Stephen Gruppetta]]></dc:creator><pubDate>Fri, 08 May 2026 12:29:01 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/4dfc98cb-b18b-4311-b358-ed04e8491619_1672x941.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hey!</p><p>It&#8217;s Tivadar from The Palindrome. Back when I wrote the <em>Mathematics of Machine Learning</em> book, I realized</p><ol><li><p>what a great language Python is,</p></li><li><p>and that object-oriented Python should be the first thing taught to every machine learning engineer.</p></li></ol><p>So, I&#8217;ve been thinking about publishing a series, but my Python skills are not exactly top-of-the-line; I just hack and slash until things work. Fortunately, I found the best person who could do that, and even better, he agreed to write a special article for you!</p><p>It&#8217;s my pleasure to introduce <span class="mention-wrap" data-attrs="{&quot;name&quot;:&quot;Stephen Gruppetta&quot;,&quot;id&quot;:120170782,&quot;type&quot;:&quot;user&quot;,&quot;url&quot;:null,&quot;photo_url&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/ca736a83-f5a1-4563-ac6c-c09a9e6fa351_800x800.png&quot;,&quot;uuid&quot;:&quot;4a700fa6-f573-43a7-bb02-df1279787ada&quot;}" data-component-name="MentionToDOM"></span>, author of <span class="mention-wrap" data-attrs="{&quot;name&quot;:&quot;The Python Coding Stack&quot;,&quot;id&quot;:1563052,&quot;type&quot;:&quot;pub&quot;,&quot;url&quot;:&quot;https://open.substack.com/pub/thepythoncodingstack&quot;,&quot;photo_url&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/ab4a59e8-e362-456b-8427-934e87c31a0d_600x600.png&quot;,&quot;uuid&quot;:&quot;26bcf8de-47da-4533-a58b-b49266ccd00c&quot;}" data-component-name="MentionToDOM"></span>, and my longtime online friend from back when X was called Twitter.</p><p>If you ever wanted to become a power user of Python and take advantage of all the heavy machinery provided by classes, operator overloading, inheritance, composition, etc., this is the article for you.</p><p>Dig in!</p><p>Cheers,<br>Tivadar</p><div><hr></div><p><em>&#8220;A computer program stores data and does stuff with the data.&#8221;</em></p><p>This is not the most technical definition of a computer program you&#8217;ll see. But it&#8217;s a valid one. When you learn to code, you learn about data structures to store different types of data. And you also learn about tools needed to manipulate and transform the data. You often define functions containing code to &#8220;do stuff&#8221; with the data.</p><p>Your code will contain data structures and functions, and you pass those data structures to the functions when needed.</p><p>Object-oriented programming (OOP) brings these two aspects together into a single unit. This unit is the object, which contains the data and the tools needed to manipulate the data. This may not sound like much, but it enables you to think about the problem you&#8217;re trying to solve differently. You can visualize your problem in a way closer to how humans see the world.</p><p>Let&#8217;s look at some examples, starting with a concrete one. Consider a country. There&#8217;s plenty of data relevant to a country: its name, population size, geographical area, capital city, and more. All countries have these attributes. Therefore, you can create a template that includes these attributes that you can use each time you want to represent a different country. Countries also include people, so these can be included in the data for each country, too.</p><p>But countries also perform actions. They issue passports, they collect taxes, they create laws, and so on. OOP urges you to think of a single unit to represent a country, which includes all the data and tools needed for the country to perform the actions required. You&#8217;d create a class called Country&#8211;this is the template you need to create lots of countries. The class doesn&#8217;t represent a specific country but the idea of a country. Once you define the class, you can create as many instances of the class as you need. Each instance represents a specific country.</p><h2>Classes and Instances &#8226; The Vector Class</h2><p>But let&#8217;s work on a different example in this article. Let&#8217;s consider a vector. One way to view vectors is as entities with both magnitude and direction. In three-dimensional (3D) Euclidean geometry, a vector is represented by three numbers.</p><p>Let&#8217;s put on our OOP hat. We need a unit in our program to represent a vector. It needs to represent its data and its functionality. Let&#8217;s start by creating a class called Vector:</p><div class="captioned-image-container"><figure><a class="image-link image2" target="_blank" href="https://substackcdn.com/image/fetch/$s_!u3p3!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F91aa0151-710d-4297-8136-508e350e1718_2120x428.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!u3p3!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F91aa0151-710d-4297-8136-508e350e1718_2120x428.png 424w, https://substackcdn.com/image/fetch/$s_!u3p3!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F91aa0151-710d-4297-8136-508e350e1718_2120x428.png 848w, https://substackcdn.com/image/fetch/$s_!u3p3!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F91aa0151-710d-4297-8136-508e350e1718_2120x428.png 1272w, https://substackcdn.com/image/fetch/$s_!u3p3!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F91aa0151-710d-4297-8136-508e350e1718_2120x428.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!u3p3!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F91aa0151-710d-4297-8136-508e350e1718_2120x428.png" width="1456" height="294" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/91aa0151-710d-4297-8136-508e350e1718_2120x428.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:294,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;code&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="code" title="code" srcset="https://substackcdn.com/image/fetch/$s_!u3p3!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F91aa0151-710d-4297-8136-508e350e1718_2120x428.png 424w, https://substackcdn.com/image/fetch/$s_!u3p3!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F91aa0151-710d-4297-8136-508e350e1718_2120x428.png 848w, https://substackcdn.com/image/fetch/$s_!u3p3!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F91aa0151-710d-4297-8136-508e350e1718_2120x428.png 1272w, https://substackcdn.com/image/fetch/$s_!u3p3!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F91aa0151-710d-4297-8136-508e350e1718_2120x428.png 1456w" sizes="100vw" loading="lazy"></picture><div></div></div></a></figure></div><p>Admittedly, this class doesn&#8217;t do much for now. The ellipsis (...) is just a placeholder that&#8217;s valid Python syntax. You&#8217;ll add more to this class soon. In the previous section, I mentioned that a class is a template for creating many objects modelled from the same blueprint. Let&#8217;s create a few instances of this class:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!V99G!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F71034348-fb22-4f22-a654-2652fab011c1_2120x611.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!V99G!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F71034348-fb22-4f22-a654-2652fab011c1_2120x611.png 424w, https://substackcdn.com/image/fetch/$s_!V99G!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F71034348-fb22-4f22-a654-2652fab011c1_2120x611.png 848w, https://substackcdn.com/image/fetch/$s_!V99G!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F71034348-fb22-4f22-a654-2652fab011c1_2120x611.png 1272w, https://substackcdn.com/image/fetch/$s_!V99G!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F71034348-fb22-4f22-a654-2652fab011c1_2120x611.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!V99G!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F71034348-fb22-4f22-a654-2652fab011c1_2120x611.png" width="1456" height="420" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/71034348-fb22-4f22-a654-2652fab011c1_2120x611.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:420,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;code&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="code" title="code" srcset="https://substackcdn.com/image/fetch/$s_!V99G!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F71034348-fb22-4f22-a654-2652fab011c1_2120x611.png 424w, https://substackcdn.com/image/fetch/$s_!V99G!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F71034348-fb22-4f22-a654-2652fab011c1_2120x611.png 848w, https://substackcdn.com/image/fetch/$s_!V99G!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F71034348-fb22-4f22-a654-2652fab011c1_2120x611.png 1272w, https://substackcdn.com/image/fetch/$s_!V99G!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F71034348-fb22-4f22-a654-2652fab011c1_2120x611.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>There&#8217;s only one Vector class. But now you have two instances of this class. You create an instance of the class when you add parentheses after the class name. The objects referenced by v1 and v2 are separate objects that occupy different areas of your computer&#8217;s memory. You can confirm that they&#8217;re different objects by showing their identity using Python&#8217;s <code>id()</code> function. The two instances of the Vector class have different identities:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!2JPb!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8126d64e-c245-4d07-8973-70caa9365ed6_2120x768.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!2JPb!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8126d64e-c245-4d07-8973-70caa9365ed6_2120x768.png 424w, https://substackcdn.com/image/fetch/$s_!2JPb!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8126d64e-c245-4d07-8973-70caa9365ed6_2120x768.png 848w, https://substackcdn.com/image/fetch/$s_!2JPb!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8126d64e-c245-4d07-8973-70caa9365ed6_2120x768.png 1272w, https://substackcdn.com/image/fetch/$s_!2JPb!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8126d64e-c245-4d07-8973-70caa9365ed6_2120x768.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!2JPb!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8126d64e-c245-4d07-8973-70caa9365ed6_2120x768.png" width="1456" height="527" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/8126d64e-c245-4d07-8973-70caa9365ed6_2120x768.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:527,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;code&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="code" title="code" srcset="https://substackcdn.com/image/fetch/$s_!2JPb!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8126d64e-c245-4d07-8973-70caa9365ed6_2120x768.png 424w, https://substackcdn.com/image/fetch/$s_!2JPb!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8126d64e-c245-4d07-8973-70caa9365ed6_2120x768.png 848w, https://substackcdn.com/image/fetch/$s_!2JPb!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8126d64e-c245-4d07-8973-70caa9365ed6_2120x768.png 1272w, https://substackcdn.com/image/fetch/$s_!2JPb!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8126d64e-c245-4d07-8973-70caa9365ed6_2120x768.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>You&#8217;ll get different values from the ones shown here when you run this code on your computer. But what matters is that the two numbers you get are different from each other. You can also confirm that <code>v1</code> and <code>v2</code> represent different objects by using <code>v1</code> is <code>v2</code>, which returns <code>False</code>.</p><p>Note that the terms object and instance are both commonly used to refer to the unit created by a class. They refer to the same thing.</p><p>However, these are &#8220;blank&#8221; objects. They don&#8217;t have anything beyond the bare minimum a Python object needs. Let&#8217;s add some data.</p>
      <p>
          <a href="https://thepalindrome.org/p/introduction-to-object-oriented-programming">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[Explore LLM word representations using similarity analysis (part 1)]]></title><description><![CDATA[A hands-on introduction to representational similarity analysis (RSA) with GPT-2 and BERT embeddings]]></description><link>https://thepalindrome.org/p/explore-llm-word-representations</link><guid isPermaLink="false">https://thepalindrome.org/p/explore-llm-word-representations</guid><dc:creator><![CDATA[Mike X Cohen, PhD]]></dc:creator><pubDate>Wed, 22 Apr 2026 12:43:43 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/c50dc465-a555-4819-b83e-d9d4f29dba7c_1200x630.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p><em>Hey! It&#8217;s Tivadar.</em></p><p><em><span class="mention-wrap" data-attrs="{&quot;name&quot;:&quot;Mike X Cohen, PhD&quot;,&quot;id&quot;:382604135,&quot;type&quot;:&quot;user&quot;,&quot;url&quot;:null,&quot;photo_url&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/3c804d93-69c2-49a9-a797-2216b4bae5ba_1000x1000.jpeg&quot;,&quot;uuid&quot;:&quot;b23ff038-6b40-48bb-ab4c-b4d5522ff932&quot;}" data-component-name="MentionToDOM"></span> returns to The Palindrome! You know I&#8217;m a big fan of his work, and if you are into machine learning, you should be too. His posts always strike the perfect balance between educational, practical, and entertaining.</em></p><p><em>He recently published the book <a href="https://github.com/mikexcohen/ML4LLM_book">50 ML Projects to Understand LLMs</a>, and his upcoming two-part series on exploring word representations is taken directly from the book. If you want to understand how Large Language Models work under the hood, don&#8217;t miss the post below.</em></p><p><em>Enjoy!</em></p><p><em>Cheers,<br>Tivadar</em></p><div><hr></div><h2>What you will learn in this 2-part post series</h2><p>The primary goal of this post series is to teach you the Representational Similarity Analysis (RSA), which is a machine-learning analysis that compares distributed representations in different systems. It was originally developed as a neuroscience tool to compare how image categories are represented in different parts of the brain, and was then adapted to compare across different brain-imaging methods, different species, and between brains and computer vision models. Here in this post, I&#8217;ll teach you how to use RSA to explore whether different language models encode words in similar ways.</p><p>The secondary goal of this post series is to use RSA to learn about LLM architecture and representations. You&#8217;ll use RSA as a tool to peer into the internal calculations and representations inside LLMs, including embeddings vectors and the famous &#8220;attention&#8221; algorithm in the transformer blocks.</p><p>This post roughly corresponds to Project 12 in my recent book on <a href="https://github.com/mikexcohen/ML4LLM_book">using machine-learning projects to understand how LLMs work</a>. Don&#8217;t worry, you don&#8217;t need the book to follow this post.</p><p>The main prerequisite for these posts is understanding correlation and cosine similarity. If you don&#8217;t know those two analyses &#8212; or if you want a refresher &#8212; <a href="https://thepalindrome.org/p/correlation-vs-cosine-similarity">check out this post</a>. If you want to follow the code that accompanies this post, you&#8217;ll also need some Python coding skills.</p><h2>How to use the code with these posts</h2><p>Here&#8217;s the most important learning tip: Don&#8217;t just read the post; follow along with the code! The accompanying code will reproduce all the figures in this post &#8212; but you can do so much more by thinking of the code as a starting-point for your continued explorations. Try changing parameters, adding new words or categories, using different similarity/distance metrics, different models, etc.</p><p><a href="https://github.com/mikexcohen/Substack/blob/main/MLonLLMs/Cohen_RSA_LLMs_part1.ipynb">The code is available here on my GitHub.</a> In the video below, I show how to get and run the code using Google Colab. You can also download the notebook file and run it locally, but I recommend using Colab because you won&#8217;t need to worry about local installations or library versions.</p><div class="native-video-embed" data-component-name="VideoPlaceholder" data-attrs="{&quot;mediaUploadId&quot;:&quot;48251e9f-7b1c-4509-9bfe-21833d889443&quot;,&quot;duration&quot;:null}"></div><div><hr></div><p><em>&#128204; The Palindrome breaks down advanced math and machine learning with visuals that make everything click.</em></p><p><strong>Join now while it&#8217;s 33% off (until the end of April)</strong><em> and lock in your discount for life. Unlock exclusive posts and 150+ deep dives into the heart of machine learning.</em></p><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://thepalindrome.org/subscribe?coupon=77a08a1b&quot;,&quot;text&quot;:&quot;Upgrade to Paid (33% Off)&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://thepalindrome.org/subscribe?coupon=77a08a1b"><span>Upgrade to Paid (33% Off)</span></a></p><div><hr></div><h2>What are &#8220;embeddings&#8221; in language models like Claude?</h2><p>Language models do not process text; they process numbers. When you write a prompt to a chatbot, that text is converted into a sequence of high-dimensional vectors called embeddings vectors. You can think of an embeddings vector as a coordinate, just like how the two numbers <code>[1,-3]</code> can be represented as a coordinate in a 2D space. So, each word is encoded as a coordinate, like the following illustration:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!uiab!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9f677f4-f033-4a1c-8b0a-23f00f7826ab_1951x729.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!uiab!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9f677f4-f033-4a1c-8b0a-23f00f7826ab_1951x729.png 424w, https://substackcdn.com/image/fetch/$s_!uiab!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9f677f4-f033-4a1c-8b0a-23f00f7826ab_1951x729.png 848w, https://substackcdn.com/image/fetch/$s_!uiab!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9f677f4-f033-4a1c-8b0a-23f00f7826ab_1951x729.png 1272w, https://substackcdn.com/image/fetch/$s_!uiab!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9f677f4-f033-4a1c-8b0a-23f00f7826ab_1951x729.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!uiab!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9f677f4-f033-4a1c-8b0a-23f00f7826ab_1951x729.png" width="1456" height="544" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/b9f677f4-f033-4a1c-8b0a-23f00f7826ab_1951x729.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:544,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!uiab!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9f677f4-f033-4a1c-8b0a-23f00f7826ab_1951x729.png 424w, https://substackcdn.com/image/fetch/$s_!uiab!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9f677f4-f033-4a1c-8b0a-23f00f7826ab_1951x729.png 848w, https://substackcdn.com/image/fetch/$s_!uiab!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9f677f4-f033-4a1c-8b0a-23f00f7826ab_1951x729.png 1272w, https://substackcdn.com/image/fetch/$s_!uiab!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9f677f4-f033-4a1c-8b0a-23f00f7826ab_1951x729.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption"><em>Figure 1: Illustration of a human-crafted 2D embeddings space with five word embeddings shown. Taken from my longer <a href="https://mikexcohen.substack.com/p/llm-breakdown-36-embeddings">post on LLM</a> embeddings, which itself is taken from my video-based <a href="https://www.udemy.com/course/dullms_x/?couponCode=202510">course on LLM</a> mechanisms.</em></figcaption></figure></div><p>But here&#8217;s the thing: That diagram is really oversimplified. In practice, the dimensionality of word embeddings in language models isn&#8217;t two; it&#8217;s several thousand. Even GPT2-small &#8212; one of the smallest LLMs &#8212; has an embeddings dimensionality of 768. The models we&#8217;ll use in this post have an embeddings dimensionality of 1024. Even a 3-dimensional graph can be confusing and difficult to interpret.</p><p>And even more confusing is this: the dimensions are not human-crafted, nor do they correspond to human-interpretable traits like size and friendliness. In fact, we cannot interpret the axes at all. And when I write &#8220;we&#8221; I&#8217;m not referring to you and me; humans cannot understand what the axes mean, because the axes don&#8217;t mean anything in the sense of corresponding to physical characteristics of nature.</p><p>Still, those embeddings vectors are key to unlocking how LLMs represent and calculate information, and understanding those embeddings is key to technical AI safety and efficient fine-tuning of large models, in addition to research into complex systems and emergence.</p><h2>How can we compare different embeddings?</h2><p>All LLMs have an embeddings layer, but not all embeddings layers are the same. Different training sets, embeddings dimensionalities, and model training goals produce different embeddings vectors in different models. And because the embeddings matrix is initialized with random numbers, even the exact same LLM architecture with the exact same training data will have different embeddings vectors.</p><p>So how can we compare the embeddings vectors from different models? The answer is we cannot directly compare them.</p><p>However, it is possible to compare different embeddings by examining whether they have similar internal statistical structures. And that&#8217;s what you&#8217;re going to learn in this post.</p><p>RSA stands for <em>representational similarity analysis</em> and is a technique to compare representations across multiple encodings. The idea is this: Instead of correlating embeddings vectors directly between models, calculate similarities within models across embeddings, and then determine whether the patterns of across-embeddings similarities are similar.</p><p>In other words, the embeddings vector of &#8220;banana&#8221; might be very different between BERT and GPT-2, but the way that &#8220;banana&#8221; and &#8220;apple&#8221; relate to each other within each model might be similar.</p><h2>Extract embeddings from two LLMs</h2><p>We&#8217;ll work with the BERT-large model and the GPT-2-medium model. I&#8217;ll explain why I chose those two models in a moment, and then at the end of this post, I&#8217;ll explore a different pair of models.</p><p>The code below imports the BERT model and its tokenizer (a tokenizer is an algorithm that converts text into a sequence of integers that it is used to pick out the corresponding embeddings vectors).</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!7028!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fcf2c7b68-b15a-4e64-a452-ed1ec008fab5_2186x855.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!7028!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fcf2c7b68-b15a-4e64-a452-ed1ec008fab5_2186x855.png 424w, https://substackcdn.com/image/fetch/$s_!7028!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fcf2c7b68-b15a-4e64-a452-ed1ec008fab5_2186x855.png 848w, https://substackcdn.com/image/fetch/$s_!7028!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fcf2c7b68-b15a-4e64-a452-ed1ec008fab5_2186x855.png 1272w, https://substackcdn.com/image/fetch/$s_!7028!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fcf2c7b68-b15a-4e64-a452-ed1ec008fab5_2186x855.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!7028!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fcf2c7b68-b15a-4e64-a452-ed1ec008fab5_2186x855.png" width="1456" height="569" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/cf2c7b68-b15a-4e64-a452-ed1ec008fab5_2186x855.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:569,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;code&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="code" title="code" srcset="https://substackcdn.com/image/fetch/$s_!7028!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fcf2c7b68-b15a-4e64-a452-ed1ec008fab5_2186x855.png 424w, https://substackcdn.com/image/fetch/$s_!7028!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fcf2c7b68-b15a-4e64-a452-ed1ec008fab5_2186x855.png 848w, https://substackcdn.com/image/fetch/$s_!7028!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fcf2c7b68-b15a-4e64-a452-ed1ec008fab5_2186x855.png 1272w, https://substackcdn.com/image/fetch/$s_!7028!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fcf2c7b68-b15a-4e64-a452-ed1ec008fab5_2186x855.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>I used &#8220;B&#8221; at the end of the variable names to disambiguate from the GPT-2 variables that end with &#8220;G&#8221;. The code for importing GPT-2-medium looks very similar and is in the online code file.</p><p>Let&#8217;s check the sizes of the embeddings matrices:</p><pre><code><code>BERT embeddings shape: [30522, 1024]
GPT2 embeddings shape: [50257, 1024]</code></code></pre><p>The size of the matrices corresponds to the number of items in the vocab (how many tokens each model has learned; that&#8217;s around 30k for BERT and 50k for GPT-2), and the dimensionality of the embeddings vectors (1024).</p><p>The two models have a different vocab size (briefly: BERT has mostly whole words while GPT-2 has subwords for non-Latin languages and code), but &#8212; germane to our application &#8212; the embeddings dimension (1024) is exactly the same for both models. That means we can directly compare the embeddings vectors between the two models.</p><p>Spoiler alert: Directly comparing their embeddings will not be insightful. But that will lead us to discover something amazing when we apply RSA.</p><h2>Directly comparing model embeddings</h2><p>For the rest of this project, we will use 34 words in three semantic categories. The idea is to compare &#8212; both directly and via RSA &#8212; whether BERT and GPT2 encode these words or their semantic categories in similar ways. Here are the categories and words:<br>Space: galaxy, asteroid, comet, cosmos, space, sun, planet, moon, star, orbit<br>Furniture: ceiling, sofa, couch, carpet, door, window, lamp, chair, table, rug, bed, floor, wall<br>Fruit: pear, grape, banana, cherry, peach, apple, seed, jelly, orange, lime, fruit</p><p>These words are all encoded as single tokens (when including a preceding space for GPT-2, which is a result of the byte-pair encoding algorithm).</p><p>Those tokens are row indices into the embeddings matrices, which we use to extract a submatrix of the embeddings from each model:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!6w6T!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5d14e019-56bc-4bbf-bad9-e660f8009dc4_2120x672.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!6w6T!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5d14e019-56bc-4bbf-bad9-e660f8009dc4_2120x672.png 424w, https://substackcdn.com/image/fetch/$s_!6w6T!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5d14e019-56bc-4bbf-bad9-e660f8009dc4_2120x672.png 848w, https://substackcdn.com/image/fetch/$s_!6w6T!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5d14e019-56bc-4bbf-bad9-e660f8009dc4_2120x672.png 1272w, https://substackcdn.com/image/fetch/$s_!6w6T!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5d14e019-56bc-4bbf-bad9-e660f8009dc4_2120x672.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!6w6T!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5d14e019-56bc-4bbf-bad9-e660f8009dc4_2120x672.png" width="1456" height="462" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/5d14e019-56bc-4bbf-bad9-e660f8009dc4_2120x672.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:462,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;code&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="code" title="code" srcset="https://substackcdn.com/image/fetch/$s_!6w6T!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5d14e019-56bc-4bbf-bad9-e660f8009dc4_2120x672.png 424w, https://substackcdn.com/image/fetch/$s_!6w6T!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5d14e019-56bc-4bbf-bad9-e660f8009dc4_2120x672.png 848w, https://substackcdn.com/image/fetch/$s_!6w6T!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5d14e019-56bc-4bbf-bad9-e660f8009dc4_2120x672.png 1272w, https://substackcdn.com/image/fetch/$s_!6w6T!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5d14e019-56bc-4bbf-bad9-e660f8009dc4_2120x672.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>The two submatrices have the same size: 18 by 1024, corresponding to the 18 words and 1024 embeddings dimensions.</p><p>Now for the question at hand: do BERT and GPT-2 embed those words in the same way? We can answer that question with a correlation analysis. The idea is simple: If the two models use the same embeddings dimensions, then their embeddings vectors for the word &#8220;galaxy&#8221; should be identical &#8212; or at least very strongly correlated.</p><p>Let&#8217;s see what the data show:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!VeGu!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4e78369d-fe98-4267-b2d6-684a8ee68fb7_2304x768.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!VeGu!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4e78369d-fe98-4267-b2d6-684a8ee68fb7_2304x768.png 424w, https://substackcdn.com/image/fetch/$s_!VeGu!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4e78369d-fe98-4267-b2d6-684a8ee68fb7_2304x768.png 848w, https://substackcdn.com/image/fetch/$s_!VeGu!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4e78369d-fe98-4267-b2d6-684a8ee68fb7_2304x768.png 1272w, https://substackcdn.com/image/fetch/$s_!VeGu!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4e78369d-fe98-4267-b2d6-684a8ee68fb7_2304x768.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!VeGu!,w_2400,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4e78369d-fe98-4267-b2d6-684a8ee68fb7_2304x768.png" width="1200" height="399.72527472527474" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/4e78369d-fe98-4267-b2d6-684a8ee68fb7_2304x768.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:false,&quot;imageSize&quot;:&quot;large&quot;,&quot;height&quot;:485,&quot;width&quot;:1456,&quot;resizeWidth&quot;:1200,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:&quot;center&quot;,&quot;offset&quot;:false}" class="sizing-large" alt="" title="" srcset="https://substackcdn.com/image/fetch/$s_!VeGu!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4e78369d-fe98-4267-b2d6-684a8ee68fb7_2304x768.png 424w, https://substackcdn.com/image/fetch/$s_!VeGu!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4e78369d-fe98-4267-b2d6-684a8ee68fb7_2304x768.png 848w, https://substackcdn.com/image/fetch/$s_!VeGu!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4e78369d-fe98-4267-b2d6-684a8ee68fb7_2304x768.png 1272w, https://substackcdn.com/image/fetch/$s_!VeGu!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4e78369d-fe98-4267-b2d6-684a8ee68fb7_2304x768.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption"><em>Figure 2: Lack of robust correlations between GPT-2 and BERT embeddings for 18 sample words.</em></figcaption></figure></div><p>The answer is a clear and resounding NOPE! The embeddings are completely different, with basically zero-valued correlations with small non-zero values attributable to noise in finite samples.</p><p>Let&#8217;s take a step back. Does it even make sense to compare embeddings directly? Doing so relies on the assumption that the embeddings dimensions are identical, and thus the embeddings values can be lined up and quantitatively compared.</p><p>But embeddings don&#8217;t work that way. In fact, embeddings matrices start off as random numbers and then are trained based on large datasets (the Internet text). Because of the random initialization, even training the same model on the exact same training set will create different embeddings matrices.</p><p>Segue to RSA.</p><h2>Representational similarity analysis</h2><p>Embeddings vectors cannot be directly compared across models. But, the relations across vectors within models can be compared, and then those within-model relations can be compared across models.</p><p>In practice, you calculate the RSA score in two steps:</p><p><strong>Step 1</strong>: Calculate the cosine similarity between all pairs of embeddings vectors within each model.</p><p><strong>Step 2</strong>: Correlate the two sets of cosine similarity values.</p><p>Let&#8217;s walk through the analysis, and then I&#8217;ll provide more discussion about how to interpret the RSA score, why Step 1 used cosine similarity while Step 2 used correlation, and other similarity metrics to calculate RSA.</p><p>The figure below shows the two within-model cosine similarity matrices as heatmaps.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!U_KS!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8ddd7ca7-7cfc-4d2d-bc5f-74b3a1d18026_1920x768.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!U_KS!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8ddd7ca7-7cfc-4d2d-bc5f-74b3a1d18026_1920x768.png 424w, https://substackcdn.com/image/fetch/$s_!U_KS!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8ddd7ca7-7cfc-4d2d-bc5f-74b3a1d18026_1920x768.png 848w, https://substackcdn.com/image/fetch/$s_!U_KS!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8ddd7ca7-7cfc-4d2d-bc5f-74b3a1d18026_1920x768.png 1272w, https://substackcdn.com/image/fetch/$s_!U_KS!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8ddd7ca7-7cfc-4d2d-bc5f-74b3a1d18026_1920x768.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!U_KS!,w_2400,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8ddd7ca7-7cfc-4d2d-bc5f-74b3a1d18026_1920x768.png" width="1200" height="479.6703296703297" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/8ddd7ca7-7cfc-4d2d-bc5f-74b3a1d18026_1920x768.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:false,&quot;imageSize&quot;:&quot;large&quot;,&quot;height&quot;:582,&quot;width&quot;:1456,&quot;resizeWidth&quot;:1200,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:&quot;center&quot;,&quot;offset&quot;:false}" class="sizing-large" alt="" title="" srcset="https://substackcdn.com/image/fetch/$s_!U_KS!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8ddd7ca7-7cfc-4d2d-bc5f-74b3a1d18026_1920x768.png 424w, https://substackcdn.com/image/fetch/$s_!U_KS!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8ddd7ca7-7cfc-4d2d-bc5f-74b3a1d18026_1920x768.png 848w, https://substackcdn.com/image/fetch/$s_!U_KS!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8ddd7ca7-7cfc-4d2d-bc5f-74b3a1d18026_1920x768.png 1272w, https://substackcdn.com/image/fetch/$s_!U_KS!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8ddd7ca7-7cfc-4d2d-bc5f-74b3a1d18026_1920x768.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption"><em>Figure 3: Heatmaps showing cosine similarities of embeddings vectors across words for each model. The words are the same on the x- and y-axes but the tick labels are offset to show all words.</em></figcaption></figure></div><p>There are several results visible in Figure 3, including that the three semantic categories are visible as the block-diagonal structure in the similarity matrices, and that the cosine similarities appear overall stronger in GPT-2 compared to BERT (note the color levels with equal color map limits).</p><p>The more interesting result, however, is the RSA scatter plot.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!iU37!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F72105bef-9053-4ef2-947a-17a8d80a63a5_1152x960.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!iU37!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F72105bef-9053-4ef2-947a-17a8d80a63a5_1152x960.png 424w, https://substackcdn.com/image/fetch/$s_!iU37!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F72105bef-9053-4ef2-947a-17a8d80a63a5_1152x960.png 848w, https://substackcdn.com/image/fetch/$s_!iU37!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F72105bef-9053-4ef2-947a-17a8d80a63a5_1152x960.png 1272w, https://substackcdn.com/image/fetch/$s_!iU37!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F72105bef-9053-4ef2-947a-17a8d80a63a5_1152x960.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!iU37!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F72105bef-9053-4ef2-947a-17a8d80a63a5_1152x960.png" width="1152" height="960" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/72105bef-9053-4ef2-947a-17a8d80a63a5_1152x960.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:960,&quot;width&quot;:1152,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" title="" srcset="https://substackcdn.com/image/fetch/$s_!iU37!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F72105bef-9053-4ef2-947a-17a8d80a63a5_1152x960.png 424w, https://substackcdn.com/image/fetch/$s_!iU37!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F72105bef-9053-4ef2-947a-17a8d80a63a5_1152x960.png 848w, https://substackcdn.com/image/fetch/$s_!iU37!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F72105bef-9053-4ef2-947a-17a8d80a63a5_1152x960.png 1272w, https://substackcdn.com/image/fetch/$s_!iU37!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F72105bef-9053-4ef2-947a-17a8d80a63a5_1152x960.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption"><em>Figure 4: The RSA score is calculated as the correlation between the similarity metrics (cosine similarity, in this case) between the two models. Although the embeddings spaces are completely different in the two models, the internal statistical structures within each model are similar across the two models.</em></figcaption></figure></div><p>Here&#8217;s the interpretation: The token pairs that have higher similarity in GPT-2&#8217;s embeddings also have higher similarity in BERT&#8217;s embeddings. This indicates that although the embeddings spaces are different, there are statistical patterns inside the embeddings spaces that are similar across these two models.</p><p>Here&#8217;s a helpful analogy: Imagine representing the number &#8220;7&#8221; as an image. Then make a copy of that image and rotate it. The information content of the two images is the same, and yet their direct pixel-wise correlation is nearly zero:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!HhBy!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1afb3efe-1b27-406e-b672-04940af25ab2_1920x672.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!HhBy!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1afb3efe-1b27-406e-b672-04940af25ab2_1920x672.png 424w, https://substackcdn.com/image/fetch/$s_!HhBy!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1afb3efe-1b27-406e-b672-04940af25ab2_1920x672.png 848w, https://substackcdn.com/image/fetch/$s_!HhBy!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1afb3efe-1b27-406e-b672-04940af25ab2_1920x672.png 1272w, https://substackcdn.com/image/fetch/$s_!HhBy!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1afb3efe-1b27-406e-b672-04940af25ab2_1920x672.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!HhBy!,w_2400,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1afb3efe-1b27-406e-b672-04940af25ab2_1920x672.png" width="1200" height="420.3296703296703" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/1afb3efe-1b27-406e-b672-04940af25ab2_1920x672.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:false,&quot;imageSize&quot;:&quot;large&quot;,&quot;height&quot;:510,&quot;width&quot;:1456,&quot;resizeWidth&quot;:1200,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:&quot;center&quot;,&quot;offset&quot;:false}" class="sizing-large" alt="" title="" srcset="https://substackcdn.com/image/fetch/$s_!HhBy!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1afb3efe-1b27-406e-b672-04940af25ab2_1920x672.png 424w, https://substackcdn.com/image/fetch/$s_!HhBy!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1afb3efe-1b27-406e-b672-04940af25ab2_1920x672.png 848w, https://substackcdn.com/image/fetch/$s_!HhBy!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1afb3efe-1b27-406e-b672-04940af25ab2_1920x672.png 1272w, https://substackcdn.com/image/fetch/$s_!HhBy!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1afb3efe-1b27-406e-b672-04940af25ab2_1920x672.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption"><em>Figure 5: A visual analogy to motivate the RSA. Two embeddings spaces (with noise added) can encode the same information while being unrelated to each other.</em></figcaption></figure></div><p>To complete the RSA analogy, you&#8217;d need to create images of many more numbers, calculate cosine similarity across the number-images within each embeddings, then correlate those similarity values between embeddings &#8220;A&#8221; and &#8220;B&#8221;.</p><p>That&#8217;s just a helpful way to think about the motivation of RSA; don&#8217;t push the analogy too far.</p><p>In fact, here is an important note: The embeddings spaces of different models &#8212; especially models trained for different purposes (GPT-2 for text generation, BERT for text classification) &#8212; <strong>are not simply rotated versions of each other</strong>. They really are distinct embeddings spaces, but they do share some internal semantic structure that can be measured with an RSA.</p><p>As for why the RSA score is a correlation although the within-model relations were calculated using similarity: Within each model, the mean offsets of different vectors are relevant and meaningful. Across models, however, cosine similarities might be overall stronger or weaker; the question we ask with RSA is whether the relationships across token pairs are similar in different models. For that analysis, we do not want mean offsets to bias the score. Indeed, the distribution of similarity values is different between GPT-2 and BERT (see x- and y-axes in Figure 4). If you&#8217;re unsure of why a mean offset impacts cosine similarity and not correlation, you can check out <a href="https://mikexcohen.substack.com/p/correlation-vs-cosine-similarity">my post on the topic</a>.</p><p>Regarding the similarity metric: Cosine similarity is appropriate for embeddings vectors, but the analysis works the same way for any similarity or distance metric, such as correlation or Euclidean distance. In fact, if you use a distance metric, the analysis is termed &#8220;representational dissimilarity analysis.&#8221;</p><p>By the way, you may have noticed that I didn&#8217;t incorporate the three categories into the analysis. Great observation! I&#8217;ll use those categories in Part 2 of this 2-part post series. What I&#8217;d like you to do now is think about what analyses you might do with those categories.</p><h2>RSA with different embeddings sizes</h2><p>A key advantage of RSA is that it is robust to the dimensionality within each model. For example, how can you compare the embeddings between BERT-large (embeddings dimensionality of 1024) and GPT-2-XL (embeddings dimensionality of 1600)?</p><p>You can explore that in the code simply by importing gpt2-xl instead of gpt2-medium.</p><p>Well, when you try the direct correlation analysis (Figure 2), you get errors and cannot run the analysis or generate the plots. Both a correlation coefficient and a scatter plot are defined only for two vectors of the same dimensionality.</p><p>But don&#8217;t be concerned! I already discussed why the direct correlation analysis is invalid for comparing embeddings.</p><p>The RSA analyses, on the other hand, look great.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!yusO!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd7ffc7e5-4526-4466-8320-d126c3065375_2841x768.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!yusO!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd7ffc7e5-4526-4466-8320-d126c3065375_2841x768.png 424w, https://substackcdn.com/image/fetch/$s_!yusO!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd7ffc7e5-4526-4466-8320-d126c3065375_2841x768.png 848w, https://substackcdn.com/image/fetch/$s_!yusO!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd7ffc7e5-4526-4466-8320-d126c3065375_2841x768.png 1272w, https://substackcdn.com/image/fetch/$s_!yusO!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd7ffc7e5-4526-4466-8320-d126c3065375_2841x768.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!yusO!,w_2400,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd7ffc7e5-4526-4466-8320-d126c3065375_2841x768.png" width="1200" height="324.72527472527474" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/d7ffc7e5-4526-4466-8320-d126c3065375_2841x768.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:false,&quot;imageSize&quot;:&quot;large&quot;,&quot;height&quot;:394,&quot;width&quot;:1456,&quot;resizeWidth&quot;:1200,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:&quot;center&quot;,&quot;offset&quot;:false}" class="sizing-large" alt="" title="" srcset="https://substackcdn.com/image/fetch/$s_!yusO!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd7ffc7e5-4526-4466-8320-d126c3065375_2841x768.png 424w, https://substackcdn.com/image/fetch/$s_!yusO!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd7ffc7e5-4526-4466-8320-d126c3065375_2841x768.png 848w, https://substackcdn.com/image/fetch/$s_!yusO!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd7ffc7e5-4526-4466-8320-d126c3065375_2841x768.png 1272w, https://substackcdn.com/image/fetch/$s_!yusO!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd7ffc7e5-4526-4466-8320-d126c3065375_2841x768.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption"><em>Figure 6: Same analysis as in Figures 3 and 4, but using GPT-2-XL instead of GPT-2-medium.</em></figcaption></figure></div><h2>Conclusions and what&#8217;s coming up in the next post</h2><p>RSA is a powerful analysis for comparing how different systems &#8212; brains or machines &#8212; represent information, when those representations are in different spaces with different dimensionalities. RSA was originally developed in neuroscience, then applied in many other machine-learning applications.</p><p>RSA is also easy to understand, easy to code, easy to interpret, and easy to visualize &#8212; all ideal properties of a machine-learning analysis.</p><p>In this post, you learned about how the analysis works and saw an application using token embeddings in language models. The goal of Part 2 in this series will be to apply this analysis to explore how the embeddings change inside the LLMs, as those embeddings vectors traverse the transformer stack. You&#8217;ll also learn how to explore category selectivity.</p>]]></content:encoded></item><item><title><![CDATA[I Built the Knowledge Graph of Machine Learning]]></title><description><![CDATA[Exploring the structure of machine learning]]></description><link>https://thepalindrome.org/p/i-built-the-knowledge-graph-of-machine</link><guid isPermaLink="false">https://thepalindrome.org/p/i-built-the-knowledge-graph-of-machine</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Sun, 19 Apr 2026 07:46:57 GMT</pubDate><enclosure url="https://substackcdn.com/image/youtube/w_728,c_limit/WR-VyH0pIgs" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hey! It&#8217;s Tivadar from The Palindrome.</p><p><em>&#8220;How to get started in machine learning?&#8221;</em> is one of the most common questions I get. I have a couple of default answers, but they are based more on my personal experience than on science.</p><p>Inspired by this, I&#8217;ve mapped out the knowledge graph of machine learning, building a hierarchy of concepts that can guide you from the foundations to the state of the art.</p><p>A couple of fascinating patterns have emerged from my journey: the thin spine of mathematics that holds up the entire knowledge graph, the central concepts like gradient descent that enable modern machine learning as we know it, and more.</p><p>Here&#8217;s the video where I talk about my findings:</p><div id="youtube2-WR-VyH0pIgs" class="youtube-wrap" data-attrs="{&quot;videoId&quot;:&quot;WR-VyH0pIgs&quot;,&quot;startTime&quot;:null,&quot;endTime&quot;:null}" data-component-name="Youtube2ToDOM"><div class="youtube-inner"><iframe src="https://www.youtube-nocookie.com/embed/WR-VyH0pIgs?rel=0&amp;autoplay=0&amp;showinfo=0&amp;enablejsapi=0" frameborder="0" loading="lazy" gesture="media" allow="autoplay; fullscreen" allowautoplay="true" allowfullscreen="true" width="728" height="409"></iframe></div></div><div><hr></div><p><strong>Before you go:</strong> if you find value in my work, consider upgrading to a paid subscription. Your support is what makes it possible for me to keep creating high-quality educational content like this.</p><p>Right now is the best time to join&#8212;there&#8217;s a <strong>33% discount until the end of April</strong>, and you can lock in that price for good.</p><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://thepalindrome.org/77a08a1b&quot;,&quot;text&quot;:&quot;Upgrade to Paid (33% off)&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://thepalindrome.org/77a08a1b"><span>Upgrade to Paid (33% off)</span></a></p><p>With a premium subscription, you&#8217;ll get access to</p><ul><li><p>the monthly live workshops,</p></li><li><p>the subscriber chat,</p></li><li><p>and the archive of 150+ deep dives into mathematics and machine learning.</p></li></ul><p>In any case, I&#8217;m grateful you&#8217;re here. Your time and attention mean a lot, and The Palindrome wouldn&#8217;t exist without you.</p><p>Cheers,<br>Tivadar</p>]]></content:encoded></item><item><title><![CDATA[This Week at The Palindrome]]></title><description><![CDATA[Finishing up with knowledge graphs and building more interactive tools]]></description><link>https://thepalindrome.org/p/this-week-at-the-palindrome</link><guid isPermaLink="false">https://thepalindrome.org/p/this-week-at-the-palindrome</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Sat, 11 Apr 2026 09:42:48 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!xKLg!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F462454e3-5f77-4889-b287-ebc2750db03b_1345x770.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hey! It&#8217;s Tivadar from The Palindrome. It&#8217;s time for an update. Let&#8217;s </p><p>I&#8217;m finishing up my video about <a href="https://the-palindrome.github.io/ml-knowledge-graph/">the knowledge graph of machine learning</a>, which will be released next week; I&#8217;ll do a live premiere right here on Substack Live, with a discussion after the viewing. (<a href="https://open.substack.com/live-stream/160251">You can join here.</a>)</p><p>This video will mark a milestone for me: instead of relying on hand-crafted slides and a presentation-style exposition, I built a scripting engine on top of the knowledge graph explorer that turns a JSON script like</p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;json&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-json">[{
  "at": 0.0,
  "action": "autoRotate",
  "axis": "y",
  "speed": 0.01,
  "duration": 9.3,
  "windDown": 2.0,
  "easing": "linear"
},
{
  "at": 9.3,
  "action": "selectNode",
  "nodeId": "gpt",
  "showPrerequisites": true,
  "showDependents": false,
  "duration": 2.0
}]</code></pre></div><p>into a beautifully rendered video.</p><p>Here&#8217;s a sneak peek:</p><div class="native-video-embed" data-component-name="VideoPlaceholder" data-attrs="{&quot;mediaUploadId&quot;:&quot;f441ec90-5bce-463d-a7a6-504a23d70b56&quot;,&quot;duration&quot;:null}"></div><p>The machine learning knowledge graph project could serve as a template for my future content. From now on, I&#8217;ll go full multimodal, meaning that I&#8217;ll</p><ul><li><p>build interactive visualizations (such as <a href="https://the-palindrome.github.io/ml-knowledge-graph/">the knowledge graph explorer</a>),</p></li><li><p>then write posts and record videos, aided by the interactive tool.</p></li></ul><p>Now that the current video-in-progress is about to be finished, what&#8217;s next?</p><p>Read on.</p>
      <p>
          <a href="https://thepalindrome.org/p/this-week-at-the-palindrome">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[The Power of Mathematical Modeling]]></title><description><![CDATA[What do online rumors, computer viruses and zombie apocalypses have in common?]]></description><link>https://thepalindrome.org/p/the-power-of-mathematical-modeling</link><guid isPermaLink="false">https://thepalindrome.org/p/the-power-of-mathematical-modeling</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Tue, 07 Apr 2026 11:03:35 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!QFjt!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F5475cbc3-22c6-4279-a65a-f2a61e3d6f71_759x506.webp" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hey! It&#8217;s Tivadar from The Palindrome.</p><p>This week, it&#8217;s my pleasure to introduce <span class="mention-wrap" data-attrs="{&quot;name&quot;:&quot;Manlio De Domenico, Ph.D.&quot;,&quot;id&quot;:38842368,&quot;type&quot;:&quot;user&quot;,&quot;url&quot;:null,&quot;photo_url&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/537de500-db20-4bcd-a894-5ef6226bbf13_1080x1080.jpeg&quot;,&quot;uuid&quot;:&quot;8477290e-4570-449a-b642-328a24f2b0f1&quot;}" data-component-name="MentionToDOM"></span>, a fellow scholar working at the forefront of physics, mathematics, and computer science.</p><p>One of the main reasons behind the success of modern science is mathematical modeling, the process of translating complex real-life observations into a language that allows us to generalize, understand, and predict.</p><p>If you have enjoyed this post, subscribe to his newsletter <span class="mention-wrap" data-attrs="{&quot;name&quot;:&quot;Complexity Thoughts&quot;,&quot;id&quot;:1183925,&quot;type&quot;:&quot;pub&quot;,&quot;url&quot;:&quot;https://open.substack.com/pub/manlius&quot;,&quot;photo_url&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/5d142d85-7836-48c2-8e36-664af3a7d8ef_1280x1280.png&quot;,&quot;uuid&quot;:&quot;943a9401-ffb7-4d44-a5dc-b0d8c29eade4&quot;}" data-component-name="MentionToDOM"></span>, a space dedicated to translating the complexity of the empirical world, from your cells to entire societies, into language that is <strong>as simple as possible, though not necessarily simpler.</strong></p>
      <p>
          <a href="https://thepalindrome.org/p/the-power-of-mathematical-modeling">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[Explore Machine Learning as a Knowledge Graph]]></title><description><![CDATA[And see how everything connects]]></description><link>https://thepalindrome.org/p/explore-machine-learning-as-a-knowledge</link><guid isPermaLink="false">https://thepalindrome.org/p/explore-machine-learning-as-a-knowledge</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Mon, 30 Mar 2026 08:25:06 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!kyQK!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F13131e5c-5c36-4833-9ffe-4b89bf9e8f03_898x850.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>TL;DR: <em>Now you can play around with the <a href="https://the-palindrome.github.io/ml-knowledge-graph/">Machine Learning Knowledge Graph Explorer</a> I&#8217;ve been building. Check it out; it&#8217;s awesome.</em></p>
      <p>
          <a href="https://thepalindrome.org/p/explore-machine-learning-as-a-knowledge">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[This Week at The Palindrome (2025, Week 13)]]></title><description><![CDATA[Knowledge graphs and Minecraft epidemics]]></description><link>https://thepalindrome.org/p/this-week-at-the-palindrome-2025</link><guid isPermaLink="false">https://thepalindrome.org/p/this-week-at-the-palindrome-2025</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Fri, 27 Mar 2026 17:16:10 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!YMWO!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F951085b5-b67c-44c0-970e-2943d5579254_926x875.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hey! It&#8217;s Tivadar from The Palindrome.</p><p>Let&#8217;s try something new. In recent months, I started to feel that the weekly publishing schedule takes its toll on the quality of my posts. I want to take more time per post to give you some high-quality technical content. I&#8217;m inspired by amazing writers such as Sebastian Raschka (<span class="mention-wrap" data-attrs="{&quot;name&quot;:&quot;Ahead of AI&quot;,&quot;id&quot;:1174659,&quot;type&quot;:&quot;pub&quot;,&quot;url&quot;:&quot;https://open.substack.com/pub/sebastianraschka&quot;,&quot;photo_url&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/49f25d0a-212b-4853-8bcb-128d0a3edbbf_1196x1196.png&quot;,&quot;uuid&quot;:&quot;030fabf3-a6a7-4feb-90dd-5f95e98572b6&quot;}" data-component-name="MentionToDOM"></span>) or Cameron R. Wolfe (<span class="mention-wrap" data-attrs="{&quot;name&quot;:&quot;Deep (Learning) Focus&quot;,&quot;id&quot;:1092659,&quot;type&quot;:&quot;pub&quot;,&quot;url&quot;:&quot;https://open.substack.com/pub/cameronrwolfe&quot;,&quot;photo_url&quot;:&quot;https://bucketeer-e05bbc84-baa3-437e-9518-adb32be77984.s3.amazonaws.com/public/images/ab9b43fb-52d5-40da-995d-5b7cd3f91064_896x896.png&quot;,&quot;uuid&quot;:&quot;20698ad0-6f62-44dd-957b-39485eb37f8f&quot;}" data-component-name="MentionToDOM"></span>), who publish once a month, but each post is a work of art.</p><p>On the other hand, I miss you. A monthly schedule feels too long, and I have a lot to share with you. Ever since I got my ChatGPT Max subscription with access to Codex, my creativity is out of bounds.</p><p>So, here&#8217;s a new format. Each week, I&#8217;m sending you my unfiltered stream of consciousness, all the projects that I&#8217;m currently working on. Think of it as joining me for a coffee, where we talk about all the exciting/revolutionary/insane ideas we have in our minds.</p><p>This week, there are two things on my mind: knowledge graphs and Minecraft.</p><p>Let&#8217;s start with knowledge graphs.</p><h1>The Complete Map of Machine Learning</h1><p>If you are a regular reader, you know that one of the most common questions I get is <em>&#8220;which part of mathematics do I need to study machine learning?&#8221;</em> My default answer, based on my decade of experience, is: a ton of linear algebra, a decent amount of calculus, and a snippet of probability theory.</p><p>To be honest, I&#8217;m not completely satisfied with my reply. So, I dug deep with my newly found agentic AI-fueled superpower to find what is scientifically backed.</p><p>Without further ado: here&#8217;s the full knowledge graph of mathematics and machine learning. 2081 nodes, 5149 edges.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!pN9B!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!pN9B!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png 424w, https://substackcdn.com/image/fetch/$s_!pN9B!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png 848w, https://substackcdn.com/image/fetch/$s_!pN9B!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png 1272w, https://substackcdn.com/image/fetch/$s_!pN9B!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!pN9B!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png" width="728" height="607.8947368421053" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:false,&quot;imageSize&quot;:&quot;normal&quot;,&quot;height&quot;:825,&quot;width&quot;:988,&quot;resizeWidth&quot;:728,&quot;bytes&quot;:493437,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://thepalindrome.org/i/192289224?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:&quot;center&quot;,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!pN9B!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png 424w, https://substackcdn.com/image/fetch/$s_!pN9B!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png 848w, https://substackcdn.com/image/fetch/$s_!pN9B!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png 1272w, https://substackcdn.com/image/fetch/$s_!pN9B!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F60918a9d-6076-4b86-879b-cc39b7454f06_988x825.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption">The knowledge graph of machine learning</figcaption></figure></div><p>(The images are screenshots from the interactive graph explorer I&#8217;m building, which will be open source and publicly available.)</p><p>Let&#8217;s unravel this.</p>
      <p>
          <a href="https://thepalindrome.org/p/this-week-at-the-palindrome-2025">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[Mathematics of Machine Learning workshop]]></title><description><![CDATA[Watch now | The full recording of the workshop]]></description><link>https://thepalindrome.org/p/mathematics-of-machine-learning-workshop</link><guid isPermaLink="false">https://thepalindrome.org/p/mathematics-of-machine-learning-workshop</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Sun, 22 Mar 2026 08:23:46 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/a06820a5-38c7-4999-825d-0dba24ca1159_1920x1008.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hey!</p><p>Yesterday we concluded our first monthly workshop! As promised, here is the full recording, exclusive to paid subscribers.</p><p>You can access the Jupyter Notebook lecture notes here: <a href="https://github.com/the-palindrome/mathematics-of-machine-learning-workshop">https://github.com/the-palindrome/mathematics-of-machine-learning-workshop</a></p><p>The next monthly workshop is already in the works; it&#8217;s going to be the next iteration of the Neural Networks From Scratch course. The tentative date is April 18th, 15:00&#8211;19:00 CET, but stay tuned for the announcement, as this date might change.</p><p>Thanks again so much for attending!</p><p>Cheers,<br>Tivadar</p>
      <p>
          <a href="https://thepalindrome.org/p/mathematics-of-machine-learning-workshop">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[Machine Learning From Zero, Chapter 01]]></title><description><![CDATA[Machine Learning From Zero, Chapter 01]]></description><link>https://thepalindrome.org/p/what-is-machine-learning</link><guid isPermaLink="false">https://thepalindrome.org/p/what-is-machine-learning</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Sat, 14 Mar 2026 14:43:31 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/2554ada4-39ba-41ae-80ca-41a491e2e5e8_1200x630.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hey! This is Tivadar from The Palindrome.</p><p>I&#8217;m finally working on my upcoming book <em>Machine Learning From Zero</em>, the sequel to <em>Mathematics of Machine Learning</em>.</p><p>The first chapter has just been finished, which sets the foundations for the neat stuff, like implementing neural networks from scratch. (Which is the core of the book.)</p><p>Without further ado, here&#8217;s an exclusive preview.</p><p>Enjoy!</p><p>P.S. I&#8217;m writing this book in Jupyter Notebooks, and I turn them into Substack posts with <a href="https://notebookpress.xyz/">NotebookPress</a>, a tool I&#8217;m building to bring technical writing on Substack to the next level. If you write math-and-code-heavy content, you should check it out.</p><div><hr></div><p><em>Machine learning is training predictive models from data.</em></p><p>Sure, we can be academic about it and refine the definition of machine learning by looking at the countless of nuances, but that&#8217;s not what we are here to do. We are here to understand the core fundamentals of machine learning &#8212; the fundamentals that will take you further than anything else.</p><p>I believe the only way to aquire deep knowledge of any technical subject is to take it apart and put it back together again. <em>This</em> is what we are here to do.</p><p>The fundamental machine learning setup consists of:</p><ol><li><p>a dataset, usually coming in the form of input and target variables,</p></li><li><p>a parametric function that models the relation between the input and the target variables,</p></li><li><p>and a loss function that measures the model&#8217;s fit to the data.</p></li></ol><p>Let&#8217;s start with the data.</p><p>To look behind the curtain of machine learning algorithms, we have to precisely formulate the problems that we deal with. Three important parameters determine a machine learning paradigm: the input, the output, and the training data.</p><p>All machine learning tasks boil down to finding a model that provides additional insight into the data, i.e., a function <em>f</em> that transforms the input <em>x</em> into the useful representation <em>y</em>. This can be a prediction, an action to take, a high-level feature representation, and many more. We&#8217;ll learn about all of them.</p><p>Mathematically speaking, the basic machine learning setup consists of:</p><ol><li><p>a dataset &#119967;,</p></li><li><p>a function <em>f</em> that describes the true relation between the input and the output,</p></li><li><p>and a parametric model <em>h</em> &#8212; also called a <em>hypothesis</em> &#8212; that serves as our estimation of <em>f</em>.</p></li></ol><div><hr></div><p><strong>Remark.</strong> <em>(Common abuses of machine learning notation.)</em></p><p><em>Note that although the function f only depends on the input x, the parametric model h also depends on the parameters and the training dataset.</em></p><p><em>Thus, it is customary to write h(x) as h(x; w, &#119967;), where w represents the parameters, and &#119967; is our training dataset.</em></p><p><em>This dependence is often omitted, but keep in mind that it&#8217;s always there.</em></p><div><hr></div><p>We make no restrictions about how the model <em>f</em>&#770; is constructed. It can be a deterministic function like <em>h</em>(<em>x</em>) = &#8722;13.2 <em>x</em>&#178; + 0.92 <em>x</em> + 3.0 or a probability distribution <em>h</em>(<em>x</em>) = <em>P</em>(<em>Y</em> = <em>y</em> &#8739; <em>X</em> = <em>x</em>). Models have all kinds of families like <em>generative</em>, <em>discriminative</em>, and more. We&#8217;ll talk about them in detail; in fact, models will be the focal points of the majority of the chapters.</p><p>First, let&#8217;s focus on the paradigms themselves. There are four major ones:</p><ul><li><p>supervised learning,</p></li><li><p>unsupervised learning,</p></li><li><p>semi-supervised learning,</p></li><li><p>and reinforcement learning.</p></li></ul><p>What are these?</p><h2>Supervised learning</h2><p>The most common paradigm is <em>supervised learning</em>. There, we have inputs &#119857;&#7522; &#8712; &#8477;&#7504; and ground truth labels y&#7522; that form our training dataset</p><div class="captioned-image-container"><figure><a class="image-link image2" target="_blank" href="https://substackcdn.com/image/fetch/$s_!voUV!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ec88697-eef9-4b76-ab01-752340845aa9_1920x236.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!voUV!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ec88697-eef9-4b76-ab01-752340845aa9_1920x236.png 424w, https://substackcdn.com/image/fetch/$s_!voUV!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ec88697-eef9-4b76-ab01-752340845aa9_1920x236.png 848w, https://substackcdn.com/image/fetch/$s_!voUV!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ec88697-eef9-4b76-ab01-752340845aa9_1920x236.png 1272w, https://substackcdn.com/image/fetch/$s_!voUV!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ec88697-eef9-4b76-ab01-752340845aa9_1920x236.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!voUV!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ec88697-eef9-4b76-ab01-752340845aa9_1920x236.png" width="1456" height="179" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/2ec88697-eef9-4b76-ab01-752340845aa9_1920x236.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:179,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;math&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="math" title="math" srcset="https://substackcdn.com/image/fetch/$s_!voUV!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ec88697-eef9-4b76-ab01-752340845aa9_1920x236.png 424w, https://substackcdn.com/image/fetch/$s_!voUV!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ec88697-eef9-4b76-ab01-752340845aa9_1920x236.png 848w, https://substackcdn.com/image/fetch/$s_!voUV!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ec88697-eef9-4b76-ab01-752340845aa9_1920x236.png 1272w, https://substackcdn.com/image/fetch/$s_!voUV!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ec88697-eef9-4b76-ab01-752340845aa9_1920x236.png 1456w" sizes="100vw" loading="lazy"></picture><div></div></div></a></figure></div><p>Although the labels can be anything like numbers or text, they are all available for us. The goal is to construct a function that models the relationship between the input <em>x</em> and the target variable <em>y</em>.</p><p>Let&#8217;s saddle up and see a couple of examples.</p>
      <p>
          <a href="https://thepalindrome.org/p/what-is-machine-learning">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[Let’s Bring Jupyter Notebooks to Substack]]></title><description><![CDATA[From Jupyter Notebook to Substack post in two clicks]]></description><link>https://thepalindrome.org/p/lets-bring-jupyter-notebooks-to-substack</link><guid isPermaLink="false">https://thepalindrome.org/p/lets-bring-jupyter-notebooks-to-substack</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Thu, 05 Mar 2026 12:30:25 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/c4e4cc41-93d5-4fbe-bb07-030c0c7aeea7_1200x630.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Jupyter Notebooks are my favorite publishing format by far. I write all my posts in them.</p><p>They are the perfect medium for math-and-code-heavy technical content: they support LaTeX snippets, code execution, and, to top it all, enable interactive exploration. Every time I&#8217;m reading a hands-on tutorial about some fancy new framework, I cannot resist the urge to jump into edit mode and break the code in ways no author can think of.</p><p>Unfortunately, if you choose to write in Jupyter Notebooks, you either abandon content distribution by platforms such as Substack, LinkedIn, or X (because they don&#8217;t support the format) or manually convert the notebooks to satisfy every possible whim of every possible editor.</p><p>So, I built a tool that enables writers to publish Jupyter Notebooks on Substack (and other platforms) with a couple of clicks. It&#8217;s called <a href="https://notebookpress.xyz/">NotebookPress</a>, and it solves four major pain points:</p><ul><li><p>LaTeX rendering,</p></li><li><p>code snippets,</p></li><li><p>user interactivity,</p></li><li><p>and cross-platform compatibility.</p></li></ul><p>Let me give you a t&#8230;</p>
      <p>
          <a href="https://thepalindrome.org/p/lets-bring-jupyter-notebooks-to-substack">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[Accio Insights: The Marauder’s Map of the ML World]]></title><description><![CDATA[A deep dive into the swiss army knife of machine learning]]></description><link>https://thepalindrome.org/p/accio-insights-the-marauders-map</link><guid isPermaLink="false">https://thepalindrome.org/p/accio-insights-the-marauders-map</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Thu, 19 Feb 2026 10:58:20 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!chXt!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fff6f3fe5-9a37-40af-97c1-226ba20f247d_480x320.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hi there! It&#8217;s Tivadar from The Palindrome.</p><p>Please welcome <span class="mention-wrap" data-attrs="{&quot;name&quot;:&quot;Sairam Sundaresan&quot;,&quot;id&quot;:85853406,&quot;type&quot;:&quot;user&quot;,&quot;url&quot;:null,&quot;photo_url&quot;:&quot;https://substackcdn.com/image/fetch/$s_!3vud!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79cc4b2d-3161-4743-85d8-97910007711b_1463x1463.jpeg&quot;,&quot;uuid&quot;:&quot;bc15a281-1e09-4497-a6e2-0e4c8ef5204a&quot;}" data-component-name="MentionToDOM"></span>, author of the brilliant <span class="mention-wrap" data-attrs="{&quot;name&quot;:&quot;Gradient Ascent&quot;,&quot;id&quot;:1199871,&quot;type&quot;:&quot;pub&quot;,&quot;url&quot;:&quot;https://open.substack.com/pub/artofsaience&quot;,&quot;photo_url&quot;:&quot;https://bucketeer-e05bbc84-baa3-437e-9518-adb32be77984.s3.amazonaws.com/public/images/01dfb858-3107-4656-b289-cf13de969a17_800x800.png&quot;,&quot;uuid&quot;:&quot;ce83f3e6-f9b6-4a5c-89ac-1b7d07b9f0fd&quot;}" data-component-name="MentionToDOM"></span> Substack. I&#8217;ve been following his work for years, and I&#8217;m honored to have him here for a guest post.</p><p>By the way, <a href="https://www.eventbrite.com/e/machine-learning-and-generative-ai-system-design-workshop-tickets-1975103644168?aff=Tivadar">he is hosting a workshop on February 28th titled &#8220;Machine Learning and Generative AI System Design,&#8221;</a> and he has kindly offered a 35% discount for readers of <em>The Palindrome</em>.</p><p>The code <strong>TIVADAR35</strong> is valid until February 24th.&#8221;</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!COP6!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbe2d1426-cd58-44f5-9ac8-a90df07f85ec_1179x578.webp" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!COP6!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbe2d1426-cd58-44f5-9ac8-a90df07f85ec_1179x578.webp 424w, https://substackcdn.com/image/fetch/$s_!COP6!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbe2d1426-cd58-44f5-9ac8-a90df07f85ec_1179x578.webp 848w, https://substackcdn.com/image/fetch/$s_!COP6!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbe2d1426-cd58-44f5-9ac8-a90df07f85ec_1179x578.webp 1272w, https://substackcdn.com/image/fetch/$s_!COP6!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbe2d1426-cd58-44f5-9ac8-a90df07f85ec_1179x578.webp 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!COP6!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbe2d1426-cd58-44f5-9ac8-a90df07f85ec_1179x578.webp" width="1179" height="578" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/be2d1426-cd58-44f5-9ac8-a90df07f85ec_1179x578.webp&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:578,&quot;width&quot;:1179,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:false,&quot;topImage&quot;:true,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!COP6!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbe2d1426-cd58-44f5-9ac8-a90df07f85ec_1179x578.webp 424w, https://substackcdn.com/image/fetch/$s_!COP6!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbe2d1426-cd58-44f5-9ac8-a90df07f85ec_1179x578.webp 848w, https://substackcdn.com/image/fetch/$s_!COP6!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbe2d1426-cd58-44f5-9ac8-a90df07f85ec_1179x578.webp 1272w, https://substackcdn.com/image/fetch/$s_!COP6!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fbe2d1426-cd58-44f5-9ac8-a90df07f85ec_1179x578.webp 1456w" sizes="100vw" fetchpriority="high"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p class="button-wrapper" data-attrs="{&quot;url&quot;:&quot;https://www.eventbrite.com/e/machine-learning-and-generative-ai-system-design-workshop-tickets-1975103644168?aff=Tivadar&quot;,&quot;text&quot;:&quot;Reserve Your Seat&quot;,&quot;action&quot;:null,&quot;class&quot;:null}" data-component-name="ButtonCreateButton"><a class="button primary" href="https://www.eventbrite.com/e/machine-learning-and-generative-ai-system-design-workshop-tickets-1975103644168?aff=Tivadar"><span>Reserve Your Seat</span></a></p><p>Now, I&#8217;ll pass the mic to Sairam.</p><p>Enjoy!</p><p>Cheers,<br>Tivadar</p>
      <p>
          <a href="https://thepalindrome.org/p/accio-insights-the-marauders-map">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[The Palindrome in 2026]]></title><description><![CDATA[What's coming]]></description><link>https://thepalindrome.org/p/the-palindrome-in-2026</link><guid isPermaLink="false">https://thepalindrome.org/p/the-palindrome-in-2026</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Sun, 15 Feb 2026 07:50:11 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/01a35c2b-d6bb-4a35-8a50-1ac8d52b15a3_1920x1008.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hey! It's Tivadar.</p><p>Yes, I know that it is February. It took me a bit longer to write this post.</p><p>I also know that your inbox is (<em>was</em>) overloaded with triumphant 2025 reviews and grand plans for 2026. To respect your time, here's a no-bullshit summary of what you'll get from The Palindrome this year, and if you want the details, just read on.</p><p><strong>All subscribers:</strong></p><ul><li><p>I'm finishing my Machine Learning From Zero book this year, where we'll implement all the fundamental algorithms from scratch. This'll be the topic for my technical posts.</p></li><li><p>I'll do more explainer-style videos, <a href="https://youtu.be/PB-1_JTHyEU?si=-7o5KsgJjA_WYRyc">like this one from the Matrices and Graphs post</a>.</p></li></ul><p><strong>Paid subscribers:</strong></p><ul><li><p>Monthly live workshops, streamed live right here on Substack.  </p></li><li><p>First workshop: Mathematics of Machine Learning, March 7th, 15:00 - 20:00 CET.</p></li><li><p>Second workshop: Neural Networks from Scratch, date TBD.</p></li></ul>
      <p>
          <a href="https://thepalindrome.org/p/the-palindrome-in-2026">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[The Day My Project Went to Space]]></title><description><![CDATA[From whiteboard to orbit to science]]></description><link>https://thepalindrome.org/p/the-day-my-project-went-to-space</link><guid isPermaLink="false">https://thepalindrome.org/p/the-day-my-project-went-to-space</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Mon, 02 Feb 2026 12:33:14 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!C5XA!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff444b75c-8d7c-4ceb-ab1c-b20622d27b5f_1600x1200.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hi there! It&#8217;s Tivadar from The Palindrome.</p><p>Today&#8217;s post is a very special one, written by my friend Mikl&#243;s, whom I met during our PhD years. (Which was more than ten years ago. I feel old.) He is one of the smartest people I know, and he&#8217;s been doing impressive research projects since then.</p><p>One of his latest projects made the news recently, because the data collection took place on the International Space Station (ISS). This is interesting in itself, but what you rarely see is the &#8220;backend&#8221; side of science, the stuff that don&#8217;t make the news, but makes or breaks a research project of this scale.</p><p>What follows is a deep-dive report on the entire lifecycle of a space-bound project:</p><ul><li><p>grant proposal (moving from a whiteboard to orbit),</p></li><li><p>agile problem solving (like jumping hoops to meet Apple Store regulations),</p></li><li><p>stakeholder coordination (managing the logistics between international space agencies),</p></li><li><p>project management (handling &#8220;no second chance&#8221; execution under the pressure of shifting launch windo&#8230;</p></li></ul>
      <p>
          <a href="https://thepalindrome.org/p/the-day-my-project-went-to-space">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[Why is the Golden Ratio Hiding in the Fibonacci Sequence?]]></title><description><![CDATA[The non-recursive formula for Fibonacci numbers]]></description><link>https://thepalindrome.org/p/why-is-the-golden-ratio-hiding-in</link><guid isPermaLink="false">https://thepalindrome.org/p/why-is-the-golden-ratio-hiding-in</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Fri, 30 Jan 2026 09:17:44 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/43220097-ce29-4505-aa4a-da3b6f699577_2090x1080.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>The Fibonacci numbers form one of the most famous integer sequences, known for their close connection to the golden ratio, sunflower spirals, the mating habits of rabbits, and several other things.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!iE9D!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!iE9D!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png 424w, https://substackcdn.com/image/fetch/$s_!iE9D!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png 848w, https://substackcdn.com/image/fetch/$s_!iE9D!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png 1272w, https://substackcdn.com/image/fetch/$s_!iE9D!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!iE9D!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png" width="1456" height="819" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:819,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:156485,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:false,&quot;topImage&quot;:true,&quot;internalRedirect&quot;:&quot;https://thepalindrome.org/i/186281090?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!iE9D!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png 424w, https://substackcdn.com/image/fetch/$s_!iE9D!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png 848w, https://substackcdn.com/image/fetch/$s_!iE9D!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png 1272w, https://substackcdn.com/image/fetch/$s_!iE9D!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F849eea4a-dec2-4dd5-bcb4-107d3e703b30_3840x2160.png 1456w" sizes="100vw" fetchpriority="high"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Because of its recursive nature, computing the Fibonacci sequence via brute force is computationally expensive.</p><p>However, the Fibonacci numbers have a simple and beautiful closed-form expression written in terms of the golden ratio (&#966;) and the conjugate golden ratio (&#968;).</p>
      <p>
          <a href="https://thepalindrome.org/p/why-is-the-golden-ratio-hiding-in">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[How did the Babylonians know √2 up to six digits?]]></title><description><![CDATA[The greatest known computational accuracy in the ancient world]]></description><link>https://thepalindrome.org/p/how-did-the-babylonians-know-2-up-e2c</link><guid isPermaLink="false">https://thepalindrome.org/p/how-did-the-babylonians-know-2-up-e2c</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Wed, 21 Jan 2026 17:04:40 GMT</pubDate><enclosure url="https://substackcdn.com/image/youtube/w_728,c_limit/3O730YTS8Yg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>There&#8217;s an ancient Babylonian clay tablet from 1800-1600 BC that contains the square root of two with 99.9999% precision.</p><p>How did they compute it?</p><p>Let me show you:</p>
      <p>
          <a href="https://thepalindrome.org/p/how-did-the-babylonians-know-2-up-e2c">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[I Finally Listened to You and I’m So Glad I Did]]></title><description><![CDATA[(you will be too)]]></description><link>https://thepalindrome.org/p/i-finally-listened-to-you-and-im</link><guid isPermaLink="false">https://thepalindrome.org/p/i-finally-listened-to-you-and-im</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Thu, 15 Jan 2026 19:50:02 GMT</pubDate><enclosure url="https://substackcdn.com/image/youtube/w_728,c_limit/PB-1_JTHyEU" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hey there!</p><p>For the longest time, people have told me that I should start sharing my educational content in video format.</p><p>I&#8217;ve gotten compliments like the fact that my illustrations resemble those of 3B1B, for which I&#8217;m extremely honored.</p><p>So, after a few years of second-guessing whether I should dive into video content, I&#8217;ve finally decided to give it a try&#8230;</p><p>&#8230;and, in the short time I&#8217;ve been doing it, the results have amazed me.</p><h2>Introducing The Palindrome YouTube channel</h2><p>I&#8217;ve had a YouTube account since 2011, but just very recently I started shifting towards the creator side instead of being just a plain consumer.</p><p>My goal for the next couple of weeks is simple: every fan-favorite post from The Palindrome newsletter and from my social media posts will be turned into video.</p><p>So far, there are three videos uploaded to the channel. These are sort of the greatest hits of my educational content. Those that, no matter how many times I republish them, they always get a lot of engagement and I keep gett&#8230;</p>
      <p>
          <a href="https://thepalindrome.org/p/i-finally-listened-to-you-and-im">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[The Camel Principle: Why Adding Zero is the Most Powerful Trick in Mathematics]]></title><description><![CDATA[What it is, how it works, and why it is essential]]></description><link>https://thepalindrome.org/p/the-camel-principle-why-adding-zero</link><guid isPermaLink="false">https://thepalindrome.org/p/the-camel-principle-why-adding-zero</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Mon, 12 Jan 2026 20:23:58 GMT</pubDate><enclosure url="https://substackcdn.com/image/youtube/w_728,c_limit/fjMKGkocgaE" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Behold one of the mightiest tools in mathematics: the camel principle.</p><p>I am dead serious. Deep down, this tiny rule is the cog in many methods. Ones that you use every day.</p><p>Here is what it is, how it works, and why it is essential:</p>
      <p>
          <a href="https://thepalindrome.org/p/the-camel-principle-why-adding-zero">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[The Single Most Undervalued Fact of Linear Algebra]]></title><description><![CDATA[Matrices are graphs]]></description><link>https://thepalindrome.org/p/the-single-most-undervalued-fact</link><guid isPermaLink="false">https://thepalindrome.org/p/the-single-most-undervalued-fact</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Sun, 04 Jan 2026 10:25:38 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/71d0dfd0-aefe-4dd7-8f3b-9f55b9f8b70c_2304x1210.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hey! It's Tivadar from The Palindrome.</p><p>Hope that you enjoyed the Holidays! This time, I have a brand new video post for you. I'm really into video making now, so you'll see many more like this one in the future.</p><p>Enjoy!</p>
      <p>
          <a href="https://thepalindrome.org/p/the-single-most-undervalued-fact">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[The 10 Most Popular Posts of The Palindrome in 2025]]></title><description><![CDATA[Chosen by you]]></description><link>https://thepalindrome.org/p/the-10-most-popular-posts-of-the</link><guid isPermaLink="false">https://thepalindrome.org/p/the-10-most-popular-posts-of-the</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Tue, 23 Dec 2025 14:58:01 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/27203e61-02f4-4b16-9047-55f0e55862d7_1920x1008.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Hi there!</p><p>Here&#8217;s a quick compilation of the most popular posts we published on The Palindrome in 2025.</p><p>Take a chance to read some of them, in case you missed them, or revisit your favorites.</p><p>Here&#8217;s the full list:</p><h2>The 10 most popular posts of 2025</h2><ol><li><p><a href="https://thepalindrome.org/p/the-roadmap-of-mathematics-for-machine-learning">The Roadmap of Mathematics for Machine Learning</a></p></li><li><p><a href="https://thepalindrome.org/p/machine-learning-is-not-just-statistics-4d9">Machine Learning is not just Statistics</a></p></li><li><p><a href="https://thepalindrome.org/p/the-palindrome-library">Your Machine Learning Library</a></p></li><li><p><a href="https://thepalindrome.org/p/the-competitive-programmers-introduction">The Competitive Programmer&#8217;s Introduction to Graph Theory</a></p></li><li><p><a href="https://thepalindrome.org/p/coding-on-paper">Coding on Paper</a></p></li><li><p><a href="https://thepalindrome.org/p/representing-graphs">Representing Graphs</a></p></li><li><p><a href="https://thepalindrome.org/p/the-camel-principle">The Camel Principle</a></p></li><li><p><a href="https://thepalindrome.org/p/how-detective-turing-catched-the">Introduction to Algorithmic Analysis</a></p></li><li><p><a href="https://thepalindrome.org/p/comparing-algorithms">Comparing Algorithms</a></p></li><li><p><a href="https://thepalindrome.org/p/the-most-important-skill-you-were">The Most Important Skill You Were Never Taught</a></p></li></ol><p>I hope you enjoy reading them as much as I enjoyed making them for you.</p><p>And, if you have a favorite that didn&#8217;t make the list, reply to this email and let me know! I reply to all messages from you.</p>
      <p>
          <a href="https://thepalindrome.org/p/the-10-most-popular-posts-of-the">
              Read more
          </a>
      </p>
   ]]></content:encoded></item><item><title><![CDATA[Visualizing the Chain Rule]]></title><description><![CDATA[(because I can never remember the formula)]]></description><link>https://thepalindrome.org/p/visualizing-the-chain-rule</link><guid isPermaLink="false">https://thepalindrome.org/p/visualizing-the-chain-rule</guid><dc:creator><![CDATA[Tivadar Danka]]></dc:creator><pubDate>Mon, 22 Dec 2025 09:50:37 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/6c001bc0-1dda-426e-85eb-f63c033ed04d_1920x1008.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>The chain rule is one of the most important formulas of machine learning, allowing us to compute the gradient of composite functions. (Which is needed to do gradient descent and fit the model to the data.)</p><p>In a single variable, the chain rule says that</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!xz6Z!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!xz6Z!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png 424w, https://substackcdn.com/image/fetch/$s_!xz6Z!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png 848w, https://substackcdn.com/image/fetch/$s_!xz6Z!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png 1272w, https://substackcdn.com/image/fetch/$s_!xz6Z!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!xz6Z!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png" width="1456" height="531" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:531,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:32217,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:false,&quot;topImage&quot;:true,&quot;internalRedirect&quot;:&quot;https://thepalindrome.org/i/182108159?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!xz6Z!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png 424w, https://substackcdn.com/image/fetch/$s_!xz6Z!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png 848w, https://substackcdn.com/image/fetch/$s_!xz6Z!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png 1272w, https://substackcdn.com/image/fetch/$s_!xz6Z!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F89d85f1d-978d-4ac3-8a63-42188bea16bf_1920x700.png 1456w" sizes="100vw" fetchpriority="high"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>holds for any two univariate differentiable functions <em>f</em> and <em>g</em>. It&#8217;s simple, compact, and user-friendly.</p><p>However, the math quickly becomes complicated when we introduce multiple variables. And we have to, because there are billions of parameters to tune.</p><p>In the general case, we are interested in the composition of the vector-vector function <strong>g</strong>: &#8477;&#8319; &#8594; &#8477;&#7504; with the vector-scalar function <em>f</em>: &#8477;&#7504; &#8594; &#8477;. For instance, if we have</p><ul><li><p>a machine learning model with <em>n</em> parameters <strong>x</strong> = (<em>x</em>&#8321;, ..., <em>x&#8345;</em>),</p></li><li><p>a training dataset of <em>m</em> samples <strong>d</strong>&#8321;, ..., <strong>d</strong><em>&#8344;</em>,</p></li><li><p>predictions <strong>g</strong>(<strong>x</strong>) = (<em>g</em>&#8321;(<strong>x</strong>, <strong>d</strong>&#8321;), ..., <em>g&#8344;</em>(<strong>w</strong>, <strong>d</strong><em>&#8344;</em>))<em>,</em></p></li><li><p>and a loss function <em>f</em>,</p></li></ul><p>then fitting the model is equivalent to finding the maximum of the composite function <em>h</em>(<strong>x</strong>) = <em>f</em>(<strong>g</strong>(<strong>x</strong>)). (The dependence on the data in <strong>g</strong>(<strong>x</strong>) is omitted for simplicity.)</p><p>To compute the gradient, that is,</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!eDGS!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!eDGS!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png 424w, https://substackcdn.com/image/fetch/$s_!eDGS!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png 848w, https://substackcdn.com/image/fetch/$s_!eDGS!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png 1272w, https://substackcdn.com/image/fetch/$s_!eDGS!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!eDGS!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png" width="1456" height="531" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:531,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:33483,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://thepalindrome.org/i/182108159?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!eDGS!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png 424w, https://substackcdn.com/image/fetch/$s_!eDGS!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png 848w, https://substackcdn.com/image/fetch/$s_!eDGS!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png 1272w, https://substackcdn.com/image/fetch/$s_!eDGS!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F82c003f2-0af6-45a8-9f53-514f67207beb_1920x700.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>(where &#8706;<em>&#7522;h</em> denotes the partial derivative of the function <em>h</em> with respect to its <em>i</em>-th variable), the chain rule says that</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Iobu!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Iobu!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png 424w, https://substackcdn.com/image/fetch/$s_!Iobu!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png 848w, https://substackcdn.com/image/fetch/$s_!Iobu!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png 1272w, https://substackcdn.com/image/fetch/$s_!Iobu!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!Iobu!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png" width="1456" height="531" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/ce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:531,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:30402,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://thepalindrome.org/i/182108159?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Iobu!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png 424w, https://substackcdn.com/image/fetch/$s_!Iobu!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png 848w, https://substackcdn.com/image/fetch/$s_!Iobu!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png 1272w, https://substackcdn.com/image/fetch/$s_!Iobu!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fce9fefb3-812e-49d4-9f4e-1991d855e9e1_1920x700.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>This post is about what&#8217;s behind this formula.</p>
      <p>
          <a href="https://thepalindrome.org/p/visualizing-the-chain-rule">
              Read more
          </a>
      </p>
   ]]></content:encoded></item></channel></rss>