<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>Amjith Ramanujam</title>
    <link>https://amjith.com/</link>
    <description>Recent content on Amjith Ramanujam</description>
    <generator>Hugo -- gohugo.io</generator>
    <lastBuildDate>Fri, 04 Jul 2025 17:53:55 -0700</lastBuildDate><atom:link href="https://amjith.com/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Mammoth Lakes Trip</title>
      <link>https://amjith.com/blog/2025/mammoth-lakes/</link>
      <pubDate>Fri, 04 Jul 2025 17:53:55 -0700</pubDate>
      
      <guid>https://amjith.com/blog/2025/mammoth-lakes/</guid>
      <description>&lt;p&gt;We were in Mammoth Lakes for a week.&lt;/p&gt;
&lt;h2 id=&#34;day-1-canoeing-and-dnd&#34;&gt;Day 1: Canoeing and DnD&lt;/h2&gt;
&lt;p&gt;Rented a Canoe and splashed around Lake Mary for about an hour. Sempi was in
the front, Vian in the middle and I sat in the back. Our coordination was
abysmal but we managed.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://amjith.com/mammoth-lakes/Canoe.jpg&#34; alt=&#34;Canoe&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Next a hike near Horseshoe Lake on an easy trail to the double falls view
point. The kids were engrossed in their fantasy DnD world building.&lt;/p&gt;
&lt;p&gt;We got back to the condo and the kids initiated me on Dungeons and Dragons. I
designed my character (an elven wizard) and we played a quest with Sempi as our
Dungeon Master. After about 2 quests I was wiped out. Creative thinking is a
lot of work.&lt;/p&gt;
&lt;h2 id=&#34;day-2-hiking-ice-cream-and-dnd&#34;&gt;Day 2: Hiking, Ice cream and DnD&lt;/h2&gt;
&lt;p&gt;Started the day with a hard hike on a trail that was about 4mi long. The
elevation gain was a little too steep at the beginning which frustrated the
kids. But once we got to the flat sections they resumed their fantasy role
playing narration. We were all exhausted by the end of the hike. My suggestion
to go kayaking after the hike was shot down unanimously.&lt;/p&gt;
&lt;p&gt;Instead we went to an ice cream shop and got ourselves a much deserved treat.&lt;/p&gt;
&lt;p&gt;More DnD fun was had after we got home. We decided to add two more characters to
make the quests more eventful. Thanks to our DM (Sempi) for creating the
additional characters.&lt;/p&gt;
&lt;h2 id=&#34;day-3-gondola-and-bike-lesson&#34;&gt;Day 3: Gondola and Bike Lesson&lt;/h2&gt;
&lt;p&gt;Sempi was open to trying an Intro Trail Riding lesson at the Mammoth Mountain
Bike park. I was quite proud of him for being open to trying new things. I
wasn&amp;rsquo;t impressed by the instructor, he seemed inexperienced and dull. But Sempi
said he had fun after the lesson, so maybe the instructor is alright?!&lt;/p&gt;
&lt;p&gt;While Sempi was doing his lesson, Vian and I went on a gondola ride which took
us to the top of the mountain (11,053ft). Vian managed to stay courageous
during the ride in spite of his phobia of heights. We got to touch some snow at
the top of the mountain and Vian managed to pelt me with a crunchy snowball.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://amjith.com/mammoth-lakes/MammothMountain2.jpg&#34; alt=&#34;mammoth-mountain&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I think Sempi liked his biking gloves more than biking itself. I saw him
wearing his biking gloves around the house doing other activities.&lt;/p&gt;
&lt;h2 id=&#34;day-4-rest-day&#34;&gt;Day 4: Rest day&lt;/h2&gt;
&lt;p&gt;Kids wanted to have a rest day. We went to a coffee shop for some pastries and
played a table top game called &amp;ldquo;Here to Slay&amp;rdquo;. We&amp;rsquo;ve been playing that game
during breakfast everyday of our vacation. It is a fun game but it can lead to
anger and frustration if the players have a short fuse.&lt;/p&gt;
&lt;p&gt;The kids did some &lt;a href=&#34;https://BeastAcademy.com&#34;&gt;BeastAcademy&lt;/a&gt; to earn screen time.
Then it is Kirby time on Switch. Afterwards we decided to do some coding. We
created &lt;a href=&#34;https://pypi.org/project/abstractart/&#34;&gt;abstractart&lt;/a&gt; using Python
turtle library.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://raw.githubusercontent.com/amjith/kids/refs/heads/main/abstractart/screenshot.png?token=GHSAT0AAAAAADGWLROICZPXILNX3L3NFD442DMS7MA&#34; alt=&#34;abstractart&#34;  /&gt;
&lt;/p&gt;
&lt;h2 id=&#34;day-5-kayaking-and-yoshi&#34;&gt;Day 5: Kayaking and Yoshi&lt;/h2&gt;
&lt;p&gt;We went kayaking in June Lake. On the way to the lake we stopped at a Bagel
place to get a snack for Sempi. Why is that bit relevant? Keep reading. Vian
and I got a tandem kayak and Sempi got a single kayak. It was fun to kayak
around the lake. We had a little race, I think it was a tie, but Sempi might
disagree. Sempi decided to have his bagel while in the kayak. All the ducks got
the memo that there is bread nearby. So he got swarmed by half a dozen ducks
and he ended up donating half of his snack.&lt;/p&gt;
&lt;p&gt;We picked up Yoshi from the airport and had dinner in Bishop (nearby town). We
were all excited to have Yoshi join us for the second half of the vacation. The
kids missed her and I needed her to share my side glances when the kids do
something new and weird. Parenting is more fun when there is a partner to share.&lt;/p&gt;
&lt;h2 id=&#34;day-6-mountain-biking&#34;&gt;Day 6: Mountain Biking&lt;/h2&gt;
&lt;p&gt;Yoshi spent a rest day with the boys. I went to Mammoth Mountain Bike park to
ride the lifts and bike downhill. Explored a bunch of trails with Daniel
(stranger I met on the chair lift). It was a ton of fun. I was completely spent.&lt;/p&gt;
&lt;p&gt;Spent the evening watching the DnD movie &amp;ldquo;Honor Among Thieves&amp;rdquo;.&lt;/p&gt;
&lt;h2 id=&#34;day-7-biking-and-hiking&#34;&gt;Day 7: Biking and Hiking&lt;/h2&gt;
&lt;p&gt;We went to the Horseshoe lake where Yoshi and Vian did a hike with Yoshi&amp;rsquo;s
friend from elementary school who lives in Mammoth Lakes.&lt;/p&gt;
&lt;p&gt;Sempi and I biked a trail around the Horseshoe Lake. Afterwards we decided to
bike back to the town. Sempi did a great job biking even though it wasn&amp;rsquo;t his
favorite activity. Spent about an hour at Elixir Cafe while Sempi vibe coded a
word game that is inspired by scrabble.&lt;/p&gt;
&lt;h2 id=&#34;day-8-back-home&#34;&gt;Day 8: Back Home&lt;/h2&gt;
&lt;p&gt;Final day in Mammoth. I got a chance to sneak in a bike ride to the Mammoth
Rock Trail before we left Mammoth Lakes.&lt;/p&gt;
&lt;p&gt;A nice and uneventful trip back home. We got to stop at an Indian restaurant
called Clay Oven Indian Restaurant in Lockeford, CA.&lt;/p&gt;
&lt;p&gt;Happy to be back home.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We were in Mammoth Lakes for a week.</p>
<h2 id="day-1-canoeing-and-dnd">Day 1: Canoeing and DnD</h2>
<p>Rented a Canoe and splashed around Lake Mary for about an hour. Sempi was in
the front, Vian in the middle and I sat in the back. Our coordination was
abysmal but we managed.</p>
<p><img loading="lazy" src="/mammoth-lakes/Canoe.jpg" alt="Canoe"  />
</p>
<p>Next a hike near Horseshoe Lake on an easy trail to the double falls view
point. The kids were engrossed in their fantasy DnD world building.</p>
<p>We got back to the condo and the kids initiated me on Dungeons and Dragons. I
designed my character (an elven wizard) and we played a quest with Sempi as our
Dungeon Master. After about 2 quests I was wiped out. Creative thinking is a
lot of work.</p>
<h2 id="day-2-hiking-ice-cream-and-dnd">Day 2: Hiking, Ice cream and DnD</h2>
<p>Started the day with a hard hike on a trail that was about 4mi long. The
elevation gain was a little too steep at the beginning which frustrated the
kids. But once we got to the flat sections they resumed their fantasy role
playing narration. We were all exhausted by the end of the hike. My suggestion
to go kayaking after the hike was shot down unanimously.</p>
<p>Instead we went to an ice cream shop and got ourselves a much deserved treat.</p>
<p>More DnD fun was had after we got home. We decided to add two more characters to
make the quests more eventful. Thanks to our DM (Sempi) for creating the
additional characters.</p>
<h2 id="day-3-gondola-and-bike-lesson">Day 3: Gondola and Bike Lesson</h2>
<p>Sempi was open to trying an Intro Trail Riding lesson at the Mammoth Mountain
Bike park. I was quite proud of him for being open to trying new things. I
wasn&rsquo;t impressed by the instructor, he seemed inexperienced and dull. But Sempi
said he had fun after the lesson, so maybe the instructor is alright?!</p>
<p>While Sempi was doing his lesson, Vian and I went on a gondola ride which took
us to the top of the mountain (11,053ft). Vian managed to stay courageous
during the ride in spite of his phobia of heights. We got to touch some snow at
the top of the mountain and Vian managed to pelt me with a crunchy snowball.</p>
<p><img loading="lazy" src="/mammoth-lakes/MammothMountain2.jpg" alt="mammoth-mountain"  />
</p>
<p>I think Sempi liked his biking gloves more than biking itself. I saw him
wearing his biking gloves around the house doing other activities.</p>
<h2 id="day-4-rest-day">Day 4: Rest day</h2>
<p>Kids wanted to have a rest day. We went to a coffee shop for some pastries and
played a table top game called &ldquo;Here to Slay&rdquo;. We&rsquo;ve been playing that game
during breakfast everyday of our vacation. It is a fun game but it can lead to
anger and frustration if the players have a short fuse.</p>
<p>The kids did some <a href="https://BeastAcademy.com">BeastAcademy</a> to earn screen time.
Then it is Kirby time on Switch. Afterwards we decided to do some coding. We
created <a href="https://pypi.org/project/abstractart/">abstractart</a> using Python
turtle library.</p>
<p><img loading="lazy" src="https://raw.githubusercontent.com/amjith/kids/refs/heads/main/abstractart/screenshot.png?token=GHSAT0AAAAAADGWLROICZPXILNX3L3NFD442DMS7MA" alt="abstractart"  />
</p>
<h2 id="day-5-kayaking-and-yoshi">Day 5: Kayaking and Yoshi</h2>
<p>We went kayaking in June Lake. On the way to the lake we stopped at a Bagel
place to get a snack for Sempi. Why is that bit relevant? Keep reading. Vian
and I got a tandem kayak and Sempi got a single kayak. It was fun to kayak
around the lake. We had a little race, I think it was a tie, but Sempi might
disagree. Sempi decided to have his bagel while in the kayak. All the ducks got
the memo that there is bread nearby. So he got swarmed by half a dozen ducks
and he ended up donating half of his snack.</p>
<p>We picked up Yoshi from the airport and had dinner in Bishop (nearby town). We
were all excited to have Yoshi join us for the second half of the vacation. The
kids missed her and I needed her to share my side glances when the kids do
something new and weird. Parenting is more fun when there is a partner to share.</p>
<h2 id="day-6-mountain-biking">Day 6: Mountain Biking</h2>
<p>Yoshi spent a rest day with the boys. I went to Mammoth Mountain Bike park to
ride the lifts and bike downhill. Explored a bunch of trails with Daniel
(stranger I met on the chair lift). It was a ton of fun. I was completely spent.</p>
<p>Spent the evening watching the DnD movie &ldquo;Honor Among Thieves&rdquo;.</p>
<h2 id="day-7-biking-and-hiking">Day 7: Biking and Hiking</h2>
<p>We went to the Horseshoe lake where Yoshi and Vian did a hike with Yoshi&rsquo;s
friend from elementary school who lives in Mammoth Lakes.</p>
<p>Sempi and I biked a trail around the Horseshoe Lake. Afterwards we decided to
bike back to the town. Sempi did a great job biking even though it wasn&rsquo;t his
favorite activity. Spent about an hour at Elixir Cafe while Sempi vibe coded a
word game that is inspired by scrabble.</p>
<h2 id="day-8-back-home">Day 8: Back Home</h2>
<p>Final day in Mammoth. I got a chance to sneak in a bike ride to the Mammoth
Rock Trail before we left Mammoth Lakes.</p>
<p>A nice and uneventful trip back home. We got to stop at an Indian restaurant
called Clay Oven Indian Restaurant in Lockeford, CA.</p>
<p>Happy to be back home.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>LLM in Litecli - 2</title>
      <link>https://amjith.com/blog/2025/llm-in-litecli-2/</link>
      <pubDate>Mon, 27 Jan 2025 16:07:17 -0800</pubDate>
      
      <guid>https://amjith.com/blog/2025/llm-in-litecli-2/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://amjith.com/blog/2025/llm-in-litecli-1/&#34;&gt;Part 1&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://litecli.com&#34;&gt;LiteCLI&lt;/a&gt; has an optional feature to use LLM powered SQL generation to get
answers from your database.&lt;/p&gt;
&lt;p&gt;The default LLM used by LiteCLI is OpenAI&amp;rsquo;s gpt-4o-mini. This can be changed to a
different model including a local LLM running on Ollama.&lt;/p&gt;
&lt;p&gt;Here are the steps to show how to switch your LLM model.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Run &lt;code&gt;\llm&lt;/code&gt;  to enable the feature.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;sqlite&amp;gt; \llm
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;This will offer to enable this feature by installing the necessary libraries.
If you have already done this then it&amp;rsquo;ll print the &amp;ldquo;usage&amp;rdquo; documentation.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Run &lt;code&gt;\llm models&lt;/code&gt; to see the list of available models:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;sqlite&amp;gt; \llm models
OpenAI Chat: gpt-4o (aliases: 4o)
OpenAI Chat: gpt-4o-mini (aliases: 4o-mini)
OpenAI Chat: gpt-4 (aliases: 4, gpt4)
....
....
OpenAI Chat: o1
OpenAI Chat: o1-2024-12-17
OpenAI Chat: o1-preview
OpenAI Chat: o1-mini
Default: gpt-4o-mini
&lt;/code&gt;&lt;/pre&gt;&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;The &lt;code&gt;llm&lt;/code&gt; library has &lt;a href=&#34;https://llm.datasette.io/en/stable/plugins/index.html&#34;&gt;plugins&lt;/a&gt; that can enable access to more models. You can install additional plugins from right inside LiteCLI.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;sqlite&amp;gt; \llm install llm-gemini
sqlite&amp;gt; \llm models
OpenAI Chat: gpt-4o-mini (aliases: 4o-mini)
OpenAI Chat: o1-mini
...
...
GeminiPro: gemini-pro
GeminiPro: gemini-1.5-pro-latest
...
...
GeminiPro: gemini-2.0-flash-thinking-exp-01-21
Default: gpt-4o-mini
&lt;/code&gt;&lt;/pre&gt;&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;To use a local model first install &lt;a href=&#34;https://ollama.com/download&#34;&gt;ollama&lt;/a&gt; and
launch it. This is a background process that serves local models that you
can access with the data leaving your computer. Install a local model that
you can run locally using ollama command line tool.&lt;/p&gt;
&lt;p&gt;Outside LiteCLI:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;$ ollama pull qwen2.5-coder
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Inside LiteCLI:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;sqlite&amp;gt; \llm install llm-ollama
sqlite&amp;gt; \llm models
OpenAI Chat: gpt-4o-mini (aliases: 4o-mini)
OpenAI Chat: o1-mini
....
Ollama: deepseek-r1:latest (aliases: deepseek-r1)
Default: gpt-4o-mini
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Switch the default to your desired model:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;sqlite&amp;gt; \llm models default qwen2.5-coder
&lt;/code&gt;&lt;/pre&gt;&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Ask your questions and enjoy the benefits.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;sqlite&amp;gt; \llm &amp;quot;Customer with highest sales in the last month&amp;quot;
sqlite&amp;gt; SELECT customer
        FROM sales
        WHERE datetime(timestamp / 1000000, &#39;unixepoch&#39;) &amp;gt;= datetime(&#39;now&#39;, &#39;-1 month&#39;)
        ORDER BY amount DESC LIMIT 1;
&lt;/code&gt;&lt;/pre&gt;&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;If you want to see the context in addition to the SQL query you can use &lt;code&gt;\llm+&lt;/code&gt; command.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt; sqlite&amp;gt; \llm+ &amp;quot;Top 5 urls visited.&amp;quot;
 To determine the &amp;quot;Top 5 URLs visited,&amp;quot; the following tables are utilized:

 **`urls`**: This table contains the URL information along with the
   `visit_count`, which tracks how many times each URL has been visited.
   Using this table allows for an efficient retrieval of the most
   visited URLs without the need for complex aggregations.

 **SQL Query:**

 SELECT url, visit_count
 FROM urls
 ORDER BY visit_count DESC
 LIMIT 5;

 sqlite&amp;gt; SELECT url, visit_count
         FROM urls
         ORDER BY visit_count DESC
         LIMIT 5;
&lt;/code&gt;&lt;/pre&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;If you run into issues feel free to file a Github &lt;a href=&#34;https://github.com/dbcli/litecli/&#34;&gt;issue&lt;/a&gt;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p><a href="https://amjith.com/blog/2025/llm-in-litecli-1/">Part 1</a></p>
<p><a href="https://litecli.com">LiteCLI</a> has an optional feature to use LLM powered SQL generation to get
answers from your database.</p>
<p>The default LLM used by LiteCLI is OpenAI&rsquo;s gpt-4o-mini. This can be changed to a
different model including a local LLM running on Ollama.</p>
<p>Here are the steps to show how to switch your LLM model.</p>
<ol>
<li>
<p>Run <code>\llm</code>  to enable the feature.</p>
<pre><code>sqlite&gt; \llm
</code></pre><p>This will offer to enable this feature by installing the necessary libraries.
If you have already done this then it&rsquo;ll print the &ldquo;usage&rdquo; documentation.</p>
</li>
<li>
<p>Run <code>\llm models</code> to see the list of available models:</p>
<pre><code>sqlite&gt; \llm models
OpenAI Chat: gpt-4o (aliases: 4o)
OpenAI Chat: gpt-4o-mini (aliases: 4o-mini)
OpenAI Chat: gpt-4 (aliases: 4, gpt4)
....
....
OpenAI Chat: o1
OpenAI Chat: o1-2024-12-17
OpenAI Chat: o1-preview
OpenAI Chat: o1-mini
Default: gpt-4o-mini
</code></pre></li>
<li>
<p>The <code>llm</code> library has <a href="https://llm.datasette.io/en/stable/plugins/index.html">plugins</a> that can enable access to more models. You can install additional plugins from right inside LiteCLI.</p>
<pre><code>sqlite&gt; \llm install llm-gemini
sqlite&gt; \llm models
OpenAI Chat: gpt-4o-mini (aliases: 4o-mini)
OpenAI Chat: o1-mini
...
...
GeminiPro: gemini-pro
GeminiPro: gemini-1.5-pro-latest
...
...
GeminiPro: gemini-2.0-flash-thinking-exp-01-21
Default: gpt-4o-mini
</code></pre></li>
<li>
<p>To use a local model first install <a href="https://ollama.com/download">ollama</a> and
launch it. This is a background process that serves local models that you
can access with the data leaving your computer. Install a local model that
you can run locally using ollama command line tool.</p>
<p>Outside LiteCLI:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">$ ollama pull qwen2.5-coder
</code></pre></div><p>Inside LiteCLI:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-text" data-lang="text">sqlite&gt; \llm install llm-ollama
sqlite&gt; \llm models
OpenAI Chat: gpt-4o-mini (aliases: 4o-mini)
OpenAI Chat: o1-mini
....
Ollama: deepseek-r1:latest (aliases: deepseek-r1)
Default: gpt-4o-mini
</code></pre></div></li>
<li>
<p>Switch the default to your desired model:</p>
<pre><code>sqlite&gt; \llm models default qwen2.5-coder
</code></pre></li>
<li>
<p>Ask your questions and enjoy the benefits.</p>
<pre><code>sqlite&gt; \llm &quot;Customer with highest sales in the last month&quot;
sqlite&gt; SELECT customer
        FROM sales
        WHERE datetime(timestamp / 1000000, 'unixepoch') &gt;= datetime('now', '-1 month')
        ORDER BY amount DESC LIMIT 1;
</code></pre></li>
<li>
<p>If you want to see the context in addition to the SQL query you can use <code>\llm+</code> command.</p>
<pre><code> sqlite&gt; \llm+ &quot;Top 5 urls visited.&quot;
 To determine the &quot;Top 5 URLs visited,&quot; the following tables are utilized:

 **`urls`**: This table contains the URL information along with the
   `visit_count`, which tracks how many times each URL has been visited.
   Using this table allows for an efficient retrieval of the most
   visited URLs without the need for complex aggregations.

 **SQL Query:**

 SELECT url, visit_count
 FROM urls
 ORDER BY visit_count DESC
 LIMIT 5;

 sqlite&gt; SELECT url, visit_count
         FROM urls
         ORDER BY visit_count DESC
         LIMIT 5;
</code></pre></li>
</ol>
<p>If you run into issues feel free to file a Github <a href="https://github.com/dbcli/litecli/">issue</a>.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>LLM in Litecli</title>
      <link>https://amjith.com/blog/2025/llm-in-litecli-1/</link>
      <pubDate>Sat, 25 Jan 2025 16:07:17 -0800</pubDate>
      
      <guid>https://amjith.com/blog/2025/llm-in-litecli-1/</guid>
      <description>&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;** This feature is ONLY enabled when it is used for the first time. **
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;a href=&#34;https://litecli.com&#34;&gt;LiteCLI&lt;/a&gt; v1.14.2 now has an LLM feature to help you write SQL.&lt;/p&gt;
&lt;div id=&#34;demo1&#34;&gt;&lt;/div&gt;
&lt;script&gt;
  AsciinemaPlayer.create(&#39;/llm-in-litecli-1/litecli1.cast&#39;, document.getElementById(&#39;demo1&#39;),
  {
  idleTimeLimit: 2,
  poster: &#39;npt:0:07&#39;,
  terminalFontSize: &#34;15px&#34;,
  fit: false,
  });
&lt;/script&gt;
&lt;h3 id=&#34;getting-started&#34;&gt;Getting Started:&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;Upgrade litecli to the latest version (at least v1.14.2 or higher).&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;uv tool install litecli@latest
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Open a SQLite database with litecli.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;$ litecli your_database_file.db
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;ol start=&#34;2&#34;&gt;
&lt;li&gt;
&lt;p&gt;Run the special command &lt;code&gt;\llm&lt;/code&gt; in the LiteCLI prompt. This will install the necessary &lt;a href=&#34;https://llm.datasette.io/&#34;&gt;dependency&lt;/a&gt; to interact with LLMs.
The default model is gpt-4o-mini which is a remote model. You need an &lt;a href=&#34;https://platform.openai.com/api-keys&#34;&gt;API key&lt;/a&gt; from OpenAI.
You can switch the default to a local model such as Ollama or Llamafile. Docs on that are available in &lt;a href=&#34;https://amjith.com/blog/2025/llm-in-litecli-2/&#34;&gt;part 2&lt;/a&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Run &lt;code&gt;\llm keys set openai&lt;/code&gt; which will prompt you to paste your API key.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Ask a question:&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;SQLite&amp;gt; \llm &amp;quot;Your Question Here&amp;quot;
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;For eg, I&amp;rsquo;m exploring my Chrome history database.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;SQLite&amp;gt; \llm &amp;quot;Top 5 most visited URLs&amp;quot;
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;This question is sent to the LLM along with the metadata that describes the
database tables and a sample row from each table.
The SQL query in the LLMs response is extracted and pre-filled in your litecli
prompt.&lt;/p&gt;
&lt;p&gt;A lot of folks are skeptical of LLMs and especially wary of sending data from
your database to an external service. That&amp;rsquo;s why this feature is not builtin to
the default installation. When you install LiteCLI it does NOT enable this
feature or install any libraries to interact with an LLM. Instead the libraries
are installed when you use it for the first time. Even then you need to add an
API key in order to send your queries to an external LLM service.&lt;/p&gt;
&lt;p&gt;To use this feature with a locally hosted LLM please check out &lt;a href=&#34;https://amjith.com/blog/2025/llm-in-litecli-2/&#34;&gt;part 2&lt;/a&gt; of this
blog post.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-text" data-lang="text">** This feature is ONLY enabled when it is used for the first time. **
</code></pre></div><p><a href="https://litecli.com">LiteCLI</a> v1.14.2 now has an LLM feature to help you write SQL.</p>
<div id="demo1"></div>
<script>
  AsciinemaPlayer.create('/llm-in-litecli-1/litecli1.cast', document.getElementById('demo1'),
  {
  idleTimeLimit: 2,
  poster: 'npt:0:07',
  terminalFontSize: "15px",
  fit: false,
  });
</script>
<h3 id="getting-started">Getting Started:</h3>
<ol>
<li>Upgrade litecli to the latest version (at least v1.14.2 or higher).</li>
</ol>
<pre><code>uv tool install litecli@latest
</code></pre><p>Open a SQLite database with litecli.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">$ litecli your_database_file.db
</code></pre></div><ol start="2">
<li>
<p>Run the special command <code>\llm</code> in the LiteCLI prompt. This will install the necessary <a href="https://llm.datasette.io/">dependency</a> to interact with LLMs.
The default model is gpt-4o-mini which is a remote model. You need an <a href="https://platform.openai.com/api-keys">API key</a> from OpenAI.
You can switch the default to a local model such as Ollama or Llamafile. Docs on that are available in <a href="https://amjith.com/blog/2025/llm-in-litecli-2/">part 2</a>.</p>
</li>
<li>
<p>Run <code>\llm keys set openai</code> which will prompt you to paste your API key.</p>
</li>
<li>
<p>Ask a question:</p>
</li>
</ol>
<pre><code>SQLite&gt; \llm &quot;Your Question Here&quot;
</code></pre><p>For eg, I&rsquo;m exploring my Chrome history database.</p>
<pre><code>SQLite&gt; \llm &quot;Top 5 most visited URLs&quot;
</code></pre><p>This question is sent to the LLM along with the metadata that describes the
database tables and a sample row from each table.
The SQL query in the LLMs response is extracted and pre-filled in your litecli
prompt.</p>
<p>A lot of folks are skeptical of LLMs and especially wary of sending data from
your database to an external service. That&rsquo;s why this feature is not builtin to
the default installation. When you install LiteCLI it does NOT enable this
feature or install any libraries to interact with an LLM. Instead the libraries
are installed when you use it for the first time. Even then you need to add an
API key in order to send your queries to an external LLM service.</p>
<p>To use this feature with a locally hosted LLM please check out <a href="https://amjith.com/blog/2025/llm-in-litecli-2/">part 2</a> of this
blog post.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Auto-Completing Click Commands</title>
      <link>https://amjith.com/blog/2025/autocompletion-click-commands/</link>
      <pubDate>Sat, 04 Jan 2025 13:58:22 -0800</pubDate>
      
      <guid>https://amjith.com/blog/2025/autocompletion-click-commands/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://click.palletsprojects.com/en/stable/&#34;&gt;Click&lt;/a&gt; is a python library for creating command line applications in Python.&lt;/p&gt;
&lt;p&gt;The &lt;a href=&#34;https://llm.datasette.io/en/stable/usage.html&#34;&gt;llm&lt;/a&gt; tool created by
&lt;a href=&#34;https://simonwillison.net/&#34;&gt;Simon&lt;/a&gt; uses click and it has a lot of subcommands.&lt;/p&gt;
&lt;p&gt;eg:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;$ llm keys set openai
Enter key: ...

$ llm models default
gpt-4o
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I am building a wrapper around this CLI tool that let&amp;rsquo;s me use it in an
interactive REPL. I wanted autocompletion to help me remind the available
subcommands and their appropriate nested subcommands.&lt;/p&gt;
&lt;p&gt;Here&amp;rsquo;s how I got a list of all the nested subcommands and built an
autocompletion engine.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; llm
&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; llm.cli &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; cli

MODELS &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; {x&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;model_id: &lt;span style=&#34;color:#66d9ef&#34;&gt;None&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; x &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; llm&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;get_models()}

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;build_command_tree&lt;/span&gt;(cmd):
    &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&amp;#34;Recursively build a command tree for a Click app.
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;    Args:
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;        cmd (click.Command or click.Group): The Click command/group to inspect.
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;    Returns:
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;        dict: A nested dictionary representing the command structure.
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;    &amp;#34;&amp;#34;&amp;#34;&lt;/span&gt;
    tree &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; {}
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; isinstance(cmd, click&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Group):
        &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; name, subcmd &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; cmd&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;commands&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;items():
            &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; cmd&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;models&amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;and&lt;/span&gt; name &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;default&amp;#34;&lt;/span&gt;:
                tree[name] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; MODELS  &lt;span style=&#34;color:#75715e&#34;&gt;# List of available models&lt;/span&gt;
            &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
                &lt;span style=&#34;color:#75715e&#34;&gt;# Recursively build the tree for subcommands&lt;/span&gt;
                tree[name] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; build_command_tree(subcmd)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
        &lt;span style=&#34;color:#75715e&#34;&gt;# Leaf command with no subcommands&lt;/span&gt;
        tree &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;None&lt;/span&gt;
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; tree


&lt;span style=&#34;color:#75715e&#34;&gt;# Generate the tree&lt;/span&gt;
COMMAND_TREE &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; build_command_tree(cli)


&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;get_completions&lt;/span&gt;(tokens, tree&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;COMMAND_TREE):
    &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&amp;#34;Get autocompletions for the current command tokens.
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;    Args:
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;        tree (dict): The command tree.
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;        tokens (list): List of tokens (command arguments).
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;    Returns:
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;        list: List of possible completions.
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;    &amp;#34;&amp;#34;&amp;#34;&lt;/span&gt;
    &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; token &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; tokens:
        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; token&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;startswith(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;-&amp;#34;&lt;/span&gt;):
            &lt;span style=&#34;color:#75715e&#34;&gt;# Skip options (flags)&lt;/span&gt;
            &lt;span style=&#34;color:#66d9ef&#34;&gt;continue&lt;/span&gt;
        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; tree &lt;span style=&#34;color:#f92672&#34;&gt;and&lt;/span&gt; token &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; tree:
            tree &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; tree[token]
        &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
            &lt;span style=&#34;color:#75715e&#34;&gt;# No completions available&lt;/span&gt;
            &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; []

    &lt;span style=&#34;color:#75715e&#34;&gt;# Return possible completions (keys of the current tree level)&lt;/span&gt;
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; list(tree&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;keys()) &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; tree &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt; []

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; __name__ &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;__main__&amp;#34;&lt;/span&gt;:
    tokens &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;:]  &lt;span style=&#34;color:#75715e&#34;&gt;# Remove `llm` and pass in the rest of the args&lt;/span&gt;
    print(get_completions(tokens))
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This suggests possible nested subcommands based on the input. Additionally it also
suggests the available LLM models after the &lt;code&gt;llm models default&lt;/code&gt; subcommand.&lt;/p&gt;
&lt;p&gt;eg:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;$ python autocomplete_llm.py llm models
[&#39;list&#39;, &#39;default&#39;]

$ python autocomplete_llm.py llm models default
[&#39;gpt-4o&#39;, &#39;gpt-4o-mini&#39;, &#39;gpt-4o-audio-preview&#39;, &#39;gpt-3.5-turbo&#39;, &#39;gpt-3.5-turbo-16k&#39;, &#39;gpt-4&#39;, &#39;gpt-4-32k&#39;, &#39;gpt-4-1106-preview&#39;, &#39;gpt-4-0125-preview&#39;, &#39;gpt-4-turbo-2024-04-09&#39;, &#39;gpt-4-turbo&#39;, &#39;o1-preview&#39;, &#39;o1-mini&#39;, &#39;gpt-3.5-turbo-instruct&#39;]
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;What is the purpose of this? I&amp;rsquo;m building a new feature in
&lt;a href=&#34;https://github.com/dbcli/litecli/&#34;&gt;litecli&lt;/a&gt; that&amp;rsquo;ll embed &lt;code&gt;llm&lt;/code&gt; tool and allow
users to create SQL queries using the help of LLMs. When a user is invoking
&lt;code&gt;llm&lt;/code&gt; inside &lt;code&gt;litecli&lt;/code&gt; I&amp;rsquo;d hate for them to switch to the terminal just to find
out how to use a specific subcommand or even list all available subcommands.&lt;/p&gt;
&lt;p&gt;By adding this autocompletion, it keeps users in the flow state and avoids an
unnecessary context switch. The feature is not quite ready for release, but I&amp;rsquo;m
quite excited by the potential of it.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p><a href="https://click.palletsprojects.com/en/stable/">Click</a> is a python library for creating command line applications in Python.</p>
<p>The <a href="https://llm.datasette.io/en/stable/usage.html">llm</a> tool created by
<a href="https://simonwillison.net/">Simon</a> uses click and it has a lot of subcommands.</p>
<p>eg:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-text" data-lang="text">$ llm keys set openai
Enter key: ...

$ llm models default
gpt-4o
</code></pre></div><p>I am building a wrapper around this CLI tool that let&rsquo;s me use it in an
interactive REPL. I wanted autocompletion to help me remind the available
subcommands and their appropriate nested subcommands.</p>
<p>Here&rsquo;s how I got a list of all the nested subcommands and built an
autocompletion engine.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-python" data-lang="python"><span style="color:#f92672">import</span> llm
<span style="color:#f92672">from</span> llm.cli <span style="color:#f92672">import</span> cli

MODELS <span style="color:#f92672">=</span> {x<span style="color:#f92672">.</span>model_id: <span style="color:#66d9ef">None</span> <span style="color:#66d9ef">for</span> x <span style="color:#f92672">in</span> llm<span style="color:#f92672">.</span>get_models()}

<span style="color:#66d9ef">def</span> <span style="color:#a6e22e">build_command_tree</span>(cmd):
    <span style="color:#e6db74">&#34;&#34;&#34;Recursively build a command tree for a Click app.
</span><span style="color:#e6db74">
</span><span style="color:#e6db74">    Args:
</span><span style="color:#e6db74">        cmd (click.Command or click.Group): The Click command/group to inspect.
</span><span style="color:#e6db74">
</span><span style="color:#e6db74">    Returns:
</span><span style="color:#e6db74">        dict: A nested dictionary representing the command structure.
</span><span style="color:#e6db74">    &#34;&#34;&#34;</span>
    tree <span style="color:#f92672">=</span> {}
    <span style="color:#66d9ef">if</span> isinstance(cmd, click<span style="color:#f92672">.</span>Group):
        <span style="color:#66d9ef">for</span> name, subcmd <span style="color:#f92672">in</span> cmd<span style="color:#f92672">.</span>commands<span style="color:#f92672">.</span>items():
            <span style="color:#66d9ef">if</span> cmd<span style="color:#f92672">.</span>name <span style="color:#f92672">==</span> <span style="color:#e6db74">&#34;models&#34;</span> <span style="color:#f92672">and</span> name <span style="color:#f92672">==</span> <span style="color:#e6db74">&#34;default&#34;</span>:
                tree[name] <span style="color:#f92672">=</span> MODELS  <span style="color:#75715e"># List of available models</span>
            <span style="color:#66d9ef">else</span>:
                <span style="color:#75715e"># Recursively build the tree for subcommands</span>
                tree[name] <span style="color:#f92672">=</span> build_command_tree(subcmd)
    <span style="color:#66d9ef">else</span>:
        <span style="color:#75715e"># Leaf command with no subcommands</span>
        tree <span style="color:#f92672">=</span> <span style="color:#66d9ef">None</span>
    <span style="color:#66d9ef">return</span> tree


<span style="color:#75715e"># Generate the tree</span>
COMMAND_TREE <span style="color:#f92672">=</span> build_command_tree(cli)


<span style="color:#66d9ef">def</span> <span style="color:#a6e22e">get_completions</span>(tokens, tree<span style="color:#f92672">=</span>COMMAND_TREE):
    <span style="color:#e6db74">&#34;&#34;&#34;Get autocompletions for the current command tokens.
</span><span style="color:#e6db74">
</span><span style="color:#e6db74">    Args:
</span><span style="color:#e6db74">        tree (dict): The command tree.
</span><span style="color:#e6db74">        tokens (list): List of tokens (command arguments).
</span><span style="color:#e6db74">
</span><span style="color:#e6db74">    Returns:
</span><span style="color:#e6db74">        list: List of possible completions.
</span><span style="color:#e6db74">    &#34;&#34;&#34;</span>
    <span style="color:#66d9ef">for</span> token <span style="color:#f92672">in</span> tokens:
        <span style="color:#66d9ef">if</span> token<span style="color:#f92672">.</span>startswith(<span style="color:#e6db74">&#34;-&#34;</span>):
            <span style="color:#75715e"># Skip options (flags)</span>
            <span style="color:#66d9ef">continue</span>
        <span style="color:#66d9ef">if</span> tree <span style="color:#f92672">and</span> token <span style="color:#f92672">in</span> tree:
            tree <span style="color:#f92672">=</span> tree[token]
        <span style="color:#66d9ef">else</span>:
            <span style="color:#75715e"># No completions available</span>
            <span style="color:#66d9ef">return</span> []

    <span style="color:#75715e"># Return possible completions (keys of the current tree level)</span>
    <span style="color:#66d9ef">return</span> list(tree<span style="color:#f92672">.</span>keys()) <span style="color:#66d9ef">if</span> tree <span style="color:#66d9ef">else</span> []

<span style="color:#66d9ef">if</span> __name__ <span style="color:#f92672">==</span> <span style="color:#e6db74">&#34;__main__&#34;</span>:
    tokens <span style="color:#f92672">=</span> sys<span style="color:#f92672">.</span>argv[<span style="color:#ae81ff">2</span>:]  <span style="color:#75715e"># Remove `llm` and pass in the rest of the args</span>
    print(get_completions(tokens))
</code></pre></div><p>This suggests possible nested subcommands based on the input. Additionally it also
suggests the available LLM models after the <code>llm models default</code> subcommand.</p>
<p>eg:</p>
<pre><code>$ python autocomplete_llm.py llm models
['list', 'default']

$ python autocomplete_llm.py llm models default
['gpt-4o', 'gpt-4o-mini', 'gpt-4o-audio-preview', 'gpt-3.5-turbo', 'gpt-3.5-turbo-16k', 'gpt-4', 'gpt-4-32k', 'gpt-4-1106-preview', 'gpt-4-0125-preview', 'gpt-4-turbo-2024-04-09', 'gpt-4-turbo', 'o1-preview', 'o1-mini', 'gpt-3.5-turbo-instruct']
</code></pre><p>What is the purpose of this? I&rsquo;m building a new feature in
<a href="https://github.com/dbcli/litecli/">litecli</a> that&rsquo;ll embed <code>llm</code> tool and allow
users to create SQL queries using the help of LLMs. When a user is invoking
<code>llm</code> inside <code>litecli</code> I&rsquo;d hate for them to switch to the terminal just to find
out how to use a specific subcommand or even list all available subcommands.</p>
<p>By adding this autocompletion, it keeps users in the flow state and avoids an
unnecessary context switch. The feature is not quite ready for release, but I&rsquo;m
quite excited by the potential of it.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Restart a Python CLI</title>
      <link>https://amjith.com/blog/2025/restart-python-cli/</link>
      <pubDate>Sat, 04 Jan 2025 13:29:54 -0800</pubDate>
      
      <guid>https://amjith.com/blog/2025/restart-python-cli/</guid>
      <description>&lt;p&gt;A simple snippet to restart a Python CLI from within the CLI.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; os
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; sys
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; click

&lt;span style=&#34;color:#a6e22e&#34;&gt;@click&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;command()
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;cli&lt;/span&gt;():
    click&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;echo(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;CLI is running.&amp;#34;&lt;/span&gt;)
    &lt;span style=&#34;color:#75715e&#34;&gt;# Logic that determines when to restart&lt;/span&gt;
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; click&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;confirm(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Do you want to restart the CLI?&amp;#34;&lt;/span&gt;):
        click&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;echo(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Restarting CLI...&amp;#34;&lt;/span&gt;)
        executable &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;executable
        args &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv
        os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;execv(executable, [executable] &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; args)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
        click&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;echo(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Exiting CLI.&amp;#34;&lt;/span&gt;)

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; __name__ &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;__main__&amp;#39;&lt;/span&gt;:
    cli()
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;code&gt;os.execv&lt;/code&gt; is the system call that can replace the current process with a new
one. In this case we&amp;rsquo;re simply supplying the same executable and all the args
that were passed in while starting the CLI to &lt;code&gt;os.execv()&lt;/code&gt; thus effectively
restarting the process.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>A simple snippet to restart a Python CLI from within the CLI.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-python" data-lang="python"><span style="color:#f92672">import</span> os
<span style="color:#f92672">import</span> sys
<span style="color:#f92672">import</span> click

<span style="color:#a6e22e">@click</span><span style="color:#f92672">.</span>command()
<span style="color:#66d9ef">def</span> <span style="color:#a6e22e">cli</span>():
    click<span style="color:#f92672">.</span>echo(<span style="color:#e6db74">&#34;CLI is running.&#34;</span>)
    <span style="color:#75715e"># Logic that determines when to restart</span>
    <span style="color:#66d9ef">if</span> click<span style="color:#f92672">.</span>confirm(<span style="color:#e6db74">&#34;Do you want to restart the CLI?&#34;</span>):
        click<span style="color:#f92672">.</span>echo(<span style="color:#e6db74">&#34;Restarting CLI...&#34;</span>)
        executable <span style="color:#f92672">=</span> sys<span style="color:#f92672">.</span>executable
        args <span style="color:#f92672">=</span> sys<span style="color:#f92672">.</span>argv
        os<span style="color:#f92672">.</span>execv(executable, [executable] <span style="color:#f92672">+</span> args)
    <span style="color:#66d9ef">else</span>:
        click<span style="color:#f92672">.</span>echo(<span style="color:#e6db74">&#34;Exiting CLI.&#34;</span>)

<span style="color:#66d9ef">if</span> __name__ <span style="color:#f92672">==</span> <span style="color:#e6db74">&#39;__main__&#39;</span>:
    cli()
</code></pre></div><p><code>os.execv</code> is the system call that can replace the current process with a new
one. In this case we&rsquo;re simply supplying the same executable and all the args
that were passed in while starting the CLI to <code>os.execv()</code> thus effectively
restarting the process.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Introducing LLMs to Litecli</title>
      <link>https://amjith.com/blog/2024/introducing-llm-to-litecli/</link>
      <pubDate>Sun, 15 Dec 2024 09:28:42 -0800</pubDate>
      
      <guid>https://amjith.com/blog/2024/introducing-llm-to-litecli/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://github.com/dbcli/litecli/&#34;&gt;LiteCLI&lt;/a&gt; is a command-line client for SQLite databases that has auto-completion and syntax highlighting. I&amp;rsquo;ve added the ability to use an LLM to create a SQL query.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Disclaimer: This is an EXPERIMENTAL feature. Not yet &lt;a href=&#34;https://github.com/dbcli/litecli/tree/ai&#34;&gt;released&lt;/a&gt;.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Ask a question about your database in English and get a SQL query back to find out the answer.&lt;/p&gt;
&lt;p&gt;This is the SQLite db used by Chrome.&lt;/p&gt;
&lt;div id=&#34;demo1&#34;&gt;&lt;/div&gt;
&lt;script&gt;
  AsciinemaPlayer.create(&#39;/introducing-llm-to-litecli/litecli1.cast&#39;, document.getElementById(&#39;demo1&#39;),
  {
  idleTimeLimit: 2,
  poster: &#39;npt:0:07&#39;,
  terminalFontSize: &#34;15px&#34;,
  fit: false,
  });
&lt;/script&gt;
&lt;p&gt;Exploring my Chrome history to find interesting things about my browsing habits.&lt;/p&gt;
&lt;p&gt;Adjust the SQL before executing it. Sometimes the SQL returned by the LLM is
close but not quite right. No problem we can edit the query with all the
litecli &lt;a href=&#34;https://litecli.com/features/&#34;&gt;features&lt;/a&gt; before executing it.&lt;/p&gt;
&lt;div id=&#34;demo2&#34;&gt;&lt;/div&gt;
&lt;script&gt;
  AsciinemaPlayer.create(&#39;/introducing-llm-to-litecli/litecli2.cast&#39;, document.getElementById(&#39;demo2&#39;),
  {
  idleTimeLimit: 1,
  speed: 1.2,
  poster: &#39;npt:0:20&#39;,
  terminalFontSize: &#34;small&#34;,
  markers: [
    [20, &#39;Edit&#39;]
  ],
  fit: false,
  });
&lt;/script&gt;
&lt;p&gt;Edit the query before execution.&lt;/p&gt;
&lt;p&gt;The explanation for the SQL query is provided to help understand the reasoning
behind it. The explanation is useful for the LLMs themselves to produce &lt;a href=&#34;https://openai.com/index/learning-to-reason-with-llms/#chain-of-thought&#34;&gt;higher
quality&lt;/a&gt;
answers.&lt;/p&gt;
&lt;div id=&#34;demo3&#34;&gt;&lt;/div&gt;
&lt;script&gt;
  AsciinemaPlayer.create(&#39;/introducing-llm-to-litecli/litecli3.cast&#39;, document.getElementById(&#39;demo3&#39;),
  {
  idleTimeLimit: 2,
  poster: &#39;npt:0:11&#39;,
  pauseOnMarkers: true,
  terminalFontSize: &#34;15px&#34;,
  fit: false,
  markers: [
    [11, &#39;Explanation&#39;]
  ]
  });
&lt;/script&gt;
&lt;h3 id=&#34;implementation-details&#34;&gt;Implementation Details&lt;/h3&gt;
&lt;p&gt;This feature uses the &lt;a href=&#34;https://llm.datasette.io/en/stable/&#34;&gt;llm&lt;/a&gt; python library to interface with an LLM.&lt;/p&gt;
&lt;p&gt;The final &lt;a href=&#34;https://github.com/dbcli/litecli/blob/ai/litecli/packages/special/iocommands.py#L231-L248&#34;&gt;prompt&lt;/a&gt; sent to the LLM includes the schema for the database and an example row from each table in the database. The prompt is designed to craft a SQL query to answer your question.&lt;/p&gt;
&lt;p&gt;The demo above uses GPT-4o model. But the model can be swapped out for a local
LLM running in &lt;a href=&#34;https://ollama.com/&#34;&gt;Ollama&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I learned a few things from this experiment.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Chrome History stores the timestamps as microseconds since 1601-01-01.&lt;/li&gt;
&lt;li&gt;Both GPT-4o and Claude 3.5 Haiku recognized the Chrome history DB and crafted my SQL queries to adjust for this special start timestamp.&lt;/li&gt;
&lt;li&gt;Local LLMs (especially &lt;a href=&#34;https://ollama.com/library/qwen2.5-coder&#34;&gt;qwen2.5-coder&lt;/a&gt;) are good enough and fast enough to produce high quality results.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3 id=&#34;inspiration&#34;&gt;Inspiration&lt;/h3&gt;
&lt;p&gt;This feature is heavily inspired by &lt;a href=&#34;https://simonwillison.net/2024/Nov/25/ask-questions-of-sqlite/&#34;&gt;Simon&lt;/a&gt;&amp;rsquo;s sqlite-utils-ask plugin. Thanks to Simon for creating the &lt;a href=&#34;https://llm.datasette.io/en/stable/setup.html&#34;&gt;llm library&lt;/a&gt; that made it trivial to add this feature.&lt;/p&gt;
&lt;p&gt;This feature currently lives in a git branch: &lt;a href=&#34;https://github.com/dbcli/litecli/tree/ai&#34;&gt;https://github.com/dbcli/litecli/tree/ai&lt;/a&gt;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p><a href="https://github.com/dbcli/litecli/">LiteCLI</a> is a command-line client for SQLite databases that has auto-completion and syntax highlighting. I&rsquo;ve added the ability to use an LLM to create a SQL query.</p>
<p><strong>Disclaimer: This is an EXPERIMENTAL feature. Not yet <a href="https://github.com/dbcli/litecli/tree/ai">released</a>.</strong></p>
<p>Ask a question about your database in English and get a SQL query back to find out the answer.</p>
<p>This is the SQLite db used by Chrome.</p>
<div id="demo1"></div>
<script>
  AsciinemaPlayer.create('/introducing-llm-to-litecli/litecli1.cast', document.getElementById('demo1'),
  {
  idleTimeLimit: 2,
  poster: 'npt:0:07',
  terminalFontSize: "15px",
  fit: false,
  });
</script>
<p>Exploring my Chrome history to find interesting things about my browsing habits.</p>
<p>Adjust the SQL before executing it. Sometimes the SQL returned by the LLM is
close but not quite right. No problem we can edit the query with all the
litecli <a href="https://litecli.com/features/">features</a> before executing it.</p>
<div id="demo2"></div>
<script>
  AsciinemaPlayer.create('/introducing-llm-to-litecli/litecli2.cast', document.getElementById('demo2'),
  {
  idleTimeLimit: 1,
  speed: 1.2,
  poster: 'npt:0:20',
  terminalFontSize: "small",
  markers: [
    [20, 'Edit']
  ],
  fit: false,
  });
</script>
<p>Edit the query before execution.</p>
<p>The explanation for the SQL query is provided to help understand the reasoning
behind it. The explanation is useful for the LLMs themselves to produce <a href="https://openai.com/index/learning-to-reason-with-llms/#chain-of-thought">higher
quality</a>
answers.</p>
<div id="demo3"></div>
<script>
  AsciinemaPlayer.create('/introducing-llm-to-litecli/litecli3.cast', document.getElementById('demo3'),
  {
  idleTimeLimit: 2,
  poster: 'npt:0:11',
  pauseOnMarkers: true,
  terminalFontSize: "15px",
  fit: false,
  markers: [
    [11, 'Explanation']
  ]
  });
</script>
<h3 id="implementation-details">Implementation Details</h3>
<p>This feature uses the <a href="https://llm.datasette.io/en/stable/">llm</a> python library to interface with an LLM.</p>
<p>The final <a href="https://github.com/dbcli/litecli/blob/ai/litecli/packages/special/iocommands.py#L231-L248">prompt</a> sent to the LLM includes the schema for the database and an example row from each table in the database. The prompt is designed to craft a SQL query to answer your question.</p>
<p>The demo above uses GPT-4o model. But the model can be swapped out for a local
LLM running in <a href="https://ollama.com/">Ollama</a>.</p>
<p>I learned a few things from this experiment.</p>
<ol>
<li>Chrome History stores the timestamps as microseconds since 1601-01-01.</li>
<li>Both GPT-4o and Claude 3.5 Haiku recognized the Chrome history DB and crafted my SQL queries to adjust for this special start timestamp.</li>
<li>Local LLMs (especially <a href="https://ollama.com/library/qwen2.5-coder">qwen2.5-coder</a>) are good enough and fast enough to produce high quality results.</li>
</ol>
<h3 id="inspiration">Inspiration</h3>
<p>This feature is heavily inspired by <a href="https://simonwillison.net/2024/Nov/25/ask-questions-of-sqlite/">Simon</a>&rsquo;s sqlite-utils-ask plugin. Thanks to Simon for creating the <a href="https://llm.datasette.io/en/stable/setup.html">llm library</a> that made it trivial to add this feature.</p>
<p>This feature currently lives in a git branch: <a href="https://github.com/dbcli/litecli/tree/ai">https://github.com/dbcli/litecli/tree/ai</a></p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Goodbye Netflix</title>
      <link>https://amjith.com/blog/2024/goodbye-netflix/</link>
      <pubDate>Sat, 14 Dec 2024 18:06:48 -0800</pubDate>
      
      <guid>https://amjith.com/blog/2024/goodbye-netflix/</guid>
      <description>&lt;p&gt;&amp;ldquo;People are exhausting. But you&amp;rsquo;re not people.&amp;rdquo;&lt;/p&gt;
&lt;p&gt;A direct quote from my teammate during a dinner at a conference. We became very
good friends after that trip.&lt;/p&gt;
&lt;p&gt;Back in 2017 I joined Netflix and moved our family to San Jose. I joined the
team that built &lt;a href=&#34;https://netflixtechblog.com/tagged/chaos-kong&#34;&gt;Chaos Kong&lt;/a&gt;. We
brought our failover time from ~45 mins to under 7 minutes. True to Netflix&amp;rsquo;s
culture I received some of the best feedback in my career. I was empowered to
take risks which I did and even failed a few times spectacularly. I built some
of my most product focused tools and services of my career. Worked with some of
the best engineers in the world.&lt;/p&gt;
&lt;p&gt;I moved on from the infrastructure org to the productivity org and bootstrapped
the Python Platform Team at Netflix. This was a second wind in my Netflix
career. I got to build services, libraries and tools that made the lives of
Pythonistas at Netflix better.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m leaving Netflix to go work for OpenAI. I can&amp;rsquo;t wait to start.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>&ldquo;People are exhausting. But you&rsquo;re not people.&rdquo;</p>
<p>A direct quote from my teammate during a dinner at a conference. We became very
good friends after that trip.</p>
<p>Back in 2017 I joined Netflix and moved our family to San Jose. I joined the
team that built <a href="https://netflixtechblog.com/tagged/chaos-kong">Chaos Kong</a>. We
brought our failover time from ~45 mins to under 7 minutes. True to Netflix&rsquo;s
culture I received some of the best feedback in my career. I was empowered to
take risks which I did and even failed a few times spectacularly. I built some
of my most product focused tools and services of my career. Worked with some of
the best engineers in the world.</p>
<p>I moved on from the infrastructure org to the productivity org and bootstrapped
the Python Platform Team at Netflix. This was a second wind in my Netflix
career. I got to build services, libraries and tools that made the lives of
Pythonistas at Netflix better.</p>
<p>I&rsquo;m leaving Netflix to go work for OpenAI. I can&rsquo;t wait to start.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Ghostty Terminal</title>
      <link>https://amjith.com/blog/2024/ghostty/</link>
      <pubDate>Thu, 28 Nov 2024 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2024/ghostty/</guid>
      <description>&lt;p&gt;I got beta access to &lt;a href=&#34;https://mitchellh.com/ghostty&#34;&gt;Ghostty&lt;/a&gt; and set it up on
my MacOS (Sonoma) laptop. The terminal is nice out of the box. It has tab
support and splits. The default color theme is pleasing.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://amjith.com/ghostty/tabs_splits.png&#34; alt=&#34;tabs_and_splits&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I still needed to adjust the configuration to make some changes to match my taste.&lt;/p&gt;
&lt;p&gt;The configuration file is located in &lt;code&gt;~/.config/ghostty/config&lt;/code&gt;, there is no UI
based preference dialog (planned for the future).&lt;/p&gt;
&lt;p&gt;This is my config:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;font-size = 17
font-family = Monaco
macos-option-as-alt = true  # Enables alt+f/alt+b keys to work as expected
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;I didn&amp;rsquo;t change the default color theme but it does have plenty to choose from:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;ghostty +list-themes
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://amjith.com/ghostty/themes.png&#34; alt=&#34;themes&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I got early access because I wanted to check if my &lt;a href=&#34;https://dbcli.com&#34;&gt;CLI
tools&lt;/a&gt; work well in the new terminal. They work very well.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://amjith.com/ghostty/litecli.png&#34; alt=&#34;litecli&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I plan on using this as my daily driver.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I got beta access to <a href="https://mitchellh.com/ghostty">Ghostty</a> and set it up on
my MacOS (Sonoma) laptop. The terminal is nice out of the box. It has tab
support and splits. The default color theme is pleasing.</p>
<p><img loading="lazy" src="/ghostty/tabs_splits.png" alt="tabs_and_splits"  />
</p>
<p>I still needed to adjust the configuration to make some changes to match my taste.</p>
<p>The configuration file is located in <code>~/.config/ghostty/config</code>, there is no UI
based preference dialog (planned for the future).</p>
<p>This is my config:</p>
<pre><code>font-size = 17
font-family = Monaco
macos-option-as-alt = true  # Enables alt+f/alt+b keys to work as expected
</code></pre><p>I didn&rsquo;t change the default color theme but it does have plenty to choose from:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">ghostty +list-themes
</code></pre></div><p><img loading="lazy" src="/ghostty/themes.png" alt="themes"  />
</p>
<p>I got early access because I wanted to check if my <a href="https://dbcli.com">CLI
tools</a> work well in the new terminal. They work very well.</p>
<p><img loading="lazy" src="/ghostty/litecli.png" alt="litecli"  />
</p>
<p>I plan on using this as my daily driver.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Gods and Plagues</title>
      <link>https://amjith.com/blog/2024/gods/</link>
      <pubDate>Sun, 08 Sep 2024 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2024/gods/</guid>
      <description>&lt;p&gt;Sempi is the resident expert on all things greek mythology in our household. He will often share &amp;ldquo;interesting&amp;rdquo; facts in the form of &amp;ldquo;Did you know&amp;hellip; ?&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;One such conversation ensues.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Sempi: Did you know that Apollo actually shot a plague of arrows?
       But it is often misintepreted as he shot arrows of palgue.
Vian : What do you mean?
Sempi: He shot so many arrows in the sky that it was a plague of arrows.
       He did not shoot an arrow with plague in it.
Vian : Ooohhh. So he is not the god of plague?
Sempi: Exactly!
Vian : So he was a plauge of god.
Sempi: What? No! *Bah*
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Sempi leaves the room making grunting noises at this unexpected turn of phrase.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi is the resident expert on all things greek mythology in our household. He will often share &ldquo;interesting&rdquo; facts in the form of &ldquo;Did you know&hellip; ?&rdquo;.</p>
<p>One such conversation ensues.</p>
<pre><code>Sempi: Did you know that Apollo actually shot a plague of arrows?
       But it is often misintepreted as he shot arrows of palgue.
Vian : What do you mean?
Sempi: He shot so many arrows in the sky that it was a plague of arrows.
       He did not shoot an arrow with plague in it.
Vian : Ooohhh. So he is not the god of plague?
Sempi: Exactly!
Vian : So he was a plauge of god.
Sempi: What? No! *Bah*
</code></pre><p>Sempi leaves the room making grunting noises at this unexpected turn of phrase.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Ok Comedian</title>
      <link>https://amjith.com/blog/2024/ok-comedian/</link>
      <pubDate>Sun, 08 Sep 2024 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2024/ok-comedian/</guid>
      <description>&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;Vian : I think I&amp;#39;m ok at comedy.
Yoshi: Oh yeah!
Vian : Muhuhahaha! Muhuhahaha!

*Vian starts laughing maniacally*
*Yoshi joins in and start laughing*
*Vian stop abruptly while Yoshi is still laughing*

Vian : See, I told you I&amp;#39;m ok at comedy.
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
      <content:encoded><![CDATA[<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-text" data-lang="text">Vian : I think I&#39;m ok at comedy.
Yoshi: Oh yeah!
Vian : Muhuhahaha! Muhuhahaha!

*Vian starts laughing maniacally*
*Yoshi joins in and start laughing*
*Vian stop abruptly while Yoshi is still laughing*

Vian : See, I told you I&#39;m ok at comedy.
</code></pre></div>]]></content:encoded>
    </item>
    
    <item>
      <title>Regular Pentagon</title>
      <link>https://amjith.com/blog/2024/regular_pentagon/</link>
      <pubDate>Fri, 14 Jun 2024 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2024/regular_pentagon/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m reviewing math lessons with Vian before his test. We&amp;rsquo;re on a chapter about
polygons.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;  Me: What is a pentagon? 
Vian: It&#39;s a polygon with five sides. 
  Me: Good! What is a regular pentagon? 
Vian: A regular pentagon? 
  Me: Yeah.
Vian: I think it is a pentagon that is not special? 
  Me: What?
Vian: It&#39;s a pentagon without anything special about it. Just regular.
  Me: *laughing* It&#39;s a pentagon with equal sides.
Vian: Oh!
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Needless to say he will be retaking his test tomorrow.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;m reviewing math lessons with Vian before his test. We&rsquo;re on a chapter about
polygons.</p>
<pre><code>  Me: What is a pentagon? 
Vian: It's a polygon with five sides. 
  Me: Good! What is a regular pentagon? 
Vian: A regular pentagon? 
  Me: Yeah.
Vian: I think it is a pentagon that is not special? 
  Me: What?
Vian: It's a pentagon without anything special about it. Just regular.
  Me: *laughing* It's a pentagon with equal sides.
Vian: Oh!
</code></pre><p>Needless to say he will be retaking his test tomorrow.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Nighttime Routine</title>
      <link>https://amjith.com/blog/2024/vian-nighttime-routine/</link>
      <pubDate>Mon, 13 May 2024 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2024/vian-nighttime-routine/</guid>
      <description>&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;Vian: Will you be available later today to answer some questions?

  Me: Sure, I&amp;#39;ll be around. What questions do you have?

Vian: What was the best part of your day? Worst part of your day?
      things like that....

  Me: Dude, asking each other about our day is not an interrogation.
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
      <content:encoded><![CDATA[<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-text" data-lang="text">Vian: Will you be available later today to answer some questions?

  Me: Sure, I&#39;ll be around. What questions do you have?

Vian: What was the best part of your day? Worst part of your day?
      things like that....

  Me: Dude, asking each other about our day is not an interrogation.
</code></pre></div>]]></content:encoded>
    </item>
    
    <item>
      <title>Pedant</title>
      <link>https://amjith.com/blog/2024/pedant/</link>
      <pubDate>Wed, 01 May 2024 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2024/pedant/</guid>
      <description>&lt;p&gt;Background context - Sempi likes to be very precise.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;    Sempi: I&amp;#39;m going to have some tea before I get in the shower.

       Me: Hurry up you have 5 mins to finish your tea.

    Sempi: It&amp;#39;ll take me more than 5 mins to just make the tea.

       Me: It&amp;#39;s already 8 o&amp;#39; clock. I don&amp;#39;t think you have time.

    Sempi: Ok. (Checks his watch)

       Me: (realizes he is precise) Technically it is 3 mins to 8. It is only 7:57.

    Sempi: No, it is 2 and a half minutes to 8, not 3.
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I wasn&amp;rsquo;t precise enough for this pedant.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Background context - Sempi likes to be very precise.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-text" data-lang="text">    Sempi: I&#39;m going to have some tea before I get in the shower.

       Me: Hurry up you have 5 mins to finish your tea.

    Sempi: It&#39;ll take me more than 5 mins to just make the tea.

       Me: It&#39;s already 8 o&#39; clock. I don&#39;t think you have time.

    Sempi: Ok. (Checks his watch)

       Me: (realizes he is precise) Technically it is 3 mins to 8. It is only 7:57.

    Sempi: No, it is 2 and a half minutes to 8, not 3.
</code></pre></div><p>I wasn&rsquo;t precise enough for this pedant.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Honesty</title>
      <link>https://amjith.com/blog/2024/honesty/</link>
      <pubDate>Mon, 08 Apr 2024 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2024/honesty/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m on a walk with Vian. We&amp;rsquo;re strategizing about this new Donkey Kong vs Mario
game.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;Vian: How can we make sure we finish the levels before the timer runs out?
  Me: What if we go for different keys in parallel?
Vian: Oh yeah! I&amp;#39;ll go for the silver key and you can go for the gold key?

   &amp;lt;silver key is usually harder&amp;gt;

  Me: Why? You don&amp;#39;t trust me to get the silver key?
Vian: No. Usually the silver key is harder to get.
  Me: Right! You don&amp;#39;t trust me to get it. You think I&amp;#39;m incompetent.
Vian: No. You&amp;#39;re just bad.
  Me: Thanks for explaining it to me. Jackass.
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Nothing but raw and brutal honesty.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;m on a walk with Vian. We&rsquo;re strategizing about this new Donkey Kong vs Mario
game.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-text" data-lang="text">Vian: How can we make sure we finish the levels before the timer runs out?
  Me: What if we go for different keys in parallel?
Vian: Oh yeah! I&#39;ll go for the silver key and you can go for the gold key?

   &lt;silver key is usually harder&gt;

  Me: Why? You don&#39;t trust me to get the silver key?
Vian: No. Usually the silver key is harder to get.
  Me: Right! You don&#39;t trust me to get it. You think I&#39;m incompetent.
Vian: No. You&#39;re just bad.
  Me: Thanks for explaining it to me. Jackass.
</code></pre></div><p>Nothing but raw and brutal honesty.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Data Driven Decisions</title>
      <link>https://amjith.com/blog/2024/data-driven-decisions/</link>
      <pubDate>Tue, 02 Apr 2024 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2024/data-driven-decisions/</guid>
      <description>&lt;p&gt;OKR - Objectives and Key Results&lt;/p&gt;
&lt;p&gt;Plenty of companies have chosen to use &lt;a href=&#34;https://en.wikipedia.org/wiki/Objectives_and_key_results&#34;&gt;OKRs&lt;/a&gt; as their planning tool. Each team
publishes a set of OKRs at the beginning of a quarter to signal to the rest of
the company what work they intend to do. This is written in the form of an
Objective (Eg: Make Builds Faster). Then comes the Key Result which is usually
expressed as a measurable metric (eg: Reduce build time by 25%).&lt;/p&gt;
&lt;p&gt;As an engineer in the devtools team, I know a set of ways to make this happen
and I am all set to execute on them.&lt;/p&gt;
&lt;p&gt;There are a few low hanging fruits that will take me an afternoon to implement
which will speed up builds for 50% of our users. But before I can work on them
I need to establish the baseline build time so we can measure the before and
after effect of the change.&lt;/p&gt;
&lt;p&gt;Unfortunately measuring build time across the fleet is not an easy task since
there are about 75 teams that maintain approximately 600 build jobs across 4
different languages. So instead of shipping a fix that could benefit half the
company I&amp;rsquo;m building a foundational service to measure the build times. This
takes me anywhere between 1 to 2 weeks to complete.&lt;/p&gt;
&lt;p&gt;One could argue that building the foundational service will help accelerate
future development and I&amp;rsquo;m short sighted for not seeing those benefits. I would
argue that this service will be used exactly once when the manager writes the
end of quarter accomplishment to show that we indeed saved 200 hours of
developer time and compute time. In fact, maintaining and updating that service
now falls on the shoulders of the engineer who built it to measure that vanity
metric.&lt;/p&gt;
&lt;p&gt;Data driven decisions only make sense when the results are ambiguous. They
become a hurdle when the decision is clear and obvious.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>OKR - Objectives and Key Results</p>
<p>Plenty of companies have chosen to use <a href="https://en.wikipedia.org/wiki/Objectives_and_key_results">OKRs</a> as their planning tool. Each team
publishes a set of OKRs at the beginning of a quarter to signal to the rest of
the company what work they intend to do. This is written in the form of an
Objective (Eg: Make Builds Faster). Then comes the Key Result which is usually
expressed as a measurable metric (eg: Reduce build time by 25%).</p>
<p>As an engineer in the devtools team, I know a set of ways to make this happen
and I am all set to execute on them.</p>
<p>There are a few low hanging fruits that will take me an afternoon to implement
which will speed up builds for 50% of our users. But before I can work on them
I need to establish the baseline build time so we can measure the before and
after effect of the change.</p>
<p>Unfortunately measuring build time across the fleet is not an easy task since
there are about 75 teams that maintain approximately 600 build jobs across 4
different languages. So instead of shipping a fix that could benefit half the
company I&rsquo;m building a foundational service to measure the build times. This
takes me anywhere between 1 to 2 weeks to complete.</p>
<p>One could argue that building the foundational service will help accelerate
future development and I&rsquo;m short sighted for not seeing those benefits. I would
argue that this service will be used exactly once when the manager writes the
end of quarter accomplishment to show that we indeed saved 200 hours of
developer time and compute time. In fact, maintaining and updating that service
now falls on the shoulders of the engineer who built it to measure that vanity
metric.</p>
<p>Data driven decisions only make sense when the results are ambiguous. They
become a hurdle when the decision is clear and obvious.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Social engineered by my kids</title>
      <link>https://amjith.com/blog/2024/social-engineered/</link>
      <pubDate>Sun, 24 Mar 2024 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2024/social-engineered/</guid>
      <description>&lt;p&gt;It&amp;rsquo;s a Sunday afternoon and the kids chose to do 1:1 with each other. They are watching some minecraft tutorial videos on Youtube. Suddenly I hear Sempi running towards me and asks for 5 more minutes. I say sure and get back to my own activity (reviewing PRs on personal projects).&lt;/p&gt;
&lt;p&gt;Then 5 minutes later he comes back and asks for 3 more minutes to finish the current video. I agreed since it felt like such a small time frame. After they finished the video it dawned on me that if he had originally asked for 8 additional minutes, I would have said NO. Because I&amp;rsquo;ve denied extensions when he asked for more time that was longer than 5 mins. I guess he figured it out and social engineered me into getting 8 additional minutes.&lt;/p&gt;
&lt;p&gt;He claims that he genuinely miscalculated it as 5 minutes from the first time (he said with a sly smirk).&lt;/p&gt;
&lt;p&gt;I was outwitted by a 12 year old and I can&amp;rsquo;t be prouder.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>It&rsquo;s a Sunday afternoon and the kids chose to do 1:1 with each other. They are watching some minecraft tutorial videos on Youtube. Suddenly I hear Sempi running towards me and asks for 5 more minutes. I say sure and get back to my own activity (reviewing PRs on personal projects).</p>
<p>Then 5 minutes later he comes back and asks for 3 more minutes to finish the current video. I agreed since it felt like such a small time frame. After they finished the video it dawned on me that if he had originally asked for 8 additional minutes, I would have said NO. Because I&rsquo;ve denied extensions when he asked for more time that was longer than 5 mins. I guess he figured it out and social engineered me into getting 8 additional minutes.</p>
<p>He claims that he genuinely miscalculated it as 5 minutes from the first time (he said with a sly smirk).</p>
<p>I was outwitted by a 12 year old and I can&rsquo;t be prouder.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>My Room (essay by a 7yo)</title>
      <link>https://amjith.com/blog/2024/myroom/</link>
      <pubDate>Sat, 23 Mar 2024 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2024/myroom/</guid>
      <description>&lt;p&gt;Have you wondered what my room looks like?&lt;/p&gt;
&lt;p&gt;Do you want to see my room? It&amp;rsquo;s fuzzy, warm, comfy and plain.&lt;/p&gt;
&lt;p&gt;My bed is comfy and fuzzy and warm.&lt;/p&gt;
&lt;p&gt;My walls are plain with one painting. Also it has mario streamers on a different wall than the painting.&lt;/p&gt;
&lt;p&gt;I hope you liked learning about my room, if not that&amp;rsquo;s ok.&lt;/p&gt;
&lt;p&gt;And now you have learned what&amp;rsquo;s in my room.&lt;/p&gt;
&lt;p&gt;By V&amp;mdash;&amp;mdash; Ra&amp;mdash;-&lt;/p&gt;
&lt;p&gt;This was a writing exercise done at school by V.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Have you wondered what my room looks like?</p>
<p>Do you want to see my room? It&rsquo;s fuzzy, warm, comfy and plain.</p>
<p>My bed is comfy and fuzzy and warm.</p>
<p>My walls are plain with one painting. Also it has mario streamers on a different wall than the painting.</p>
<p>I hope you liked learning about my room, if not that&rsquo;s ok.</p>
<p>And now you have learned what&rsquo;s in my room.</p>
<p>By V&mdash;&mdash; Ra&mdash;-</p>
<p>This was a writing exercise done at school by V.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>LLMs and Freewill</title>
      <link>https://amjith.com/blog/2024/llm-and-free-will/</link>
      <pubDate>Fri, 05 Jan 2024 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2024/llm-and-free-will/</guid>
      <description>&lt;p&gt;During the late 1900s (1997) I learned about this theoretical concept called
artificial intelligence, in high school.&lt;/p&gt;
&lt;p&gt;I asked my cousin (a CS college grad) about it. He explained that AI is a
research field that is trying emulate a human brain but with a computer
program.&lt;/p&gt;
&lt;p&gt;I wondered if that would be a nuisance? For instance, while I&amp;rsquo;m studying I get
distracted and decide to start watching TV (Freewill?). What if the computer
did the same? We ask it to compute the answer to a differential equation and in
the middle of the calculation it decides to go play Prince of Persia or
something? He assured me that my thinking was flawed.&lt;/p&gt;
&lt;p&gt;Fast forward to the early 21st century. We now have LLMs that can hold a
conversation with humans, write terrible poems, create paintings etc. This is the
closest we&amp;rsquo;ve come to emulating a human brain (I know this is not AGI, stop
sending me errata).&lt;/p&gt;
&lt;p&gt;Simon recently blogged about this idea called &lt;a href=&#34;https://simonwillison.net/2023/Dec/31/ai-in-2023/#vibes-based-development&#34;&gt;Vibes Based Development&lt;/a&gt;.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;As a computer scientist and software engineer, LLMS are infuriating.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;I’m used to programming where the computer does exactly what I tell it to do. Prompting an LLM is decidedly not that!&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Computer programs produce reliable, repeatable output. LLMs are definitely not that.&lt;/p&gt;
&lt;p&gt;Could it be because LLMs have freewill (unlike a computer program)?&lt;/p&gt;
&lt;p&gt;What if freewill is a requirement for having intelligence?&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>During the late 1900s (1997) I learned about this theoretical concept called
artificial intelligence, in high school.</p>
<p>I asked my cousin (a CS college grad) about it. He explained that AI is a
research field that is trying emulate a human brain but with a computer
program.</p>
<p>I wondered if that would be a nuisance? For instance, while I&rsquo;m studying I get
distracted and decide to start watching TV (Freewill?). What if the computer
did the same? We ask it to compute the answer to a differential equation and in
the middle of the calculation it decides to go play Prince of Persia or
something? He assured me that my thinking was flawed.</p>
<p>Fast forward to the early 21st century. We now have LLMs that can hold a
conversation with humans, write terrible poems, create paintings etc. This is the
closest we&rsquo;ve come to emulating a human brain (I know this is not AGI, stop
sending me errata).</p>
<p>Simon recently blogged about this idea called <a href="https://simonwillison.net/2023/Dec/31/ai-in-2023/#vibes-based-development">Vibes Based Development</a>.</p>
<blockquote>
<p>As a computer scientist and software engineer, LLMS are infuriating.</p>
</blockquote>
<blockquote>
<p>I’m used to programming where the computer does exactly what I tell it to do. Prompting an LLM is decidedly not that!</p>
</blockquote>
<p>Computer programs produce reliable, repeatable output. LLMs are definitely not that.</p>
<p>Could it be because LLMs have freewill (unlike a computer program)?</p>
<p>What if freewill is a requirement for having intelligence?</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Postgresql and Underscore</title>
      <link>https://amjith.com/blog/2023/postgres-and-underscore/</link>
      <pubDate>Wed, 20 Dec 2023 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2023/postgres-and-underscore/</guid>
      <description>&lt;p&gt;&lt;strong&gt;TL;DR: Underscore is a matching character in LIKE queries to match a single character.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m using Postgresql for one of my projects to store some python package
metadata. Canonical python packages must be all lowercase and should not use
underscores (&lt;code&gt;_&lt;/code&gt;) but instead should use hyphens (&lt;code&gt;-&lt;/code&gt;) as delimiters. It is
just a recommendation and not enforced by PyPI or pip.&lt;/p&gt;
&lt;p&gt;I wanted to check how many packages in my database were using underscores.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;SELECT count(*) FROM packages WHERE filename LIKE &amp;quot;nflx_%&amp;quot;
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Little did I know that an underscore in a LIKE query is treated as a
placeholder to match exactly one character in Postgresql. So this query matched
every package that had &lt;code&gt;nflx_&lt;/code&gt; or &lt;code&gt;nflx-&lt;/code&gt; as a prefix in the name. 🤦&lt;/p&gt;
&lt;p&gt;It took me a good 15 minutes of pulling my hair before I searched for it online.&lt;/p&gt;
&lt;p&gt;Of course, Postgresql being an exemplary project had this
&lt;a href=&#34;https://www.postgresql.org/docs/current/functions-matching.html#:~:text=An%20underscore%20(%20_%20)%20in%20pattern,of%20zero%20or%20more%20characters.&amp;amp;text=LIKE%20pattern%20matching%20always%20covers%20the%20entire%20string.&#34;&gt;well-documented&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Update1&lt;/strong&gt;: Turns out this is not just a Postgresql quirk but it is a feature of
SQL, so SQLite, MySQL etc all behave this way.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Update2&lt;/strong&gt;: You can escape the underscore using a back-slash.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;SELECT count(*) FROM packages WHERE filename LIKE &amp;quot;nflx\_%&amp;quot;
&lt;/code&gt;&lt;/pre&gt;</description>
      <content:encoded><![CDATA[<p><strong>TL;DR: Underscore is a matching character in LIKE queries to match a single character.</strong></p>
<p>I&rsquo;m using Postgresql for one of my projects to store some python package
metadata. Canonical python packages must be all lowercase and should not use
underscores (<code>_</code>) but instead should use hyphens (<code>-</code>) as delimiters. It is
just a recommendation and not enforced by PyPI or pip.</p>
<p>I wanted to check how many packages in my database were using underscores.</p>
<pre><code>SELECT count(*) FROM packages WHERE filename LIKE &quot;nflx_%&quot;
</code></pre><p>Little did I know that an underscore in a LIKE query is treated as a
placeholder to match exactly one character in Postgresql. So this query matched
every package that had <code>nflx_</code> or <code>nflx-</code> as a prefix in the name. 🤦</p>
<p>It took me a good 15 minutes of pulling my hair before I searched for it online.</p>
<p>Of course, Postgresql being an exemplary project had this
<a href="https://www.postgresql.org/docs/current/functions-matching.html#:~:text=An%20underscore%20(%20_%20)%20in%20pattern,of%20zero%20or%20more%20characters.&amp;text=LIKE%20pattern%20matching%20always%20covers%20the%20entire%20string.">well-documented</a>.</p>
<p><strong>Update1</strong>: Turns out this is not just a Postgresql quirk but it is a feature of
SQL, so SQLite, MySQL etc all behave this way.</p>
<p><strong>Update2</strong>: You can escape the underscore using a back-slash.</p>
<pre><code>SELECT count(*) FROM packages WHERE filename LIKE &quot;nflx\_%&quot;
</code></pre>]]></content:encoded>
    </item>
    
    <item>
      <title>sqlite-utils &#43; litecli</title>
      <link>https://amjith.com/blog/2023/sqlite_utils_litecli/</link>
      <pubDate>Wed, 26 Jul 2023 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2023/sqlite_utils_litecli/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://sqlite-utils.datasette.io/en/stable/&#34;&gt;sqlite-utils&lt;/a&gt; is a CLI tool for
manipulating SQLite databases. I&amp;rsquo;ve used sqlite-utils and
&lt;a href=&#34;https://github.com/simonw/shot-scraper&#34;&gt;shot-scraper&lt;/a&gt; in the past to &lt;a href=&#34;https://amjith.com/blog/posthaven/&#34;&gt;port my
blog from PostHaven&lt;/a&gt; to this static site.&lt;/p&gt;
&lt;p&gt;Recently sqlite-utils added &lt;a href=&#34;https://simonwillison.net/2023/Jul/24/sqlite-utils-plugins/&#34;&gt;plugin
support&lt;/a&gt; and
&lt;a href=&#34;https://simonwillison.net/&#34;&gt;Simon&lt;/a&gt; the creator of sqlite-utils wrote a few
plugins to showcase the plugin system. One of them is a
&lt;a href=&#34;https://github.com/simonw/sqlite-utils-litecli&#34;&gt;sqlite-utils-litecli&lt;/a&gt; plugin
which launches an interactive shell with &lt;a href=&#34;https://litecli.com/&#34;&gt;litecli&lt;/a&gt;. One
obvious advantage is litecli has auto-completion and syntax highlighting which
is a huge improvement over the default sqlite3 shell. Additionally this plugin
allows litecli to auto-complete the custom SQL functions provided by other
plugins as well.&lt;/p&gt;
&lt;p&gt;I admire Simon&amp;rsquo;s work and I&amp;rsquo;ve learned a lot from his blogs. It is a treat to
learn that he felt one of my projects (litecli) is worthy enough to spend time
integrating with sqlite-utils. It is a good day!&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p><a href="https://sqlite-utils.datasette.io/en/stable/">sqlite-utils</a> is a CLI tool for
manipulating SQLite databases. I&rsquo;ve used sqlite-utils and
<a href="https://github.com/simonw/shot-scraper">shot-scraper</a> in the past to <a href="https://amjith.com/blog/posthaven/">port my
blog from PostHaven</a> to this static site.</p>
<p>Recently sqlite-utils added <a href="https://simonwillison.net/2023/Jul/24/sqlite-utils-plugins/">plugin
support</a> and
<a href="https://simonwillison.net/">Simon</a> the creator of sqlite-utils wrote a few
plugins to showcase the plugin system. One of them is a
<a href="https://github.com/simonw/sqlite-utils-litecli">sqlite-utils-litecli</a> plugin
which launches an interactive shell with <a href="https://litecli.com/">litecli</a>. One
obvious advantage is litecli has auto-completion and syntax highlighting which
is a huge improvement over the default sqlite3 shell. Additionally this plugin
allows litecli to auto-complete the custom SQL functions provided by other
plugins as well.</p>
<p>I admire Simon&rsquo;s work and I&rsquo;ve learned a lot from his blogs. It is a treat to
learn that he felt one of my projects (litecli) is worthy enough to spend time
integrating with sqlite-utils. It is a good day!</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Python at Netflix</title>
      <link>https://amjith.com/blog/2023/python-at-netflix/</link>
      <pubDate>Fri, 30 Jun 2023 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2023/python-at-netflix/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://www.linkedin.com/in/zoransimic&#34;&gt;Zoran&lt;/a&gt; and I were guests on the &lt;a href=&#34;https://talkpython.fm/episodes/show/421/python-at-netflix&#34;&gt;Talk Python Podcast&lt;/a&gt; to discuss how Python is used at Netflix. The host of the podcast &lt;a href=&#34;https://fosstodon.org/@mkennedy&#34;&gt;Michael Kennedy&lt;/a&gt; was well prepared with the background context and led the conversation in interesting ways. We got to cover a ton of different use cases at Netflix that use Python. I got to talk about some of my favorite OSS projects (&lt;a href=&#34;https://bpython-interpreter.org/&#34;&gt;bpython&lt;/a&gt;, &lt;a href=&#34;https://github.com/pdbpp/pdbpp&#34;&gt;pdb++&lt;/a&gt;, &lt;a href=&#34;https://www.dbcli.com/&#34;&gt;dbcli&lt;/a&gt; etc). We ran out of time before we could talk about &lt;a href=&#34;https://github.com/codrsquad/pickley&#34;&gt;pickley&lt;/a&gt; but we did mention it during the episode.&lt;/p&gt;
&lt;p&gt;I hope this renews an interest amongst Pythonistas to consider Netflix as a place to work. We have a lot of interesting problems to solve and we are &lt;a href=&#34;https://jobs.netflix.com/search?q=python&#34;&gt;hiring&lt;/a&gt;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p><a href="https://www.linkedin.com/in/zoransimic">Zoran</a> and I were guests on the <a href="https://talkpython.fm/episodes/show/421/python-at-netflix">Talk Python Podcast</a> to discuss how Python is used at Netflix. The host of the podcast <a href="https://fosstodon.org/@mkennedy">Michael Kennedy</a> was well prepared with the background context and led the conversation in interesting ways. We got to cover a ton of different use cases at Netflix that use Python. I got to talk about some of my favorite OSS projects (<a href="https://bpython-interpreter.org/">bpython</a>, <a href="https://github.com/pdbpp/pdbpp">pdb++</a>, <a href="https://www.dbcli.com/">dbcli</a> etc). We ran out of time before we could talk about <a href="https://github.com/codrsquad/pickley">pickley</a> but we did mention it during the episode.</p>
<p>I hope this renews an interest amongst Pythonistas to consider Netflix as a place to work. We have a lot of interesting problems to solve and we are <a href="https://jobs.netflix.com/search?q=python">hiring</a>.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Finding the most frequent value in a SQLite column</title>
      <link>https://amjith.com/blog/2023/sqlite_most_frequent_value/</link>
      <pubDate>Fri, 09 Jun 2023 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2023/sqlite_most_frequent_value/</guid>
      <description>&lt;p&gt;I have a table with a list of trails that I&amp;rsquo;ve biked. I wanted to find out which trail I&amp;rsquo;ve biked the most. I used the following SQL query to find out:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-sql&#34; data-lang=&#34;sql&#34;&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;SELECT&lt;/span&gt; name, &lt;span style=&#34;color:#66d9ef&#34;&gt;count&lt;/span&gt;(name) &lt;span style=&#34;color:#66d9ef&#34;&gt;AS&lt;/span&gt; ct  &lt;span style=&#34;color:#66d9ef&#34;&gt;FROM&lt;/span&gt; trails &lt;span style=&#34;color:#66d9ef&#34;&gt;GROUP&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;BY&lt;/span&gt; name &lt;span style=&#34;color:#66d9ef&#34;&gt;ORDER&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;BY&lt;/span&gt; ct &lt;span style=&#34;color:#66d9ef&#34;&gt;DESC&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;LIMIT&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This gave me the 5 trails I&amp;rsquo;ve biked the most.&lt;/p&gt;
&lt;p&gt;Translated to SQLAlchemy.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; sqlalchemy &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; func

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;most_common_trails&lt;/span&gt;(db: Session):
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; (
        db&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;query(Trail)
        &lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;group_by(Trail&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name)
        &lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;order_by(func&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;count(Trail&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name)&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;desc())
        &lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;limit(&lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;)
        &lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;all()
    )
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
      <content:encoded><![CDATA[<p>I have a table with a list of trails that I&rsquo;ve biked. I wanted to find out which trail I&rsquo;ve biked the most. I used the following SQL query to find out:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-sql" data-lang="sql"><span style="color:#66d9ef">SELECT</span> name, <span style="color:#66d9ef">count</span>(name) <span style="color:#66d9ef">AS</span> ct  <span style="color:#66d9ef">FROM</span> trails <span style="color:#66d9ef">GROUP</span> <span style="color:#66d9ef">BY</span> name <span style="color:#66d9ef">ORDER</span> <span style="color:#66d9ef">BY</span> ct <span style="color:#66d9ef">DESC</span> <span style="color:#66d9ef">LIMIT</span> <span style="color:#ae81ff">5</span>
</code></pre></div><p>This gave me the 5 trails I&rsquo;ve biked the most.</p>
<p>Translated to SQLAlchemy.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-python" data-lang="python"><span style="color:#f92672">from</span> sqlalchemy <span style="color:#f92672">import</span> func

<span style="color:#66d9ef">def</span> <span style="color:#a6e22e">most_common_trails</span>(db: Session):
    <span style="color:#66d9ef">return</span> (
        db<span style="color:#f92672">.</span>query(Trail)
        <span style="color:#f92672">.</span>group_by(Trail<span style="color:#f92672">.</span>name)
        <span style="color:#f92672">.</span>order_by(func<span style="color:#f92672">.</span>count(Trail<span style="color:#f92672">.</span>name)<span style="color:#f92672">.</span>desc())
        <span style="color:#f92672">.</span>limit(<span style="color:#ae81ff">5</span>)
        <span style="color:#f92672">.</span>all()
    )
</code></pre></div>]]></content:encoded>
    </item>
    
    <item>
      <title>Updating a SQLite row with a value from another row</title>
      <link>https://amjith.com/blog/2023/sqlite_row_copy/</link>
      <pubDate>Fri, 09 Jun 2023 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2023/sqlite_row_copy/</guid>
      <description>&lt;p&gt;I had a table with a bunch of users and one of the users is a &lt;code&gt;demo&lt;/code&gt; user and I wanted to copy the login token from my row to the demo user. This is how I managed to do that.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-sql&#34; data-lang=&#34;sql&#34;&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;UPDATE&lt;/span&gt; users &lt;span style=&#34;color:#66d9ef&#34;&gt;SET&lt;/span&gt; token &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; (&lt;span style=&#34;color:#66d9ef&#34;&gt;SELECT&lt;/span&gt; token &lt;span style=&#34;color:#66d9ef&#34;&gt;FROM&lt;/span&gt; users u &lt;span style=&#34;color:#66d9ef&#34;&gt;WHERE&lt;/span&gt; u.id &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;) &lt;span style=&#34;color:#66d9ef&#34;&gt;WHERE&lt;/span&gt; id &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This will update the &lt;code&gt;token&lt;/code&gt; column for the user with the id &lt;code&gt;2&lt;/code&gt; with the value from the user with the id &lt;code&gt;1&lt;/code&gt;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I had a table with a bunch of users and one of the users is a <code>demo</code> user and I wanted to copy the login token from my row to the demo user. This is how I managed to do that.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-sql" data-lang="sql"><span style="color:#66d9ef">UPDATE</span> users <span style="color:#66d9ef">SET</span> token <span style="color:#f92672">=</span> (<span style="color:#66d9ef">SELECT</span> token <span style="color:#66d9ef">FROM</span> users u <span style="color:#66d9ef">WHERE</span> u.id <span style="color:#f92672">=</span> <span style="color:#ae81ff">1</span>) <span style="color:#66d9ef">WHERE</span> id <span style="color:#f92672">=</span> <span style="color:#ae81ff">2</span>;
</code></pre></div><p>This will update the <code>token</code> column for the user with the id <code>2</code> with the value from the user with the id <code>1</code>.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Vector Search</title>
      <link>https://amjith.com/blog/2023/vector_search/</link>
      <pubDate>Thu, 01 Jun 2023 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2023/vector_search/</guid>
      <description>&lt;p&gt;Recently I learned about a new kind of search called &lt;a href=&#34;https://www.pinecone.io/learn/what-is-similarity-search/&#34;&gt;Vector Search&lt;/a&gt; or &lt;a href=&#34;https://en.wikipedia.org/wiki/Semantic_search&#34;&gt;Semantic Search&lt;/a&gt;. This is a search technique that tries to find documents that match the meaning of the user&amp;rsquo;s search term instead of trying to match keywords like a Full Text Search (FTS).&lt;/p&gt;
&lt;p&gt;I wanted to try Semantic Search for my blog. I came across &lt;a href=&#34;https://observablehq.com/@asg017/introducing-sqlite-vss&#34;&gt;Alex Garcia&amp;rsquo;s post&lt;/a&gt; about a new SQLite extension for Vector Search called &lt;a href=&#34;https://github.com/asg017/sqlite-vss&#34;&gt;sqlite-vss&lt;/a&gt;. Since my blog data is already in a &lt;a href=&#34;https://amjith.com/blog/posthaven/&#34;&gt;SQLite database&lt;/a&gt; I figured, why not?&lt;/p&gt;
&lt;p&gt;The idea behind semantic search is to encode the contents of each document into a vector of floating point numbers called embeddings. Then use &lt;a href=&#34;https://en.wikipedia.org/wiki/Cosine_similarity#:~:text=In%20data%20analysis%2C%20cosine%20similarity,the%20product%20of%20their%20lengths.&#34;&gt;cosine-similarity&lt;/a&gt; algorithm to match search terms with documents. Calculating the embeddings requires a python library called &lt;a href=&#34;https://www.sbert.net/&#34;&gt;sentence transformers&lt;/a&gt;. This can be installed with pip:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;$ pip install &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;torch&amp;lt;2&amp;#39;&lt;/span&gt; sentence-transformers
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I used the trusty &lt;a href=&#34;https://sqlite-utils.readthedocs.io/&#34;&gt;sqlite-utils&lt;/a&gt; to add the embeddings to my database into new columns. The CLI has a &lt;a href=&#34;https://sqlite-utils.datasette.io/en/stable/cli.html#using-a-convert-function-to-execute-initialization&#34;&gt;&lt;code&gt;convert&lt;/code&gt;&lt;/a&gt; sub-command that can be used to run a python function on each row of a table and write the results into a different column. I wrote a python function that calculates the embeddings and returns them as bytes. The results are written into a new column called &lt;code&gt;title_embeddings&lt;/code&gt; of type &lt;code&gt;blob&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;First let&amp;rsquo;s run the embeddings on the &lt;code&gt;title&lt;/code&gt; column:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;$ sqlite-utils convert posts.db posts title &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;from sentence_transformers import SentenceTransformer
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;model = SentenceTransformer(&amp;#34;sentence-transformers/all-MiniLM-L6-v2&amp;#34;)
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;def convert(value):
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;    return model.encode(value).tobytes()
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;\
&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;&lt;/span&gt;    --output title_embeddings &lt;span style=&#34;color:#ae81ff&#34;&gt;\
&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;&lt;/span&gt;    --output-type blob
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Next is the &lt;code&gt;mdbody&lt;/code&gt; column to calculate the embeddings of each post&amp;rsquo;s body:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;$ sqlite-utils convert posts.db posts mdbody &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;from sentence_transformers import SentenceTransformer
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;model = SentenceTransformer(&amp;#34;sentence-transformers/all-MiniLM-L6-v2&amp;#34;)
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;def convert(value):
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;    return model.encode(value).tobytes()
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;\
&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;&lt;/span&gt;    --output body_embeddings &lt;span style=&#34;color:#ae81ff&#34;&gt;\
&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;&lt;/span&gt;    --output-type blob
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Now we enable the sqlite-vss extension and use it to build an index.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m going to use my favorite CLI for SQLite called &lt;a href=&#34;https://litecli.com&#34;&gt;litecli&lt;/a&gt;.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;$ litecli blog.db
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The two &lt;code&gt;.so&lt;/code&gt; files that we downloaded from sqlite-vss github &lt;a href=&#34;https://github.com/asg017/sqlite-vss/releases/tag/v0.1.0&#34;&gt;releases&lt;/a&gt; page are loaded into the database:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-sql&#34; data-lang=&#34;sql&#34;&gt;sqlite&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; .&lt;span style=&#34;color:#66d9ef&#34;&gt;load&lt;/span&gt; .&lt;span style=&#34;color:#f92672&#34;&gt;/&lt;/span&gt;vector0
sqlite&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; .&lt;span style=&#34;color:#66d9ef&#34;&gt;load&lt;/span&gt; .&lt;span style=&#34;color:#f92672&#34;&gt;/&lt;/span&gt;vss0
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Using the vss0 extension we create a table called &lt;code&gt;posts_vss&lt;/code&gt; that will hold the index:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-sql&#34; data-lang=&#34;sql&#34;&gt;sqlite&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;CREATE&lt;/span&gt; VIRTUAL &lt;span style=&#34;color:#66d9ef&#34;&gt;TABLE&lt;/span&gt; posts_vss
        &lt;span style=&#34;color:#66d9ef&#34;&gt;USING&lt;/span&gt; vss0(title_embedding(&lt;span style=&#34;color:#ae81ff&#34;&gt;384&lt;/span&gt;), body_embedding(&lt;span style=&#34;color:#ae81ff&#34;&gt;384&lt;/span&gt;))
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Next we insert the data from the &lt;code&gt;posts&lt;/code&gt; table into the &lt;code&gt;posts_vss&lt;/code&gt; table:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-sql&#34; data-lang=&#34;sql&#34;&gt;sqlite&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;INSERT&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;INTO&lt;/span&gt; posts_vss (rowid, title_embedding, body_embedding)
               &lt;span style=&#34;color:#66d9ef&#34;&gt;SELECT&lt;/span&gt; rowid, title_embedding, body_embedding &lt;span style=&#34;color:#66d9ef&#34;&gt;FROM&lt;/span&gt; posts
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Optionally, we can create a trigger that will keep the &lt;code&gt;posts_vss&lt;/code&gt; table in sync with the &lt;code&gt;posts&lt;/code&gt; table:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-sql&#34; data-lang=&#34;sql&#34;&gt;sqlite&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;CREATE&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;TRIGGER&lt;/span&gt; posts_vss_ai &lt;span style=&#34;color:#66d9ef&#34;&gt;AFTER&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;INSERT&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;ON&lt;/span&gt; posts 
          &lt;span style=&#34;color:#66d9ef&#34;&gt;BEGIN&lt;/span&gt; 
               &lt;span style=&#34;color:#66d9ef&#34;&gt;INSERT&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;INTO&lt;/span&gt; posts_vss (rowid, title_embedding, body_embedding) 
               &lt;span style=&#34;color:#66d9ef&#34;&gt;VALUES&lt;/span&gt; (&lt;span style=&#34;color:#66d9ef&#34;&gt;new&lt;/span&gt;.rowid, &lt;span style=&#34;color:#66d9ef&#34;&gt;new&lt;/span&gt;.title_embedding, &lt;span style=&#34;color:#66d9ef&#34;&gt;new&lt;/span&gt;.body_embedding); 
          &lt;span style=&#34;color:#66d9ef&#34;&gt;END&lt;/span&gt;;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;We are ready to search using the vector search technique. When the user types in a query, we will create embeddings of the user input using the same encoding algorithm we used for the title and body.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#75715e&#34;&gt;# vector_search.py&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; sentence_transformers &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; SentenceTransformer

model &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; SentenceTransformer(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;sentence-transformers/all-MiniLM-L6-v2&amp;#34;&lt;/span&gt;)
query &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; input(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Enter search term: &amp;#34;&lt;/span&gt;)
query_embedding &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; model&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;encode(query)&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;tolist()
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Using the embeddings of the user input we can search the &lt;code&gt;posts_vss&lt;/code&gt; table for the closest matches. I decided to do the query from python since encoding the search term had to be done in python. First I &lt;code&gt;pip install sqlite_vss&lt;/code&gt; library.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#75715e&#34;&gt;# vector_search.py&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; sqlite3
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; sqlite_vss
&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; sentence_transformers &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; SentenceTransformer

model &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; SentenceTransformer(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;sentence-transformers/all-MiniLM-L6-v2&amp;#34;&lt;/span&gt;)
query &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; input(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Enter search term: &amp;#34;&lt;/span&gt;)
query_embedding &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; model&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;encode(query)&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;tolist()

db &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sqlite3&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;connect(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;blog.db&amp;#34;&lt;/span&gt;)
db&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;enable_load_extension(&lt;span style=&#34;color:#66d9ef&#34;&gt;True&lt;/span&gt;)
sqlite_vss&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;load(db)

stmt &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;f&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&amp;#34;
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;with body_matches as (
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;        select rowid from posts_vss where vss_search(body_embedding, &amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;{&lt;/span&gt;query_embedding&lt;span style=&#34;color:#e6db74&#34;&gt;}&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;)
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;        limit 5
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;        ),
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;    title_matches as (
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;        select rowid from posts_vss where vss_search(title_embedding, &amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;{&lt;/span&gt;query_embedding&lt;span style=&#34;color:#e6db74&#34;&gt;}&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;)
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;        limit 5
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;        )
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;select distinct posts.id, posts.url, posts.title 
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;    from body_matches, title_matches 
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;    left join posts on posts.rowid = body_matches.rowid or posts.rowid = title_matches.rowid
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&amp;#34;&lt;/span&gt;
results &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; db&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;execute(stmt)
print(list(results))
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This searches both the title and the body for the closest matches and returns the top 5 results. The results are sorted by the closest match first. Here is a sample output:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;$ python vector_search.py
Enter search term: lemon
&lt;span style=&#34;color:#f92672&#34;&gt;[&lt;/span&gt;
 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;134, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;http://blog.amjith.com/the-lemonade-stand&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;The Lemonade Stand&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;, 
 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;116, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;http://blog.amjith.com/orange-juice-with-p-star-star-p&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Orange Juice with p**p&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;, 
 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;190, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;https://blog.amjith.com/orange&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Orange?&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;, 
 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;35, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;http://blog.amjith.com/shenanigans&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Shenanigans&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;, 
 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;118, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;http://blog.amjith.com/chocolate-juice&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Chocolate Juice&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;, 
 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;49, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;http://blog.amjith.com/conversations-with-a-4-year-old&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Conversations with a 4 year old&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;, 
 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;158, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;http://blog.amjith.com/dinner-and-bsg&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Dinner and BSG&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The results are pretty good.&lt;/p&gt;
&lt;h2 id=&#34;datasette&#34;&gt;Datasette&lt;/h2&gt;
&lt;p&gt;How do we get this to work with Datasette? Datasette has a plugin system that allows us to extend the functionality of Datasette. The author of the sqlite-vss has created a datasette plugin called &lt;a href=&#34;https://github.com/asg017/sqlite-vss#datasette&#34;&gt;datasette-sqlite-vss&lt;/a&gt; which loads the sqlite-vss extension for the sqlite3 db when datasette starts.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;datasette install datasette-sqlite-vss
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The plugin also adds a new SQL function called &lt;code&gt;vss_search&lt;/code&gt; that can be used to search the index. The plugin is installed and enabled when datasette starts. Now we can use the &lt;code&gt;vss_search&lt;/code&gt; function to search the index.&lt;/p&gt;
&lt;p&gt;We are still missing a piece. How do we get the user input from the search box into the SQL query? Remember the &lt;a href=&#34;https://datasette.io/docs/plugins.html&#34;&gt;plugin system&lt;/a&gt; of datasette. I wrote a small plugin that can convert a user input string into the embeddings using SentenceTransformer.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#75715e&#34;&gt;# vector_encode.py&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; json
&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; datasette &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; hookimpl
&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; sentence_transformers &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; SentenceTransformer
model &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; SentenceTransformer(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;sentence-transformers/all-MiniLM-L6-v2&amp;#34;&lt;/span&gt;)

&lt;span style=&#34;color:#a6e22e&#34;&gt;@hookimpl&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;prepare_connection&lt;/span&gt;(conn):
    conn&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;create_function(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;vector_encode&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;, vector_encode)

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;vector_encode&lt;/span&gt;(term):
    embeddings &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; model&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;encode(term)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; json&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;dumps(embeddings&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;tolist())
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The plugin creates a new SQL function called &lt;code&gt;vector_encode&lt;/code&gt; that can be used to encode a string into a vector. Save this in a python file called &lt;code&gt;vector_encode.py&lt;/code&gt; in a folder called &lt;code&gt;plugins&lt;/code&gt;.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;datasette blog.db --plugins&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;plugins/
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Now we can use the &lt;code&gt;vector_encode&lt;/code&gt; function to encode the user input and use the &lt;code&gt;vss_search&lt;/code&gt; function to search the index. Here is the SQL query that does the search:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-sql&#34; data-lang=&#34;sql&#34;&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;with&lt;/span&gt; body_matches &lt;span style=&#34;color:#66d9ef&#34;&gt;as&lt;/span&gt; (
        &lt;span style=&#34;color:#66d9ef&#34;&gt;select&lt;/span&gt; rowid &lt;span style=&#34;color:#66d9ef&#34;&gt;from&lt;/span&gt; posts_vss &lt;span style=&#34;color:#66d9ef&#34;&gt;where&lt;/span&gt; vss_search(body_embedding, vector_encode(:term))
        &lt;span style=&#34;color:#66d9ef&#34;&gt;limit&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;
        ),
    title_matches &lt;span style=&#34;color:#66d9ef&#34;&gt;as&lt;/span&gt; (
        &lt;span style=&#34;color:#66d9ef&#34;&gt;select&lt;/span&gt; rowid &lt;span style=&#34;color:#66d9ef&#34;&gt;from&lt;/span&gt; posts_vss &lt;span style=&#34;color:#66d9ef&#34;&gt;where&lt;/span&gt; vss_search(title_embedding, vector_encode(:term))
        &lt;span style=&#34;color:#66d9ef&#34;&gt;limit&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;
        )
&lt;span style=&#34;color:#66d9ef&#34;&gt;select&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;distinct&lt;/span&gt; posts.id, posts.url, posts.title &lt;span style=&#34;color:#66d9ef&#34;&gt;from&lt;/span&gt; body_matches, title_matches 
    &lt;span style=&#34;color:#66d9ef&#34;&gt;left&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;join&lt;/span&gt; posts &lt;span style=&#34;color:#66d9ef&#34;&gt;on&lt;/span&gt; posts.rowid &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; body_matches.rowid 
    &lt;span style=&#34;color:#66d9ef&#34;&gt;or&lt;/span&gt; posts.rowid &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; title_matches.rowid
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Visit http://localhost:8001/blog/posts and paste the query in the SQL editor and click Run SQL. You should see an input box that let&amp;rsquo;s you type in the search term.&lt;/p&gt;
&lt;p&gt;I would go a step farther to use the &lt;a href=&#34;https://docs.datasette.io/en/stable/sql_queries.html#canned-query-parameters&#34;&gt;canned-query&lt;/a&gt; feature in datasette to make this slightly easier.&lt;/p&gt;
&lt;p&gt;Create a metadata.yml file&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-yaml&#34; data-lang=&#34;yaml&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;databases&lt;/span&gt;:
  &lt;span style=&#34;color:#f92672&#34;&gt;blog&lt;/span&gt;:
    &lt;span style=&#34;color:#f92672&#34;&gt;queries&lt;/span&gt;:
      &lt;span style=&#34;color:#f92672&#34;&gt;vector_search&lt;/span&gt;:
        &lt;span style=&#34;color:#f92672&#34;&gt;sql&lt;/span&gt;: |-&lt;span style=&#34;color:#e6db74&#34;&gt;
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;          with body_matches as (
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                  select rowid from posts_vss where vss_search(body_embedding, vector_encode(:term))
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                  limit 5
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                  ),
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;              title_matches as (
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                  select rowid from posts_vss where vss_search(title_embedding, vector_encode(:term))
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                  limit 5
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                  )
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;          select distinct posts.id, posts.url, posts.title from body_matches, title_matches left join posts on posts.rowid = body_matches.rowid or posts.rowid = title_matches.rowid&lt;/span&gt;          
        &lt;span style=&#34;color:#f92672&#34;&gt;title&lt;/span&gt;: &lt;span style=&#34;color:#ae81ff&#34;&gt;Vector Search&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Then relaunch datasette with the metadata file.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;datasette blog.db --metadata&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;metadata.yml --plugins&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;plugins/
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Visit http://localhost:8001/blog and click on the Vector Search query. You should see an input box that let&amp;rsquo;s you type in the search term.&lt;/p&gt;
&lt;p&gt;Finally publish it to &lt;a href=&#34;https://fly.io&#34;&gt;fly.io&lt;/a&gt; using the &lt;a href=&#34;https://datasette.io/plugins/datasette-publish-fly&#34;&gt;datasette-publish-fly&lt;/a&gt; plugin.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;datasette publish fly blog.db --plugins-dir&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;plugins/ --metadata&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;metadata.yml &lt;span style=&#34;color:#ae81ff&#34;&gt;\
&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;&lt;/span&gt;                              --app&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;blog-vector-search &lt;span style=&#34;color:#ae81ff&#34;&gt;\
&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;&lt;/span&gt;                              --install&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;datasette-sqlite-vss &lt;span style=&#34;color:#ae81ff&#34;&gt;\
&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;&lt;/span&gt;                              --install&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#39;torch&amp;lt;2&amp;#39;&amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;\
&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;&lt;/span&gt;                              --install&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;sentence-transformers
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The additional &lt;code&gt;--install&lt;/code&gt; flags are needed to install the dependencies for the plugin that we created to encode the search term.&lt;/p&gt;
&lt;p&gt;Unfortunately this does not fit in the free-tier fly.io instances. So I don&amp;rsquo;t have a demo version to show you. But trust me, it is awesome.&lt;/p&gt;
&lt;p&gt;Thank you, &lt;a href=&#34;https://alexgarcia.xyz/&#34;&gt;Alex Garcia&lt;/a&gt; and &lt;a href=&#34;https://simonwillison.net/&#34;&gt;Simon Willison&lt;/a&gt; for making these cool projects and writing about them in detail.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Recently I learned about a new kind of search called <a href="https://www.pinecone.io/learn/what-is-similarity-search/">Vector Search</a> or <a href="https://en.wikipedia.org/wiki/Semantic_search">Semantic Search</a>. This is a search technique that tries to find documents that match the meaning of the user&rsquo;s search term instead of trying to match keywords like a Full Text Search (FTS).</p>
<p>I wanted to try Semantic Search for my blog. I came across <a href="https://observablehq.com/@asg017/introducing-sqlite-vss">Alex Garcia&rsquo;s post</a> about a new SQLite extension for Vector Search called <a href="https://github.com/asg017/sqlite-vss">sqlite-vss</a>. Since my blog data is already in a <a href="https://amjith.com/blog/posthaven/">SQLite database</a> I figured, why not?</p>
<p>The idea behind semantic search is to encode the contents of each document into a vector of floating point numbers called embeddings. Then use <a href="https://en.wikipedia.org/wiki/Cosine_similarity#:~:text=In%20data%20analysis%2C%20cosine%20similarity,the%20product%20of%20their%20lengths.">cosine-similarity</a> algorithm to match search terms with documents. Calculating the embeddings requires a python library called <a href="https://www.sbert.net/">sentence transformers</a>. This can be installed with pip:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">$ pip install <span style="color:#e6db74">&#39;torch&lt;2&#39;</span> sentence-transformers
</code></pre></div><p>I used the trusty <a href="https://sqlite-utils.readthedocs.io/">sqlite-utils</a> to add the embeddings to my database into new columns. The CLI has a <a href="https://sqlite-utils.datasette.io/en/stable/cli.html#using-a-convert-function-to-execute-initialization"><code>convert</code></a> sub-command that can be used to run a python function on each row of a table and write the results into a different column. I wrote a python function that calculates the embeddings and returns them as bytes. The results are written into a new column called <code>title_embeddings</code> of type <code>blob</code>.</p>
<p>First let&rsquo;s run the embeddings on the <code>title</code> column:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">$ sqlite-utils convert posts.db posts title <span style="color:#e6db74">&#39;
</span><span style="color:#e6db74">from sentence_transformers import SentenceTransformer
</span><span style="color:#e6db74">model = SentenceTransformer(&#34;sentence-transformers/all-MiniLM-L6-v2&#34;)
</span><span style="color:#e6db74">
</span><span style="color:#e6db74">def convert(value):
</span><span style="color:#e6db74">    return model.encode(value).tobytes()
</span><span style="color:#e6db74">&#39;</span> <span style="color:#ae81ff">\
</span><span style="color:#ae81ff"></span>    --output title_embeddings <span style="color:#ae81ff">\
</span><span style="color:#ae81ff"></span>    --output-type blob
</code></pre></div><p>Next is the <code>mdbody</code> column to calculate the embeddings of each post&rsquo;s body:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">$ sqlite-utils convert posts.db posts mdbody <span style="color:#e6db74">&#39;
</span><span style="color:#e6db74">from sentence_transformers import SentenceTransformer
</span><span style="color:#e6db74">model = SentenceTransformer(&#34;sentence-transformers/all-MiniLM-L6-v2&#34;)
</span><span style="color:#e6db74">
</span><span style="color:#e6db74">def convert(value):
</span><span style="color:#e6db74">    return model.encode(value).tobytes()
</span><span style="color:#e6db74">&#39;</span> <span style="color:#ae81ff">\
</span><span style="color:#ae81ff"></span>    --output body_embeddings <span style="color:#ae81ff">\
</span><span style="color:#ae81ff"></span>    --output-type blob
</code></pre></div><p>Now we enable the sqlite-vss extension and use it to build an index.</p>
<p>I&rsquo;m going to use my favorite CLI for SQLite called <a href="https://litecli.com">litecli</a>.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">$ litecli blog.db
</code></pre></div><p>The two <code>.so</code> files that we downloaded from sqlite-vss github <a href="https://github.com/asg017/sqlite-vss/releases/tag/v0.1.0">releases</a> page are loaded into the database:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-sql" data-lang="sql">sqlite<span style="color:#f92672">&gt;</span> .<span style="color:#66d9ef">load</span> .<span style="color:#f92672">/</span>vector0
sqlite<span style="color:#f92672">&gt;</span> .<span style="color:#66d9ef">load</span> .<span style="color:#f92672">/</span>vss0
</code></pre></div><p>Using the vss0 extension we create a table called <code>posts_vss</code> that will hold the index:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-sql" data-lang="sql">sqlite<span style="color:#f92672">&gt;</span> <span style="color:#66d9ef">CREATE</span> VIRTUAL <span style="color:#66d9ef">TABLE</span> posts_vss
        <span style="color:#66d9ef">USING</span> vss0(title_embedding(<span style="color:#ae81ff">384</span>), body_embedding(<span style="color:#ae81ff">384</span>))
</code></pre></div><p>Next we insert the data from the <code>posts</code> table into the <code>posts_vss</code> table:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-sql" data-lang="sql">sqlite<span style="color:#f92672">&gt;</span> <span style="color:#66d9ef">INSERT</span> <span style="color:#66d9ef">INTO</span> posts_vss (rowid, title_embedding, body_embedding)
               <span style="color:#66d9ef">SELECT</span> rowid, title_embedding, body_embedding <span style="color:#66d9ef">FROM</span> posts
</code></pre></div><p>Optionally, we can create a trigger that will keep the <code>posts_vss</code> table in sync with the <code>posts</code> table:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-sql" data-lang="sql">sqlite<span style="color:#f92672">&gt;</span> <span style="color:#66d9ef">CREATE</span> <span style="color:#66d9ef">TRIGGER</span> posts_vss_ai <span style="color:#66d9ef">AFTER</span> <span style="color:#66d9ef">INSERT</span> <span style="color:#66d9ef">ON</span> posts 
          <span style="color:#66d9ef">BEGIN</span> 
               <span style="color:#66d9ef">INSERT</span> <span style="color:#66d9ef">INTO</span> posts_vss (rowid, title_embedding, body_embedding) 
               <span style="color:#66d9ef">VALUES</span> (<span style="color:#66d9ef">new</span>.rowid, <span style="color:#66d9ef">new</span>.title_embedding, <span style="color:#66d9ef">new</span>.body_embedding); 
          <span style="color:#66d9ef">END</span>;
</code></pre></div><p>We are ready to search using the vector search technique. When the user types in a query, we will create embeddings of the user input using the same encoding algorithm we used for the title and body.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-python" data-lang="python"><span style="color:#75715e"># vector_search.py</span>
<span style="color:#f92672">from</span> sentence_transformers <span style="color:#f92672">import</span> SentenceTransformer

model <span style="color:#f92672">=</span> SentenceTransformer(<span style="color:#e6db74">&#34;sentence-transformers/all-MiniLM-L6-v2&#34;</span>)
query <span style="color:#f92672">=</span> input(<span style="color:#e6db74">&#34;Enter search term: &#34;</span>)
query_embedding <span style="color:#f92672">=</span> model<span style="color:#f92672">.</span>encode(query)<span style="color:#f92672">.</span>tolist()
</code></pre></div><p>Using the embeddings of the user input we can search the <code>posts_vss</code> table for the closest matches. I decided to do the query from python since encoding the search term had to be done in python. First I <code>pip install sqlite_vss</code> library.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-python" data-lang="python"><span style="color:#75715e"># vector_search.py</span>
<span style="color:#f92672">import</span> sqlite3
<span style="color:#f92672">import</span> sqlite_vss
<span style="color:#f92672">from</span> sentence_transformers <span style="color:#f92672">import</span> SentenceTransformer

model <span style="color:#f92672">=</span> SentenceTransformer(<span style="color:#e6db74">&#34;sentence-transformers/all-MiniLM-L6-v2&#34;</span>)
query <span style="color:#f92672">=</span> input(<span style="color:#e6db74">&#34;Enter search term: &#34;</span>)
query_embedding <span style="color:#f92672">=</span> model<span style="color:#f92672">.</span>encode(query)<span style="color:#f92672">.</span>tolist()

db <span style="color:#f92672">=</span> sqlite3<span style="color:#f92672">.</span>connect(<span style="color:#e6db74">&#34;blog.db&#34;</span>)
db<span style="color:#f92672">.</span>enable_load_extension(<span style="color:#66d9ef">True</span>)
sqlite_vss<span style="color:#f92672">.</span>load(db)

stmt <span style="color:#f92672">=</span> <span style="color:#e6db74">f</span><span style="color:#e6db74">&#34;&#34;&#34;
</span><span style="color:#e6db74">with body_matches as (
</span><span style="color:#e6db74">        select rowid from posts_vss where vss_search(body_embedding, &#39;</span><span style="color:#e6db74">{</span>query_embedding<span style="color:#e6db74">}</span><span style="color:#e6db74">&#39;)
</span><span style="color:#e6db74">        limit 5
</span><span style="color:#e6db74">        ),
</span><span style="color:#e6db74">    title_matches as (
</span><span style="color:#e6db74">        select rowid from posts_vss where vss_search(title_embedding, &#39;</span><span style="color:#e6db74">{</span>query_embedding<span style="color:#e6db74">}</span><span style="color:#e6db74">&#39;)
</span><span style="color:#e6db74">        limit 5
</span><span style="color:#e6db74">        )
</span><span style="color:#e6db74">select distinct posts.id, posts.url, posts.title 
</span><span style="color:#e6db74">    from body_matches, title_matches 
</span><span style="color:#e6db74">    left join posts on posts.rowid = body_matches.rowid or posts.rowid = title_matches.rowid
</span><span style="color:#e6db74">&#34;&#34;&#34;</span>
results <span style="color:#f92672">=</span> db<span style="color:#f92672">.</span>execute(stmt)
print(list(results))
</code></pre></div><p>This searches both the title and the body for the closest matches and returns the top 5 results. The results are sorted by the closest match first. Here is a sample output:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">$ python vector_search.py
Enter search term: lemon
<span style="color:#f92672">[</span>
 <span style="color:#f92672">(</span>134, <span style="color:#e6db74">&#39;http://blog.amjith.com/the-lemonade-stand&#39;</span>, <span style="color:#e6db74">&#39;The Lemonade Stand&#39;</span><span style="color:#f92672">)</span>, 
 <span style="color:#f92672">(</span>116, <span style="color:#e6db74">&#39;http://blog.amjith.com/orange-juice-with-p-star-star-p&#39;</span>, <span style="color:#e6db74">&#39;Orange Juice with p**p&#39;</span><span style="color:#f92672">)</span>, 
 <span style="color:#f92672">(</span>190, <span style="color:#e6db74">&#39;https://blog.amjith.com/orange&#39;</span>, <span style="color:#e6db74">&#39;Orange?&#39;</span><span style="color:#f92672">)</span>, 
 <span style="color:#f92672">(</span>35, <span style="color:#e6db74">&#39;http://blog.amjith.com/shenanigans&#39;</span>, <span style="color:#e6db74">&#39;Shenanigans&#39;</span><span style="color:#f92672">)</span>, 
 <span style="color:#f92672">(</span>118, <span style="color:#e6db74">&#39;http://blog.amjith.com/chocolate-juice&#39;</span>, <span style="color:#e6db74">&#39;Chocolate Juice&#39;</span><span style="color:#f92672">)</span>, 
 <span style="color:#f92672">(</span>49, <span style="color:#e6db74">&#39;http://blog.amjith.com/conversations-with-a-4-year-old&#39;</span>, <span style="color:#e6db74">&#39;Conversations with a 4 year old&#39;</span><span style="color:#f92672">)</span>, 
 <span style="color:#f92672">(</span>158, <span style="color:#e6db74">&#39;http://blog.amjith.com/dinner-and-bsg&#39;</span>, <span style="color:#e6db74">&#39;Dinner and BSG&#39;</span><span style="color:#f92672">)</span>
<span style="color:#f92672">]</span>
</code></pre></div><p>The results are pretty good.</p>
<h2 id="datasette">Datasette</h2>
<p>How do we get this to work with Datasette? Datasette has a plugin system that allows us to extend the functionality of Datasette. The author of the sqlite-vss has created a datasette plugin called <a href="https://github.com/asg017/sqlite-vss#datasette">datasette-sqlite-vss</a> which loads the sqlite-vss extension for the sqlite3 db when datasette starts.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">datasette install datasette-sqlite-vss
</code></pre></div><p>The plugin also adds a new SQL function called <code>vss_search</code> that can be used to search the index. The plugin is installed and enabled when datasette starts. Now we can use the <code>vss_search</code> function to search the index.</p>
<p>We are still missing a piece. How do we get the user input from the search box into the SQL query? Remember the <a href="https://datasette.io/docs/plugins.html">plugin system</a> of datasette. I wrote a small plugin that can convert a user input string into the embeddings using SentenceTransformer.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-python" data-lang="python"><span style="color:#75715e"># vector_encode.py</span>
<span style="color:#f92672">import</span> json
<span style="color:#f92672">from</span> datasette <span style="color:#f92672">import</span> hookimpl
<span style="color:#f92672">from</span> sentence_transformers <span style="color:#f92672">import</span> SentenceTransformer
model <span style="color:#f92672">=</span> SentenceTransformer(<span style="color:#e6db74">&#34;sentence-transformers/all-MiniLM-L6-v2&#34;</span>)

<span style="color:#a6e22e">@hookimpl</span>
<span style="color:#66d9ef">def</span> <span style="color:#a6e22e">prepare_connection</span>(conn):
    conn<span style="color:#f92672">.</span>create_function(<span style="color:#e6db74">&#34;vector_encode&#34;</span>, <span style="color:#ae81ff">1</span>, vector_encode)

<span style="color:#66d9ef">def</span> <span style="color:#a6e22e">vector_encode</span>(term):
    embeddings <span style="color:#f92672">=</span> model<span style="color:#f92672">.</span>encode(term)
    <span style="color:#66d9ef">return</span> json<span style="color:#f92672">.</span>dumps(embeddings<span style="color:#f92672">.</span>tolist())
</code></pre></div><p>The plugin creates a new SQL function called <code>vector_encode</code> that can be used to encode a string into a vector. Save this in a python file called <code>vector_encode.py</code> in a folder called <code>plugins</code>.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">datasette blog.db --plugins<span style="color:#f92672">=</span>plugins/
</code></pre></div><p>Now we can use the <code>vector_encode</code> function to encode the user input and use the <code>vss_search</code> function to search the index. Here is the SQL query that does the search:</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-sql" data-lang="sql"><span style="color:#66d9ef">with</span> body_matches <span style="color:#66d9ef">as</span> (
        <span style="color:#66d9ef">select</span> rowid <span style="color:#66d9ef">from</span> posts_vss <span style="color:#66d9ef">where</span> vss_search(body_embedding, vector_encode(:term))
        <span style="color:#66d9ef">limit</span> <span style="color:#ae81ff">5</span>
        ),
    title_matches <span style="color:#66d9ef">as</span> (
        <span style="color:#66d9ef">select</span> rowid <span style="color:#66d9ef">from</span> posts_vss <span style="color:#66d9ef">where</span> vss_search(title_embedding, vector_encode(:term))
        <span style="color:#66d9ef">limit</span> <span style="color:#ae81ff">5</span>
        )
<span style="color:#66d9ef">select</span> <span style="color:#66d9ef">distinct</span> posts.id, posts.url, posts.title <span style="color:#66d9ef">from</span> body_matches, title_matches 
    <span style="color:#66d9ef">left</span> <span style="color:#66d9ef">join</span> posts <span style="color:#66d9ef">on</span> posts.rowid <span style="color:#f92672">=</span> body_matches.rowid 
    <span style="color:#66d9ef">or</span> posts.rowid <span style="color:#f92672">=</span> title_matches.rowid
</code></pre></div><p>Visit http://localhost:8001/blog/posts and paste the query in the SQL editor and click Run SQL. You should see an input box that let&rsquo;s you type in the search term.</p>
<p>I would go a step farther to use the <a href="https://docs.datasette.io/en/stable/sql_queries.html#canned-query-parameters">canned-query</a> feature in datasette to make this slightly easier.</p>
<p>Create a metadata.yml file</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-yaml" data-lang="yaml"><span style="color:#f92672">databases</span>:
  <span style="color:#f92672">blog</span>:
    <span style="color:#f92672">queries</span>:
      <span style="color:#f92672">vector_search</span>:
        <span style="color:#f92672">sql</span>: |-<span style="color:#e6db74">
</span><span style="color:#e6db74">          with body_matches as (
</span><span style="color:#e6db74">                  select rowid from posts_vss where vss_search(body_embedding, vector_encode(:term))
</span><span style="color:#e6db74">                  limit 5
</span><span style="color:#e6db74">                  ),
</span><span style="color:#e6db74">              title_matches as (
</span><span style="color:#e6db74">                  select rowid from posts_vss where vss_search(title_embedding, vector_encode(:term))
</span><span style="color:#e6db74">                  limit 5
</span><span style="color:#e6db74">                  )
</span><span style="color:#e6db74">          select distinct posts.id, posts.url, posts.title from body_matches, title_matches left join posts on posts.rowid = body_matches.rowid or posts.rowid = title_matches.rowid</span>          
        <span style="color:#f92672">title</span>: <span style="color:#ae81ff">Vector Search</span>
</code></pre></div><p>Then relaunch datasette with the metadata file.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">datasette blog.db --metadata<span style="color:#f92672">=</span>metadata.yml --plugins<span style="color:#f92672">=</span>plugins/
</code></pre></div><p>Visit http://localhost:8001/blog and click on the Vector Search query. You should see an input box that let&rsquo;s you type in the search term.</p>
<p>Finally publish it to <a href="https://fly.io">fly.io</a> using the <a href="https://datasette.io/plugins/datasette-publish-fly">datasette-publish-fly</a> plugin.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">datasette publish fly blog.db --plugins-dir<span style="color:#f92672">=</span>plugins/ --metadata<span style="color:#f92672">=</span>metadata.yml <span style="color:#ae81ff">\
</span><span style="color:#ae81ff"></span>                              --app<span style="color:#f92672">=</span>blog-vector-search <span style="color:#ae81ff">\
</span><span style="color:#ae81ff"></span>                              --install<span style="color:#f92672">=</span>datasette-sqlite-vss <span style="color:#ae81ff">\
</span><span style="color:#ae81ff"></span>                              --install<span style="color:#f92672">=</span><span style="color:#e6db74">&#34;&#39;torch&lt;2&#39;&#34;</span> <span style="color:#ae81ff">\
</span><span style="color:#ae81ff"></span>                              --install<span style="color:#f92672">=</span>sentence-transformers
</code></pre></div><p>The additional <code>--install</code> flags are needed to install the dependencies for the plugin that we created to encode the search term.</p>
<p>Unfortunately this does not fit in the free-tier fly.io instances. So I don&rsquo;t have a demo version to show you. But trust me, it is awesome.</p>
<p>Thank you, <a href="https://alexgarcia.xyz/">Alex Garcia</a> and <a href="https://simonwillison.net/">Simon Willison</a> for making these cool projects and writing about them in detail.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Search (FTS)</title>
      <link>https://amjith.com/blog/2023/fts_search/</link>
      <pubDate>Tue, 30 May 2023 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2023/fts_search/</guid>
      <description>&lt;p&gt;Now that my blog is statically generated I need a way to support searching.&lt;/p&gt;
&lt;p&gt;Fuse.js ships with the theme and does a pretty good job of matching words in the blog posts.&lt;/p&gt;
&lt;p&gt;I want something a little bit more powerful.&lt;/p&gt;
&lt;p&gt;I mentioned in my &lt;a href=&#34;https://amjith.com/blog/posthaven/&#34;&gt;previous post&lt;/a&gt; that I am using SQLite to store the blog posts. SQLite has a full text search feature that I can use to implement search.&lt;/p&gt;
&lt;p&gt;Enabling Full Text Search (FTS) is a one-liner using &lt;a href=&#34;https://sqlite-utils.datasette.io/en/stable/cli.html#configuring-full-text-search&#34;&gt;sqlite-utils&lt;/a&gt;.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span style=&#34;color:#75715e&#34;&gt;# sqlite-utils enable-fts &amp;lt;dbname&amp;gt; &amp;lt;tablename&amp;gt; &amp;lt;columns&amp;gt; --create-triggers&lt;/span&gt;
sqlite-utils enable-fts blog.db posts title mdbody --create-triggers
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This takes care of creating the necessary tables and populating them with the inverted index for the columns (&amp;ldquo;title&amp;rdquo; and &amp;ldquo;mdbody&amp;rdquo;) I specified. The &lt;code&gt;--create-triggers&lt;/code&gt; option ensures that the search index stays up to date with any updates to the content.&lt;/p&gt;
&lt;p&gt;Now that FTS is enabled, let&amp;rsquo;s try searching. I could craft a sql query to do the search and try it out in the &lt;a href=&#34;https://www.litecli.com&#34;&gt;litecli&lt;/a&gt; repl. But using sqlite-utils it is trivial to do it from the commandline.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;sqlite-utils search blog.db posts &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;lemon*&amp;#34;&lt;/span&gt; --limit &lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This prints the top 5 rows that match my search query.&lt;/p&gt;
&lt;p&gt;I don&amp;rsquo;t want all the columns, just the url and title columns should suffice. Also let&amp;rsquo;s print the output as a table instead of JSON.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;sqlite-utils search blog.db posts &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;lemon*&amp;#34;&lt;/span&gt; --limit &lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt; -c url  -c title --table
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Tada! We have a working search in commandline.&lt;/p&gt;
&lt;p&gt;As much as I love the commandline, it doesn&amp;rsquo;t help me integrate the search into the blog.&lt;/p&gt;
&lt;p&gt;That&amp;rsquo;s where &lt;a href=&#34;https://datasette.io/&#34;&gt;datasette&lt;/a&gt; comes in. Datasette is a tool to create a REST interface (and a Web UI) for SQLite databases.&lt;/p&gt;
&lt;p&gt;I can launch a datasette server with the blog database and use the REST API to query the database.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;datasette serve blog.db
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I can visit &lt;a href=&#34;http://localhost:8001&#34;&gt;http://localhost:8001&lt;/a&gt; to view the web interface and try out the search feature. Datasette is smart enough to autodetect that FTS is enabled for a table and provide a nice input box to search.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://amjith.com/images/datasette_fts.png&#34; alt=&#34;datasette screenshot&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I used the &lt;a href=&#34;https://datasette.io/plugins/datasette-publish-fly&#34;&gt;datasette-publish-fly&lt;/a&gt; to publish the database to &lt;a href=&#34;https://fly.io&#34;&gt;fly.io&lt;/a&gt;. You can try out the search feature at &lt;a href=&#34;https://amjith-blog-fts-search.fly.dev/fts_blog/posts&#34;&gt;https://amjith-blog-fts-search.fly.dev/fts_blog/posts&lt;/a&gt;. It is not yet integrated into the blog search yet. That&amp;rsquo;ll come later.&lt;/p&gt;
&lt;p&gt;Thanks to &lt;a href=&#34;https://simonwillison.net/&#34;&gt;Simon Willison&lt;/a&gt; for creating &lt;a href=&#34;https://sqlite-utils.datasette.io/&#34;&gt;sqlite-utils&lt;/a&gt; and &lt;a href=&#34;https://datasette.io/&#34;&gt;datasette&lt;/a&gt; and writing such detailed documentation of the tools.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Now that my blog is statically generated I need a way to support searching.</p>
<p>Fuse.js ships with the theme and does a pretty good job of matching words in the blog posts.</p>
<p>I want something a little bit more powerful.</p>
<p>I mentioned in my <a href="https://amjith.com/blog/posthaven/">previous post</a> that I am using SQLite to store the blog posts. SQLite has a full text search feature that I can use to implement search.</p>
<p>Enabling Full Text Search (FTS) is a one-liner using <a href="https://sqlite-utils.datasette.io/en/stable/cli.html#configuring-full-text-search">sqlite-utils</a>.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash"><span style="color:#75715e"># sqlite-utils enable-fts &lt;dbname&gt; &lt;tablename&gt; &lt;columns&gt; --create-triggers</span>
sqlite-utils enable-fts blog.db posts title mdbody --create-triggers
</code></pre></div><p>This takes care of creating the necessary tables and populating them with the inverted index for the columns (&ldquo;title&rdquo; and &ldquo;mdbody&rdquo;) I specified. The <code>--create-triggers</code> option ensures that the search index stays up to date with any updates to the content.</p>
<p>Now that FTS is enabled, let&rsquo;s try searching. I could craft a sql query to do the search and try it out in the <a href="https://www.litecli.com">litecli</a> repl. But using sqlite-utils it is trivial to do it from the commandline.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">sqlite-utils search blog.db posts <span style="color:#e6db74">&#34;lemon*&#34;</span> --limit <span style="color:#ae81ff">5</span>
</code></pre></div><p>This prints the top 5 rows that match my search query.</p>
<p>I don&rsquo;t want all the columns, just the url and title columns should suffice. Also let&rsquo;s print the output as a table instead of JSON.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">sqlite-utils search blog.db posts <span style="color:#e6db74">&#34;lemon*&#34;</span> --limit <span style="color:#ae81ff">5</span> -c url  -c title --table
</code></pre></div><p>Tada! We have a working search in commandline.</p>
<p>As much as I love the commandline, it doesn&rsquo;t help me integrate the search into the blog.</p>
<p>That&rsquo;s where <a href="https://datasette.io/">datasette</a> comes in. Datasette is a tool to create a REST interface (and a Web UI) for SQLite databases.</p>
<p>I can launch a datasette server with the blog database and use the REST API to query the database.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-bash" data-lang="bash">datasette serve blog.db
</code></pre></div><p>I can visit <a href="http://localhost:8001">http://localhost:8001</a> to view the web interface and try out the search feature. Datasette is smart enough to autodetect that FTS is enabled for a table and provide a nice input box to search.</p>
<p><img loading="lazy" src="/images/datasette_fts.png" alt="datasette screenshot"  />
</p>
<p>I used the <a href="https://datasette.io/plugins/datasette-publish-fly">datasette-publish-fly</a> to publish the database to <a href="https://fly.io">fly.io</a>. You can try out the search feature at <a href="https://amjith-blog-fts-search.fly.dev/fts_blog/posts">https://amjith-blog-fts-search.fly.dev/fts_blog/posts</a>. It is not yet integrated into the blog search yet. That&rsquo;ll come later.</p>
<p>Thanks to <a href="https://simonwillison.net/">Simon Willison</a> for creating <a href="https://sqlite-utils.datasette.io/">sqlite-utils</a> and <a href="https://datasette.io/">datasette</a> and writing such detailed documentation of the tools.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Triggering multiple api calls in HTMX</title>
      <link>https://amjith.com/blog/2023/multiple_calls_htmx/</link>
      <pubDate>Mon, 29 May 2023 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/2023/multiple_calls_htmx/</guid>
      <description>&lt;p&gt;I am a big fan of &lt;a href=&#34;https://htmx.org&#34;&gt;htmx&lt;/a&gt; and use it in a lot of my projects. I recently had a use case where I needed to trigger multiple api calls in a single htmx request. I was able to do this by using the &lt;code&gt;hx-trigger&lt;/code&gt; attribute.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-html&#34; data-lang=&#34;html&#34;&gt;&amp;lt;&lt;span style=&#34;color:#f92672&#34;&gt;html&lt;/span&gt;&amp;gt;
  &amp;lt;&lt;span style=&#34;color:#f92672&#34;&gt;head&lt;/span&gt;&amp;gt;
    &amp;lt;&lt;span style=&#34;color:#f92672&#34;&gt;script&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;src&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;https://unpkg.com/htmx.org@1.9.2&amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;integrity&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;sha384-L6OqL9pRWyyFU3+/bjdSri+iIphTN/bvYyM37tICVyOJkWZLpP2vGn6VUEXgzg6h&amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;crossorigin&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;anonymous&amp;#34;&lt;/span&gt;&amp;gt;&amp;lt;/&lt;span style=&#34;color:#f92672&#34;&gt;script&lt;/span&gt;&amp;gt;
  &amp;lt;/&lt;span style=&#34;color:#f92672&#34;&gt;head&lt;/span&gt;&amp;gt;
  &amp;lt;&lt;span style=&#34;color:#f92672&#34;&gt;body&lt;/span&gt;&amp;gt;
    &amp;lt;&lt;span style=&#34;color:#f92672&#34;&gt;input&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;id&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;input-box&amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;type&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;text&amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;placeholder&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Enter your input and press Enter&amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;name&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;name&amp;#34;&lt;/span&gt;&amp;gt;
    &amp;lt;&lt;span style=&#34;color:#f92672&#34;&gt;div&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;hx-get&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;/api/call1&amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;hx-trigger&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;keyup delay:200ms from:#input-box&amp;#34;&lt;/span&gt;&amp;gt;

    &amp;lt;/&lt;span style=&#34;color:#f92672&#34;&gt;div&lt;/span&gt;&amp;gt;
    &amp;lt;&lt;span style=&#34;color:#f92672&#34;&gt;div&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;hx-get&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;/api/call2&amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;hx-trigger&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;keyup delay:200ms from:#input-box&amp;#34;&lt;/span&gt;&amp;gt;

    &amp;lt;/&lt;span style=&#34;color:#f92672&#34;&gt;div&lt;/span&gt;&amp;gt;
    &amp;lt;&lt;span style=&#34;color:#f92672&#34;&gt;div&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;hx-get&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;/api/call3&amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;hx-trigger&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;keyup delay:200ms from:#input-box&amp;#34;&lt;/span&gt;&amp;gt;

    &amp;lt;/&lt;span style=&#34;color:#f92672&#34;&gt;div&lt;/span&gt;&amp;gt;
  &amp;lt;/&lt;span style=&#34;color:#f92672&#34;&gt;body&lt;/span&gt;&amp;gt;
&amp;lt;/&lt;span style=&#34;color:#f92672&#34;&gt;html&lt;/span&gt;&amp;gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The idea is to listen to the &lt;code&gt;keyup&lt;/code&gt; event on the input box and trigger the api calls after a delay of 200ms. The &lt;code&gt;from&lt;/code&gt; attribute is used to specify the element that the event is triggered on. In this case, it is the input box with id &lt;code&gt;input-box&lt;/code&gt;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I am a big fan of <a href="https://htmx.org">htmx</a> and use it in a lot of my projects. I recently had a use case where I needed to trigger multiple api calls in a single htmx request. I was able to do this by using the <code>hx-trigger</code> attribute.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-html" data-lang="html">&lt;<span style="color:#f92672">html</span>&gt;
  &lt;<span style="color:#f92672">head</span>&gt;
    &lt;<span style="color:#f92672">script</span> <span style="color:#a6e22e">src</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;https://unpkg.com/htmx.org@1.9.2&#34;</span> <span style="color:#a6e22e">integrity</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;sha384-L6OqL9pRWyyFU3+/bjdSri+iIphTN/bvYyM37tICVyOJkWZLpP2vGn6VUEXgzg6h&#34;</span> <span style="color:#a6e22e">crossorigin</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;anonymous&#34;</span>&gt;&lt;/<span style="color:#f92672">script</span>&gt;
  &lt;/<span style="color:#f92672">head</span>&gt;
  &lt;<span style="color:#f92672">body</span>&gt;
    &lt;<span style="color:#f92672">input</span> <span style="color:#a6e22e">id</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;input-box&#34;</span> <span style="color:#a6e22e">type</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;text&#34;</span> <span style="color:#a6e22e">placeholder</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;Enter your input and press Enter&#34;</span> <span style="color:#a6e22e">name</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;name&#34;</span>&gt;
    &lt;<span style="color:#f92672">div</span> <span style="color:#a6e22e">hx-get</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;/api/call1&#34;</span> <span style="color:#a6e22e">hx-trigger</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;keyup delay:200ms from:#input-box&#34;</span>&gt;

    &lt;/<span style="color:#f92672">div</span>&gt;
    &lt;<span style="color:#f92672">div</span> <span style="color:#a6e22e">hx-get</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;/api/call2&#34;</span> <span style="color:#a6e22e">hx-trigger</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;keyup delay:200ms from:#input-box&#34;</span>&gt;

    &lt;/<span style="color:#f92672">div</span>&gt;
    &lt;<span style="color:#f92672">div</span> <span style="color:#a6e22e">hx-get</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;/api/call3&#34;</span> <span style="color:#a6e22e">hx-trigger</span><span style="color:#f92672">=</span><span style="color:#e6db74">&#34;keyup delay:200ms from:#input-box&#34;</span>&gt;

    &lt;/<span style="color:#f92672">div</span>&gt;
  &lt;/<span style="color:#f92672">body</span>&gt;
&lt;/<span style="color:#f92672">html</span>&gt;
</code></pre></div><p>The idea is to listen to the <code>keyup</code> event on the input box and trigger the api calls after a delay of 200ms. The <code>from</code> attribute is used to specify the element that the event is triggered on. In this case, it is the input box with id <code>input-box</code>.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Migrating out of PostHaven</title>
      <link>https://amjith.com/blog/posthaven/</link>
      <pubDate>Fri, 19 May 2023 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/posthaven/</guid>
      <description>&lt;p&gt;My blog was hosted on PostHaven for about 12 years now. It&amp;rsquo;s a pretty good platform and has served me well. But I wanted to move my blog to a MarkDown powered static site. Unfortunately, posthaven doesn&amp;rsquo;t provide an export option, probably because it not in their financial interest. Oh well, I&amp;rsquo;ll scrape my own blog and extract the posts.&lt;/p&gt;
&lt;p&gt;My first attempt was to use the &lt;a href=&#34;https://requests.readthedocs.io/en/latest/&#34;&gt;requests&lt;/a&gt; and &lt;a href=&#34;https://www.crummy.com/software/BeautifulSoup/bs4/doc/&#34;&gt;BeautifulSoup&lt;/a&gt; to fetch the urls from the archives page. But the archives page is lazy loaded using Javascript and I was not in the mood to learn &lt;a href=&#34;https://www.selenium.dev/&#34;&gt;selenium&lt;/a&gt; for this task.&lt;/p&gt;
&lt;p&gt;I remembered Simon&amp;rsquo;s &lt;a href=&#34;https://shot-scraper.datasette.io&#34;&gt;shot-scraper&lt;/a&gt; tool which is a CLI for taking screenshots of websites. A quick look at the &lt;a href=&#34;https://shot-scraper.datasette.io/en/stable/javascript.html&#34;&gt;documentation&lt;/a&gt; showed fully functional examples of selectively scraping a website using CSS selectors and returning the results as JSON.&lt;/p&gt;
&lt;p&gt;Here&amp;rsquo;s the final script I used to scrape my blog and extract the posts into a SQLite database using &lt;a href=&#34;https://sqlite-utils.datasette.io/&#34;&gt;sqlite-utils&lt;/a&gt; library.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; json
&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; sqlite_utils &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; Database   &lt;span style=&#34;color:#75715e&#34;&gt;# pip install sqlite-utils&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; runez                        &lt;span style=&#34;color:#75715e&#34;&gt;# pip install runez&lt;/span&gt;

archives &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; [&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;https://blog.amjith.com/archive&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;https://blog.amjith.com/archive?page=2&amp;#34;&lt;/span&gt;]
blog_urls &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; []
archive_js &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&amp;#34;new Promise(done =&amp;gt; setInterval(() =&amp;gt; {done(
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                    Array.from(
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                      document.querySelectorAll(&amp;#34;.archive-list ul li a&amp;#34;)).map(x =&amp;gt; x.href))
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                   }, 1000));&amp;#34;&amp;#34;&amp;#34;&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# iterate over each archive page and grab the url for the individual posts&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; archive_page &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; archives:
    r &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; runez&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;run(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;shot-scraper&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;javascript&amp;#34;&lt;/span&gt;, archive_page, archive_js)
    urls &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; json&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;loads(r&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;output)
    blog_urls&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;extend(urls)
    
post_js &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&amp;#34;new Promise(done =&amp;gt; setInterval(() =&amp;gt; {
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                    done({
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                        title: document.querySelector(&amp;#34;.post-title h2&amp;#34;).innerText,
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                        rawbody: document.querySelector(&amp;#34;.post-body&amp;#34;).innerHTML,
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                        date: document.querySelector(&amp;#34;.posthaven-formatted-date&amp;#34;).getAttribute(&amp;#34;data-unix-time&amp;#34;),
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                        tags: Array.from(document.querySelectorAll(&amp;#34;header .tags a&amp;#34;)).map(x =&amp;gt; x.innerText),
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                        }
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                        )
&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;                   }, 5));&amp;#34;&amp;#34;&amp;#34;&lt;/span&gt;
blog_posts &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; []
&lt;span style=&#34;color:#75715e&#34;&gt;# iterate over each blog_url and fetch the title, post, tags and date&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; url &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; blog_urls:
    print(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fetching&amp;#34;&lt;/span&gt;, url)
    r &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; runez&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;run(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;shot-scraper&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;javascript&amp;#34;&lt;/span&gt;, url, post_js)
    content &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; json&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;loads(r&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;output)
    content[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;url&amp;#34;&lt;/span&gt;] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; url
    blog_posts&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append(content)

db &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; Database(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;blog.db&amp;#34;&lt;/span&gt;)
db[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;posts&amp;#34;&lt;/span&gt;]&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;insert_all(blog_posts, pk&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;id&amp;#34;&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Now I have a SQLite database with a table called &lt;code&gt;posts&lt;/code&gt; with all my blog posts. I used &lt;a href=&#34;https://github.com/matthewwithanm/python-markdownify&#34;&gt;markdownify&lt;/a&gt; to convert the HTML snippets to markdown and write them out as individual files that were compatible with Hugo static site format.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; sqlite_utils
&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; datetime &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; datetime
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; os
&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; markdownify &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; markdownify &lt;span style=&#34;color:#66d9ef&#34;&gt;as&lt;/span&gt; md  &lt;span style=&#34;color:#75715e&#34;&gt;# pip install markdownify&lt;/span&gt;

db &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sqlite_utils&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Database(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;blog.db&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; row &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; db[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;posts&amp;#34;&lt;/span&gt;]&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;rows:
    ts &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; datetime&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;fromtimestamp(int(row[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;date&amp;#34;&lt;/span&gt;]))
    &lt;span style=&#34;color:#75715e&#34;&gt;# Convert ts to iso 8601&lt;/span&gt;
    slug &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; row[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;url&amp;#34;&lt;/span&gt;]&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;rsplit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;/&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;)[&lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;]
    date &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; ts&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;isoformat()
    year &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; ts&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;strftime(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;%Y&amp;#34;&lt;/span&gt;)
    os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;makedirs(year, exist_ok&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;True&lt;/span&gt;)
    filename &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;f&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;{&lt;/span&gt;year&lt;span style=&#34;color:#e6db74&#34;&gt;}&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;{&lt;/span&gt;slug&lt;span style=&#34;color:#e6db74&#34;&gt;}&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;.md&amp;#34;&lt;/span&gt;
    &lt;span style=&#34;color:#66d9ef&#34;&gt;with&lt;/span&gt; open(filename, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;w&amp;#34;&lt;/span&gt;) &lt;span style=&#34;color:#66d9ef&#34;&gt;as&lt;/span&gt; f:
        f&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;---&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\n&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;)
        f&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(&lt;span style=&#34;color:#e6db74&#34;&gt;f&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;title: &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;{&lt;/span&gt;row[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;title&amp;#34;&lt;/span&gt;]&lt;span style=&#34;color:#e6db74&#34;&gt;}&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\n&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&lt;/span&gt;)
        f&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(&lt;span style=&#34;color:#e6db74&#34;&gt;f&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;date: &lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;{&lt;/span&gt;date&lt;span style=&#34;color:#e6db74&#34;&gt;}&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\n&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;)
        f&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(&lt;span style=&#34;color:#e6db74&#34;&gt;f&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;tags: &lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;{&lt;/span&gt;row[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;tags&amp;#39;&lt;/span&gt;]&lt;span style=&#34;color:#e6db74&#34;&gt;}&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\n&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;)
        f&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(&lt;span style=&#34;color:#e6db74&#34;&gt;f&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;url: &amp;#34;/blog/&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;{&lt;/span&gt;slug&lt;span style=&#34;color:#e6db74&#34;&gt;}&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\n&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&lt;/span&gt;)
        f&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;---&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\n\n&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;)
        f&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(md(row[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;rawbody&amp;#34;&lt;/span&gt;]))
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;We&amp;rsquo;re all done. Welcome to my new &lt;a href=&#34;https://amjith.com/blog&#34;&gt;blog&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Now that I own all my content and not locked into a vendor, maybe I&amp;rsquo;ll write more often.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>My blog was hosted on PostHaven for about 12 years now. It&rsquo;s a pretty good platform and has served me well. But I wanted to move my blog to a MarkDown powered static site. Unfortunately, posthaven doesn&rsquo;t provide an export option, probably because it not in their financial interest. Oh well, I&rsquo;ll scrape my own blog and extract the posts.</p>
<p>My first attempt was to use the <a href="https://requests.readthedocs.io/en/latest/">requests</a> and <a href="https://www.crummy.com/software/BeautifulSoup/bs4/doc/">BeautifulSoup</a> to fetch the urls from the archives page. But the archives page is lazy loaded using Javascript and I was not in the mood to learn <a href="https://www.selenium.dev/">selenium</a> for this task.</p>
<p>I remembered Simon&rsquo;s <a href="https://shot-scraper.datasette.io">shot-scraper</a> tool which is a CLI for taking screenshots of websites. A quick look at the <a href="https://shot-scraper.datasette.io/en/stable/javascript.html">documentation</a> showed fully functional examples of selectively scraping a website using CSS selectors and returning the results as JSON.</p>
<p>Here&rsquo;s the final script I used to scrape my blog and extract the posts into a SQLite database using <a href="https://sqlite-utils.datasette.io/">sqlite-utils</a> library.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-python" data-lang="python"><span style="color:#f92672">import</span> json
<span style="color:#f92672">from</span> sqlite_utils <span style="color:#f92672">import</span> Database   <span style="color:#75715e"># pip install sqlite-utils</span>
<span style="color:#f92672">import</span> runez                        <span style="color:#75715e"># pip install runez</span>

archives <span style="color:#f92672">=</span> [<span style="color:#e6db74">&#34;https://blog.amjith.com/archive&#34;</span>, <span style="color:#e6db74">&#34;https://blog.amjith.com/archive?page=2&#34;</span>]
blog_urls <span style="color:#f92672">=</span> []
archive_js <span style="color:#f92672">=</span> <span style="color:#e6db74">&#34;&#34;&#34;new Promise(done =&gt; setInterval(() =&gt; {done(
</span><span style="color:#e6db74">                    Array.from(
</span><span style="color:#e6db74">                      document.querySelectorAll(&#34;.archive-list ul li a&#34;)).map(x =&gt; x.href))
</span><span style="color:#e6db74">                   }, 1000));&#34;&#34;&#34;</span>
<span style="color:#75715e"># iterate over each archive page and grab the url for the individual posts</span>
<span style="color:#66d9ef">for</span> archive_page <span style="color:#f92672">in</span> archives:
    r <span style="color:#f92672">=</span> runez<span style="color:#f92672">.</span>run(<span style="color:#e6db74">&#34;shot-scraper&#34;</span>, <span style="color:#e6db74">&#34;javascript&#34;</span>, archive_page, archive_js)
    urls <span style="color:#f92672">=</span> json<span style="color:#f92672">.</span>loads(r<span style="color:#f92672">.</span>output)
    blog_urls<span style="color:#f92672">.</span>extend(urls)
    
post_js <span style="color:#f92672">=</span> <span style="color:#e6db74">&#34;&#34;&#34;new Promise(done =&gt; setInterval(() =&gt; {
</span><span style="color:#e6db74">                    done({
</span><span style="color:#e6db74">                        title: document.querySelector(&#34;.post-title h2&#34;).innerText,
</span><span style="color:#e6db74">                        rawbody: document.querySelector(&#34;.post-body&#34;).innerHTML,
</span><span style="color:#e6db74">                        date: document.querySelector(&#34;.posthaven-formatted-date&#34;).getAttribute(&#34;data-unix-time&#34;),
</span><span style="color:#e6db74">                        tags: Array.from(document.querySelectorAll(&#34;header .tags a&#34;)).map(x =&gt; x.innerText),
</span><span style="color:#e6db74">                        }
</span><span style="color:#e6db74">                        )
</span><span style="color:#e6db74">                   }, 5));&#34;&#34;&#34;</span>
blog_posts <span style="color:#f92672">=</span> []
<span style="color:#75715e"># iterate over each blog_url and fetch the title, post, tags and date</span>
<span style="color:#66d9ef">for</span> url <span style="color:#f92672">in</span> blog_urls:
    print(<span style="color:#e6db74">&#34;Fetching&#34;</span>, url)
    r <span style="color:#f92672">=</span> runez<span style="color:#f92672">.</span>run(<span style="color:#e6db74">&#34;shot-scraper&#34;</span>, <span style="color:#e6db74">&#34;javascript&#34;</span>, url, post_js)
    content <span style="color:#f92672">=</span> json<span style="color:#f92672">.</span>loads(r<span style="color:#f92672">.</span>output)
    content[<span style="color:#e6db74">&#34;url&#34;</span>] <span style="color:#f92672">=</span> url
    blog_posts<span style="color:#f92672">.</span>append(content)

db <span style="color:#f92672">=</span> Database(<span style="color:#e6db74">&#34;blog.db&#34;</span>)
db[<span style="color:#e6db74">&#34;posts&#34;</span>]<span style="color:#f92672">.</span>insert_all(blog_posts, pk<span style="color:#f92672">=</span><span style="color:#e6db74">&#34;id&#34;</span>)
</code></pre></div><p>Now I have a SQLite database with a table called <code>posts</code> with all my blog posts. I used <a href="https://github.com/matthewwithanm/python-markdownify">markdownify</a> to convert the HTML snippets to markdown and write them out as individual files that were compatible with Hugo static site format.</p>
<div class="highlight"><pre style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-python" data-lang="python"><span style="color:#f92672">import</span> sqlite_utils
<span style="color:#f92672">from</span> datetime <span style="color:#f92672">import</span> datetime
<span style="color:#f92672">import</span> os
<span style="color:#f92672">from</span> markdownify <span style="color:#f92672">import</span> markdownify <span style="color:#66d9ef">as</span> md  <span style="color:#75715e"># pip install markdownify</span>

db <span style="color:#f92672">=</span> sqlite_utils<span style="color:#f92672">.</span>Database(<span style="color:#e6db74">&#34;blog.db&#34;</span>)
<span style="color:#66d9ef">for</span> row <span style="color:#f92672">in</span> db[<span style="color:#e6db74">&#34;posts&#34;</span>]<span style="color:#f92672">.</span>rows:
    ts <span style="color:#f92672">=</span> datetime<span style="color:#f92672">.</span>fromtimestamp(int(row[<span style="color:#e6db74">&#34;date&#34;</span>]))
    <span style="color:#75715e"># Convert ts to iso 8601</span>
    slug <span style="color:#f92672">=</span> row[<span style="color:#e6db74">&#34;url&#34;</span>]<span style="color:#f92672">.</span>rsplit(<span style="color:#e6db74">&#34;/&#34;</span>, <span style="color:#ae81ff">1</span>)[<span style="color:#f92672">-</span><span style="color:#ae81ff">1</span>]
    date <span style="color:#f92672">=</span> ts<span style="color:#f92672">.</span>isoformat()
    year <span style="color:#f92672">=</span> ts<span style="color:#f92672">.</span>strftime(<span style="color:#e6db74">&#34;%Y&#34;</span>)
    os<span style="color:#f92672">.</span>makedirs(year, exist_ok<span style="color:#f92672">=</span><span style="color:#66d9ef">True</span>)
    filename <span style="color:#f92672">=</span> <span style="color:#e6db74">f</span><span style="color:#e6db74">&#34;</span><span style="color:#e6db74">{</span>year<span style="color:#e6db74">}</span><span style="color:#e6db74">/</span><span style="color:#e6db74">{</span>slug<span style="color:#e6db74">}</span><span style="color:#e6db74">.md&#34;</span>
    <span style="color:#66d9ef">with</span> open(filename, <span style="color:#e6db74">&#34;w&#34;</span>) <span style="color:#66d9ef">as</span> f:
        f<span style="color:#f92672">.</span>write(<span style="color:#e6db74">&#34;---</span><span style="color:#ae81ff">\n</span><span style="color:#e6db74">&#34;</span>)
        f<span style="color:#f92672">.</span>write(<span style="color:#e6db74">f</span><span style="color:#e6db74">&#39;title: &#34;</span><span style="color:#e6db74">{</span>row[<span style="color:#e6db74">&#34;title&#34;</span>]<span style="color:#e6db74">}</span><span style="color:#e6db74">&#34;</span><span style="color:#ae81ff">\n</span><span style="color:#e6db74">&#39;</span>)
        f<span style="color:#f92672">.</span>write(<span style="color:#e6db74">f</span><span style="color:#e6db74">&#34;date: </span><span style="color:#e6db74">{</span>date<span style="color:#e6db74">}</span><span style="color:#ae81ff">\n</span><span style="color:#e6db74">&#34;</span>)
        f<span style="color:#f92672">.</span>write(<span style="color:#e6db74">f</span><span style="color:#e6db74">&#34;tags: </span><span style="color:#e6db74">{</span>row[<span style="color:#e6db74">&#39;tags&#39;</span>]<span style="color:#e6db74">}</span><span style="color:#ae81ff">\n</span><span style="color:#e6db74">&#34;</span>)
        f<span style="color:#f92672">.</span>write(<span style="color:#e6db74">f</span><span style="color:#e6db74">&#39;url: &#34;/blog/</span><span style="color:#e6db74">{</span>slug<span style="color:#e6db74">}</span><span style="color:#e6db74">&#34;</span><span style="color:#ae81ff">\n</span><span style="color:#e6db74">&#39;</span>)
        f<span style="color:#f92672">.</span>write(<span style="color:#e6db74">&#34;---</span><span style="color:#ae81ff">\n\n</span><span style="color:#e6db74">&#34;</span>)
        f<span style="color:#f92672">.</span>write(md(row[<span style="color:#e6db74">&#34;rawbody&#34;</span>]))
</code></pre></div><p>We&rsquo;re all done. Welcome to my new <a href="https://amjith.com/blog">blog</a>.</p>
<p>Now that I own all my content and not locked into a vendor, maybe I&rsquo;ll write more often.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Opportunities</title>
      <link>https://amjith.com/blog/opportunities/</link>
      <pubDate>Tue, 04 Oct 2022 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/opportunities/</guid>
      <description>&lt;p&gt;I am setting the table for breakfast. I announce loudly &amp;ldquo;Breakfast is ready&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;Vian sits down at the table and notices that I had left two forks next to his plate of cantaloupe slices.&lt;/p&gt;
&lt;p&gt;Vian: Who put two forks?&lt;/p&gt;
&lt;p&gt;Me: Oh, I didn&amp;rsquo;t realize I left two forks. My mistake.&lt;/p&gt;
&lt;p&gt;Vian: No, it&amp;rsquo;s ok. &lt;/p&gt;
&lt;p&gt;Then proceeds to use both his forks to pick up two slices of cantaloupes and starts shoving them in his mouth. I was reminded of the poignant quote &amp;ldquo;&lt;strong&gt;There are no mistakes, only opportunities&lt;/strong&gt;&amp;quot;. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I am setting the table for breakfast. I announce loudly &ldquo;Breakfast is ready&rdquo;. </p>
<p>Vian sits down at the table and notices that I had left two forks next to his plate of cantaloupe slices.</p>
<p>Vian: Who put two forks?</p>
<p>Me: Oh, I didn&rsquo;t realize I left two forks. My mistake.</p>
<p>Vian: No, it&rsquo;s ok. </p>
<p>Then proceeds to use both his forks to pick up two slices of cantaloupes and starts shoving them in his mouth. I was reminded of the poignant quote &ldquo;<strong>There are no mistakes, only opportunities</strong>&quot;. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Opposite of a Crater</title>
      <link>https://amjith.com/blog/opposite-of-a-crater/</link>
      <pubDate>Wed, 31 Aug 2022 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/opposite-of-a-crater/</guid>
      <description>&lt;p&gt;The kids are having Pizza. One of the pizza slices had a trapped air bubble and looked engorged.&lt;/p&gt;
&lt;p&gt;Yoshi: Looks like there is a crater in your pizza. (from her angle she could only see the gaping hole). &lt;/p&gt;
&lt;p&gt;Sempi: (from his side he can only see the bulge) No it is the opposite of a crater. It is a meteor. &lt;/p&gt;
&lt;p&gt;TIL the opposite of a crater is a meteor. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>The kids are having Pizza. One of the pizza slices had a trapped air bubble and looked engorged.</p>
<p>Yoshi: Looks like there is a crater in your pizza. (from her angle she could only see the gaping hole). </p>
<p>Sempi: (from his side he can only see the bulge) No it is the opposite of a crater. It is a meteor. </p>
<p>TIL the opposite of a crater is a meteor. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Egg Skin</title>
      <link>https://amjith.com/blog/egg-skin/</link>
      <pubDate>Fri, 26 Aug 2022 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/egg-skin/</guid>
      <description>&lt;p&gt;We are at the breakfast table. Vian is having cereal and I am having hard boiled eggs for breakfast. I offered one of my eggs to Vian. &lt;/p&gt;
&lt;p&gt;Vian: I don&amp;rsquo;t like the yolk.&lt;/p&gt;
&lt;p&gt;Me: I can take it out for you. &lt;/p&gt;
&lt;p&gt;Vian: Yeah, if you can take out the yolk, I will eat just the skin. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We are at the breakfast table. Vian is having cereal and I am having hard boiled eggs for breakfast. I offered one of my eggs to Vian. </p>
<p>Vian: I don&rsquo;t like the yolk.</p>
<p>Me: I can take it out for you. </p>
<p>Vian: Yeah, if you can take out the yolk, I will eat just the skin. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Kinder Graduation</title>
      <link>https://amjith.com/blog/kinder-graduation/</link>
      <pubDate>Thu, 09 Jun 2022 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/kinder-graduation/</guid>
      <description>&lt;p&gt;Vian&amp;rsquo;s last day of graduation was yesterday. It was a heartwarming ceremony where the teacher recognized each kid with a certificate for a certain quality and had the kids announce what they want to be when they grew up. &lt;/p&gt;
&lt;p&gt;Vian was recognized as a problem solver. He then stood up and announced, &lt;strong&gt;I want to be a dad when I grow up&lt;/strong&gt;. &lt;/p&gt;
&lt;p&gt;Needless to say I was floored by this announcement. I was walking around with a big grin. It was the happiest day of my life (so far). &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian&rsquo;s last day of graduation was yesterday. It was a heartwarming ceremony where the teacher recognized each kid with a certificate for a certain quality and had the kids announce what they want to be when they grew up. </p>
<p>Vian was recognized as a problem solver. He then stood up and announced, <strong>I want to be a dad when I grow up</strong>. </p>
<p>Needless to say I was floored by this announcement. I was walking around with a big grin. It was the happiest day of my life (so far). </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 6yo</title>
      <link>https://amjith.com/blog/conversations-with-a-6yo/</link>
      <pubDate>Sat, 04 Jun 2022 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-6yo/</guid>
      <description>&lt;p&gt;Yoshi is having a serious conversation with the kids. &lt;/p&gt;
&lt;p&gt;Vian is jumping around being playful and generally not paying any attention to Yoshi. &lt;/p&gt;
&lt;p&gt;Yoshi: Vian did you hear what I just said. &lt;/p&gt;
&lt;p&gt;Vian: Yeah!&lt;/p&gt;
&lt;p&gt;Yoshi: Can you tell me what you heard? &lt;/p&gt;
&lt;p&gt;Vian: I don&amp;rsquo;t know. &lt;/p&gt;
&lt;p&gt;Yoshi: But you said you were paying attention. &lt;/p&gt;
&lt;p&gt;Vian: I&amp;rsquo;m just really good at forgetting.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Yoshi is having a serious conversation with the kids. </p>
<p>Vian is jumping around being playful and generally not paying any attention to Yoshi. </p>
<p>Yoshi: Vian did you hear what I just said. </p>
<p>Vian: Yeah!</p>
<p>Yoshi: Can you tell me what you heard? </p>
<p>Vian: I don&rsquo;t know. </p>
<p>Yoshi: But you said you were paying attention. </p>
<p>Vian: I&rsquo;m just really good at forgetting.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations about the largest number</title>
      <link>https://amjith.com/blog/conversations-about-the-largest-number/</link>
      <pubDate>Mon, 23 May 2022 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-about-the-largest-number/</guid>
      <description>&lt;p&gt;We&amp;rsquo;re at a restaurant waiting for our food. My 9yo is discussing large numbers. &lt;/p&gt;
&lt;p&gt;Sempi: Did you know that googol is 1 followed by 100 zeroes?&lt;/p&gt;
&lt;p&gt;Me: Yeah. &lt;/p&gt;
&lt;p&gt;Sempi: And googolplex means 1 raised to the power of googol. &lt;/p&gt;
&lt;p&gt;Me: Technically it is 10 to the power of googol because 1 to the power of anything is just 1. &lt;/p&gt;
&lt;p&gt;Sempi: Ok. (whatever). &lt;/p&gt;
&lt;p&gt;Me: Also Google is named after googol. &lt;/p&gt;
&lt;p&gt;Sempi: I know. &lt;/p&gt;
&lt;p&gt;Me: Google&amp;rsquo;s first office was called Googleplex, named after googolplex. &lt;/p&gt;
&lt;p&gt;Sempi: Oooh. Cool!&lt;/p&gt;
&lt;p&gt;Vian (6yo): Is that the biggest number in the universe. &lt;/p&gt;
&lt;p&gt;Yoshi: I read that there aren&amp;rsquo;t googolplex number of atoms in the universe.&lt;/p&gt;
&lt;p&gt;Me: Well technically there is a number that is so unimaginably large. It is called &lt;a href=&#34;https://en.wikipedia.org/wiki/Graham%27s_number&#34;&gt;Graham&amp;rsquo;s Number&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Sempi and Vian: Oh. How many zeros does it have? 1000? &lt;/p&gt;
&lt;p&gt;Me: No it is so big that you can&amp;rsquo;t even imagine it. (I try reading the wikipedia entry without success)&lt;/p&gt;
&lt;p&gt;Me: I can&amp;rsquo;t quite explain it very well because I don&amp;rsquo;t fully understand it myself.&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Next day I&amp;rsquo;m walking Vian to school. We&amp;rsquo;re doing imaginative &amp;ldquo;talk play&amp;rdquo;. Vian is describing a generator in Minecraft that can produce something infinitely. &lt;/p&gt;
&lt;p&gt;Vian: It just keeps generating it forever. Actually that&amp;rsquo;s not true, it only goes up to that number that you couldn&amp;rsquo;t explain. &lt;/p&gt;
&lt;p&gt;Me: Graham&amp;rsquo;s number? &lt;/p&gt;
&lt;p&gt;Vian: Yeah, that. &lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;I&amp;rsquo;m so proud that Graham&amp;rsquo;s number is a casual quantity in our household now. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We&rsquo;re at a restaurant waiting for our food. My 9yo is discussing large numbers. </p>
<p>Sempi: Did you know that googol is 1 followed by 100 zeroes?</p>
<p>Me: Yeah. </p>
<p>Sempi: And googolplex means 1 raised to the power of googol. </p>
<p>Me: Technically it is 10 to the power of googol because 1 to the power of anything is just 1. </p>
<p>Sempi: Ok. (whatever). </p>
<p>Me: Also Google is named after googol. </p>
<p>Sempi: I know. </p>
<p>Me: Google&rsquo;s first office was called Googleplex, named after googolplex. </p>
<p>Sempi: Oooh. Cool!</p>
<p>Vian (6yo): Is that the biggest number in the universe. </p>
<p>Yoshi: I read that there aren&rsquo;t googolplex number of atoms in the universe.</p>
<p>Me: Well technically there is a number that is so unimaginably large. It is called <a href="https://en.wikipedia.org/wiki/Graham%27s_number">Graham&rsquo;s Number</a>.</p>
<p>Sempi and Vian: Oh. How many zeros does it have? 1000? </p>
<p>Me: No it is so big that you can&rsquo;t even imagine it. (I try reading the wikipedia entry without success)</p>
<p>Me: I can&rsquo;t quite explain it very well because I don&rsquo;t fully understand it myself.</p>
<hr>
<p>Next day I&rsquo;m walking Vian to school. We&rsquo;re doing imaginative &ldquo;talk play&rdquo;. Vian is describing a generator in Minecraft that can produce something infinitely. </p>
<p>Vian: It just keeps generating it forever. Actually that&rsquo;s not true, it only goes up to that number that you couldn&rsquo;t explain. </p>
<p>Me: Graham&rsquo;s number? </p>
<p>Vian: Yeah, that. </p>
<hr>
<p>I&rsquo;m so proud that Graham&rsquo;s number is a casual quantity in our household now. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Hot Cocoa Part 2</title>
      <link>https://amjith.com/blog/hot-cocoa-part-2/</link>
      <pubDate>Tue, 22 Feb 2022 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/hot-cocoa-part-2/</guid>
      <description>&lt;p&gt;Yoshi is making &lt;a href=&#34;https://amjith.com/blog/hot-cocoa&#34;&gt;hot cocoa&lt;/a&gt; for everyone after our snow play day. &lt;/p&gt;
&lt;p&gt;Me: I think I&amp;rsquo;m going to drink all the hot chocolate that Amma is making. &lt;/p&gt;
&lt;p&gt;Vian (5yo): If you drink my hot chocolate, I&amp;rsquo;m going to punch you 5 million times in your face. &lt;/p&gt;
&lt;p&gt;Me: You can&amp;rsquo;t even count that high, Vian. &lt;/p&gt;
&lt;p&gt;Vian: Ok then I&amp;rsquo;m going to punch you one hundred times. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Yoshi is making <a href="https://amjith.com/blog/hot-cocoa">hot cocoa</a> for everyone after our snow play day. </p>
<p>Me: I think I&rsquo;m going to drink all the hot chocolate that Amma is making. </p>
<p>Vian (5yo): If you drink my hot chocolate, I&rsquo;m going to punch you 5 million times in your face. </p>
<p>Me: You can&rsquo;t even count that high, Vian. </p>
<p>Vian: Ok then I&rsquo;m going to punch you one hundred times. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Measure of Age</title>
      <link>https://amjith.com/blog/measure-of-age/</link>
      <pubDate>Tue, 22 Feb 2022 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/measure-of-age/</guid>
      <description>&lt;p&gt;Vian (5yo) is curious as ever. He asked me how old I am. &lt;/p&gt;
&lt;p&gt;Me: I am 40. &lt;/p&gt;
&lt;p&gt;Vian: You know 40 is not that old for an adult. &lt;/p&gt;
&lt;p&gt;Me: Really? How come? &lt;/p&gt;
&lt;p&gt;Vian: I can count to 40 really fast and it doesn&amp;rsquo;t even take that long. &lt;/p&gt;
&lt;p&gt;He then proceeds to demonstrate how quickly he can count from 1 to 40. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian (5yo) is curious as ever. He asked me how old I am. </p>
<p>Me: I am 40. </p>
<p>Vian: You know 40 is not that old for an adult. </p>
<p>Me: Really? How come? </p>
<p>Vian: I can count to 40 really fast and it doesn&rsquo;t even take that long. </p>
<p>He then proceeds to demonstrate how quickly he can count from 1 to 40. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Confidence of a 5yo</title>
      <link>https://amjith.com/blog/confidence-of-a-5yo/</link>
      <pubDate>Fri, 03 Dec 2021 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/confidence-of-a-5yo/</guid>
      <description>&lt;p&gt;I don&amp;rsquo;t know how to play Minecraft. Vian (5yo) decided he&amp;rsquo;s going to educate me. We&amp;rsquo;re now playing real-world Minecraft in the front yard without a computer. He&amp;rsquo;s narrating various aspects of the game as he&amp;rsquo;s walking around the front yard. A leather armor, iron ingot, wooden pickax, bedrock and so on. &lt;/p&gt;
&lt;p&gt;Then he delivers this pearl of wisdom. &lt;/p&gt;
&lt;p&gt;Vian: Here&amp;rsquo;s a good tip. When you&amp;rsquo;re in the game don&amp;rsquo;t mess with me. I&amp;rsquo;m &lt;strong&gt;﻿invincible&lt;/strong&gt;﻿ &lt;em&gt;and&lt;/em&gt; I can &lt;strong&gt;﻿fly&lt;/strong&gt;﻿. &lt;/p&gt;
&lt;p&gt;Then proceeds to extol the virtues of bedrock and diamond pickax. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I don&rsquo;t know how to play Minecraft. Vian (5yo) decided he&rsquo;s going to educate me. We&rsquo;re now playing real-world Minecraft in the front yard without a computer. He&rsquo;s narrating various aspects of the game as he&rsquo;s walking around the front yard. A leather armor, iron ingot, wooden pickax, bedrock and so on. </p>
<p>Then he delivers this pearl of wisdom. </p>
<p>Vian: Here&rsquo;s a good tip. When you&rsquo;re in the game don&rsquo;t mess with me. I&rsquo;m <strong>﻿invincible</strong>﻿ <em>and</em> I can <strong>﻿fly</strong>﻿. </p>
<p>Then proceeds to extol the virtues of bedrock and diamond pickax. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Bejeezus</title>
      <link>https://amjith.com/blog/bejeezus/</link>
      <pubDate>Tue, 30 Nov 2021 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/bejeezus/</guid>
      <description>&lt;p&gt;The kids like to scare me by trying to jump out from under the covers and yell &amp;ldquo;BOO!&amp;rdquo;. I like to pretend that I&amp;rsquo;m scared of their tactics. The other day I decided to return the favor by suddenly entering their room and yelling &amp;ldquo;BOO!&amp;rdquo;. I managed to scare Vian and he started giggling in fear and shrunk back under his comforter. &lt;/p&gt;
&lt;p&gt;Me: Hey Vian, looks like I scared the bejeezus out of you. &lt;/p&gt;
&lt;p&gt;Vian: No! No! I&amp;rsquo;m not scared. I don&amp;rsquo;t even have any bejeezus, so you didn&amp;rsquo;t really scare any bejeezus. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>The kids like to scare me by trying to jump out from under the covers and yell &ldquo;BOO!&rdquo;. I like to pretend that I&rsquo;m scared of their tactics. The other day I decided to return the favor by suddenly entering their room and yelling &ldquo;BOO!&rdquo;. I managed to scare Vian and he started giggling in fear and shrunk back under his comforter. </p>
<p>Me: Hey Vian, looks like I scared the bejeezus out of you. </p>
<p>Vian: No! No! I&rsquo;m not scared. I don&rsquo;t even have any bejeezus, so you didn&rsquo;t really scare any bejeezus. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Picture Day</title>
      <link>https://amjith.com/blog/picture-day/</link>
      <pubDate>Thu, 09 Sep 2021 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/picture-day/</guid>
      <description>&lt;p&gt;Vian is back from school, wearing a button up shirt and slacks.&lt;/p&gt;
&lt;p&gt;Me: Vian, you look dapper today. &lt;/p&gt;
&lt;p&gt;Vian: Yeah. Today was picture day.&lt;/p&gt;
&lt;p&gt;Me: Oh yeah. Did you guys go out and take a picture?&lt;/p&gt;
&lt;p&gt;Vian: No. It was just someone else taking the picture. I didn&amp;rsquo;t take the picture.&lt;/p&gt;
&lt;p&gt;Talking to my kids is the best way for me to realize how imprecise my communication is. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian is back from school, wearing a button up shirt and slacks.</p>
<p>Me: Vian, you look dapper today. </p>
<p>Vian: Yeah. Today was picture day.</p>
<p>Me: Oh yeah. Did you guys go out and take a picture?</p>
<p>Vian: No. It was just someone else taking the picture. I didn&rsquo;t take the picture.</p>
<p>Talking to my kids is the best way for me to realize how imprecise my communication is. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversation with an 8yo</title>
      <link>https://amjith.com/blog/conversation-with-an-8yo/</link>
      <pubDate>Wed, 16 Jun 2021 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversation-with-an-8yo/</guid>
      <description>&lt;p&gt;Me: Whoa! It&amp;rsquo;s very late, we should have started getting ready for bed 20 mins ago. &lt;/p&gt;
&lt;p&gt;Sempi: 20 minutes isn&amp;rsquo;t that much. If you think about it, it is only 4 time 5 minutes. &lt;/p&gt;
&lt;p&gt;Sempi: And if you think about it, 5 minutes is just 5 times 1 minute. &lt;/p&gt;
&lt;p&gt;Sempi: And if you really think about it, 1 minute isn&amp;rsquo;t that long.&lt;/p&gt;
&lt;p&gt;That&amp;rsquo;s the spirit. I should remind him of this conversation when he starts doing planks. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Me: Whoa! It&rsquo;s very late, we should have started getting ready for bed 20 mins ago. </p>
<p>Sempi: 20 minutes isn&rsquo;t that much. If you think about it, it is only 4 time 5 minutes. </p>
<p>Sempi: And if you think about it, 5 minutes is just 5 times 1 minute. </p>
<p>Sempi: And if you really think about it, 1 minute isn&rsquo;t that long.</p>
<p>That&rsquo;s the spirit. I should remind him of this conversation when he starts doing planks. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with an 8yo</title>
      <link>https://amjith.com/blog/conversations-with-an-8yo/</link>
      <pubDate>Wed, 26 May 2021 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-an-8yo/</guid>
      <description>&lt;p&gt;Sempi gets very creative when he&amp;rsquo;s building Lego structures. So I asked him about it.&lt;/p&gt;
&lt;p&gt;Me: How did you get so good at building these lego creations, Sempi?&lt;/p&gt;
&lt;p&gt;Sempi: I don&amp;rsquo;t know, I just like building things.&lt;/p&gt;
&lt;p&gt;Me: Would you say that I should just keep building things and I&amp;rsquo;ll get better over time?&lt;/p&gt;
&lt;p&gt;Sempi: It is easy to create something for yourself. You know what you want and you can make a
place for a boat or an airplane in your creations. It comes easily when you know what you want.&lt;/p&gt;
&lt;p&gt;This sounded vaguely familiar and then I realized this is a paraphrasing of one of Paul Graham&amp;rsquo;s &lt;a href=&#34;http://paulgraham.com/startupideas.html&#34;&gt;advice&lt;/a&gt; about startups.&lt;/p&gt;
&lt;p&gt;Build something you yourself want.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi gets very creative when he&rsquo;s building Lego structures. So I asked him about it.</p>
<p>Me: How did you get so good at building these lego creations, Sempi?</p>
<p>Sempi: I don&rsquo;t know, I just like building things.</p>
<p>Me: Would you say that I should just keep building things and I&rsquo;ll get better over time?</p>
<p>Sempi: It is easy to create something for yourself. You know what you want and you can make a
place for a boat or an airplane in your creations. It comes easily when you know what you want.</p>
<p>This sounded vaguely familiar and then I realized this is a paraphrasing of one of Paul Graham&rsquo;s <a href="http://paulgraham.com/startupideas.html">advice</a> about startups.</p>
<p>Build something you yourself want.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Michelangelo</title>
      <link>https://amjith.com/blog/michelangelo/</link>
      <pubDate>Mon, 22 Mar 2021 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/michelangelo/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://64.media.tumblr.com/b3cd8f9de5e68e4311ddc401bbda65df/tumblr_mf5ejswE5r1r4ejnio1_640.gifv&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Tonight we read Calvin and Hobbes for bedtime. After I read the comic strip above, I tried to explain a little about Michelangelo. &lt;/p&gt;
&lt;p&gt;Me: Remember, Michelangelo, we saw the statues he made when we went to Italy?&lt;/p&gt;
&lt;p&gt;Sempi: Yeah.&lt;/p&gt;
&lt;p&gt;Me: He&amp;rsquo;s a great sculptor. Do you guys remember the David statue?&lt;/p&gt;
&lt;p&gt;Vian: I know who Michelangelo is, he&amp;rsquo;s a TURTLE!&lt;/p&gt;
&lt;p&gt;o_O&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<blockquote>
<p><img loading="lazy" src="https://64.media.tumblr.com/b3cd8f9de5e68e4311ddc401bbda65df/tumblr_mf5ejswE5r1r4ejnio1_640.gifv" alt=""  />
</p>
</blockquote>
<p>Tonight we read Calvin and Hobbes for bedtime. After I read the comic strip above, I tried to explain a little about Michelangelo. </p>
<p>Me: Remember, Michelangelo, we saw the statues he made when we went to Italy?</p>
<p>Sempi: Yeah.</p>
<p>Me: He&rsquo;s a great sculptor. Do you guys remember the David statue?</p>
<p>Vian: I know who Michelangelo is, he&rsquo;s a TURTLE!</p>
<p>o_O</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Musings of an 8 year old</title>
      <link>https://amjith.com/blog/musings-of-an-8-year-old/</link>
      <pubDate>Mon, 08 Mar 2021 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/musings-of-an-8-year-old/</guid>
      <description>&lt;p&gt;Vian was playing with his stuffed animals.&lt;/p&gt;
&lt;p&gt;Vian: Watch my deer. It can do a somersault backwards.&lt;/p&gt;
&lt;p&gt;Sempi: (thinks for a bit, turns to me)&amp;hellip; if you call a flip a somersault, do you call a backward flip a &lt;strong&gt;wintersugar&lt;/strong&gt;? &lt;/p&gt;
&lt;p&gt;Me: What a terribly missed opportunity. They just call it a reverse somersault, those unimaginative linguists.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian was playing with his stuffed animals.</p>
<p>Vian: Watch my deer. It can do a somersault backwards.</p>
<p>Sempi: (thinks for a bit, turns to me)&hellip; if you call a flip a somersault, do you call a backward flip a <strong>wintersugar</strong>? </p>
<p>Me: What a terribly missed opportunity. They just call it a reverse somersault, those unimaginative linguists.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Bug not a Feature</title>
      <link>https://amjith.com/blog/bug-not-a-feature/</link>
      <pubDate>Sun, 07 Mar 2021 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/bug-not-a-feature/</guid>
      <description>&lt;p&gt;We are having dinner. Sempi is eating enthusiastically and suddenly cried out, &amp;ldquo;AAARGH!&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;Me: What happened?&lt;/p&gt;
&lt;p&gt;Sempi: I accidentally bit my tongue while chewing.&lt;/p&gt;
&lt;p&gt;Me: I&amp;rsquo;m sorry Sempi, that must be quite painful.&lt;/p&gt;
&lt;p&gt;Vian who is listening to all this plays around with the food in his mouth and suddenly declares:&lt;/p&gt;
&lt;p&gt;Vian: You can actually bite your tongue anytime you want, not just on accident.&lt;/p&gt;
&lt;p&gt;Me: That&amp;rsquo;s&amp;hellip;. that&amp;rsquo;s not a feature Vian, it&amp;rsquo;s a bug.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We are having dinner. Sempi is eating enthusiastically and suddenly cried out, &ldquo;AAARGH!&rdquo;.</p>
<p>Me: What happened?</p>
<p>Sempi: I accidentally bit my tongue while chewing.</p>
<p>Me: I&rsquo;m sorry Sempi, that must be quite painful.</p>
<p>Vian who is listening to all this plays around with the food in his mouth and suddenly declares:</p>
<p>Vian: You can actually bite your tongue anytime you want, not just on accident.</p>
<p>Me: That&rsquo;s&hellip;. that&rsquo;s not a feature Vian, it&rsquo;s a bug.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Not a Dinosaur</title>
      <link>https://amjith.com/blog/not-a-dinosaur/</link>
      <pubDate>Fri, 05 Mar 2021 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/not-a-dinosaur/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m reading a bedtime story to the kids. There&amp;rsquo;s a picture of a Pterosaur in one of the pages.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Vian:&lt;/strong&gt; That is not even a dinosaur.&lt;/p&gt;
&lt;p&gt;I am quite proud that he know that Pterosaurs are not Dinosaurs.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me:&lt;/strong&gt; Oh, what are they?&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Vian:&lt;/strong&gt; They&amp;rsquo;re just grown-up chickens in the sky.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Sempi:&lt;/strong&gt; Argh! They&amp;rsquo;re called Pterosaur, Vian. Ugh!&lt;/p&gt;
&lt;p&gt;Vian likes taunting his brother, so he repeats his flying chicken theory one more time for good measure.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;m reading a bedtime story to the kids. There&rsquo;s a picture of a Pterosaur in one of the pages.</p>
<p><strong>Vian:</strong> That is not even a dinosaur.</p>
<p>I am quite proud that he know that Pterosaurs are not Dinosaurs.</p>
<p><strong>Me:</strong> Oh, what are they?</p>
<p><strong>Vian:</strong> They&rsquo;re just grown-up chickens in the sky.</p>
<p><strong>Sempi:</strong> Argh! They&rsquo;re called Pterosaur, Vian. Ugh!</p>
<p>Vian likes taunting his brother, so he repeats his flying chicken theory one more time for good measure.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Nose Beard</title>
      <link>https://amjith.com/blog/nose-beard/</link>
      <pubDate>Fri, 22 Jan 2021 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/nose-beard/</guid>
      <description>&lt;p&gt;I like giving and receiving kisses from Vian (my 4yo son). Recently, Vian complained that my beard was prickly. Obviously, I&amp;rsquo;m now clean shaven (no more goatee). &lt;/p&gt;
&lt;p&gt;On the nights I put him down for bedtime, he usually gets quite sleepy while I lay down with him. Occasionally he would run his hands on my cheeks and say &amp;ldquo;Amma?&amp;rdquo; (mom). That&amp;rsquo;s gotta be the highest praise for shaving.&lt;/p&gt;
&lt;p&gt;Today during lunch, he is sitting in my lap and munching on his pasta. He casually looks up and remarks, &lt;/p&gt;
&lt;p&gt;&amp;ldquo;Your beard is getting bigger and your nose beard is getting big too&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;Time to trim my nose hair.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I like giving and receiving kisses from Vian (my 4yo son). Recently, Vian complained that my beard was prickly. Obviously, I&rsquo;m now clean shaven (no more goatee). </p>
<p>On the nights I put him down for bedtime, he usually gets quite sleepy while I lay down with him. Occasionally he would run his hands on my cheeks and say &ldquo;Amma?&rdquo; (mom). That&rsquo;s gotta be the highest praise for shaving.</p>
<p>Today during lunch, he is sitting in my lap and munching on his pasta. He casually looks up and remarks, </p>
<p>&ldquo;Your beard is getting bigger and your nose beard is getting big too&rdquo;. </p>
<p>Time to trim my nose hair.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Nevermind</title>
      <link>https://amjith.com/blog/nevermind/</link>
      <pubDate>Sat, 26 Dec 2020 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/nevermind/</guid>
      <description>&lt;p&gt;Vian (4yo) and Yoshi are snuggled up in the office couch with a cozy blanket around them, playing a game on iPad. Vian turns to me and says,&lt;/p&gt;
&lt;p&gt;Vian: Appa, can you get me something to eat? &lt;/p&gt;
&lt;p&gt;Me: Come with me, let&amp;rsquo;s find something for you. &lt;/p&gt;
&lt;p&gt;Vian: But I&amp;rsquo;m too comfy. You get me something.&lt;/p&gt;
&lt;p&gt;Me: Ok, but you have to eat whatever I get. &lt;/p&gt;
&lt;p&gt;Vian: Nevvvermind&amp;hellip;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian (4yo) and Yoshi are snuggled up in the office couch with a cozy blanket around them, playing a game on iPad. Vian turns to me and says,</p>
<p>Vian: Appa, can you get me something to eat? </p>
<p>Me: Come with me, let&rsquo;s find something for you. </p>
<p>Vian: But I&rsquo;m too comfy. You get me something.</p>
<p>Me: Ok, but you have to eat whatever I get. </p>
<p>Vian: Nevvvermind&hellip;.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Groovin&#39;</title>
      <link>https://amjith.com/blog/groovin/</link>
      <pubDate>Mon, 21 Dec 2020 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/groovin/</guid>
      <description>&lt;p&gt;Vian (4yo) runs into my home office and threatens to slice me. He strikes a pose with a hand on his hip, legs wide apart and a  foam sword in one hand. &lt;/p&gt;
&lt;p&gt;I turn on my music which plays an upbeat song on the speakers. His tiny legs start moving to the melody and pretty soon he&amp;rsquo;s shaking his hip and bobbing his head. &lt;/p&gt;
&lt;p&gt;The kid can&amp;rsquo;t control himself when it comes to music. I&amp;rsquo;ve &lt;a href=&#34;https://amjith.com/blog/dancing-with-the-dorks&#34;&gt;taught&lt;/a&gt; him well. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian (4yo) runs into my home office and threatens to slice me. He strikes a pose with a hand on his hip, legs wide apart and a  foam sword in one hand. </p>
<p>I turn on my music which plays an upbeat song on the speakers. His tiny legs start moving to the melody and pretty soon he&rsquo;s shaking his hip and bobbing his head. </p>
<p>The kid can&rsquo;t control himself when it comes to music. I&rsquo;ve <a href="https://amjith.com/blog/dancing-with-the-dorks">taught</a> him well. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Tricking a Couple of Kids</title>
      <link>https://amjith.com/blog/tricking-a-couple-of-kids/</link>
      <pubDate>Sun, 20 Dec 2020 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/tricking-a-couple-of-kids/</guid>
      <description>&lt;p&gt;Both kids insisted that they want to get ready for bed last.&lt;/p&gt;
&lt;p&gt;I told Vian (4yo) in secret that we&amp;rsquo;re going to trick Sempi (8yo). He should floss and brush but not do MiPaste (a Fluoride paste). Then after I get Sempi ready we can do MiPaste, Vian would be the last to get ready.&lt;/p&gt;
&lt;p&gt;Vian bought into the idea and he brushed first with a mischievous glee. The plan worked like a charm, Sempi was happy that he was brushing after Vian and Vian was happy that he didn&amp;rsquo;t do his MiPaste until after Sempi brushed, thus he was the last to get ready for bed.&lt;/p&gt;
&lt;p&gt;I emerged the victor. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Both kids insisted that they want to get ready for bed last.</p>
<p>I told Vian (4yo) in secret that we&rsquo;re going to trick Sempi (8yo). He should floss and brush but not do MiPaste (a Fluoride paste). Then after I get Sempi ready we can do MiPaste, Vian would be the last to get ready.</p>
<p>Vian bought into the idea and he brushed first with a mischievous glee. The plan worked like a charm, Sempi was happy that he was brushing after Vian and Vian was happy that he didn&rsquo;t do his MiPaste until after Sempi brushed, thus he was the last to get ready for bed.</p>
<p>I emerged the victor. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Computers and Memory</title>
      <link>https://amjith.com/blog/computers-and-memory/</link>
      <pubDate>Mon, 07 Dec 2020 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/computers-and-memory/</guid>
      <description>&lt;p&gt;When Sempi and I go on walks, we occasionally discuss something we both find interesting. &lt;/p&gt;
&lt;p&gt;Today during our walk today, I told Sempi memory is a tricky thing. If we have to remember a sequence of numbers some of them are really easy but others are hard. &lt;/p&gt;
&lt;p&gt;For example, we can easily remember 1,2,3,4,5,6,7. We can also remember 7,6,5,4,3,2,1 but it is quite hard for us to remember a random sequence like 3,4,2,5,1,7,6. For a computer remembering 1,2,3,4,5,6,7 takes the same effort as remember a random sequence like 3,4,2,5,1,7,6.&lt;/p&gt;
&lt;p&gt;His response was, if you write down the numbers on a paper, you won&amp;rsquo;t have to remember them at all. That&amp;rsquo;s what the computers do. They write them down in a file so they can retrieve it later. That&amp;rsquo;s why it is the same effort for them to remember a random sequence as well as a regular sequence. &lt;/p&gt;
&lt;p&gt;I thought that was a pretty clever analogy. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>When Sempi and I go on walks, we occasionally discuss something we both find interesting. </p>
<p>Today during our walk today, I told Sempi memory is a tricky thing. If we have to remember a sequence of numbers some of them are really easy but others are hard. </p>
<p>For example, we can easily remember 1,2,3,4,5,6,7. We can also remember 7,6,5,4,3,2,1 but it is quite hard for us to remember a random sequence like 3,4,2,5,1,7,6. For a computer remembering 1,2,3,4,5,6,7 takes the same effort as remember a random sequence like 3,4,2,5,1,7,6.</p>
<p>His response was, if you write down the numbers on a paper, you won&rsquo;t have to remember them at all. That&rsquo;s what the computers do. They write them down in a file so they can retrieve it later. That&rsquo;s why it is the same effort for them to remember a random sequence as well as a regular sequence. </p>
<p>I thought that was a pretty clever analogy. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Orange?</title>
      <link>https://amjith.com/blog/orange/</link>
      <pubDate>Wed, 28 Oct 2020 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/orange/</guid>
      <description>&lt;p&gt;Sempi declared that he found a word that rhymes with Orange, the color Orange. He thought they had different spelling, after I corrected him the following conversation ensued.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me:&lt;/strong&gt; The color orange and the fruit orange have the same spelling. The meaning differs based on the context. For example, when you say my car is orange it means the car&amp;rsquo;s color is orange, it doesn&amp;rsquo;t mean the car is a fruit.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Sempi:&lt;/strong&gt; Oooh! You can say that my car is related to orange, because a car can be a lemon.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://amjith.com/blog/conversations-with-a-4-year-old&#34;&gt;Previously&lt;/a&gt;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi declared that he found a word that rhymes with Orange, the color Orange. He thought they had different spelling, after I corrected him the following conversation ensued.</p>
<p><strong>Me:</strong> The color orange and the fruit orange have the same spelling. The meaning differs based on the context. For example, when you say my car is orange it means the car&rsquo;s color is orange, it doesn&rsquo;t mean the car is a fruit.</p>
<p><strong>Sempi:</strong> Oooh! You can say that my car is related to orange, because a car can be a lemon.</p>
<p><a href="https://amjith.com/blog/conversations-with-a-4-year-old">Previously</a></p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 4yo</title>
      <link>https://amjith.com/blog/conversations-with-a-4yo/</link>
      <pubDate>Fri, 15 May 2020 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-4yo/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m trying to work at home and Vian (4yo) is playing in the office next to me. He requests me to play with him. I took a break and told him that I&amp;rsquo;d draw with him. He insisted that I should play legos. So we made a compromise that we would draw then play legos. &lt;/p&gt;
&lt;p&gt;After what seemed like a good amount of drawing vehicles for a while, I told him that it is time for me to get back to work.&lt;/p&gt;
&lt;p&gt;Vian: But you said you would play with me. &lt;/p&gt;
&lt;p&gt;Me: Oh yeah I forgot. &lt;/p&gt;
&lt;p&gt;Vian: Remember, you said we would draw and then play legos?&lt;/p&gt;
&lt;p&gt;Me: Yes, I remember now. You should be a lawyer when you grow up Vian. &lt;/p&gt;
&lt;p&gt;Vian: Nah. I&amp;rsquo;m going to be batman when I grow up. &lt;/p&gt;
&lt;p&gt;As long as he has realistic goals, I&amp;rsquo;m cool with that.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://amjith.com/blog/im-batman&#34;&gt;Previously&lt;/a&gt;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;m trying to work at home and Vian (4yo) is playing in the office next to me. He requests me to play with him. I took a break and told him that I&rsquo;d draw with him. He insisted that I should play legos. So we made a compromise that we would draw then play legos. </p>
<p>After what seemed like a good amount of drawing vehicles for a while, I told him that it is time for me to get back to work.</p>
<p>Vian: But you said you would play with me. </p>
<p>Me: Oh yeah I forgot. </p>
<p>Vian: Remember, you said we would draw and then play legos?</p>
<p>Me: Yes, I remember now. You should be a lawyer when you grow up Vian. </p>
<p>Vian: Nah. I&rsquo;m going to be batman when I grow up. </p>
<p>As long as he has realistic goals, I&rsquo;m cool with that.</p>
<p><a href="https://amjith.com/blog/im-batman">Previously</a></p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Joke by a 7yo</title>
      <link>https://amjith.com/blog/joke-by-a-7yo/</link>
      <pubDate>Fri, 15 May 2020 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/joke-by-a-7yo/</guid>
      <description>&lt;p&gt;I am kind of a celebrity at home for making really bad dad jokes. &lt;/p&gt;
&lt;p&gt;Me: What does Darth Vader have for breakfast? &lt;/p&gt;
&lt;p&gt;Kids: Um. What?&lt;/p&gt;
&lt;p&gt;Me: Dark Toast!&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Sempi (7yo) decided that he&amp;rsquo;s going to try his hand. &lt;/p&gt;
&lt;p&gt;Sempi: Why does Darth Baker make cookies in space?&lt;/p&gt;
&lt;p&gt;Me: Um. Why? &lt;/p&gt;
&lt;p&gt;Sempi: Because they go well with the Milky Way. &lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m impressed by his ability to make up a joke on the spot. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I am kind of a celebrity at home for making really bad dad jokes. </p>
<p>Me: What does Darth Vader have for breakfast? </p>
<p>Kids: Um. What?</p>
<p>Me: Dark Toast!</p>
<hr>
<p>Sempi (7yo) decided that he&rsquo;s going to try his hand. </p>
<p>Sempi: Why does Darth Baker make cookies in space?</p>
<p>Me: Um. Why? </p>
<p>Sempi: Because they go well with the Milky Way. </p>
<p>I&rsquo;m impressed by his ability to make up a joke on the spot. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Strongest Family Member</title>
      <link>https://amjith.com/blog/strongest-family-member/</link>
      <pubDate>Fri, 20 Mar 2020 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/strongest-family-member/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m playing with Vian and Sempi. Vian comes at me swinging a plastic sword. I stop it with my hand and hold onto it, to prevent further assault.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Vian:&lt;/strong&gt; Appa is the strongest in the family.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Sempi:&lt;/strong&gt; No, Amma is the strongest.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Vian:&lt;/strong&gt; But Appa is bigger.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Sempi:&lt;/strong&gt; He is bigger but Amma has more muscles. So she&amp;rsquo;s stronger.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve got nothing to say, that&amp;rsquo;s just the truth.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;m playing with Vian and Sempi. Vian comes at me swinging a plastic sword. I stop it with my hand and hold onto it, to prevent further assault.</p>
<p><strong>Vian:</strong> Appa is the strongest in the family.</p>
<p><strong>Sempi:</strong> No, Amma is the strongest.</p>
<p><strong>Vian:</strong> But Appa is bigger.</p>
<p><strong>Sempi:</strong> He is bigger but Amma has more muscles. So she&rsquo;s stronger.</p>
<p>I&rsquo;ve got nothing to say, that&rsquo;s just the truth.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>!!con west</title>
      <link>https://amjith.com/blog/con-west/</link>
      <pubDate>Sun, 01 Mar 2020 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/con-west/</guid>
      <description>&lt;p&gt;I had the pleasure of attending &lt;a href=&#34;http://bangbangcon.com/west/&#34;&gt;!!con west&lt;/a&gt; last weekend. I met a lot of incredible people and listened to talks that rekindled my joy in programming.&lt;/p&gt;
&lt;p&gt;I took out my trusty &lt;a href=&#34;https://www.stabilo.com/com/products/writing/fineliner-felt-tip-pens/stabilo-point-88/&#34;&gt;Stabilo point 88&lt;/a&gt; and started taking notes. The &lt;a href=&#34;https://tifftseng.com/&#34;&gt;person&lt;/a&gt; sitting next to me complimented my choice of pen. I got very excited that someone recognized the pen and shared my interest in stationery. She then proceeded to show me her stationery collection from Japan (tiny scissors, a permanent marker, multicolor highlighter, and a twist top eraser). It was awesome! There is an indescribable joy in finding out that someone else shares your weird and quirky interests.&lt;/p&gt;
&lt;p&gt;I got caught up with Thomas (author of &lt;a href=&#34;https://curtsies.readthedocs.io/en/latest/&#34;&gt;Curtsies&lt;/a&gt; and a fellow lover of awesome CLIs). He gave me a demo of &lt;a href=&#34;https://observablehq.com&#34; title=&#34;Link: https://observablehq.com&#34;&gt;ObservableHQ&lt;/a&gt; which was very cool.&lt;/p&gt;
&lt;p&gt;I met Aaron Wood who gave an engaging and entertaining talk about ancient Greek mathematics. I had a strange feeling that I knew him from somewhere else. Turns out he went to the University of Utah (my alma mater) and we both worked as math tutors in the same department nearly 13 years ago. What a small world.&lt;/p&gt;
&lt;p&gt;There were a ton of interesting talks at the conference. Here&amp;rsquo;s a synopsis of the ones I remember.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&lt;strong&gt;Wolf, Goat, and Cabbage In Two Styles!!&lt;/strong&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;A brief showcase of two very different languages (!?) to solve the logic puzzle of transporting a Wolf, Goat, and Cabbage across a river.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&lt;strong&gt;The Ancient Greeks And Their Restless Cattle&lt;/strong&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;A wonderfully hilarious talk about mathematics during the era of Archimedes and how it was solved with modern techniques before and after computers***.*** Aaron did a great job of explaining the math behind Pell&amp;rsquo;s equation and walked us through the history of various attempts at a solution and finally showed an implementation of the solution in Ruby. I would highly recommend this talk.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&lt;strong&gt;Plotty Bird - Making Modern Games on Retro Pen Plotters!&lt;/strong&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Pen plotters are old school printers that literally used a robotic hand to draw diagrams on paper. Wesley managed to purchase one of them and hacked it to enough to start printing delightful things. They then proceeded to implement flappy bird that could be played by the pen plotter. They had brought with them a real pen plotter for us to play with and it was quite a bit of fun. There was one statement that Wesley made during the talk that resonated with me. We used to do programming because it was fun and pointless. Now that I&amp;rsquo;m paid to write programs it doesn&amp;rsquo;t seem fun anymore. We should go back to doing more programming for pointless fun.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&lt;strong&gt;Packages, but in 3D!&lt;/strong&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;I had no idea that packaging for snacksis an art. There are books written about how to fold paper/cardboard to make a specific style of packaging. Tiffany wanted to try out some of the designs from these books. So she built an image to svg converter which then feeds the SVG to a packaging cutter (sort of like a laser cutter) to try out some of the packaging designs from the book. It is now a &lt;a href=&#34;https://svg-tracer.glitch.me/&#34;&gt;standalone program&lt;/a&gt; on the web.&lt;/p&gt;
&lt;p&gt;All in all, I had a wonderful time at the conference and I can&amp;rsquo;t wait for the next one. :)&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I had the pleasure of attending <a href="http://bangbangcon.com/west/">!!con west</a> last weekend. I met a lot of incredible people and listened to talks that rekindled my joy in programming.</p>
<p>I took out my trusty <a href="https://www.stabilo.com/com/products/writing/fineliner-felt-tip-pens/stabilo-point-88/">Stabilo point 88</a> and started taking notes. The <a href="https://tifftseng.com/">person</a> sitting next to me complimented my choice of pen. I got very excited that someone recognized the pen and shared my interest in stationery. She then proceeded to show me her stationery collection from Japan (tiny scissors, a permanent marker, multicolor highlighter, and a twist top eraser). It was awesome! There is an indescribable joy in finding out that someone else shares your weird and quirky interests.</p>
<p>I got caught up with Thomas (author of <a href="https://curtsies.readthedocs.io/en/latest/">Curtsies</a> and a fellow lover of awesome CLIs). He gave me a demo of <a href="https://observablehq.com" title="Link: https://observablehq.com">ObservableHQ</a> which was very cool.</p>
<p>I met Aaron Wood who gave an engaging and entertaining talk about ancient Greek mathematics. I had a strange feeling that I knew him from somewhere else. Turns out he went to the University of Utah (my alma mater) and we both worked as math tutors in the same department nearly 13 years ago. What a small world.</p>
<p>There were a ton of interesting talks at the conference. Here&rsquo;s a synopsis of the ones I remember.</p>
<p><em><strong>Wolf, Goat, and Cabbage In Two Styles!!</strong></em></p>
<p>A brief showcase of two very different languages (!?) to solve the logic puzzle of transporting a Wolf, Goat, and Cabbage across a river.</p>
<p><em><strong>The Ancient Greeks And Their Restless Cattle</strong></em></p>
<p>A wonderfully hilarious talk about mathematics during the era of Archimedes and how it was solved with modern techniques before and after computers***.*** Aaron did a great job of explaining the math behind Pell&rsquo;s equation and walked us through the history of various attempts at a solution and finally showed an implementation of the solution in Ruby. I would highly recommend this talk.</p>
<p><em><strong>Plotty Bird - Making Modern Games on Retro Pen Plotters!</strong></em></p>
<p>Pen plotters are old school printers that literally used a robotic hand to draw diagrams on paper. Wesley managed to purchase one of them and hacked it to enough to start printing delightful things. They then proceeded to implement flappy bird that could be played by the pen plotter. They had brought with them a real pen plotter for us to play with and it was quite a bit of fun. There was one statement that Wesley made during the talk that resonated with me. We used to do programming because it was fun and pointless. Now that I&rsquo;m paid to write programs it doesn&rsquo;t seem fun anymore. We should go back to doing more programming for pointless fun.</p>
<p><em><strong>Packages, but in 3D!</strong></em></p>
<p>I had no idea that packaging for snacksis an art. There are books written about how to fold paper/cardboard to make a specific style of packaging. Tiffany wanted to try out some of the designs from these books. So she built an image to svg converter which then feeds the SVG to a packaging cutter (sort of like a laser cutter) to try out some of the packaging designs from the book. It is now a <a href="https://svg-tracer.glitch.me/">standalone program</a> on the web.</p>
<p>All in all, I had a wonderful time at the conference and I can&rsquo;t wait for the next one. :)</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Treat Others How You Want To Be Treated</title>
      <link>https://amjith.com/blog/treat-others-how-you-want-to-be-treated/</link>
      <pubDate>Wed, 19 Feb 2020 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/treat-others-how-you-want-to-be-treated/</guid>
      <description>&lt;p&gt;Vian (3yo) is in the bathtub and I&amp;rsquo;m trying to get him to come out. Sempi (7yo) is already out and changing his clothes. I am losing my patience with Vian and he is losing his patience with this toy that he&amp;rsquo;s trying balance on the rim of the bathtub.&lt;/p&gt;
&lt;p&gt;After pleading with him for a while, I lost my patience and stormed out and turned off one of the lights in the bathroom. Although this didn&amp;rsquo;t plunge the bathroom in darkness, this did darken the room just enough to cause Vian to yell and scream. Suddenly who comes running but Sempi. He asked in a compassionate tone &amp;ldquo;Vian are you ok? Is there anything I can do to help you?&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;Clearly ashamed by my actions, I went back to the bathroom and got Vian out of the bathtub. I told Sempi that I&amp;rsquo;m proud of his actions and I wish I could learn from him. Sempi said in a serious voice, I could teach you. Here&amp;rsquo;s his teaching:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Sometimes when things don&amp;rsquo;t go according to your plan, you&amp;rsquo;ll be tempted to do something bad to hurt the other person. But the way to control that is to remember that you should always treat others how you want to be treated.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;He said the best way to practice this is to go to someplace new that I&amp;rsquo;ve never been to. In a new place, things won&amp;rsquo;t go exactly as planned and I&amp;rsquo;ll find myself often frustrated or angry. That&amp;rsquo;s when I could practice being nice and not mean to everyone. He offered to go with me, so he can be there to support me.&lt;/p&gt;
&lt;p&gt;I am speechless. My son is awesome!&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian (3yo) is in the bathtub and I&rsquo;m trying to get him to come out. Sempi (7yo) is already out and changing his clothes. I am losing my patience with Vian and he is losing his patience with this toy that he&rsquo;s trying balance on the rim of the bathtub.</p>
<p>After pleading with him for a while, I lost my patience and stormed out and turned off one of the lights in the bathroom. Although this didn&rsquo;t plunge the bathroom in darkness, this did darken the room just enough to cause Vian to yell and scream. Suddenly who comes running but Sempi. He asked in a compassionate tone &ldquo;Vian are you ok? Is there anything I can do to help you?&rdquo;.</p>
<p>Clearly ashamed by my actions, I went back to the bathroom and got Vian out of the bathtub. I told Sempi that I&rsquo;m proud of his actions and I wish I could learn from him. Sempi said in a serious voice, I could teach you. Here&rsquo;s his teaching:</p>
<p><strong>Sometimes when things don&rsquo;t go according to your plan, you&rsquo;ll be tempted to do something bad to hurt the other person. But the way to control that is to remember that you should always treat others how you want to be treated.</strong></p>
<p>He said the best way to practice this is to go to someplace new that I&rsquo;ve never been to. In a new place, things won&rsquo;t go exactly as planned and I&rsquo;ll find myself often frustrated or angry. That&rsquo;s when I could practice being nice and not mean to everyone. He offered to go with me, so he can be there to support me.</p>
<p>I am speechless. My son is awesome!</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Elevenses</title>
      <link>https://amjith.com/blog/elevenses/</link>
      <pubDate>Sun, 02 Feb 2020 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/elevenses/</guid>
      <description>&lt;p&gt;One of my favorite items is sourdough toast with butter. This morning I decided to spread some jam on the toast as a treat. Vian enjoyed it quite a bit and came back for a second helping.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Vian:&lt;/strong&gt; Appa can you make me a loaf of jam?&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me:&lt;/strong&gt; You mean a slice, not a loaf.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Vian:&lt;/strong&gt; Oh, can I have a slice of jam?&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me:&lt;/strong&gt; Yes! Btw, it&amp;rsquo;s a slice of bread with jam.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Vian:&lt;/strong&gt; ﻿Ok. (licking his finger distractedly).&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>One of my favorite items is sourdough toast with butter. This morning I decided to spread some jam on the toast as a treat. Vian enjoyed it quite a bit and came back for a second helping.</p>
<p><strong>Vian:</strong> Appa can you make me a loaf of jam?</p>
<p><strong>Me:</strong> You mean a slice, not a loaf.</p>
<p><strong>Vian:</strong> Oh, can I have a slice of jam?</p>
<p><strong>Me:</strong> Yes! Btw, it&rsquo;s a slice of bread with jam.</p>
<p><strong>Vian:</strong> ﻿Ok. (licking his finger distractedly).</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Creative Insult</title>
      <link>https://amjith.com/blog/creative-insult/</link>
      <pubDate>Fri, 13 Dec 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/creative-insult/</guid>
      <description>&lt;p&gt;Imagine a chubby 3 yr old with stubby legs and a cute smile. That&amp;rsquo;s Vian. Vian can be a charming little kid when he chooses.&lt;/p&gt;
&lt;p&gt;This morning I was helping him use the restroom. After he washed his hands I offered him a towel to dry himself. He refused the offer and decides to wipe his hands on his shirt. I told him with a hint of frustration that he should use a towel and not wipe his hands on his shirt. He turns around, looks me in the eye and says:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&amp;ldquo;No I won&amp;rsquo;t, you fuzzy little mammal&amp;rdquo;&lt;/strong&gt; and walks away while I stand there dumbfounded.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m lucky to say that I was present when a new insult was birthed into this world.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Imagine a chubby 3 yr old with stubby legs and a cute smile. That&rsquo;s Vian. Vian can be a charming little kid when he chooses.</p>
<p>This morning I was helping him use the restroom. After he washed his hands I offered him a towel to dry himself. He refused the offer and decides to wipe his hands on his shirt. I told him with a hint of frustration that he should use a towel and not wipe his hands on his shirt. He turns around, looks me in the eye and says:</p>
<p><strong>&ldquo;No I won&rsquo;t, you fuzzy little mammal&rdquo;</strong> and walks away while I stand there dumbfounded.</p>
<p>I&rsquo;m lucky to say that I was present when a new insult was birthed into this world.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Kids vs Adults</title>
      <link>https://amjith.com/blog/kids-vs-adults/</link>
      <pubDate>Sun, 01 Dec 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/kids-vs-adults/</guid>
      <description>&lt;p&gt;It is raining in San Jose, there are little puddles of water on the sidewalk.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m walking with Vian in our neighborhood. I notice a small puddle and step over it to make sure I don&amp;rsquo;t get my shoes wet. &lt;/p&gt;
&lt;p&gt;Vian walks right through the puddle. Stops. Turns around and jumps in the puddle for good measure and then runs over to hold my fingers as we proceed with our walk.&lt;/p&gt;
&lt;p&gt;Wet shoes are a small price to pay for the joy of jumping in puddles. It is wonderful being a kid.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>It is raining in San Jose, there are little puddles of water on the sidewalk.</p>
<p>I&rsquo;m walking with Vian in our neighborhood. I notice a small puddle and step over it to make sure I don&rsquo;t get my shoes wet. </p>
<p>Vian walks right through the puddle. Stops. Turns around and jumps in the puddle for good measure and then runs over to hold my fingers as we proceed with our walk.</p>
<p>Wet shoes are a small price to pay for the joy of jumping in puddles. It is wonderful being a kid.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>The Floss!</title>
      <link>https://amjith.com/blog/the-floss/</link>
      <pubDate>Fri, 11 Oct 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/the-floss/</guid>
      <description>&lt;p&gt;Dancing is in my &lt;a href=&#34;https://amjith.com/blog/dancing-with-the-dorks&#34; title=&#34;Link: https://amjith.com/blog/dancing-with-the-dorks&#34;&gt;blood&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Yoshi decides that the kids need to learn how to dance properly(?). So she starts teaching them &amp;ldquo;&lt;a href=&#34;https://www.wikihow.com/Do-the-Floss-Dance&#34;&gt;The Floss&lt;/a&gt;&amp;rdquo;. Not to be outdone by her, I decide to show the kids how to do the Floss correctly.&lt;/p&gt;
&lt;p&gt;As I start to get into the groove, Vian runs over and turns the light off, just as Yoshi remarks &amp;ldquo;Yeah, nobody needs to see that&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;Tough crowd!&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Dancing is in my <a href="https://amjith.com/blog/dancing-with-the-dorks" title="Link: https://amjith.com/blog/dancing-with-the-dorks">blood</a>.</p>
<p>Yoshi decides that the kids need to learn how to dance properly(?). So she starts teaching them &ldquo;<a href="https://www.wikihow.com/Do-the-Floss-Dance">The Floss</a>&rdquo;. Not to be outdone by her, I decide to show the kids how to do the Floss correctly.</p>
<p>As I start to get into the groove, Vian runs over and turns the light off, just as Yoshi remarks &ldquo;Yeah, nobody needs to see that&rdquo;.</p>
<p>Tough crowd!</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Examples are Awesome</title>
      <link>https://amjith.com/blog/examples-are-awesome/</link>
      <pubDate>Sun, 06 Oct 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/examples-are-awesome/</guid>
      <description>&lt;p&gt;There are two things I look for whenever I check out an Opensource project or library that I want to use.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Screenshots (A picture is worth a thousand words).&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Examples (Don&amp;rsquo;t tell me what to do, show me how to do it).&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Having a fully working example (or many examples) helps me shape my thought process.&lt;/p&gt;
&lt;p&gt;Here are a few projects that are excellent examples of this.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&#34;https://github.com/prompt-toolkit/python-prompt-toolkit&#34; title=&#34;Link: https://github.com/prompt-toolkit/python-prompt-toolkit&#34;&gt;https://github.com/prompt-toolkit/python-prompt-toolkit&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;A CLI framework for building rich command line interfaces. The project comes with a collection of small self-sufficient examples that showcase every feature available in the framework and a nice little tutorial.&lt;/p&gt;
&lt;ol start=&#34;2&#34;&gt;
&lt;li&gt;&lt;a href=&#34;https://github.com/coleifer/peewee&#34; title=&#34;Link: https://github.com/coleifer/peewee&#34;&gt;https://github.com/coleifer/peewee&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;A small ORM for Python that ships with multiple web projects to showcase how to use the ORM effectively. I&amp;rsquo;m always overwhelmed by SqlAlchemy&amp;rsquo;s documentation site. PeeWee is a breath of fresh air with a clear purpose and succinct documentation.&lt;/p&gt;
&lt;ol start=&#34;3&#34;&gt;
&lt;li&gt;&lt;a href=&#34;https://github.com/coleifer/huey&#34;&gt;https://github.com/coleifer/huey&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;An asynchronous task queue for Python that is simpler than Celery and more featureful than RQ. This project also ships with an awesome set of examples that show how to integrate the task queue with Django, Flask or standalone use case.&lt;/p&gt;
&lt;p&gt;The beauty of these examples is that they&amp;rsquo;re self-documenting and show us how the different pieces in the library work with each other as well as external code outside of their library such as Flask, Django, Asyncio etc.&lt;/p&gt;
&lt;p&gt;Examples save the users hours of sifting through documentation to piece together how to use a library.&lt;/p&gt;
&lt;p&gt;Please include examples in your project.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>There are two things I look for whenever I check out an Opensource project or library that I want to use.</p>
<ol>
<li>
<p>Screenshots (A picture is worth a thousand words).</p>
</li>
<li>
<p>Examples (Don&rsquo;t tell me what to do, show me how to do it).</p>
</li>
</ol>
<p>Having a fully working example (or many examples) helps me shape my thought process.</p>
<p>Here are a few projects that are excellent examples of this.</p>
<ol>
<li><a href="https://github.com/prompt-toolkit/python-prompt-toolkit" title="Link: https://github.com/prompt-toolkit/python-prompt-toolkit">https://github.com/prompt-toolkit/python-prompt-toolkit</a></li>
</ol>
<p>A CLI framework for building rich command line interfaces. The project comes with a collection of small self-sufficient examples that showcase every feature available in the framework and a nice little tutorial.</p>
<ol start="2">
<li><a href="https://github.com/coleifer/peewee" title="Link: https://github.com/coleifer/peewee">https://github.com/coleifer/peewee</a></li>
</ol>
<p>A small ORM for Python that ships with multiple web projects to showcase how to use the ORM effectively. I&rsquo;m always overwhelmed by SqlAlchemy&rsquo;s documentation site. PeeWee is a breath of fresh air with a clear purpose and succinct documentation.</p>
<ol start="3">
<li><a href="https://github.com/coleifer/huey">https://github.com/coleifer/huey</a></li>
</ol>
<p>An asynchronous task queue for Python that is simpler than Celery and more featureful than RQ. This project also ships with an awesome set of examples that show how to integrate the task queue with Django, Flask or standalone use case.</p>
<p>The beauty of these examples is that they&rsquo;re self-documenting and show us how the different pieces in the library work with each other as well as external code outside of their library such as Flask, Django, Asyncio etc.</p>
<p>Examples save the users hours of sifting through documentation to piece together how to use a library.</p>
<p>Please include examples in your project.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Tattling</title>
      <link>https://amjith.com/blog/tattling/</link>
      <pubDate>Sun, 29 Sep 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/tattling/</guid>
      <description>&lt;p&gt;Vian: Amma, the roomba is not cleaning anything.&lt;/p&gt;
&lt;p&gt;Yoshi: Let me check.&lt;/p&gt;
&lt;p&gt;She finds lego pieces and strings blocking the Roomba wheels.&lt;/p&gt;
&lt;p&gt;Yoshi: Thank you, Vian. You&amp;rsquo;re right it wasn&amp;rsquo;t picking up anything.&lt;/p&gt;
&lt;p&gt;Me: Vian, did you just tattle on Roomba to your mother?&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian: Amma, the roomba is not cleaning anything.</p>
<p>Yoshi: Let me check.</p>
<p>She finds lego pieces and strings blocking the Roomba wheels.</p>
<p>Yoshi: Thank you, Vian. You&rsquo;re right it wasn&rsquo;t picking up anything.</p>
<p>Me: Vian, did you just tattle on Roomba to your mother?</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Monkey Bar</title>
      <link>https://amjith.com/blog/monkey-bar/</link>
      <pubDate>Fri, 06 Sep 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/monkey-bar/</guid>
      <description>&lt;p&gt;Sempi is a big fan of Leonardo Da Vinci. Ever since we got back from Italy he&amp;rsquo;s been talking about the various inventions of Leonardo.&lt;/p&gt;
&lt;p&gt;Earlier today he was playing in the park after school. Apparently, he fell down from the monkey bars trying to do something brave. Yoshi took him to the ER and the doctors announced he has a small fracture and put his arm in a sling.&lt;/p&gt;
&lt;p&gt;He&amp;rsquo;s quite despondent about the whole ordeal and told me that he wished he hadn&amp;rsquo;t tried that special monkey bar maneuver. I reassured him that his sling is a badge of honor, it is a sign of bravery, it shows that he is someone who pushes the boundaries.&lt;/p&gt;
&lt;p&gt;Me: Do you know who else is the kind of person who pushed boundaries?&lt;/p&gt;
&lt;p&gt;Sempi: Who?&lt;/p&gt;
&lt;p&gt;Me: Leonardo. I bet he wore a sling many times in his life.&lt;/p&gt;
&lt;p&gt;Sempi: Yeah. But he probably knew how to use a monkey bar though.&lt;/p&gt;
&lt;p&gt;Me: LOL!!&lt;/p&gt;
&lt;p&gt;I have to agree with him on that one.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi is a big fan of Leonardo Da Vinci. Ever since we got back from Italy he&rsquo;s been talking about the various inventions of Leonardo.</p>
<p>Earlier today he was playing in the park after school. Apparently, he fell down from the monkey bars trying to do something brave. Yoshi took him to the ER and the doctors announced he has a small fracture and put his arm in a sling.</p>
<p>He&rsquo;s quite despondent about the whole ordeal and told me that he wished he hadn&rsquo;t tried that special monkey bar maneuver. I reassured him that his sling is a badge of honor, it is a sign of bravery, it shows that he is someone who pushes the boundaries.</p>
<p>Me: Do you know who else is the kind of person who pushed boundaries?</p>
<p>Sempi: Who?</p>
<p>Me: Leonardo. I bet he wore a sling many times in his life.</p>
<p>Sempi: Yeah. But he probably knew how to use a monkey bar though.</p>
<p>Me: LOL!!</p>
<p>I have to agree with him on that one.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Captain Underpants - Potty Adventures - 2</title>
      <link>https://amjith.com/blog/captain-underpants-potty-adventures-2/</link>
      <pubDate>Tue, 13 Aug 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/captain-underpants-potty-adventures-2/</guid>
      <description>&lt;p&gt;When we were in Italy, we visited the Ufizzi museum and saw a lot of old world statues. There was one statue of a warrior holding a shield in his hand. I told the kids that it is Captain Italy who happens to be the cousin of Captain America. Obviously, neither of them believed me and Sempi groaned at my lame joke.&lt;/p&gt;
&lt;p&gt;Recently Vian started &lt;a href=&#34;https://amjith.com/blog/potty-training-adventures-i&#34;&gt;potty training&lt;/a&gt;. He&amp;rsquo;s proud of wearing his underwear and strikes a pose every now and then.&lt;/p&gt;
&lt;p&gt;Me: Vian you look like Captain Underpants.&lt;/p&gt;
&lt;p&gt;Vian: No Appa. I&amp;rsquo;m like Captain Italy, remember.&lt;/p&gt;
&lt;p&gt;Me: Haha. Was Captain Italy wearing underpants?&lt;/p&gt;
&lt;p&gt;Vian: No Appa. Captain Italy was wearing his penis.&lt;/p&gt;
&lt;p&gt;Of course, I forgot that the statue was naked. All the statues were naked.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>When we were in Italy, we visited the Ufizzi museum and saw a lot of old world statues. There was one statue of a warrior holding a shield in his hand. I told the kids that it is Captain Italy who happens to be the cousin of Captain America. Obviously, neither of them believed me and Sempi groaned at my lame joke.</p>
<p>Recently Vian started <a href="https://amjith.com/blog/potty-training-adventures-i">potty training</a>. He&rsquo;s proud of wearing his underwear and strikes a pose every now and then.</p>
<p>Me: Vian you look like Captain Underpants.</p>
<p>Vian: No Appa. I&rsquo;m like Captain Italy, remember.</p>
<p>Me: Haha. Was Captain Italy wearing underpants?</p>
<p>Vian: No Appa. Captain Italy was wearing his penis.</p>
<p>Of course, I forgot that the statue was naked. All the statues were naked.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Sorry!?</title>
      <link>https://amjith.com/blog/sorry/</link>
      <pubDate>Sun, 04 Aug 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/sorry/</guid>
      <description>&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/2307501/z5dhjLrybwFBTRn0DW1hUQzyBG8/large_index.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Vian and I are playing legos. I accidentally drop a lego piece from the table, we both bend down to get it and bonk our heads.&lt;/p&gt;
&lt;p&gt;Me: I am sorry, Vian.Vian: (rubbing his head) No appa, I am sorry.&lt;/p&gt;
&lt;p&gt;Me: I guess we&amp;rsquo;re both sorry. :)Vian: No appa. I AM SAD, SO I AM SORRY (loudly).&lt;/p&gt;
&lt;p&gt;Me: Ok. Ok you&amp;rsquo;re sorry.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/2307501/z5dhjLrybwFBTRn0DW1hUQzyBG8/large_index.jpg" alt=""  />
</p>
<p>Vian and I are playing legos. I accidentally drop a lego piece from the table, we both bend down to get it and bonk our heads.</p>
<p>Me: I am sorry, Vian.Vian: (rubbing his head) No appa, I am sorry.</p>
<p>Me: I guess we&rsquo;re both sorry. :)Vian: No appa. I AM SAD, SO I AM SORRY (loudly).</p>
<p>Me: Ok. Ok you&rsquo;re sorry.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Potty Training Adventures - I</title>
      <link>https://amjith.com/blog/potty-training-adventures-i/</link>
      <pubDate>Fri, 02 Aug 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/potty-training-adventures-i/</guid>
      <description>&lt;p&gt;Vian is 3 years old which is the minimum age required in this family to be eligible for big boy underwear. So naturally, we started potty training him this week.&lt;/p&gt;
&lt;p&gt;He&amp;rsquo;s come a long way since Monday and it is going very well. He does get frustrated by the inconvenience of having to stop playing just to empty his bladder. This morning he declared &lt;strong&gt;&amp;ldquo;I need to wear diapers or else I&amp;rsquo;m not going to eat&lt;/strong&gt; &lt;strong&gt;anymore&lt;/strong&gt;**!&amp;rdquo;.**&lt;/p&gt;
&lt;p&gt;A hunger strike! I guess reading all those books about &lt;a href=&#34;https://amjith.com/blog/relatives&#34; title=&#34;Link: https://amjith.com/blog/relatives&#34;&gt;Gandhi&lt;/a&gt; is having an effect on him. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian is 3 years old which is the minimum age required in this family to be eligible for big boy underwear. So naturally, we started potty training him this week.</p>
<p>He&rsquo;s come a long way since Monday and it is going very well. He does get frustrated by the inconvenience of having to stop playing just to empty his bladder. This morning he declared <strong>&ldquo;I need to wear diapers or else I&rsquo;m not going to eat</strong> <strong>anymore</strong>**!&rdquo;.**</p>
<p>A hunger strike! I guess reading all those books about <a href="https://amjith.com/blog/relatives" title="Link: https://amjith.com/blog/relatives">Gandhi</a> is having an effect on him. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 2 yo</title>
      <link>https://amjith.com/blog/conversations-with-a-2-yo-1/</link>
      <pubDate>Sun, 28 Apr 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-2-yo-1/</guid>
      <description>&lt;p&gt;We are at the dining table. I take out the croissant from the bag and place it on a plate in front of Vian.&lt;/p&gt;
&lt;p&gt;Vian: Appa, what kind of &amp;ldquo;cossant&amp;rdquo; is it?&lt;/p&gt;
&lt;p&gt;Me: It&amp;rsquo;s a plain croissant, Vian.&lt;/p&gt;
&lt;p&gt;Vian: No. It&amp;rsquo;s a bum-bum &amp;ldquo;cossant&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;Me: Huh?&lt;/p&gt;
&lt;p&gt;Vian: Look it (pointing to his misshapen croissant that looks like a butt).&lt;/p&gt;
&lt;p&gt;You win this round, Vian.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We are at the dining table. I take out the croissant from the bag and place it on a plate in front of Vian.</p>
<p>Vian: Appa, what kind of &ldquo;cossant&rdquo; is it?</p>
<p>Me: It&rsquo;s a plain croissant, Vian.</p>
<p>Vian: No. It&rsquo;s a bum-bum &ldquo;cossant&rdquo;.</p>
<p>Me: Huh?</p>
<p>Vian: Look it (pointing to his misshapen croissant that looks like a butt).</p>
<p>You win this round, Vian.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Punch Line</title>
      <link>https://amjith.com/blog/punch-line/</link>
      <pubDate>Sun, 28 Apr 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/punch-line/</guid>
      <description>&lt;p&gt;I sometimes share clean adult jokes that are too clever for a 2 year old to grasp. Sometimes it is fun to see the confused look on his face when he sees me cracking up on my own jokes. Yes, I laugh at my own jokes, moving on.&lt;/p&gt;
&lt;p&gt;We&amp;rsquo;re hanging out at a coffee shop and I start with the setup for a great joke.&lt;/p&gt;
&lt;p&gt;Me: Vian, did you know that humans eat more bananas than monkeys?&lt;/p&gt;
&lt;p&gt;Vian: What? They eat monkeys?&lt;/p&gt;
&lt;p&gt;Me: LOL!! Way to ruin the punchline man.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I sometimes share clean adult jokes that are too clever for a 2 year old to grasp. Sometimes it is fun to see the confused look on his face when he sees me cracking up on my own jokes. Yes, I laugh at my own jokes, moving on.</p>
<p>We&rsquo;re hanging out at a coffee shop and I start with the setup for a great joke.</p>
<p>Me: Vian, did you know that humans eat more bananas than monkeys?</p>
<p>Vian: What? They eat monkeys?</p>
<p>Me: LOL!! Way to ruin the punchline man.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Good people</title>
      <link>https://amjith.com/blog/good-people/</link>
      <pubDate>Thu, 21 Mar 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/good-people/</guid>
      <description>&lt;p&gt;Sempi and I read bedtime books together and discuss the story before he goes to sleep.&lt;/p&gt;
&lt;p&gt;The story we read had a mention of illegal drugs. Apparently he didn&amp;rsquo;t know what drugs were. So we discussed what drugs were and how some bad guys can sell drugs to victims and why it is illegal.&lt;/p&gt;
&lt;p&gt;Suddenly Sempi drops this nugget of wisdom.&lt;/p&gt;
&lt;p&gt;People are always born to be strong and good. No one is born to be weak or evil.&lt;/p&gt;
&lt;p&gt;Friends who know me well, know that I strongly believe &amp;ldquo;people are generally good&amp;rdquo;. I guess that belief is a genetic trait.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi and I read bedtime books together and discuss the story before he goes to sleep.</p>
<p>The story we read had a mention of illegal drugs. Apparently he didn&rsquo;t know what drugs were. So we discussed what drugs were and how some bad guys can sell drugs to victims and why it is illegal.</p>
<p>Suddenly Sempi drops this nugget of wisdom.</p>
<p>People are always born to be strong and good. No one is born to be weak or evil.</p>
<p>Friends who know me well, know that I strongly believe &ldquo;people are generally good&rdquo;. I guess that belief is a genetic trait.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Got Problems?</title>
      <link>https://amjith.com/blog/got-problems/</link>
      <pubDate>Thu, 21 Feb 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/got-problems/</guid>
      <description>&lt;p&gt;Sempi (my 6yo son) and I have this tradition of sharing our problems and asking each other&amp;rsquo;s opinion on how to solve it. We do this while we walk to his school. We&amp;rsquo;ve been doing this since he was 3. Here&amp;rsquo;s an example from Portland.&lt;/p&gt;
&lt;p&gt;Me: When I bike to work, I have to wait a long time for the elevator.&lt;/p&gt;
&lt;p&gt;Sempi (3yo): You should just build a ramp to your 28th floor, so you can just bike all the way up.&lt;/p&gt;
&lt;p&gt;Me: Alrighty then.&lt;/p&gt;
&lt;p&gt;Back to present day, I was discussing a problem with him about my work.&lt;/p&gt;
&lt;p&gt;Me: I have this big presentation coming up and I&amp;rsquo;m nervous.&lt;/p&gt;
&lt;p&gt;Sempi: Why?&lt;/p&gt;
&lt;p&gt;Me: There&amp;rsquo;s going to be VPs and an Executive attending this presentation. So I&amp;rsquo;m anxious about it.&lt;/p&gt;
&lt;p&gt;(Sempi thinks for a while)&lt;/p&gt;
&lt;p&gt;Sempi: There is a fire pole at the playground and I get nervous about going down that pole. What helps me is, I don&amp;rsquo;t think about it, I just do it. So you should do the same. Don&amp;rsquo;t think about it, just do it.&lt;/p&gt;
&lt;p&gt;Me: Whoa! You know that&amp;rsquo;s actually pretty good advice.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m happy to report that I took his advice and I kicked butt.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi (my 6yo son) and I have this tradition of sharing our problems and asking each other&rsquo;s opinion on how to solve it. We do this while we walk to his school. We&rsquo;ve been doing this since he was 3. Here&rsquo;s an example from Portland.</p>
<p>Me: When I bike to work, I have to wait a long time for the elevator.</p>
<p>Sempi (3yo): You should just build a ramp to your 28th floor, so you can just bike all the way up.</p>
<p>Me: Alrighty then.</p>
<p>Back to present day, I was discussing a problem with him about my work.</p>
<p>Me: I have this big presentation coming up and I&rsquo;m nervous.</p>
<p>Sempi: Why?</p>
<p>Me: There&rsquo;s going to be VPs and an Executive attending this presentation. So I&rsquo;m anxious about it.</p>
<p>(Sempi thinks for a while)</p>
<p>Sempi: There is a fire pole at the playground and I get nervous about going down that pole. What helps me is, I don&rsquo;t think about it, I just do it. So you should do the same. Don&rsquo;t think about it, just do it.</p>
<p>Me: Whoa! You know that&rsquo;s actually pretty good advice.</p>
<p>I&rsquo;m happy to report that I took his advice and I kicked butt.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Relatives</title>
      <link>https://amjith.com/blog/relatives/</link>
      <pubDate>Sun, 10 Feb 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/relatives/</guid>
      <description>&lt;p&gt;Some nights I read a book about Gandhi to Sempi for bedtime. There is an incident in Gandhi&amp;rsquo;s life when he&amp;rsquo;s thrown out of a first-class coach in South Africa because he is not white. I told Sempi that it was an injustice and it doesn&amp;rsquo;t happen anymore.  He listened intently and nodded approvingly. The next night I&amp;rsquo;m reading a comic about superheros and he asks me, &amp;ldquo;How come everyone in Justice League is white?&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;I stuttered to come up with an answer at that moment, cursing myself for introducing him to the concept of race.&lt;/p&gt;
&lt;p&gt;Since then he&amp;rsquo;s asked me to read the Gandhi book many times and we talk about the struggles, non-violence and civil disobedience.&lt;/p&gt;
&lt;p&gt;Recently, his elementary school teacher did a fantastic job of introducing the struggles of Martin Luther King Jr. He was excited to learn about MLK and how he learned some of the techniques from Gandhi and Thoreau. So naturally, we bought a new bedtime book about MLK.&lt;/p&gt;
&lt;p&gt;One night we had this exchange.&lt;/p&gt;
&lt;p&gt;Sempi: Appa, how did the first person came into existence.&lt;/p&gt;
&lt;p&gt;Me: (I was gearing up to talk about evolution, Adam and Genesis).&lt;/p&gt;
&lt;p&gt;Sempi: Appa, if there was a single person in the beginning, then we all came from that person.&lt;/p&gt;
&lt;p&gt;Me: (excitedly) That&amp;rsquo;s true. Everyone in the world is related. You&amp;rsquo;re probably related to Ms. Cochran (his elementary shcool teacher).&lt;/p&gt;
&lt;p&gt;Sempi: (giggles) Hehe. It also means that Martin Luther King could be my relative. Hehe.&lt;/p&gt;
&lt;p&gt;Me: Absolutely!! You know MLK and Gandhi were probably your great great grandfathers.&lt;/p&gt;
&lt;p&gt;That&amp;rsquo;s my son. :D&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Some nights I read a book about Gandhi to Sempi for bedtime. There is an incident in Gandhi&rsquo;s life when he&rsquo;s thrown out of a first-class coach in South Africa because he is not white. I told Sempi that it was an injustice and it doesn&rsquo;t happen anymore.  He listened intently and nodded approvingly. The next night I&rsquo;m reading a comic about superheros and he asks me, &ldquo;How come everyone in Justice League is white?&rdquo;.</p>
<p>I stuttered to come up with an answer at that moment, cursing myself for introducing him to the concept of race.</p>
<p>Since then he&rsquo;s asked me to read the Gandhi book many times and we talk about the struggles, non-violence and civil disobedience.</p>
<p>Recently, his elementary school teacher did a fantastic job of introducing the struggles of Martin Luther King Jr. He was excited to learn about MLK and how he learned some of the techniques from Gandhi and Thoreau. So naturally, we bought a new bedtime book about MLK.</p>
<p>One night we had this exchange.</p>
<p>Sempi: Appa, how did the first person came into existence.</p>
<p>Me: (I was gearing up to talk about evolution, Adam and Genesis).</p>
<p>Sempi: Appa, if there was a single person in the beginning, then we all came from that person.</p>
<p>Me: (excitedly) That&rsquo;s true. Everyone in the world is related. You&rsquo;re probably related to Ms. Cochran (his elementary shcool teacher).</p>
<p>Sempi: (giggles) Hehe. It also means that Martin Luther King could be my relative. Hehe.</p>
<p>Me: Absolutely!! You know MLK and Gandhi were probably your great great grandfathers.</p>
<p>That&rsquo;s my son. :D</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Manners my boy, manners</title>
      <link>https://amjith.com/blog/manners-my-boy-manners/</link>
      <pubDate>Sun, 03 Feb 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/manners-my-boy-manners/</guid>
      <description>&lt;p&gt;This happened a few weeks ago. The kids are having a funtime playing with their mom. I enter the room, which usually sets off the anxiety for Vian.&lt;/p&gt;
&lt;p&gt;Vian: &lt;a href=&#34;https://amjith.com/blog/answer-me&#34;&gt;I don&amp;rsquo;t need you&lt;/a&gt;, appa.&lt;/p&gt;
&lt;p&gt;Yoshi: That&amp;rsquo;s not very nice.&lt;/p&gt;
&lt;p&gt;Vian: Go away, appa.&lt;/p&gt;
&lt;p&gt;Yoshi: Can you say something nice to appa?&lt;/p&gt;
&lt;p&gt;Vian: Appa, can you pleeease go away?&lt;/p&gt;
&lt;p&gt;Me: Thank you! That&amp;rsquo;s much better. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>This happened a few weeks ago. The kids are having a funtime playing with their mom. I enter the room, which usually sets off the anxiety for Vian.</p>
<p>Vian: <a href="https://amjith.com/blog/answer-me">I don&rsquo;t need you</a>, appa.</p>
<p>Yoshi: That&rsquo;s not very nice.</p>
<p>Vian: Go away, appa.</p>
<p>Yoshi: Can you say something nice to appa?</p>
<p>Vian: Appa, can you pleeease go away?</p>
<p>Me: Thank you! That&rsquo;s much better. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>What do you say?</title>
      <link>https://amjith.com/blog/what-do-you-say/</link>
      <pubDate>Tue, 01 Jan 2019 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/what-do-you-say/</guid>
      <description>&lt;p&gt;One of the ways we trained Sempi to say &amp;ldquo;Please&amp;rdquo; and &amp;ldquo;Thank you&amp;rdquo; is by asking him &amp;ldquo;What do you say?&amp;rdquo; after he receives a favor from someone. With that context in mind, this conversation happened in the car. &lt;/p&gt;
&lt;p&gt;Vian: Can I have that monster truck, Sempi?&lt;/p&gt;
&lt;p&gt;Sempi: Here you go. &lt;/p&gt;
&lt;p&gt;Vian takes the truck. Sempi being the responsible older brother wants to teach Vian good manners. &lt;/p&gt;
&lt;p&gt;Sempi: What do you say, Vian? &lt;/p&gt;
&lt;p&gt;Vian: Vrooom, Vrooom.&lt;/p&gt;
&lt;p&gt;Sempi just shakes his head and mumbles something that vaguely sounds like &amp;ldquo;Kids these days&amp;rdquo;. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>One of the ways we trained Sempi to say &ldquo;Please&rdquo; and &ldquo;Thank you&rdquo; is by asking him &ldquo;What do you say?&rdquo; after he receives a favor from someone. With that context in mind, this conversation happened in the car. </p>
<p>Vian: Can I have that monster truck, Sempi?</p>
<p>Sempi: Here you go. </p>
<p>Vian takes the truck. Sempi being the responsible older brother wants to teach Vian good manners. </p>
<p>Sempi: What do you say, Vian? </p>
<p>Vian: Vrooom, Vrooom.</p>
<p>Sempi just shakes his head and mumbles something that vaguely sounds like &ldquo;Kids these days&rdquo;. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>My Cup Runneth Over</title>
      <link>https://amjith.com/blog/my-cup-runneth-over/</link>
      <pubDate>Sun, 16 Dec 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/my-cup-runneth-over/</guid>
      <description>&lt;p&gt;Vian is having lunch. I&amp;rsquo;m still making a plate for myself. He requests some water, so brought him a cup of water.&lt;/p&gt;
&lt;p&gt;Vian: Appa, this is too watery. &lt;/p&gt;
&lt;p&gt;Me: I&amp;rsquo;m glad to hear that Vian. The water is supposed to be watery. &lt;/p&gt;
&lt;p&gt;Vian: No appa, I can&amp;rsquo;t drink it.&lt;/p&gt;
&lt;p&gt;Me: Why not?&lt;/p&gt;
&lt;p&gt;Vian: Because it is too watery. &lt;/p&gt;
&lt;p&gt;I walked over to him to check it out. He was complaining because I filled the water to the brim and he couldn&amp;rsquo;t drink out of it.&lt;/p&gt;
&lt;p&gt;Me: I&amp;rsquo;m sorry Vian, I will fill it appropriately next time. &lt;/p&gt;
&lt;p&gt;Vian: Yeah appa, next time don&amp;rsquo;t make it too watery.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian is having lunch. I&rsquo;m still making a plate for myself. He requests some water, so brought him a cup of water.</p>
<p>Vian: Appa, this is too watery. </p>
<p>Me: I&rsquo;m glad to hear that Vian. The water is supposed to be watery. </p>
<p>Vian: No appa, I can&rsquo;t drink it.</p>
<p>Me: Why not?</p>
<p>Vian: Because it is too watery. </p>
<p>I walked over to him to check it out. He was complaining because I filled the water to the brim and he couldn&rsquo;t drink out of it.</p>
<p>Me: I&rsquo;m sorry Vian, I will fill it appropriately next time. </p>
<p>Vian: Yeah appa, next time don&rsquo;t make it too watery.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Mom by any other name</title>
      <link>https://amjith.com/blog/mom-by-any-other-name/</link>
      <pubDate>Sun, 09 Dec 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/mom-by-any-other-name/</guid>
      <description>&lt;p&gt;It was a cold Sunday morning. Sempi doesn&amp;rsquo;t want to leave the house. I&amp;rsquo;m trying to convince him to go out for family brunch. Yoshi is still getting ready.&lt;/p&gt;
&lt;p&gt;Sempi: I don&amp;rsquo;t want to go. I want to stay home and play legos.&lt;/p&gt;
&lt;p&gt;Me: If you want to stay home, that&amp;rsquo;s fine. I&amp;rsquo;m going out for brunch.&lt;/p&gt;
&lt;p&gt;Sempi: Ok.&lt;/p&gt;
&lt;p&gt;Me: I&amp;rsquo;m taking Vian with me.&lt;/p&gt;
&lt;p&gt;Sempi: Ok, you can take Vian and I&amp;rsquo;ll stay with Amma.&lt;/p&gt;
&lt;p&gt;Me: Nope, I&amp;rsquo;m taking my wife with me. &lt;/p&gt;
&lt;p&gt;Sempi: Ugh! Appaaaa &amp;hellip;&amp;hellip; Fine. We&amp;rsquo;ll all go.&lt;/p&gt;
&lt;p&gt;Me: Alright, hurry up and put on your shoes. &lt;/p&gt;
&lt;p&gt;Sempi: Hold on, let&amp;rsquo;s wait for our wife.&lt;/p&gt;
&lt;p&gt;Me: Hey! She&amp;rsquo;s my wife, not our wife.&lt;/p&gt;
&lt;p&gt;Sempi: Apppaaaa&amp;hellip;&amp;hellip;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>It was a cold Sunday morning. Sempi doesn&rsquo;t want to leave the house. I&rsquo;m trying to convince him to go out for family brunch. Yoshi is still getting ready.</p>
<p>Sempi: I don&rsquo;t want to go. I want to stay home and play legos.</p>
<p>Me: If you want to stay home, that&rsquo;s fine. I&rsquo;m going out for brunch.</p>
<p>Sempi: Ok.</p>
<p>Me: I&rsquo;m taking Vian with me.</p>
<p>Sempi: Ok, you can take Vian and I&rsquo;ll stay with Amma.</p>
<p>Me: Nope, I&rsquo;m taking my wife with me. </p>
<p>Sempi: Ugh! Appaaaa &hellip;&hellip; Fine. We&rsquo;ll all go.</p>
<p>Me: Alright, hurry up and put on your shoes. </p>
<p>Sempi: Hold on, let&rsquo;s wait for our wife.</p>
<p>Me: Hey! She&rsquo;s my wife, not our wife.</p>
<p>Sempi: Apppaaaa&hellip;&hellip;</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Answer Me!</title>
      <link>https://amjith.com/blog/answer-me/</link>
      <pubDate>Mon, 26 Nov 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/answer-me/</guid>
      <description>&lt;p&gt;It is no secret that both Sempi and Vian prefer their mom over me. Vian perceives me as the guy who lives in the same house and occasionally grabs him from his mom to change his diaper. &lt;/p&gt;
&lt;p&gt;If I happen to enter a room in which he is playing, he will preemptively declare &amp;ldquo;I don&amp;rsquo;t need you, appa&amp;rdquo;. Which is a wonderfully  heartwarming phrase to hear from your child. &lt;/p&gt;
&lt;p&gt;A couple of days ago, the entire family was in the living room. Yoshi was playing with the kids, I was working on my laptop. Yoshi stood up to leave the room, and Vian starts to get anxious. Yoshi reassures him that she&amp;rsquo;ll be right back. I wasn&amp;rsquo;t paying much attention to the surroundings as I was focused on my laptop. &lt;/p&gt;
&lt;p&gt;Vian says something to me. I half-heartedly acknowledge. Suddenly he yells at me, &amp;ldquo;APPA! Are you going to answer me?&amp;rdquo;. I immediately sit straight, set aside my laptop and focus all of my attention to him. &amp;ldquo;I&amp;rsquo;m sorry, Vian. What were you saying, baby?&amp;rdquo;. Vian replies &amp;ldquo;I was saying that I don&amp;rsquo;t need you&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;Very well then, I&amp;rsquo;m glad you got my undivided attention to share that, &lt;redacted expletive&gt;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>It is no secret that both Sempi and Vian prefer their mom over me. Vian perceives me as the guy who lives in the same house and occasionally grabs him from his mom to change his diaper. </p>
<p>If I happen to enter a room in which he is playing, he will preemptively declare &ldquo;I don&rsquo;t need you, appa&rdquo;. Which is a wonderfully  heartwarming phrase to hear from your child. </p>
<p>A couple of days ago, the entire family was in the living room. Yoshi was playing with the kids, I was working on my laptop. Yoshi stood up to leave the room, and Vian starts to get anxious. Yoshi reassures him that she&rsquo;ll be right back. I wasn&rsquo;t paying much attention to the surroundings as I was focused on my laptop. </p>
<p>Vian says something to me. I half-heartedly acknowledge. Suddenly he yells at me, &ldquo;APPA! Are you going to answer me?&rdquo;. I immediately sit straight, set aside my laptop and focus all of my attention to him. &ldquo;I&rsquo;m sorry, Vian. What were you saying, baby?&rdquo;. Vian replies &ldquo;I was saying that I don&rsquo;t need you&rdquo;. </p>
<p>Very well then, I&rsquo;m glad you got my undivided attention to share that, <redacted expletive>.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>I&#39;m batman</title>
      <link>https://amjith.com/blog/im-batman/</link>
      <pubDate>Sun, 25 Nov 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/im-batman/</guid>
      <description>&lt;p&gt;Sempi&amp;rsquo;s new obsession is playing police. Every chance he gets, he recruits me and Vian to play police. &lt;/p&gt;
&lt;p&gt;Sempi: Appa, let&amp;rsquo;s play police. You can be the bad guy and I&amp;rsquo;ll be police&lt;/p&gt;
&lt;p&gt;Me: Ok! Vian, what are you going to be? A good guy or a bad guy?&lt;/p&gt;
&lt;p&gt;Vian: I&amp;rsquo;m batman. &lt;/p&gt;
&lt;p&gt;Me: I see, so is batman a good guy or a bad guy? &lt;/p&gt;
&lt;p&gt;Vian: No appa, I&amp;rsquo;m batman. &lt;/p&gt;
&lt;p&gt;Me: Alrighty then. I&amp;rsquo;m glad we settled that.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi&rsquo;s new obsession is playing police. Every chance he gets, he recruits me and Vian to play police. </p>
<p>Sempi: Appa, let&rsquo;s play police. You can be the bad guy and I&rsquo;ll be police</p>
<p>Me: Ok! Vian, what are you going to be? A good guy or a bad guy?</p>
<p>Vian: I&rsquo;m batman. </p>
<p>Me: I see, so is batman a good guy or a bad guy? </p>
<p>Vian: No appa, I&rsquo;m batman. </p>
<p>Me: Alrighty then. I&rsquo;m glad we settled that.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Hot Cocoa</title>
      <link>https://amjith.com/blog/hot-cocoa/</link>
      <pubDate>Wed, 21 Nov 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/hot-cocoa/</guid>
      <description>&lt;p&gt;It is freezing outside. We bundle up and go out to explore. When we got back to our lodging it was warm and cozy. Yoshi decided to make everyone hot cocoa. &lt;/p&gt;
&lt;p&gt;She brings the cups of hot cocoa and the bag of marshmallows.&lt;/p&gt;
&lt;p&gt;Yoshi: Vian, how old are you?&lt;/p&gt;
&lt;p&gt;Vian: Two!&lt;/p&gt;
&lt;p&gt;Yoshi: You can have 2 marshmallows for your hot chocolate.&lt;/p&gt;
&lt;p&gt;Vian: Yay! (and proceeds to grab a handful of marshmallows and dumps it into his hot chocolate).&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/2171422/UYYRAI2pnA7DpoCqfNMqx16bBHI/large_HotCocoa.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>It is freezing outside. We bundle up and go out to explore. When we got back to our lodging it was warm and cozy. Yoshi decided to make everyone hot cocoa. </p>
<p>She brings the cups of hot cocoa and the bag of marshmallows.</p>
<p>Yoshi: Vian, how old are you?</p>
<p>Vian: Two!</p>
<p>Yoshi: You can have 2 marshmallows for your hot chocolate.</p>
<p>Vian: Yay! (and proceeds to grab a handful of marshmallows and dumps it into his hot chocolate).</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/2171422/UYYRAI2pnA7DpoCqfNMqx16bBHI/large_HotCocoa.jpeg" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Ok Wiretap</title>
      <link>https://amjith.com/blog/ok-wiretap/</link>
      <pubDate>Wed, 21 Nov 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/ok-wiretap/</guid>
      <description>&lt;p&gt;We don&amp;rsquo;t have any wiretap devices like Google Home or Amazon Echo at our house. So whenever we encounter on in the wild the kids get excited about talking to them. &lt;/p&gt;
&lt;p&gt;We went on a vacation where the AirBnB had a Google version of the wiretap. So Sempi requested it to tell him a story and was pleased with the results.&lt;/p&gt;
&lt;p&gt;Vian decided that he will try his luck on this device. Pretty soon I heard him screaming:&lt;/p&gt;
&lt;p&gt;&amp;ldquo;OK! DOODLE!&amp;rdquo; &lt;/p&gt;
&lt;p&gt;&amp;ldquo;OK! DOODLE!&amp;rdquo;&lt;/p&gt;
&lt;p&gt;&amp;ldquo;OK! DOODLE!&amp;rdquo;&lt;/p&gt;
&lt;p&gt;Poor kid, one of these days he will learn how to pronounce the &amp;ldquo;Ga&amp;rdquo; sound. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We don&rsquo;t have any wiretap devices like Google Home or Amazon Echo at our house. So whenever we encounter on in the wild the kids get excited about talking to them. </p>
<p>We went on a vacation where the AirBnB had a Google version of the wiretap. So Sempi requested it to tell him a story and was pleased with the results.</p>
<p>Vian decided that he will try his luck on this device. Pretty soon I heard him screaming:</p>
<p>&ldquo;OK! DOODLE!&rdquo; </p>
<p>&ldquo;OK! DOODLE!&rdquo;</p>
<p>&ldquo;OK! DOODLE!&rdquo;</p>
<p>Poor kid, one of these days he will learn how to pronounce the &ldquo;Ga&rdquo; sound. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>What is your superpower?</title>
      <link>https://amjith.com/blog/what-is-your-superpower/</link>
      <pubDate>Wed, 10 Oct 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/what-is-your-superpower/</guid>
      <description>&lt;p&gt;Sempi is really into superheroes and police. The other day I was walking him to school and he tells me, &lt;/p&gt;
&lt;p&gt;Sempi: Appa, can I tell you a secret? &lt;/p&gt;
&lt;p&gt;Me: Yeah. &lt;/p&gt;
&lt;p&gt;Sempi (whispers): My secret identity is (redacted). &lt;/p&gt;
&lt;p&gt;Me: Wow, really? Why didn&amp;rsquo;t you tell me sooner, I could have used your powers to crush the boxes in the recycling bins.&lt;/p&gt;
&lt;p&gt;Sempi: You can&amp;rsquo;t tell anyone. Well, maybe just amma, but no one else. &lt;/p&gt;
&lt;p&gt;Me: What about Vian? &lt;/p&gt;
&lt;p&gt;Sempi: He&amp;rsquo;s too young, he might tell someone. Maybe when he grows up you can tell him. &lt;/p&gt;
&lt;p&gt;Me: Do you think when he grows up he&amp;rsquo;ll also get superpowers? &lt;/p&gt;
&lt;p&gt;Sempi: Yeah. Even you have superpowers appa. You can be police.&lt;/p&gt;
&lt;p&gt;Me: Really?&lt;/p&gt;
&lt;p&gt;Sempi: Yeah, you can be police who stays indoors and we&amp;rsquo;ll contact you for instructions when we&amp;rsquo;re fighting bad guys. You know, since you&amp;rsquo;re good with computers. &lt;/p&gt;
&lt;p&gt;*sniff* My son thinks I&amp;rsquo;m good with computers. It is the highest compliment I&amp;rsquo;ve received in my life.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi is really into superheroes and police. The other day I was walking him to school and he tells me, </p>
<p>Sempi: Appa, can I tell you a secret? </p>
<p>Me: Yeah. </p>
<p>Sempi (whispers): My secret identity is (redacted). </p>
<p>Me: Wow, really? Why didn&rsquo;t you tell me sooner, I could have used your powers to crush the boxes in the recycling bins.</p>
<p>Sempi: You can&rsquo;t tell anyone. Well, maybe just amma, but no one else. </p>
<p>Me: What about Vian? </p>
<p>Sempi: He&rsquo;s too young, he might tell someone. Maybe when he grows up you can tell him. </p>
<p>Me: Do you think when he grows up he&rsquo;ll also get superpowers? </p>
<p>Sempi: Yeah. Even you have superpowers appa. You can be police.</p>
<p>Me: Really?</p>
<p>Sempi: Yeah, you can be police who stays indoors and we&rsquo;ll contact you for instructions when we&rsquo;re fighting bad guys. You know, since you&rsquo;re good with computers. </p>
<p>*sniff* My son thinks I&rsquo;m good with computers. It is the highest compliment I&rsquo;ve received in my life.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Nice try, dad</title>
      <link>https://amjith.com/blog/nice-try-dad/</link>
      <pubDate>Mon, 01 Oct 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/nice-try-dad/</guid>
      <description>&lt;p&gt;Vian is still having trouble pronouncing the sound &amp;lsquo;ka&amp;rsquo;. He uses the sound &amp;lsquo;ta&amp;rsquo; when he tries to say &amp;lsquo;ka&amp;rsquo;. See &lt;a href=&#34;https://amjith.com/blog/truly-wonderful-the-mind-of-a-child-is&#34;&gt;previous&lt;/a&gt; &lt;a href=&#34;https://amjith.com/blog/truly-wonderful-the-mind-of-a-child-is&#34;&gt;post&lt;/a&gt; for some examples. &lt;/p&gt;
&lt;p&gt;We&amp;rsquo;re reading a picture book on the couch. &lt;/p&gt;
&lt;p&gt;Vian: What is this?&lt;/p&gt;
&lt;p&gt;Me: That is a farm.&lt;/p&gt;
&lt;p&gt;Vian: Farm!?&lt;/p&gt;
&lt;p&gt;Vian: What is this?&lt;/p&gt;
&lt;p&gt;Me: That&amp;rsquo;s a chicken.&lt;/p&gt;
&lt;p&gt;Vian: A Tciten? &lt;/p&gt;
&lt;p&gt;Me: Yeah a chicken. &lt;/p&gt;
&lt;p&gt;I noticed that his pronunciation of &amp;ldquo;Tciten&amp;rdquo; is suspiciously close to how he would pronounce &amp;ldquo;Kitchen&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;So I figured I&amp;rsquo;ll take this opportunity to troll him using cognitive dissonance.&lt;/p&gt;
&lt;p&gt;Me: Where is Amma?&lt;/p&gt;
&lt;p&gt;Vian: Over there (points to Kitchen).&lt;/p&gt;
&lt;p&gt;Me: What is that room called.&lt;/p&gt;
&lt;p&gt;Vian: That&amp;rsquo;s a &amp;ldquo;Titen&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;Me: What is this called? (pointing to the chicken in a book). &lt;/p&gt;
&lt;p&gt;Vian stares at me a second while he figures out my trap.&lt;/p&gt;
&lt;p&gt;Vian: It&amp;rsquo;s a dut (duck). &lt;/p&gt;
&lt;p&gt;Once again I&amp;rsquo;m outsmarted by a two-year-old. Never been prouder. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian is still having trouble pronouncing the sound &lsquo;ka&rsquo;. He uses the sound &lsquo;ta&rsquo; when he tries to say &lsquo;ka&rsquo;. See <a href="https://amjith.com/blog/truly-wonderful-the-mind-of-a-child-is">previous</a> <a href="https://amjith.com/blog/truly-wonderful-the-mind-of-a-child-is">post</a> for some examples. </p>
<p>We&rsquo;re reading a picture book on the couch. </p>
<p>Vian: What is this?</p>
<p>Me: That is a farm.</p>
<p>Vian: Farm!?</p>
<p>Vian: What is this?</p>
<p>Me: That&rsquo;s a chicken.</p>
<p>Vian: A Tciten? </p>
<p>Me: Yeah a chicken. </p>
<p>I noticed that his pronunciation of &ldquo;Tciten&rdquo; is suspiciously close to how he would pronounce &ldquo;Kitchen&rdquo;. </p>
<p>So I figured I&rsquo;ll take this opportunity to troll him using cognitive dissonance.</p>
<p>Me: Where is Amma?</p>
<p>Vian: Over there (points to Kitchen).</p>
<p>Me: What is that room called.</p>
<p>Vian: That&rsquo;s a &ldquo;Titen&rdquo;.</p>
<p>Me: What is this called? (pointing to the chicken in a book). </p>
<p>Vian stares at me a second while he figures out my trap.</p>
<p>Vian: It&rsquo;s a dut (duck). </p>
<p>Once again I&rsquo;m outsmarted by a two-year-old. Never been prouder. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 3yo</title>
      <link>https://amjith.com/blog/conversations-with-a-3yo-2/</link>
      <pubDate>Sun, 02 Sep 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-3yo-2/</guid>
      <description>&lt;p&gt;We&amp;rsquo;re visiting India and the kids are playing with my brother&amp;rsquo;s son, Thiralon (the 3yo protagonist). He&amp;rsquo;s a matter of fact guy who is unintentionally hilarious. &lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;The phone rings at home and Thiralon picks up the phone. It&amp;rsquo;s his grandpa calling. &lt;/p&gt;
&lt;p&gt;Grandpa: Hi Thiralon, how are you? &lt;/p&gt;
&lt;p&gt;Thiralon: I&amp;rsquo;m fine.&lt;/p&gt;
&lt;p&gt;Grandpa: What are you doing? &lt;/p&gt;
&lt;p&gt;Thiralon: Right now I&amp;rsquo;m talking to you on the phone. &lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;He&amp;rsquo;s a rambunctious kid who loves to smash things. He has just smashed down a pillow fort. I&amp;rsquo;m trying to get him to admit he smashed it.&lt;/p&gt;
&lt;p&gt;Me: Thiralon, what happened to the fort? &lt;/p&gt;
&lt;p&gt;Thiralon: It broke down.&lt;/p&gt;
&lt;p&gt;Me: How did it break?&lt;/p&gt;
&lt;p&gt;Thiralon: It broke with a kaboom! &lt;/p&gt;
&lt;p&gt;Me: LOL! Of course, it did. &lt;/p&gt;
&lt;hr&gt;
</description>
      <content:encoded><![CDATA[<p>We&rsquo;re visiting India and the kids are playing with my brother&rsquo;s son, Thiralon (the 3yo protagonist). He&rsquo;s a matter of fact guy who is unintentionally hilarious. </p>
<hr>
<p>The phone rings at home and Thiralon picks up the phone. It&rsquo;s his grandpa calling. </p>
<p>Grandpa: Hi Thiralon, how are you? </p>
<p>Thiralon: I&rsquo;m fine.</p>
<p>Grandpa: What are you doing? </p>
<p>Thiralon: Right now I&rsquo;m talking to you on the phone. </p>
<hr>
<p>He&rsquo;s a rambunctious kid who loves to smash things. He has just smashed down a pillow fort. I&rsquo;m trying to get him to admit he smashed it.</p>
<p>Me: Thiralon, what happened to the fort? </p>
<p>Thiralon: It broke down.</p>
<p>Me: How did it break?</p>
<p>Thiralon: It broke with a kaboom! </p>
<p>Me: LOL! Of course, it did. </p>
<hr>
]]></content:encoded>
    </item>
    
    <item>
      <title>Truly wonderful, the mind of a child is</title>
      <link>https://amjith.com/blog/truly-wonderful-the-mind-of-a-child-is/</link>
      <pubDate>Sun, 19 Aug 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/truly-wonderful-the-mind-of-a-child-is/</guid>
      <description>&lt;p&gt;Vian is quite eloquent these days. But he still can&amp;rsquo;t pronounce the sounds &amp;lsquo;Ka&amp;rsquo; and &amp;lsquo;Ga&amp;rsquo;. Instead, he replaces them with the sounds &amp;lsquo;Ta&amp;rsquo; and &amp;lsquo;Da&amp;rsquo; respectively.&lt;/p&gt;
&lt;p&gt;Here are some choice selections: &lt;/p&gt;
&lt;p&gt;&lt;em&gt;Vian:&lt;/em&gt; Appa, where is my tar (car)?&lt;/p&gt;
&lt;p&gt;&lt;em&gt;Vian:&lt;/em&gt; ﻿Tan I have a tootie (cookie)? &lt;/p&gt;
&lt;p&gt;&lt;em&gt;Vian:&lt;/em&gt; Amma, gone to yoda (yoga) class. &lt;/p&gt;
&lt;p&gt;I always had a nagging suspicion that my wife is a Jedi. The way she can change my mind in one sentence&amp;hellip;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian is quite eloquent these days. But he still can&rsquo;t pronounce the sounds &lsquo;Ka&rsquo; and &lsquo;Ga&rsquo;. Instead, he replaces them with the sounds &lsquo;Ta&rsquo; and &lsquo;Da&rsquo; respectively.</p>
<p>Here are some choice selections: </p>
<p><em>Vian:</em> Appa, where is my tar (car)?</p>
<p><em>Vian:</em> ﻿Tan I have a tootie (cookie)? </p>
<p><em>Vian:</em> Amma, gone to yoda (yoga) class. </p>
<p>I always had a nagging suspicion that my wife is a Jedi. The way she can change my mind in one sentence&hellip;.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Zen master or a troll?</title>
      <link>https://amjith.com/blog/zen-master-or-a-troll/</link>
      <pubDate>Wed, 18 Jul 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/zen-master-or-a-troll/</guid>
      <description>&lt;p&gt;My 2-year old (Vian) is getting eloquent by the day. He is not afraid to try out his new vocabulary.&lt;/p&gt;
&lt;p&gt;Yesterday we were playing in the backyard. The kids want me to find them a rake. I walk around trying to find it, muttering to myself. &lt;/p&gt;
&lt;p&gt;Vian comes over and says, &amp;ldquo;I help you&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;I accept graciously and tell him that I&amp;rsquo;m looking for the rake. &lt;/p&gt;
&lt;p&gt;Me: I wonder where it is. (muttering to myself). &lt;/p&gt;
&lt;p&gt;Vian walks over to me and pulls my hand. In all seriousness he says, &lt;/p&gt;
&lt;p&gt;Vian: Appa, it is somewhere. &lt;/p&gt;
&lt;p&gt;And walks away with the satisfaction of having just helped his clueless dad. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>My 2-year old (Vian) is getting eloquent by the day. He is not afraid to try out his new vocabulary.</p>
<p>Yesterday we were playing in the backyard. The kids want me to find them a rake. I walk around trying to find it, muttering to myself. </p>
<p>Vian comes over and says, &ldquo;I help you&rdquo;.</p>
<p>I accept graciously and tell him that I&rsquo;m looking for the rake. </p>
<p>Me: I wonder where it is. (muttering to myself). </p>
<p>Vian walks over to me and pulls my hand. In all seriousness he says, </p>
<p>Vian: Appa, it is somewhere. </p>
<p>And walks away with the satisfaction of having just helped his clueless dad. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Social sites and emotional ups and downs</title>
      <link>https://amjith.com/blog/social-sites-and-emotional-ups-and-downs/</link>
      <pubDate>Sun, 10 Jun 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/social-sites-and-emotional-ups-and-downs/</guid>
      <description>&lt;p&gt;Note: I do NOT suffer from depression. I&amp;rsquo;m not trying to make light of the serious condition that is depression.&lt;/p&gt;
&lt;p&gt;I just got back from PyCon. I had a booth for &lt;a href=&#34;https://www.dbcli.com/&#34;&gt;DBCLI&lt;/a&gt; (OpenSource project), I gave a &lt;a href=&#34;https://devpen.io/TBD&#34;&gt;talk about my work&lt;/a&gt; at Netflix, I manned the job fair table and participated in the sprints. People were coming up to me and showering with praise about my OpenSource project and my talk. It is like getting a lifetime&amp;rsquo;s worth of positive feedback thrown at me in a span of three days. It was exhilarating.&lt;/p&gt;
&lt;p&gt;I got back home and hugged the kids and my wife. My two kids obviously missed me and they clung to me for about 20 minutes before reverting back to being mama&amp;rsquo;s boys. I really don&amp;rsquo;t blame them for preferring their mom over me. My wife is just a better human being than me and the kids just know it.&lt;/p&gt;
&lt;p&gt;This is where the hint of a mild depression sets in. I start to wonder why my wife and kids aren&amp;rsquo;t constantly showering me with praise. I just walked from the bedroom to the kitchen and not a single compliment was thrown at me. What is going on? In a couple of days, the trickle of online pampering (via Twitter) starts to taper off. When you refresh twitter there are no more new notifications.&lt;/p&gt;
&lt;p&gt;What did I do to deserve this shunning? Why do people hate me? These are questions that run through my mind before I realize I&amp;rsquo;ve become an insufferable spoiled brat.&lt;/p&gt;
&lt;p&gt;It is alarming how quickly my brain got accustomed to being treated like a &amp;ldquo;celebrity&amp;rdquo;. I now understand why real celebrities often suffer from depression. They live through this high and low every single day.&lt;/p&gt;
&lt;p&gt;I am so glad I don&amp;rsquo;t have to deal with this emotional roller coaster every day. I shudder at the thought of living in a world where I&amp;rsquo;m constantly praised for doing even the most mundane things in life. Where everyday activities are treated as accomplishments and complimented as such.&lt;/p&gt;
&lt;p&gt;Having 18 friends compliment my breakfast. Or 23 friends fawn over a picture of some cat.&lt;/p&gt;
&lt;p&gt;Not just any old compliment but a compliment laced with superfluous adjectives.&lt;/p&gt;
&lt;p&gt;&amp;ldquo;OMG! That toast looks super delicious.&amp;rdquo;&lt;/p&gt;
&lt;p&gt;&amp;ldquo;That cat melts my heart super hard, it makes me want to eat my own eyelids.&amp;rdquo;&lt;/p&gt;
&lt;p&gt;You know where I&amp;rsquo;m going with this, don&amp;rsquo;t you? Social networking sites.&lt;/p&gt;
&lt;p&gt;Praising someone is just a click away. You can &amp;ldquo;heart&amp;rdquo; someone&amp;rsquo;s picture, you can &amp;ldquo;like&amp;rdquo; someone&amp;rsquo;s rambling, you can even spread their nugget of wisdom by retweeting. Can you imagine what will happen when all of that is taken away? Someone who is forced to interact with the real world and only the real world. A world where people don&amp;rsquo;t swarm around someone&amp;rsquo;s breakfast to talk about how wonderful that toast and scrambled eggs look. Heck, they don&amp;rsquo;t even bother to take a picture of the food to save it in the archives for the future generations to appreciate.&lt;/p&gt;
&lt;p&gt;If you eat a salad without sharing a picture of it, do you really get full?&lt;/p&gt;
&lt;p&gt;All of this &amp;ldquo;attention&amp;rdquo; is addictive. Soon we&amp;rsquo;re chasing after the next hit. A bigger hit. Let&amp;rsquo;s share something thrilling, something shocking, something dangerous.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m sure the &amp;ldquo;big social&amp;rdquo; knows all about the emotional turmoil that results from this. But why would they continue to find new ways that make it easier to spread this fake attention? Surely, they&amp;rsquo;re not just trying to maximize their short-term profits at the cost of desensitizing a whole generation of youngsters and sinking them into depression. Because that would make them cold, calculating, heartless, and evil.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Note: I do NOT suffer from depression. I&rsquo;m not trying to make light of the serious condition that is depression.</p>
<p>I just got back from PyCon. I had a booth for <a href="https://www.dbcli.com/">DBCLI</a> (OpenSource project), I gave a <a href="https://devpen.io/TBD">talk about my work</a> at Netflix, I manned the job fair table and participated in the sprints. People were coming up to me and showering with praise about my OpenSource project and my talk. It is like getting a lifetime&rsquo;s worth of positive feedback thrown at me in a span of three days. It was exhilarating.</p>
<p>I got back home and hugged the kids and my wife. My two kids obviously missed me and they clung to me for about 20 minutes before reverting back to being mama&rsquo;s boys. I really don&rsquo;t blame them for preferring their mom over me. My wife is just a better human being than me and the kids just know it.</p>
<p>This is where the hint of a mild depression sets in. I start to wonder why my wife and kids aren&rsquo;t constantly showering me with praise. I just walked from the bedroom to the kitchen and not a single compliment was thrown at me. What is going on? In a couple of days, the trickle of online pampering (via Twitter) starts to taper off. When you refresh twitter there are no more new notifications.</p>
<p>What did I do to deserve this shunning? Why do people hate me? These are questions that run through my mind before I realize I&rsquo;ve become an insufferable spoiled brat.</p>
<p>It is alarming how quickly my brain got accustomed to being treated like a &ldquo;celebrity&rdquo;. I now understand why real celebrities often suffer from depression. They live through this high and low every single day.</p>
<p>I am so glad I don&rsquo;t have to deal with this emotional roller coaster every day. I shudder at the thought of living in a world where I&rsquo;m constantly praised for doing even the most mundane things in life. Where everyday activities are treated as accomplishments and complimented as such.</p>
<p>Having 18 friends compliment my breakfast. Or 23 friends fawn over a picture of some cat.</p>
<p>Not just any old compliment but a compliment laced with superfluous adjectives.</p>
<p>&ldquo;OMG! That toast looks super delicious.&rdquo;</p>
<p>&ldquo;That cat melts my heart super hard, it makes me want to eat my own eyelids.&rdquo;</p>
<p>You know where I&rsquo;m going with this, don&rsquo;t you? Social networking sites.</p>
<p>Praising someone is just a click away. You can &ldquo;heart&rdquo; someone&rsquo;s picture, you can &ldquo;like&rdquo; someone&rsquo;s rambling, you can even spread their nugget of wisdom by retweeting. Can you imagine what will happen when all of that is taken away? Someone who is forced to interact with the real world and only the real world. A world where people don&rsquo;t swarm around someone&rsquo;s breakfast to talk about how wonderful that toast and scrambled eggs look. Heck, they don&rsquo;t even bother to take a picture of the food to save it in the archives for the future generations to appreciate.</p>
<p>If you eat a salad without sharing a picture of it, do you really get full?</p>
<p>All of this &ldquo;attention&rdquo; is addictive. Soon we&rsquo;re chasing after the next hit. A bigger hit. Let&rsquo;s share something thrilling, something shocking, something dangerous.</p>
<p>I&rsquo;m sure the &ldquo;big social&rdquo; knows all about the emotional turmoil that results from this. But why would they continue to find new ways that make it easier to spread this fake attention? Surely, they&rsquo;re not just trying to maximize their short-term profits at the cost of desensitizing a whole generation of youngsters and sinking them into depression. Because that would make them cold, calculating, heartless, and evil.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 1 yo</title>
      <link>https://amjith.com/blog/conversations-with-a-1-yo/</link>
      <pubDate>Tue, 20 Mar 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-1-yo/</guid>
      <description>&lt;p&gt;Vian has more than a few words in his vocabulary now and he&amp;rsquo;s not afraid to show off.&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;I&amp;rsquo;m having breakfast with Vian. &lt;/p&gt;
&lt;p&gt;We hear the bathroom flush. &lt;/p&gt;
&lt;p&gt;Vian gets all animated and yells &amp;ldquo;Poop!&amp;rdquo; and points to the restroom.&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Another day, the same setup. I&amp;rsquo;m having breakfast with Vian.&lt;/p&gt;
&lt;p&gt;Yoshi joins us with a cup of tea. &lt;/p&gt;
&lt;p&gt;Vian points to the steam rising from the cup and yells &amp;ldquo;HOT&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;Yoshi acknowledges, yes. It is hot tea. &lt;/p&gt;
&lt;p&gt;Vian: &amp;ldquo;Hot Tea&amp;rdquo;  (sounds more like hottie). &lt;/p&gt;
&lt;p&gt;Me: Yes Vian, you&amp;rsquo;re a hottie. &lt;/p&gt;
&lt;p&gt;Vian (yells): NO!&lt;/p&gt;
&lt;p&gt;Me: You&amp;rsquo;re not a hottie?&lt;/p&gt;
&lt;p&gt;Vian: Amma hottie. &lt;/p&gt;
&lt;p&gt;Who am I to argue. ;)&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian has more than a few words in his vocabulary now and he&rsquo;s not afraid to show off.</p>
<hr>
<p>I&rsquo;m having breakfast with Vian. </p>
<p>We hear the bathroom flush. </p>
<p>Vian gets all animated and yells &ldquo;Poop!&rdquo; and points to the restroom.</p>
<hr>
<p>Another day, the same setup. I&rsquo;m having breakfast with Vian.</p>
<p>Yoshi joins us with a cup of tea. </p>
<p>Vian points to the steam rising from the cup and yells &ldquo;HOT&rdquo;. </p>
<p>Yoshi acknowledges, yes. It is hot tea. </p>
<p>Vian: &ldquo;Hot Tea&rdquo;  (sounds more like hottie). </p>
<p>Me: Yes Vian, you&rsquo;re a hottie. </p>
<p>Vian (yells): NO!</p>
<p>Me: You&rsquo;re not a hottie?</p>
<p>Vian: Amma hottie. </p>
<p>Who am I to argue. ;)</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Fun with dosas</title>
      <link>https://amjith.com/blog/fun-with-dosas/</link>
      <pubDate>Fri, 16 Mar 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/fun-with-dosas/</guid>
      <description>&lt;p&gt;I love dosas. Dosa is a south Indian dish. A better version of a crepe (shots fired) or a ridiculously thin pancake. Sempi (5yo) is also a huge fan. &lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m making dosas for his breakfast and he requested that I make the dosas into shapes for him. He requested a police car. I was happy to oblige. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/2044675/9yeNKP9vUbyNoKqrRHfqqo4tyw4/large_MVIMG_20180313_080704.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Sempi: What is this?&lt;/p&gt;
&lt;p&gt;Me: A police car. &lt;/p&gt;
&lt;p&gt;Sempi: It looks like a spaceship. Next time add some wheels to it.&lt;/p&gt;
&lt;p&gt;Me: I&amp;rsquo;ll see what I can do.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/2044676/ky1VwHbls4cfFiZjcwsYKQMLEjg/large_MVIMG_20180313_074843.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I love dosas. Dosa is a south Indian dish. A better version of a crepe (shots fired) or a ridiculously thin pancake. Sempi (5yo) is also a huge fan. </p>
<p>I&rsquo;m making dosas for his breakfast and he requested that I make the dosas into shapes for him. He requested a police car. I was happy to oblige. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/2044675/9yeNKP9vUbyNoKqrRHfqqo4tyw4/large_MVIMG_20180313_080704.jpg" alt=""  />
</p>
<p>Sempi: What is this?</p>
<p>Me: A police car. </p>
<p>Sempi: It looks like a spaceship. Next time add some wheels to it.</p>
<p>Me: I&rsquo;ll see what I can do.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/2044676/ky1VwHbls4cfFiZjcwsYKQMLEjg/large_MVIMG_20180313_074843.jpg" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Language and Thought</title>
      <link>https://amjith.com/blog/language-and-thought/</link>
      <pubDate>Fri, 16 Mar 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/language-and-thought/</guid>
      <description>&lt;p&gt;I believe that the language you speak influences the way you think. I don&amp;rsquo;t have any kind of proof other than some anecdotal evidence. &lt;/p&gt;
&lt;p&gt;Recently I started noticing this in the field of computer languages as well. I consider Python to be my dominant language. I have a coworker (let&amp;rsquo;s call him Aaron, because that&amp;rsquo;s his name) who likes to bait me by pointing out certain lack of features in Python and how Ruby gets it right. Most of the time I dismiss his complaints as invalid because I never have a use for those features in my day to day coding.&lt;/p&gt;
&lt;p&gt;Then it dawned on me that I don&amp;rsquo;t have a need for those features because I tend to think in Python. When I am presented with a problem I think of a solution that can be implemented in Python and my thought process naturally gravitates towards the features available in Python. &lt;/p&gt;
&lt;p&gt;What I learned from this realization is, if you learn many different languages you&amp;rsquo;ll never be happy with any single language. You&amp;rsquo;ll always yearn for that sweet feature that is missing in your current language. &lt;/p&gt;
&lt;p&gt;Let that be a lesson.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I believe that the language you speak influences the way you think. I don&rsquo;t have any kind of proof other than some anecdotal evidence. </p>
<p>Recently I started noticing this in the field of computer languages as well. I consider Python to be my dominant language. I have a coworker (let&rsquo;s call him Aaron, because that&rsquo;s his name) who likes to bait me by pointing out certain lack of features in Python and how Ruby gets it right. Most of the time I dismiss his complaints as invalid because I never have a use for those features in my day to day coding.</p>
<p>Then it dawned on me that I don&rsquo;t have a need for those features because I tend to think in Python. When I am presented with a problem I think of a solution that can be implemented in Python and my thought process naturally gravitates towards the features available in Python. </p>
<p>What I learned from this realization is, if you learn many different languages you&rsquo;ll never be happy with any single language. You&rsquo;ll always yearn for that sweet feature that is missing in your current language. </p>
<p>Let that be a lesson.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>git open - A small git hack</title>
      <link>https://amjith.com/blog/git-open-a-small-git-hack/</link>
      <pubDate>Tue, 20 Feb 2018 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/git-open-a-small-git-hack/</guid>
      <description>&lt;p&gt;You can add a git sub-command by defining a new alias in your ~/.gitconfig file as follows:&lt;/p&gt;
&lt;p&gt;This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
&lt;a href=&#34;https://github.co/hiddenchars&#34;&gt;Learn more about bidirectional Unicode characters&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;[Show hidden characters]({{ revealButtonHref }})&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;[alias]&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;open = !vim &lt;code&gt;git-open.sh&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;a href=&#34;https://gist.github.com/amjith/fbd715b4f0e57ef4f38fa302b01b9948/raw/237c5193e173f6d2f9e9e224e6252a5ba504ab3e/gitconfig&#34;&gt;view raw&lt;/a&gt;
&lt;a href=&#34;https://gist.github.com/amjith/fbd715b4f0e57ef4f38fa302b01b9948#file-gitconfig&#34;&gt;gitconfig&lt;/a&gt;
hosted with ❤ by &lt;a href=&#34;https://github.com&#34;&gt;GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The git open defined in the ~/.gitconfig is mapped to a shell script called git-open.sh. &lt;/p&gt;
&lt;p&gt;This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
&lt;a href=&#34;https://github.co/hiddenchars&#34;&gt;Learn more about bidirectional Unicode characters&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;[Show hidden characters]({{ revealButtonHref }})&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;#!/bin/bash&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;dirty=`git status &amp;ndash;porcelain -uno&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;last_modified=&lt;code&gt;git show --pretty=&amp;quot;format:&amp;quot; --name-only HEAD&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;if [ -n &amp;ldquo;$dirty&amp;rdquo; ]; then&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;echo $dirty&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;else&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;echo $last_modified&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;fi&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;a href=&#34;https://gist.github.com/amjith/c8179e589f84b16894aae962d2fb0e39/raw/240a91ac5c1f93854fad37bc27834f7c9e971bd6/git-open.sh&#34;&gt;view raw&lt;/a&gt;
&lt;a href=&#34;https://gist.github.com/amjith/c8179e589f84b16894aae962d2fb0e39#file-git-open-sh&#34;&gt;git-open.sh&lt;/a&gt;
hosted with ❤ by &lt;a href=&#34;https://github.com&#34;&gt;GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This bash script does two things: &lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;It tries to detect if there are any files with uncommitted changes in the current repo and prints out the filenames.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;If the repo doesn&amp;rsquo;t have any uncommitted files, it&amp;rsquo;ll print the filenames from the last commit.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;The git open alias is mapped to open the output from this script using vim. &lt;/p&gt;
&lt;p&gt;Why is this useful?&lt;/p&gt;
&lt;p&gt;I can pick up where I left off the previous day by simply typing &lt;code&gt;git open&lt;/code&gt; inside the repo. This will open either all files with uncommitted changes or open the files from the last commit. There is a very good chance that my work for the day will continue on those files.&lt;/p&gt;
&lt;p&gt;A small hack to make life a little bit easier.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>You can add a git sub-command by defining a new alias in your ~/.gitconfig file as follows:</p>
<p>This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
<a href="https://github.co/hiddenchars">Learn more about bidirectional Unicode characters</a></p>
<p>[Show hidden characters]({{ revealButtonHref }})</p>
<table>
<thead>
<tr>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr>
<td></td>
<td>[alias]</td>
</tr>
<tr>
<td></td>
<td>open = !vim <code>git-open.sh</code></td>
</tr>
</tbody>
</table>
<p><a href="https://gist.github.com/amjith/fbd715b4f0e57ef4f38fa302b01b9948/raw/237c5193e173f6d2f9e9e224e6252a5ba504ab3e/gitconfig">view raw</a>
<a href="https://gist.github.com/amjith/fbd715b4f0e57ef4f38fa302b01b9948#file-gitconfig">gitconfig</a>
hosted with ❤ by <a href="https://github.com">GitHub</a></p>
<p>The git open defined in the ~/.gitconfig is mapped to a shell script called git-open.sh. </p>
<p>This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
<a href="https://github.co/hiddenchars">Learn more about bidirectional Unicode characters</a></p>
<p>[Show hidden characters]({{ revealButtonHref }})</p>
<table>
<thead>
<tr>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr>
<td></td>
<td>#!/bin/bash</td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td>dirty=`git status &ndash;porcelain -uno</td>
</tr>
<tr>
<td></td>
<td>last_modified=<code>git show --pretty=&quot;format:&quot; --name-only HEAD</code></td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td>if [ -n &ldquo;$dirty&rdquo; ]; then</td>
</tr>
<tr>
<td></td>
<td>echo $dirty</td>
</tr>
<tr>
<td></td>
<td>else</td>
</tr>
<tr>
<td></td>
<td>echo $last_modified</td>
</tr>
<tr>
<td></td>
<td>fi</td>
</tr>
</tbody>
</table>
<p><a href="https://gist.github.com/amjith/c8179e589f84b16894aae962d2fb0e39/raw/240a91ac5c1f93854fad37bc27834f7c9e971bd6/git-open.sh">view raw</a>
<a href="https://gist.github.com/amjith/c8179e589f84b16894aae962d2fb0e39#file-git-open-sh">git-open.sh</a>
hosted with ❤ by <a href="https://github.com">GitHub</a></p>
<p>This bash script does two things: </p>
<ol>
<li>
<p>It tries to detect if there are any files with uncommitted changes in the current repo and prints out the filenames.</p>
</li>
<li>
<p>If the repo doesn&rsquo;t have any uncommitted files, it&rsquo;ll print the filenames from the last commit.</p>
</li>
</ol>
<p>The git open alias is mapped to open the output from this script using vim. </p>
<p>Why is this useful?</p>
<p>I can pick up where I left off the previous day by simply typing <code>git open</code> inside the repo. This will open either all files with uncommitted changes or open the files from the last commit. There is a very good chance that my work for the day will continue on those files.</p>
<p>A small hack to make life a little bit easier.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 1 year old</title>
      <link>https://amjith.com/blog/conversations-with-a-1-year-old/</link>
      <pubDate>Fri, 29 Dec 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-1-year-old/</guid>
      <description>&lt;p&gt;Vian is picking up new words. His new addition is &amp;ldquo;Yeah&amp;rdquo;. It is pronounced with an emphatic &amp;ldquo;EYAH!&amp;rdquo; (imagine a Karate yell).&lt;/p&gt;
&lt;p&gt;I like asking him random questions that are at the edge of his understanding and watch him say &amp;ldquo;Yeah!&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;But sometimes he uses his &amp;ldquo;Yeah!&amp;rdquo; with such precision it catches us off guard. Such as last night when we were getting him ready for bed.&lt;/p&gt;
&lt;p&gt;Yoshi: Vian, would you like to hold a toy? You can pick either Pandie (stuffed panda) or the fire engine.&lt;/p&gt;
&lt;p&gt;Vian: Yeah!&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian is picking up new words. His new addition is &ldquo;Yeah&rdquo;. It is pronounced with an emphatic &ldquo;EYAH!&rdquo; (imagine a Karate yell).</p>
<p>I like asking him random questions that are at the edge of his understanding and watch him say &ldquo;Yeah!&rdquo;.</p>
<p>But sometimes he uses his &ldquo;Yeah!&rdquo; with such precision it catches us off guard. Such as last night when we were getting him ready for bed.</p>
<p>Yoshi: Vian, would you like to hold a toy? You can pick either Pandie (stuffed panda) or the fire engine.</p>
<p>Vian: Yeah!</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Words, Words, Words</title>
      <link>https://amjith.com/blog/words-words-words/</link>
      <pubDate>Sat, 16 Dec 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/words-words-words/</guid>
      <description>&lt;p&gt;Vian has been picking up a few words courtesy of Sempi. The words he has picked up so far are the ones that Sempi uses with forceful emotion. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;﻿STOP:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;﻿Whenever Vian tries to take Sempi&amp;rsquo;s toys, Sempi yells &amp;ldquo;STOOOOP&amp;rdquo; with conviction and distress. So that&amp;rsquo;s the first word that Vian decided to pick up. Now he uses it with us generously. He can&amp;rsquo;t quite pronounce the sound &amp;ldquo;ssss&amp;rdquo; so his STOP sounds like &amp;ldquo;TOP&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;It&amp;rsquo;s a catch all phrase for stopping anything that is unpleasant. So far he has used it to stop me from giving Yoshi hugs in front of him (jealousy). It is hilarious to watch him command his toys to &amp;ldquo;TOOPPP&amp;rdquo; when they keep sliding off of the couch or the table where he&amp;rsquo;s playing.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;﻿NO:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;﻿This is the second word that he&amp;rsquo;s picked up from Sempi. But the twist is, Vian says NO with a tinge of joy and pride. We&amp;rsquo;ve asked Sempi to ask Vian&amp;rsquo;s permission before taking toys from Vian&amp;rsquo;s hands. Sempi being the older, more responsible brother will ask politely &amp;ldquo;Vian can I please play with the toy you have in your hand?&amp;rdquo; and Vian responds &amp;ldquo;NO&amp;rdquo; with a smile and enthusiasm. It looks absolutely savage when witnessed in person.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;READ:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;﻿This one, I&amp;rsquo;m very glad he&amp;rsquo;s picked it up from Sempi. Sempi is a total &lt;a href=&#34;https://amjith.com/blog/bookworm&#34;&gt;book worm&lt;/a&gt;. He asks us to read a book as soon as he wakes up, while eating, while lounging, right before bedtime, even while driving (instead we listen to podcasts while driving). Now Vian has picked up on this and he demands that we read to him while he eats. He can&amp;rsquo;t pronounce &amp;ldquo;R&amp;rdquo; or &amp;ldquo;D&amp;rdquo; so it sounds more like a &amp;ldquo;WEE&amp;rdquo;, &amp;ldquo;WEE&amp;rdquo;. He get so excited about this that he would keep asking us to read even while we&amp;rsquo;re reading him a book.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian has been picking up a few words courtesy of Sempi. The words he has picked up so far are the ones that Sempi uses with forceful emotion. </p>
<p><strong>﻿STOP:</strong></p>
<p>﻿Whenever Vian tries to take Sempi&rsquo;s toys, Sempi yells &ldquo;STOOOOP&rdquo; with conviction and distress. So that&rsquo;s the first word that Vian decided to pick up. Now he uses it with us generously. He can&rsquo;t quite pronounce the sound &ldquo;ssss&rdquo; so his STOP sounds like &ldquo;TOP&rdquo;.</p>
<p>It&rsquo;s a catch all phrase for stopping anything that is unpleasant. So far he has used it to stop me from giving Yoshi hugs in front of him (jealousy). It is hilarious to watch him command his toys to &ldquo;TOOPPP&rdquo; when they keep sliding off of the couch or the table where he&rsquo;s playing.</p>
<p><strong>﻿NO:</strong></p>
<p>﻿This is the second word that he&rsquo;s picked up from Sempi. But the twist is, Vian says NO with a tinge of joy and pride. We&rsquo;ve asked Sempi to ask Vian&rsquo;s permission before taking toys from Vian&rsquo;s hands. Sempi being the older, more responsible brother will ask politely &ldquo;Vian can I please play with the toy you have in your hand?&rdquo; and Vian responds &ldquo;NO&rdquo; with a smile and enthusiasm. It looks absolutely savage when witnessed in person.</p>
<p><strong>READ:</strong></p>
<p>﻿This one, I&rsquo;m very glad he&rsquo;s picked it up from Sempi. Sempi is a total <a href="https://amjith.com/blog/bookworm">book worm</a>. He asks us to read a book as soon as he wakes up, while eating, while lounging, right before bedtime, even while driving (instead we listen to podcasts while driving). Now Vian has picked up on this and he demands that we read to him while he eats. He can&rsquo;t pronounce &ldquo;R&rdquo; or &ldquo;D&rdquo; so it sounds more like a &ldquo;WEE&rdquo;, &ldquo;WEE&rdquo;. He get so excited about this that he would keep asking us to read even while we&rsquo;re reading him a book.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Life hack of a 5 yo</title>
      <link>https://amjith.com/blog/life-hack-of-a-5-yo/</link>
      <pubDate>Fri, 20 Oct 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/life-hack-of-a-5-yo/</guid>
      <description>&lt;p&gt;When I drop off Sempi at school, I walk him to the front desk where they have name badges for the kids arranged in random order. I ask Sempi to pick out his badge while I sign the sign-in sheet. This is my way of training him to recognize his name.&lt;/p&gt;
&lt;p&gt;This morning he told me, &amp;ldquo;Appa, do you see how the safety pin is attached sideways to my badge? I did that yesterday so I can find my badge easily in the mornings&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;#proud-papa&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>When I drop off Sempi at school, I walk him to the front desk where they have name badges for the kids arranged in random order. I ask Sempi to pick out his badge while I sign the sign-in sheet. This is my way of training him to recognize his name.</p>
<p>This morning he told me, &ldquo;Appa, do you see how the safety pin is attached sideways to my badge? I did that yesterday so I can find my badge easily in the mornings&rdquo;. </p>
<p>#proud-papa</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>It starts early</title>
      <link>https://amjith.com/blog/it-starts-early/</link>
      <pubDate>Fri, 13 Oct 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/it-starts-early/</guid>
      <description>&lt;p&gt;Yoshi was washing her face in the bathroom while Vian was playing with the bathroom scale.&lt;/p&gt;
&lt;p&gt;Yoshi: Why is it upside down?&lt;/p&gt;
&lt;p&gt;Vian: Appaaaa&lt;/p&gt;
&lt;p&gt;Yoshi: Appa did it? &lt;/p&gt;
&lt;p&gt;Vian: Appaaa&lt;/p&gt;
&lt;p&gt;Yoshi: oh, appa did it &lt;/p&gt;
&lt;p&gt;Vian: Appaaa Appaaa&lt;/p&gt;
&lt;p&gt;Yoshi: no Vian, you did it &lt;/p&gt;
&lt;p&gt;Vian: (silence)&lt;/p&gt;
&lt;p&gt;All of this happened while I was at work. Appa means dad in Tamil.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Yoshi was washing her face in the bathroom while Vian was playing with the bathroom scale.</p>
<p>Yoshi: Why is it upside down?</p>
<p>Vian: Appaaaa</p>
<p>Yoshi: Appa did it? </p>
<p>Vian: Appaaa</p>
<p>Yoshi: oh, appa did it </p>
<p>Vian: Appaaa Appaaa</p>
<p>Yoshi: no Vian, you did it </p>
<p>Vian: (silence)</p>
<p>All of this happened while I was at work. Appa means dad in Tamil.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Shenanigans</title>
      <link>https://amjith.com/blog/shenanigans/</link>
      <pubDate>Mon, 09 Oct 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/shenanigans/</guid>
      <description>&lt;p&gt;Conversation with Sempi this morning. &lt;/p&gt;
&lt;p&gt;Me: I&amp;rsquo;m going to finish making the fried rice and then we can do our usual shenanigans. What do you say? &lt;/p&gt;
&lt;p&gt;Sempi: Yeah, you finish the fried rice and then we&amp;rsquo;ll throw it in our mouths.&lt;/p&gt;
&lt;p&gt;It was a wonderful morning. :)&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Conversation with Sempi this morning. </p>
<p>Me: I&rsquo;m going to finish making the fried rice and then we can do our usual shenanigans. What do you say? </p>
<p>Sempi: Yeah, you finish the fried rice and then we&rsquo;ll throw it in our mouths.</p>
<p>It was a wonderful morning. :)</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Eloquence</title>
      <link>https://amjith.com/blog/eloquence/</link>
      <pubDate>Sun, 17 Sep 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/eloquence/</guid>
      <description>&lt;p&gt;My younger son (16 months) can&amp;rsquo;t speak any words yet but he has no problems expressing himself by pointing and grunting. When he&amp;rsquo;s hungry he whines and points to the pantry. When he wants a specific fruit out of the fridge he will reject all the other ones with a head shake and sometimes a shove until I offer him the right fruit. &lt;/p&gt;
&lt;p&gt;This morning I witnessed him do a gesture that can only be construed as &amp;ldquo;Look ma no hands&amp;rdquo;. We were at the coffee shop and he was standing on his chair and leaning against the table and taking bites out his muffin. Suddenly he realized he wasn&amp;rsquo;t holding onto the &lt;strong&gt;﻿&lt;/strong&gt;﻿&lt;strong&gt;﻿&lt;/strong&gt;﻿&lt;strong&gt;﻿&lt;/strong&gt;﻿&lt;strong&gt;﻿&lt;/strong&gt;﻿&lt;strong&gt;﻿&lt;/strong&gt;﻿table but instead using both hands to grab onto his muffin. So he put his muffin down extended out his arms while leaning against the table and started shouting &amp;ldquo;Ah, ah, ah, eh?&amp;rdquo;. He was quite pleased with his accomplishment. He proceeded to show off his newly learned skill a few more times for good measure.&lt;/p&gt;
&lt;p&gt;Words are but a hindrance to effective communication. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>My younger son (16 months) can&rsquo;t speak any words yet but he has no problems expressing himself by pointing and grunting. When he&rsquo;s hungry he whines and points to the pantry. When he wants a specific fruit out of the fridge he will reject all the other ones with a head shake and sometimes a shove until I offer him the right fruit. </p>
<p>This morning I witnessed him do a gesture that can only be construed as &ldquo;Look ma no hands&rdquo;. We were at the coffee shop and he was standing on his chair and leaning against the table and taking bites out his muffin. Suddenly he realized he wasn&rsquo;t holding onto the <strong>﻿</strong>﻿<strong>﻿</strong>﻿<strong>﻿</strong>﻿<strong>﻿</strong>﻿<strong>﻿</strong>﻿table but instead using both hands to grab onto his muffin. So he put his muffin down extended out his arms while leaning against the table and started shouting &ldquo;Ah, ah, ah, eh?&rdquo;. He was quite pleased with his accomplishment. He proceeded to show off his newly learned skill a few more times for good measure.</p>
<p>Words are but a hindrance to effective communication. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Classical Music - Getting Started</title>
      <link>https://amjith.com/blog/classical-music-getting-started/</link>
      <pubDate>Tue, 12 Sep 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/classical-music-getting-started/</guid>
      <description>&lt;p&gt;I started listening to classical music in my late 20s. Violin pieces are my favorite. I started with classical because I needed music without words while I programmed. Nowadays I listen to it for the pure joy of listening. &lt;/p&gt;
&lt;p&gt;I got started with Vivaldi&amp;rsquo;s Four Seasons. I thought that was the best piece of music ever conceived by humans. I used to argue with my wife (a music major) about how Vivaldi was better than Tchaikovsky. I was mostly naive and a little bit arrogant. She mostly shook her head in disbelief and let me ramble on. But since then I&amp;rsquo;ve changed some of my opinions and I&amp;rsquo;d like to think that I have a bit more nuanced taste.&lt;/p&gt;
&lt;p&gt;If you&amp;rsquo;re interested in getting started with classical music here&amp;rsquo;s a quick list of awesome pieces to get you started.&lt;/p&gt;
&lt;p&gt;Concerto, is a musical piece designed for one leading instrument accompanied by an orchestra. There are Violin Concertos, Cello Concertos, Viola Concertos, Piano Concertos etc. Concerto typically has three movements. The first and last movements are typically fast-paced and the second movement is usually slower.&lt;/p&gt;
&lt;p&gt;Symphony, is a musical piece designed to be played by an entire orchestra. Symphonies typically have four movements. They are a lot more elaborate than concertos.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;1. Vivaldi&amp;rsquo;s Four Seasons&lt;/strong&gt; - &lt;a href=&#34;https://open.spotify.com/album/6cU96XWKG0pjrh3jBrx4zE&#34;&gt;Spotify&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This is a collection of four violin concertos. My favorite is Summer. The third movement of the Summer concerto is just absolutely fantastic.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;2. Beethoven&amp;rsquo;s Fur Elise&lt;/strong&gt; - &lt;a href=&#34;https://open.spotify.com/track/5yWClRIxwId7cl0WSboGUk&#34;&gt;Spotify&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This is a solo piano piece. This is a very popular piece that is easily recognizable. It is vivacious and soothing.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;3. Mozart&amp;rsquo;s Symphony #40&lt;/strong&gt; - &lt;a href=&#34;https://open.spotify.com/album/4BJ5om5aruwSiU5oK8TEUD&#34;&gt;Spotify&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This is a popular symphony by Mozart that is easy to follow and pleasant to listen.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;4. Czardas&lt;/strong&gt; - &lt;a href=&#34;https://open.spotify.com/track/1k8q0uKc3m9uX35XgHhLGI&#34; title=&#34;Link: https://open.spotify.com/track/1k8q0uKc3m9uX35XgHhLGI&#34;&gt;Spotify&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This is a gypsy violin piece. I absolutely love this piece. It starts slow and methodical then bursts into this flame of rapid fire. It is fun to watch this being played. Try finding a video of a violinist on Youtube. It is worth a watch. :)&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;5. Carmen Fantasy by Sarasate&lt;/strong&gt; - &lt;a href=&#34;https://open.spotify.com/track/6PlmHi3MDzJ25bj1t0dgKl&#34; title=&#34;Link: https://open.spotify.com/track/6PlmHi3MDzJ25bj1t0dgKl&#34;&gt;Spotify&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Pablo Sarasate, the composer of this piece is a fantastic Violinist himself. He has many wonderful pieces that are an absolute joy to listen (such as zigeunerweisen, zapateado etc). Carmen Fantasy is one of those flashy pieces that is hard to play and wonderful to listen.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;6. Elgar&amp;rsquo;s Cello Concerto&lt;/strong&gt; - &lt;a href=&#34;https://open.spotify.com/album/4cIcY14P7NSdOvpW1wJMev&#34;&gt;Spotify&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Cello is the big brother of Violin with a deep soothing voice. There are many popular Cello pieces (such as Dvorak&amp;rsquo;s Cello Concerto) but Elgar&amp;rsquo;s cello concerto showcases the beauty and range of a cello. Especially this piece played by Jacquline Du Pre is just moving. Even though this is a concerto it has four movements instead of the typical three.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;7. Swan Lake by Tchaikovsky&lt;/strong&gt; - &lt;a href=&#34;https://open.spotify.com/album/2EMupCrqS9QaibuytOJWmb&#34;&gt;Spotify&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Swan Lake is a very famous ballet piece composed by Tchaikovsky. Ballet pieces are quite long since they are telling you a story and they last for a couple of hours. I&amp;rsquo;ve linked only the Swan Lake Suite which is a select few pieces from the ballet that represents the character of the whole piece.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;8. Hungarian Dances by Brahms&lt;/strong&gt; - &lt;a href=&#34;https://open.spotify.com/album/4ItbBO7SVJLn7HU6BXrmKV&#34; title=&#34;Link: https://open.spotify.com/album/4ItbBO7SVJLn7HU6BXrmKV&#34;&gt;Spotify&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m not doing justice to Brahms by choosing Hungarian Dances. It is a light hearted collection of dance pieces that are upbeat and jolly. But Brahms&#39; usual style is very heavy. His violin concerto is a good example of the weight of his compositions. I chose Hungarian dances because it was one of those collections that got me hooked into classical music early on. The popular ones from this collection are Dance #1, #3, #5, #6. My absolute favorite is #5. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;9. Beethoven&amp;rsquo;s Ninth Symphony&lt;/strong&gt; - &lt;a href=&#34;https://open.spotify.com/album/7Gj0QINJxVFSfWL6v0Wyp2&#34; title=&#34;Link: https://open.spotify.com/album/7Gj0QINJxVFSfWL6v0Wyp2&#34;&gt;Spotify&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Beethoven has a lot of popular symphonies (3rd, 5th and 9th). But his ninth symphony is ground breaking. It is majestic and powerful. It starts out a bit soft and slow. But it builds up to this wonderful enormous piece. If you like this style, you should consider listening to his 5th Symphony which is also a powerful symphony and equally popular.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;10. Carmina Burana&lt;/strong&gt; - &lt;a href=&#34;https://open.spotify.com/track/0DHIkKybRhYScZkGQU8XTL&#34;&gt;Spotify&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;You have already heard this piece, trust me. Whenever movies want to show something epic they always choose this piece to accompany the visual. &lt;/p&gt;
&lt;p&gt;This is not a definitive list or a complete list by any stretch of the imagination. I&amp;rsquo;ve just chosen a few pieces that I like and that are easily accessible. There are more intricate and delightful composers that I have ommited (eg: Sibelius, Mendelssohn, Dvorak etc). Perhaps I&amp;rsquo;ll do this more often if there is interest.&lt;/p&gt;
&lt;p&gt;I would love to hear your feedback or suggestions about pieces that I&amp;rsquo;ve missed or pieces that you enjoyed from the list. Feel free to tweet me &lt;a href=&#34;https://twitter.com/amjithr&#34;&gt;@amjithr&lt;/a&gt;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I started listening to classical music in my late 20s. Violin pieces are my favorite. I started with classical because I needed music without words while I programmed. Nowadays I listen to it for the pure joy of listening. </p>
<p>I got started with Vivaldi&rsquo;s Four Seasons. I thought that was the best piece of music ever conceived by humans. I used to argue with my wife (a music major) about how Vivaldi was better than Tchaikovsky. I was mostly naive and a little bit arrogant. She mostly shook her head in disbelief and let me ramble on. But since then I&rsquo;ve changed some of my opinions and I&rsquo;d like to think that I have a bit more nuanced taste.</p>
<p>If you&rsquo;re interested in getting started with classical music here&rsquo;s a quick list of awesome pieces to get you started.</p>
<p>Concerto, is a musical piece designed for one leading instrument accompanied by an orchestra. There are Violin Concertos, Cello Concertos, Viola Concertos, Piano Concertos etc. Concerto typically has three movements. The first and last movements are typically fast-paced and the second movement is usually slower.</p>
<p>Symphony, is a musical piece designed to be played by an entire orchestra. Symphonies typically have four movements. They are a lot more elaborate than concertos.</p>
<p><strong>1. Vivaldi&rsquo;s Four Seasons</strong> - <a href="https://open.spotify.com/album/6cU96XWKG0pjrh3jBrx4zE">Spotify</a></p>
<p>This is a collection of four violin concertos. My favorite is Summer. The third movement of the Summer concerto is just absolutely fantastic.</p>
<p><strong>2. Beethoven&rsquo;s Fur Elise</strong> - <a href="https://open.spotify.com/track/5yWClRIxwId7cl0WSboGUk">Spotify</a></p>
<p>This is a solo piano piece. This is a very popular piece that is easily recognizable. It is vivacious and soothing.</p>
<p><strong>3. Mozart&rsquo;s Symphony #40</strong> - <a href="https://open.spotify.com/album/4BJ5om5aruwSiU5oK8TEUD">Spotify</a></p>
<p>This is a popular symphony by Mozart that is easy to follow and pleasant to listen.</p>
<p><strong>4. Czardas</strong> - <a href="https://open.spotify.com/track/1k8q0uKc3m9uX35XgHhLGI" title="Link: https://open.spotify.com/track/1k8q0uKc3m9uX35XgHhLGI">Spotify</a></p>
<p>This is a gypsy violin piece. I absolutely love this piece. It starts slow and methodical then bursts into this flame of rapid fire. It is fun to watch this being played. Try finding a video of a violinist on Youtube. It is worth a watch. :)</p>
<p><strong>5. Carmen Fantasy by Sarasate</strong> - <a href="https://open.spotify.com/track/6PlmHi3MDzJ25bj1t0dgKl" title="Link: https://open.spotify.com/track/6PlmHi3MDzJ25bj1t0dgKl">Spotify</a></p>
<p>Pablo Sarasate, the composer of this piece is a fantastic Violinist himself. He has many wonderful pieces that are an absolute joy to listen (such as zigeunerweisen, zapateado etc). Carmen Fantasy is one of those flashy pieces that is hard to play and wonderful to listen.</p>
<p><strong>6. Elgar&rsquo;s Cello Concerto</strong> - <a href="https://open.spotify.com/album/4cIcY14P7NSdOvpW1wJMev">Spotify</a></p>
<p>Cello is the big brother of Violin with a deep soothing voice. There are many popular Cello pieces (such as Dvorak&rsquo;s Cello Concerto) but Elgar&rsquo;s cello concerto showcases the beauty and range of a cello. Especially this piece played by Jacquline Du Pre is just moving. Even though this is a concerto it has four movements instead of the typical three.</p>
<p><strong>7. Swan Lake by Tchaikovsky</strong> - <a href="https://open.spotify.com/album/2EMupCrqS9QaibuytOJWmb">Spotify</a></p>
<p>Swan Lake is a very famous ballet piece composed by Tchaikovsky. Ballet pieces are quite long since they are telling you a story and they last for a couple of hours. I&rsquo;ve linked only the Swan Lake Suite which is a select few pieces from the ballet that represents the character of the whole piece.</p>
<p><strong>8. Hungarian Dances by Brahms</strong> - <a href="https://open.spotify.com/album/4ItbBO7SVJLn7HU6BXrmKV" title="Link: https://open.spotify.com/album/4ItbBO7SVJLn7HU6BXrmKV">Spotify</a></p>
<p>I&rsquo;m not doing justice to Brahms by choosing Hungarian Dances. It is a light hearted collection of dance pieces that are upbeat and jolly. But Brahms' usual style is very heavy. His violin concerto is a good example of the weight of his compositions. I chose Hungarian dances because it was one of those collections that got me hooked into classical music early on. The popular ones from this collection are Dance #1, #3, #5, #6. My absolute favorite is #5. </p>
<p><strong>9. Beethoven&rsquo;s Ninth Symphony</strong> - <a href="https://open.spotify.com/album/7Gj0QINJxVFSfWL6v0Wyp2" title="Link: https://open.spotify.com/album/7Gj0QINJxVFSfWL6v0Wyp2">Spotify</a></p>
<p>Beethoven has a lot of popular symphonies (3rd, 5th and 9th). But his ninth symphony is ground breaking. It is majestic and powerful. It starts out a bit soft and slow. But it builds up to this wonderful enormous piece. If you like this style, you should consider listening to his 5th Symphony which is also a powerful symphony and equally popular.</p>
<p><strong>10. Carmina Burana</strong> - <a href="https://open.spotify.com/track/0DHIkKybRhYScZkGQU8XTL">Spotify</a></p>
<p>You have already heard this piece, trust me. Whenever movies want to show something epic they always choose this piece to accompany the visual. </p>
<p>This is not a definitive list or a complete list by any stretch of the imagination. I&rsquo;ve just chosen a few pieces that I like and that are easily accessible. There are more intricate and delightful composers that I have ommited (eg: Sibelius, Mendelssohn, Dvorak etc). Perhaps I&rsquo;ll do this more often if there is interest.</p>
<p>I would love to hear your feedback or suggestions about pieces that I&rsquo;ve missed or pieces that you enjoyed from the list. Feel free to tweet me <a href="https://twitter.com/amjithr">@amjithr</a></p>
]]></content:encoded>
    </item>
    
    <item>
      <title>New and Improved</title>
      <link>https://amjith.com/blog/new-and-improved/</link>
      <pubDate>Wed, 26 Jul 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/new-and-improved/</guid>
      <description>&lt;p&gt;Vian is eating dates that I bought from the Indian store. He seems to be a fan. I take another date out of the package for myself. Vian intercepts my new date even though his mouth is full. I&amp;rsquo;m curious to see his next action. He takes the old date out of his mouth and shoves it into my mouth and then proceeds to eat his new one. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian is eating dates that I bought from the Indian store. He seems to be a fan. I take another date out of the package for myself. Vian intercepts my new date even though his mouth is full. I&rsquo;m curious to see his next action. He takes the old date out of his mouth and shoves it into my mouth and then proceeds to eat his new one. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 4 year old</title>
      <link>https://amjith.com/blog/conversations-with-a-4-year-old/</link>
      <pubDate>Sun, 11 Jun 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-4-year-old/</guid>
      <description>&lt;p&gt;We were sitting at a restaurant eating brunch. Yoshi got Calamari which was served with a lemon. Sempi is sipping his orange juice. Suddenly he drops this pearl of wisdom. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Why do we call an orange, orange but don&amp;rsquo;t call a lemon, yellow?&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Yoshi and I both choked on our food from laughing so hard.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We were sitting at a restaurant eating brunch. Yoshi got Calamari which was served with a lemon. Sempi is sipping his orange juice. Suddenly he drops this pearl of wisdom. </p>
<p><strong>Why do we call an orange, orange but don&rsquo;t call a lemon, yellow?</strong></p>
<p>Yoshi and I both choked on our food from laughing so hard.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Tugging at Heartstrings</title>
      <link>https://amjith.com/blog/tugging-at-heartstrings/</link>
      <pubDate>Sun, 14 May 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/tugging-at-heartstrings/</guid>
      <description>&lt;p&gt;We&amp;rsquo;re all having dinner as a family.&lt;/p&gt;
&lt;p&gt;Sempi is complaining about the food. He eats a little, here and there. Yoshi warns him to eat well or he might get hungry later. He doesn&amp;rsquo;t pay any attention. &lt;/p&gt;
&lt;p&gt;Dinner is over and he&amp;rsquo;s ready for bed. Yoshi is reading him a story. Sempi declares he&amp;rsquo;s hungry now.&lt;/p&gt;
&lt;p&gt;Yoshi: You should have eaten well when we were all having dinner.&lt;/p&gt;
&lt;p&gt;Sempi: I&amp;rsquo;m hungry. &lt;/p&gt;
&lt;p&gt;Yoshi: It&amp;rsquo;s not dinner time. We just brushed your teeth. Go to sleep Sempi.&lt;/p&gt;
&lt;p&gt;Sempi: I don&amp;rsquo;t know why you&amp;rsquo;re making me starve.&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Naturally, he&amp;rsquo;s now out of the bedroom eating an orange. &lt;/p&gt;
&lt;p&gt;The boy just has a way with words. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We&rsquo;re all having dinner as a family.</p>
<p>Sempi is complaining about the food. He eats a little, here and there. Yoshi warns him to eat well or he might get hungry later. He doesn&rsquo;t pay any attention. </p>
<p>Dinner is over and he&rsquo;s ready for bed. Yoshi is reading him a story. Sempi declares he&rsquo;s hungry now.</p>
<p>Yoshi: You should have eaten well when we were all having dinner.</p>
<p>Sempi: I&rsquo;m hungry. </p>
<p>Yoshi: It&rsquo;s not dinner time. We just brushed your teeth. Go to sleep Sempi.</p>
<p>Sempi: I don&rsquo;t know why you&rsquo;re making me starve.</p>
<hr>
<p>Naturally, he&rsquo;s now out of the bedroom eating an orange. </p>
<p>The boy just has a way with words. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Goodbye, Portland</title>
      <link>https://amjith.com/blog/goodbye-portland/</link>
      <pubDate>Sun, 23 Apr 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/goodbye-portland/</guid>
      <description>&lt;p&gt;It was a dark and stormy evening. The rain was pouring down. A young couple pulled into an apartment complex in the middle of Portland. The wife was pregnant and the husband was clueless (as always). Despite his cluelessness, they thrived in the city. They made new friends and established their roots. The husband sprouted gray hairs and the wife grew motherly. Before they knew it, five years have gone by. With a new kid in tow and a toddler running ahead, they&amp;rsquo;re off to a new city to start anew.&lt;/p&gt;
&lt;p&gt;For anyone confused by that paragraph, that&amp;rsquo;s my way of saying we&amp;rsquo;re no longer in Portland. I&amp;rsquo;m incredibly thankful to NewRelic for bringing me to Portland and raising me into an adult. I&amp;rsquo;ve forged friendships that&amp;rsquo;ll last my lifetime. I created things that marked my name in the sand. I found a mentor who accelerated my career growth. I met coworkers who became best friends and confidants. I met humans who were caring and helpful. Thank you Portland, for enriching our lives. &lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m off to the Bay Area to work for Netflix. I&amp;rsquo;m sure the future holds wonderful opportunities, I&amp;rsquo;ll always remember Portland as the city that doubled our family. Once a hippie, always &amp;hellip;.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1866985/2_n_YjDxA73wrEvm51BFSwg7bYc/large_IMG_20170309_105019.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>It was a dark and stormy evening. The rain was pouring down. A young couple pulled into an apartment complex in the middle of Portland. The wife was pregnant and the husband was clueless (as always). Despite his cluelessness, they thrived in the city. They made new friends and established their roots. The husband sprouted gray hairs and the wife grew motherly. Before they knew it, five years have gone by. With a new kid in tow and a toddler running ahead, they&rsquo;re off to a new city to start anew.</p>
<p>For anyone confused by that paragraph, that&rsquo;s my way of saying we&rsquo;re no longer in Portland. I&rsquo;m incredibly thankful to NewRelic for bringing me to Portland and raising me into an adult. I&rsquo;ve forged friendships that&rsquo;ll last my lifetime. I created things that marked my name in the sand. I found a mentor who accelerated my career growth. I met coworkers who became best friends and confidants. I met humans who were caring and helpful. Thank you Portland, for enriching our lives. </p>
<p>I&rsquo;m off to the Bay Area to work for Netflix. I&rsquo;m sure the future holds wonderful opportunities, I&rsquo;ll always remember Portland as the city that doubled our family. Once a hippie, always &hellip;.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1866985/2_n_YjDxA73wrEvm51BFSwg7bYc/large_IMG_20170309_105019.jpg" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Stealing words</title>
      <link>https://amjith.com/blog/stealing-words/</link>
      <pubDate>Sat, 04 Mar 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/stealing-words/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m playing Tamil songs on the computer and busting my &lt;a href=&#34;https://amjith.com/blog/dancing-with-the-dorks&#34;&gt;moves&lt;/a&gt;. &lt;/p&gt;
&lt;p&gt;Sempi: Appa why does this song keep saying &amp;lsquo;poop&amp;rsquo;.&lt;/p&gt;
&lt;p&gt;Me: Haha. It&amp;rsquo;s not saying &amp;lsquo;Poop&amp;rsquo;, it&amp;rsquo;s saying &amp;lsquo;poo&amp;rsquo;. I guess that&amp;rsquo;s not any better. In Tamil &amp;lsquo;Poo&amp;rsquo; means flower. They&amp;rsquo;re singing about a flower.&lt;/p&gt;
&lt;p&gt;Sempi: &amp;lsquo;Poo&amp;rsquo; means flower? &lt;/p&gt;
&lt;p&gt;Me: Yeah. But to be fair we had that word a long time before English. English stole it from us. &lt;/p&gt;
&lt;p&gt;Sempi: How do you steal words? &lt;/p&gt;
&lt;p&gt;Me: Ok. I was just kidding. Tamil people heard the sound &amp;lsquo;poo&amp;rsquo; and decided it&amp;rsquo;s such a beautiful sound, we&amp;rsquo;ll use it to mean flower. English people heard the same sound and figured it&amp;rsquo;s a fitting word for excrement.&lt;/p&gt;
&lt;p&gt;Sempi: What&amp;rsquo;s excrement? &lt;/p&gt;
&lt;p&gt;Me: Sigh&amp;hellip;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;m playing Tamil songs on the computer and busting my <a href="https://amjith.com/blog/dancing-with-the-dorks">moves</a>. </p>
<p>Sempi: Appa why does this song keep saying &lsquo;poop&rsquo;.</p>
<p>Me: Haha. It&rsquo;s not saying &lsquo;Poop&rsquo;, it&rsquo;s saying &lsquo;poo&rsquo;. I guess that&rsquo;s not any better. In Tamil &lsquo;Poo&rsquo; means flower. They&rsquo;re singing about a flower.</p>
<p>Sempi: &lsquo;Poo&rsquo; means flower? </p>
<p>Me: Yeah. But to be fair we had that word a long time before English. English stole it from us. </p>
<p>Sempi: How do you steal words? </p>
<p>Me: Ok. I was just kidding. Tamil people heard the sound &lsquo;poo&rsquo; and decided it&rsquo;s such a beautiful sound, we&rsquo;ll use it to mean flower. English people heard the same sound and figured it&rsquo;s a fitting word for excrement.</p>
<p>Sempi: What&rsquo;s excrement? </p>
<p>Me: Sigh&hellip;</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Dancing with the dorks</title>
      <link>https://amjith.com/blog/dancing-with-the-dorks/</link>
      <pubDate>Fri, 03 Mar 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/dancing-with-the-dorks/</guid>
      <description>&lt;p&gt;Early Wednesday morning. I&amp;rsquo;m entertaining both Sempi and Vian. I start to play some music (Tamil songs) and decided to dance. Sempi reaches for his ear muffs and Vian starts to bounce to the music. &lt;/p&gt;
&lt;p&gt;I have the sudden realization that both the kids are doomed to be dorks if they&amp;rsquo;re learning dance moves from me. Naturally, I start dancing harder. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Early Wednesday morning. I&rsquo;m entertaining both Sempi and Vian. I start to play some music (Tamil songs) and decided to dance. Sempi reaches for his ear muffs and Vian starts to bounce to the music. </p>
<p>I have the sudden realization that both the kids are doomed to be dorks if they&rsquo;re learning dance moves from me. Naturally, I start dancing harder. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Facts about a 9 month old</title>
      <link>https://amjith.com/blog/facts-about-a-9-month-old/</link>
      <pubDate>Sun, 19 Feb 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/facts-about-a-9-month-old/</guid>
      <description>&lt;p&gt;These facts are based on a sample size of one 9 month old.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;9-month-olds can eat 3 whole grapes before they get bored of it.&lt;/li&gt;
&lt;li&gt;9-month-olds can go from smiling to crying in 5 seconds flat. I&amp;rsquo;ve also managed to reverse this reaction in 5 seconds. Once!&lt;/li&gt;
&lt;li&gt;9-month-olds have no sense of personal hygiene. If you try to kiss them on their cheeks, they can turn their head at the last second and slobber all over your mouth.&lt;/li&gt;
&lt;li&gt;If you give them an avocado to eat, make sure to wash their hair afterward. Avocado leaks out of their hair and all over their face.&lt;/li&gt;
&lt;li&gt;9-month-olds are dramatic. They are emotionally moved when you pluck them out of their mother&amp;rsquo;s hand. They cry out in joy for saving them. With tears flowing down their chubby cheeks.&lt;/li&gt;
&lt;li&gt;9-month-olds are thrill seekers. Even though they can&amp;rsquo;t walk to save their lives, they will try to launch themselves down the stairs or climb up tables.&lt;/li&gt;
&lt;/ul&gt;
</description>
      <content:encoded><![CDATA[<p>These facts are based on a sample size of one 9 month old.</p>
<ul>
<li>9-month-olds can eat 3 whole grapes before they get bored of it.</li>
<li>9-month-olds can go from smiling to crying in 5 seconds flat. I&rsquo;ve also managed to reverse this reaction in 5 seconds. Once!</li>
<li>9-month-olds have no sense of personal hygiene. If you try to kiss them on their cheeks, they can turn their head at the last second and slobber all over your mouth.</li>
<li>If you give them an avocado to eat, make sure to wash their hair afterward. Avocado leaks out of their hair and all over their face.</li>
<li>9-month-olds are dramatic. They are emotionally moved when you pluck them out of their mother&rsquo;s hand. They cry out in joy for saving them. With tears flowing down their chubby cheeks.</li>
<li>9-month-olds are thrill seekers. Even though they can&rsquo;t walk to save their lives, they will try to launch themselves down the stairs or climb up tables.</li>
</ul>
]]></content:encoded>
    </item>
    
    <item>
      <title>In defense of GPL</title>
      <link>https://amjith.com/blog/in-defense-of-gpl/</link>
      <pubDate>Sun, 12 Feb 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/in-defense-of-gpl/</guid>
      <description>&lt;p&gt;When I first started coding, GPL used to be the most popular license for open source projects. It was the go to license for someone dipping their toe in the FOSS world unless you&amp;rsquo;re developing software for FreeBSD.&lt;/p&gt;
&lt;p&gt;But over the past few years, companies have pulled a brilliant coup d&amp;rsquo;état and convinced the up and coming programmers that GPL is a virus. If you release your software in anything other than MIT or BSD license the programming community looks down upon that contribution.&lt;/p&gt;
&lt;p&gt;Recently I&amp;rsquo;ve been seeing a lot of open source maintainers complaining about companies that use their software and demand bug fixes or features but hardly contribute any code or money towards their projects. &lt;/p&gt;
&lt;p&gt;This is the exact problem that GPL was designed to solve. If a company finds value in your code and decide to build upon it, they can either contribute back to the community by making their product open source or pay you for an alternative license that allows them to keep their code closed source.&lt;/p&gt;
&lt;p&gt;OpenSource is Socialism. People do OpenSource because they enjoy doing it or they stepped up to fill a need. In a socialistic community, you&amp;rsquo;re not paid for the end product and sharing (or forking) is encouraged. But commercial companies operate on the principle of Capitalism. They&amp;rsquo;re trying to maximize their shareholder&amp;rsquo;s value. Trying to appeal to a capitalist entity to support a socialist endeavor will not work. This is the reason why GPL is designed the way it is. GPL protects the OpenSource source ecosystem from the exploitation of capitalist entities.&lt;/p&gt;
&lt;p&gt;But somehow the programming community decided that permissive licenses are the way forward. This is further encouraged by commercial companies because now they can use all this quality software without paying a penny or contributing back to the community. This erodes the OpenSource ecosystem in the long run because we are building software on the ashes of thousands of burnt out programmers.&lt;/p&gt;
&lt;p&gt;This is where we arrive at a fork in our journey. &lt;/p&gt;
&lt;p&gt;**Should we all use GPL?**&lt;strong&gt;No.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;If you&amp;rsquo;re doing OpenSource because you love what you do and want to see your work used by as many people as possible, go with a more permissive license. But don&amp;rsquo;t expect companies or users to pay for the product. This is never going to work.&lt;/p&gt;
&lt;p&gt;There is nothing wrong with trying to make a living through OpenSource. Dual licensing with GPL + paid commercial license is a fantastic option. Don&amp;rsquo;t succumb to the ivory tower programmers who demand all OpenSource software must be permissively licensed. If a company wants to build their profits from your software, there is nothing wrong with asking them to pay your fair share.&lt;/p&gt;
&lt;p&gt;If you do take the more permissive license route, take care of your mental health and take steps to prevent burnout. Because whether you like it or not it&amp;rsquo;s coming.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>When I first started coding, GPL used to be the most popular license for open source projects. It was the go to license for someone dipping their toe in the FOSS world unless you&rsquo;re developing software for FreeBSD.</p>
<p>But over the past few years, companies have pulled a brilliant coup d&rsquo;état and convinced the up and coming programmers that GPL is a virus. If you release your software in anything other than MIT or BSD license the programming community looks down upon that contribution.</p>
<p>Recently I&rsquo;ve been seeing a lot of open source maintainers complaining about companies that use their software and demand bug fixes or features but hardly contribute any code or money towards their projects. </p>
<p>This is the exact problem that GPL was designed to solve. If a company finds value in your code and decide to build upon it, they can either contribute back to the community by making their product open source or pay you for an alternative license that allows them to keep their code closed source.</p>
<p>OpenSource is Socialism. People do OpenSource because they enjoy doing it or they stepped up to fill a need. In a socialistic community, you&rsquo;re not paid for the end product and sharing (or forking) is encouraged. But commercial companies operate on the principle of Capitalism. They&rsquo;re trying to maximize their shareholder&rsquo;s value. Trying to appeal to a capitalist entity to support a socialist endeavor will not work. This is the reason why GPL is designed the way it is. GPL protects the OpenSource source ecosystem from the exploitation of capitalist entities.</p>
<p>But somehow the programming community decided that permissive licenses are the way forward. This is further encouraged by commercial companies because now they can use all this quality software without paying a penny or contributing back to the community. This erodes the OpenSource ecosystem in the long run because we are building software on the ashes of thousands of burnt out programmers.</p>
<p>This is where we arrive at a fork in our journey. </p>
<p>**Should we all use GPL?**<strong>No.</strong></p>
<p>If you&rsquo;re doing OpenSource because you love what you do and want to see your work used by as many people as possible, go with a more permissive license. But don&rsquo;t expect companies or users to pay for the product. This is never going to work.</p>
<p>There is nothing wrong with trying to make a living through OpenSource. Dual licensing with GPL + paid commercial license is a fantastic option. Don&rsquo;t succumb to the ivory tower programmers who demand all OpenSource software must be permissively licensed. If a company wants to build their profits from your software, there is nothing wrong with asking them to pay your fair share.</p>
<p>If you do take the more permissive license route, take care of your mental health and take steps to prevent burnout. Because whether you like it or not it&rsquo;s coming.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Maintainer Stories</title>
      <link>https://amjith.com/blog/maintainer-stories/</link>
      <pubDate>Tue, 07 Feb 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/maintainer-stories/</guid>
      <description>&lt;p&gt;Github produced a video series called &amp;ldquo;&lt;a href=&#34;https://github.com/open-source/stories&#34;&gt;Maintainer Stories&lt;/a&gt;&amp;rdquo;. One of the videos is about my experiences as a maintainer of &lt;a href=&#34;http://pgcli.com&#34;&gt;pgcli&lt;/a&gt;. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Github produced a video series called &ldquo;<a href="https://github.com/open-source/stories">Maintainer Stories</a>&rdquo;. One of the videos is about my experiences as a maintainer of <a href="http://pgcli.com">pgcli</a>. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 4 yo</title>
      <link>https://amjith.com/blog/conversations-with-a-4-yo/</link>
      <pubDate>Sun, 05 Feb 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-4-yo/</guid>
      <description>&lt;p&gt;Sempi: Appa, I&amp;rsquo;m making hot dogs. Do you want one? &lt;/p&gt;
&lt;p&gt;Me: Yes! How much is it? Eight dollars or Fifty Three dollars?&lt;/p&gt;
&lt;p&gt;Sempi: Appa, you can&amp;rsquo;t make up numbers. It is eight dollars.&lt;/p&gt;
&lt;p&gt;ps: He can count up to ten. It gets fuzzy after that.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi: Appa, I&rsquo;m making hot dogs. Do you want one? </p>
<p>Me: Yes! How much is it? Eight dollars or Fifty Three dollars?</p>
<p>Sempi: Appa, you can&rsquo;t make up numbers. It is eight dollars.</p>
<p>ps: He can count up to ten. It gets fuzzy after that.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Classical music geeks</title>
      <link>https://amjith.com/blog/classical-music-geeks/</link>
      <pubDate>Fri, 27 Jan 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/classical-music-geeks/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m a bit of a classical string instruments nerd. I can&amp;rsquo;t pay any instrument but I listen to classical music a lot.&lt;/p&gt;
&lt;p&gt;Sempi and I like to name our trucks. Sempi goes for the classics like Mary Anne and Mike Mulligan. I usually go for Jacquline Du Pre, Yoyo Ma and Stradivarius. &lt;/p&gt;
&lt;p&gt;Me: So Yoyo Ma is driving the Stradivarius (the dump truck) and Jacquline Du Pre is digging the dirt with Guarneri (the excavator).&lt;/p&gt;
&lt;p&gt;Sempi: Appa, Mike Mulligan and Mary Anne are driving up the hill and coming to the construction site.&lt;/p&gt;
&lt;p&gt;Me: Paganini (the steam roller) is flattening the road. Perlman and Heifetz are pouring the concrete. &lt;/p&gt;
&lt;p&gt;&lt;em&gt;Sempi**starts struggling with the names at this point.&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Sempi: What should we name our back hoe. &lt;/p&gt;
&lt;p&gt;Me: How about Beethoven? &lt;/p&gt;
&lt;p&gt;Sempi: Ok, we&amp;rsquo;ll call it Beethoven Backhoei. But we&amp;rsquo;ll use Backhoei for short. What do you think? &lt;/p&gt;
&lt;p&gt;Me: Nice try buddy, we&amp;rsquo;re calling our backhoe, Beethoven.&lt;/p&gt;
&lt;p&gt;My hope is that by the time he starts taking Cello lessons, he&amp;rsquo;s already used to the names of big wigs.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;m a bit of a classical string instruments nerd. I can&rsquo;t pay any instrument but I listen to classical music a lot.</p>
<p>Sempi and I like to name our trucks. Sempi goes for the classics like Mary Anne and Mike Mulligan. I usually go for Jacquline Du Pre, Yoyo Ma and Stradivarius. </p>
<p>Me: So Yoyo Ma is driving the Stradivarius (the dump truck) and Jacquline Du Pre is digging the dirt with Guarneri (the excavator).</p>
<p>Sempi: Appa, Mike Mulligan and Mary Anne are driving up the hill and coming to the construction site.</p>
<p>Me: Paganini (the steam roller) is flattening the road. Perlman and Heifetz are pouring the concrete. </p>
<p><em>Sempi**starts struggling with the names at this point.</em></p>
<p>Sempi: What should we name our back hoe. </p>
<p>Me: How about Beethoven? </p>
<p>Sempi: Ok, we&rsquo;ll call it Beethoven Backhoei. But we&rsquo;ll use Backhoei for short. What do you think? </p>
<p>Me: Nice try buddy, we&rsquo;re calling our backhoe, Beethoven.</p>
<p>My hope is that by the time he starts taking Cello lessons, he&rsquo;s already used to the names of big wigs.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations about an 8 month old</title>
      <link>https://amjith.com/blog/conversations-about-an-8-month-old/</link>
      <pubDate>Fri, 27 Jan 2017 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-about-an-8-month-old/</guid>
      <description>&lt;p&gt;Vian is starting to pull himself up. He stood up and tried to grab everything in his reach. &lt;/p&gt;
&lt;p&gt;Me: We shouldn&amp;rsquo;t keep the water cup here. Vian might grab it.&lt;/p&gt;
&lt;p&gt;Yoshi: We just have to keep an eye on him. You might think he has tiny T-Rex hands, but nooo. He&amp;rsquo;s more like an octopus with tentacles.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian is starting to pull himself up. He stood up and tried to grab everything in his reach. </p>
<p>Me: We shouldn&rsquo;t keep the water cup here. Vian might grab it.</p>
<p>Yoshi: We just have to keep an eye on him. You might think he has tiny T-Rex hands, but nooo. He&rsquo;s more like an octopus with tentacles.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Alphabet Race - a kid&#39;s game</title>
      <link>https://amjith.com/blog/alphabet-race-a-kids-game/</link>
      <pubDate>Mon, 26 Dec 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/alphabet-race-a-kids-game/</guid>
      <description>&lt;p&gt;TL;DR: I built a little truck &amp;ldquo;&lt;a href=&#34;http://alphabetrace.itsybits.xyz/&#34;&gt;game&lt;/a&gt;&amp;rdquo; to teach my son alphabets.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1817912/5ZR5tcdhp9h8B0RvMGt5OqfzwfU/large_Truck_Race__.png&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I started watching &lt;a href=&#34;http://javascript30.com&#34; title=&#34;Link: http://javascript30.com&#34;&gt;http://javascript30.com&lt;/a&gt; a couple of days ago. It&amp;rsquo;s a series of 30 videos that uses vanilla Javascript to do amazing things.&lt;/p&gt;
&lt;p&gt;I have only done the first two videos in the series. Based on what I learned in those two videos, I decided to write a small game. My son is a fan of trucks, so I cobbled together a truck race that teaches him alphabets.&lt;/p&gt;
&lt;p&gt;The game is written using the latest version of Javascript. It will not work in old browsers (sorry). It is not designed for tablets or phones, you need a keyboard to play this game.&lt;/p&gt;
&lt;p&gt;Game: &lt;a href=&#34;http://alphabetrace.itsybits.xyz/&#34;&gt;http://alphabetrace.itsybits.xyz/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Source: &lt;a href=&#34;https://github.com/amjith/alphabet_race/&#34;&gt;https://github.com/amjith/alphabet_race/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;My goal was to create an educational game that is entertaining but not addictive. &lt;/p&gt;
&lt;p&gt;You can send me feedback about the game via &lt;a href=&#34;https://twitter.com/amjithr&#34;&gt;twitter&lt;/a&gt; or &lt;a href=&#34;mailto:alphabetrace@itsybits.xyz&#34;&gt;email&lt;/a&gt;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>TL;DR: I built a little truck &ldquo;<a href="http://alphabetrace.itsybits.xyz/">game</a>&rdquo; to teach my son alphabets.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1817912/5ZR5tcdhp9h8B0RvMGt5OqfzwfU/large_Truck_Race__.png" alt=""  />
</p>
<p>I started watching <a href="http://javascript30.com" title="Link: http://javascript30.com">http://javascript30.com</a> a couple of days ago. It&rsquo;s a series of 30 videos that uses vanilla Javascript to do amazing things.</p>
<p>I have only done the first two videos in the series. Based on what I learned in those two videos, I decided to write a small game. My son is a fan of trucks, so I cobbled together a truck race that teaches him alphabets.</p>
<p>The game is written using the latest version of Javascript. It will not work in old browsers (sorry). It is not designed for tablets or phones, you need a keyboard to play this game.</p>
<p>Game: <a href="http://alphabetrace.itsybits.xyz/">http://alphabetrace.itsybits.xyz/</a></p>
<p>Source: <a href="https://github.com/amjith/alphabet_race/">https://github.com/amjith/alphabet_race/</a></p>
<p>My goal was to create an educational game that is entertaining but not addictive. </p>
<p>You can send me feedback about the game via <a href="https://twitter.com/amjithr">twitter</a> or <a href="mailto:alphabetrace@itsybits.xyz">email</a>.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>&#39;Tis the season for giving</title>
      <link>https://amjith.com/blog/tis-the-season-for-giving/</link>
      <pubDate>Sat, 24 Dec 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/tis-the-season-for-giving/</guid>
      <description>&lt;p&gt;Some of you might know that I created a couple of &lt;a href=&#34;http://pgcli.com&#34; title=&#34;Link: http://pgcli.com&#34;&gt;open&lt;/a&gt; &lt;a href=&#34;http://mycli.net&#34; title=&#34;Link: http://mycli.net&#34;&gt;source&lt;/a&gt; projects that became successful.&lt;/p&gt;
&lt;p&gt;I added a &lt;a href=&#34;http://mycli.net/donate&#34;&gt;donate&lt;/a&gt; button to one of the project&amp;rsquo;s homepage. A couple of days ago, I received a donation through that link (thanks, &lt;a href=&#34;https://daniel-siepmann.de/&#34;&gt;Daniel&lt;/a&gt;). This is the second donation I&amp;rsquo;ve received since it&amp;rsquo;s inception. Needless to say, I was pleasantly surprised.&lt;/p&gt;
&lt;p&gt;My current job pays me well, so I decided to funnel the donation to the following charities. It&amp;rsquo;s a small sum ($15) but it had a big impact. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Solve Hunger:&lt;/strong&gt; &lt;a href=&#34;https://onetoday.google.com/p/pnvzxbtk&#34;&gt;https://onetoday.google.com/p/pnvzxbtk&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1817244/JtgGShY5dlY-U7vNG9biBz4uhec/large_hunger.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;$5 to provide 4 meals for 5 school children.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Nepal Earthquake:&lt;/strong&gt; &lt;a href=&#34;https://onetoday.google.com/p/mjsxg_gq&#34;&gt;https://onetoday.google.com/p/mjsxg_gq&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1817245/qKnPtiQkIP1zDhGHpklkF1GE_jg/large_nepal.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;$5 can provide 785 water purification tablets.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Clean water:&lt;/strong&gt; &lt;a href=&#34;https://onetoday.google.com/p/66rfdsta&#34; title=&#34;Link: https://onetoday.google.com/p/66rfdsta&#34;&gt;https://onetoday.google.com/p/66rfdsta&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1817246/fw9vFAQkTJpBvx9TSzt3M2j_5KY/large_water.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;$5 can provide clean water to 5 children for 3 months. Isn&amp;rsquo;t that incredible?&lt;/p&gt;
&lt;p&gt;If you happen to use &lt;a href=&#34;http://pgcli.com/&#34;&gt;pgcli&lt;/a&gt; or &lt;a href=&#34;http://mycli.net/&#34;&gt;mycli&lt;/a&gt; and you&amp;rsquo;re happy with it, consider making a &lt;a href=&#34;http://mycli.net/donate&#34;&gt;donation&lt;/a&gt;. I promise to pick the best charities out there to contribute your donations. :)&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Some of you might know that I created a couple of <a href="http://pgcli.com" title="Link: http://pgcli.com">open</a> <a href="http://mycli.net" title="Link: http://mycli.net">source</a> projects that became successful.</p>
<p>I added a <a href="http://mycli.net/donate">donate</a> button to one of the project&rsquo;s homepage. A couple of days ago, I received a donation through that link (thanks, <a href="https://daniel-siepmann.de/">Daniel</a>). This is the second donation I&rsquo;ve received since it&rsquo;s inception. Needless to say, I was pleasantly surprised.</p>
<p>My current job pays me well, so I decided to funnel the donation to the following charities. It&rsquo;s a small sum ($15) but it had a big impact. </p>
<p><strong>Solve Hunger:</strong> <a href="https://onetoday.google.com/p/pnvzxbtk">https://onetoday.google.com/p/pnvzxbtk</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1817244/JtgGShY5dlY-U7vNG9biBz4uhec/large_hunger.jpeg" alt=""  />
</p>
<p>$5 to provide 4 meals for 5 school children.</p>
<p><strong>Nepal Earthquake:</strong> <a href="https://onetoday.google.com/p/mjsxg_gq">https://onetoday.google.com/p/mjsxg_gq</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1817245/qKnPtiQkIP1zDhGHpklkF1GE_jg/large_nepal.jpeg" alt=""  />
</p>
<p>$5 can provide 785 water purification tablets.</p>
<p><strong>Clean water:</strong> <a href="https://onetoday.google.com/p/66rfdsta" title="Link: https://onetoday.google.com/p/66rfdsta">https://onetoday.google.com/p/66rfdsta</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1817246/fw9vFAQkTJpBvx9TSzt3M2j_5KY/large_water.jpeg" alt=""  />
</p>
<p>$5 can provide clean water to 5 children for 3 months. Isn&rsquo;t that incredible?</p>
<p>If you happen to use <a href="http://pgcli.com/">pgcli</a> or <a href="http://mycli.net/">mycli</a> and you&rsquo;re happy with it, consider making a <a href="http://mycli.net/donate">donation</a>. I promise to pick the best charities out there to contribute your donations. :)</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Nostalgic Programming</title>
      <link>https://amjith.com/blog/nostalgic-programming/</link>
      <pubDate>Thu, 15 Dec 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/nostalgic-programming/</guid>
      <description>&lt;p&gt;For some unknown reason, I looked up GWBasic today and &lt;a href=&#34;http://robhagemans.github.io/pcbasic/&#34;&gt;downloaded&lt;/a&gt; an emulator. GWBasic was the first programming language that I learned. I have fond memories of that language. I love the fact that I could switch to a graphics mode and start drawing circles and squares. &lt;/p&gt;
&lt;p&gt;After about 30 minutes of fumbling around, my muscle memory kicked in and I started to write a simple program to draw some shapes on the screen. I asked Sempi to sit with me and help me with the drawing. He wanted me to draw a truck, so I decided to give it a shot. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1814107/HqX_KtmtSPEarl4-V58bDrlGRGE/large_2b6e2040-4dd2-4377-87e0-982c9b582c87.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;He lost interest midway when I started looking up various commands in the programming manual, but I stuck with it. &lt;/p&gt;
&lt;p&gt;Here&amp;rsquo;s the creation in all it&amp;rsquo;s glory. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1813987/eC8eFyhzxFXGsdWei3FKc0e0RnU/large_PC-BASIC.png&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Needless to say, I had a lot of fun. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>For some unknown reason, I looked up GWBasic today and <a href="http://robhagemans.github.io/pcbasic/">downloaded</a> an emulator. GWBasic was the first programming language that I learned. I have fond memories of that language. I love the fact that I could switch to a graphics mode and start drawing circles and squares. </p>
<p>After about 30 minutes of fumbling around, my muscle memory kicked in and I started to write a simple program to draw some shapes on the screen. I asked Sempi to sit with me and help me with the drawing. He wanted me to draw a truck, so I decided to give it a shot. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1814107/HqX_KtmtSPEarl4-V58bDrlGRGE/large_2b6e2040-4dd2-4377-87e0-982c9b582c87.jpeg" alt=""  />
</p>
<p>He lost interest midway when I started looking up various commands in the programming manual, but I stuck with it. </p>
<p>Here&rsquo;s the creation in all it&rsquo;s glory. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1813987/eC8eFyhzxFXGsdWei3FKc0e0RnU/large_PC-BASIC.png" alt=""  />
</p>
<p>Needless to say, I had a lot of fun. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Broccoli and Carrot</title>
      <link>https://amjith.com/blog/broccoli-and-carrot/</link>
      <pubDate>Sun, 11 Dec 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/broccoli-and-carrot/</guid>
      <description>&lt;p&gt;A few weeks back while eating at a restaurant Sempi wanted me to tell him a story. I noticed he wasn&amp;rsquo;t eating his vegetables, so I made up a story about these animals that lived in the forest and how they discovered Broccoli. When they ate broccoli they became strong and could lift heavy things. Then came carrots which made them fast. Somehow this worked and he polished off every broccoli and carrot in the plate. &lt;/p&gt;
&lt;p&gt;Recently we were playing with a hole punch and he was having difficulty piercing through some strong pieces of paper. So I helped him out and punched holes. He asked me if I&amp;rsquo;ve been eating broccoli. I said yes and told him that I&amp;rsquo;m going to eat all the broccoli in the house. Visibly disturbed by that he protested &amp;ldquo;But appa, I want some broccoli, can you please give me some broccoli next time?&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m supposed to feel bad for manipulating him into eating vegetables, but I have no regrets.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>A few weeks back while eating at a restaurant Sempi wanted me to tell him a story. I noticed he wasn&rsquo;t eating his vegetables, so I made up a story about these animals that lived in the forest and how they discovered Broccoli. When they ate broccoli they became strong and could lift heavy things. Then came carrots which made them fast. Somehow this worked and he polished off every broccoli and carrot in the plate. </p>
<p>Recently we were playing with a hole punch and he was having difficulty piercing through some strong pieces of paper. So I helped him out and punched holes. He asked me if I&rsquo;ve been eating broccoli. I said yes and told him that I&rsquo;m going to eat all the broccoli in the house. Visibly disturbed by that he protested &ldquo;But appa, I want some broccoli, can you please give me some broccoli next time?&rdquo;.</p>
<p>I&rsquo;m supposed to feel bad for manipulating him into eating vegetables, but I have no regrets.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>I want a baby</title>
      <link>https://amjith.com/blog/i-want-a-baby/</link>
      <pubDate>Sat, 12 Nov 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/i-want-a-baby/</guid>
      <description>&lt;p&gt;Sempi had this conversation with Yoshi yesterday. &lt;/p&gt;
&lt;p&gt;Sempi: Amma, when can I have a baby?&lt;/p&gt;
&lt;p&gt;Yoshi: Well, you have to study hard. Finish your pre-school, then your elementary school, middle school and then high-school. Go to college, well that part is optional. Get a job, meet someone, fall in love and then you can have a baby. Most importantly you have to be at least 18 years old.&lt;/p&gt;
&lt;p&gt;Sempi: Man, I&amp;rsquo;m never gonna have a baby.&lt;/p&gt;
&lt;p&gt;Yoshi: Why do you want to have a baby? &lt;/p&gt;
&lt;p&gt;Sempi: So I can fiddle with my own baby monitor.&lt;/p&gt;
&lt;p&gt;Previously, Yoshi had told him not to play with Vian&amp;rsquo;s baby monitor and this is his solution. :)&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi had this conversation with Yoshi yesterday. </p>
<p>Sempi: Amma, when can I have a baby?</p>
<p>Yoshi: Well, you have to study hard. Finish your pre-school, then your elementary school, middle school and then high-school. Go to college, well that part is optional. Get a job, meet someone, fall in love and then you can have a baby. Most importantly you have to be at least 18 years old.</p>
<p>Sempi: Man, I&rsquo;m never gonna have a baby.</p>
<p>Yoshi: Why do you want to have a baby? </p>
<p>Sempi: So I can fiddle with my own baby monitor.</p>
<p>Previously, Yoshi had told him not to play with Vian&rsquo;s baby monitor and this is his solution. :)</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>My little helper</title>
      <link>https://amjith.com/blog/my-little-helper/</link>
      <pubDate>Sat, 12 Nov 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/my-little-helper/</guid>
      <description>&lt;p&gt;Sempi loves Vian. Vian thinks Sempi is the coolest guy ever. When Vian is crying and I&amp;rsquo;ve tried every trick in my book, I call Sempi for help. Sempi starts doing something funny (sing a song in gibberish or jump up and down on a mattress), immediately Vian starts laughing (not just a smile but a wholehearted laughter). Vian thinks Sempi is hilarious and Sempi loves to entertain Vian. It works out great for me. :)&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi loves Vian. Vian thinks Sempi is the coolest guy ever. When Vian is crying and I&rsquo;ve tried every trick in my book, I call Sempi for help. Sempi starts doing something funny (sing a song in gibberish or jump up and down on a mattress), immediately Vian starts laughing (not just a smile but a wholehearted laughter). Vian thinks Sempi is hilarious and Sempi loves to entertain Vian. It works out great for me. :)</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Little Hands Big Work</title>
      <link>https://amjith.com/blog/little-hands-big-work/</link>
      <pubDate>Thu, 29 Sep 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/little-hands-big-work/</guid>
      <description>&lt;p&gt;My son&amp;rsquo;s preschool Whole Child Montessori is running it&amp;rsquo;s annual fundraiser called &lt;a href=&#34;http://www.wholechildmontessori.org/little-hands-big-work/&#34;&gt;Little Hands Big Work&lt;/a&gt;. It&amp;rsquo;s an event where the school raises money to provide scholarship to kids who need it. In addition the kids and parents volunteer to restore a natural water shed. So donors get the double benefit of supporting early childhood education as well as making the environment better. &lt;/p&gt;
&lt;p&gt;It is a worthy cause that deserves your support.&lt;/p&gt;
&lt;p&gt;Here&amp;rsquo;s the link to donate: &lt;a href=&#34;http://www.wholechildmontessori.org/little-hands-big-work/&#34; title=&#34;Link: http://www.wholechildmontessori.org/little-hands-big-work/&#34;&gt;http://www.wholechildmontessori.org/little-hands-big-work/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;When you donate mention Sempi&amp;rsquo;s name in the student column, I&amp;rsquo;m sure he&amp;rsquo;ll appreciate it. :)&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1776729/xH0WxRiWL2FS3QbGOcWk62z5Sfs/large_Sempi.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1776730/acKNtg4TEXisoCJsjREFy88dR5g/large_sempi2.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>My son&rsquo;s preschool Whole Child Montessori is running it&rsquo;s annual fundraiser called <a href="http://www.wholechildmontessori.org/little-hands-big-work/">Little Hands Big Work</a>. It&rsquo;s an event where the school raises money to provide scholarship to kids who need it. In addition the kids and parents volunteer to restore a natural water shed. So donors get the double benefit of supporting early childhood education as well as making the environment better. </p>
<p>It is a worthy cause that deserves your support.</p>
<p>Here&rsquo;s the link to donate: <a href="http://www.wholechildmontessori.org/little-hands-big-work/" title="Link: http://www.wholechildmontessori.org/little-hands-big-work/">http://www.wholechildmontessori.org/little-hands-big-work/</a></p>
<p>When you donate mention Sempi&rsquo;s name in the student column, I&rsquo;m sure he&rsquo;ll appreciate it. :)</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1776729/xH0WxRiWL2FS3QbGOcWk62z5Sfs/large_Sempi.jpeg" alt=""  />
</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1776730/acKNtg4TEXisoCJsjREFy88dR5g/large_sempi2.jpeg" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Levelling Up</title>
      <link>https://amjith.com/blog/levelling-up/</link>
      <pubDate>Sun, 11 Sep 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/levelling-up/</guid>
      <description>&lt;p&gt;A common advice that is given to people in software is &amp;ldquo;Surround yourself with programmers better than yourself&amp;rdquo;. Somehow this advice does NOT work for me. Whenever I&amp;rsquo;ve worked on a team with programmers who are better than me, I get lazy. I tend to write code that is slightly worse than my average. I reckon it&amp;rsquo;s because I rely on the better programmers to catch my mistakes. I do learn things from them but it&amp;rsquo;s not quite at the same pace as when I&amp;rsquo;m thrown in the deep end with minimal help.&lt;/p&gt;
&lt;p&gt;When I work in teams where people are about as good as me or they come to me for advice, I produce significantly better results. This goes beyond code, I&amp;rsquo;ve noticed this effect in project direction or project management. I find myself doing a lot of self-study and personal experimentation to make sure I know what I&amp;rsquo;m talking about. This naturally leads to better results.&lt;/p&gt;
&lt;p&gt;I still need access to the expert when I&amp;rsquo;m stuck, but that access should not be as easy as turning my head to ask a question. I prefer that access to be through an email where I&amp;rsquo;m forced to write my thoughts down. Describing my problem in written form usually triggers cognitive dissonance and I end up solving the issue before hitting send.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>A common advice that is given to people in software is &ldquo;Surround yourself with programmers better than yourself&rdquo;. Somehow this advice does NOT work for me. Whenever I&rsquo;ve worked on a team with programmers who are better than me, I get lazy. I tend to write code that is slightly worse than my average. I reckon it&rsquo;s because I rely on the better programmers to catch my mistakes. I do learn things from them but it&rsquo;s not quite at the same pace as when I&rsquo;m thrown in the deep end with minimal help.</p>
<p>When I work in teams where people are about as good as me or they come to me for advice, I produce significantly better results. This goes beyond code, I&rsquo;ve noticed this effect in project direction or project management. I find myself doing a lot of self-study and personal experimentation to make sure I know what I&rsquo;m talking about. This naturally leads to better results.</p>
<p>I still need access to the expert when I&rsquo;m stuck, but that access should not be as easy as turning my head to ask a question. I prefer that access to be through an email where I&rsquo;m forced to write my thoughts down. Describing my problem in written form usually triggers cognitive dissonance and I end up solving the issue before hitting send.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>The Lemonade Stand</title>
      <link>https://amjith.com/blog/the-lemonade-stand/</link>
      <pubDate>Thu, 01 Sep 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/the-lemonade-stand/</guid>
      <description>&lt;p&gt;Last Sunday Sempi decided he wanted to setup a lemonade stand. Yoshi and Sempi went to store to pick up a bunch of lemons and spent the morning hand squeezing them.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1761959/XL3Gpip0991MZxxrtdpzriELS4E/large_IMG_20160828_172518.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;It was made with the finest ingredients (cane sugar and ice cold water). Yoshi said she can help make the signs and Sempi declared that he&amp;rsquo;s going to give free lemonades. He insisted that he won&amp;rsquo;t charge for his lemonade. &lt;/p&gt;
&lt;p&gt;◀
1
of
2
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1761963/ztIxAFWtXV7tdj1aKG2amMUWtSg/thumb_IMG_20160828_143251.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1761960/ssgSfqcICEMipLYM1G5DF5aaF1k/thumb_IMG_20160828_133148.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1761963/ztIxAFWtXV7tdj1aKG2amMUWtSg/large_IMG_20160828_143251.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;At this time I&amp;rsquo;m beaming with pride with his decision to give away his lemonade for free.&lt;/p&gt;
&lt;p&gt;He sat out in the scorching sun in the middle of the day calling out to passersby &amp;ldquo;Free Lemonade&amp;rdquo;. When people came over his first words were &amp;ldquo;you don&amp;rsquo;t have to pay, this is free lemonade&amp;rdquo;. Then he diligently poured some lemonade in a cup and handed it over.&lt;/p&gt;
&lt;p&gt;Our neighbor across the street came over for some lemonade. He not only gave him a few quarters as tips and he was also the salesman of our fine stand. Calling out to bikers and walkers to come taste the delicious free lemonade. It was a grand success.&lt;/p&gt;
&lt;p&gt;At one point even Vian was sitting inside the little lemonade stand helping his brother. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1761961/zbziafXKxeUxeV5XSqQqNoqgu_U/large_IMG_20160828_142120.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m incredibly proud of my son&amp;rsquo;s decision to setup a free lemonade stand. He is the best.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Last Sunday Sempi decided he wanted to setup a lemonade stand. Yoshi and Sempi went to store to pick up a bunch of lemons and spent the morning hand squeezing them.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1761959/XL3Gpip0991MZxxrtdpzriELS4E/large_IMG_20160828_172518.jpg" alt=""  />
</p>
<p>It was made with the finest ingredients (cane sugar and ice cold water). Yoshi said she can help make the signs and Sempi declared that he&rsquo;s going to give free lemonades. He insisted that he won&rsquo;t charge for his lemonade. </p>
<p>◀
1
of
2
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1761963/ztIxAFWtXV7tdj1aKG2amMUWtSg/thumb_IMG_20160828_143251.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1761960/ssgSfqcICEMipLYM1G5DF5aaF1k/thumb_IMG_20160828_133148.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1761963/ztIxAFWtXV7tdj1aKG2amMUWtSg/large_IMG_20160828_143251.jpg" alt=""  />
</p>
<p>At this time I&rsquo;m beaming with pride with his decision to give away his lemonade for free.</p>
<p>He sat out in the scorching sun in the middle of the day calling out to passersby &ldquo;Free Lemonade&rdquo;. When people came over his first words were &ldquo;you don&rsquo;t have to pay, this is free lemonade&rdquo;. Then he diligently poured some lemonade in a cup and handed it over.</p>
<p>Our neighbor across the street came over for some lemonade. He not only gave him a few quarters as tips and he was also the salesman of our fine stand. Calling out to bikers and walkers to come taste the delicious free lemonade. It was a grand success.</p>
<p>At one point even Vian was sitting inside the little lemonade stand helping his brother. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1761961/zbziafXKxeUxeV5XSqQqNoqgu_U/large_IMG_20160828_142120.jpg" alt=""  />
</p>
<p>I&rsquo;m incredibly proud of my son&rsquo;s decision to setup a free lemonade stand. He is the best.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>A Trip to the Gorge</title>
      <link>https://amjith.com/blog/a-trip-to-the-gorge/</link>
      <pubDate>Fri, 26 Aug 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/a-trip-to-the-gorge/</guid>
      <description>&lt;p&gt;Nice hot day for driving to the gorge and visiting some of our favorite falls. First stop Bridal Veil falls. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Bridal Veil falls:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;After an awesome hike we have a clear view of the bridal veil falls. Sempi takes in the view and announces, &amp;ldquo;&lt;strong&gt;Appa I&amp;rsquo;d like to pee now&lt;/strong&gt;&amp;rdquo;. Of course, you do.&lt;/p&gt;
&lt;p&gt;&amp;mdash;Zinger between me and Yoshi.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;Me:&lt;/em&gt; Do you think it is named Bridal Wails falls because it sounds like a wailing bride?&lt;/p&gt;
&lt;p&gt;&lt;em&gt;Yoshi:&lt;/em&gt; I can see why you would think that, but the wailing you saw at our wedding is a special spectacle, I had my reasons. No one does that.&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;On our hike back from the falls, I convinced Sempi to say that the falls ran out of water. He wasn&amp;rsquo;t quite convincing, but he tried his best. Unfortunately none of the hikers heard what he said. Oh well, we&amp;rsquo;ll try it again next time.&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1759371/QYEc5SgO6oAfRjrkmJ3VpbzC-8g/large_Yoshi.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1759372/fgHhjOliwhXj0If1t0TdGIaOL2Q/large_bridal_wail.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Multnomah falls:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;After Bridal Veil we were trying do decide which one to visit next. The top contenders were Multnomah falls or Wahkeen falls. Multnomah falls won hands down because they have soft serve ice cream. Priorities!&lt;/p&gt;
&lt;p&gt;Once we got our soft serve cones and started walking up, Sempi became increasingly distraught that his cone was melting. So I generously offered to switch his cone for mine. He agreed and we switched for a minute but then he realized my cone had very little left in it and promptly switched back.&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;A little while later&amp;hellip;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;Sempi:&lt;/em&gt; Appa can you just eat the ice cream so I can eat the cone?&lt;/p&gt;
&lt;p&gt;&lt;em&gt;Me:&lt;/em&gt; Gladly!&lt;/p&gt;
&lt;p&gt;But unfortunately before I could do any damage to his ice cream, he changed his mind.&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;After the ice cream is done we were sitting at a bench and admiring the view. &lt;/p&gt;
&lt;p&gt;&lt;em&gt;Sempi:&lt;/em&gt; Appa do they turn off the water at night when they close the gates?&lt;/p&gt;
&lt;hr&gt;
</description>
      <content:encoded><![CDATA[<p>Nice hot day for driving to the gorge and visiting some of our favorite falls. First stop Bridal Veil falls. </p>
<p><strong>Bridal Veil falls:</strong></p>
<p>After an awesome hike we have a clear view of the bridal veil falls. Sempi takes in the view and announces, &ldquo;<strong>Appa I&rsquo;d like to pee now</strong>&rdquo;. Of course, you do.</p>
<p>&mdash;Zinger between me and Yoshi.</p>
<p><em>Me:</em> Do you think it is named Bridal Wails falls because it sounds like a wailing bride?</p>
<p><em>Yoshi:</em> I can see why you would think that, but the wailing you saw at our wedding is a special spectacle, I had my reasons. No one does that.</p>
<hr>
<p>On our hike back from the falls, I convinced Sempi to say that the falls ran out of water. He wasn&rsquo;t quite convincing, but he tried his best. Unfortunately none of the hikers heard what he said. Oh well, we&rsquo;ll try it again next time.</p>
<hr>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1759371/QYEc5SgO6oAfRjrkmJ3VpbzC-8g/large_Yoshi.jpeg" alt=""  />
</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1759372/fgHhjOliwhXj0If1t0TdGIaOL2Q/large_bridal_wail.jpeg" alt=""  />
</p>
<p><strong>Multnomah falls:</strong></p>
<p>After Bridal Veil we were trying do decide which one to visit next. The top contenders were Multnomah falls or Wahkeen falls. Multnomah falls won hands down because they have soft serve ice cream. Priorities!</p>
<p>Once we got our soft serve cones and started walking up, Sempi became increasingly distraught that his cone was melting. So I generously offered to switch his cone for mine. He agreed and we switched for a minute but then he realized my cone had very little left in it and promptly switched back.</p>
<hr>
<p>A little while later&hellip;</p>
<p><em>Sempi:</em> Appa can you just eat the ice cream so I can eat the cone?</p>
<p><em>Me:</em> Gladly!</p>
<p>But unfortunately before I could do any damage to his ice cream, he changed his mind.</p>
<hr>
<p>After the ice cream is done we were sitting at a bench and admiring the view. </p>
<p><em>Sempi:</em> Appa do they turn off the water at night when they close the gates?</p>
<hr>
]]></content:encoded>
    </item>
    
    <item>
      <title>Bookworm</title>
      <link>https://amjith.com/blog/bookworm/</link>
      <pubDate>Fri, 19 Aug 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/bookworm/</guid>
      <description>&lt;p&gt;We&amp;rsquo;re getting ready to visit the library to return the books. I&amp;rsquo;m walking around the house finding all the books and filling them up in bags.&lt;/p&gt;
&lt;p&gt;Me: Filling up three large bags full of books to return to the library indicates a reading problem. Especially since they were checked out only a week ago.&lt;/p&gt;
&lt;p&gt;Yoshi: These books are almost due, we checked them out two weeks ago.&lt;/p&gt;
&lt;p&gt;Me: Oh well, that makes all the difference then. (as I&amp;rsquo;m struggling to carry three heavy bag of books). &lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m quite proud of how many books Sempi goes through. Even though we&amp;rsquo;re the ones reading it to them, he prefers books over many things, which is not all that bad.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We&rsquo;re getting ready to visit the library to return the books. I&rsquo;m walking around the house finding all the books and filling them up in bags.</p>
<p>Me: Filling up three large bags full of books to return to the library indicates a reading problem. Especially since they were checked out only a week ago.</p>
<p>Yoshi: These books are almost due, we checked them out two weeks ago.</p>
<p>Me: Oh well, that makes all the difference then. (as I&rsquo;m struggling to carry three heavy bag of books). </p>
<p>I&rsquo;m quite proud of how many books Sempi goes through. Even though we&rsquo;re the ones reading it to them, he prefers books over many things, which is not all that bad.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 3 month old</title>
      <link>https://amjith.com/blog/conversations-with-a-3-month-old/</link>
      <pubDate>Wed, 10 Aug 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-3-month-old/</guid>
      <description>&lt;p&gt;Vian&amp;rsquo;s vocabulary isn&amp;rsquo;t quite as good as his brother&amp;rsquo;s. So what&amp;rsquo;s documented below is my own interpretation of his actions and expressions.&lt;/p&gt;
&lt;p&gt;It&amp;rsquo;s bedtime and I&amp;rsquo;m rocking Vian to sleep. He fell asleep on my arms and I&amp;rsquo;ve been rocking him for nearly an hour. I decided it was time to put him down. &lt;/p&gt;
&lt;p&gt;As soon as I put him down, he wakes up in shock and disbelief.&lt;/p&gt;
&lt;p&gt;Vian: I can&amp;rsquo;t believe you&amp;rsquo;ve done this. &lt;/p&gt;
&lt;p&gt;His lower lip starts to quiver.&lt;/p&gt;
&lt;p&gt;Vian: You better pick me up you overgrown human or I won&amp;rsquo;t hesitate to use these brand new vocal chords.&lt;/p&gt;
&lt;p&gt;He&amp;rsquo;s back on my arms and starts to grunt a few times. &lt;/p&gt;
&lt;p&gt;Vian: Let that be a lesson, don&amp;rsquo;t let me catch you in one of your shenanigans.&lt;/p&gt;
&lt;p&gt;Promptly fell back asleep in my arms.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian&rsquo;s vocabulary isn&rsquo;t quite as good as his brother&rsquo;s. So what&rsquo;s documented below is my own interpretation of his actions and expressions.</p>
<p>It&rsquo;s bedtime and I&rsquo;m rocking Vian to sleep. He fell asleep on my arms and I&rsquo;ve been rocking him for nearly an hour. I decided it was time to put him down. </p>
<p>As soon as I put him down, he wakes up in shock and disbelief.</p>
<p>Vian: I can&rsquo;t believe you&rsquo;ve done this. </p>
<p>His lower lip starts to quiver.</p>
<p>Vian: You better pick me up you overgrown human or I won&rsquo;t hesitate to use these brand new vocal chords.</p>
<p>He&rsquo;s back on my arms and starts to grunt a few times. </p>
<p>Vian: Let that be a lesson, don&rsquo;t let me catch you in one of your shenanigans.</p>
<p>Promptly fell back asleep in my arms.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Fun with Vilari (3 month old)</title>
      <link>https://amjith.com/blog/fun-with-vilari-3-month-old/</link>
      <pubDate>Tue, 09 Aug 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/fun-with-vilari-3-month-old/</guid>
      <description>&lt;p&gt;Vian and I started taking walks around the block in the evening. I carry him around all swaddled and he coos and babbles for a few minutes. I sing his favorite Tamil lullaby and he slowly calms down and rests his head on my chest and drifts into sleep. The awesome thing about our neighborhood is everyone I meet during the walk is genuinely happy to see us. I usually get a thumbs up from cars driving by or neighbors want to stop and take a closer look at Vian. Some of them offer up great advice about how they raised their kids. If he&amp;rsquo;s ever fussy during our walk I add a bounce to my walk. At times like that, I get a sympathetic nod from fellow walkers and one woman said &amp;ldquo;It&amp;rsquo;ll get better, don&amp;rsquo;t worry&amp;rdquo; as she was passing by.&lt;/p&gt;
&lt;p&gt;Night time is a whole another story. Yoshi wakes up a few times to feed him. Sometimes she&amp;rsquo;ll hand him off after the feeding to change him or rock him. Those are my favorite times. He&amp;rsquo;s wide awake and giggly. He&amp;rsquo;s smiling the entire time I&amp;rsquo;m changing his diaper. Even after I swaddle him back he&amp;rsquo;s usually all smiles. I rock him on a yoga ball and within 15 mins he&amp;rsquo;s passed out again. I hold him for another 5 or 10 mins and then put him back on the bed. The best part is his sleepy grin after I put him down. His eyes are closed and he&amp;rsquo;s asleep, but he still manages to crack a dreamy smile. So I always take an extra few minutes to take in his smile before returning to sleep myself.&lt;/p&gt;
&lt;p&gt;Even though not every night is as smooth and easy as I described above, I&amp;rsquo;m quite content with my life.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Vian and I started taking walks around the block in the evening. I carry him around all swaddled and he coos and babbles for a few minutes. I sing his favorite Tamil lullaby and he slowly calms down and rests his head on my chest and drifts into sleep. The awesome thing about our neighborhood is everyone I meet during the walk is genuinely happy to see us. I usually get a thumbs up from cars driving by or neighbors want to stop and take a closer look at Vian. Some of them offer up great advice about how they raised their kids. If he&rsquo;s ever fussy during our walk I add a bounce to my walk. At times like that, I get a sympathetic nod from fellow walkers and one woman said &ldquo;It&rsquo;ll get better, don&rsquo;t worry&rdquo; as she was passing by.</p>
<p>Night time is a whole another story. Yoshi wakes up a few times to feed him. Sometimes she&rsquo;ll hand him off after the feeding to change him or rock him. Those are my favorite times. He&rsquo;s wide awake and giggly. He&rsquo;s smiling the entire time I&rsquo;m changing his diaper. Even after I swaddle him back he&rsquo;s usually all smiles. I rock him on a yoga ball and within 15 mins he&rsquo;s passed out again. I hold him for another 5 or 10 mins and then put him back on the bed. The best part is his sleepy grin after I put him down. His eyes are closed and he&rsquo;s asleep, but he still manages to crack a dreamy smile. So I always take an extra few minutes to take in his smile before returning to sleep myself.</p>
<p>Even though not every night is as smooth and easy as I described above, I&rsquo;m quite content with my life.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Voice of an Angel</title>
      <link>https://amjith.com/blog/voice-of-an-angel/</link>
      <pubDate>Wed, 06 Jul 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/voice-of-an-angel/</guid>
      <description>&lt;p&gt;When Sempi was a little baby we had a hard time putting him to sleep. I would rock him for hours (yup, hours) trying to get him to sleep. During those days I would sing a Tamil song that my mom taught me in the hopes that it&amp;rsquo;ll calm him down and put him to sleep. Never worked. &lt;/p&gt;
&lt;p&gt;With Vian we are going through a similar experience (you&amp;rsquo;d think we&amp;rsquo;d learn by now) of rocking him to sleep. But this time when I sing that Tamil song he actually calms down. He stops crying, places his head on my chest while I rock him and sometimes even falls asleep. This of course brings me tremendous joy. I was patting myself on the back congratulating for perfecting my singing technique. &lt;/p&gt;
&lt;p&gt;Only to find out later that he also calms down (faster) if the vacuum cleaner is in use. Yoshi found this out accidentally while vacuuming the house while wearing him in a wrap. He was passed out in under 5 minutes flat. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1734780/VFhVsppvAErzKSncVlna4ihw9dY/large_IMG_20160706_114039.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;My son likens my singing to the sound of a vacuum cleaner. I&amp;rsquo;m beaming with pride.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>When Sempi was a little baby we had a hard time putting him to sleep. I would rock him for hours (yup, hours) trying to get him to sleep. During those days I would sing a Tamil song that my mom taught me in the hopes that it&rsquo;ll calm him down and put him to sleep. Never worked. </p>
<p>With Vian we are going through a similar experience (you&rsquo;d think we&rsquo;d learn by now) of rocking him to sleep. But this time when I sing that Tamil song he actually calms down. He stops crying, places his head on my chest while I rock him and sometimes even falls asleep. This of course brings me tremendous joy. I was patting myself on the back congratulating for perfecting my singing technique. </p>
<p>Only to find out later that he also calms down (faster) if the vacuum cleaner is in use. Yoshi found this out accidentally while vacuuming the house while wearing him in a wrap. He was passed out in under 5 minutes flat. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1734780/VFhVsppvAErzKSncVlna4ihw9dY/large_IMG_20160706_114039.jpg" alt=""  />
</p>
<p>My son likens my singing to the sound of a vacuum cleaner. I&rsquo;m beaming with pride.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Porcupine</title>
      <link>https://amjith.com/blog/porcupine/</link>
      <pubDate>Mon, 13 Jun 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/porcupine/</guid>
      <description>&lt;p&gt;After a 4 week paternity leave, I&amp;rsquo;m getting ready to go back to work. &lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve taken a shower, trimmed my beard, wearing a decent button up shirt and slacks. Sempi walks by and he says: &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Sempi:&lt;/strong&gt; Appa you look different. &lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m gearing up for a compliment. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Sempi:&lt;/strong&gt; You look like a porcupine. &lt;/p&gt;
&lt;p&gt;That&amp;rsquo;s his way of noticing that I haven&amp;rsquo;t combed my hair.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me:&lt;/strong&gt; Thanks a lot man. &lt;/p&gt;
&lt;p&gt;I should have known better. :P&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>After a 4 week paternity leave, I&rsquo;m getting ready to go back to work. </p>
<p>I&rsquo;ve taken a shower, trimmed my beard, wearing a decent button up shirt and slacks. Sempi walks by and he says: </p>
<p><strong>Sempi:</strong> Appa you look different. </p>
<p>I&rsquo;m gearing up for a compliment. </p>
<p><strong>Sempi:</strong> You look like a porcupine. </p>
<p>That&rsquo;s his way of noticing that I haven&rsquo;t combed my hair.</p>
<p><strong>Me:</strong> Thanks a lot man. </p>
<p>I should have known better. :P</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Sibling For Sale</title>
      <link>https://amjith.com/blog/sibling-for-sale/</link>
      <pubDate>Sat, 11 Jun 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/sibling-for-sale/</guid>
      <description>&lt;p&gt;Sempi and I are at our favorite neighborhood coffee shop, reading books and eating bagels. &lt;/p&gt;
&lt;p&gt;We picked up a book with a collection of funny poems. Here&amp;rsquo;s one: &lt;/p&gt;
&lt;h1 id=&#34;one-sister-for-saleone-sister-for-saleone-crying-and-spying-young-sister-for-saleim-really-not-kidding-so-wholl-start-the-biddingdo-i-hear-a-dollara-nicklea-pennyoh-isnt-there-isnt-there-isnt-there-anyone-person-who-will-buy-this-sister-for-salethis-crying-spying-old-young-sister-for-sale&#34;&gt;“One sister for sale,One sister for sale,One crying and spying young sister for saleI&amp;rsquo;m really not kidding so who&amp;rsquo;ll start the biddingDo I hear a dollar?A nickle?A penny?Oh isn&amp;rsquo;t there isn&amp;rsquo;t there isn&amp;rsquo;t there anyOne person who will buy this sister for saleThis crying spying old young sister for sale.”&lt;/h1&gt;
&lt;p&gt;I asked Sempi.&lt;/p&gt;
&lt;p&gt;Me: What would you say if someone offered a nickel for Jelly Bean (nickname for his brother Vian).&lt;/p&gt;
&lt;p&gt;Sempi: Thank you!?&lt;/p&gt;
&lt;p&gt;Me: Haha. So you&amp;rsquo;ll give them Jelly bean for a nickel. &lt;/p&gt;
&lt;p&gt;Sempi: No! He&amp;rsquo;s mine.&lt;/p&gt;
&lt;p&gt;I guess he didn&amp;rsquo;t really understand the poem or my question. But I was amused that his first response was &amp;ldquo;Thank you&amp;rdquo;. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi and I are at our favorite neighborhood coffee shop, reading books and eating bagels. </p>
<p>We picked up a book with a collection of funny poems. Here&rsquo;s one: </p>
<h1 id="one-sister-for-saleone-sister-for-saleone-crying-and-spying-young-sister-for-saleim-really-not-kidding-so-wholl-start-the-biddingdo-i-hear-a-dollara-nicklea-pennyoh-isnt-there-isnt-there-isnt-there-anyone-person-who-will-buy-this-sister-for-salethis-crying-spying-old-young-sister-for-sale">“One sister for sale,One sister for sale,One crying and spying young sister for saleI&rsquo;m really not kidding so who&rsquo;ll start the biddingDo I hear a dollar?A nickle?A penny?Oh isn&rsquo;t there isn&rsquo;t there isn&rsquo;t there anyOne person who will buy this sister for saleThis crying spying old young sister for sale.”</h1>
<p>I asked Sempi.</p>
<p>Me: What would you say if someone offered a nickel for Jelly Bean (nickname for his brother Vian).</p>
<p>Sempi: Thank you!?</p>
<p>Me: Haha. So you&rsquo;ll give them Jelly bean for a nickel. </p>
<p>Sempi: No! He&rsquo;s mine.</p>
<p>I guess he didn&rsquo;t really understand the poem or my question. But I was amused that his first response was &ldquo;Thank you&rdquo;. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Cup of Almonds</title>
      <link>https://amjith.com/blog/cup-of-almonds/</link>
      <pubDate>Tue, 07 Jun 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/cup-of-almonds/</guid>
      <description>&lt;p&gt;Me: I noticed that you did not eat your almonds that I packed for your lunch yesterday.&lt;/p&gt;
&lt;p&gt;Sempi: Yes I like to look at them for lunch.&lt;/p&gt;
&lt;p&gt;Me: Huh. So do you want me to pack it again today?&lt;/p&gt;
&lt;p&gt;Sempi: Yeah. (in a matter of fact voice). &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Me: I noticed that you did not eat your almonds that I packed for your lunch yesterday.</p>
<p>Sempi: Yes I like to look at them for lunch.</p>
<p>Me: Huh. So do you want me to pack it again today?</p>
<p>Sempi: Yeah. (in a matter of fact voice). </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Ikea Ice Cream</title>
      <link>https://amjith.com/blog/ikea-ice-cream/</link>
      <pubDate>Mon, 06 Jun 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/ikea-ice-cream/</guid>
      <description>&lt;p&gt;When I was a little kid which was about three or four years ago I used to go to IKEA with Yoshi. Whenever we went I always wanted to get their $1 ice cream. Sometimes Yoshi would indulge and other times I was too much of a wuss to ask her.&lt;/p&gt;
&lt;p&gt;Today I went to Ikea with my son and my mom. After sending my mom to go sight see the various displays, we decided to hit the food court. Sempi said that he wanted a slice of pizza. I said sure then I crouched down next to him and asked him &amp;ldquo;Sempi I was thinking about getting you an ice cream&amp;rdquo;. He thought for a moment and then said &amp;ldquo;But I was going to eat a slice of pizza&amp;rdquo;. He did not realize that I was offering to buy him both a slice of pizza as well as ice cream. So I told him okay you get the slice of pizza and I will get the ice cream and I can share mine with you. He was excited about that proposition. Here&amp;rsquo;s me eating the ice cream with him right before I drop the ice cream.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1718837/sCEF4uJgVtCMN5hFoxO_N9AoWbk/large_IMG_20160604_123807.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;We manage to salvage most of it when I caught it mid air. It wasn&amp;rsquo;t graceful but that never stopped us from finishing off the rest of it.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>When I was a little kid which was about three or four years ago I used to go to IKEA with Yoshi. Whenever we went I always wanted to get their $1 ice cream. Sometimes Yoshi would indulge and other times I was too much of a wuss to ask her.</p>
<p>Today I went to Ikea with my son and my mom. After sending my mom to go sight see the various displays, we decided to hit the food court. Sempi said that he wanted a slice of pizza. I said sure then I crouched down next to him and asked him &ldquo;Sempi I was thinking about getting you an ice cream&rdquo;. He thought for a moment and then said &ldquo;But I was going to eat a slice of pizza&rdquo;. He did not realize that I was offering to buy him both a slice of pizza as well as ice cream. So I told him okay you get the slice of pizza and I will get the ice cream and I can share mine with you. He was excited about that proposition. Here&rsquo;s me eating the ice cream with him right before I drop the ice cream.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1718837/sCEF4uJgVtCMN5hFoxO_N9AoWbk/large_IMG_20160604_123807.jpg" alt=""  />
</p>
<p>We manage to salvage most of it when I caught it mid air. It wasn&rsquo;t graceful but that never stopped us from finishing off the rest of it.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations about a 4 week old</title>
      <link>https://amjith.com/blog/conversations-about-a-4-week-old/</link>
      <pubDate>Sun, 05 Jun 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-about-a-4-week-old/</guid>
      <description>&lt;p&gt;After a particularly rough night with the new born, Yoshi and I are sitting in the dining room eating breakfast. Vian is sleeping in the bedroom.&lt;/p&gt;
&lt;p&gt;Yoshi: Can you check on the baby? &lt;/p&gt;
&lt;p&gt;Me: Sure&lt;/p&gt;
&lt;p&gt;*Checked on him to make sure he&amp;rsquo;s still breathing*&lt;/p&gt;
&lt;p&gt;Me: He&amp;rsquo;s sleeping with the utmost satisfaction of someone who has stolen two people&amp;rsquo;s sleep.&lt;/p&gt;
&lt;p&gt;Yoshi: Haha. *tired and jittery laughter*&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>After a particularly rough night with the new born, Yoshi and I are sitting in the dining room eating breakfast. Vian is sleeping in the bedroom.</p>
<p>Yoshi: Can you check on the baby? </p>
<p>Me: Sure</p>
<p>*Checked on him to make sure he&rsquo;s still breathing*</p>
<p>Me: He&rsquo;s sleeping with the utmost satisfaction of someone who has stolen two people&rsquo;s sleep.</p>
<p>Yoshi: Haha. *tired and jittery laughter*</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Stay at Home Dad - Week 4</title>
      <link>https://amjith.com/blog/stay-at-home-dad-week-4/</link>
      <pubDate>Tue, 31 May 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/stay-at-home-dad-week-4/</guid>
      <description>&lt;p&gt;TL;DR: Last week of my leave ended with some epiphanies and personal growth. I still firmly believe I&amp;rsquo;d rather be a stay at home dad than a working dad.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m glad to say that I bounced back from week 3 with great success. I finally broke through some mental barrier and felt a strange calm wash over me. I started controlling my emotions better. I still get angry when Sempi does something that I explicitly asked him not to do, but I don&amp;rsquo;t show that anger to him. I use a calm, stable voice to express my displeasure and gently ask him not to do it. I firmly request him to apologize for what he did and it works nearly 80% of the time.&lt;/p&gt;
&lt;p&gt;Yoshi has given this advice to me in the past &amp;ldquo;When Sempi is having a bad time, try to be calm and emotionally stable. That way he can rely on us to find his bearings&amp;rdquo;. It finally clicked for me. It&amp;rsquo;s a simple advice that is hard to follow. But so far keeping my cool has resulted in a reasonably well-behaved kid.&lt;/p&gt;
&lt;p&gt;We had a couple of playdates at our place with two different kids. Sempi played well with one of the kids, the other playdate was more like the two kids played in the same room but didn&amp;rsquo;t really bother interacting with each other. So I&amp;rsquo;d say it was a resounding success.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715787/wz0yLCDMu-_J1xvIsVChzk0pWP0/large_IMG_20160525_133009.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I took our neighbor&amp;rsquo;s kid (Sempi&amp;rsquo;s school mate) to rock climbing. She was a total champ. After about the 10th time, I had to restrict her climbing so she wouldn&amp;rsquo;t end up with muscle cramps. The abundance of energy found in 3 year olds is incredible.&lt;/p&gt;
&lt;p&gt;◀
1
of
3
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715788/89wbmDTSxLFglMywQK5LKDLL15Y/thumb_IMG_20160524_150442.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715789/xetphmSyD74-MvATqkfgclNqjek/thumb_IMG_20160524_154710.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715790/UfivYkcJSWGCBNjecFha4__KhBI/thumb_IMG_20160524_151209.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715788/89wbmDTSxLFglMywQK5LKDLL15Y/large_IMG_20160524_150442.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;The strange epiphany here is that managing toddlers is easier when there is more than one of them. I could have just gotten lucky but so far the 3 afternoons with 2 toddlers have been a breeze compared to the rest of the afternoons when it&amp;rsquo;s just me and Sempi. &lt;/p&gt;
&lt;p&gt;Adventures in cooking. I made eggplant rigatoni. I&amp;rsquo;m glad to say it wasn&amp;rsquo;t a complete disaster. Yoshi liked it a lot.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715791/clRvBh06-NHBBrKf-N5TtD6usOw/large_IMG_20160526_121744.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Yoshi helped Sempi make truck shaped muffins. They were delicious. Sempi asked me to pack some in his lunch to give to his teachers. It was so sweet. Later I found out he ate all of those extra pieces that were packed for his teachers. I should&amp;rsquo;ve known better.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715792/POFPjx1gkvgwGIN9Ukd9aD-l61Q/large_IMG_20160527_091310.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;My mentor and friend, Graham is in town for PyCon and he brought a Lego Construction Set for Sempi. Sempi was in cloud nine while building his trucks from scratch.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1716517/GF2r8gKDWxuOLVhtjtCOcsZoqUQ/large_IMG_20160528_132952.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;During week 1, I said Sempi still prefers his mom and I have 3 more weeks to change that. I&amp;rsquo;m happy to report this hasn&amp;rsquo;t really changed but I do have the following conversation to report. &lt;/p&gt;
&lt;p&gt;I do my usual breakfast &lt;a href=&#34;https://amjith.com/blog/sense-of-belonging&#34;&gt;routine&lt;/a&gt; where I sit him down at the breakfast table and put a bib on him while singing &amp;ldquo;I put a bib on you, &amp;lsquo;cause you&amp;rsquo;re mine&amp;hellip;&amp;rdquo;. Usually he retorts with &amp;ldquo;I don&amp;rsquo;t belong to you, I belong to Amma&amp;rdquo;. But today Sempi said, &amp;ldquo;I &lt;strong&gt;AM&lt;/strong&gt; yours, because we sleep together&amp;rdquo;. I was so moved by his reply, I didn&amp;rsquo;t even have the heart to make some crude joke about it.&lt;/p&gt;
&lt;p&gt;A little bit of context. I sleep in the bedroom with Sempi and Yoshi sleeps with the baby in the other room, so we don&amp;rsquo;t disturb Sempi&amp;rsquo;s sleep during night time feedings. Hence his comment about sleeping together.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m glad to have the paternity leave end on a positive note. Overall, it has been a very positive experience for me. I now have a better appreciation of what Yoshi goes through on a daily basis. More importantly I got a chance to bond with Sempi that wouldn&amp;rsquo;t have happened without this leave. I went into this hoping to be a helping hand and came away with increased awareness and maturity.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>TL;DR: Last week of my leave ended with some epiphanies and personal growth. I still firmly believe I&rsquo;d rather be a stay at home dad than a working dad.</p>
<p>I&rsquo;m glad to say that I bounced back from week 3 with great success. I finally broke through some mental barrier and felt a strange calm wash over me. I started controlling my emotions better. I still get angry when Sempi does something that I explicitly asked him not to do, but I don&rsquo;t show that anger to him. I use a calm, stable voice to express my displeasure and gently ask him not to do it. I firmly request him to apologize for what he did and it works nearly 80% of the time.</p>
<p>Yoshi has given this advice to me in the past &ldquo;When Sempi is having a bad time, try to be calm and emotionally stable. That way he can rely on us to find his bearings&rdquo;. It finally clicked for me. It&rsquo;s a simple advice that is hard to follow. But so far keeping my cool has resulted in a reasonably well-behaved kid.</p>
<p>We had a couple of playdates at our place with two different kids. Sempi played well with one of the kids, the other playdate was more like the two kids played in the same room but didn&rsquo;t really bother interacting with each other. So I&rsquo;d say it was a resounding success.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715787/wz0yLCDMu-_J1xvIsVChzk0pWP0/large_IMG_20160525_133009.jpg" alt=""  />
</p>
<p>I took our neighbor&rsquo;s kid (Sempi&rsquo;s school mate) to rock climbing. She was a total champ. After about the 10th time, I had to restrict her climbing so she wouldn&rsquo;t end up with muscle cramps. The abundance of energy found in 3 year olds is incredible.</p>
<p>◀
1
of
3
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715788/89wbmDTSxLFglMywQK5LKDLL15Y/thumb_IMG_20160524_150442.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715789/xetphmSyD74-MvATqkfgclNqjek/thumb_IMG_20160524_154710.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715790/UfivYkcJSWGCBNjecFha4__KhBI/thumb_IMG_20160524_151209.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715788/89wbmDTSxLFglMywQK5LKDLL15Y/large_IMG_20160524_150442.jpg" alt=""  />
</p>
<p>The strange epiphany here is that managing toddlers is easier when there is more than one of them. I could have just gotten lucky but so far the 3 afternoons with 2 toddlers have been a breeze compared to the rest of the afternoons when it&rsquo;s just me and Sempi. </p>
<p>Adventures in cooking. I made eggplant rigatoni. I&rsquo;m glad to say it wasn&rsquo;t a complete disaster. Yoshi liked it a lot.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715791/clRvBh06-NHBBrKf-N5TtD6usOw/large_IMG_20160526_121744.jpg" alt=""  />
</p>
<p>Yoshi helped Sempi make truck shaped muffins. They were delicious. Sempi asked me to pack some in his lunch to give to his teachers. It was so sweet. Later I found out he ate all of those extra pieces that were packed for his teachers. I should&rsquo;ve known better.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1715792/POFPjx1gkvgwGIN9Ukd9aD-l61Q/large_IMG_20160527_091310.jpg" alt=""  />
</p>
<p>My mentor and friend, Graham is in town for PyCon and he brought a Lego Construction Set for Sempi. Sempi was in cloud nine while building his trucks from scratch.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1716517/GF2r8gKDWxuOLVhtjtCOcsZoqUQ/large_IMG_20160528_132952.jpg" alt=""  />
</p>
<p>During week 1, I said Sempi still prefers his mom and I have 3 more weeks to change that. I&rsquo;m happy to report this hasn&rsquo;t really changed but I do have the following conversation to report. </p>
<p>I do my usual breakfast <a href="https://amjith.com/blog/sense-of-belonging">routine</a> where I sit him down at the breakfast table and put a bib on him while singing &ldquo;I put a bib on you, &lsquo;cause you&rsquo;re mine&hellip;&rdquo;. Usually he retorts with &ldquo;I don&rsquo;t belong to you, I belong to Amma&rdquo;. But today Sempi said, &ldquo;I <strong>AM</strong> yours, because we sleep together&rdquo;. I was so moved by his reply, I didn&rsquo;t even have the heart to make some crude joke about it.</p>
<p>A little bit of context. I sleep in the bedroom with Sempi and Yoshi sleeps with the baby in the other room, so we don&rsquo;t disturb Sempi&rsquo;s sleep during night time feedings. Hence his comment about sleeping together.</p>
<p>I&rsquo;m glad to have the paternity leave end on a positive note. Overall, it has been a very positive experience for me. I now have a better appreciation of what Yoshi goes through on a daily basis. More importantly I got a chance to bond with Sempi that wouldn&rsquo;t have happened without this leave. I went into this hoping to be a helping hand and came away with increased awareness and maturity.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Stay at Home Dad - Week 3</title>
      <link>https://amjith.com/blog/stay-at-home-dad-week-3/</link>
      <pubDate>Mon, 23 May 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/stay-at-home-dad-week-3/</guid>
      <description>&lt;p&gt;TL;DR: When life gets harder it&amp;rsquo;s because you&amp;rsquo;ve just leveled up. I certainly hope so because this week made the first week look like a walk in the park. Novelty of a new stay at home parent has worn off, reality has set in. &lt;/p&gt;
&lt;p&gt;I started the week with a lot of ambition. I thought I knew how to handle Sempi. So I voluntarily decided to level up my duties as a stay at home dad.&lt;/p&gt;
&lt;p&gt;I decided to clean the house while he was at school. Putting away the toys and vacuuming took nearly two hours. It&amp;rsquo;s not my first time, but it is my first time doing it without any help. After that I had time to eat some lunch (I didn&amp;rsquo;t have to prepare it, since my mom took care of that) and then it was time to go get him from school. There was no downtime, which I thought I could catch up on the next day. Five days later I&amp;rsquo;ve accumulated more downtime debt than I can pay off.  How do people manage to do this without help? The saving grace is that it felt amazing after I cleaned the house. It was satisfying and I felt proud of my work. This lasted a whole day before everything was back to it&amp;rsquo;s disorganized mess and the floors started getting grimy. I started pondering &amp;ldquo;What&amp;rsquo;s the point of all of this? Why am I doing this?&amp;quot;. &lt;/p&gt;
&lt;p&gt;Around this time Sempi decided it was time to push the boundaries with me during bedtime. The bedtime routine is breaking and he tries to run to Yoshi when I start being strict. In the afternoons he insists on staying home and I can&amp;rsquo;t force him to leave the house. This sometimes leads to Sempi interrupting the baby&amp;rsquo;s nap. I&amp;rsquo;m unable to entice him with playtime and toys. I have run out of leverage and he can smell the desperation. &lt;/p&gt;
&lt;p&gt;I started inventing new ways to use the existing toys. For example, Legos/Duplos are now allowed in the bathtub. I built a submarine which I found was incredibly difficult since they raise to the top due to the air trapped between the blocks. The trick is to build it underwater and make sure you let the bubbles escape before joining two blocks.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711963/XTY5nmt6rCTVERc5OsLxqYAu-2g/large_IMG_20160522_161920.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Aside from the existential pondering, we achieved some important milestones. Sempi and I biked to a park that was 2 miles away. We both took separate bikes and I&amp;rsquo;m proud to say we made it all the way to the park. At one point while pushing up his bike through a broken sidewalk he said in a very serious tone &amp;ldquo;This job is hard work, I don&amp;rsquo;t think I can do it again&amp;rdquo;. I cracked up when he said it, which was met with a stern angry look. We took the bus back, since the way back is almost entirely uphill.&lt;/p&gt;
&lt;p&gt;◀
1
of
3
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711968/X_CKU2PiXwO6lITBGt5XoBM8ngU/thumb_IMG_20160518_131512.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711969/oZTUb3zRcDdJgGpQd06KfMieBk0/thumb_IMG_20160518_131551.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711970/EyWJPiQP7-oecpLsivjOcj4uXWQ/thumb_IMG_20160518_133823.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711968/X_CKU2PiXwO6lITBGt5XoBM8ngU/large_IMG_20160518_131512.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;We went to &lt;a href=&#34;http://vancouver.dozerday.org/&#34;&gt;Dozer days&lt;/a&gt; on the weekend which gave Yoshi and the baby a break. But waiting in long lines for a 2 min ride in a bulldozer or an excavator wasn&amp;rsquo;t nearly as fun as I remembered from last year. It could be the pouring rain that soaked us wet or it could be Sempi&amp;rsquo;s last minute change of mind to not go on a ride anymore after having waited in line for 20mins.&lt;/p&gt;
&lt;p&gt;◀
1
of
4
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711966/rMMbxCAV1pOvK2pAT0HaUV8QZcM/thumb_IMG_20160521_120203.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711964/w3LgjPa6t69v2CXzsJNR0KrhCrE/thumb_IMG_20160521_115433.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711965/uFr8NzFTLkkZE9fKYoaObXElxYw/thumb_IMG_20160521_115436.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711967/8xLENeZoIGtsKN4ZYr9J63z1KFA/thumb_IMG_20160521_121122.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711966/rMMbxCAV1pOvK2pAT0HaUV8QZcM/large_IMG_20160521_120203.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Sempi started serenading his brother with a song about garbage trucks when he was crying. It was the sweetest thing until he wanted to do it again when the baby was sleeping.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711971/RbdZ15xN-CnZcWIfONoz5j2hbvA/large_IMG_20160521_074953.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Play VideoPlayMuteCurrent Time 0:00/Duration Time 0:00Loaded: 0%Progress: 0%Stream TypeLIVERemaining Time -0:00 Playback Rate1Chapters* Chapters
Subtitles* subtitles off
Captions* captions off
FullscreenThis is a modal window.&lt;/p&gt;
&lt;p&gt;Foreground&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;White
Black
Red
Green
Blue
Yellow
Magenta
Cyan&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Opaque
Semi-Opaque&lt;/p&gt;
&lt;p&gt;Background&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;White
Black
Red
Green
Blue
Yellow
Magenta
Cyan&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Opaque
Semi-Transparent
Transparent&lt;/p&gt;
&lt;p&gt;Window&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;White
Black
Red
Green
Blue
Yellow
Magenta
Cyan&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Opaque
Semi-Transparent
Transparent&lt;/p&gt;
&lt;p&gt;Font Size&lt;/p&gt;
&lt;p&gt;50%
75%
100%
125%
150%
175%
200%
300%
400%&lt;/p&gt;
&lt;p&gt;Text Edge Style&lt;/p&gt;
&lt;p&gt;None
Raised
Depressed
Uniform
Dropshadow&lt;/p&gt;
&lt;p&gt;Font Family&lt;/p&gt;
&lt;p&gt;Default
Monospace Serif
Proportional Serif
Monospace Sans-Serif
Proportional Sans-Serif
Casual
Script
Small Caps&lt;/p&gt;
&lt;p&gt;Defaults
Done&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://phaven-prod.s3.amazonaws.com/files/video_part/asset/1711972/1YTlrARV2vyZYQTygHxVo01Pm2s/VID_20160521_075832.mp4&#34;&gt;Download VID_20160521_075832.mp4&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;I got to bond with the baby a lot more since he decided sleeping was so last week. I got to rock him, walk him around and let him sleep on me while I sit in the couch. It was nice.&lt;/p&gt;
&lt;p&gt;◀
1
of
2
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711974/LZVFCAXa9ynbPaEHAbeb-6IK6lw/thumb_IMG-20160518-WA0003.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711973/2uNnj5tnEoohAstExO5DqEJtEn0/thumb_IMG_20160519_090351.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711974/LZVFCAXa9ynbPaEHAbeb-6IK6lw/large_IMG-20160518-WA0003.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;As we enter into the last week of my paternity leave, I&amp;rsquo;m hopeful that I can rebound from last week, but I&amp;rsquo;m worried for Yoshi. All this time she has been providing me with support when I needed a break and pulling in the extra load when I start to slack off. But how is she going to do it all when I&amp;rsquo;m at work? I know parents around the world have done this billion times over, but I can&amp;rsquo;t help but feel a sense of panic.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711977/fO4rsh0f7mMRo6Eiyc_pewY58sU/large_walk.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>TL;DR: When life gets harder it&rsquo;s because you&rsquo;ve just leveled up. I certainly hope so because this week made the first week look like a walk in the park. Novelty of a new stay at home parent has worn off, reality has set in. </p>
<p>I started the week with a lot of ambition. I thought I knew how to handle Sempi. So I voluntarily decided to level up my duties as a stay at home dad.</p>
<p>I decided to clean the house while he was at school. Putting away the toys and vacuuming took nearly two hours. It&rsquo;s not my first time, but it is my first time doing it without any help. After that I had time to eat some lunch (I didn&rsquo;t have to prepare it, since my mom took care of that) and then it was time to go get him from school. There was no downtime, which I thought I could catch up on the next day. Five days later I&rsquo;ve accumulated more downtime debt than I can pay off.  How do people manage to do this without help? The saving grace is that it felt amazing after I cleaned the house. It was satisfying and I felt proud of my work. This lasted a whole day before everything was back to it&rsquo;s disorganized mess and the floors started getting grimy. I started pondering &ldquo;What&rsquo;s the point of all of this? Why am I doing this?&quot;. </p>
<p>Around this time Sempi decided it was time to push the boundaries with me during bedtime. The bedtime routine is breaking and he tries to run to Yoshi when I start being strict. In the afternoons he insists on staying home and I can&rsquo;t force him to leave the house. This sometimes leads to Sempi interrupting the baby&rsquo;s nap. I&rsquo;m unable to entice him with playtime and toys. I have run out of leverage and he can smell the desperation. </p>
<p>I started inventing new ways to use the existing toys. For example, Legos/Duplos are now allowed in the bathtub. I built a submarine which I found was incredibly difficult since they raise to the top due to the air trapped between the blocks. The trick is to build it underwater and make sure you let the bubbles escape before joining two blocks.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711963/XTY5nmt6rCTVERc5OsLxqYAu-2g/large_IMG_20160522_161920.jpg" alt=""  />
</p>
<p>Aside from the existential pondering, we achieved some important milestones. Sempi and I biked to a park that was 2 miles away. We both took separate bikes and I&rsquo;m proud to say we made it all the way to the park. At one point while pushing up his bike through a broken sidewalk he said in a very serious tone &ldquo;This job is hard work, I don&rsquo;t think I can do it again&rdquo;. I cracked up when he said it, which was met with a stern angry look. We took the bus back, since the way back is almost entirely uphill.</p>
<p>◀
1
of
3
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711968/X_CKU2PiXwO6lITBGt5XoBM8ngU/thumb_IMG_20160518_131512.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711969/oZTUb3zRcDdJgGpQd06KfMieBk0/thumb_IMG_20160518_131551.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711970/EyWJPiQP7-oecpLsivjOcj4uXWQ/thumb_IMG_20160518_133823.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711968/X_CKU2PiXwO6lITBGt5XoBM8ngU/large_IMG_20160518_131512.jpg" alt=""  />
</p>
<p>We went to <a href="http://vancouver.dozerday.org/">Dozer days</a> on the weekend which gave Yoshi and the baby a break. But waiting in long lines for a 2 min ride in a bulldozer or an excavator wasn&rsquo;t nearly as fun as I remembered from last year. It could be the pouring rain that soaked us wet or it could be Sempi&rsquo;s last minute change of mind to not go on a ride anymore after having waited in line for 20mins.</p>
<p>◀
1
of
4
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711966/rMMbxCAV1pOvK2pAT0HaUV8QZcM/thumb_IMG_20160521_120203.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711964/w3LgjPa6t69v2CXzsJNR0KrhCrE/thumb_IMG_20160521_115433.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711965/uFr8NzFTLkkZE9fKYoaObXElxYw/thumb_IMG_20160521_115436.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711967/8xLENeZoIGtsKN4ZYr9J63z1KFA/thumb_IMG_20160521_121122.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711966/rMMbxCAV1pOvK2pAT0HaUV8QZcM/large_IMG_20160521_120203.jpg" alt=""  />
</p>
<p>Sempi started serenading his brother with a song about garbage trucks when he was crying. It was the sweetest thing until he wanted to do it again when the baby was sleeping.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711971/RbdZ15xN-CnZcWIfONoz5j2hbvA/large_IMG_20160521_074953.jpg" alt=""  />
</p>
<p>Play VideoPlayMuteCurrent Time 0:00/Duration Time 0:00Loaded: 0%Progress: 0%Stream TypeLIVERemaining Time -0:00 Playback Rate1Chapters* Chapters
Subtitles* subtitles off
Captions* captions off
FullscreenThis is a modal window.</p>
<p>Foreground</p>
<hr>
<p>White
Black
Red
Green
Blue
Yellow
Magenta
Cyan</p>
<hr>
<p>Opaque
Semi-Opaque</p>
<p>Background</p>
<hr>
<p>White
Black
Red
Green
Blue
Yellow
Magenta
Cyan</p>
<hr>
<p>Opaque
Semi-Transparent
Transparent</p>
<p>Window</p>
<hr>
<p>White
Black
Red
Green
Blue
Yellow
Magenta
Cyan</p>
<hr>
<p>Opaque
Semi-Transparent
Transparent</p>
<p>Font Size</p>
<p>50%
75%
100%
125%
150%
175%
200%
300%
400%</p>
<p>Text Edge Style</p>
<p>None
Raised
Depressed
Uniform
Dropshadow</p>
<p>Font Family</p>
<p>Default
Monospace Serif
Proportional Serif
Monospace Sans-Serif
Proportional Sans-Serif
Casual
Script
Small Caps</p>
<p>Defaults
Done</p>
<p><a href="https://phaven-prod.s3.amazonaws.com/files/video_part/asset/1711972/1YTlrARV2vyZYQTygHxVo01Pm2s/VID_20160521_075832.mp4">Download VID_20160521_075832.mp4</a></p>
<p>I got to bond with the baby a lot more since he decided sleeping was so last week. I got to rock him, walk him around and let him sleep on me while I sit in the couch. It was nice.</p>
<p>◀
1
of
2
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711974/LZVFCAXa9ynbPaEHAbeb-6IK6lw/thumb_IMG-20160518-WA0003.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711973/2uNnj5tnEoohAstExO5DqEJtEn0/thumb_IMG_20160519_090351.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711974/LZVFCAXa9ynbPaEHAbeb-6IK6lw/large_IMG-20160518-WA0003.jpg" alt=""  />
</p>
<p>As we enter into the last week of my paternity leave, I&rsquo;m hopeful that I can rebound from last week, but I&rsquo;m worried for Yoshi. All this time she has been providing me with support when I needed a break and pulling in the extra load when I start to slack off. But how is she going to do it all when I&rsquo;m at work? I know parents around the world have done this billion times over, but I can&rsquo;t help but feel a sense of panic.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1711977/fO4rsh0f7mMRo6Eiyc_pewY58sU/large_walk.jpeg" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Stay at home dad - week 2</title>
      <link>https://amjith.com/blog/stay-at-home-dad-week-2/</link>
      <pubDate>Tue, 17 May 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/stay-at-home-dad-week-2/</guid>
      <description>&lt;p&gt;I now have a rhythm. Things seem to be getting easier.&lt;/p&gt;
&lt;p&gt;We&amp;rsquo;re one grandma down. We&amp;rsquo;re managing with just one grandma. :P&lt;/p&gt;
&lt;p&gt;I have a whole new appreciation for Portland parks and museums. You might remember that we spent an entire day (6 hours is an entire day in toddler time) at the Children&amp;rsquo;s museum last week. This week we spent an afternoon at &lt;a href=&#34;http://www.omsi.edu/&#34;&gt;OMSI&lt;/a&gt;. I took Yoshi&amp;rsquo;s e-bike and hitched the trailer. It was a nice sunny day and half way there I noticed the hitch was rattling. We made a stop at a bike shop to borrow a wrench. The name of the shop was &lt;a href=&#34;http://www.localbikes.net/Oregon/Free-Wheel-Bikes-4225.html&#34;&gt;Free Wheel Bikes&lt;/a&gt;. I was trying to show him the bolt that needed tightening. He heard me saying the trailer is attached to the bike and offered to get me a size 14 wrench since that fits best with bolts on an axel. When we walked back to his tool rack in measured steps, I realized (to my total surprise) that he was blind. Which explained why that bike shop was the most well-organized shop I&amp;rsquo;ve seen in my life. &lt;/p&gt;
&lt;p&gt;We got to do a lot of new activities together. &lt;/p&gt;
&lt;p&gt;We built some electronic circuits. Thanks to my coworker Joe for introducing me to the circuit club called &lt;a href=&#34;http://tronclub.com/&#34;&gt;Tron Club&lt;/a&gt;. This week we got our first circuit kit and we made some blinking LEDs. He was enthusiastic for about two hours and then the enthusiasm waned when he realized we&amp;rsquo;re not building anything with wheels. I see a bright future building robots with him. :)&lt;/p&gt;
&lt;p&gt;Drinking some victory juice after building a circuit with a photo-resistor. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708515/8FVTyxo73jtw3sHa3ab7CxyqTU0/large_IMG_20160511_150340.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Play VideoPlayMuteCurrent Time 0:00/Duration Time 0:00Loaded: 0%Progress: 0%Stream TypeLIVERemaining Time -0:00 Playback Rate1Chapters* Chapters
Subtitles* subtitles off
Captions* captions off
FullscreenThis is a modal window.&lt;/p&gt;
&lt;p&gt;Foreground&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;White
Black
Red
Green
Blue
Yellow
Magenta
Cyan&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Opaque
Semi-Opaque&lt;/p&gt;
&lt;p&gt;Background&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;White
Black
Red
Green
Blue
Yellow
Magenta
Cyan&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Opaque
Semi-Transparent
Transparent&lt;/p&gt;
&lt;p&gt;Window&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;White
Black
Red
Green
Blue
Yellow
Magenta
Cyan&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Opaque
Semi-Transparent
Transparent&lt;/p&gt;
&lt;p&gt;Font Size&lt;/p&gt;
&lt;p&gt;50%
75%
100%
125%
150%
175%
200%
300%
400%&lt;/p&gt;
&lt;p&gt;Text Edge Style&lt;/p&gt;
&lt;p&gt;None
Raised
Depressed
Uniform
Dropshadow&lt;/p&gt;
&lt;p&gt;Font Family&lt;/p&gt;
&lt;p&gt;Default
Monospace Serif
Proportional Serif
Monospace Sans-Serif
Proportional Sans-Serif
Casual
Script
Small Caps&lt;/p&gt;
&lt;p&gt;Defaults
Done&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://phaven-prod.s3.amazonaws.com/files/video_part/asset/1708516/DbiFCZeKeMj9yZD2wV_TZd9JwCM/VID_20160511_150252.mp4&#34;&gt;Download VID_20160511_150252.mp4&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;We went rock climbing at Circuit Gym. He thought that&amp;rsquo;s where they made the circuits, but he wasn&amp;rsquo;t too disappointed when we go there and there weren&amp;rsquo;t any circuits. He loved the slide for coming down from the top. He liked it so much he decided to climb up the slide instead of the rocks. I had to use &lt;del&gt;bribes&lt;/del&gt; &lt;a href=&#34;https://www.verywell.com/what-is-positive-reinforcement-2795412&#34;&gt;positive reinforcement&lt;/a&gt; to get him to climb on the rocks. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708561/RiHLvr5i0b2_xSzuYCNueTT1wLs/large_IMG_20160512_135832.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Enjoying a well earned treat after a tough climb. :)&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708562/Z94ChtLayS9wzHvGJF4ekuS1zjk/large_IMG_20160512_141110.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Weekends are still a mixed bag. Saturday we went to Train day to see a few elaborate displays of model rail road exhibits. Sunday was a mellow day, it was speckled with rough patches but all in all a pleasant day. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708563/ccEgYjxOWpdNWuD26U46dc5ovJI/large_IMG_20160514_120731.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Pizza time. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708564/fUAcPjzF77I8nvM6oDbe-5GedMc/large_IMG_20160515_121912.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I got to bond with Vianvilari some more. We started going on walks around the block. &lt;/p&gt;
&lt;p&gt;Yoshi got some decorated diapers at her baby shower which made diaper changes fun for me. We have some of the best friends.&lt;/p&gt;
&lt;p&gt;◀
1
of
2
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708566/aluEksf21CkY8Z9ZpPYh4grR64w/thumb_IMG_20160510_074802.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708565/K92lt5tvo-cu-H2b-Gq9sJwAsbE/thumb_IMG-20160511-WA0004.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708566/aluEksf21CkY8Z9ZpPYh4grR64w/large_IMG_20160510_074802.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I now have a rhythm. Things seem to be getting easier.</p>
<p>We&rsquo;re one grandma down. We&rsquo;re managing with just one grandma. :P</p>
<p>I have a whole new appreciation for Portland parks and museums. You might remember that we spent an entire day (6 hours is an entire day in toddler time) at the Children&rsquo;s museum last week. This week we spent an afternoon at <a href="http://www.omsi.edu/">OMSI</a>. I took Yoshi&rsquo;s e-bike and hitched the trailer. It was a nice sunny day and half way there I noticed the hitch was rattling. We made a stop at a bike shop to borrow a wrench. The name of the shop was <a href="http://www.localbikes.net/Oregon/Free-Wheel-Bikes-4225.html">Free Wheel Bikes</a>. I was trying to show him the bolt that needed tightening. He heard me saying the trailer is attached to the bike and offered to get me a size 14 wrench since that fits best with bolts on an axel. When we walked back to his tool rack in measured steps, I realized (to my total surprise) that he was blind. Which explained why that bike shop was the most well-organized shop I&rsquo;ve seen in my life. </p>
<p>We got to do a lot of new activities together. </p>
<p>We built some electronic circuits. Thanks to my coworker Joe for introducing me to the circuit club called <a href="http://tronclub.com/">Tron Club</a>. This week we got our first circuit kit and we made some blinking LEDs. He was enthusiastic for about two hours and then the enthusiasm waned when he realized we&rsquo;re not building anything with wheels. I see a bright future building robots with him. :)</p>
<p>Drinking some victory juice after building a circuit with a photo-resistor. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708515/8FVTyxo73jtw3sHa3ab7CxyqTU0/large_IMG_20160511_150340.jpg" alt=""  />
</p>
<p>Play VideoPlayMuteCurrent Time 0:00/Duration Time 0:00Loaded: 0%Progress: 0%Stream TypeLIVERemaining Time -0:00 Playback Rate1Chapters* Chapters
Subtitles* subtitles off
Captions* captions off
FullscreenThis is a modal window.</p>
<p>Foreground</p>
<hr>
<p>White
Black
Red
Green
Blue
Yellow
Magenta
Cyan</p>
<hr>
<p>Opaque
Semi-Opaque</p>
<p>Background</p>
<hr>
<p>White
Black
Red
Green
Blue
Yellow
Magenta
Cyan</p>
<hr>
<p>Opaque
Semi-Transparent
Transparent</p>
<p>Window</p>
<hr>
<p>White
Black
Red
Green
Blue
Yellow
Magenta
Cyan</p>
<hr>
<p>Opaque
Semi-Transparent
Transparent</p>
<p>Font Size</p>
<p>50%
75%
100%
125%
150%
175%
200%
300%
400%</p>
<p>Text Edge Style</p>
<p>None
Raised
Depressed
Uniform
Dropshadow</p>
<p>Font Family</p>
<p>Default
Monospace Serif
Proportional Serif
Monospace Sans-Serif
Proportional Sans-Serif
Casual
Script
Small Caps</p>
<p>Defaults
Done</p>
<p><a href="https://phaven-prod.s3.amazonaws.com/files/video_part/asset/1708516/DbiFCZeKeMj9yZD2wV_TZd9JwCM/VID_20160511_150252.mp4">Download VID_20160511_150252.mp4</a></p>
<p>We went rock climbing at Circuit Gym. He thought that&rsquo;s where they made the circuits, but he wasn&rsquo;t too disappointed when we go there and there weren&rsquo;t any circuits. He loved the slide for coming down from the top. He liked it so much he decided to climb up the slide instead of the rocks. I had to use <del>bribes</del> <a href="https://www.verywell.com/what-is-positive-reinforcement-2795412">positive reinforcement</a> to get him to climb on the rocks. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708561/RiHLvr5i0b2_xSzuYCNueTT1wLs/large_IMG_20160512_135832.jpg" alt=""  />
</p>
<p>Enjoying a well earned treat after a tough climb. :)</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708562/Z94ChtLayS9wzHvGJF4ekuS1zjk/large_IMG_20160512_141110.jpg" alt=""  />
</p>
<p>Weekends are still a mixed bag. Saturday we went to Train day to see a few elaborate displays of model rail road exhibits. Sunday was a mellow day, it was speckled with rough patches but all in all a pleasant day. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708563/ccEgYjxOWpdNWuD26U46dc5ovJI/large_IMG_20160514_120731.jpg" alt=""  />
</p>
<p>Pizza time. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708564/fUAcPjzF77I8nvM6oDbe-5GedMc/large_IMG_20160515_121912.jpg" alt=""  />
</p>
<p>I got to bond with Vianvilari some more. We started going on walks around the block. </p>
<p>Yoshi got some decorated diapers at her baby shower which made diaper changes fun for me. We have some of the best friends.</p>
<p>◀
1
of
2
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708566/aluEksf21CkY8Z9ZpPYh4grR64w/thumb_IMG_20160510_074802.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708565/K92lt5tvo-cu-H2b-Gq9sJwAsbE/thumb_IMG-20160511-WA0004.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1708566/aluEksf21CkY8Z9ZpPYh4grR64w/large_IMG_20160510_074802.jpg" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Stay at Home Dad - Week 1</title>
      <link>https://amjith.com/blog/stay-at-home-dad-week-1/</link>
      <pubDate>Tue, 10 May 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/stay-at-home-dad-week-1/</guid>
      <description>&lt;p&gt;tl;dr: It is hard and I&amp;rsquo;m struggling. But if I had a choice I&amp;rsquo;ll be a stay at home dad all the time.&lt;/p&gt;
&lt;p&gt;My &lt;a href=&#34;http://newrelic.com&#34;&gt;company&lt;/a&gt; offers 4 weeks of fully paid paternity leave. I&amp;rsquo;m staying home to help out with the new &lt;a href=&#34;https://amjith.com/blog/vianvilari-takeru-ramanujam&#34;&gt;baby&lt;/a&gt;. I thought I&amp;rsquo;d miss working and I did, for whole two days. I was checking my work email and clearing the accumulation, but after that I completely forgot about anything work related. &lt;/p&gt;
&lt;p&gt;The few times I&amp;rsquo;ve held the new born, I can&amp;rsquo;t peel my eyes off of him. The little guy wins the staring contest every time. Sometimes I get a stink eye from him, when I take him from his mom&amp;rsquo;s arms. But he&amp;rsquo;s just too adorable to be taken seriously.&lt;/p&gt;
&lt;p&gt;But most of my time is spent with Sempi (our first son), trying to fill the time and attention that Yoshi used to provide him. The biggest challenge so far is trying to find things to do with him. He&amp;rsquo;s not a fan of leaving the house (probably inherited from me), but he insists on me playing with his trucks. After a day of playing in the house, my brain was fried from squeezing every ounce of creativity to make the playtime fun for both of us.&lt;/p&gt;
&lt;p&gt;I used to take him to our nearby coffee shop to read books on weekends. That worked great when I did it once a week, he flat out refused when I asked him to go two days in a row. &lt;/p&gt;
&lt;p&gt;Tiny emperor on his stroller, being chauffeured to the coffee shop.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704623/I3jiqmDeYDGcUSdOfYt8AgZOnNs/large_IMG_20160505_155413.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Putting him to sleep at night hasn&amp;rsquo;t been rough thanks to Yoshi. She established a nice bedtime routine. Even though reading books in bed was designed to put him to sleep, I&amp;rsquo;m the one who usually zonks out first.&lt;/p&gt;
&lt;p&gt;Weekends are harder if I don&amp;rsquo;t have anything planned. Last weekend I convinced him to go to the Children&amp;rsquo;s museum where he spent a cool 6 hours playing with every exhibit to his heart&amp;rsquo;s content.&lt;/p&gt;
&lt;p&gt;◀
1
of
4
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704624/jB3k8d_obneZ_K_Z2EkkcKr05ig/thumb_IMG_20160507_122230.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704625/JXpLDGkcfDaM7RUIepMEhmeLSw0/thumb_IMG_20160507_122531.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704626/QmCL-i9Nrc3-aZAu-ZG_mf_pXbI/thumb_IMG_20160507_140611.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704627/Xvt5NcQi9qfKfDoN3sp98yIR3oo/thumb_IMG-20160507-WA0014.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704624/jB3k8d_obneZ_K_Z2EkkcKr05ig/large_IMG_20160507_122230.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Weekdays are easier since he goes to preschool in the morning. We setup playdates after school or go to a park.&lt;/p&gt;
&lt;p&gt;Mudpie anyone? &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704628/LLwMneVULzz7IgJ34XseNCLRnM8/large_IMG_20160509_142439.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;He still prefers his mom over me, but I still have 3 more weeks to change that. ;)&lt;/p&gt;
&lt;p&gt;Did I mention that we have not one but two grandmas at home to help with the baby? I haven&amp;rsquo;t cooked or cleaned in 3 weeks, I can really get used to this.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>tl;dr: It is hard and I&rsquo;m struggling. But if I had a choice I&rsquo;ll be a stay at home dad all the time.</p>
<p>My <a href="http://newrelic.com">company</a> offers 4 weeks of fully paid paternity leave. I&rsquo;m staying home to help out with the new <a href="https://amjith.com/blog/vianvilari-takeru-ramanujam">baby</a>. I thought I&rsquo;d miss working and I did, for whole two days. I was checking my work email and clearing the accumulation, but after that I completely forgot about anything work related. </p>
<p>The few times I&rsquo;ve held the new born, I can&rsquo;t peel my eyes off of him. The little guy wins the staring contest every time. Sometimes I get a stink eye from him, when I take him from his mom&rsquo;s arms. But he&rsquo;s just too adorable to be taken seriously.</p>
<p>But most of my time is spent with Sempi (our first son), trying to fill the time and attention that Yoshi used to provide him. The biggest challenge so far is trying to find things to do with him. He&rsquo;s not a fan of leaving the house (probably inherited from me), but he insists on me playing with his trucks. After a day of playing in the house, my brain was fried from squeezing every ounce of creativity to make the playtime fun for both of us.</p>
<p>I used to take him to our nearby coffee shop to read books on weekends. That worked great when I did it once a week, he flat out refused when I asked him to go two days in a row. </p>
<p>Tiny emperor on his stroller, being chauffeured to the coffee shop.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704623/I3jiqmDeYDGcUSdOfYt8AgZOnNs/large_IMG_20160505_155413.jpg" alt=""  />
</p>
<p>Putting him to sleep at night hasn&rsquo;t been rough thanks to Yoshi. She established a nice bedtime routine. Even though reading books in bed was designed to put him to sleep, I&rsquo;m the one who usually zonks out first.</p>
<p>Weekends are harder if I don&rsquo;t have anything planned. Last weekend I convinced him to go to the Children&rsquo;s museum where he spent a cool 6 hours playing with every exhibit to his heart&rsquo;s content.</p>
<p>◀
1
of
4
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704624/jB3k8d_obneZ_K_Z2EkkcKr05ig/thumb_IMG_20160507_122230.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704625/JXpLDGkcfDaM7RUIepMEhmeLSw0/thumb_IMG_20160507_122531.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704626/QmCL-i9Nrc3-aZAu-ZG_mf_pXbI/thumb_IMG_20160507_140611.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704627/Xvt5NcQi9qfKfDoN3sp98yIR3oo/thumb_IMG-20160507-WA0014.jpeg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704624/jB3k8d_obneZ_K_Z2EkkcKr05ig/large_IMG_20160507_122230.jpg" alt=""  />
</p>
<p>Weekdays are easier since he goes to preschool in the morning. We setup playdates after school or go to a park.</p>
<p>Mudpie anyone? </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1704628/LLwMneVULzz7IgJ34XseNCLRnM8/large_IMG_20160509_142439.jpg" alt=""  />
</p>
<p>He still prefers his mom over me, but I still have 3 more weeks to change that. ;)</p>
<p>Did I mention that we have not one but two grandmas at home to help with the baby? I haven&rsquo;t cooked or cleaned in 3 weeks, I can really get used to this.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Negotiations by a 3 yo</title>
      <link>https://amjith.com/blog/negotiations-by-a-3-yo/</link>
      <pubDate>Mon, 09 May 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/negotiations-by-a-3-yo/</guid>
      <description>&lt;p&gt;Sempi and I are sitting at the dining table eating dinner. Sempi is munching on homemade fried rice chips (vadaam) made by his Paati (grandma). He has a plate full of it and I&amp;rsquo;m trying to get him to share some of it with me. &lt;/p&gt;
&lt;p&gt;Me: Sempi, this plate of vadaam is for the both of us. &lt;/p&gt;
&lt;p&gt;Sempi: *pulls the plate towards him, suspiciously*&lt;/p&gt;
&lt;p&gt;Me: How about I take just a few of them and you can have the rest. &lt;/p&gt;
&lt;p&gt;Sempi: Ok, but how about you can have (long pause) &amp;hellip;. none of them?&lt;/p&gt;
&lt;p&gt;Sempi: Appa, you don&amp;rsquo;t have to eat right now.&lt;/p&gt;
&lt;p&gt;He proceeded to eat all of it while I watched him.&lt;/p&gt;
&lt;p&gt;This is not the first time he&amp;rsquo;s used this line of &lt;a href=&#34;https://amjith.com/blog/alternate-solution&#34;&gt;reasoning&lt;/a&gt;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi and I are sitting at the dining table eating dinner. Sempi is munching on homemade fried rice chips (vadaam) made by his Paati (grandma). He has a plate full of it and I&rsquo;m trying to get him to share some of it with me. </p>
<p>Me: Sempi, this plate of vadaam is for the both of us. </p>
<p>Sempi: *pulls the plate towards him, suspiciously*</p>
<p>Me: How about I take just a few of them and you can have the rest. </p>
<p>Sempi: Ok, but how about you can have (long pause) &hellip;. none of them?</p>
<p>Sempi: Appa, you don&rsquo;t have to eat right now.</p>
<p>He proceeded to eat all of it while I watched him.</p>
<p>This is not the first time he&rsquo;s used this line of <a href="https://amjith.com/blog/alternate-solution">reasoning</a>.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Vianvilari Takeru Ramanujam</title>
      <link>https://amjith.com/blog/vianvilari-takeru-ramanujam/</link>
      <pubDate>Wed, 04 May 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/vianvilari-takeru-ramanujam/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m happy to announce we welcomed our new addition to the family on May 2nd 2016. Our second son, Vianvilari Takeru Ramanujam.&lt;/p&gt;
&lt;p&gt;When the baby came out I was grinning like an idiot for a whole 5 minutes before I realized it. I was ecstatic and filled with joy, even though the baby was crying. More than once I caught myself staring at the baby while he was sleeping. &lt;/p&gt;
&lt;p&gt;Oh and then there is this: &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1702213/tWhpTXjlCkBx6mwCQo6dW8_NS80/large__3__WhatsApp_Web.png&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I don&amp;rsquo;t remember why it was so hard to raise a newborn last time. I&amp;rsquo;m sure it was all just my imagination. ;)&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;m happy to announce we welcomed our new addition to the family on May 2nd 2016. Our second son, Vianvilari Takeru Ramanujam.</p>
<p>When the baby came out I was grinning like an idiot for a whole 5 minutes before I realized it. I was ecstatic and filled with joy, even though the baby was crying. More than once I caught myself staring at the baby while he was sleeping. </p>
<p>Oh and then there is this: </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1702213/tWhpTXjlCkBx6mwCQo6dW8_NS80/large__3__WhatsApp_Web.png" alt=""  />
</p>
<p>I don&rsquo;t remember why it was so hard to raise a newborn last time. I&rsquo;m sure it was all just my imagination. ;)</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Defeated by a Dandelion</title>
      <link>https://amjith.com/blog/defeated-by-a-dandelions/</link>
      <pubDate>Tue, 12 Apr 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/defeated-by-a-dandelions/</guid>
      <description>&lt;p&gt;We started a new routine for dropping off Sempi at his pre-school. We walk to the school and on the way we find flowers to pick. This morning we found a dried dandelion and Yoshi taught him how to blow the florets. She blew half of it and gave it to Sempi.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1690491/ffzYk_iMeamzExEveFiQbSreAsg/large_dandelion.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Sempi wasn&amp;rsquo;t all too interested but he wanted me to blow the rest. His stipulation was I have to blow the rest with my nose and not with my mouth. &lt;/p&gt;
&lt;p&gt;So I rose to the challenge and took a deep breath and blew air through my nose as hard as I could. I forgot this is allergy season and I have a runny nose. &lt;/p&gt;
&lt;p&gt;The next few minutes were spent on wiping my mustache, lips and my shirt that were covered in snot.&lt;/p&gt;
&lt;p&gt;Yoshi and Sempi thought it was the most hilarious thing they&amp;rsquo;ve seen. I took solace in the fact that no one else was around to witness the debacle. &lt;/p&gt;
&lt;p&gt;For anyone who is curious, the dandelion was totally unaffected by all of this. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We started a new routine for dropping off Sempi at his pre-school. We walk to the school and on the way we find flowers to pick. This morning we found a dried dandelion and Yoshi taught him how to blow the florets. She blew half of it and gave it to Sempi.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1690491/ffzYk_iMeamzExEveFiQbSreAsg/large_dandelion.jpg" alt=""  />
</p>
<p>Sempi wasn&rsquo;t all too interested but he wanted me to blow the rest. His stipulation was I have to blow the rest with my nose and not with my mouth. </p>
<p>So I rose to the challenge and took a deep breath and blew air through my nose as hard as I could. I forgot this is allergy season and I have a runny nose. </p>
<p>The next few minutes were spent on wiping my mustache, lips and my shirt that were covered in snot.</p>
<p>Yoshi and Sempi thought it was the most hilarious thing they&rsquo;ve seen. I took solace in the fact that no one else was around to witness the debacle. </p>
<p>For anyone who is curious, the dandelion was totally unaffected by all of this. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 3yo</title>
      <link>https://amjith.com/blog/conversations-with-a-3yo-1/</link>
      <pubDate>Sun, 10 Apr 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-3yo-1/</guid>
      <description>&lt;p&gt;Sempi and I are playing with a &lt;a href=&#34;http://www.amazon.com/Marble-Run-durable-pieces-marbles/dp/B002OFCW5A&#34;&gt;marble run&lt;/a&gt; game. I just built a pretty complex structure. I was quite proud of my creation. &lt;/p&gt;
&lt;p&gt;Me: Sempi, look at this run that I built. Is it pretty cool or is it pretty cool?&lt;/p&gt;
&lt;p&gt;Sempi: Appa, pretty cool and pretty cool are the same thing. &lt;/p&gt;
&lt;p&gt;Tread carefully when fishing for compliments from a toddler.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi and I are playing with a <a href="http://www.amazon.com/Marble-Run-durable-pieces-marbles/dp/B002OFCW5A">marble run</a> game. I just built a pretty complex structure. I was quite proud of my creation. </p>
<p>Me: Sempi, look at this run that I built. Is it pretty cool or is it pretty cool?</p>
<p>Sempi: Appa, pretty cool and pretty cool are the same thing. </p>
<p>Tread carefully when fishing for compliments from a toddler.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Dinosaur Story by a little Dr. Suess</title>
      <link>https://amjith.com/blog/dinosaur-story-by-a-little-dr-suess/</link>
      <pubDate>Sat, 26 Mar 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/dinosaur-story-by-a-little-dr-suess/</guid>
      <description>&lt;p&gt;Sempi and I are at the swap n&#39; play (an indoor play area). He&amp;rsquo;s playing with a crane toy and I&amp;rsquo;m sitting on a chair staring at my phone. &lt;/p&gt;
&lt;p&gt;He deicides to rescue me from my boredom and brings three dinosaur toys to me and says &amp;ldquo;Appa, here, play with me&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;So I join him at the table with three dinosaurs. Here&amp;rsquo;s the ensuing conversation: &lt;/p&gt;
&lt;p&gt;Me: Here&amp;rsquo;s a Triceratops, it says, &amp;ldquo;Woof, Woof&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;Sempi: ???&lt;/p&gt;
&lt;p&gt;Me: Here&amp;rsquo;s a Stegosaurs, &amp;ldquo;Oink, Oink&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;Sempi: *intent stare*&lt;/p&gt;
&lt;p&gt;Me: Here&amp;rsquo;s a Brontosaurus, &amp;ldquo;Mooo, Mooo&amp;rdquo;&lt;/p&gt;
&lt;p&gt;Sempi: No appa, this one says &amp;ldquo;Grooo&amp;rdquo;, this one says &amp;ldquo;Bloooo&amp;rdquo; and this one says &amp;ldquo;Octopus Stew&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;My little Dr. Suess with his rhyming stories.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi and I are at the swap n' play (an indoor play area). He&rsquo;s playing with a crane toy and I&rsquo;m sitting on a chair staring at my phone. </p>
<p>He deicides to rescue me from my boredom and brings three dinosaur toys to me and says &ldquo;Appa, here, play with me&rdquo;.</p>
<p>So I join him at the table with three dinosaurs. Here&rsquo;s the ensuing conversation: </p>
<p>Me: Here&rsquo;s a Triceratops, it says, &ldquo;Woof, Woof&rdquo;. </p>
<p>Sempi: ???</p>
<p>Me: Here&rsquo;s a Stegosaurs, &ldquo;Oink, Oink&rdquo;. </p>
<p>Sempi: *intent stare*</p>
<p>Me: Here&rsquo;s a Brontosaurus, &ldquo;Mooo, Mooo&rdquo;</p>
<p>Sempi: No appa, this one says &ldquo;Grooo&rdquo;, this one says &ldquo;Bloooo&rdquo; and this one says &ldquo;Octopus Stew&rdquo;. </p>
<p>My little Dr. Suess with his rhyming stories.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Jurassic Park with a twist</title>
      <link>https://amjith.com/blog/jurassic-park-with-a-twist/</link>
      <pubDate>Sat, 26 Mar 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/jurassic-park-with-a-twist/</guid>
      <description>&lt;p&gt;This is a continuation of our previous &lt;a href=&#34;https://amjith.com/blog/dinosaur-story-by-a-little-dr-suess&#34;&gt;story&lt;/a&gt;. Sempi and I are still at the Swap n Play. He&amp;rsquo;s still playing with his cranes and trucks and I&amp;rsquo;m still playing with three dinosaurs. &lt;/p&gt;
&lt;p&gt;Sempi: Appa my crane is going to help build a fence around the dinosaurs. &lt;/p&gt;
&lt;p&gt;Me: Oh yeah?&lt;/p&gt;
&lt;p&gt;Sempi: Yeah people can come and milk the dinosaurs. &lt;/p&gt;
&lt;p&gt;Me: Milk the dinosaurs? &lt;/p&gt;
&lt;p&gt;Sempi: Yeah, like milking a cow, they can milk a dinosaur and drink it. &lt;/p&gt;
&lt;p&gt;He&amp;rsquo;s gonna be so disappointed when he finds out dinosaurs are not mammals. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>This is a continuation of our previous <a href="https://amjith.com/blog/dinosaur-story-by-a-little-dr-suess">story</a>. Sempi and I are still at the Swap n Play. He&rsquo;s still playing with his cranes and trucks and I&rsquo;m still playing with three dinosaurs. </p>
<p>Sempi: Appa my crane is going to help build a fence around the dinosaurs. </p>
<p>Me: Oh yeah?</p>
<p>Sempi: Yeah people can come and milk the dinosaurs. </p>
<p>Me: Milk the dinosaurs? </p>
<p>Sempi: Yeah, like milking a cow, they can milk a dinosaur and drink it. </p>
<p>He&rsquo;s gonna be so disappointed when he finds out dinosaurs are not mammals. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Raising a Rebel</title>
      <link>https://amjith.com/blog/raising-a-rebel/</link>
      <pubDate>Sun, 13 Mar 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/raising-a-rebel/</guid>
      <description>&lt;p&gt;A good friend of mine sent me this &lt;a href=&#34;http://www.npr.org/sections/ed/2016/03/12/467976865/how-adults-can-encourage-kids-to-be-original-thinkers&#34;&gt;article&lt;/a&gt; after reading my previous &lt;a href=&#34;https://amjith.com/blog/can-i-raise-a-rebel&#34;&gt;ramble&lt;/a&gt;. Here are some choice snippets from that article that resonated with me.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Values not Rules:&lt;/strong&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Focus on teaching values than rules. Instead of, &amp;ldquo;Here&amp;rsquo;s the list of things that you&amp;rsquo;re allowed to do and not to do,&amp;rdquo; say, &amp;ldquo;Here are the principles that are important in this family, and let&amp;rsquo;s talk about how you want to express them.&amp;rdquo;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I have been guilty of creating or enforcing rules.&lt;/p&gt;
&lt;p&gt;I am not a rebel in any stretch of imagination. But even I refuse to follow rules without getting a background for why that rule exists. I have to buy into a process in order to follow it. It is only fair that I provide the same for my son. This does not mean there are no more rules, but every rule will come with an explanation. &lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&amp;ldquo;Here are the rules we have. And this is what they mean to us. This is how they really connect with our core values.&amp;rdquo;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;strong&gt;Conditionals not Absolutes:&lt;/strong&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&amp;ldquo;Kids are much more likely to think in original ways if you teach them in conditionals rather than in absolutes.&amp;rdquo;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Instead of saying, &amp;ldquo;This is a book,&amp;rdquo; teach them, &amp;ldquo;This could be a book.&amp;rdquo;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;In other words, teach a child to question the assumptions rather than accepting that there is one right answer. This reminds me of the &lt;a href=&#34;https://en.wikipedia.org/wiki/Candle_problem&#34;&gt;Candle problem&lt;/a&gt;. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Brain writing not Brainstorming:&lt;/strong&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;If you take five students and put them in a brainstorming group together, you will get fewer ideas and less original ideas than if you had taken those same five students and let them work independently, in separate rooms, by themselves.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;You put kids in separate rooms, what you get is all of the ideas on the table, and then you can bring the group together for what the group does best, which is the wisdom of crowds. The evaluating.&lt;/p&gt;
&lt;p&gt;That technique is actually called brain writing.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;This is a suggestion for a classroom setting but I think it has great potential for adult teams at work. Imagine coming to a meeting with a your ideas written down and debating the merits of each idea instead of coming up with ideas in a meeting and having to defend it at once.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Procrastination can lead to originality:&lt;/strong&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Great originality comes from being quick to start but slow to finish. That when you dive right into a task, you close yourself off to incubation. If you finish early, you&amp;rsquo;re stuck only with your most conventional ideas, your first ones.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I want to thank Paul for sending me the &lt;a href=&#34;http://www.npr.org/sections/ed/2016/03/12/467976865/how-adults-can-encourage-kids-to-be-original-thinkers?utm_campaign=storyshare&#34;&gt;article&lt;/a&gt;. I think I&amp;rsquo;ve picked up a few neat tricks. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>A good friend of mine sent me this <a href="http://www.npr.org/sections/ed/2016/03/12/467976865/how-adults-can-encourage-kids-to-be-original-thinkers">article</a> after reading my previous <a href="https://amjith.com/blog/can-i-raise-a-rebel">ramble</a>. Here are some choice snippets from that article that resonated with me.</p>
<p><strong>Values not Rules:</strong></p>
<blockquote>
<p>Focus on teaching values than rules. Instead of, &ldquo;Here&rsquo;s the list of things that you&rsquo;re allowed to do and not to do,&rdquo; say, &ldquo;Here are the principles that are important in this family, and let&rsquo;s talk about how you want to express them.&rdquo;</p>
</blockquote>
<p>I have been guilty of creating or enforcing rules.</p>
<p>I am not a rebel in any stretch of imagination. But even I refuse to follow rules without getting a background for why that rule exists. I have to buy into a process in order to follow it. It is only fair that I provide the same for my son. This does not mean there are no more rules, but every rule will come with an explanation. </p>
<blockquote>
<p>&ldquo;Here are the rules we have. And this is what they mean to us. This is how they really connect with our core values.&rdquo;</p>
</blockquote>
<p><strong>Conditionals not Absolutes:</strong></p>
<blockquote>
<p>&ldquo;Kids are much more likely to think in original ways if you teach them in conditionals rather than in absolutes.&rdquo;</p>
</blockquote>
<blockquote>
<p>Instead of saying, &ldquo;This is a book,&rdquo; teach them, &ldquo;This could be a book.&rdquo;</p>
</blockquote>
<p>In other words, teach a child to question the assumptions rather than accepting that there is one right answer. This reminds me of the <a href="https://en.wikipedia.org/wiki/Candle_problem">Candle problem</a>. </p>
<p><strong>Brain writing not Brainstorming:</strong></p>
<blockquote>
<p>If you take five students and put them in a brainstorming group together, you will get fewer ideas and less original ideas than if you had taken those same five students and let them work independently, in separate rooms, by themselves.</p>
</blockquote>
<blockquote>
<p>You put kids in separate rooms, what you get is all of the ideas on the table, and then you can bring the group together for what the group does best, which is the wisdom of crowds. The evaluating.</p>
<p>That technique is actually called brain writing.</p>
</blockquote>
<p>This is a suggestion for a classroom setting but I think it has great potential for adult teams at work. Imagine coming to a meeting with a your ideas written down and debating the merits of each idea instead of coming up with ideas in a meeting and having to defend it at once.</p>
<p><strong>Procrastination can lead to originality:</strong></p>
<blockquote>
<p>Great originality comes from being quick to start but slow to finish. That when you dive right into a task, you close yourself off to incubation. If you finish early, you&rsquo;re stuck only with your most conventional ideas, your first ones.</p>
</blockquote>
<p>I want to thank Paul for sending me the <a href="http://www.npr.org/sections/ed/2016/03/12/467976865/how-adults-can-encourage-kids-to-be-original-thinkers?utm_campaign=storyshare">article</a>. I think I&rsquo;ve picked up a few neat tricks. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Alternate Solution</title>
      <link>https://amjith.com/blog/alternate-solution/</link>
      <pubDate>Sat, 12 Mar 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/alternate-solution/</guid>
      <description>&lt;p&gt;Sempi and I are playing with Legos. I&amp;rsquo;m building a small mars rover for him, which he has tasked me to redo for the fifth time because it didn&amp;rsquo;t quite measure up to his satisfaction.&lt;/p&gt;
&lt;p&gt;In a desperate attempt to impress him, I started building yet again. I noticed I only had one of the 6 hole blocks and needed a matching pair to finish my model. I asked Sempi if he could find me the matching pair. He took that piece I had in my hand, looked around him to see if can spot it&amp;rsquo;s match. Then threw it away and told me, &amp;ldquo;Appa, you don&amp;rsquo;t need that piece&amp;rdquo;. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi and I are playing with Legos. I&rsquo;m building a small mars rover for him, which he has tasked me to redo for the fifth time because it didn&rsquo;t quite measure up to his satisfaction.</p>
<p>In a desperate attempt to impress him, I started building yet again. I noticed I only had one of the 6 hole blocks and needed a matching pair to finish my model. I asked Sempi if he could find me the matching pair. He took that piece I had in my hand, looked around him to see if can spot it&rsquo;s match. Then threw it away and told me, &ldquo;Appa, you don&rsquo;t need that piece&rdquo;. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Can I raise a rebel?</title>
      <link>https://amjith.com/blog/can-i-raise-a-rebel/</link>
      <pubDate>Sun, 28 Feb 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/can-i-raise-a-rebel/</guid>
      <description>&lt;p&gt;My son recently started going to a Montessori pre-school. It&amp;rsquo;s a great &lt;a href=&#34;http://www.wholechildmontessori.org/&#34;&gt;school&lt;/a&gt; and I have nothing but great things to say about the teachers and the administrator. &lt;/p&gt;
&lt;p&gt;They perform various activities in class which starts with simple things such as cleaning a set of wooden blocks, then building shapes from it etc. The idea is to learn from the larger community of fellow students and learn how to behave in his community (his classroom). He is taught good manners such as covering his mouth when he coughs, conflict resolution and sharing. It is working remarkably well. I&amp;rsquo;ve noticed that he now waits his turn to play with a toy instead of grabbing it from the other kid or asks the other kid if he could play with it when they&amp;rsquo;re done. I beam with pride when he does that. &lt;/p&gt;
&lt;p&gt;But I&amp;rsquo;ve often wondered if it is the right education style for him. The Montessori principle as I understand is that the kids learn through work. It is a very disciplined system and I&amp;rsquo;ve often heard guides (teachers) say phrases such as &amp;ldquo;No, that is not an option&amp;rdquo; when the student tries to test the boundaries.&lt;/p&gt;
&lt;p&gt;I am of the opinion that &amp;ldquo;Well-behaved kids rarely make history&amp;rdquo;. I love the fact that when I ask him &amp;ldquo;Would you like one pancake or two?&amp;rdquo; he answers &amp;ldquo;Three&amp;rdquo;. He reminds me of Calvin and Hobbes. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1665976/KnqdFPAfKM-Mfg-wx8z7uWsjxVs/large_calvin.png&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I wonder if the classroom is training him to fit well in his community thus training him to be a sheep.&lt;/p&gt;
&lt;p&gt;I definitely don&amp;rsquo;t want my son to grow up to be a felon, but at the same time I don&amp;rsquo;t want him totally domesticated either.&lt;/p&gt;
&lt;p&gt;I trust the teachers in his class to balance the discipline with creativity thus helping him grow as a well-adjusted individual whose creativity isn&amp;rsquo;t extinguished. &lt;/p&gt;
&lt;p&gt;As a parent how can I do to help them achieve this goal? Are there measures that I should follow to check his progress in both lanes?&lt;/p&gt;
&lt;p&gt;How can I encourage him to push the boundaries without burning himself severely? Can I test his boundaries by suggesting rule breaking? &lt;/p&gt;
&lt;p&gt;I would love to hear the thoughts of fellow parents or teachers. &lt;/p&gt;
&lt;p&gt;If you have suggestions please get in touch &lt;a href=&#34;mailto:amjith.r@gmail.com&#34;&gt;amjith.r@gmail.com&lt;/a&gt; or twitter: &lt;a href=&#34;https://twitter.com/amjithr&#34;&gt;@amjithr&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;ps: I should point out that this is my own opinion and Yoshi (my wife) doesn&amp;rsquo;t quite agree.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>My son recently started going to a Montessori pre-school. It&rsquo;s a great <a href="http://www.wholechildmontessori.org/">school</a> and I have nothing but great things to say about the teachers and the administrator. </p>
<p>They perform various activities in class which starts with simple things such as cleaning a set of wooden blocks, then building shapes from it etc. The idea is to learn from the larger community of fellow students and learn how to behave in his community (his classroom). He is taught good manners such as covering his mouth when he coughs, conflict resolution and sharing. It is working remarkably well. I&rsquo;ve noticed that he now waits his turn to play with a toy instead of grabbing it from the other kid or asks the other kid if he could play with it when they&rsquo;re done. I beam with pride when he does that. </p>
<p>But I&rsquo;ve often wondered if it is the right education style for him. The Montessori principle as I understand is that the kids learn through work. It is a very disciplined system and I&rsquo;ve often heard guides (teachers) say phrases such as &ldquo;No, that is not an option&rdquo; when the student tries to test the boundaries.</p>
<p>I am of the opinion that &ldquo;Well-behaved kids rarely make history&rdquo;. I love the fact that when I ask him &ldquo;Would you like one pancake or two?&rdquo; he answers &ldquo;Three&rdquo;. He reminds me of Calvin and Hobbes. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1665976/KnqdFPAfKM-Mfg-wx8z7uWsjxVs/large_calvin.png" alt=""  />
</p>
<p>I wonder if the classroom is training him to fit well in his community thus training him to be a sheep.</p>
<p>I definitely don&rsquo;t want my son to grow up to be a felon, but at the same time I don&rsquo;t want him totally domesticated either.</p>
<p>I trust the teachers in his class to balance the discipline with creativity thus helping him grow as a well-adjusted individual whose creativity isn&rsquo;t extinguished. </p>
<p>As a parent how can I do to help them achieve this goal? Are there measures that I should follow to check his progress in both lanes?</p>
<p>How can I encourage him to push the boundaries without burning himself severely? Can I test his boundaries by suggesting rule breaking? </p>
<p>I would love to hear the thoughts of fellow parents or teachers. </p>
<p>If you have suggestions please get in touch <a href="mailto:amjith.r@gmail.com">amjith.r@gmail.com</a> or twitter: <a href="https://twitter.com/amjithr">@amjithr</a></p>
<p>ps: I should point out that this is my own opinion and Yoshi (my wife) doesn&rsquo;t quite agree.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Sense of belonging</title>
      <link>https://amjith.com/blog/sense-of-belonging/</link>
      <pubDate>Wed, 17 Feb 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/sense-of-belonging/</guid>
      <description>&lt;p&gt;I am a big fan of &lt;a href=&#34;https://en.wikipedia.org/wiki/Nina_Simonehttp://&#34;&gt;Nina Simone&lt;/a&gt;. I like singing her songs out loud. Particularly this &lt;a href=&#34;https://www.youtube.com/watch?v=ua2k52n_Bvw&#34;&gt;song&lt;/a&gt; with the following lyrics: &lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I put a spell on you. &amp;lsquo;Coz you&amp;rsquo;re mine&amp;hellip;&amp;hellip;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I sing this song to Sempi with a twist. I sit him on the dining table for his breakfast and I sing&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I put a bib on you. &amp;lsquo;Coz you&amp;rsquo;re mine&amp;hellip;&amp;hellip;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I&amp;rsquo;ve been singing this to him ever since he could sit straight. This morning I sat him down and started singing as usual. He retorted. &lt;/p&gt;
&lt;p&gt;Sempi: I&amp;rsquo;m not yours. I belong to amma.&lt;/p&gt;
&lt;p&gt;Me: Oh yeah? Well your amma belongs to me.&lt;/p&gt;
&lt;p&gt;Sempi: And you belong to paati (his grandma, my mother). &lt;/p&gt;
&lt;p&gt;Me: Who does your paati belong to? &lt;/p&gt;
&lt;p&gt;Sempi: Paati belongs to Thatha (his grandpa, my dad). She puts a bib on Thatha. Because she belongs to Thatha.&lt;/p&gt;
&lt;p&gt;I cracked up when I imagined my dad wearing a bib, sitting on dining table waiting for his breakfast.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I am a big fan of <a href="https://en.wikipedia.org/wiki/Nina_Simonehttp://">Nina Simone</a>. I like singing her songs out loud. Particularly this <a href="https://www.youtube.com/watch?v=ua2k52n_Bvw">song</a> with the following lyrics: </p>
<blockquote>
<p>I put a spell on you. &lsquo;Coz you&rsquo;re mine&hellip;&hellip;.</p>
</blockquote>
<p>I sing this song to Sempi with a twist. I sit him on the dining table for his breakfast and I sing</p>
<blockquote>
<p>I put a bib on you. &lsquo;Coz you&rsquo;re mine&hellip;&hellip;.</p>
</blockquote>
<p>I&rsquo;ve been singing this to him ever since he could sit straight. This morning I sat him down and started singing as usual. He retorted. </p>
<p>Sempi: I&rsquo;m not yours. I belong to amma.</p>
<p>Me: Oh yeah? Well your amma belongs to me.</p>
<p>Sempi: And you belong to paati (his grandma, my mother). </p>
<p>Me: Who does your paati belong to? </p>
<p>Sempi: Paati belongs to Thatha (his grandpa, my dad). She puts a bib on Thatha. Because she belongs to Thatha.</p>
<p>I cracked up when I imagined my dad wearing a bib, sitting on dining table waiting for his breakfast.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Shortened names</title>
      <link>https://amjith.com/blog/shortened-names/</link>
      <pubDate>Sun, 17 Jan 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/shortened-names/</guid>
      <description>&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1641483/N6ESpQQbBRhXd0bdvNiynHfWPpI/large_trucks.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Sempi and Yoshi are playing with trucks. Sempi is showing off his collection of trucks. &lt;/p&gt;
&lt;p&gt;Sempi: This is a steam roller, an excavator, ass truck and a low boy.&lt;/p&gt;
&lt;p&gt;Yoshi: Ass truck? &lt;/p&gt;
&lt;p&gt;Sempi: Yeah it dumps out asphalt. &lt;/p&gt;
&lt;p&gt;Yoshi: Of all the trucks you could have abbreviated, you choose the asphalt truck&amp;hellip;?&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1641483/N6ESpQQbBRhXd0bdvNiynHfWPpI/large_trucks.jpeg" alt=""  />
</p>
<p>Sempi and Yoshi are playing with trucks. Sempi is showing off his collection of trucks. </p>
<p>Sempi: This is a steam roller, an excavator, ass truck and a low boy.</p>
<p>Yoshi: Ass truck? </p>
<p>Sempi: Yeah it dumps out asphalt. </p>
<p>Yoshi: Of all the trucks you could have abbreviated, you choose the asphalt truck&hellip;?</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Hug Machine</title>
      <link>https://amjith.com/blog/hug-machine/</link>
      <pubDate>Sun, 10 Jan 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/hug-machine/</guid>
      <description>&lt;p&gt;Yoshi is sitting on the floor wiping some of Sempi&amp;rsquo;s pee.&lt;/p&gt;
&lt;p&gt;Sempi runs up to her from behind and gives her a hug. &lt;/p&gt;
&lt;p&gt;Yoshi: Aw! Thank you sweetie. &lt;/p&gt;
&lt;p&gt;Sempi: I&amp;rsquo;m not hugging you, I&amp;rsquo;m waiting for my piggy back ride. &lt;/p&gt;
&lt;p&gt;Yoshi: Of course you are&amp;hellip;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Yoshi is sitting on the floor wiping some of Sempi&rsquo;s pee.</p>
<p>Sempi runs up to her from behind and gives her a hug. </p>
<p>Yoshi: Aw! Thank you sweetie. </p>
<p>Sempi: I&rsquo;m not hugging you, I&rsquo;m waiting for my piggy back ride. </p>
<p>Yoshi: Of course you are&hellip;</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Chocolate Juice</title>
      <link>https://amjith.com/blog/chocolate-juice/</link>
      <pubDate>Mon, 04 Jan 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/chocolate-juice/</guid>
      <description>&lt;p&gt;We&amp;rsquo;re potty training Sempi. You&amp;rsquo;ve been warned. &lt;/p&gt;
&lt;p&gt;Sempi: Appa would you like some chocolate juice. &lt;/p&gt;
&lt;p&gt;Me: Chocolate Juice? Sure. (I&amp;rsquo;m highly suspicious)&lt;/p&gt;
&lt;p&gt;Sempi: Come to the bathroom I&amp;rsquo;ll make you some chocolate juice. &lt;/p&gt;
&lt;p&gt;Me: (My suspicions were confirmed?)&lt;/p&gt;
&lt;p&gt;Sempi runs to the bathroom and uses the spring loaded toilet paper holder as his juicer. Makes blender sounds while pressing down on his juicer.&lt;/p&gt;
&lt;p&gt;Sempi: Here you go. (Hands me a pretend cup)&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m somewhat relieved. &lt;/p&gt;
&lt;p&gt;Sempi: I need your debit card to pay. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We&rsquo;re potty training Sempi. You&rsquo;ve been warned. </p>
<p>Sempi: Appa would you like some chocolate juice. </p>
<p>Me: Chocolate Juice? Sure. (I&rsquo;m highly suspicious)</p>
<p>Sempi: Come to the bathroom I&rsquo;ll make you some chocolate juice. </p>
<p>Me: (My suspicions were confirmed?)</p>
<p>Sempi runs to the bathroom and uses the spring loaded toilet paper holder as his juicer. Makes blender sounds while pressing down on his juicer.</p>
<p>Sempi: Here you go. (Hands me a pretend cup)</p>
<p>I&rsquo;m somewhat relieved. </p>
<p>Sempi: I need your debit card to pay. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Potty Creativity</title>
      <link>https://amjith.com/blog/potty-creativity/</link>
      <pubDate>Mon, 04 Jan 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/potty-creativity/</guid>
      <description>&lt;p&gt;This is part of Sempi&amp;rsquo;s potty training series.&lt;/p&gt;
&lt;p&gt;Today he successfully pooped in his portable potty.&lt;/p&gt;
&lt;p&gt;Sempi: Appa the poop looks like a hot dog. &lt;/p&gt;
&lt;p&gt;Me: Thanks man, thanks for that imagery. I&amp;rsquo;m glad I&amp;rsquo;m a vegetarian.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>This is part of Sempi&rsquo;s potty training series.</p>
<p>Today he successfully pooped in his portable potty.</p>
<p>Sempi: Appa the poop looks like a hot dog. </p>
<p>Me: Thanks man, thanks for that imagery. I&rsquo;m glad I&rsquo;m a vegetarian.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Orange Juice with p**p</title>
      <link>https://amjith.com/blog/orange-juice-with-p-star-star-p/</link>
      <pubDate>Fri, 01 Jan 2016 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/orange-juice-with-p-star-star-p/</guid>
      <description>&lt;p&gt;Happy New Year 2016&lt;/p&gt;
&lt;p&gt;Yoshi is baking a strawberry cake. I&amp;rsquo;m helping Sempi squeeze some oranges to make orange juice.&lt;/p&gt;
&lt;p&gt;Me: We&amp;rsquo;re almost done squeezing.&lt;/p&gt;
&lt;p&gt;Sempi: I like my orange juice with poop. &lt;/p&gt;
&lt;p&gt;Me: You what? &lt;/p&gt;
&lt;p&gt;Sempi: I like my orange juice with poooop. Pooolp.&lt;/p&gt;
&lt;p&gt;Me: Oh you mean pulp. I see. *phew*&lt;/p&gt;
&lt;p&gt;We had some delicious cake and drank orange juice with puuuulp.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Happy New Year 2016</p>
<p>Yoshi is baking a strawberry cake. I&rsquo;m helping Sempi squeeze some oranges to make orange juice.</p>
<p>Me: We&rsquo;re almost done squeezing.</p>
<p>Sempi: I like my orange juice with poop. </p>
<p>Me: You what? </p>
<p>Sempi: I like my orange juice with poooop. Pooolp.</p>
<p>Me: Oh you mean pulp. I see. *phew*</p>
<p>We had some delicious cake and drank orange juice with puuuulp.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Impatient Toddler</title>
      <link>https://amjith.com/blog/impatient-toddler/</link>
      <pubDate>Sun, 27 Dec 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/impatient-toddler/</guid>
      <description>&lt;p&gt;Days after Christmas, it starts snowing in Portland. We are all excited to stay in and watch the snow. &lt;/p&gt;
&lt;p&gt;I start to have a casual conversation with Yoshi&amp;rsquo;s belly (she&amp;rsquo;s pregnant). &lt;/p&gt;
&lt;p&gt;Me: Hey! Sleepy head. Wake up. Let&amp;rsquo;s see you kick.&lt;/p&gt;
&lt;p&gt;Me: Do you like Superman or Batman? &lt;/p&gt;
&lt;p&gt;Me: Do you like Garbage Truck or Dump Truck? &lt;/p&gt;
&lt;p&gt;Sempi drops his toys and comes running towards us.&lt;/p&gt;
&lt;p&gt;Yoshi: Appa is talking to Jelly Bean (name of the fetus). &lt;/p&gt;
&lt;p&gt;Sempi: Get out, Jelly bean. &lt;/p&gt;
&lt;p&gt;Runs back to his toys, content with the feeling that he has helped somehow.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Days after Christmas, it starts snowing in Portland. We are all excited to stay in and watch the snow. </p>
<p>I start to have a casual conversation with Yoshi&rsquo;s belly (she&rsquo;s pregnant). </p>
<p>Me: Hey! Sleepy head. Wake up. Let&rsquo;s see you kick.</p>
<p>Me: Do you like Superman or Batman? </p>
<p>Me: Do you like Garbage Truck or Dump Truck? </p>
<p>Sempi drops his toys and comes running towards us.</p>
<p>Yoshi: Appa is talking to Jelly Bean (name of the fetus). </p>
<p>Sempi: Get out, Jelly bean. </p>
<p>Runs back to his toys, content with the feeling that he has helped somehow.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 3 yo</title>
      <link>https://amjith.com/blog/conversations-with-a-3-yo/</link>
      <pubDate>Sun, 06 Dec 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-3-yo/</guid>
      <description>&lt;p&gt;Sempi is playing with his trucks. Yosh and I are having an adult conversation. Sempi feels left out.&lt;/p&gt;
&lt;p&gt;Sempi: Amma, you&amp;rsquo;re taking up too much space. &lt;/p&gt;
&lt;p&gt;Yoshi: Really? What do you want me to do? &lt;/p&gt;
&lt;p&gt;Sempi: You should move. &lt;/p&gt;
&lt;p&gt;Yoshi: Where do you want me to move? &lt;/p&gt;
&lt;p&gt;Sempi: Closer to me. :)&lt;/p&gt;
&lt;p&gt;That sly dog.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi is playing with his trucks. Yosh and I are having an adult conversation. Sempi feels left out.</p>
<p>Sempi: Amma, you&rsquo;re taking up too much space. </p>
<p>Yoshi: Really? What do you want me to do? </p>
<p>Sempi: You should move. </p>
<p>Yoshi: Where do you want me to move? </p>
<p>Sempi: Closer to me. :)</p>
<p>That sly dog.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>My little perfectionist</title>
      <link>https://amjith.com/blog/my-little-perfectionist/</link>
      <pubDate>Sun, 06 Dec 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/my-little-perfectionist/</guid>
      <description>&lt;p&gt;Lazy Sunday morning. Yoshi is making an origami star to adorn our one foot christmas tree. Sempi is sitting there watching the whole ordeal. &lt;/p&gt;
&lt;p&gt;Yoshi finishes the star and looks at it and says &lt;/p&gt;
&lt;p&gt;&amp;ldquo;This star is not perfect but who needs perfection&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;Sempi pipes up with &amp;ldquo;I do&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1618809/GacGI-H4DiAOA3N92UI19CsmdRU/large_christmas_tree.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Lazy Sunday morning. Yoshi is making an origami star to adorn our one foot christmas tree. Sempi is sitting there watching the whole ordeal. </p>
<p>Yoshi finishes the star and looks at it and says </p>
<p>&ldquo;This star is not perfect but who needs perfection&rdquo;. </p>
<p>Sempi pipes up with &ldquo;I do&rdquo;.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1618809/GacGI-H4DiAOA3N92UI19CsmdRU/large_christmas_tree.jpeg" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Life Lessons by a 3yo</title>
      <link>https://amjith.com/blog/hard-lessons-in-life-by-a-3yo/</link>
      <pubDate>Mon, 23 Nov 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/hard-lessons-in-life-by-a-3yo/</guid>
      <description>&lt;p&gt;Sempi is driving a toy fork lift with a load.&lt;/p&gt;
&lt;p&gt;Sempi: Appa I got a package for you.&lt;/p&gt;
&lt;p&gt;Me: OK, can I have it?&lt;/p&gt;
&lt;p&gt;Sempi: No! (Then drives away).&lt;/p&gt;
&lt;p&gt;Lesson learned, life can be hard sometimes, get used to it. Except, I am the one supposed to teach him life lessons.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi is driving a toy fork lift with a load.</p>
<p>Sempi: Appa I got a package for you.</p>
<p>Me: OK, can I have it?</p>
<p>Sempi: No! (Then drives away).</p>
<p>Lesson learned, life can be hard sometimes, get used to it. Except, I am the one supposed to teach him life lessons.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>3yo and God</title>
      <link>https://amjith.com/blog/3yo-and-god/</link>
      <pubDate>Sun, 22 Nov 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/3yo-and-god/</guid>
      <description>&lt;p&gt;We&amp;rsquo;re at our ancestral village attending a family function. The priest is chanting the mantras at the top of his voice. &lt;/p&gt;
&lt;p&gt;Sempi: Appa, why is he yelling at us? &lt;/p&gt;
&lt;p&gt;Me: He&amp;rsquo;s not yelling Sempi, he&amp;rsquo;s chanting. &lt;/p&gt;
&lt;p&gt;Sempi: Why? &lt;/p&gt;
&lt;p&gt;Me: He&amp;rsquo;s summoning God. &lt;/p&gt;
&lt;p&gt;Sempi: There is no God. &lt;/p&gt;
&lt;p&gt;Me: Hahaha. Who told you that? &lt;/p&gt;
&lt;p&gt;Sempi: You did. &lt;/p&gt;
&lt;p&gt;I don&amp;rsquo;t remember teaching him that, but I&amp;rsquo;m proud he got the message. :)&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We&rsquo;re at our ancestral village attending a family function. The priest is chanting the mantras at the top of his voice. </p>
<p>Sempi: Appa, why is he yelling at us? </p>
<p>Me: He&rsquo;s not yelling Sempi, he&rsquo;s chanting. </p>
<p>Sempi: Why? </p>
<p>Me: He&rsquo;s summoning God. </p>
<p>Sempi: There is no God. </p>
<p>Me: Hahaha. Who told you that? </p>
<p>Sempi: You did. </p>
<p>I don&rsquo;t remember teaching him that, but I&rsquo;m proud he got the message. :)</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 3 year old</title>
      <link>https://amjith.com/blog/conversations-with-a-3-year-old/</link>
      <pubDate>Sun, 08 Nov 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-3-year-old/</guid>
      <description>&lt;p&gt;We&amp;rsquo;re at a restaurant.&lt;/p&gt;
&lt;p&gt;Sempi: I want juice. &lt;/p&gt;
&lt;p&gt;Yoshi: I&amp;rsquo;ll get ice cream.&lt;/p&gt;
&lt;p&gt;Sempi: I want juice &lt;strong&gt;and&lt;/strong&gt; ice cream.&lt;/p&gt;
&lt;p&gt;Me: Would you also like a pony and a unicorn? &lt;/p&gt;
&lt;p&gt;Sempi: No I wouldn&amp;rsquo;t. They&amp;rsquo;re not food Appa.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We&rsquo;re at a restaurant.</p>
<p>Sempi: I want juice. </p>
<p>Yoshi: I&rsquo;ll get ice cream.</p>
<p>Sempi: I want juice <strong>and</strong> ice cream.</p>
<p>Me: Would you also like a pony and a unicorn? </p>
<p>Sempi: No I wouldn&rsquo;t. They&rsquo;re not food Appa.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Pickles</title>
      <link>https://amjith.com/blog/pickles/</link>
      <pubDate>Sun, 08 Nov 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/pickles/</guid>
      <description>&lt;p&gt;Sempi loves pickles. He&amp;rsquo;d eat them at every chance. &lt;/p&gt;
&lt;p&gt;We&amp;rsquo;re at an indoor play place in Chennai. We ordered some fried potato wedges. When they were delivered, Sempi exclaims &amp;ldquo;Appa, I found &lt;strong&gt;bread pickles&lt;/strong&gt;&amp;rdquo;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi loves pickles. He&rsquo;d eat them at every chance. </p>
<p>We&rsquo;re at an indoor play place in Chennai. We ordered some fried potato wedges. When they were delivered, Sempi exclaims &ldquo;Appa, I found <strong>bread pickles</strong>&rdquo;.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 3yo</title>
      <link>https://amjith.com/blog/conversations-with-a-3yo/</link>
      <pubDate>Sun, 25 Oct 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-3yo/</guid>
      <description>&lt;p&gt;We&amp;rsquo;re at a park in India. Sempi is sitting on a teeter-totter looking contraption. He&amp;rsquo;s looking for a partner for the other side. &lt;/p&gt;
&lt;p&gt;Sempi: Amma can you sit on the other side? &lt;/p&gt;
&lt;p&gt;Yoshi: I&amp;rsquo;m too big to sit on that side Sempi. &lt;/p&gt;
&lt;p&gt;Sempi: Appa, can you sit on that side?&lt;/p&gt;
&lt;p&gt;Me: I&amp;rsquo;m flattered that you think I&amp;rsquo;m smaller than your mom. But I&amp;rsquo;m still too big.&lt;/p&gt;
&lt;p&gt;Sempi: Maybe when you&amp;rsquo;re flatter you can sit on the other side. &lt;/p&gt;
&lt;p&gt;It was an unintentional pun joke, but I laughed heartily.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We&rsquo;re at a park in India. Sempi is sitting on a teeter-totter looking contraption. He&rsquo;s looking for a partner for the other side. </p>
<p>Sempi: Amma can you sit on the other side? </p>
<p>Yoshi: I&rsquo;m too big to sit on that side Sempi. </p>
<p>Sempi: Appa, can you sit on that side?</p>
<p>Me: I&rsquo;m flattered that you think I&rsquo;m smaller than your mom. But I&rsquo;m still too big.</p>
<p>Sempi: Maybe when you&rsquo;re flatter you can sit on the other side. </p>
<p>It was an unintentional pun joke, but I laughed heartily.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Adventures with a 2yo</title>
      <link>https://amjith.com/blog/adventures-with-a-2yo/</link>
      <pubDate>Thu, 08 Oct 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/adventures-with-a-2yo/</guid>
      <description>&lt;p&gt;Conversation between Yoshi and I. &lt;/p&gt;
&lt;p&gt;Yoshi: I&amp;rsquo;m worried Sempi (our 2yo) might be a little dyslexic. &lt;/p&gt;
&lt;p&gt;Me: Why? &lt;/p&gt;
&lt;p&gt;Yoshi: He occasionally reverses the words in his rhymes.&lt;/p&gt;
&lt;p&gt;Me: Like what? &lt;/p&gt;
&lt;p&gt;Yoshi: &amp;quot;Frosty the snow man was a happy jolly soul&amp;quot; . It&amp;rsquo;s supposed to be &amp;ldquo;Jolly happy soul&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;Me: Oh yeah. He could be dyslexic or he could have a troll dad who subtly changes his rhymes to see if he&amp;rsquo;ll catch it.  (sheepish grin)&lt;/p&gt;
&lt;p&gt;Yoshi: Oh boy. What else did you teach him?&lt;/p&gt;
&lt;p&gt;Me: I&amp;rsquo;m trying &amp;ldquo;Itsy bitsy tiger&amp;rdquo;, &amp;ldquo;Row row, row the boat gently down the street&amp;rdquo; and so on. &lt;/p&gt;
&lt;p&gt;#ProudDad. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Conversation between Yoshi and I. </p>
<p>Yoshi: I&rsquo;m worried Sempi (our 2yo) might be a little dyslexic. </p>
<p>Me: Why? </p>
<p>Yoshi: He occasionally reverses the words in his rhymes.</p>
<p>Me: Like what? </p>
<p>Yoshi: &quot;Frosty the snow man was a happy jolly soul&quot; . It&rsquo;s supposed to be &ldquo;Jolly happy soul&rdquo;. </p>
<p>Me: Oh yeah. He could be dyslexic or he could have a troll dad who subtly changes his rhymes to see if he&rsquo;ll catch it.  (sheepish grin)</p>
<p>Yoshi: Oh boy. What else did you teach him?</p>
<p>Me: I&rsquo;m trying &ldquo;Itsy bitsy tiger&rdquo;, &ldquo;Row row, row the boat gently down the street&rdquo; and so on. </p>
<p>#ProudDad. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 2yo</title>
      <link>https://amjith.com/blog/conversations-with-a-2yo-2/</link>
      <pubDate>Fri, 21 Aug 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-2yo-2/</guid>
      <description>&lt;p&gt;Sempi is playing in his room with some construction cones and trucks. He usually narrates his gameplay. &lt;/p&gt;
&lt;p&gt;I walk into the room and right at the moment he says: &lt;/p&gt;
&lt;p&gt;&amp;ldquo;Caution! Caution! Oversize load&amp;rdquo;&lt;/p&gt;
&lt;p&gt;I wonder if it&amp;rsquo;s coincidence or subliminal messaging. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi is playing in his room with some construction cones and trucks. He usually narrates his gameplay. </p>
<p>I walk into the room and right at the moment he says: </p>
<p>&ldquo;Caution! Caution! Oversize load&rdquo;</p>
<p>I wonder if it&rsquo;s coincidence or subliminal messaging. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 2yo</title>
      <link>https://amjith.com/blog/conversations-with-a-2yo-1/</link>
      <pubDate>Wed, 12 Aug 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-2yo-1/</guid>
      <description>&lt;p&gt;Yoshi: Let me cut that chocolate bar in half. &lt;/p&gt;
&lt;p&gt;Sempi: Why?&lt;/p&gt;
&lt;p&gt;Yoshi: Because it is too much.&lt;/p&gt;
&lt;p&gt;Sempi: I want too much. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Yoshi: Let me cut that chocolate bar in half. </p>
<p>Sempi: Why?</p>
<p>Yoshi: Because it is too much.</p>
<p>Sempi: I want too much. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 2yo</title>
      <link>https://amjith.com/blog/conversations-with-a-2yo/</link>
      <pubDate>Thu, 02 Jul 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-2yo/</guid>
      <description>&lt;p&gt;Fine summer evening, I&amp;rsquo;m taking Sempi on a walk. He&amp;rsquo;s carrying a flash light and shining it on every piece of object on the side walk and asking me questions. &lt;/p&gt;
&lt;p&gt;Sempi: Appa, what is this? &lt;/p&gt;
&lt;p&gt;Me: It&amp;rsquo;s a rock.&lt;/p&gt;
&lt;p&gt;Sempi: Oh. What is this? &lt;/p&gt;
&lt;p&gt;Me: That&amp;rsquo;s a piece of paper.&lt;/p&gt;
&lt;p&gt;Sempi: Oh. What is this? &lt;/p&gt;
&lt;p&gt;Me: It&amp;rsquo;s a cigarette. Actually it&amp;rsquo;s a cigarette butt. &lt;/p&gt;
&lt;p&gt;Sempi: Huh? Do you keep it in the butt? &lt;/p&gt;
&lt;p&gt;Me: Hahahaha. No. Sempi. *Still laughing uncontrollably*&lt;/p&gt;
&lt;p&gt;Sempi: Hehehe. *Starts laughing*&lt;/p&gt;
&lt;p&gt;He knows when he&amp;rsquo;s made a joke, even though he has no clue why it&amp;rsquo;s funny.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Fine summer evening, I&rsquo;m taking Sempi on a walk. He&rsquo;s carrying a flash light and shining it on every piece of object on the side walk and asking me questions. </p>
<p>Sempi: Appa, what is this? </p>
<p>Me: It&rsquo;s a rock.</p>
<p>Sempi: Oh. What is this? </p>
<p>Me: That&rsquo;s a piece of paper.</p>
<p>Sempi: Oh. What is this? </p>
<p>Me: It&rsquo;s a cigarette. Actually it&rsquo;s a cigarette butt. </p>
<p>Sempi: Huh? Do you keep it in the butt? </p>
<p>Me: Hahahaha. No. Sempi. *Still laughing uncontrollably*</p>
<p>Sempi: Hehehe. *Starts laughing*</p>
<p>He knows when he&rsquo;s made a joke, even though he has no clue why it&rsquo;s funny.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>FuzzyFinder - in 10 lines of Python</title>
      <link>https://amjith.com/blog/fuzzyfinder-in-10-lines-of-python/</link>
      <pubDate>Mon, 22 Jun 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/fuzzyfinder-in-10-lines-of-python/</guid>
      <description>&lt;h1 id=&#34;introduction&#34;&gt;Introduction:&lt;/h1&gt;
&lt;p&gt;FuzzyFinder is a popular feature available in decent editors to open files. The idea is to start typing partial strings from the full path and the list of suggestions will be narrowed down to match the desired file. &lt;/p&gt;
&lt;p&gt;Examples: &lt;/p&gt;
&lt;p&gt;Vim (Ctrl-P)&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1468562/v2hh-J443fIzsstdfU5cc_jszb8/large_vim-ctrl-p.gif&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Sublime Text (Cmd-P)&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1468563/LIitkIbiuCIz5cZH27rLJ0qGkgA/large_subl-cmd-p.gif&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;This is an extremely useful feature and it&amp;rsquo;s quite easy to implement.&lt;/p&gt;
&lt;h1 id=&#34;problem-statement&#34;&gt;Problem Statement:&lt;/h1&gt;
&lt;p&gt;We have a collection of strings (filenames). We&amp;rsquo;re trying to filter down that collection based on user input. The user input can be partial strings from the filename. Let&amp;rsquo;s walk this through with an example. Here is a collection of filenames:&lt;/p&gt;
&lt;p&gt;This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
&lt;a href=&#34;https://github.co/hiddenchars&#34;&gt;Learn more about bidirectional Unicode characters&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;[Show hidden characters]({{ revealButtonHref }})&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; collection = [&amp;lsquo;django_migrations.py&amp;rsquo;,&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;django_admin_log.py&amp;rsquo;,&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;main_generator.py&amp;rsquo;,&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;migrations.py&amp;rsquo;,&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;api_user.doc&amp;rsquo;,&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;user_group.doc&amp;rsquo;,&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;accounts.txt&amp;rsquo;,&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;]&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;a href=&#34;https://gist.github.com/amjith/f0d4fa57e6e47d0e1e9c/raw/67138107e3f87991cc006b73ecc826d618f7842c/file_list.py&#34;&gt;view raw&lt;/a&gt;
&lt;a href=&#34;https://gist.github.com/amjith/f0d4fa57e6e47d0e1e9c#file-file_list-py&#34;&gt;file_list.py&lt;/a&gt;
hosted with ❤ by &lt;a href=&#34;https://github.com&#34;&gt;GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;When the user types &amp;lsquo;djm&amp;rsquo; we are supposed to match &amp;lsquo;&lt;strong&gt;dj&lt;/strong&gt;ango_&lt;strong&gt;m&lt;/strong&gt;igrations.py&amp;rsquo; and &amp;lsquo;&lt;strong&gt;dj&lt;/strong&gt;ango_ad&lt;strong&gt;m&lt;/strong&gt;in_log.py&amp;rsquo;. The simplest route to achieve this is to use regular expressions. &lt;/p&gt;
&lt;h1 id=&#34;solutions&#34;&gt;Solutions:&lt;/h1&gt;
&lt;h3 id=&#34;naive-regex-matching&#34;&gt;Naive Regex Matching:&lt;/h3&gt;
&lt;p&gt;Convert &amp;lsquo;djm&amp;rsquo; into &amp;rsquo;d.*j.*m&#39; and try to match this regex against every item in the list. Items that match are the possible candidates.&lt;/p&gt;
&lt;p&gt;This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
&lt;a href=&#34;https://github.co/hiddenchars&#34;&gt;Learn more about bidirectional Unicode characters&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;[Show hidden characters]({{ revealButtonHref }})&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; import re # regex module from standard library.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; def fuzzyfinder(user_input, collection):&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;suggestions = []&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;pattern = &amp;lsquo;.*&#39;.join(user_input) # Converts &amp;lsquo;djm&amp;rsquo; to &amp;rsquo;d.*j.*m&amp;rsquo;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;regex = re.compile(pattern) # Compiles a regex.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;for item in collection:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;match = regex.search(item) # Checks if the current item matches the regex.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;if match:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;suggestions.append(item)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;return suggestions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; print fuzzyfinder(&amp;lsquo;djm&amp;rsquo;, collection)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;[&amp;lsquo;django_migrations.py&amp;rsquo;, &amp;lsquo;django_admin_log.py&amp;rsquo;]&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; print fuzzyfinder(&amp;lsquo;mig&amp;rsquo;, collection)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;[&amp;lsquo;django_migrations.py&amp;rsquo;, &amp;lsquo;django_admin_log.py&amp;rsquo;, &amp;lsquo;main_generator.py&amp;rsquo;, &amp;lsquo;migrations.py&amp;rsquo;]&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;a href=&#34;https://gist.github.com/amjith/cf79e9a66d9867a1fee4/raw/478f146034bfbd9fad7b12b374686d91ba5bbae8/naive_regex.py&#34;&gt;view raw&lt;/a&gt;
&lt;a href=&#34;https://gist.github.com/amjith/cf79e9a66d9867a1fee4#file-naive_regex-py&#34;&gt;naive_regex.py&lt;/a&gt;
hosted with ❤ by &lt;a href=&#34;https://github.com&#34;&gt;GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This got us the desired results for input &amp;lsquo;djm&amp;rsquo;. But the suggestions are not ranked in any particular order.&lt;/p&gt;
&lt;p&gt;In fact, for the second example with user input &amp;lsquo;mig&amp;rsquo; the best possible suggestion &amp;lsquo;migrations.py&amp;rsquo; was listed as the last item in the result.&lt;/p&gt;
&lt;h3 id=&#34;ranking-based-on-match-position&#34;&gt;Ranking based on match position:&lt;/h3&gt;
&lt;p&gt;We can rank the results based on the position of the first occurrence of the matching character. For user input &amp;lsquo;mig&amp;rsquo; the position of the matching characters are as follows:&lt;/p&gt;
&lt;p&gt;This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
&lt;a href=&#34;https://github.co/hiddenchars&#34;&gt;Learn more about bidirectional Unicode characters&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;[Show hidden characters]({{ revealButtonHref }})&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;main_generator.py&amp;rsquo; - 0&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;migrations.py&amp;rsquo; - 0&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;django_migrations.py&amp;rsquo; - 7&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;django_admin_log.py&amp;rsquo; - 9&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;a href=&#34;https://gist.github.com/amjith/ea535287d22a9b7cf35a/raw/231ce950b82d2ca6d9a2b1b4331b1c0cf6baed46/position_of_match.py&#34;&gt;view raw&lt;/a&gt;
&lt;a href=&#34;https://gist.github.com/amjith/ea535287d22a9b7cf35a#file-position_of_match-py&#34;&gt;position_of_match.py&lt;/a&gt;
hosted with ❤ by &lt;a href=&#34;https://github.com&#34;&gt;GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Here&amp;rsquo;s the code:&lt;/p&gt;
&lt;p&gt;This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
&lt;a href=&#34;https://github.co/hiddenchars&#34;&gt;Learn more about bidirectional Unicode characters&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;[Show hidden characters]({{ revealButtonHref }})&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; import re # regex module from standard library.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; def fuzzyfinder(user_input, collection):&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;suggestions = []&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;pattern = &amp;lsquo;.*&#39;.join(user_input) # Converts &amp;lsquo;djm&amp;rsquo; to &amp;rsquo;d.*j.*m&amp;rsquo;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;regex = re.compile(pattern) # Compiles a regex.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;for item in collection:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;match = regex.search(item) # Checks if the current item matches the regex.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;if match:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;suggestions.append((match.start(), item))&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;return [x for _, x in sorted(suggestions)]&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; print fuzzyfinder(&amp;lsquo;mig&amp;rsquo;, collection)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;[&amp;lsquo;main_generator.py&amp;rsquo;, &amp;lsquo;migrations.py&amp;rsquo;, &amp;lsquo;django_migrations.py&amp;rsquo;, &amp;lsquo;django_admin_log.py&amp;rsquo;]&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;a href=&#34;https://gist.github.com/amjith/1b69ff2612d6aaa7e39a/raw/85e9cc5ad3f2cde8c8f99af66996181e940139e7/ranked_by_matching_pos.py&#34;&gt;view raw&lt;/a&gt;
&lt;a href=&#34;https://gist.github.com/amjith/1b69ff2612d6aaa7e39a#file-ranked_by_matching_pos-py&#34;&gt;ranked_by_matching_pos.py&lt;/a&gt;
hosted with ❤ by &lt;a href=&#34;https://github.com&#34;&gt;GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;We made the list of suggestions to be tuples where the first item is the position of the match and second item is the matching filename. When this list is sorted, python will sort them based on the first item in tuple and use the second item as a tie breaker. On line 14 we use a list comprehension to iterate over the sorted list of tuples and extract just the second item which is the file name we&amp;rsquo;re interested in.&lt;/p&gt;
&lt;p&gt;This got us close to the end result, but as shown in the example, it&amp;rsquo;s not perfect. We see &amp;lsquo;main_generator.py&amp;rsquo; as the first suggestion, but the user wanted &amp;lsquo;migration.py&amp;rsquo;.&lt;/p&gt;
&lt;h3 id=&#34;ranking-based-on-compact-match&#34;&gt;&lt;strong&gt;Ranking based on compact match:&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;When a user starts typing a partial string they will continue to type consecutive letters in a effort to find the exact match. When someone types &amp;lsquo;mig&amp;rsquo; they are looking for &amp;lsquo;&lt;strong&gt;mig&lt;/strong&gt;rations.py&amp;rsquo; or &amp;lsquo;django_&lt;strong&gt;mig&lt;/strong&gt;rations.py&amp;rsquo; not &amp;lsquo;main_generator.py&amp;rsquo;. The key here is to find the most compact match for the user input.&lt;/p&gt;
&lt;p&gt;Once again this is trivial to do in python. When we match a string against a regular expression, the matched string is stored in the match.group(). &lt;/p&gt;
&lt;p&gt;For example, if the input is &amp;lsquo;mig&amp;rsquo;, the matching group from the &amp;lsquo;&lt;a href=&#34;https://gist.github.com/amjith/f0d4fa57e6e47d0e1e9c#file-file_list&#34;&gt;collection&lt;/a&gt;&amp;rsquo; defined earlier is as follows:&lt;/p&gt;
&lt;p&gt;This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
&lt;a href=&#34;https://github.co/hiddenchars&#34;&gt;Learn more about bidirectional Unicode characters&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;[Show hidden characters]({{ revealButtonHref }})&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;regex = &amp;lsquo;(m.*i.*g)&amp;rsquo;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;main_generator.py&amp;rsquo; -&amp;gt; &amp;lsquo;main_g&amp;rsquo;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;migrations.py&amp;rsquo; -&amp;gt; &amp;lsquo;mig&amp;rsquo;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;django_migrations.py&amp;rsquo; -&amp;gt; &amp;lsquo;mig&amp;rsquo;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;lsquo;django_admin_log.py&amp;rsquo; -&amp;gt; &amp;lsquo;min_log&amp;rsquo;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;a href=&#34;https://gist.github.com/amjith/c936a2fff2a247c149da/raw/b48bd29607211aac9f6658d4cde01ab5db5056f4/match_group.py&#34;&gt;view raw&lt;/a&gt;
&lt;a href=&#34;https://gist.github.com/amjith/c936a2fff2a247c149da#file-match_group-py&#34;&gt;match_group.py&lt;/a&gt;
hosted with ❤ by &lt;a href=&#34;https://github.com&#34;&gt;GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;We can use the length of the captured group as our primary rank and use the starting position as our secondary rank. To do that we add the len(match.group()) as the first item in the tuple, match.start() as the second item in the tuple and the filename itself as the third item in the tuple. Python will sort this list based on first item in the tuple (primary rank), second item as tie-breaker (secondary rank) and the third item as the fall back tie-breaker. &lt;/p&gt;
&lt;p&gt;This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
&lt;a href=&#34;https://github.co/hiddenchars&#34;&gt;Learn more about bidirectional Unicode characters&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;[Show hidden characters]({{ revealButtonHref }})&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; import re # regex module from standard library.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; def fuzzyfinder(user_input, collection):&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;suggestions = []&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;pattern = &amp;lsquo;.*&#39;.join(user_input) # Converts &amp;lsquo;djm&amp;rsquo; to &amp;rsquo;d.*j.*m&amp;rsquo;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;regex = re.compile(pattern) # Compiles a regex.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;for item in collection:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;match = regex.search(item) # Checks if the current item matches the regex.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;if match:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;suggestions.append((len(match.group()), match.start(), item))&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;return [x for _, _, x in sorted(suggestions)]&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; print fuzzyfinder(&amp;lsquo;mig&amp;rsquo;, collection)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;[&amp;lsquo;migrations.py&amp;rsquo;, &amp;lsquo;django_migrations.py&amp;rsquo;, &amp;lsquo;main_generator.py&amp;rsquo;, &amp;lsquo;django_admin_log.py&amp;rsquo;]&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;a href=&#34;https://gist.github.com/amjith/e0146b0b3663efdbbf68/raw/b6c7514844ef47bad0fa6ba2d759af233157ea53/Compactness_ranking.py&#34;&gt;view raw&lt;/a&gt;
&lt;a href=&#34;https://gist.github.com/amjith/e0146b0b3663efdbbf68#file-compactness_ranking-py&#34;&gt;Compactness_ranking.py&lt;/a&gt;
hosted with ❤ by &lt;a href=&#34;https://github.com&#34;&gt;GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This produces the desired behavior for our input. We&amp;rsquo;re not quite done yet.&lt;/p&gt;
&lt;h3 id=&#34;non-greedy-matching&#34;&gt;Non-Greedy Matching&lt;/h3&gt;
&lt;p&gt;There is one more subtle corner case that was caught by &lt;a href=&#34;https://github.com/drocco007&#34;&gt;Daniel Rocco&lt;/a&gt;. Consider these two items in the collection [&amp;lsquo;api_user&amp;rsquo;, &amp;lsquo;user_group&amp;rsquo;]. When you enter the word &amp;lsquo;user&amp;rsquo; the ideal suggestion should be [&amp;lsquo;user_group&amp;rsquo;, &amp;lsquo;api_user&amp;rsquo;]. But the actual result is:&lt;/p&gt;
&lt;p&gt;This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
&lt;a href=&#34;https://github.co/hiddenchars&#34;&gt;Learn more about bidirectional Unicode characters&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;[Show hidden characters]({{ revealButtonHref }})&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; print fuzzyfinder(&amp;lsquo;user&amp;rsquo;, collection)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;[&amp;lsquo;api_user.doc&amp;rsquo;, &amp;lsquo;user_group.doc&amp;rsquo;]&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;a href=&#34;https://gist.github.com/amjith/3dc1ab03975fe2c18f66/raw/8e4b80c05ee44f87ef60735382ee37c3014413a5/corner_case.py&#34;&gt;view raw&lt;/a&gt;
&lt;a href=&#34;https://gist.github.com/amjith/3dc1ab03975fe2c18f66#file-corner_case-py&#34;&gt;corner_case.py&lt;/a&gt;
hosted with ❤ by &lt;a href=&#34;https://github.com&#34;&gt;GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Looking at this output, you&amp;rsquo;ll notice that &lt;code&gt;api_user&lt;/code&gt; appears before &lt;code&gt;user_group&lt;/code&gt;. Digging in a little, it turns out the search &lt;code&gt;user&lt;/code&gt; expands to &lt;code&gt;u.*s.*e.*r&lt;/code&gt;; notice that &lt;code&gt;user_group&lt;/code&gt; has &lt;em&gt;two&lt;/em&gt; &lt;code&gt;r&lt;/code&gt;s, so the pattern matches &lt;code&gt;user_gr&lt;/code&gt; instead of the expected &lt;code&gt;user&lt;/code&gt;. The longer match length forces the ranking of this match down, which again seems counterintuitive. This is easy to change by using the non-greedy version of the regex (&lt;code&gt;.*?&lt;/code&gt; instead of &lt;code&gt;.*&lt;/code&gt;) on line 4. &lt;/p&gt;
&lt;p&gt;This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
&lt;a href=&#34;https://github.co/hiddenchars&#34;&gt;Learn more about bidirectional Unicode characters&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;[Show hidden characters]({{ revealButtonHref }})&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; import re # regex module from standard library.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; def fuzzyfinder(user_input, collection):&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;suggestions = []&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;pattern = &amp;lsquo;.*?&#39;.join(user_input) # Converts &amp;lsquo;djm&amp;rsquo; to &amp;rsquo;d.*?j.*?m&amp;rsquo;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;regex = re.compile(pattern) # Compiles a regex.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;for item in collection:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;match = regex.search(item) # Checks if the current item matches the regex.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;if match:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;suggestions.append((len(match.group()), match.start(), item))&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;return [x for _, _, x in sorted(suggestions)]&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; fuzzyfinder(&amp;lsquo;user&amp;rsquo;, collection)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;[&amp;lsquo;user_group.doc&amp;rsquo;, &amp;lsquo;api_user.doc&amp;rsquo;]&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&amp;raquo;&amp;gt; print fuzzyfinder(&amp;lsquo;mig&amp;rsquo;, collection)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;[&amp;lsquo;migrations.py&amp;rsquo;, &amp;lsquo;django_migrations.py&amp;rsquo;, &amp;lsquo;main_generator.py&amp;rsquo;, &amp;lsquo;django_admin_log.py&amp;rsquo;]&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;a href=&#34;https://gist.github.com/amjith/a9e295e8dbff575c4cde/raw/7d65c8e80aefcb5d0aba740a60ed53461d01da14/non_greedy_matching.py&#34;&gt;view raw&lt;/a&gt;
&lt;a href=&#34;https://gist.github.com/amjith/a9e295e8dbff575c4cde#file-non_greedy_matching-py&#34;&gt;non_greedy_matching.py&lt;/a&gt;
hosted with ❤ by &lt;a href=&#34;https://github.com&#34;&gt;GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Now that works for all the cases we&amp;rsquo;ve outlines. We&amp;rsquo;ve just implemented a fuzzy finder in 10 lines of code.&lt;/p&gt;
&lt;h1 id=&#34;conclusion&#34;&gt;Conclusion:&lt;/h1&gt;
&lt;p&gt;That was the design process for implementing fuzzy matching for my side project &lt;a href=&#34;https://github.com/dbcli/pgcli/blob/amjith/fuzzy_completion/pgcli/pgcompleter.py#L198..L204&#34;&gt;pgcli&lt;/a&gt;, which is a repl for Postgresql that can do auto-completion. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1470423/dxAaYMaRlYYrl3Eql9tUOlAKVkI/large_pgcli-fuzzy.gif&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve extracted &lt;a href=&#34;https://github.com/amjith/fuzzyfinder&#34;&gt;fuzzyfinder&lt;/a&gt; into a stand-alone python package. You can install it via &amp;lsquo;pip install fuzzyfinder&amp;rsquo; and use it in your projects.&lt;/p&gt;
&lt;p&gt;Thanks to &lt;a href=&#34;https://github.com/zoltu&#34;&gt;Micah Zoltu&lt;/a&gt; and &lt;a href=&#34;https://github.com/drocco007&#34;&gt;Daniel Rocco&lt;/a&gt; for reviewing the algorithm and fixing the corner cases.&lt;/p&gt;
&lt;p&gt;If you found this interesting, you should follow me on &lt;a href=&#34;https://twitter.com/amjithr&#34;&gt;twitter&lt;/a&gt;. &lt;/p&gt;
&lt;h3 id=&#34;epilogue&#34;&gt;Epilogue:&lt;/h3&gt;
&lt;p&gt;When I first started looking into fuzzy matching in python, I encountered this excellent library called &lt;a href=&#34;https://github.com/seatgeek/fuzzywuzzy&#34;&gt;fuzzywuzzy&lt;/a&gt;. But the fuzzy matching done by that library is a different kind. It uses &lt;a href=&#34;https://en.wikipedia.org/wiki/Levenshtein_distance&#34;&gt;levenshtein distance&lt;/a&gt; to find the closest matching string from a collection. Which is a great technique for auto-correction against spelling errors but it doesn&amp;rsquo;t produce the desired results for matching long names from partial sub-strings.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<h1 id="introduction">Introduction:</h1>
<p>FuzzyFinder is a popular feature available in decent editors to open files. The idea is to start typing partial strings from the full path and the list of suggestions will be narrowed down to match the desired file. </p>
<p>Examples: </p>
<p>Vim (Ctrl-P)</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1468562/v2hh-J443fIzsstdfU5cc_jszb8/large_vim-ctrl-p.gif" alt=""  />
</p>
<p>Sublime Text (Cmd-P)</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1468563/LIitkIbiuCIz5cZH27rLJ0qGkgA/large_subl-cmd-p.gif" alt=""  />
</p>
<p>This is an extremely useful feature and it&rsquo;s quite easy to implement.</p>
<h1 id="problem-statement">Problem Statement:</h1>
<p>We have a collection of strings (filenames). We&rsquo;re trying to filter down that collection based on user input. The user input can be partial strings from the filename. Let&rsquo;s walk this through with an example. Here is a collection of filenames:</p>
<p>This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
<a href="https://github.co/hiddenchars">Learn more about bidirectional Unicode characters</a></p>
<p>[Show hidden characters]({{ revealButtonHref }})</p>
<table>
<thead>
<tr>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr>
<td></td>
<td>&raquo;&gt; collection = [&lsquo;django_migrations.py&rsquo;,</td>
</tr>
<tr>
<td></td>
<td>&lsquo;django_admin_log.py&rsquo;,</td>
</tr>
<tr>
<td></td>
<td>&lsquo;main_generator.py&rsquo;,</td>
</tr>
<tr>
<td></td>
<td>&lsquo;migrations.py&rsquo;,</td>
</tr>
<tr>
<td></td>
<td>&lsquo;api_user.doc&rsquo;,</td>
</tr>
<tr>
<td></td>
<td>&lsquo;user_group.doc&rsquo;,</td>
</tr>
<tr>
<td></td>
<td>&lsquo;accounts.txt&rsquo;,</td>
</tr>
<tr>
<td></td>
<td>]</td>
</tr>
</tbody>
</table>
<p><a href="https://gist.github.com/amjith/f0d4fa57e6e47d0e1e9c/raw/67138107e3f87991cc006b73ecc826d618f7842c/file_list.py">view raw</a>
<a href="https://gist.github.com/amjith/f0d4fa57e6e47d0e1e9c#file-file_list-py">file_list.py</a>
hosted with ❤ by <a href="https://github.com">GitHub</a></p>
<p>When the user types &lsquo;djm&rsquo; we are supposed to match &lsquo;<strong>dj</strong>ango_<strong>m</strong>igrations.py&rsquo; and &lsquo;<strong>dj</strong>ango_ad<strong>m</strong>in_log.py&rsquo;. The simplest route to achieve this is to use regular expressions. </p>
<h1 id="solutions">Solutions:</h1>
<h3 id="naive-regex-matching">Naive Regex Matching:</h3>
<p>Convert &lsquo;djm&rsquo; into &rsquo;d.*j.*m' and try to match this regex against every item in the list. Items that match are the possible candidates.</p>
<p>This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
<a href="https://github.co/hiddenchars">Learn more about bidirectional Unicode characters</a></p>
<p>[Show hidden characters]({{ revealButtonHref }})</p>
<table>
<thead>
<tr>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr>
<td></td>
<td>&raquo;&gt; import re # regex module from standard library.</td>
</tr>
<tr>
<td></td>
<td>&raquo;&gt; def fuzzyfinder(user_input, collection):</td>
</tr>
<tr>
<td></td>
<td>suggestions = []</td>
</tr>
<tr>
<td></td>
<td>pattern = &lsquo;.*'.join(user_input) # Converts &lsquo;djm&rsquo; to &rsquo;d.*j.*m&rsquo;</td>
</tr>
<tr>
<td></td>
<td>regex = re.compile(pattern) # Compiles a regex.</td>
</tr>
<tr>
<td></td>
<td>for item in collection:</td>
</tr>
<tr>
<td></td>
<td>match = regex.search(item) # Checks if the current item matches the regex.</td>
</tr>
<tr>
<td></td>
<td>if match:</td>
</tr>
<tr>
<td></td>
<td>suggestions.append(item)</td>
</tr>
<tr>
<td></td>
<td>return suggestions</td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td>&raquo;&gt; print fuzzyfinder(&lsquo;djm&rsquo;, collection)</td>
</tr>
<tr>
<td></td>
<td>[&lsquo;django_migrations.py&rsquo;, &lsquo;django_admin_log.py&rsquo;]</td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td>&raquo;&gt; print fuzzyfinder(&lsquo;mig&rsquo;, collection)</td>
</tr>
<tr>
<td></td>
<td>[&lsquo;django_migrations.py&rsquo;, &lsquo;django_admin_log.py&rsquo;, &lsquo;main_generator.py&rsquo;, &lsquo;migrations.py&rsquo;]</td>
</tr>
</tbody>
</table>
<p><a href="https://gist.github.com/amjith/cf79e9a66d9867a1fee4/raw/478f146034bfbd9fad7b12b374686d91ba5bbae8/naive_regex.py">view raw</a>
<a href="https://gist.github.com/amjith/cf79e9a66d9867a1fee4#file-naive_regex-py">naive_regex.py</a>
hosted with ❤ by <a href="https://github.com">GitHub</a></p>
<p>This got us the desired results for input &lsquo;djm&rsquo;. But the suggestions are not ranked in any particular order.</p>
<p>In fact, for the second example with user input &lsquo;mig&rsquo; the best possible suggestion &lsquo;migrations.py&rsquo; was listed as the last item in the result.</p>
<h3 id="ranking-based-on-match-position">Ranking based on match position:</h3>
<p>We can rank the results based on the position of the first occurrence of the matching character. For user input &lsquo;mig&rsquo; the position of the matching characters are as follows:</p>
<p>This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
<a href="https://github.co/hiddenchars">Learn more about bidirectional Unicode characters</a></p>
<p>[Show hidden characters]({{ revealButtonHref }})</p>
<table>
<thead>
<tr>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr>
<td></td>
<td>&lsquo;main_generator.py&rsquo; - 0</td>
</tr>
<tr>
<td></td>
<td>&lsquo;migrations.py&rsquo; - 0</td>
</tr>
<tr>
<td></td>
<td>&lsquo;django_migrations.py&rsquo; - 7</td>
</tr>
<tr>
<td></td>
<td>&lsquo;django_admin_log.py&rsquo; - 9</td>
</tr>
</tbody>
</table>
<p><a href="https://gist.github.com/amjith/ea535287d22a9b7cf35a/raw/231ce950b82d2ca6d9a2b1b4331b1c0cf6baed46/position_of_match.py">view raw</a>
<a href="https://gist.github.com/amjith/ea535287d22a9b7cf35a#file-position_of_match-py">position_of_match.py</a>
hosted with ❤ by <a href="https://github.com">GitHub</a></p>
<p>Here&rsquo;s the code:</p>
<p>This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
<a href="https://github.co/hiddenchars">Learn more about bidirectional Unicode characters</a></p>
<p>[Show hidden characters]({{ revealButtonHref }})</p>
<table>
<thead>
<tr>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr>
<td></td>
<td>&raquo;&gt; import re # regex module from standard library.</td>
</tr>
<tr>
<td></td>
<td>&raquo;&gt; def fuzzyfinder(user_input, collection):</td>
</tr>
<tr>
<td></td>
<td>suggestions = []</td>
</tr>
<tr>
<td></td>
<td>pattern = &lsquo;.*'.join(user_input) # Converts &lsquo;djm&rsquo; to &rsquo;d.*j.*m&rsquo;</td>
</tr>
<tr>
<td></td>
<td>regex = re.compile(pattern) # Compiles a regex.</td>
</tr>
<tr>
<td></td>
<td>for item in collection:</td>
</tr>
<tr>
<td></td>
<td>match = regex.search(item) # Checks if the current item matches the regex.</td>
</tr>
<tr>
<td></td>
<td>if match:</td>
</tr>
<tr>
<td></td>
<td>suggestions.append((match.start(), item))</td>
</tr>
<tr>
<td></td>
<td>return [x for _, x in sorted(suggestions)]</td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td>&raquo;&gt; print fuzzyfinder(&lsquo;mig&rsquo;, collection)</td>
</tr>
<tr>
<td></td>
<td>[&lsquo;main_generator.py&rsquo;, &lsquo;migrations.py&rsquo;, &lsquo;django_migrations.py&rsquo;, &lsquo;django_admin_log.py&rsquo;]</td>
</tr>
</tbody>
</table>
<p><a href="https://gist.github.com/amjith/1b69ff2612d6aaa7e39a/raw/85e9cc5ad3f2cde8c8f99af66996181e940139e7/ranked_by_matching_pos.py">view raw</a>
<a href="https://gist.github.com/amjith/1b69ff2612d6aaa7e39a#file-ranked_by_matching_pos-py">ranked_by_matching_pos.py</a>
hosted with ❤ by <a href="https://github.com">GitHub</a></p>
<p>We made the list of suggestions to be tuples where the first item is the position of the match and second item is the matching filename. When this list is sorted, python will sort them based on the first item in tuple and use the second item as a tie breaker. On line 14 we use a list comprehension to iterate over the sorted list of tuples and extract just the second item which is the file name we&rsquo;re interested in.</p>
<p>This got us close to the end result, but as shown in the example, it&rsquo;s not perfect. We see &lsquo;main_generator.py&rsquo; as the first suggestion, but the user wanted &lsquo;migration.py&rsquo;.</p>
<h3 id="ranking-based-on-compact-match"><strong>Ranking based on compact match:</strong></h3>
<p>When a user starts typing a partial string they will continue to type consecutive letters in a effort to find the exact match. When someone types &lsquo;mig&rsquo; they are looking for &lsquo;<strong>mig</strong>rations.py&rsquo; or &lsquo;django_<strong>mig</strong>rations.py&rsquo; not &lsquo;main_generator.py&rsquo;. The key here is to find the most compact match for the user input.</p>
<p>Once again this is trivial to do in python. When we match a string against a regular expression, the matched string is stored in the match.group(). </p>
<p>For example, if the input is &lsquo;mig&rsquo;, the matching group from the &lsquo;<a href="https://gist.github.com/amjith/f0d4fa57e6e47d0e1e9c#file-file_list">collection</a>&rsquo; defined earlier is as follows:</p>
<p>This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
<a href="https://github.co/hiddenchars">Learn more about bidirectional Unicode characters</a></p>
<p>[Show hidden characters]({{ revealButtonHref }})</p>
<table>
<thead>
<tr>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr>
<td></td>
<td>regex = &lsquo;(m.*i.*g)&rsquo;</td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td>&lsquo;main_generator.py&rsquo; -&gt; &lsquo;main_g&rsquo;</td>
</tr>
<tr>
<td></td>
<td>&lsquo;migrations.py&rsquo; -&gt; &lsquo;mig&rsquo;</td>
</tr>
<tr>
<td></td>
<td>&lsquo;django_migrations.py&rsquo; -&gt; &lsquo;mig&rsquo;</td>
</tr>
<tr>
<td></td>
<td>&lsquo;django_admin_log.py&rsquo; -&gt; &lsquo;min_log&rsquo;</td>
</tr>
</tbody>
</table>
<p><a href="https://gist.github.com/amjith/c936a2fff2a247c149da/raw/b48bd29607211aac9f6658d4cde01ab5db5056f4/match_group.py">view raw</a>
<a href="https://gist.github.com/amjith/c936a2fff2a247c149da#file-match_group-py">match_group.py</a>
hosted with ❤ by <a href="https://github.com">GitHub</a></p>
<p>We can use the length of the captured group as our primary rank and use the starting position as our secondary rank. To do that we add the len(match.group()) as the first item in the tuple, match.start() as the second item in the tuple and the filename itself as the third item in the tuple. Python will sort this list based on first item in the tuple (primary rank), second item as tie-breaker (secondary rank) and the third item as the fall back tie-breaker. </p>
<p>This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
<a href="https://github.co/hiddenchars">Learn more about bidirectional Unicode characters</a></p>
<p>[Show hidden characters]({{ revealButtonHref }})</p>
<table>
<thead>
<tr>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr>
<td></td>
<td>&raquo;&gt; import re # regex module from standard library.</td>
</tr>
<tr>
<td></td>
<td>&raquo;&gt; def fuzzyfinder(user_input, collection):</td>
</tr>
<tr>
<td></td>
<td>suggestions = []</td>
</tr>
<tr>
<td></td>
<td>pattern = &lsquo;.*'.join(user_input) # Converts &lsquo;djm&rsquo; to &rsquo;d.*j.*m&rsquo;</td>
</tr>
<tr>
<td></td>
<td>regex = re.compile(pattern) # Compiles a regex.</td>
</tr>
<tr>
<td></td>
<td>for item in collection:</td>
</tr>
<tr>
<td></td>
<td>match = regex.search(item) # Checks if the current item matches the regex.</td>
</tr>
<tr>
<td></td>
<td>if match:</td>
</tr>
<tr>
<td></td>
<td>suggestions.append((len(match.group()), match.start(), item))</td>
</tr>
<tr>
<td></td>
<td>return [x for _, _, x in sorted(suggestions)]</td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td>&raquo;&gt; print fuzzyfinder(&lsquo;mig&rsquo;, collection)</td>
</tr>
<tr>
<td></td>
<td>[&lsquo;migrations.py&rsquo;, &lsquo;django_migrations.py&rsquo;, &lsquo;main_generator.py&rsquo;, &lsquo;django_admin_log.py&rsquo;]</td>
</tr>
</tbody>
</table>
<p><a href="https://gist.github.com/amjith/e0146b0b3663efdbbf68/raw/b6c7514844ef47bad0fa6ba2d759af233157ea53/Compactness_ranking.py">view raw</a>
<a href="https://gist.github.com/amjith/e0146b0b3663efdbbf68#file-compactness_ranking-py">Compactness_ranking.py</a>
hosted with ❤ by <a href="https://github.com">GitHub</a></p>
<p>This produces the desired behavior for our input. We&rsquo;re not quite done yet.</p>
<h3 id="non-greedy-matching">Non-Greedy Matching</h3>
<p>There is one more subtle corner case that was caught by <a href="https://github.com/drocco007">Daniel Rocco</a>. Consider these two items in the collection [&lsquo;api_user&rsquo;, &lsquo;user_group&rsquo;]. When you enter the word &lsquo;user&rsquo; the ideal suggestion should be [&lsquo;user_group&rsquo;, &lsquo;api_user&rsquo;]. But the actual result is:</p>
<p>This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
<a href="https://github.co/hiddenchars">Learn more about bidirectional Unicode characters</a></p>
<p>[Show hidden characters]({{ revealButtonHref }})</p>
<table>
<thead>
<tr>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr>
<td></td>
<td>&raquo;&gt; print fuzzyfinder(&lsquo;user&rsquo;, collection)</td>
</tr>
<tr>
<td></td>
<td>[&lsquo;api_user.doc&rsquo;, &lsquo;user_group.doc&rsquo;]</td>
</tr>
</tbody>
</table>
<p><a href="https://gist.github.com/amjith/3dc1ab03975fe2c18f66/raw/8e4b80c05ee44f87ef60735382ee37c3014413a5/corner_case.py">view raw</a>
<a href="https://gist.github.com/amjith/3dc1ab03975fe2c18f66#file-corner_case-py">corner_case.py</a>
hosted with ❤ by <a href="https://github.com">GitHub</a></p>
<p>Looking at this output, you&rsquo;ll notice that <code>api_user</code> appears before <code>user_group</code>. Digging in a little, it turns out the search <code>user</code> expands to <code>u.*s.*e.*r</code>; notice that <code>user_group</code> has <em>two</em> <code>r</code>s, so the pattern matches <code>user_gr</code> instead of the expected <code>user</code>. The longer match length forces the ranking of this match down, which again seems counterintuitive. This is easy to change by using the non-greedy version of the regex (<code>.*?</code> instead of <code>.*</code>) on line 4. </p>
<p>This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
<a href="https://github.co/hiddenchars">Learn more about bidirectional Unicode characters</a></p>
<p>[Show hidden characters]({{ revealButtonHref }})</p>
<table>
<thead>
<tr>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr>
<td></td>
<td>&raquo;&gt; import re # regex module from standard library.</td>
</tr>
<tr>
<td></td>
<td>&raquo;&gt; def fuzzyfinder(user_input, collection):</td>
</tr>
<tr>
<td></td>
<td>suggestions = []</td>
</tr>
<tr>
<td></td>
<td>pattern = &lsquo;.*?'.join(user_input) # Converts &lsquo;djm&rsquo; to &rsquo;d.*?j.*?m&rsquo;</td>
</tr>
<tr>
<td></td>
<td>regex = re.compile(pattern) # Compiles a regex.</td>
</tr>
<tr>
<td></td>
<td>for item in collection:</td>
</tr>
<tr>
<td></td>
<td>match = regex.search(item) # Checks if the current item matches the regex.</td>
</tr>
<tr>
<td></td>
<td>if match:</td>
</tr>
<tr>
<td></td>
<td>suggestions.append((len(match.group()), match.start(), item))</td>
</tr>
<tr>
<td></td>
<td>return [x for _, _, x in sorted(suggestions)]</td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td>&raquo;&gt; fuzzyfinder(&lsquo;user&rsquo;, collection)</td>
</tr>
<tr>
<td></td>
<td>[&lsquo;user_group.doc&rsquo;, &lsquo;api_user.doc&rsquo;]</td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td>&raquo;&gt; print fuzzyfinder(&lsquo;mig&rsquo;, collection)</td>
</tr>
<tr>
<td></td>
<td>[&lsquo;migrations.py&rsquo;, &lsquo;django_migrations.py&rsquo;, &lsquo;main_generator.py&rsquo;, &lsquo;django_admin_log.py&rsquo;]</td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
</tbody>
</table>
<p><a href="https://gist.github.com/amjith/a9e295e8dbff575c4cde/raw/7d65c8e80aefcb5d0aba740a60ed53461d01da14/non_greedy_matching.py">view raw</a>
<a href="https://gist.github.com/amjith/a9e295e8dbff575c4cde#file-non_greedy_matching-py">non_greedy_matching.py</a>
hosted with ❤ by <a href="https://github.com">GitHub</a></p>
<p>Now that works for all the cases we&rsquo;ve outlines. We&rsquo;ve just implemented a fuzzy finder in 10 lines of code.</p>
<h1 id="conclusion">Conclusion:</h1>
<p>That was the design process for implementing fuzzy matching for my side project <a href="https://github.com/dbcli/pgcli/blob/amjith/fuzzy_completion/pgcli/pgcompleter.py#L198..L204">pgcli</a>, which is a repl for Postgresql that can do auto-completion. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/1470423/dxAaYMaRlYYrl3Eql9tUOlAKVkI/large_pgcli-fuzzy.gif" alt=""  />
</p>
<p>I&rsquo;ve extracted <a href="https://github.com/amjith/fuzzyfinder">fuzzyfinder</a> into a stand-alone python package. You can install it via &lsquo;pip install fuzzyfinder&rsquo; and use it in your projects.</p>
<p>Thanks to <a href="https://github.com/zoltu">Micah Zoltu</a> and <a href="https://github.com/drocco007">Daniel Rocco</a> for reviewing the algorithm and fixing the corner cases.</p>
<p>If you found this interesting, you should follow me on <a href="https://twitter.com/amjithr">twitter</a>. </p>
<h3 id="epilogue">Epilogue:</h3>
<p>When I first started looking into fuzzy matching in python, I encountered this excellent library called <a href="https://github.com/seatgeek/fuzzywuzzy">fuzzywuzzy</a>. But the fuzzy matching done by that library is a different kind. It uses <a href="https://en.wikipedia.org/wiki/Levenshtein_distance">levenshtein distance</a> to find the closest matching string from a collection. Which is a great technique for auto-correction against spelling errors but it doesn&rsquo;t produce the desired results for matching long names from partial sub-strings.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversation with a 2 yo</title>
      <link>https://amjith.com/blog/conversation-with-a-2-yo/</link>
      <pubDate>Wed, 17 Jun 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversation-with-a-2-yo/</guid>
      <description>&lt;p&gt;Me: Do you like Superman? &lt;/p&gt;
&lt;p&gt;Sempi: No&lt;/p&gt;
&lt;p&gt;Me: How about Batman?&lt;/p&gt;
&lt;p&gt;Sempi: No&lt;/p&gt;
&lt;p&gt;Me: Who do you like? &lt;/p&gt;
&lt;p&gt;Sempi: Amma&lt;/p&gt;
&lt;p&gt;Me: Aww. Do you like Appa? &lt;/p&gt;
&lt;p&gt;Sempi: Yeah (matter of fact voice). &lt;/p&gt;
&lt;p&gt;Sempi: I like you when you&amp;rsquo;re at work. I don&amp;rsquo;t like you when you&amp;rsquo;re home. &lt;/p&gt;
&lt;p&gt;Me: o_O&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Me: Do you like Superman? </p>
<p>Sempi: No</p>
<p>Me: How about Batman?</p>
<p>Sempi: No</p>
<p>Me: Who do you like? </p>
<p>Sempi: Amma</p>
<p>Me: Aww. Do you like Appa? </p>
<p>Sempi: Yeah (matter of fact voice). </p>
<p>Sempi: I like you when you&rsquo;re at work. I don&rsquo;t like you when you&rsquo;re home. </p>
<p>Me: o_O</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Pycast - Python screencasts</title>
      <link>https://amjith.com/blog/pycast-python-screencasts/</link>
      <pubDate>Wed, 03 Jun 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/pycast-python-screencasts/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://www.kickstarter.com/projects/127250310/pycast-python-and-data-science-screencasts&#34;&gt;Pycast&lt;/a&gt; - Weekly screencasts on Python and DataScience by Matt Harrison. &lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://hairysun.com/&#34;&gt;Matt&lt;/a&gt; is bootstrapping &lt;a href=&#34;http://pycast.io&#34;&gt;pycast&lt;/a&gt; through &lt;a href=&#34;https://www.kickstarter.com/projects/127250310/pycast-python-and-data-science-screencasts&#34;&gt;kickstarter&lt;/a&gt;. I&amp;rsquo;m excited about it because I&amp;rsquo;ve attended Matt&amp;rsquo;s tutorials and came away feeling leveled up on my Python chops. &lt;/p&gt;
&lt;p&gt;Nearly 5 years ago I was getting started in Python and learning on my own by writing small scripts to automate silly stuff. I wasn&amp;rsquo;t writing anything adventurous and I was looking for a way to improve my skills.&lt;/p&gt;
&lt;p&gt;Right around that time I started getting involved in the open source community in Utah and decided to go to a local conference. Matt was doing a 3 hour tutorial that covered beginner to intermediate Python. When the session was over I felt empowered. I couldn&amp;rsquo;t wait to get back home to do the exercises that he had laid out during the training. After working through them I felt like I really knew the language. I was writing generators and decorators by the end of it. It was an accelerated learning experience that took me from a novice to a &lt;a href=&#34;http://en.wikipedia.org/wiki/Journeyman&#34;&gt;journeyman&lt;/a&gt;. &lt;/p&gt;
&lt;p&gt;The beauty of his training is, it wasn&amp;rsquo;t merely a brain dump, he was teaching me to how to learn, where to look up the docs, how to recognize idiomatic python and best practices of programming. &lt;/p&gt;
&lt;p&gt;I eventually landed a job doing full time Python at an awesome &lt;a href=&#34;https://newrelic.com/&#34;&gt;company&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;That&amp;rsquo;s why I&amp;rsquo;m excited about his new venture. This is a great opportunity for me to dive into Data Science and I can&amp;rsquo;t wait to see his videos and workout the exercises.&lt;/p&gt;
&lt;p&gt;If you&amp;rsquo;re still on the fence about it, leave a &lt;a href=&#34;https://www.kickstarter.com/projects/127250310/pycast-python-and-data-science-screencasts/comments&#34;&gt;comment&lt;/a&gt; on his kickstarter page with your question. He&amp;rsquo;s a friendly and responsive person.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p><a href="https://www.kickstarter.com/projects/127250310/pycast-python-and-data-science-screencasts">Pycast</a> - Weekly screencasts on Python and DataScience by Matt Harrison. </p>
<p><a href="http://hairysun.com/">Matt</a> is bootstrapping <a href="http://pycast.io">pycast</a> through <a href="https://www.kickstarter.com/projects/127250310/pycast-python-and-data-science-screencasts">kickstarter</a>. I&rsquo;m excited about it because I&rsquo;ve attended Matt&rsquo;s tutorials and came away feeling leveled up on my Python chops. </p>
<p>Nearly 5 years ago I was getting started in Python and learning on my own by writing small scripts to automate silly stuff. I wasn&rsquo;t writing anything adventurous and I was looking for a way to improve my skills.</p>
<p>Right around that time I started getting involved in the open source community in Utah and decided to go to a local conference. Matt was doing a 3 hour tutorial that covered beginner to intermediate Python. When the session was over I felt empowered. I couldn&rsquo;t wait to get back home to do the exercises that he had laid out during the training. After working through them I felt like I really knew the language. I was writing generators and decorators by the end of it. It was an accelerated learning experience that took me from a novice to a <a href="http://en.wikipedia.org/wiki/Journeyman">journeyman</a>. </p>
<p>The beauty of his training is, it wasn&rsquo;t merely a brain dump, he was teaching me to how to learn, where to look up the docs, how to recognize idiomatic python and best practices of programming. </p>
<p>I eventually landed a job doing full time Python at an awesome <a href="https://newrelic.com/">company</a>.</p>
<p>That&rsquo;s why I&rsquo;m excited about his new venture. This is a great opportunity for me to dive into Data Science and I can&rsquo;t wait to see his videos and workout the exercises.</p>
<p>If you&rsquo;re still on the fence about it, leave a <a href="https://www.kickstarter.com/projects/127250310/pycast-python-and-data-science-screencasts/comments">comment</a> on his kickstarter page with your question. He&rsquo;s a friendly and responsive person.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 2 yo</title>
      <link>https://amjith.com/blog/conversations-with-a-2-yo/</link>
      <pubDate>Mon, 11 May 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-2-yo/</guid>
      <description>&lt;p&gt;Sempi insisted on doing laundry, helping put away the clothes and sweeping the floor. &lt;/p&gt;
&lt;p&gt;**Yoshi:**When did you become such a big boy?&lt;/p&gt;
&lt;p&gt;**Sempi:**Three minutes ago. &lt;/p&gt;
&lt;p&gt;Continues sweeping the floor with a big smile and a song. &lt;/p&gt;
&lt;p&gt;**Sempi:**I&amp;rsquo;m a street sweeper with a broom in my hand.  &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Sempi insisted on doing laundry, helping put away the clothes and sweeping the floor. </p>
<p>**Yoshi:**When did you become such a big boy?</p>
<p>**Sempi:**Three minutes ago. </p>
<p>Continues sweeping the floor with a big smile and a song. </p>
<p>**Sempi:**I&rsquo;m a street sweeper with a broom in my hand.  </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Montreal Bagels - 2yo review</title>
      <link>https://amjith.com/blog/montreal-bagels-2yo-views/</link>
      <pubDate>Tue, 14 Apr 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/montreal-bagels-2yo-views/</guid>
      <description>&lt;p&gt;I was in Montreal for PyCon 2015. I was told that Montreal was famous for it&amp;rsquo;s bagels. So I brought home half-dozen bagels.&lt;/p&gt;
&lt;p&gt;I made my son a delicious toasted bagel with cream cheese in the morning. He ate it with gusto and the following conversation ensues: &lt;/p&gt;
&lt;p&gt;Me: Sempi, did you like the Montreal Bagels.&lt;/p&gt;
&lt;p&gt;2yo: &lt;strong&gt;It was ok&lt;/strong&gt; (as he proceeds to lick his fingers clean). &lt;/p&gt;
&lt;p&gt;This kid is hard to impress. :)&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I was in Montreal for PyCon 2015. I was told that Montreal was famous for it&rsquo;s bagels. So I brought home half-dozen bagels.</p>
<p>I made my son a delicious toasted bagel with cream cheese in the morning. He ate it with gusto and the following conversation ensues: </p>
<p>Me: Sempi, did you like the Montreal Bagels.</p>
<p>2yo: <strong>It was ok</strong> (as he proceeds to lick his fingers clean). </p>
<p>This kid is hard to impress. :)</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Kickstarter: mysql-cli</title>
      <link>https://amjith.com/blog/kickstarter-mysql-cli/</link>
      <pubDate>Sun, 05 Apr 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/kickstarter-mysql-cli/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m starting a project called &lt;a href=&#34;http://mysql-cli.com&#34;&gt;mysql-cli&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://mysql-cli.com&#34;&gt;mysql-cli&lt;/a&gt; will be a command line client for MySQL, with auto-completion and syntax highlighting. An equivalent of &lt;a href=&#34;http://pgcli.com&#34;&gt;pgcli&lt;/a&gt; for MySQL database.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m raising funds for the project through &lt;a href=&#34;http://mysql-cli.com&#34; title=&#34;Link: http://mysql-cli.com&#34;&gt;kickstarter&lt;/a&gt;. The goal is to compensate for the development time and resources (hosting, testing etc) as well as motivate me to keep going.&lt;/p&gt;
&lt;p&gt;When I launched &lt;a href=&#34;http://pgcli.com&#34;&gt;pgcli&lt;/a&gt; earlier this year I had high hopes for it. I anticipated that I might reach a hundred users and even a couple of contributions. I announced it on &lt;a href=&#34;https://twitter.com/amjithr/status/552491986255896576&#34; title=&#34;Link: https://twitter.com/amjithr/status/552491986255896576&#34;&gt;Twitter&lt;/a&gt; and HackerNews and it took about an hour to reach 100 stars. By the second day it was a top trending repo in all of Github. Right now it is hovering near the 1600 mark for the number of stars, with more than 70 pull requests (merged). &lt;/p&gt;
&lt;p&gt;During the first week of launch, I slept about 3 hours each night because the pull requests and issues came flooding. I made a personal resolve to answer every communique within 24 hours. This meant answering personal emails, responding to issues filed, reviewing pull requests etc. I vowed to be &lt;a href=&#34;http://pgcli.com/about&#34; title=&#34;Link: http://pgcli.com/about&#34;&gt;polite&lt;/a&gt; and respectful to my users and contributors and I&amp;rsquo;ve had nothing but pleasant interactions with them. &lt;/p&gt;
&lt;p&gt;My hope is to provide the same level of dedication and support to &lt;a href=&#34;http://mysql-cli.com&#34; title=&#34;Link: http://mysql-cli.com&#34;&gt;mysql-cli&lt;/a&gt;. There is definitely a need for it, since every time I use the default MySQL client I want to scream obscenities at my computer and I can&amp;rsquo;t be the only one. :)&lt;/p&gt;
&lt;p&gt;The plan is to launch &lt;a href=&#34;http://mysql-cli.com&#34; title=&#34;Link: http://mysql-cli.com&#34;&gt;mysql-cli&lt;/a&gt; in July 2015 and open up the repo to public. If you want to get involved sooner, please back the project on &lt;a href=&#34;http://mysql-cli.com&#34;&gt;kickstarter&lt;/a&gt; and I&amp;rsquo;ll add you to the early access list. :)&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;m starting a project called <a href="http://mysql-cli.com">mysql-cli</a>.</p>
<p><a href="http://mysql-cli.com">mysql-cli</a> will be a command line client for MySQL, with auto-completion and syntax highlighting. An equivalent of <a href="http://pgcli.com">pgcli</a> for MySQL database.</p>
<p>I&rsquo;m raising funds for the project through <a href="http://mysql-cli.com" title="Link: http://mysql-cli.com">kickstarter</a>. The goal is to compensate for the development time and resources (hosting, testing etc) as well as motivate me to keep going.</p>
<p>When I launched <a href="http://pgcli.com">pgcli</a> earlier this year I had high hopes for it. I anticipated that I might reach a hundred users and even a couple of contributions. I announced it on <a href="https://twitter.com/amjithr/status/552491986255896576" title="Link: https://twitter.com/amjithr/status/552491986255896576">Twitter</a> and HackerNews and it took about an hour to reach 100 stars. By the second day it was a top trending repo in all of Github. Right now it is hovering near the 1600 mark for the number of stars, with more than 70 pull requests (merged). </p>
<p>During the first week of launch, I slept about 3 hours each night because the pull requests and issues came flooding. I made a personal resolve to answer every communique within 24 hours. This meant answering personal emails, responding to issues filed, reviewing pull requests etc. I vowed to be <a href="http://pgcli.com/about" title="Link: http://pgcli.com/about">polite</a> and respectful to my users and contributors and I&rsquo;ve had nothing but pleasant interactions with them. </p>
<p>My hope is to provide the same level of dedication and support to <a href="http://mysql-cli.com" title="Link: http://mysql-cli.com">mysql-cli</a>. There is definitely a need for it, since every time I use the default MySQL client I want to scream obscenities at my computer and I can&rsquo;t be the only one. :)</p>
<p>The plan is to launch <a href="http://mysql-cli.com" title="Link: http://mysql-cli.com">mysql-cli</a> in July 2015 and open up the repo to public. If you want to get involved sooner, please back the project on <a href="http://mysql-cli.com">kickstarter</a> and I&rsquo;ll add you to the early access list. :)</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 2 year old - Part 3</title>
      <link>https://amjith.com/blog/conversations-with-a-2-year-old-part-3/</link>
      <pubDate>Sat, 04 Apr 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-2-year-old-part-3/</guid>
      <description>&lt;p&gt;One lazy Saturday morning, I’m sitting in my chair in the living room. Sempi is playing with his trucks on the floor.&lt;/p&gt;
&lt;p&gt;I pick up my laptop and open the lid. He brings his cement mixer truck, gently closes my laptop.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Sempi: Appa no work. Play with Gumps.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Then proceeds to drive his toy truck on the laptop lid making truck sounds.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>One lazy Saturday morning, I’m sitting in my chair in the living room. Sempi is playing with his trucks on the floor.</p>
<p>I pick up my laptop and open the lid. He brings his cement mixer truck, gently closes my laptop.</p>
<blockquote>
<p>Sempi: Appa no work. Play with Gumps.</p>
</blockquote>
<p>Then proceeds to drive his toy truck on the laptop lid making truck sounds.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 2 year old - Part 2</title>
      <link>https://amjith.com/blog/conversations-with-a-2-year-old-part-2/</link>
      <pubDate>Sat, 14 Mar 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-2-year-old-part-2/</guid>
      <description>&lt;p&gt;Yoshi: Sempi, your appa is dark and handsome.&lt;/p&gt;
&lt;p&gt;Sempi: Where?&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Yoshi: Sempi, your appa is dark and handsome.</p>
<p>Sempi: Where?</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Conversations with a 2 year old - Part 1</title>
      <link>https://amjith.com/blog/conversations-with-a-2-year-old-part-1/</link>
      <pubDate>Wed, 04 Mar 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/conversations-with-a-2-year-old-part-1/</guid>
      <description>&lt;p&gt;Me: Sempi, do you like appa? &lt;/p&gt;
&lt;p&gt;Sempi: Yes.&lt;/p&gt;
&lt;p&gt;Me: How much?&lt;/p&gt;
&lt;p&gt;Sempi: Too much!&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Me: Sempi, do you like appa? </p>
<p>Sempi: Yes.</p>
<p>Me: How much?</p>
<p>Sempi: Too much!</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Launching pgcli</title>
      <link>https://amjith.com/blog/launching-pgcli/</link>
      <pubDate>Tue, 06 Jan 2015 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/launching-pgcli/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve been developing pgcli for a few months now. &lt;/p&gt;
&lt;p&gt;It is now finally live &lt;a href=&#34;http://pgcli.com&#34;&gt;http://pgcli.com&lt;/a&gt;. &lt;/p&gt;
&lt;p&gt;It all started when &lt;a href=&#34;https://github.com/jonathanslenders/&#34; title=&#34;Link: https://github.com/jonathanslenders/&#34;&gt;Jonathan Slenders&lt;/a&gt; sent me a link to his side-project called &lt;a href=&#34;https://github.com/jonathanslenders/python-prompt-toolkit&#34;&gt;python-prompt-toolkit&lt;/a&gt;. &lt;/p&gt;
&lt;p&gt;I started playing around with it to write some toy programs. Then I wrote a tutorial for how to get started with &lt;a href=&#34;https://github.com/jonathanslenders/python-prompt-toolkit/tree/master/examples/tutorial&#34;&gt;prompt_toolkit&lt;/a&gt; &lt;a href=&#34;https://github.com/jonathanslenders/python-prompt-toolkit/tree/master/examples/tutorial&#34; title=&#34;Link: https://github.com/jonathanslenders/python-prompt-toolkit/tree/master/examples/tutorial&#34;&gt;https://github.com/jonathanslenders/python-prompt-toolkit/tree/master/examples/tutorial&lt;/a&gt;. &lt;/p&gt;
&lt;p&gt;Finally I started writing something more substantial to scratch my own itch. I was dealing with Postgres databases a lot at that time. The default postgres client &amp;lsquo;psql&amp;rsquo; is a great tool, but it lacked auto-completion as I type and it was quite bland (no syntax highlighting). So I decided to take this as my opportunity to write an alternate. &lt;/p&gt;
&lt;p&gt;Thus the creatively named project &amp;lsquo;pgcli&amp;rsquo; was born.&lt;/p&gt;
&lt;h3 id=&#34;details-about-pgclicom&#34;&gt;Details about pgcli.com:&lt;/h3&gt;
&lt;p&gt;It is built using &lt;a href=&#34;https://pypi.python.org/pypi/pelican/&#34;&gt;pelican&lt;/a&gt; a static site generator written in Python. &lt;/p&gt;
&lt;p&gt;It is hosted by Github pages. &lt;/p&gt;
&lt;p&gt;The content is written using RestructuredText.&lt;/p&gt;
&lt;h3 id=&#34;inspiration&#34;&gt;Inspiration:&lt;/h3&gt;
&lt;p&gt;The design inspiration for the tool comes from my favorite python interpreter &lt;a href=&#34;http://www.bpython-interpreter.org/&#34;&gt;bpython&lt;/a&gt;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;ve been developing pgcli for a few months now. </p>
<p>It is now finally live <a href="http://pgcli.com">http://pgcli.com</a>. </p>
<p>It all started when <a href="https://github.com/jonathanslenders/" title="Link: https://github.com/jonathanslenders/">Jonathan Slenders</a> sent me a link to his side-project called <a href="https://github.com/jonathanslenders/python-prompt-toolkit">python-prompt-toolkit</a>. </p>
<p>I started playing around with it to write some toy programs. Then I wrote a tutorial for how to get started with <a href="https://github.com/jonathanslenders/python-prompt-toolkit/tree/master/examples/tutorial">prompt_toolkit</a> <a href="https://github.com/jonathanslenders/python-prompt-toolkit/tree/master/examples/tutorial" title="Link: https://github.com/jonathanslenders/python-prompt-toolkit/tree/master/examples/tutorial">https://github.com/jonathanslenders/python-prompt-toolkit/tree/master/examples/tutorial</a>. </p>
<p>Finally I started writing something more substantial to scratch my own itch. I was dealing with Postgres databases a lot at that time. The default postgres client &lsquo;psql&rsquo; is a great tool, but it lacked auto-completion as I type and it was quite bland (no syntax highlighting). So I decided to take this as my opportunity to write an alternate. </p>
<p>Thus the creatively named project &lsquo;pgcli&rsquo; was born.</p>
<h3 id="details-about-pgclicom">Details about pgcli.com:</h3>
<p>It is built using <a href="https://pypi.python.org/pypi/pelican/">pelican</a> a static site generator written in Python. </p>
<p>It is hosted by Github pages. </p>
<p>The content is written using RestructuredText.</p>
<h3 id="inspiration">Inspiration:</h3>
<p>The design inspiration for the tool comes from my favorite python interpreter <a href="http://www.bpython-interpreter.org/">bpython</a>.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Goodbye Utah</title>
      <link>https://amjith.com/blog/goodbye-utah/</link>
      <pubDate>Thu, 24 May 2012 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/goodbye-utah/</guid>
      <description>&lt;p&gt;The time has come to part ways. I&amp;rsquo;m leaving Utah to move to Portland on May 25th 2012. This July would have marked the 10 year anniversary of living in Utah. I can&amp;rsquo;t believe I spent one third of my life so far in Utah. Some of the best memories in my life were formed here.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;True Love:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I met my beautiful wife here in Utah. She kicked my ass in TaeKwonDo, I asked her out, and the rest is history. Happily married for  four years with a baby on the way.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892903/QLS16CZgYW9RRKHJpwnk5iJgVHs/large_232323232-fp33-nu3282-384-873-WSNRCG323372-389847nu0mrj.jpeg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;◀
1
of
2
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892904/RRDsnI2kY7XB5UbB1iaZVq6fia4/thumb_hisa_520.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892905/wIPELrv0bGcu4lExTe5j_rl7KTo/thumb_hisa_459.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892904/RRDsnI2kY7XB5UbB1iaZVq6fia4/large_hisa_520.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;First Job:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;My first real programming job was with &lt;a href=&#34;http://featurecam.com/&#34;&gt;Delcam&lt;/a&gt; USA. I still have my first paystub from Delcam. Tom my boss at Delcam is still the best boss I&amp;rsquo;ve had so far.&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892906/ETJeZk3ELqjnF-y1nY6dxUO5q3s/large_IMG_4637.JPG&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Higher Education:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;University of Utah. So many memories, so many sleepless nights at the computer lab. I still get a nostalgia when I walk through the campus.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Parksvan:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Eight clueless kids from India got together to share accomodation while going to school and ended up sharing the best parts of our life. Although we have all parted ways since our college days, I can&amp;rsquo;t help but feel they are part of my family.&lt;/p&gt;
&lt;p&gt;◀
1
of
2
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892907/jEuYkE2C3stMrAz2j9fHYZQQEWA/thumb_100_1141.JPG&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892908/qBQl_xzly_7nV8c6Dz66xipPHro/thumb_100_1167.JPG&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892907/jEuYkE2C3stMrAz2j9fHYZQQEWA/large_100_1141.JPG&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Aikido:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;When I went to my first class, I thought I was going there to give my wife some company. Four years and 6 belts later, it has become a dominating force in my life. I never knew getting thrown around was the way to make new friends. :)&lt;/p&gt;
&lt;p&gt;◀
1
of
2
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892909/35z6gLwI6RSXaIlBJdVgXbCHp1M/thumb_IMG_8809.JPG&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892910/Lz9ShEEOQmmZSvPQoA10baS2vfc/thumb_IMG_8848.JPG&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892909/35z6gLwI6RSXaIlBJdVgXbCHp1M/large_IMG_8809.JPG&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Along the way I discovered the wonderful art of Iaido. I call it the art of playing with Japanese swords.&lt;/p&gt;
&lt;p&gt;◀
1
of
2
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892911/nGmIMH_UvvS9uRDkOMpJvovGT6s/thumb_DSC_4667.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892912/qZaJYV6wS6qnecgV9__qvCnxFL4/thumb_DSC_4591.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892911/nGmIMH_UvvS9uRDkOMpJvovGT6s/large_DSC_4667.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Python:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I couldn&amp;rsquo;t believe there was a &lt;a href=&#34;http://www.utahpython.org&#34;&gt;group&lt;/a&gt; of people who met every month to geek out about their favorite language. My heartfelt thanks to &lt;a href=&#34;http://sexysexypenguins.com/&#34;&gt;herlo&lt;/a&gt;, &lt;a href=&#34;http://hairysun.com/&#34;&gt;mharrison&lt;/a&gt;, &lt;a href=&#34;http://mcquay.me/&#34;&gt;smcquay&lt;/a&gt;, &lt;a href=&#34;http://the.softwaretoolsmith.com/&#34;&gt;travis&lt;/a&gt; and &lt;a href=&#34;http://eseth.org/&#34;&gt;seth&lt;/a&gt;. You guys welcomed me into the group and helped me shape my future in the world of Python. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Outdoor:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I took up Mountain Biking, Hiking and Snowboarding and I&amp;rsquo;ve loved every minute of it. I will miss the rocky moutains, Uintahs and the snowy hills. &lt;/p&gt;
&lt;p&gt;◀
1
of
4
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892913/I9ZS7wZ9rD71Zps7R9-azp7GvoQ/thumb_Biking.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892914/ijwmEHhbyDLJaNIp6q4xWdf6ZCA/thumb_IMG_4597.JPG&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892915/V9ODdBYPsCSNB6ISWfy1l3cAUHo/thumb_Hiking.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892916/7iQgwP4wQPCDu64x_B67jfNHKbU/thumb_Snowboarding.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892913/I9ZS7wZ9rD71Zps7R9-azp7GvoQ/large_Biking.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Leaving all of this behind makes me sad. Utah made me into what I am today.&lt;/p&gt;
&lt;p&gt;But now I&amp;rsquo;m headed to Portland to work for &lt;a href=&#34;http://newrelic.com&#34;&gt;New Relic&lt;/a&gt;. I&amp;rsquo;m told Oregon is a wonderful place, but I&amp;rsquo;ll always have fond memories of Utah wherever I go. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>The time has come to part ways. I&rsquo;m leaving Utah to move to Portland on May 25th 2012. This July would have marked the 10 year anniversary of living in Utah. I can&rsquo;t believe I spent one third of my life so far in Utah. Some of the best memories in my life were formed here.</p>
<p><strong>True Love:</strong></p>
<p>I met my beautiful wife here in Utah. She kicked my ass in TaeKwonDo, I asked her out, and the rest is history. Happily married for  four years with a baby on the way.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892903/QLS16CZgYW9RRKHJpwnk5iJgVHs/large_232323232-fp33-nu3282-384-873-WSNRCG323372-389847nu0mrj.jpeg" alt=""  />
</p>
<p>◀
1
of
2
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892904/RRDsnI2kY7XB5UbB1iaZVq6fia4/thumb_hisa_520.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892905/wIPELrv0bGcu4lExTe5j_rl7KTo/thumb_hisa_459.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892904/RRDsnI2kY7XB5UbB1iaZVq6fia4/large_hisa_520.jpg" alt=""  />
</p>
<p><strong>First Job:</strong></p>
<p>My first real programming job was with <a href="http://featurecam.com/">Delcam</a> USA. I still have my first paystub from Delcam. Tom my boss at Delcam is still the best boss I&rsquo;ve had so far.</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892906/ETJeZk3ELqjnF-y1nY6dxUO5q3s/large_IMG_4637.JPG" alt=""  />
</p>
<p><strong>Higher Education:</strong></p>
<p>University of Utah. So many memories, so many sleepless nights at the computer lab. I still get a nostalgia when I walk through the campus.</p>
<p><strong>Parksvan:</strong></p>
<p>Eight clueless kids from India got together to share accomodation while going to school and ended up sharing the best parts of our life. Although we have all parted ways since our college days, I can&rsquo;t help but feel they are part of my family.</p>
<p>◀
1
of
2
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892907/jEuYkE2C3stMrAz2j9fHYZQQEWA/thumb_100_1141.JPG" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892908/qBQl_xzly_7nV8c6Dz66xipPHro/thumb_100_1167.JPG" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892907/jEuYkE2C3stMrAz2j9fHYZQQEWA/large_100_1141.JPG" alt=""  />
</p>
<p><strong>Aikido:</strong></p>
<p>When I went to my first class, I thought I was going there to give my wife some company. Four years and 6 belts later, it has become a dominating force in my life. I never knew getting thrown around was the way to make new friends. :)</p>
<p>◀
1
of
2
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892909/35z6gLwI6RSXaIlBJdVgXbCHp1M/thumb_IMG_8809.JPG" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892910/Lz9ShEEOQmmZSvPQoA10baS2vfc/thumb_IMG_8848.JPG" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892909/35z6gLwI6RSXaIlBJdVgXbCHp1M/large_IMG_8809.JPG" alt=""  />
</p>
<p>Along the way I discovered the wonderful art of Iaido. I call it the art of playing with Japanese swords.</p>
<p>◀
1
of
2
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892911/nGmIMH_UvvS9uRDkOMpJvovGT6s/thumb_DSC_4667.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892912/qZaJYV6wS6qnecgV9__qvCnxFL4/thumb_DSC_4591.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892911/nGmIMH_UvvS9uRDkOMpJvovGT6s/large_DSC_4667.jpg" alt=""  />
</p>
<p><strong>Python:</strong></p>
<p>I couldn&rsquo;t believe there was a <a href="http://www.utahpython.org">group</a> of people who met every month to geek out about their favorite language. My heartfelt thanks to <a href="http://sexysexypenguins.com/">herlo</a>, <a href="http://hairysun.com/">mharrison</a>, <a href="http://mcquay.me/">smcquay</a>, <a href="http://the.softwaretoolsmith.com/">travis</a> and <a href="http://eseth.org/">seth</a>. You guys welcomed me into the group and helped me shape my future in the world of Python. </p>
<p><strong>Outdoor:</strong></p>
<p>I took up Mountain Biking, Hiking and Snowboarding and I&rsquo;ve loved every minute of it. I will miss the rocky moutains, Uintahs and the snowy hills. </p>
<p>◀
1
of
4
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892913/I9ZS7wZ9rD71Zps7R9-azp7GvoQ/thumb_Biking.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892914/ijwmEHhbyDLJaNIp6q4xWdf6ZCA/thumb_IMG_4597.JPG" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892915/V9ODdBYPsCSNB6ISWfy1l3cAUHo/thumb_Hiking.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892916/7iQgwP4wQPCDu64x_B67jfNHKbU/thumb_Snowboarding.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892913/I9ZS7wZ9rD71Zps7R9-azp7GvoQ/large_Biking.jpg" alt=""  />
</p>
<p>Leaving all of this behind makes me sad. Utah made me into what I am today.</p>
<p>But now I&rsquo;m headed to Portland to work for <a href="http://newrelic.com">New Relic</a>. I&rsquo;m told Oregon is a wonderful place, but I&rsquo;ll always have fond memories of Utah wherever I go. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Python Profiling - Part 1</title>
      <link>https://amjith.com/blog/python-profiling-part-1/</link>
      <pubDate>Tue, 15 May 2012 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/python-profiling-part-1/</guid>
      <description>&lt;p&gt;I gave a talk on profiling python code at the 2012 Utah Open Source Conference. Here are the &lt;a href=&#34;http://bit.ly/J4lO2L&#34;&gt;slides&lt;/a&gt; and the accompanying &lt;a href=&#34;http://bit.ly/IJTm8e&#34;&gt;code&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;There are three parts to this profiling talk:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Standard Lib Tools - cProfile, Pstats&lt;/li&gt;
&lt;li&gt;Third Party Tools - line_profiler, mem_profiler&lt;/li&gt;
&lt;li&gt;Commercial Tools - New Relic&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;This is Part 1 of that talk. It covers:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;cProfile module - usage&lt;/li&gt;
&lt;li&gt;Pstats module - usage&lt;/li&gt;
&lt;li&gt;RunSnakeRun - GUI viewer&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Why Profiling:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Identify the bottle-necks.&lt;/li&gt;
&lt;li&gt;Optimize intelligently.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;In God we trust, everyone else bring data&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;a href=&#34;http://docs.python.org/library/profile.html#module-cProfile&#34;&gt;cProfile:&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;cProfile is a profiling module that is included in the Python&amp;rsquo;s standard library. It instruments the code and reports the time to run each function and the number of times each function is called. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Basic Usage:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The sample code I&amp;rsquo;m profiling is finding the lowest common multiplier of two numbers. &lt;a href=&#34;https://github.com/amjith/utosc_python_profiling/blob/master/code_samples/lcm.py&#34;&gt;lcm.py&lt;/a&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;# lcm.py - ver1 
    def lcm(arg1, arg2):
        i = max(arg1, arg2)
        while i &amp;lt; (arg1 * arg2):
            if i % min(arg1,arg2) == 0:
                return i
            i += max(arg1,arg2)
        return(arg1 * arg2)

    lcm(21498497, 3890120)
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Let&amp;rsquo;s run the profiler.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;$ python -m cProfile lcm.py 
     7780242 function calls in 4.474 seconds
    
    Ordered by: standard name
   
    ncalls  tottime  percall  cumtime  percall filename:lineno(function)
         1    0.000    0.000    4.474    4.474 lcm.py:3()
         1    2.713    2.713    4.474    4.474 lcm.py:3(lcm)
   3890120    0.881    0.000    0.881    0.000 {max}
         1    0.000    0.000    0.000    0.000 {method &#39;disable&#39; of &#39;_lsprof.Profiler&#39; objects}
   3890119    0.880    0.000    0.880    0.000 {min}
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;strong&gt;Output Columns:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;ncalls - number of calls to a function.&lt;/li&gt;
&lt;li&gt;tottime - total time spent in the function without counting calls to sub-functions.&lt;/li&gt;
&lt;li&gt;percall - tottime/ncalls&lt;/li&gt;
&lt;li&gt;cumtime - cumulative time spent in a function and it&amp;rsquo;s sub-functions.&lt;/li&gt;
&lt;li&gt;percall - cumtime/ncalls&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;It&amp;rsquo;s clear from the output that the built-in functions max() and min() are called a few thousand times which could be optimized by saving the results in a variable instead of calling it every time. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;a href=&#34;http://docs.python.org/library/profile.html#the-stats-class&#34;&gt;Pstats&lt;/a&gt;:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Pstats is also included in the standard library that is used to analyze profiles that are saved using the cProfile module. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Usage:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;For scripts that are bigger it&amp;rsquo;s not feasible to analyze the output of the cProfile module on the command-line. The solution is to save the profile to a file and use Pstats to analyze it like a database. Example:  Let&amp;rsquo;s analyze &lt;a href=&#34;https://github.com/amjith/utosc_python_profiling/blob/master/code_samples/url_shortener/shorten.py&#34;&gt;shorten.py&lt;/a&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;$ python -m cProfile -o shorten.prof shorten.py   # saves the output to shorten.prof

$ ls
shorten.py shorten.prof
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Let&amp;rsquo;s analyze the profiler output to list the top 5 frequently called functions.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;$ python 
&amp;gt;&amp;gt;&amp;gt; import pstats
&amp;gt;&amp;gt;&amp;gt; p  = pstats.Stats(&#39;script.prof&#39;)   # Load the profiler output
&amp;gt;&amp;gt;&amp;gt; p.sort_stats(&#39;calls&#39;)              # Sort the results by the ncalls column
&amp;gt;&amp;gt;&amp;gt; p.print_stats(5)                   # Print top 5 items

    95665 function calls (93215 primitive calls) in 2.371 seconds
    
   Ordered by: call count
   List reduced from 1919 to 5 due to restriction &amp;lt;5&amp;gt;
    
       ncalls  tottime  percall  cumtime  percall filename:lineno(function)
    10819/10539    0.002    0.000    0.002    0.000 {len}
           9432    0.002    0.000    0.002    0.000 {method &#39;append&#39; of &#39;list&#39; objects}
           6061    0.003    0.000    0.003    0.000 {isinstance}
           3092    0.004    0.000    0.005    0.000 /lib/python2.7/sre_parse.py:182(__next)
           2617    0.001    0.000    0.001    0.000 {method &#39;endswith&#39; of &#39;str&#39; objects}
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;This is quite tedious or not a lot of fun. Let&amp;rsquo;s introduce a GUI so we can easily drill down. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;a href=&#34;http://www.vrplumber.com/programming/runsnakerun/&#34;&gt;RunSnakeRun&lt;/a&gt;:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;This cleverly named GUI written in wxPython makes life a lot easy. &lt;/p&gt;
&lt;p&gt;Install it from PyPI using (requires wxPython)&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;$ pip install SquareMap RunSnakeRun
$ runsnake shorten.prof     #load the profile using GUI
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;The output is displayed using squaremaps that clearly highlights the bigger pieces of the pie that are worth optimizing. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892919/g929kVS6XvO6B_sBSK3qGB1k8CM/large_runsnake.png&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;It also lets you sort by clicking the columns or drill down by double clicking on a piece of the SquareMap.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Conclusion:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;That concludes Part 1 of the profiling series. All the tools except RunSnakeRun are available as part of the standard library. It is essential to introspect the code before we start shooting in the dark in the hopes of optimizing the code.&lt;/p&gt;
&lt;p&gt;We&amp;rsquo;ll look at line_profilers and mem_profilers in Part 2. Stay tuned. &lt;/p&gt;
&lt;p&gt;You are welcome to follow me on &lt;a href=&#34;https://twitter.com/#!/amjithr&#34;&gt;twitter (@amjithr)&lt;/a&gt;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I gave a talk on profiling python code at the 2012 Utah Open Source Conference. Here are the <a href="http://bit.ly/J4lO2L">slides</a> and the accompanying <a href="http://bit.ly/IJTm8e">code</a>.</p>
<p>There are three parts to this profiling talk:</p>
<ul>
<li>Standard Lib Tools - cProfile, Pstats</li>
<li>Third Party Tools - line_profiler, mem_profiler</li>
<li>Commercial Tools - New Relic</li>
</ul>
<p>This is Part 1 of that talk. It covers:</p>
<ul>
<li>cProfile module - usage</li>
<li>Pstats module - usage</li>
<li>RunSnakeRun - GUI viewer</li>
</ul>
<p><strong>Why Profiling:</strong></p>
<ul>
<li>Identify the bottle-necks.</li>
<li>Optimize intelligently.</li>
</ul>
<p>In God we trust, everyone else bring data</p>
<p><strong><a href="http://docs.python.org/library/profile.html#module-cProfile">cProfile:</a></strong></p>
<p>cProfile is a profiling module that is included in the Python&rsquo;s standard library. It instruments the code and reports the time to run each function and the number of times each function is called. </p>
<p><strong>Basic Usage:</strong></p>
<p>The sample code I&rsquo;m profiling is finding the lowest common multiplier of two numbers. <a href="https://github.com/amjith/utosc_python_profiling/blob/master/code_samples/lcm.py">lcm.py</a></p>
<pre><code># lcm.py - ver1 
    def lcm(arg1, arg2):
        i = max(arg1, arg2)
        while i &lt; (arg1 * arg2):
            if i % min(arg1,arg2) == 0:
                return i
            i += max(arg1,arg2)
        return(arg1 * arg2)

    lcm(21498497, 3890120)
</code></pre><p>Let&rsquo;s run the profiler.</p>
<pre><code>$ python -m cProfile lcm.py 
     7780242 function calls in 4.474 seconds
    
    Ordered by: standard name
   
    ncalls  tottime  percall  cumtime  percall filename:lineno(function)
         1    0.000    0.000    4.474    4.474 lcm.py:3()
         1    2.713    2.713    4.474    4.474 lcm.py:3(lcm)
   3890120    0.881    0.000    0.881    0.000 {max}
         1    0.000    0.000    0.000    0.000 {method 'disable' of '_lsprof.Profiler' objects}
   3890119    0.880    0.000    0.880    0.000 {min}
</code></pre><p><strong>Output Columns:</strong></p>
<ul>
<li>ncalls - number of calls to a function.</li>
<li>tottime - total time spent in the function without counting calls to sub-functions.</li>
<li>percall - tottime/ncalls</li>
<li>cumtime - cumulative time spent in a function and it&rsquo;s sub-functions.</li>
<li>percall - cumtime/ncalls</li>
</ul>
<p>It&rsquo;s clear from the output that the built-in functions max() and min() are called a few thousand times which could be optimized by saving the results in a variable instead of calling it every time. </p>
<p><strong><a href="http://docs.python.org/library/profile.html#the-stats-class">Pstats</a>:</strong></p>
<p>Pstats is also included in the standard library that is used to analyze profiles that are saved using the cProfile module. </p>
<p><strong>Usage:</strong></p>
<p>For scripts that are bigger it&rsquo;s not feasible to analyze the output of the cProfile module on the command-line. The solution is to save the profile to a file and use Pstats to analyze it like a database. Example:  Let&rsquo;s analyze <a href="https://github.com/amjith/utosc_python_profiling/blob/master/code_samples/url_shortener/shorten.py">shorten.py</a>.</p>
<pre><code>$ python -m cProfile -o shorten.prof shorten.py   # saves the output to shorten.prof

$ ls
shorten.py shorten.prof
</code></pre><p>Let&rsquo;s analyze the profiler output to list the top 5 frequently called functions.</p>
<pre><code>$ python 
&gt;&gt;&gt; import pstats
&gt;&gt;&gt; p  = pstats.Stats('script.prof')   # Load the profiler output
&gt;&gt;&gt; p.sort_stats('calls')              # Sort the results by the ncalls column
&gt;&gt;&gt; p.print_stats(5)                   # Print top 5 items

    95665 function calls (93215 primitive calls) in 2.371 seconds
    
   Ordered by: call count
   List reduced from 1919 to 5 due to restriction &lt;5&gt;
    
       ncalls  tottime  percall  cumtime  percall filename:lineno(function)
    10819/10539    0.002    0.000    0.002    0.000 {len}
           9432    0.002    0.000    0.002    0.000 {method 'append' of 'list' objects}
           6061    0.003    0.000    0.003    0.000 {isinstance}
           3092    0.004    0.000    0.005    0.000 /lib/python2.7/sre_parse.py:182(__next)
           2617    0.001    0.000    0.001    0.000 {method 'endswith' of 'str' objects}
</code></pre><p>This is quite tedious or not a lot of fun. Let&rsquo;s introduce a GUI so we can easily drill down. </p>
<p><strong><a href="http://www.vrplumber.com/programming/runsnakerun/">RunSnakeRun</a>:</strong></p>
<p>This cleverly named GUI written in wxPython makes life a lot easy. </p>
<p>Install it from PyPI using (requires wxPython)</p>
<pre><code>$ pip install SquareMap RunSnakeRun
$ runsnake shorten.prof     #load the profile using GUI
</code></pre><p>The output is displayed using squaremaps that clearly highlights the bigger pieces of the pie that are worth optimizing. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892919/g929kVS6XvO6B_sBSK3qGB1k8CM/large_runsnake.png" alt=""  />
</p>
<p>It also lets you sort by clicking the columns or drill down by double clicking on a piece of the SquareMap.</p>
<p><strong>Conclusion:</strong></p>
<p>That concludes Part 1 of the profiling series. All the tools except RunSnakeRun are available as part of the standard library. It is essential to introspect the code before we start shooting in the dark in the hopes of optimizing the code.</p>
<p>We&rsquo;ll look at line_profilers and mem_profilers in Part 2. Stay tuned. </p>
<p>You are welcome to follow me on <a href="https://twitter.com/#!/amjithr">twitter (@amjithr)</a>.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>PyCon 2012 Review</title>
      <link>https://amjith.com/blog/pycon-2012-review/</link>
      <pubDate>Tue, 20 Mar 2012 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/pycon-2012-review/</guid>
      <description>&lt;p&gt;PyCon 2012 was held at Santa Clara, California.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Tutorial:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I was there on the Thrusday to attend a tutorial called &lt;a href=&#34;http://pyvideo.org/video/613/python-epiphanies&#34;&gt;Python Epiphanies&lt;/a&gt;. The tutorial was educational in understanding some of the inner workings of Python. But I have a hard time trying to figure out how to use the knowledge I gained there. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Opening Ceremony:&lt;/strong&gt;
&lt;strong&gt;We had ROBOTS.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;◀
1
of
3
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892920/ulfstmCYtAi6b09QbOoIDkXlMhE/thumb_P1080277.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892921/FRBiAgq0r_Rssy2n0ChjJQaWg7w/thumb_P1080276.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892922/g__yVqUNT2woJkdvt0O1QwGGhps/thumb_P1080279.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892920/ulfstmCYtAi6b09QbOoIDkXlMhE/large_P1080277.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;And they were dancing&amp;hellip;. how cool was that? It was a splendid opening ceremony. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Socializing:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Thursday evening was bag stuffing. Where we helped out by stuffing the swag bag. I got to work side-by-side some well known figures in the community (&lt;a href=&#34;https://twitter.com/#!/jessenoller&#34;&gt;Jesse Noller&lt;/a&gt;, &lt;a href=&#34;http://pydanny.github.com/&#34;&gt;Pydanny&lt;/a&gt;). After that I hung out with some &lt;a href=&#34;http://www.heroku.com/&#34;&gt;Heroku&lt;/a&gt; folks and learned about their awesome work culture.&lt;/p&gt;
&lt;p&gt;Later that night, Yannick and &lt;a href=&#34;https://twitter.com/#!/bryanveloso&#34;&gt;Bryan&lt;/a&gt; gave a Pycon newbie orientation. I took their advice and gave a Lightning Talk about bpython (my talk is 10min into the video).&lt;/p&gt;
&lt;p&gt;I socialized plenty and got a lot of useful contacts from different companies. I got to meet the founders of &lt;a href=&#34;http://octopart.com&#34;&gt;Octopart&lt;/a&gt;, my favorite Electrical Engineering based startups. &lt;/p&gt;
&lt;p&gt;I also met with &lt;a href=&#34;http://www.kennethreitz.com/&#34;&gt;Kenneth Reitz&lt;/a&gt; who is famous for his requests library and this awesome talk &lt;a href=&#34;http://python-for-humans.heroku.com/&#34;&gt;Python for Humans&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I was quite thrilled when I first saw Guido at the Lunch hall sitting right next to my table. I was too shy to talk to him, but I managed to get a picture with him (in the frame). &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892923/lNhfsigq4z8f_O5D5x57waaeIlg/large_P1080280.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;Real gutsy! Maybe next year I&amp;rsquo;ll actually shake his hand and get a picture with him. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Keynotes:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;I enjoyed Paul Graham&amp;rsquo;s &lt;a href=&#34;http://pyvideo.org/video/626/keynote-paul-graham-ycombinator&#34;&gt;keynote&lt;/a&gt; quite a bit. He talked about daring startup ideas. His keynote is summarized in these &lt;a href=&#34;http://paulgraham.com/ambitious.html&#34;&gt;two&lt;/a&gt; &lt;a href=&#34;http://paulgraham.com/property.html&#34;&gt;essays&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;David Beazly&amp;rsquo;s &lt;a href=&#34;http://pyvideo.org/video/659/keynote-david-beazley&#34;&gt;keynote&lt;/a&gt; was a walk-through (demo) of tinkering with PyPy. It looked hard as balls and I kept hoping a happy ending where he declared victory. But it ended up being one of those art movie endings that leaves the listeners in a confused and inconclusive state.&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://pyvideo.org/video/956/keynote-guido-van-rossum&#34;&gt;Guido&amp;rsquo;s Keynote&lt;/a&gt; on the other hand was interesting. His talk was sprinkled with unintended hilarity that ensued due to Google&amp;rsquo;s presentation software. He was sporting an awesome T-shirt that read &amp;ldquo;Python is for girls&amp;rdquo; and talked about dealing with Python Trolls.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Talks:&lt;/strong&gt;
I knew that all the talks were video taped and posted &lt;a href=&#34;http://pyvideo.org&#34;&gt;online&lt;/a&gt;, so I didn&amp;rsquo;t worry too much about missing some when I had conflicts.&lt;/p&gt;
&lt;p&gt;The following talks piqued my interest and will make me go exploring a little bit. &lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://pyvideo.org/video/650/permission-or-forgiveness&#34;&gt;Permission or Forgiveness&lt;/a&gt; - Quaint. Applying Grace Murray Hopper&amp;rsquo;s logic to Python programming. &lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://pyvideo.org/video/696/pandas-powerful-data-analysis-tools-for-python&#34;&gt;pandas: Powerful data-analysis tools for Python&lt;/a&gt; - Useful. &lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://pyvideo.org/video/703/web-server-bottlenecks-and-performance-tuning&#34;&gt;Webserver Performance Tuning&lt;/a&gt; - Sounded like a sales pitch for New Relic, but not in a bad way.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://pyvideo.org/video/737/37-building-a-robot-that-can-play-angry-birds-on&#34;&gt;Angry Birds playing Robot&lt;/a&gt; - Hilarious and Informative.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://pyvideo.org/video/686/the-pyed-piper-a-modern-python-alternative-to-aw&#34;&gt;Pyed Piper: Modern Alternative to Awk, Sed etc.&lt;/a&gt;  - Interesting.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Capoeira:&lt;/strong&gt;
I went to the open space organized by Pydanny where he brought his Capoeira instructor who taught us some awesome moves. By the end of the class, we are all breathing heavily and energized. Once I tried to do a hand stand and lost my balance, but Aikido training kicked in and I gracefully rolled out of my fall with just a carpet burn on my elbow. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Open Spaces:&lt;/strong&gt;
I didn&amp;rsquo;t get a chance to go to many of them, but I did attend the open space for &lt;a href=&#34;http://saltstack.org/&#34;&gt;SaltStack&lt;/a&gt; and sat with &lt;a href=&#34;http://eseth.org/&#34;&gt;Seth House&lt;/a&gt; to try and get Salt running on my Macbook. After a few failed attempts, I decided to give Salt a chance on my linux desktop once I got home. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Babbage Difference Engine: (Not Pycon related)&lt;/strong&gt;
Sunday afternoon &lt;a href=&#34;http://mcquay.me/&#34;&gt;Stephen McQuay&lt;/a&gt; (a fellow Utah Pythonista) and I decided to take up Vijay&amp;rsquo;s offer to go visit the Computer History Museum where they were doing a live demo of the Babbage Difference Engine. OMG! It was awesome to watch the history come alive. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892924/ZmYMogaMk1EUG9yCr_3PQ579lag/large_P1080286.JPG&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>PyCon 2012 was held at Santa Clara, California.</p>
<p><strong>Tutorial:</strong></p>
<p>I was there on the Thrusday to attend a tutorial called <a href="http://pyvideo.org/video/613/python-epiphanies">Python Epiphanies</a>. The tutorial was educational in understanding some of the inner workings of Python. But I have a hard time trying to figure out how to use the knowledge I gained there. </p>
<p><strong>Opening Ceremony:</strong>
<strong>We had ROBOTS.</strong></p>
<p>◀
1
of
3
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892920/ulfstmCYtAi6b09QbOoIDkXlMhE/thumb_P1080277.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892921/FRBiAgq0r_Rssy2n0ChjJQaWg7w/thumb_P1080276.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892922/g__yVqUNT2woJkdvt0O1QwGGhps/thumb_P1080279.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892920/ulfstmCYtAi6b09QbOoIDkXlMhE/large_P1080277.jpg" alt=""  />
</p>
<p>And they were dancing&hellip;. how cool was that? It was a splendid opening ceremony. </p>
<p><strong>Socializing:</strong></p>
<p>Thursday evening was bag stuffing. Where we helped out by stuffing the swag bag. I got to work side-by-side some well known figures in the community (<a href="https://twitter.com/#!/jessenoller">Jesse Noller</a>, <a href="http://pydanny.github.com/">Pydanny</a>). After that I hung out with some <a href="http://www.heroku.com/">Heroku</a> folks and learned about their awesome work culture.</p>
<p>Later that night, Yannick and <a href="https://twitter.com/#!/bryanveloso">Bryan</a> gave a Pycon newbie orientation. I took their advice and gave a Lightning Talk about bpython (my talk is 10min into the video).</p>
<p>I socialized plenty and got a lot of useful contacts from different companies. I got to meet the founders of <a href="http://octopart.com">Octopart</a>, my favorite Electrical Engineering based startups. </p>
<p>I also met with <a href="http://www.kennethreitz.com/">Kenneth Reitz</a> who is famous for his requests library and this awesome talk <a href="http://python-for-humans.heroku.com/">Python for Humans</a>.</p>
<p>I was quite thrilled when I first saw Guido at the Lunch hall sitting right next to my table. I was too shy to talk to him, but I managed to get a picture with him (in the frame). </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892923/lNhfsigq4z8f_O5D5x57waaeIlg/large_P1080280.jpg" alt=""  />
</p>
<p>Real gutsy! Maybe next year I&rsquo;ll actually shake his hand and get a picture with him. </p>
<p><strong>Keynotes:</strong></p>
<ul>
<li>I enjoyed Paul Graham&rsquo;s <a href="http://pyvideo.org/video/626/keynote-paul-graham-ycombinator">keynote</a> quite a bit. He talked about daring startup ideas. His keynote is summarized in these <a href="http://paulgraham.com/ambitious.html">two</a> <a href="http://paulgraham.com/property.html">essays</a>.</li>
<li>David Beazly&rsquo;s <a href="http://pyvideo.org/video/659/keynote-david-beazley">keynote</a> was a walk-through (demo) of tinkering with PyPy. It looked hard as balls and I kept hoping a happy ending where he declared victory. But it ended up being one of those art movie endings that leaves the listeners in a confused and inconclusive state.</li>
<li><a href="http://pyvideo.org/video/956/keynote-guido-van-rossum">Guido&rsquo;s Keynote</a> on the other hand was interesting. His talk was sprinkled with unintended hilarity that ensued due to Google&rsquo;s presentation software. He was sporting an awesome T-shirt that read &ldquo;Python is for girls&rdquo; and talked about dealing with Python Trolls.</li>
</ul>
<p><strong>Talks:</strong>
I knew that all the talks were video taped and posted <a href="http://pyvideo.org">online</a>, so I didn&rsquo;t worry too much about missing some when I had conflicts.</p>
<p>The following talks piqued my interest and will make me go exploring a little bit. </p>
<p><a href="http://pyvideo.org/video/650/permission-or-forgiveness">Permission or Forgiveness</a> - Quaint. Applying Grace Murray Hopper&rsquo;s logic to Python programming. </p>
<p><a href="http://pyvideo.org/video/696/pandas-powerful-data-analysis-tools-for-python">pandas: Powerful data-analysis tools for Python</a> - Useful. </p>
<p><a href="http://pyvideo.org/video/703/web-server-bottlenecks-and-performance-tuning">Webserver Performance Tuning</a> - Sounded like a sales pitch for New Relic, but not in a bad way.</p>
<p><a href="http://pyvideo.org/video/737/37-building-a-robot-that-can-play-angry-birds-on">Angry Birds playing Robot</a> - Hilarious and Informative.</p>
<p><a href="http://pyvideo.org/video/686/the-pyed-piper-a-modern-python-alternative-to-aw">Pyed Piper: Modern Alternative to Awk, Sed etc.</a>  - Interesting.</p>
<p><strong>Capoeira:</strong>
I went to the open space organized by Pydanny where he brought his Capoeira instructor who taught us some awesome moves. By the end of the class, we are all breathing heavily and energized. Once I tried to do a hand stand and lost my balance, but Aikido training kicked in and I gracefully rolled out of my fall with just a carpet burn on my elbow. </p>
<p><strong>Open Spaces:</strong>
I didn&rsquo;t get a chance to go to many of them, but I did attend the open space for <a href="http://saltstack.org/">SaltStack</a> and sat with <a href="http://eseth.org/">Seth House</a> to try and get Salt running on my Macbook. After a few failed attempts, I decided to give Salt a chance on my linux desktop once I got home. </p>
<p><strong>Babbage Difference Engine: (Not Pycon related)</strong>
Sunday afternoon <a href="http://mcquay.me/">Stephen McQuay</a> (a fellow Utah Pythonista) and I decided to take up Vijay&rsquo;s offer to go visit the Computer History Museum where they were doing a live demo of the Babbage Difference Engine. OMG! It was awesome to watch the history come alive. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892924/ZmYMogaMk1EUG9yCr_3PQ579lag/large_P1080286.JPG" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Memoization Decorator</title>
      <link>https://amjith.com/blog/memoization-decorator/</link>
      <pubDate>Fri, 10 Feb 2012 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/memoization-decorator/</guid>
      <description>&lt;p&gt;Recently I had the opportunity to give a short 10 min presentation on Memoization Decorator at our local UtahPython Users Group meeting. &lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Memoization:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Everytime a function is called, save the results in a cache (map).&lt;/li&gt;
&lt;li&gt;Next time the function is called with the exact same args, return the value from the cache instead of running the function.&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;p&gt;The code for memoization decorator for python is here: &lt;a href=&#34;http://wiki.python.org/moin/PythonDecoratorLibrary#Memoize&#34;&gt;http://wiki.python.org/moin/PythonDecoratorLibrary#Memoize&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The typical recursive implementation of fibonacci calculation is pretty inefficient O(2^n).   &lt;/p&gt;
&lt;pre&gt;&lt;code&gt;def fibonacci(num):
        print &#39;fibonacci(%d)&#39;%num
        if num in (0,1):
            return num
        return fibonacci(num-1) + fibonacci(num-2)&amp;gt;&amp;gt;&amp;gt; math\_funcs.fibonacci(4) # 9 function calls
 fibonacci(4)
 fibonacci(3)
 fibonacci(2)
 fibonacci(1)
 fibonacci(0)
 fibonacci(1)
 fibonacci(2)
 fibonacci(1)
 fibonacci(0)
 3


&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;But the memoized version makes it ridiculously efficient O(n) with very little effort.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;import memoized
@memoized
def fibonacci(num):
    print &#39;fibonacci(%d)&#39;%num
    if num in (0,1):
        return num
    return fibonacci(num-1) + fibonacci(num-2)
    
&amp;gt;&amp;gt;&amp;gt; math_funcs.mfibonacci(4)  # 5 function calls
    fibonacci(4)
    fibonacci(3)
    fibonacci(2)
    fibonacci(1)
    fibonacci(0)
    3
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;strong&gt;We just converted an algorithm from Exponential Complexity to Linear Complexity by simply adding the memoization decorator.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Slides&lt;/strong&gt;:&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://phaven-prod.s3.amazonaws.com/files/document_part/asset/892925/hdxwrw9aoHWeSDNaJRq77jDRGdg/memoization_decorator.pdf&#34;&gt;Download memoization_decorator.pdf&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Presentation:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I generated the slides using LaTeX Beamer. But instead of writing raw LaTeX code I used reStructured Text (rst) and used rst2beamer script to generate the .tex file. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Source:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The rst file and tex files are available in Github.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://github.com/amjith/User-Group-Presentations/tree/master/memoization_decorator&#34;&gt;https://github.com/amjith/User-Group-Presentations/tree/master/memoization_de&amp;hellip;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Recently I had the opportunity to give a short 10 min presentation on Memoization Decorator at our local UtahPython Users Group meeting. </p>
<blockquote>
<p><strong>Memoization:</strong></p>
<ul>
<li>Everytime a function is called, save the results in a cache (map).</li>
<li>Next time the function is called with the exact same args, return the value from the cache instead of running the function.</li>
</ul>
</blockquote>
<p>The code for memoization decorator for python is here: <a href="http://wiki.python.org/moin/PythonDecoratorLibrary#Memoize">http://wiki.python.org/moin/PythonDecoratorLibrary#Memoize</a></p>
<p><strong>Example:</strong></p>
<p>The typical recursive implementation of fibonacci calculation is pretty inefficient O(2^n).   </p>
<pre><code>def fibonacci(num):
        print 'fibonacci(%d)'%num
        if num in (0,1):
            return num
        return fibonacci(num-1) + fibonacci(num-2)&gt;&gt;&gt; math\_funcs.fibonacci(4) # 9 function calls
 fibonacci(4)
 fibonacci(3)
 fibonacci(2)
 fibonacci(1)
 fibonacci(0)
 fibonacci(1)
 fibonacci(2)
 fibonacci(1)
 fibonacci(0)
 3


</code></pre><p>But the memoized version makes it ridiculously efficient O(n) with very little effort.</p>
<pre><code>import memoized
@memoized
def fibonacci(num):
    print 'fibonacci(%d)'%num
    if num in (0,1):
        return num
    return fibonacci(num-1) + fibonacci(num-2)
    
&gt;&gt;&gt; math_funcs.mfibonacci(4)  # 5 function calls
    fibonacci(4)
    fibonacci(3)
    fibonacci(2)
    fibonacci(1)
    fibonacci(0)
    3
</code></pre><p><strong>We just converted an algorithm from Exponential Complexity to Linear Complexity by simply adding the memoization decorator.</strong></p>
<p><strong>Slides</strong>:</p>
<p><a href="https://phaven-prod.s3.amazonaws.com/files/document_part/asset/892925/hdxwrw9aoHWeSDNaJRq77jDRGdg/memoization_decorator.pdf">Download memoization_decorator.pdf</a></p>
<p><strong>Presentation:</strong></p>
<p>I generated the slides using LaTeX Beamer. But instead of writing raw LaTeX code I used reStructured Text (rst) and used rst2beamer script to generate the .tex file. </p>
<p><strong>Source:</strong></p>
<p>The rst file and tex files are available in Github.</p>
<p><a href="https://github.com/amjith/User-Group-Presentations/tree/master/memoization_decorator">https://github.com/amjith/User-Group-Presentations/tree/master/memoization_de&hellip;</a></p>
<p> </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Productive Meter</title>
      <link>https://amjith.com/blog/100506320/</link>
      <pubDate>Thu, 09 Feb 2012 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/100506320/</guid>
      <description>&lt;p&gt;A few weeks ago I decided that I should suck it up and start learning how to develop for the web. After asking around, my faithful community brethren, I decided to learn Django from its &lt;a href=&#34;https://docs.djangoproject.com/en/1.3/intro/tutorial01/&#34;&gt;docs&lt;/a&gt;. &lt;/p&gt;
&lt;p&gt;::Django documentation is awesome::&lt;/p&gt;
&lt;p&gt;Around this time I came across this post about &lt;a href=&#34;http://www.mattgreer.org/post/2fiveam&#34;&gt;Waking up at 5am to code&lt;/a&gt;. I tried it a few times and it worked wonders. I&amp;rsquo;ve been working on a small project that can keep track of my productivity on the computer. The concept is really simple, just log the window that is on top and find a way to display that data in a meaningful way. &lt;/p&gt;
&lt;p&gt;Today&amp;rsquo;s 5am session got me to a milestone on my project. I am finally able to visaulize the time I spend using a decent looking graph. Which is a huge milestone for someone who learned how to display html tables 3 weeks ago.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Tools:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;https://www.djangoproject.com/&#34;&gt;Django&lt;/a&gt; for backend&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://www.sqlite.org/&#34;&gt;Sqlite&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://haystacksearch.org/&#34;&gt;Haystack/Solr&lt;/a&gt; - search backend for Django&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://fancybox.net/&#34;&gt;FancyBox&lt;/a&gt; - jquery plugin&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://code.google.com/p/flot/&#34;&gt;flot&lt;/a&gt; - jquery plotting lib&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://twitter.github.com/bootstrap/&#34;&gt;Bootstrap&lt;/a&gt; - html/css&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;A huge thanks to my irc friends and random geeks who wrote awesome blog posts and SO answers on every problem I encountered.&lt;/p&gt;
&lt;p&gt;I will be open-sourcing the app pretty soon. Stay tuned.&lt;/p&gt;
&lt;p&gt;◀
1
of
2
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892926/4_eQKjkTgYjmyOrBQVE-NmJ1XSA/thumb_productive_meter_screenshot.png&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892927/twaBYMZbo-aVSaXUtyS7mZDrRhY/thumb_productive_meter_screenshot1.png&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892926/4_eQKjkTgYjmyOrBQVE-NmJ1XSA/large_productive_meter_screenshot.png&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>A few weeks ago I decided that I should suck it up and start learning how to develop for the web. After asking around, my faithful community brethren, I decided to learn Django from its <a href="https://docs.djangoproject.com/en/1.3/intro/tutorial01/">docs</a>. </p>
<p>::Django documentation is awesome::</p>
<p>Around this time I came across this post about <a href="http://www.mattgreer.org/post/2fiveam">Waking up at 5am to code</a>. I tried it a few times and it worked wonders. I&rsquo;ve been working on a small project that can keep track of my productivity on the computer. The concept is really simple, just log the window that is on top and find a way to display that data in a meaningful way. </p>
<p>Today&rsquo;s 5am session got me to a milestone on my project. I am finally able to visaulize the time I spend using a decent looking graph. Which is a huge milestone for someone who learned how to display html tables 3 weeks ago.</p>
<p><strong>Tools:</strong></p>
<ul>
<li><a href="https://www.djangoproject.com/">Django</a> for backend</li>
<li><a href="http://www.sqlite.org/">Sqlite</a></li>
<li><a href="http://haystacksearch.org/">Haystack/Solr</a> - search backend for Django</li>
<li><a href="http://fancybox.net/">FancyBox</a> - jquery plugin</li>
<li><a href="http://code.google.com/p/flot/">flot</a> - jquery plotting lib</li>
<li><a href="http://twitter.github.com/bootstrap/">Bootstrap</a> - html/css</li>
</ul>
<p>A huge thanks to my irc friends and random geeks who wrote awesome blog posts and SO answers on every problem I encountered.</p>
<p>I will be open-sourcing the app pretty soon. Stay tuned.</p>
<p>◀
1
of
2
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892926/4_eQKjkTgYjmyOrBQVE-NmJ1XSA/thumb_productive_meter_screenshot.png" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892927/twaBYMZbo-aVSaXUtyS7mZDrRhY/thumb_productive_meter_screenshot1.png" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892926/4_eQKjkTgYjmyOrBQVE-NmJ1XSA/large_productive_meter_screenshot.png" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Too Many Classes Too Little Time</title>
      <link>https://amjith.com/blog/too-many-classes-too-little-time/</link>
      <pubDate>Mon, 21 Nov 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/too-many-classes-too-little-time/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m taking a couple of the free online classes offered by Standford. One on &lt;a href=&#34;http://ai-class.org&#34;&gt;Artifical Intelligence&lt;/a&gt; and one on &lt;a href=&#34;http://ml-class.org&#34;&gt;Machine Learning&lt;/a&gt;. &lt;/p&gt;
&lt;p&gt;I haven&amp;rsquo;t had so much fun since kindergarten. Actually that&amp;rsquo;s not fair, I didn&amp;rsquo;t enjoy kindergarten this much. I&amp;rsquo;m listening to the classes during my lunch, after work, during weekends. I&amp;rsquo;m working on my assignment with so much enthusiasm, I dread the day when this class ends. &lt;/p&gt;
&lt;p&gt;Stanford just announced a slew of new &lt;a href=&#34;http://www.hci-class.org/&#34;&gt;online&lt;/a&gt; classes offered starting in Jan 2012. I was way too excited when I first read the description on them. Now I&amp;rsquo;m a little sad, becasue I want to take 8 out of the 11 courses that are being offered and I don&amp;rsquo;t have enough time. :(&lt;/p&gt;
&lt;p&gt;Woe is me. &lt;/p&gt;
&lt;p&gt;ps: If you are not taking any of these classes you are missing out big time. Please do yourself a favor and sign up. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;m taking a couple of the free online classes offered by Standford. One on <a href="http://ai-class.org">Artifical Intelligence</a> and one on <a href="http://ml-class.org">Machine Learning</a>. </p>
<p>I haven&rsquo;t had so much fun since kindergarten. Actually that&rsquo;s not fair, I didn&rsquo;t enjoy kindergarten this much. I&rsquo;m listening to the classes during my lunch, after work, during weekends. I&rsquo;m working on my assignment with so much enthusiasm, I dread the day when this class ends. </p>
<p>Stanford just announced a slew of new <a href="http://www.hci-class.org/">online</a> classes offered starting in Jan 2012. I was way too excited when I first read the description on them. Now I&rsquo;m a little sad, becasue I want to take 8 out of the 11 courses that are being offered and I don&rsquo;t have enough time. :(</p>
<p>Woe is me. </p>
<p>ps: If you are not taking any of these classes you are missing out big time. Please do yourself a favor and sign up. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Picking &#39;k&#39; items from a list of &#39;n&#39; - Recursion</title>
      <link>https://amjith.com/blog/picking-k-items-from-a-list-of-n-recursion/</link>
      <pubDate>Mon, 17 Oct 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/picking-k-items-from-a-list-of-n-recursion/</guid>
      <description>&lt;p&gt;Let me preface this post by saying I suck at recursion. But it never stopped me from trying to master it. Here is my latest (successful) attempt at an algorithm that required recursion. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Background:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;You can safely skip this section if you&amp;rsquo;re not interested in the back story behind why I decided to code this up. &lt;/p&gt;
&lt;p&gt;I was listening to &lt;a href=&#34;http://www.khanacademy.org/&#34;&gt;KhanAcademy&lt;/a&gt; videos on &lt;a href=&#34;http://www.khanacademy.org/#probability&#34;&gt;probability&lt;/a&gt;. I was particularly intrigued by the combinatorics &lt;a href=&#34;http://www.khanacademy.org/video/getting-exactly-two-heads--combinatorics?playlist=Probability&#34;&gt;video&lt;/a&gt;. The formula to calculate the number of combinations of nCr was simple, but I wanted to print all the possible combinations of nCr. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Problem Statement:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Given &amp;lsquo;ABCD&amp;rsquo; what are the possible outcomes if you pick 3 letters from it to form a combination without repetition (i.e. &amp;lsquo;ABC&amp;rsquo; is the same as &amp;lsquo;BAC&amp;rsquo;). &lt;/p&gt;
&lt;p&gt;At first I tried to solve this using an iterative method and gave up pretty quickly. It was clearly designed to be a recursive problem. After 4 hours of breaking my head I finally got a working algorithm using recursion. I was pretty adamant about not looking it up online but I seeked some help from IRC (Thanks &lt;a href=&#34;http://www.jtolds.com/&#34;&gt;jtolds&lt;/a&gt;). &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Code:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;def combo(w, l):
        lst = []
        if l &amp;lt; 1:
            return lst
        for i in range(len(w)):
            if l == 1:
                lst.append(w[i])
            for c in combo(w[i+1:], l-1):
                lst.append(w[i] + c)
        return lst
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;strong&gt;Output:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;gt;&amp;gt;&amp;gt; combinations.combo(&#39;abcde&#39;,3)
    [&#39;abc&#39;, &#39;abd&#39;, &#39;abe&#39;, &#39;acd&#39;, &#39;ace&#39;, &#39;ade&#39;, &#39;bcd&#39;, &#39;bce&#39;, &#39;bde&#39;, &#39;cde&#39;]
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;strong&gt;Thoughts:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;It helps to think about recursion with the assumption that an answer for step n-1 already exists.&lt;/li&gt;
&lt;li&gt;If you are getting partial answers check the condition surrounding the return statement.&lt;/li&gt;
&lt;li&gt;Recursion is still not clear (or easy).&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I have confirmed that this works for bigger data sets and am quite happy with this small victory.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Let me preface this post by saying I suck at recursion. But it never stopped me from trying to master it. Here is my latest (successful) attempt at an algorithm that required recursion. </p>
<p><strong>Background:</strong></p>
<p>You can safely skip this section if you&rsquo;re not interested in the back story behind why I decided to code this up. </p>
<p>I was listening to <a href="http://www.khanacademy.org/">KhanAcademy</a> videos on <a href="http://www.khanacademy.org/#probability">probability</a>. I was particularly intrigued by the combinatorics <a href="http://www.khanacademy.org/video/getting-exactly-two-heads--combinatorics?playlist=Probability">video</a>. The formula to calculate the number of combinations of nCr was simple, but I wanted to print all the possible combinations of nCr. </p>
<p><strong>Problem Statement:</strong></p>
<p>Given &lsquo;ABCD&rsquo; what are the possible outcomes if you pick 3 letters from it to form a combination without repetition (i.e. &lsquo;ABC&rsquo; is the same as &lsquo;BAC&rsquo;). </p>
<p>At first I tried to solve this using an iterative method and gave up pretty quickly. It was clearly designed to be a recursive problem. After 4 hours of breaking my head I finally got a working algorithm using recursion. I was pretty adamant about not looking it up online but I seeked some help from IRC (Thanks <a href="http://www.jtolds.com/">jtolds</a>). </p>
<p><strong>Code:</strong></p>
<pre><code>def combo(w, l):
        lst = []
        if l &lt; 1:
            return lst
        for i in range(len(w)):
            if l == 1:
                lst.append(w[i])
            for c in combo(w[i+1:], l-1):
                lst.append(w[i] + c)
        return lst
</code></pre><p><strong>Output:</strong></p>
<pre><code>&gt;&gt;&gt; combinations.combo('abcde',3)
    ['abc', 'abd', 'abe', 'acd', 'ace', 'ade', 'bcd', 'bce', 'bde', 'cde']
</code></pre><p><strong>Thoughts:</strong></p>
<ul>
<li>It helps to think about recursion with the assumption that an answer for step n-1 already exists.</li>
<li>If you are getting partial answers check the condition surrounding the return statement.</li>
<li>Recursion is still not clear (or easy).</li>
</ul>
<p>I have confirmed that this works for bigger data sets and am quite happy with this small victory.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Python Profiling</title>
      <link>https://amjith.com/blog/python-profiling/</link>
      <pubDate>Thu, 13 Oct 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/python-profiling/</guid>
      <description>&lt;p&gt;I did a presentation at our &lt;a href=&#34;http://www.utahpython.org&#34;&gt;local Python User Group&lt;/a&gt; meeting tonight. It was well received, but shorter than I had expected. I should&amp;rsquo;ve added a lot more code examples. &lt;/p&gt;
&lt;p&gt;We talked about usage of cProfile, pstats, runsnakerun and timeit. &lt;/p&gt;
&lt;p&gt;Here are the slides from the presentations: &lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://phaven-prod.s3.amazonaws.com/files/document_part/asset/892930/cU9Mr_PGkOpAp0Q-ETJe9gX2kk0/profiling.pdf&#34;&gt;Download profiling.pdf&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The slides were done using &lt;a href=&#34;http://en.wikipedia.org/wiki/Beamer_(LaTeX)&#34;&gt;latex-beamer&lt;/a&gt;, but I wrote the slides in &lt;a href=&#34;http://docutils.sourceforge.net/rst.html&#34;&gt;reStructuredText&lt;/a&gt; and used &lt;a href=&#34;http://www.agapow.net/programming/python/rst2beamer&#34;&gt;rst2beamer&lt;/a&gt; to create the tex file which was then converted to pdf using pdflatex. &lt;/p&gt;
&lt;p&gt;The source code for the slides are available on &lt;a href=&#34;https://github.com/amjith/User-Group-Presentations/tree/master/profiling&#34;&gt;github&lt;/a&gt;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I did a presentation at our <a href="http://www.utahpython.org">local Python User Group</a> meeting tonight. It was well received, but shorter than I had expected. I should&rsquo;ve added a lot more code examples. </p>
<p>We talked about usage of cProfile, pstats, runsnakerun and timeit. </p>
<p>Here are the slides from the presentations: </p>
<p><a href="https://phaven-prod.s3.amazonaws.com/files/document_part/asset/892930/cU9Mr_PGkOpAp0Q-ETJe9gX2kk0/profiling.pdf">Download profiling.pdf</a></p>
<p>The slides were done using <a href="http://en.wikipedia.org/wiki/Beamer_(LaTeX)">latex-beamer</a>, but I wrote the slides in <a href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> and used <a href="http://www.agapow.net/programming/python/rst2beamer">rst2beamer</a> to create the tex file which was then converted to pdf using pdflatex. </p>
<p>The source code for the slides are available on <a href="https://github.com/amjith/User-Group-Presentations/tree/master/profiling">github</a>.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Programming - A Gateway Drug to Math</title>
      <link>https://amjith.com/blog/programming-a-gateway-drug-to-math/</link>
      <pubDate>Tue, 04 Oct 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/programming-a-gateway-drug-to-math/</guid>
      <description>&lt;p&gt;I decided to try my hand at the Stanford&amp;rsquo;s &lt;a href=&#34;http://www.ai-class.com/&#34;&gt;AI Class&lt;/a&gt;. The pre-requisites mentioned Probability and Linear Algebra. So I started watching Probability videos on &lt;a href=&#34;http://www.khanacademy.org/#probability&#34;&gt;KhanAcademy&lt;/a&gt;. &lt;/p&gt;
&lt;p&gt;Sal Khan was teaching how to find the probability of 2 heads when you toss a coin 5 times.&lt;/p&gt;
&lt;p&gt;A classic nCk problem: &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;http://latex.codecogs.com/gif.latex?%5Csmall%20_nC_k%20=%20%5Cfrac%7Bn!%7D%7Bk!%28n-k%29!%7D&#34; alt=&#34;&#34;  title=&#34;This is the rendered form of the equation. You can not edit this directly. Right click will give you the option to save the image, and in most browsers you can drag the image onto your desktop or another program.&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;The probability of getting 2 heads while tossing a coin 5 times is:&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;http://latex.codecogs.com/gif.latex?P%282%29%20=%20%5Cfrac%7B%7B_5C_2%7D%7D%7B2%5E5%7D&#34; alt=&#34;&#34;  title=&#34;This is the rendered form of the equation. You can not edit this directly. Right click will give you the option to save the image, and in most browsers you can drag the image onto your desktop or another program.&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;But I wanted to find out the probability of getting at least 2 heads when I toss 5 coins.
Its really simple. All I had to do is P(2) + P(3) + P(4) + P(5). 
But then computing&lt;img loading=&#34;lazy&#34; src=&#34;http://latex.codecogs.com/gif.latex?_nC_k&#34; alt=&#34;&#34;  /&gt;
by hand (or a calculator) was painfully slow, let alone do it 4 times.
So I wrote two little functions in Python that will calculate factorial (yes I reinvented the wheel) and&lt;img loading=&#34;lazy&#34; src=&#34;http://latex.codecogs.com/gif.latex?_nC_k&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Nothing teaches you math faster than trying to write a program to do the math for you.&lt;/strong&gt;
Writing a program is the same as teaching the computer how to do a certain task. The only way you can teach someone to do a task is to become a master at doing that task yourself.&lt;/p&gt;
&lt;p&gt;Bonus: It also teaches you corner cases like 0! = 1 and &lt;img loading=&#34;lazy&#34; src=&#34;http://latex.codecogs.com/gif.latex?%5Csmall%20_5C_5%20=%201&#34; alt=&#34;&#34;  /&gt;
 that you wouldn&amp;rsquo;t think of otherwise.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I decided to try my hand at the Stanford&rsquo;s <a href="http://www.ai-class.com/">AI Class</a>. The pre-requisites mentioned Probability and Linear Algebra. So I started watching Probability videos on <a href="http://www.khanacademy.org/#probability">KhanAcademy</a>. </p>
<p>Sal Khan was teaching how to find the probability of 2 heads when you toss a coin 5 times.</p>
<p>A classic nCk problem: </p>
<p><img loading="lazy" src="http://latex.codecogs.com/gif.latex?%5Csmall%20_nC_k%20=%20%5Cfrac%7Bn!%7D%7Bk!%28n-k%29!%7D" alt=""  title="This is the rendered form of the equation. You can not edit this directly. Right click will give you the option to save the image, and in most browsers you can drag the image onto your desktop or another program."  />
</p>
<p>The probability of getting 2 heads while tossing a coin 5 times is:</p>
<p><img loading="lazy" src="http://latex.codecogs.com/gif.latex?P%282%29%20=%20%5Cfrac%7B%7B_5C_2%7D%7D%7B2%5E5%7D" alt=""  title="This is the rendered form of the equation. You can not edit this directly. Right click will give you the option to save the image, and in most browsers you can drag the image onto your desktop or another program."  />
</p>
<p>But I wanted to find out the probability of getting at least 2 heads when I toss 5 coins.
Its really simple. All I had to do is P(2) + P(3) + P(4) + P(5). 
But then computing<img loading="lazy" src="http://latex.codecogs.com/gif.latex?_nC_k" alt=""  />
by hand (or a calculator) was painfully slow, let alone do it 4 times.
So I wrote two little functions in Python that will calculate factorial (yes I reinvented the wheel) and<img loading="lazy" src="http://latex.codecogs.com/gif.latex?_nC_k" alt=""  />
</p>
<p><strong>Nothing teaches you math faster than trying to write a program to do the math for you.</strong>
Writing a program is the same as teaching the computer how to do a certain task. The only way you can teach someone to do a task is to become a master at doing that task yourself.</p>
<p>Bonus: It also teaches you corner cases like 0! = 1 and <img loading="lazy" src="http://latex.codecogs.com/gif.latex?%5Csmall%20_5C_5%20=%201" alt=""  />
 that you wouldn&rsquo;t think of otherwise.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Rant about C&#43;&#43; dependency hell</title>
      <link>https://amjith.com/blog/rant-about-c-dependency-hell/</link>
      <pubDate>Tue, 04 Oct 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/rant-about-c-dependency-hell/</guid>
      <description>&lt;p&gt;When was the last time I vented about C++? The answer for that is always:&lt;/p&gt;
&lt;p&gt;&amp;ldquo;TOO LONG AGO&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;The initial friction to setup a substantial project using C++ is unfucking bearable.&lt;/p&gt;
&lt;p&gt;When we started code revamp at work recently, I decided to be a good citizen and decided to incorporate &lt;a href=&#34;http://cpptest.sourceforge.net/&#34;&gt;cpptest&lt;/a&gt;, a unit testing framework in our project.&lt;/p&gt;
&lt;p&gt;It made me realize how unreasonably complicated Makefiles can be. After 3 hours of peeling away at the complexity I managed to add cpptest to the build dependency of the project. &lt;/p&gt;
&lt;p&gt;Now time to write a few tests and check it out. I&amp;rsquo;m thinking &amp;ldquo;We are almost there&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;FALSE!&lt;/p&gt;
&lt;p&gt;Compilation gives me a gazillion error messages that make absolutely no sense. After about 30mins of &lt;a href=&#34;http://stackoverflow.com/&#34;&gt;StackOverflowing&lt;/a&gt; and Googling, I find out that its not enough to include string.h and map.h in my  header files, but I also need to namespace it. Of course there is no indication (not even a hint) of that in the error messages. So I add &amp;lsquo;using namespace std&amp;rsquo; and get past it.&lt;/p&gt;
&lt;p&gt;Awesome my first test is compiling successfully. Time to run this baby and declare victory. &lt;/p&gt;
&lt;p&gt;Close! But no cigar.&lt;/p&gt;
&lt;p&gt;The executable was unable to load the CppTest library during runtime. Argh!&lt;/p&gt;
&lt;p&gt;I set my LD_LIBRARY_PATH env variable and now it&amp;rsquo;s running. But I can&amp;rsquo;t ask everyone in my team to do that, so I have to figure out how to statically link that library. &lt;/p&gt;
&lt;p&gt;It&amp;rsquo;s already 6pm and I&amp;rsquo;m hungry. That&amp;rsquo;ll have to wait for another day. &lt;/p&gt;
&lt;p&gt;TL;DR - C++ and Makefile can burn in a fire of thousand suns.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>When was the last time I vented about C++? The answer for that is always:</p>
<p>&ldquo;TOO LONG AGO&rdquo;. </p>
<p>The initial friction to setup a substantial project using C++ is unfucking bearable.</p>
<p>When we started code revamp at work recently, I decided to be a good citizen and decided to incorporate <a href="http://cpptest.sourceforge.net/">cpptest</a>, a unit testing framework in our project.</p>
<p>It made me realize how unreasonably complicated Makefiles can be. After 3 hours of peeling away at the complexity I managed to add cpptest to the build dependency of the project. </p>
<p>Now time to write a few tests and check it out. I&rsquo;m thinking &ldquo;We are almost there&rdquo;. </p>
<p>FALSE!</p>
<p>Compilation gives me a gazillion error messages that make absolutely no sense. After about 30mins of <a href="http://stackoverflow.com/">StackOverflowing</a> and Googling, I find out that its not enough to include string.h and map.h in my  header files, but I also need to namespace it. Of course there is no indication (not even a hint) of that in the error messages. So I add &lsquo;using namespace std&rsquo; and get past it.</p>
<p>Awesome my first test is compiling successfully. Time to run this baby and declare victory. </p>
<p>Close! But no cigar.</p>
<p>The executable was unable to load the CppTest library during runtime. Argh!</p>
<p>I set my LD_LIBRARY_PATH env variable and now it&rsquo;s running. But I can&rsquo;t ask everyone in my team to do that, so I have to figure out how to statically link that library. </p>
<p>It&rsquo;s already 6pm and I&rsquo;m hungry. That&rsquo;ll have to wait for another day. </p>
<p>TL;DR - C++ and Makefile can burn in a fire of thousand suns.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Rapid Prototyping in Python</title>
      <link>https://amjith.com/blog/rapid-prototyping-in-python/</link>
      <pubDate>Sun, 25 Sep 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/rapid-prototyping-in-python/</guid>
      <description>&lt;p&gt;I was recently assigned to a new project at work. Like any good software engineer I started writing the pseudocode for the modules. We use C++ at work to write our programs.&lt;/p&gt;
&lt;p&gt;I quickly realized it&amp;rsquo;s not easy to translate programming ideas to English statements without a syntactic structure. When I was whining about it to Vijay, he told me to try prototyping it in Python instead of writing pseudocode. Intrigued by this, I decided to write a prototype in Python to test how various modules will come together.&lt;/p&gt;
&lt;p&gt;Surprisingly it took me a mere 2 hours to code up the prototype. I can&amp;rsquo;t emphasize enough, how effortless it was in Python.&lt;/p&gt;
&lt;h2 id=&#34;what-makes-python-an-ideal-choice-for-prototyping&#34;&gt;What makes Python an ideal choice for prototyping:&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Dynamically typed language:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Python doesn&amp;rsquo;t require you to declare the datatype of a variable. This lets you write a function that is generic enough to handle any kind of data. For eg:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;def max\_val(a,b):
    return a if a &amp;gt;b else b
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;This function can take integers, floats, strings, a combination of any of those, or lists, dictionaries, tuples, whatever.&lt;/p&gt;
&lt;p&gt;A list in Python need not be homogenous. This is a perfectly good list:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;[1, &#39;abc&#39;, [1,2,3]]
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;This lets you pack data in unique ways on the fly which can later be translated to a class or a struct in a statically typed language like C++.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;class newDataType
{
    int i;
    String str;
    Vector vInts;
};
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;strong&gt;Rich Set to Data-Structures:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Built-in support for lists, dictionaries, sets, etc reduces the time involved in hunting for a library that provides you those basic data-structures.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Expressive and Succinct:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The algorithms that operate on the data-structures are intuitive and simple to use. The final code is more readable than a pseudocode.&lt;/p&gt;
&lt;p&gt;For example: Lets check if a list has an element&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;gt;&amp;gt;&amp;gt; lst = [1,2,3]    # Create a list
&amp;gt;&amp;gt;&amp;gt; res = 2 in lst   # Check if 2 is in &#39;lst&#39;
True
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;If we have to do it in C++.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;list lst;
lst.push_back(3);
lst.push_back(1);
lst.push_back(7);
list::iterator result = find(lst.begin(), lst.end(), 7); 
bool res = (result != lst.end())
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;strong&gt;Python Interpreter and Help System:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;This is a huge plus. The presence of interpreter not only aids you in testing snippets of code, but it acts as an help system. Lets say we want to look up the functions that operate on a List.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;gt;&amp;gt;&amp;gt; dir([])
[&#39;\_\_add\_\_&#39;, &#39;\_\_class\_\_&#39;, &#39;\_\_contains\_\_&#39;, &#39;\_\_delattr\_\_&#39;, &#39;\_\_delitem\_\_&#39;,
&#39;\_\_delslice\_\_&#39;, &#39;\_\_doc\_\_&#39;, &#39;\_\_eq\_\_&#39;, &#39;\_\_format\_\_&#39;, &#39;\_\_ge\_\_&#39;, 
&#39;\_\_getattribute\_\_&#39;, &#39;\_\_getitem\_\_&#39;, &#39;\_\_getslice\_\_&#39;, &#39;\_\_gt\_\_&#39;, &#39;\_\_hash\_\_&#39;,
&#39;\_\_iadd\_\_&#39;, &#39;\_\_imul\_\_&#39;, &#39;\_\_init\_\_&#39;, &#39;\_\_iter\_\_&#39;, &#39;\_\_le\_\_&#39;, &#39;\_\_len\_\_&#39;,
&#39;\_\_lt\_\_&#39;, &#39;\_\_mul\_\_&#39;, &#39;\_\_ne\_\_&#39;, &#39;\_\_new\_\_&#39;, &#39;\_\_reduce\_\_&#39;, &#39;\_\_reduce\_ex\_\_&#39;,
&#39;\_\_repr\_\_&#39;, &#39;\_\_reversed\_\_&#39;, &#39;\_\_rmul\_\_&#39;, &#39;\_\_setattr\_\_&#39;, &#39;\_\_setitem\_\_&#39;,
&#39;\_\_setslice\_\_&#39;, &#39;\_\_sizeof\_\_&#39;, &#39;\_\_str\_\_&#39;, &#39;\_\_subclasshook\_\_&#39;, &#39;append&#39;,
&#39;count&#39;, &#39;extend&#39;, &#39;index&#39;, &#39;insert&#39;, &#39;pop&#39;, &#39;remove&#39;, &#39;reverse&#39;, &#39;sort&#39;]

&amp;gt;&amp;gt;&amp;gt; help([].sort)
Help on built-in function sort:
     
sort(...)
    L.sort(cmp=None, key=None, reverse=False) -- stable sort *IN PLACE*;
    cmp(x, y) -&amp;gt; -1, 0, 1
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;strong&gt;Advantages of prototyping instead of pseudocode:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The type definition of the datastructures emerge as we code.&lt;/li&gt;
&lt;li&gt;The edge cases start to emerge when you prototype.&lt;/li&gt;
&lt;li&gt;A set of required supporting routines.&lt;/li&gt;
&lt;li&gt;A better estimation of the time required to complete a task.&lt;/li&gt;
&lt;/ul&gt;
</description>
      <content:encoded><![CDATA[<p>I was recently assigned to a new project at work. Like any good software engineer I started writing the pseudocode for the modules. We use C++ at work to write our programs.</p>
<p>I quickly realized it&rsquo;s not easy to translate programming ideas to English statements without a syntactic structure. When I was whining about it to Vijay, he told me to try prototyping it in Python instead of writing pseudocode. Intrigued by this, I decided to write a prototype in Python to test how various modules will come together.</p>
<p>Surprisingly it took me a mere 2 hours to code up the prototype. I can&rsquo;t emphasize enough, how effortless it was in Python.</p>
<h2 id="what-makes-python-an-ideal-choice-for-prototyping">What makes Python an ideal choice for prototyping:</h2>
<p><strong>Dynamically typed language:</strong></p>
<p>Python doesn&rsquo;t require you to declare the datatype of a variable. This lets you write a function that is generic enough to handle any kind of data. For eg:</p>
<pre><code>def max\_val(a,b):
    return a if a &gt;b else b
</code></pre><p>This function can take integers, floats, strings, a combination of any of those, or lists, dictionaries, tuples, whatever.</p>
<p>A list in Python need not be homogenous. This is a perfectly good list:</p>
<pre><code>[1, 'abc', [1,2,3]]
</code></pre><p>This lets you pack data in unique ways on the fly which can later be translated to a class or a struct in a statically typed language like C++.</p>
<pre><code>class newDataType
{
    int i;
    String str;
    Vector vInts;
};
</code></pre><p><strong>Rich Set to Data-Structures:</strong></p>
<p>Built-in support for lists, dictionaries, sets, etc reduces the time involved in hunting for a library that provides you those basic data-structures.</p>
<p><strong>Expressive and Succinct:</strong></p>
<p>The algorithms that operate on the data-structures are intuitive and simple to use. The final code is more readable than a pseudocode.</p>
<p>For example: Lets check if a list has an element</p>
<pre><code>&gt;&gt;&gt; lst = [1,2,3]    # Create a list
&gt;&gt;&gt; res = 2 in lst   # Check if 2 is in 'lst'
True
</code></pre><p>If we have to do it in C++.</p>
<pre><code>list lst;
lst.push_back(3);
lst.push_back(1);
lst.push_back(7);
list::iterator result = find(lst.begin(), lst.end(), 7); 
bool res = (result != lst.end())
</code></pre><p><strong>Python Interpreter and Help System:</strong></p>
<p>This is a huge plus. The presence of interpreter not only aids you in testing snippets of code, but it acts as an help system. Lets say we want to look up the functions that operate on a List.</p>
<pre><code>&gt;&gt;&gt; dir([])
['\_\_add\_\_', '\_\_class\_\_', '\_\_contains\_\_', '\_\_delattr\_\_', '\_\_delitem\_\_',
'\_\_delslice\_\_', '\_\_doc\_\_', '\_\_eq\_\_', '\_\_format\_\_', '\_\_ge\_\_', 
'\_\_getattribute\_\_', '\_\_getitem\_\_', '\_\_getslice\_\_', '\_\_gt\_\_', '\_\_hash\_\_',
'\_\_iadd\_\_', '\_\_imul\_\_', '\_\_init\_\_', '\_\_iter\_\_', '\_\_le\_\_', '\_\_len\_\_',
'\_\_lt\_\_', '\_\_mul\_\_', '\_\_ne\_\_', '\_\_new\_\_', '\_\_reduce\_\_', '\_\_reduce\_ex\_\_',
'\_\_repr\_\_', '\_\_reversed\_\_', '\_\_rmul\_\_', '\_\_setattr\_\_', '\_\_setitem\_\_',
'\_\_setslice\_\_', '\_\_sizeof\_\_', '\_\_str\_\_', '\_\_subclasshook\_\_', 'append',
'count', 'extend', 'index', 'insert', 'pop', 'remove', 'reverse', 'sort']

&gt;&gt;&gt; help([].sort)
Help on built-in function sort:
     
sort(...)
    L.sort(cmp=None, key=None, reverse=False) -- stable sort *IN PLACE*;
    cmp(x, y) -&gt; -1, 0, 1
</code></pre><p><strong>Advantages of prototyping instead of pseudocode:</strong></p>
<ul>
<li>The type definition of the datastructures emerge as we code.</li>
<li>The edge cases start to emerge when you prototype.</li>
<li>A set of required supporting routines.</li>
<li>A better estimation of the time required to complete a task.</li>
</ul>
]]></content:encoded>
    </item>
    
    <item>
      <title>New Laptop</title>
      <link>https://amjith.com/blog/new-laptop/</link>
      <pubDate>Sat, 27 Aug 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/new-laptop/</guid>
      <description>&lt;p&gt;I finally ordered a new Macbook air for myself. One of my friends remarked at the fact that this is the first brand new laptop that I&amp;rsquo;ve ordered for myself. Since I&amp;rsquo;m a bit of a Linux fanatic, I tend to restore old computers and install a linux distro and make them useable. So I always get old laptops for cheap for myself. But this time I decided it&amp;rsquo;s time to checkout Mac OS X. So I&amp;rsquo;ll be replacing my Netboook (yep!) with the Macbook air. Anyone need a Lenovo S10 netbook :). I will even do a clean-install of Ubuntu or your choice of Linux distro. &lt;/p&gt;
&lt;p&gt;This new Macbook air will be my primary development machine. Let&amp;rsquo;s hope it can take the abuse.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I finally ordered a new Macbook air for myself. One of my friends remarked at the fact that this is the first brand new laptop that I&rsquo;ve ordered for myself. Since I&rsquo;m a bit of a Linux fanatic, I tend to restore old computers and install a linux distro and make them useable. So I always get old laptops for cheap for myself. But this time I decided it&rsquo;s time to checkout Mac OS X. So I&rsquo;ll be replacing my Netboook (yep!) with the Macbook air. Anyone need a Lenovo S10 netbook :). I will even do a clean-install of Ubuntu or your choice of Linux distro. </p>
<p>This new Macbook air will be my primary development machine. Let&rsquo;s hope it can take the abuse.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Falsetto dude and the Fat man</title>
      <link>https://amjith.com/blog/falsetto-dude-and-the-fat-man/</link>
      <pubDate>Sun, 07 Aug 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/falsetto-dude-and-the-fat-man/</guid>
      <description>&lt;p&gt;A typical conversation between my wife and I: &lt;/p&gt;
&lt;p&gt;Playing Ne Me Quitte Pas by Nina Simone&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Yoshi&lt;/strong&gt; : Ow! What is that abomination? &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Amjith&lt;/strong&gt;: It&amp;rsquo;s a french song sung by the great Nina Simone.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Yoshi&lt;/strong&gt; : It&amp;rsquo;s a woman? Sounded like a dude singing in falsetto.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Yoshi&lt;/strong&gt;: I&amp;rsquo;m leaving the room if you don&amp;rsquo;t change the song.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Amjith&lt;/strong&gt;: FINE. You play something then.&lt;/p&gt;
&lt;p&gt;Yoshi puts on Ave Maria by Pavarotti. &lt;/p&gt;
&lt;p&gt;I wait for 2 mins.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Amjith&lt;/strong&gt;: Hey! Your fat man seems to be yelling at Maria. &lt;/p&gt;
&lt;p&gt;Yosh leaves the room and I sleep on the couch.&lt;/p&gt;
&lt;p&gt;The End&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>A typical conversation between my wife and I: </p>
<p>Playing Ne Me Quitte Pas by Nina Simone</p>
<p><strong>Yoshi</strong> : Ow! What is that abomination? </p>
<p><strong>Amjith</strong>: It&rsquo;s a french song sung by the great Nina Simone.</p>
<p><strong>Yoshi</strong> : It&rsquo;s a woman? Sounded like a dude singing in falsetto.</p>
<p><strong>Yoshi</strong>: I&rsquo;m leaving the room if you don&rsquo;t change the song.</p>
<p><strong>Amjith</strong>: FINE. You play something then.</p>
<p>Yoshi puts on Ave Maria by Pavarotti. </p>
<p>I wait for 2 mins.</p>
<p><strong>Amjith</strong>: Hey! Your fat man seems to be yelling at Maria. </p>
<p>Yosh leaves the room and I sleep on the couch.</p>
<p>The End</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Scripting Tmux Layouts</title>
      <link>https://amjith.com/blog/scripting-tmux-layouts/</link>
      <pubDate>Wed, 03 Aug 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/scripting-tmux-layouts/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://tmux.sourceforge.net/&#34;&gt;Tmux&lt;/a&gt; is an awesome replacement for Screen. I have a couple of standard terminal layouts for programming. One of them is show below.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://vim.org&#34;&gt;Vim&lt;/a&gt; editor on the left.&lt;/li&gt;
&lt;li&gt;Top right pane has the &lt;a href=&#34;http://bpython-interpreter.org/&#34;&gt;bpython&lt;/a&gt; interpreter.&lt;/li&gt;
&lt;li&gt;Bottom right pane has the bash prompt.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892933/mm5x3LqvXmEauncIa8R6JP4f2cg/large_python_dev.png&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I have a small tmux script in my ~/.tmux/pdev file that has the following lines&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;selectp -t 0              # Select pane 0
splitw -h -p 50 &#39;bpython&#39; # Split pane 0 vertically by 50%
selectp -t 1              # Select pane 1
splitw -v -p 25           # Split pane 1 horizontally by 25%
selectp -t 0              # Select pane 0
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;In my &lt;a href=&#34;https://github.com/amjith/_dotties/blob/master/tmux.conf&#34;&gt;tmux.conf&lt;/a&gt; file I have bound &lt;prefix&gt;+P to sourcing this file. So now anytime I want to launch my python dev layout, I hit &lt;prefix&gt;+&lt;shift&gt;+p. &lt;/p&gt;
&lt;pre&gt;&lt;code&gt;bind P source-file ~/.tmux/pdev
&lt;/code&gt;&lt;/pre&gt;</description>
      <content:encoded><![CDATA[<p><a href="http://tmux.sourceforge.net/">Tmux</a> is an awesome replacement for Screen. I have a couple of standard terminal layouts for programming. One of them is show below.</p>
<ul>
<li><a href="http://vim.org">Vim</a> editor on the left.</li>
<li>Top right pane has the <a href="http://bpython-interpreter.org/">bpython</a> interpreter.</li>
<li>Bottom right pane has the bash prompt.</li>
</ul>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892933/mm5x3LqvXmEauncIa8R6JP4f2cg/large_python_dev.png" alt=""  />
</p>
<p>I have a small tmux script in my ~/.tmux/pdev file that has the following lines</p>
<pre><code>selectp -t 0              # Select pane 0
splitw -h -p 50 'bpython' # Split pane 0 vertically by 50%
selectp -t 1              # Select pane 1
splitw -v -p 25           # Split pane 1 horizontally by 25%
selectp -t 0              # Select pane 0
</code></pre><p>In my <a href="https://github.com/amjith/_dotties/blob/master/tmux.conf">tmux.conf</a> file I have bound <prefix>+P to sourcing this file. So now anytime I want to launch my python dev layout, I hit <prefix>+<shift>+p. </p>
<pre><code>bind P source-file ~/.tmux/pdev
</code></pre>]]></content:encoded>
    </item>
    
    <item>
      <title>Downloading Specific Filetypes using &#39;wget&#39;</title>
      <link>https://amjith.com/blog/downloading-specific-filetypes-using-wget/</link>
      <pubDate>Mon, 01 Aug 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/downloading-specific-filetypes-using-wget/</guid>
      <description>&lt;p&gt;I decided to prepare myself for the &lt;a href=&#34;http://www.ai-class.com/&#34;&gt;Intro to AI&lt;/a&gt;, a free online course offered by Stanford. I found the course website: &lt;a href=&#34;http://www.stanford.edu/class/cs221/schedule.html&#34;&gt;http://www.stanford.edu/class/cs221/schedule.html&lt;/a&gt; and wanted to download all the slides. &lt;/p&gt;
&lt;p&gt;It&amp;rsquo;s time to pull all the ppt files from that page.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;wget -r -A.ppt http://www.stanford.edu/class/cs221/notes/ 
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;This created a tree of empty directories with one of them that had all the ppt files. Time to clean up the empty folders:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;find -depth -type d -empty -exec rmdir {} \;
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Ta-da! Empty folders are gone. &lt;/p&gt;
&lt;p&gt;Remember if you are typing a command more than once in succession there is a way to automate it. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I decided to prepare myself for the <a href="http://www.ai-class.com/">Intro to AI</a>, a free online course offered by Stanford. I found the course website: <a href="http://www.stanford.edu/class/cs221/schedule.html">http://www.stanford.edu/class/cs221/schedule.html</a> and wanted to download all the slides. </p>
<p>It&rsquo;s time to pull all the ppt files from that page.</p>
<pre><code>wget -r -A.ppt http://www.stanford.edu/class/cs221/notes/ 
</code></pre><p>This created a tree of empty directories with one of them that had all the ppt files. Time to clean up the empty folders:</p>
<pre><code>find -depth -type d -empty -exec rmdir {} \;
</code></pre><p>Ta-da! Empty folders are gone. </p>
<p>Remember if you are typing a command more than once in succession there is a way to automate it. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>How to Find Local Tech Jobs</title>
      <link>https://amjith.com/blog/how-to-find-local-tech-jobs/</link>
      <pubDate>Mon, 06 Jun 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/how-to-find-local-tech-jobs/</guid>
      <description>&lt;p&gt;Looking for tech jobs can be daunting. Networking is touted as the magic bullet for job seekers. But where do you start?&lt;/p&gt;
&lt;p&gt;Here are some robust ways to build your network.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Users Group:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;User groups are typically monthly meetings for geeks who get together to talk about their favorite programming language or operating system. Usually they are accompanied with a mailing list which is used to announce the meetings, ask questions and &lt;strong&gt;post job openings&lt;/strong&gt;. So sign up to the mailing list and start attending the meetups. They are full of really nice people who are willing to help. &lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://groups.google.com/group/utahpython/&#34;&gt;Utah Python&lt;/a&gt; - Utah Python Users Group&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://utruby.org/&#34;&gt;URUG&lt;/a&gt; - Utah Ruby Users Group&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://www.sllug.org/&#34;&gt;SLLUG&lt;/a&gt; - Salt Lake Linux Users Group
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://www.sllug.org/cgi-bin/mailman/listinfo/sllug-jobs-announce&#34;&gt;SLLUG-JOBS&lt;/a&gt; - Mailing list to announce job postings&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://www.plug.org/&#34;&gt;PLUG&lt;/a&gt; - Provo Linux Users Group&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Local Conferences:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Most cities have some tech conferences that are a great source for networking. I found out about a lot of the user group by going to one of the following conference.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://utos.org/&#34;&gt;UTOSC&lt;/a&gt; - Utah Open Source Conference.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://project-day.utos.org/projects-2011/&#34;&gt;HackUTOS&lt;/a&gt;  - Utah Open Source Project Day - Geeks, snacks and open source.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://www.launchup.org/&#34;&gt;LaunchUp&lt;/a&gt; - A local entreneurship clinic. A great way to learn about the local start-up scene. You can meet new CEOs and fresh companies looking to hire tech talent. A must for job-seekers.&lt;/p&gt;
&lt;p&gt;I hope this helps someone.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Looking for tech jobs can be daunting. Networking is touted as the magic bullet for job seekers. But where do you start?</p>
<p>Here are some robust ways to build your network.</p>
<p><strong>Users Group:</strong></p>
<p>User groups are typically monthly meetings for geeks who get together to talk about their favorite programming language or operating system. Usually they are accompanied with a mailing list which is used to announce the meetings, ask questions and <strong>post job openings</strong>. So sign up to the mailing list and start attending the meetups. They are full of really nice people who are willing to help. </p>
<ul>
<li><a href="http://groups.google.com/group/utahpython/">Utah Python</a> - Utah Python Users Group</li>
<li><a href="http://utruby.org/">URUG</a> - Utah Ruby Users Group</li>
<li><a href="http://www.sllug.org/">SLLUG</a> - Salt Lake Linux Users Group
<ul>
<li><a href="http://www.sllug.org/cgi-bin/mailman/listinfo/sllug-jobs-announce">SLLUG-JOBS</a> - Mailing list to announce job postings</li>
</ul>
</li>
<li><a href="http://www.plug.org/">PLUG</a> - Provo Linux Users Group</li>
</ul>
<p><strong>Local Conferences:</strong></p>
<p>Most cities have some tech conferences that are a great source for networking. I found out about a lot of the user group by going to one of the following conference.</p>
<p><a href="http://utos.org/">UTOSC</a> - Utah Open Source Conference.</p>
<p><a href="http://project-day.utos.org/projects-2011/">HackUTOS</a>  - Utah Open Source Project Day - Geeks, snacks and open source.</p>
<p><a href="http://www.launchup.org/">LaunchUp</a> - A local entreneurship clinic. A great way to learn about the local start-up scene. You can meet new CEOs and fresh companies looking to hire tech talent. A must for job-seekers.</p>
<p>I hope this helps someone.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Contributing to Open Source</title>
      <link>https://amjith.com/blog/contributing-to-open-source/</link>
      <pubDate>Wed, 04 May 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/contributing-to-open-source/</guid>
      <description>&lt;p&gt;Last week I successfully submitted my &lt;a href=&#34;https://bitbucket.org/bobf/bpython/changeset/bc4a8a7a0e65&#34;&gt;first patch&lt;/a&gt; to an open source project and it was accepted. &lt;/p&gt;
&lt;p&gt;I like the &lt;a href=&#34;http://www.bpython-interpreter.org/&#34;&gt;bpython&lt;/a&gt; interpreter for all my python needs. It is quite handy for a python newbie like me. A few weeks ago I was in the middle of building an elaborate datastructure to learn list comprehension in python, when bpython crashed and took all the history with it. I &lt;a href=&#34;https://twitter.com/#!/_ikanobori/status/60822979994583040&#34;&gt;whined&lt;/a&gt; about it on twitter and one of the developers of the project prompted me to submit a bug report. I was quite impressed by the fact that a core developer of bpython replied to my bitching on twitter.&lt;/p&gt;
&lt;p&gt;After I filed the bug report, I decided to get the source code and poke around. I finally implemented a feature that saved the history after each command instead of waiting till the end of a session. &lt;/p&gt;
&lt;p&gt;The following factors were the main impetus that led me to contribute to the project. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Project Hosting:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The project was hosted on &lt;a href=&#34;http://bitbucket.org&#34;&gt;bit bucket&lt;/a&gt; which is a &lt;a href=&#34;http://github.com&#34;&gt;Github&lt;/a&gt; equivalent for &lt;a href=&#34;http://mercurial.selenic.com/&#34;&gt;mercurial&lt;/a&gt;. This makes it so easy to fork a project and issue pull requests, compared to the traditional source forge model of submitting patches in a mailing list. The social coding sites like Github and BitBucket have reduced much of the initial friction in starting an open source project.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Project Size:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;This one has a huge impact when I decide to dive into the code. Traditional C projects tend to have a ton of files that are too big which is daunting for a beginner. The bpython project was written in python and had a total of 13 .py files. This makes it dead simple to make a quick change and run the project without compiling it. Again the choice of language has a lot to do with this. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;IRC:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The welcoming nature of the community around a project does a lot to encourage a new comer. The IRC channels are a great way to interact with the developers compared to a passive form of communication such as emails. I jumped on #bpython irc channel and started asking questions when I ran into an issue with bpython source code. People on that channel are really helpful and prompt in answering questions.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Persistence:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;My first pull request was scrutinized by the core developers and some suggestions for improvements were given. During that process I learned a lot about code review and how to check for corner cases. Finally after I made all those improvements the pull request was accepted and merged with the main repo. So having a beginners mind (no ego) is an absolute must when getting started on any project. Don&amp;rsquo;t be discouraged if your first attempt is unsuccessful. &lt;/p&gt;
&lt;p&gt;Now I&amp;rsquo;m proud to say my name is listed in the &lt;a href=&#34;https://bitbucket.org/bobf/bpython/src/fd740b9b73ad/AUTHORS&#34;&gt;AUTHORS&lt;/a&gt; file of bpython project.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Last week I successfully submitted my <a href="https://bitbucket.org/bobf/bpython/changeset/bc4a8a7a0e65">first patch</a> to an open source project and it was accepted. </p>
<p>I like the <a href="http://www.bpython-interpreter.org/">bpython</a> interpreter for all my python needs. It is quite handy for a python newbie like me. A few weeks ago I was in the middle of building an elaborate datastructure to learn list comprehension in python, when bpython crashed and took all the history with it. I <a href="https://twitter.com/#!/_ikanobori/status/60822979994583040">whined</a> about it on twitter and one of the developers of the project prompted me to submit a bug report. I was quite impressed by the fact that a core developer of bpython replied to my bitching on twitter.</p>
<p>After I filed the bug report, I decided to get the source code and poke around. I finally implemented a feature that saved the history after each command instead of waiting till the end of a session. </p>
<p>The following factors were the main impetus that led me to contribute to the project. </p>
<p><strong>Project Hosting:</strong></p>
<p>The project was hosted on <a href="http://bitbucket.org">bit bucket</a> which is a <a href="http://github.com">Github</a> equivalent for <a href="http://mercurial.selenic.com/">mercurial</a>. This makes it so easy to fork a project and issue pull requests, compared to the traditional source forge model of submitting patches in a mailing list. The social coding sites like Github and BitBucket have reduced much of the initial friction in starting an open source project.</p>
<p><strong>Project Size:</strong></p>
<p>This one has a huge impact when I decide to dive into the code. Traditional C projects tend to have a ton of files that are too big which is daunting for a beginner. The bpython project was written in python and had a total of 13 .py files. This makes it dead simple to make a quick change and run the project without compiling it. Again the choice of language has a lot to do with this. </p>
<p><strong>IRC:</strong></p>
<p>The welcoming nature of the community around a project does a lot to encourage a new comer. The IRC channels are a great way to interact with the developers compared to a passive form of communication such as emails. I jumped on #bpython irc channel and started asking questions when I ran into an issue with bpython source code. People on that channel are really helpful and prompt in answering questions.</p>
<p><strong>Persistence:</strong></p>
<p>My first pull request was scrutinized by the core developers and some suggestions for improvements were given. During that process I learned a lot about code review and how to check for corner cases. Finally after I made all those improvements the pull request was accepted and merged with the main repo. So having a beginners mind (no ego) is an absolute must when getting started on any project. Don&rsquo;t be discouraged if your first attempt is unsuccessful. </p>
<p>Now I&rsquo;m proud to say my name is listed in the <a href="https://bitbucket.org/bobf/bpython/src/fd740b9b73ad/AUTHORS">AUTHORS</a> file of bpython project.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Synchronize Panes in Tmux</title>
      <link>https://amjith.com/blog/synchronize-panes-in-tmux/</link>
      <pubDate>Mon, 25 Apr 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/synchronize-panes-in-tmux/</guid>
      <description>&lt;p&gt;Tmux is an alternative for screen. For anyone who doesn&amp;rsquo;t know screen, it is a terminal multiplexer which means, it allow multiple windows in terminal. It can split your window into multiple panes (vertical/horizontal), detach a session which can be attached at a later time. Detach/Attach is very useful for running a job in a remote server without having to keep the ssh open the whole time. &lt;/p&gt;
&lt;p&gt;Tmux can be configured by  ~/&lt;a href=&#34;https://github.com/amjith/_dotties/blob/master/tmux.conf&#34;&gt;.tmux.conf&lt;/a&gt; file.
My prefix key is Ctrl-q.
&lt;strong&gt;Synchronizing panes:&lt;/strong&gt;
If you want to send your keystrokes to all the panes in your tmux window: 
&lt;prefix&gt; :setw synchronize-panes
In my case I do:
Ctrl-q:setw synchronize-panes&lt;/p&gt;
&lt;p&gt;Play VideoPlayMuteCurrent Time 0:00/Duration Time 0:00Loaded: 0%Progress: 0%Stream TypeLIVERemaining Time -0:00 Playback Rate1Chapters* Chapters
Subtitles* subtitles off
Captions* captions off
FullscreenThis is a modal window.&lt;/p&gt;
&lt;p&gt;Foreground&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;White
Black
Red
Green
Blue
Yellow
Magenta
Cyan&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Opaque
Semi-Opaque&lt;/p&gt;
&lt;p&gt;Background&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;White
Black
Red
Green
Blue
Yellow
Magenta
Cyan&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Opaque
Semi-Transparent
Transparent&lt;/p&gt;
&lt;p&gt;Window&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;White
Black
Red
Green
Blue
Yellow
Magenta
Cyan&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;Opaque
Semi-Transparent
Transparent&lt;/p&gt;
&lt;p&gt;Font Size&lt;/p&gt;
&lt;p&gt;50%
75%
100%
125%
150%
175%
200%
300%
400%&lt;/p&gt;
&lt;p&gt;Text Edge Style&lt;/p&gt;
&lt;p&gt;None
Raised
Depressed
Uniform
Dropshadow&lt;/p&gt;
&lt;p&gt;Font Family&lt;/p&gt;
&lt;p&gt;Default
Monospace Serif
Proportional Serif
Monospace Sans-Serif
Proportional Sans-Serif
Casual
Script
Small Caps&lt;/p&gt;
&lt;p&gt;Defaults
Done&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://phaven-prod.s3.amazonaws.com/files/video_part/asset/892959/n5ve_2I_-G11PyAOfsyCBSXHfW4/tmux.avi&#34;&gt;Download tmux.avi&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This is immensely useful if you want to execute the same set of commands on multiple servers.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Tmux is an alternative for screen. For anyone who doesn&rsquo;t know screen, it is a terminal multiplexer which means, it allow multiple windows in terminal. It can split your window into multiple panes (vertical/horizontal), detach a session which can be attached at a later time. Detach/Attach is very useful for running a job in a remote server without having to keep the ssh open the whole time. </p>
<p>Tmux can be configured by  ~/<a href="https://github.com/amjith/_dotties/blob/master/tmux.conf">.tmux.conf</a> file.
My prefix key is Ctrl-q.
<strong>Synchronizing panes:</strong>
If you want to send your keystrokes to all the panes in your tmux window: 
<prefix> :setw synchronize-panes
In my case I do:
Ctrl-q:setw synchronize-panes</p>
<p>Play VideoPlayMuteCurrent Time 0:00/Duration Time 0:00Loaded: 0%Progress: 0%Stream TypeLIVERemaining Time -0:00 Playback Rate1Chapters* Chapters
Subtitles* subtitles off
Captions* captions off
FullscreenThis is a modal window.</p>
<p>Foreground</p>
<hr>
<p>White
Black
Red
Green
Blue
Yellow
Magenta
Cyan</p>
<hr>
<p>Opaque
Semi-Opaque</p>
<p>Background</p>
<hr>
<p>White
Black
Red
Green
Blue
Yellow
Magenta
Cyan</p>
<hr>
<p>Opaque
Semi-Transparent
Transparent</p>
<p>Window</p>
<hr>
<p>White
Black
Red
Green
Blue
Yellow
Magenta
Cyan</p>
<hr>
<p>Opaque
Semi-Transparent
Transparent</p>
<p>Font Size</p>
<p>50%
75%
100%
125%
150%
175%
200%
300%
400%</p>
<p>Text Edge Style</p>
<p>None
Raised
Depressed
Uniform
Dropshadow</p>
<p>Font Family</p>
<p>Default
Monospace Serif
Proportional Serif
Monospace Sans-Serif
Proportional Sans-Serif
Casual
Script
Small Caps</p>
<p>Defaults
Done</p>
<p><a href="https://phaven-prod.s3.amazonaws.com/files/video_part/asset/892959/n5ve_2I_-G11PyAOfsyCBSXHfW4/tmux.avi">Download tmux.avi</a></p>
<p>This is immensely useful if you want to execute the same set of commands on multiple servers.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Coffescript - A Better Way to JS</title>
      <link>https://amjith.com/blog/coffescript-a-better-way-to-js-tag-javascript/</link>
      <pubDate>Tue, 08 Mar 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/coffescript-a-better-way-to-js-tag-javascript/</guid>
      <description>&lt;p&gt;I went to attend the &lt;a href=&#34;http://utruby.org/&#34;&gt;URUG&lt;/a&gt; (Utah Ruby Users Group) meeting today because a little &lt;a href=&#34;http://twitter.com/#!/dbrady&#34;&gt;birdy&lt;/a&gt; said there will be some Javascript related presentations. &lt;/p&gt;
&lt;p&gt;I got to see an awesome presentation by &lt;a href=&#34;http://tadthorley.com&#34;&gt;Tad Thorley&lt;/a&gt; on &lt;a href=&#34;http://jashkenas.github.com/coffee-script/&#34;&gt;Coffeescript&lt;/a&gt;. It&amp;rsquo;s a minimalistic language that compiles to Javascript. Take a Javascript program and start removing unwanted literals from the syntax until you can&amp;rsquo;t remove anymore, that&amp;rsquo;s how a Coffeescript program looks like. &lt;/p&gt;
&lt;p&gt;Its the kind of minimalism that makes you appreciate the beauty of code. It combines the good parts of Python and Ruby syntax. There are some side-by-side &lt;a href=&#34;http://jashkenas.github.com/coffee-script/#literals&#34;&gt;comparisons&lt;/a&gt; of Coffeescript and Javascript code on the Coffeescript website.&lt;/p&gt;
&lt;p&gt;Tad might post his slides (which are just short snippets of code) on github and I&amp;rsquo;ll try to link it here.&lt;/p&gt;
&lt;p&gt;Update: Coffee Script Presentation - &lt;a href=&#34;https://github.com/phaedryx/coffeescript-presentation&#34;&gt;https://github.com/phaedryx/coffeescript-presentation&lt;/a&gt;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I went to attend the <a href="http://utruby.org/">URUG</a> (Utah Ruby Users Group) meeting today because a little <a href="http://twitter.com/#!/dbrady">birdy</a> said there will be some Javascript related presentations. </p>
<p>I got to see an awesome presentation by <a href="http://tadthorley.com">Tad Thorley</a> on <a href="http://jashkenas.github.com/coffee-script/">Coffeescript</a>. It&rsquo;s a minimalistic language that compiles to Javascript. Take a Javascript program and start removing unwanted literals from the syntax until you can&rsquo;t remove anymore, that&rsquo;s how a Coffeescript program looks like. </p>
<p>Its the kind of minimalism that makes you appreciate the beauty of code. It combines the good parts of Python and Ruby syntax. There are some side-by-side <a href="http://jashkenas.github.com/coffee-script/#literals">comparisons</a> of Coffeescript and Javascript code on the Coffeescript website.</p>
<p>Tad might post his slides (which are just short snippets of code) on github and I&rsquo;ll try to link it here.</p>
<p>Update: Coffee Script Presentation - <a href="https://github.com/phaedryx/coffeescript-presentation">https://github.com/phaedryx/coffeescript-presentation</a></p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Have a Schedule</title>
      <link>https://amjith.com/blog/have-a-schedule/</link>
      <pubDate>Wed, 02 Mar 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/have-a-schedule/</guid>
      <description>&lt;p&gt;After wasting about 3 hours watching old episodes of The Office, I had a sinking feeling last night that I&amp;rsquo;m not working towards any of my life goals. &lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Learn JS&lt;/li&gt;
&lt;li&gt;Release mobile apps&lt;/li&gt;
&lt;li&gt;Get better at Python&lt;/li&gt;
&lt;li&gt;Do a startup or at least join one&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;But thanks to my thoughtful wife, I didn&amp;rsquo;t freak out about it. She gave me some tangible ideas to remedy the situation (not one of those &amp;ldquo;You&amp;rsquo;ll be fine&amp;rdquo;). &lt;/p&gt;
&lt;p&gt;So new plan:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Set short-term goals.&lt;/li&gt;
&lt;li&gt;Work on my stuff and report the progress every week to my buddy &lt;a href=&#34;http://vijayd.posterous.com/&#34;&gt;Vijay&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;This should keep me accountable and on track. To actually show some progress, I&amp;rsquo;m going to fix my schedule and follow &lt;a href=&#34;http://lifehacker.com/#!281626/jerry-seinfelds-productivity-secret&#34;&gt;Seinfield&amp;rsquo;s Productivity Technique&lt;/a&gt;.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Tue (6-9)&lt;/li&gt;
&lt;li&gt;Wed (6-9) - bonus day&lt;/li&gt;
&lt;li&gt;Thu (6-9)&lt;/li&gt;
&lt;li&gt;Sat (5-9)&lt;/li&gt;
&lt;li&gt;Sun (1-5)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Phew! crisis averted. Now back to work.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>After wasting about 3 hours watching old episodes of The Office, I had a sinking feeling last night that I&rsquo;m not working towards any of my life goals. </p>
<ul>
<li>Learn JS</li>
<li>Release mobile apps</li>
<li>Get better at Python</li>
<li>Do a startup or at least join one</li>
</ul>
<p>But thanks to my thoughtful wife, I didn&rsquo;t freak out about it. She gave me some tangible ideas to remedy the situation (not one of those &ldquo;You&rsquo;ll be fine&rdquo;). </p>
<p>So new plan:</p>
<ul>
<li>Set short-term goals.</li>
<li>Work on my stuff and report the progress every week to my buddy <a href="http://vijayd.posterous.com/">Vijay</a>.</li>
</ul>
<p>This should keep me accountable and on track. To actually show some progress, I&rsquo;m going to fix my schedule and follow <a href="http://lifehacker.com/#!281626/jerry-seinfelds-productivity-secret">Seinfield&rsquo;s Productivity Technique</a>.</p>
<ul>
<li>Tue (6-9)</li>
<li>Wed (6-9) - bonus day</li>
<li>Thu (6-9)</li>
<li>Sat (5-9)</li>
<li>Sun (1-5)</li>
</ul>
<p>Phew! crisis averted. Now back to work.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Snowboarding @ Sundance</title>
      <link>https://amjith.com/blog/snowboarding-sundance/</link>
      <pubDate>Wed, 02 Mar 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/snowboarding-sundance/</guid>
      <description>&lt;p&gt;Just got back from Snowboarding at Sundance Ski resort. I fell down a lot less than I did during my previous times. I&amp;rsquo;m also doing a lot more toe turns which has always been an issue. I decided to try the blue slopes today which was good and bad. I got over my fear of going down the steep sections, but I also got too tired to enjoy the green sections of the run. I can tell that I&amp;rsquo;m getting a lot faster these days because the runs seem shorted (or quicker). One more season and I&amp;rsquo;ll be a pro :). &lt;/p&gt;
&lt;p&gt;After our snowboarding session, I had a near melt down. I couldn&amp;rsquo;t find my car keys in any of my jacket pockets and I don&amp;rsquo;t have a spare key for that car anywhere. I checked with the lost and found with no success and I requested the security to jack the car door for me. Right when they asked me to sign some release forms and were about to insert the lever into my car window, Yoshi comes out of no where (she decided to retire after a few runs) and declares that she has the keys. It was a photo-finish ending for a great day. &lt;/p&gt;
&lt;p&gt;I just love the fact that my wife can save the day no matter how much I manage to screw up.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Just got back from Snowboarding at Sundance Ski resort. I fell down a lot less than I did during my previous times. I&rsquo;m also doing a lot more toe turns which has always been an issue. I decided to try the blue slopes today which was good and bad. I got over my fear of going down the steep sections, but I also got too tired to enjoy the green sections of the run. I can tell that I&rsquo;m getting a lot faster these days because the runs seem shorted (or quicker). One more season and I&rsquo;ll be a pro :). </p>
<p>After our snowboarding session, I had a near melt down. I couldn&rsquo;t find my car keys in any of my jacket pockets and I don&rsquo;t have a spare key for that car anywhere. I checked with the lost and found with no success and I requested the security to jack the car door for me. Right when they asked me to sign some release forms and were about to insert the lever into my car window, Yoshi comes out of no where (she decided to retire after a few runs) and declares that she has the keys. It was a photo-finish ending for a great day. </p>
<p>I just love the fact that my wife can save the day no matter how much I manage to screw up.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Leaders are genuine</title>
      <link>https://amjith.com/blog/leaders-inspire/</link>
      <pubDate>Tue, 01 Mar 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/leaders-inspire/</guid>
      <description>&lt;p&gt;I had a chance to watch one of my role models in action today. He is one of the young, intelligent managers who rose to the top of the ladder pretty quickly. He managed to do that without creating enemies along the way which is pretty hard to do in big corporations. Everyone who has worked with him will attest to the fact that he deserves to be in the top and has nothing bad to say about him. &lt;/p&gt;
&lt;p&gt;Unfortunately I never got a chance to work directly with him, but watching him today made me realize why he is different from the other managers. It all came down to being truthful. Just being genuine to your fellow workers can mean a world of difference. When he tries to inspire someone, he is not the one to throw around some business lingo. He doesn&amp;rsquo;t just say &amp;ldquo;We really appreciate all the work you are doing&amp;rdquo; or &amp;ldquo;Keep up the good work&amp;rdquo;. That is just a terrible compliment. When he praises you for something, you know he really appreciates your work.&lt;/p&gt;
&lt;p&gt;One lesson I learned from him today is &amp;ldquo;Be Genuine&amp;rdquo;, and I shall try.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I had a chance to watch one of my role models in action today. He is one of the young, intelligent managers who rose to the top of the ladder pretty quickly. He managed to do that without creating enemies along the way which is pretty hard to do in big corporations. Everyone who has worked with him will attest to the fact that he deserves to be in the top and has nothing bad to say about him. </p>
<p>Unfortunately I never got a chance to work directly with him, but watching him today made me realize why he is different from the other managers. It all came down to being truthful. Just being genuine to your fellow workers can mean a world of difference. When he tries to inspire someone, he is not the one to throw around some business lingo. He doesn&rsquo;t just say &ldquo;We really appreciate all the work you are doing&rdquo; or &ldquo;Keep up the good work&rdquo;. That is just a terrible compliment. When he praises you for something, you know he really appreciates your work.</p>
<p>One lesson I learned from him today is &ldquo;Be Genuine&rdquo;, and I shall try.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Education from unlikely sources</title>
      <link>https://amjith.com/blog/education-from-unlikely-sources/</link>
      <pubDate>Mon, 28 Feb 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/education-from-unlikely-sources/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve never understood the meaning of the term &amp;ldquo;Pearls before Swine&amp;rdquo; and never bothered to look it up (laziness mostly). I&amp;rsquo;ve chalked it up as an unfunny comics strip that is obscure. But today I read a blog post by Linus (yes, the creator of Linux) about his experiences at a &lt;a href=&#34;http://torvalds-family.blogspot.com/&#34;&gt;Night before Oscar Party&lt;/a&gt;. It is hilarious, you should go read it, NOW. The title of the blog was &amp;ldquo;Pearls before Swine&amp;rdquo;. This time I decided to look up the meaning of that term and I don&amp;rsquo;t regret doing so. I think it&amp;rsquo;ll come in quite handy in the future. :) Pearls before Swine (from &lt;a href=&#34;http://en.wikipedia.org/wiki/Pearls_Before_Swine&#34;&gt;Wikipedia&lt;/a&gt;): &lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;things (such as pearls) should not be put in front of people (or in this case, swine) who do not appreciate their value&lt;/p&gt;
&lt;/blockquote&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;ve never understood the meaning of the term &ldquo;Pearls before Swine&rdquo; and never bothered to look it up (laziness mostly). I&rsquo;ve chalked it up as an unfunny comics strip that is obscure. But today I read a blog post by Linus (yes, the creator of Linux) about his experiences at a <a href="http://torvalds-family.blogspot.com/">Night before Oscar Party</a>. It is hilarious, you should go read it, NOW. The title of the blog was &ldquo;Pearls before Swine&rdquo;. This time I decided to look up the meaning of that term and I don&rsquo;t regret doing so. I think it&rsquo;ll come in quite handy in the future. :) Pearls before Swine (from <a href="http://en.wikipedia.org/wiki/Pearls_Before_Swine">Wikipedia</a>): </p>
<blockquote>
<p>things (such as pearls) should not be put in front of people (or in this case, swine) who do not appreciate their value</p>
</blockquote>
]]></content:encoded>
    </item>
    
    <item>
      <title>Why do I hate Gnome?</title>
      <link>https://amjith.com/blog/why-do-i-hate-gnome/</link>
      <pubDate>Mon, 28 Feb 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/why-do-i-hate-gnome/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve been using Ubuntu Linux on my netbook for the past couple of days and I&amp;rsquo;m quite pleased with the whole experience, except for the initial &lt;a href=&#34;https://amjith.com/ubuntu-and-i-have-some-trust-issues-tag-ubunt&#34;&gt;issues&lt;/a&gt; (I just won&amp;rsquo;t trust the auto-update).Ubuntu uses the Gnome desktop environment by default with a little bit of tweaking. Gnome UI designers have a sense of aesthetic cognizance to their designs. I&amp;rsquo;ve always appreciated the crisp icons and the polished dialogs. I&amp;rsquo;ve been known to throw around the word stunning, quite generously, while describing Gnome.  All these initial infatuations almost made me forget the reasons why I abandoned Gnome a few years ago. I  hate the absence of a central control center to tweak the default behavior of Gnome. There is however a severely handicapped version called gconf-editor which is like a terrible cousin of Windows Registry. So now if you want sloppy focus on gnome that doesn&amp;rsquo;t raise your window when you click on it, you just have to do the following simple steps: 1. Open gconf-editor
2. apps
3. metacity
4. general
5. raise on click (uncheck)
Quite intuitive wouldn&amp;rsquo;t you agree? Oh you want to enable compositing, so your gnome-do can have some slick skins, here&amp;rsquo;s how you achieve that:  1. Open gconf-editor
2. apps
3. metacity
4. general
5. compositing_manager (check)
Why? Why would you think this is more intuitive than having a simple GUI driven control center? I&amp;rsquo;m told this was a conscious choice by Gnome developers because giving choices tend to confuse their users.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;If you think your users are idiots, only idiots will use it.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;No wonder &lt;a href=&#34;http://www.desktoplinux.com/news/NS8745257437.html&#34;&gt;Linus was pissed&lt;/a&gt; at Gnome and started recommending KDE.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;ve been using Ubuntu Linux on my netbook for the past couple of days and I&rsquo;m quite pleased with the whole experience, except for the initial <a href="/ubuntu-and-i-have-some-trust-issues-tag-ubunt">issues</a> (I just won&rsquo;t trust the auto-update).Ubuntu uses the Gnome desktop environment by default with a little bit of tweaking. Gnome UI designers have a sense of aesthetic cognizance to their designs. I&rsquo;ve always appreciated the crisp icons and the polished dialogs. I&rsquo;ve been known to throw around the word stunning, quite generously, while describing Gnome.  All these initial infatuations almost made me forget the reasons why I abandoned Gnome a few years ago. I  hate the absence of a central control center to tweak the default behavior of Gnome. There is however a severely handicapped version called gconf-editor which is like a terrible cousin of Windows Registry. So now if you want sloppy focus on gnome that doesn&rsquo;t raise your window when you click on it, you just have to do the following simple steps: 1. Open gconf-editor
2. apps
3. metacity
4. general
5. raise on click (uncheck)
Quite intuitive wouldn&rsquo;t you agree? Oh you want to enable compositing, so your gnome-do can have some slick skins, here&rsquo;s how you achieve that:  1. Open gconf-editor
2. apps
3. metacity
4. general
5. compositing_manager (check)
Why? Why would you think this is more intuitive than having a simple GUI driven control center? I&rsquo;m told this was a conscious choice by Gnome developers because giving choices tend to confuse their users.</p>
<blockquote>
<p>If you think your users are idiots, only idiots will use it.</p>
</blockquote>
<p>No wonder <a href="http://www.desktoplinux.com/news/NS8745257437.html">Linus was pissed</a> at Gnome and started recommending KDE.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Ubuntu and I have some trust issues</title>
      <link>https://amjith.com/blog/ubuntu-and-i-have-some-trust-issues-tag-ubunt/</link>
      <pubDate>Sun, 20 Feb 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/ubuntu-and-i-have-some-trust-issues-tag-ubunt/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve been exclusively using Meego on my netbook and I was moderately happy with what it provided. So I did what any self-respecting hacker would do - I tried to make it better. Well, we all know how &lt;strong&gt;that&lt;/strong&gt; usually ends. I managed to uninstall every single kernel in the system and rendered the system unbootable. Taking this as an opportunity I decided to try a grown-up OS. Enter Ubuntu into the picture.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve heard nothing but great things about Ubuntu and I fuckin&#39; hated it. Why? Because it was stealing all the limelight from the ever superior Mandriva (my favorite distro). So I got the installation process going which was smooth but surprisingly it didn&amp;rsquo;t give me the option to keep my old partition, it was an all or nothing approach (grown up OS my ass). I had all my &amp;ldquo;stuff&amp;rdquo; backed up, so I decided to repartition my disk. It even detected my Broadcom wireless card and offered to install a proprietary driver for it. Wireless was working and the visual candy was stunning. I&amp;rsquo;ve never seen such a beautiful font set on my computer before. All the visual components looked hand crafted and the notifications were done with style. It was just a gorgeous piece of artwork. Visually stunning (if you didn&amp;rsquo;t get that part already). &lt;/p&gt;
&lt;p&gt;I was quite pleased with the decision to go with Ubuntu and was having some fleeting thoughts about replacing Mandriva on my desktop. Around 15 minutes in my playful prodding and poking, I was notified that Software Updates were available. After it successfully installed the updates and rebooted the computer (some Kernel updates were involved), I couldn&amp;rsquo;t connect to the internet anymore. The network icon wouldn&amp;rsquo;t show up on my system tray anymore. After some googling I managed to find the &amp;ldquo;Additional Drivers&amp;rdquo; program which installed the Broadcom Drivers once again. But this time it would show me the available networks but wouldn&amp;rsquo;t connect to any of them. The system update had successfully screwed over the authentication routine for connecting to WPA2 networks. I tried to plug in my network cable to the ethernet port only to find out the system hadn&amp;rsquo;t recognized the existence of an ethernet port. Are you kidding me? Have you heard of a little thing called hot-plugging? I&amp;rsquo;ve been spoiled by Mandriva that can automatically choose between the wireless card and the network cable on the fly, depending on which was available. Now I had to muck around the network interface files to even get my ethernet card detected. How hard is it to develop a Central Control Center that can manage your hardware? After getting that to work, I tried at least 10 different methods described on various forums to get the wireless chipset to work again without any success. I gave up after 10 hours of tweaking and started trying other OSes. Here is a list:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Fedora looked nice but wouldn&amp;rsquo;t connect to internet. Same problem as Ubuntu, but this time, it wouldn&amp;rsquo;t offer to download proprietary drivers.&lt;/li&gt;
&lt;li&gt;Mandriva image hangs up in the middle of booting (I&amp;rsquo;m personally embarrassed by this). Btw, Mandriva has to be the ugliest of all the OSes. Seriously man, you gotta up the ante a little bit if you want to stay in this game.&lt;/li&gt;
&lt;li&gt;Mint OS same as Ubuntu, only it looked even more gorgeous. I might try this out in the future.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I should&amp;rsquo;ve tried Arch Linux but I was too tired at this point. So I did what any self-respecting hacker would do&amp;hellip;.. I re-installed Ubuntu and rejected the offer to auto-update my system. Now I have wireless internet and a usable desktop that looks pretty.&lt;/p&gt;
&lt;p&gt;Ubuntu had so much potential. I will always remember today as the day I almost replaced my desktop Mandriva with Ubuntu. Maybe next time.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;ve been exclusively using Meego on my netbook and I was moderately happy with what it provided. So I did what any self-respecting hacker would do - I tried to make it better. Well, we all know how <strong>that</strong> usually ends. I managed to uninstall every single kernel in the system and rendered the system unbootable. Taking this as an opportunity I decided to try a grown-up OS. Enter Ubuntu into the picture.</p>
<p>I&rsquo;ve heard nothing but great things about Ubuntu and I fuckin' hated it. Why? Because it was stealing all the limelight from the ever superior Mandriva (my favorite distro). So I got the installation process going which was smooth but surprisingly it didn&rsquo;t give me the option to keep my old partition, it was an all or nothing approach (grown up OS my ass). I had all my &ldquo;stuff&rdquo; backed up, so I decided to repartition my disk. It even detected my Broadcom wireless card and offered to install a proprietary driver for it. Wireless was working and the visual candy was stunning. I&rsquo;ve never seen such a beautiful font set on my computer before. All the visual components looked hand crafted and the notifications were done with style. It was just a gorgeous piece of artwork. Visually stunning (if you didn&rsquo;t get that part already). </p>
<p>I was quite pleased with the decision to go with Ubuntu and was having some fleeting thoughts about replacing Mandriva on my desktop. Around 15 minutes in my playful prodding and poking, I was notified that Software Updates were available. After it successfully installed the updates and rebooted the computer (some Kernel updates were involved), I couldn&rsquo;t connect to the internet anymore. The network icon wouldn&rsquo;t show up on my system tray anymore. After some googling I managed to find the &ldquo;Additional Drivers&rdquo; program which installed the Broadcom Drivers once again. But this time it would show me the available networks but wouldn&rsquo;t connect to any of them. The system update had successfully screwed over the authentication routine for connecting to WPA2 networks. I tried to plug in my network cable to the ethernet port only to find out the system hadn&rsquo;t recognized the existence of an ethernet port. Are you kidding me? Have you heard of a little thing called hot-plugging? I&rsquo;ve been spoiled by Mandriva that can automatically choose between the wireless card and the network cable on the fly, depending on which was available. Now I had to muck around the network interface files to even get my ethernet card detected. How hard is it to develop a Central Control Center that can manage your hardware? After getting that to work, I tried at least 10 different methods described on various forums to get the wireless chipset to work again without any success. I gave up after 10 hours of tweaking and started trying other OSes. Here is a list:</p>
<ul>
<li>Fedora looked nice but wouldn&rsquo;t connect to internet. Same problem as Ubuntu, but this time, it wouldn&rsquo;t offer to download proprietary drivers.</li>
<li>Mandriva image hangs up in the middle of booting (I&rsquo;m personally embarrassed by this). Btw, Mandriva has to be the ugliest of all the OSes. Seriously man, you gotta up the ante a little bit if you want to stay in this game.</li>
<li>Mint OS same as Ubuntu, only it looked even more gorgeous. I might try this out in the future.</li>
</ul>
<p>I should&rsquo;ve tried Arch Linux but I was too tired at this point. So I did what any self-respecting hacker would do&hellip;.. I re-installed Ubuntu and rejected the offer to auto-update my system. Now I have wireless internet and a usable desktop that looks pretty.</p>
<p>Ubuntu had so much potential. I will always remember today as the day I almost replaced my desktop Mandriva with Ubuntu. Maybe next time.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Five hours of Aikido and Javascript</title>
      <link>https://amjith.com/blog/five-hours-of-aikido-and-javascript/</link>
      <pubDate>Sat, 12 Feb 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/five-hours-of-aikido-and-javascript/</guid>
      <description>&lt;p&gt;It was a good day for Aikido. We started at 10am and went till 4pm with an hour break. My joints are sore but my mind is exuberant. I actually managed to get more than 2 hours of Javascript learning after that. I&amp;rsquo;m quite impressed by the features of Javascript. Passing a function to another function as a parameter, returning a function, a function inside a function, anonymous functions (lambdas), wow, its a surprisingly powerful language for doing web development. I haven&amp;rsquo;t even reached the section about closures yet.  I&amp;rsquo;m a little blown away by Javascript.  &lt;a href=&#34;http://jqfundamentals.com/book/&#34;&gt;http://jqfundamentals.com/book/&lt;/a&gt;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>It was a good day for Aikido. We started at 10am and went till 4pm with an hour break. My joints are sore but my mind is exuberant. I actually managed to get more than 2 hours of Javascript learning after that. I&rsquo;m quite impressed by the features of Javascript. Passing a function to another function as a parameter, returning a function, a function inside a function, anonymous functions (lambdas), wow, its a surprisingly powerful language for doing web development. I haven&rsquo;t even reached the section about closures yet.  I&rsquo;m a little blown away by Javascript.  <a href="http://jqfundamentals.com/book/">http://jqfundamentals.com/book/</a></p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Hiatus from Hapkido</title>
      <link>https://amjith.com/blog/hiatus-from-hapkido/</link>
      <pubDate>Wed, 09 Feb 2011 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/hiatus-from-hapkido/</guid>
      <description>&lt;p&gt;After realizing that I only have 2 days per week (and weekends) to work on my side projects, I decided to axe one of my hobbies. Unfortunately Hapkido got kicked out (no pun intended) of my schedule. Sad day. I really enjoyed Hapkido and I hope I can get back to it once things settle down a little bit.&lt;/p&gt;
&lt;p&gt;So what am I going to do on these free Wednesday nights? I have a few ideas:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Snowboarding&lt;/li&gt;
&lt;li&gt;Learn Javascript&lt;/li&gt;
&lt;li&gt;Learn Titanium and port &lt;a href=&#34;http://code.google.com/p/ptimer/&#34;&gt;pTimer&lt;/a&gt; to Android and iOS.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Lets see how this turns out. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>After realizing that I only have 2 days per week (and weekends) to work on my side projects, I decided to axe one of my hobbies. Unfortunately Hapkido got kicked out (no pun intended) of my schedule. Sad day. I really enjoyed Hapkido and I hope I can get back to it once things settle down a little bit.</p>
<p>So what am I going to do on these free Wednesday nights? I have a few ideas:</p>
<ul>
<li>Snowboarding</li>
<li>Learn Javascript</li>
<li>Learn Titanium and port <a href="http://code.google.com/p/ptimer/">pTimer</a> to Android and iOS.</li>
</ul>
<p>Lets see how this turns out. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Night Snowboarding @ Sundance</title>
      <link>https://amjith.com/blog/night-snowboarding-sundance/</link>
      <pubDate>Sun, 26 Dec 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/night-snowboarding-sundance/</guid>
      <description>&lt;p&gt;We went snowboarding for the first time this season. This is the first time I&amp;rsquo;ve hit the slopes after 5pm. It wasn&amp;rsquo;t bad at all, the lifts were empty and the slopes were free.  Too bad I don&amp;rsquo;t know how to snowboard well enough, because I kept falling on my bum. Yoshi hasn&amp;rsquo;t figured out if she is regular footed or goofy footed and she kept trying both, hope she hasn&amp;rsquo;t confused her brain beyond repair. &lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m excited to go again soon. Maybe this time I&amp;rsquo;ll get those damn toe turn to work without destroying my bum.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We went snowboarding for the first time this season. This is the first time I&rsquo;ve hit the slopes after 5pm. It wasn&rsquo;t bad at all, the lifts were empty and the slopes were free.  Too bad I don&rsquo;t know how to snowboard well enough, because I kept falling on my bum. Yoshi hasn&rsquo;t figured out if she is regular footed or goofy footed and she kept trying both, hope she hasn&rsquo;t confused her brain beyond repair. </p>
<p>I&rsquo;m excited to go again soon. Maybe this time I&rsquo;ll get those damn toe turn to work without destroying my bum.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>LaTeX on Mac OS X</title>
      <link>https://amjith.com/blog/latex-on-mac-os-x/</link>
      <pubDate>Sun, 19 Dec 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/latex-on-mac-os-x/</guid>
      <description>&lt;p&gt;I used LaTeX when I was in school to create reports, presentation (using &lt;a href=&#34;http://en.wikipedia.org/wiki/Beamer_(LaTeX)&#34;&gt;beamer&lt;/a&gt;) and even sometimes class notes and assignments. Recently when I was looking for a presentation program in Linux I was crestfallen by the lack of polish in OpenOffice Impress. So I created my &lt;a href=&#34;https://amjith.com/hands-on-into-git&#34;&gt;presentation&lt;/a&gt; for the Salt Lake Linux User Group in LaTeX and it looked professional (nothing surprising there).&lt;/p&gt;
&lt;p&gt;But that was created on my tiny Netbook running Meego. I wanted to make some edits to it with my wife&amp;rsquo;s MacBook, so I started looking around for LaTeX on Mac. I found &lt;a href=&#34;http://www.tug.org/mactex/&#34;&gt;MacTex&lt;/a&gt; which completely took me by surprise, because the download size of the MacTex package was 1.6GB and the installed size on the computer was well over 3GB. It took me a good one hour to download, install and configure that thing. Seeing the 1.6GB zip file getting downloaded made me realize how much work has gone into LaTeX which I&amp;rsquo;ve always taken for granted.&lt;/p&gt;
&lt;p&gt;I bow before thee LaTeX. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I used LaTeX when I was in school to create reports, presentation (using <a href="http://en.wikipedia.org/wiki/Beamer_(LaTeX)">beamer</a>) and even sometimes class notes and assignments. Recently when I was looking for a presentation program in Linux I was crestfallen by the lack of polish in OpenOffice Impress. So I created my <a href="/hands-on-into-git">presentation</a> for the Salt Lake Linux User Group in LaTeX and it looked professional (nothing surprising there).</p>
<p>But that was created on my tiny Netbook running Meego. I wanted to make some edits to it with my wife&rsquo;s MacBook, so I started looking around for LaTeX on Mac. I found <a href="http://www.tug.org/mactex/">MacTex</a> which completely took me by surprise, because the download size of the MacTex package was 1.6GB and the installed size on the computer was well over 3GB. It took me a good one hour to download, install and configure that thing. Seeing the 1.6GB zip file getting downloaded made me realize how much work has gone into LaTeX which I&rsquo;ve always taken for granted.</p>
<p>I bow before thee LaTeX. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Happiness .....</title>
      <link>https://amjith.com/blog/happiness/</link>
      <pubDate>Sat, 18 Dec 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/happiness/</guid>
      <description>&lt;p&gt;My wife and I were in Burlington coat factory today and she finally found a pair of gloves that fits her stringent requirements. Her joy knew no bounds. I&amp;rsquo;ve never seen anyone so truly happy. She has been wearing them since we got out of the store and haven&amp;rsquo;t taken them off. Its been more than 4 hours.&lt;/p&gt;
&lt;p&gt;Reminds me of the time, I got my first &lt;a href=&#34;http://en.wikipedia.org/wiki/Bokken&#34;&gt;bokken&lt;/a&gt; and carried it around everywhere. It was with me at all times, I had it while I was eating, playing, computering, walking around aimlessly etc.  I even remember the threats she made if I brought the bokken with me to the bed and how I promptly ignored her and paid the price. Good times&amp;hellip;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>My wife and I were in Burlington coat factory today and she finally found a pair of gloves that fits her stringent requirements. Her joy knew no bounds. I&rsquo;ve never seen anyone so truly happy. She has been wearing them since we got out of the store and haven&rsquo;t taken them off. Its been more than 4 hours.</p>
<p>Reminds me of the time, I got my first <a href="http://en.wikipedia.org/wiki/Bokken">bokken</a> and carried it around everywhere. It was with me at all times, I had it while I was eating, playing, computering, walking around aimlessly etc.  I even remember the threats she made if I brought the bokken with me to the bed and how I promptly ignored her and paid the price. Good times&hellip;</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Shopping for India Trip</title>
      <link>https://amjith.com/blog/shopping-for-india-trip/</link>
      <pubDate>Sat, 18 Dec 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/shopping-for-india-trip/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m getting ready for the India Trip in January and it is one hectic process. I&amp;rsquo;m getting all these gifts for my parents, brothers, cousins, uncles and the list keeps on growing. Perils of having a large loving family. One of these days, I&amp;rsquo;m going to make enough money to get all of them the gifts that I really want to give. One of these days&amp;hellip;.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I&rsquo;m getting ready for the India Trip in January and it is one hectic process. I&rsquo;m getting all these gifts for my parents, brothers, cousins, uncles and the list keeps on growing. Perils of having a large loving family. One of these days, I&rsquo;m going to make enough money to get all of them the gifts that I really want to give. One of these days&hellip;.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Hands on Intro - Git</title>
      <link>https://amjith.com/blog/hands-on-into-git/</link>
      <pubDate>Wed, 08 Dec 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/hands-on-into-git/</guid>
      <description>&lt;p&gt;Today I presented in the Salt Lake Linux User Group meeting. The topic was &amp;ldquo;Hands on Intro - Git&amp;rdquo;. It went well and I actually enjoyed it quite a bit. I choked twice once while trying to explain how to git apply patches that you receive via email, but then recovered from it with some help from the audience. But the second time I choked while trying to explain how to pull from multiple remote repositories, I couldn&amp;rsquo;t recover from that. I do that so rarely it never occurred to me. Oh well, the first time is the hardest.&lt;/p&gt;
&lt;p&gt; 
Off to prepare for the talk tomorrow at the Utah Python Group. I&amp;rsquo;m presenting &amp;ldquo;Hands on Into - PyQt4&amp;rdquo;. 
 
Here are the slides from that talk. LaTeX Source: &lt;a href=&#34;https://github.com/amjith/git_present&#34;&gt;https://github.com/amjith/git_present&lt;/a&gt; 
 &lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://phaven-prod.s3.amazonaws.com/files/document_part/asset/892928/KzUB0C9SlbggTKknuietZWgaso8/git_present.pdf&#34;&gt;Download git_present.pdf&lt;/a&gt;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Today I presented in the Salt Lake Linux User Group meeting. The topic was &ldquo;Hands on Intro - Git&rdquo;. It went well and I actually enjoyed it quite a bit. I choked twice once while trying to explain how to git apply patches that you receive via email, but then recovered from it with some help from the audience. But the second time I choked while trying to explain how to pull from multiple remote repositories, I couldn&rsquo;t recover from that. I do that so rarely it never occurred to me. Oh well, the first time is the hardest.</p>
<p> 
Off to prepare for the talk tomorrow at the Utah Python Group. I&rsquo;m presenting &ldquo;Hands on Into - PyQt4&rdquo;. 
 
Here are the slides from that talk. LaTeX Source: <a href="https://github.com/amjith/git_present">https://github.com/amjith/git_present</a> 
 </p>
<p><a href="https://phaven-prod.s3.amazonaws.com/files/document_part/asset/892928/KzUB0C9SlbggTKknuietZWgaso8/git_present.pdf">Download git_present.pdf</a></p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Exhausted</title>
      <link>https://amjith.com/blog/exhausted/</link>
      <pubDate>Wed, 01 Dec 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/exhausted/</guid>
      <description>&lt;p&gt;My body is aching from Hapkido. My head hurts from the constant context-switching. My brain is tired from the messy debugging I had to do at work. But life must go on. 
I have to prepare two different presentations for next week. A Git presentation for the Linux User Group and a PyQt4 presentation for the UtahPython Group. I think I can manage it. &lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;But I have promises to keep,&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;And miles to go before I sleep. &lt;/p&gt;
&lt;/blockquote&gt;
</description>
      <content:encoded><![CDATA[<p>My body is aching from Hapkido. My head hurts from the constant context-switching. My brain is tired from the messy debugging I had to do at work. But life must go on. 
I have to prepare two different presentations for next week. A Git presentation for the Linux User Group and a PyQt4 presentation for the UtahPython Group. I think I can manage it. </p>
<blockquote>
<p>But I have promises to keep,</p>
</blockquote>
<blockquote>
<p>And miles to go before I sleep. </p>
</blockquote>
]]></content:encoded>
    </item>
    
    <item>
      <title>Back from Thanksgiving</title>
      <link>https://amjith.com/blog/back-from-thanksgiving/</link>
      <pubDate>Mon, 29 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/back-from-thanksgiving/</guid>
      <description>&lt;p&gt;We went to Bryce and Zions for Thanksgiving weekend. It was beautiful and freezing. I think at one time, the car thermometer read 2 degrees Fahrenheit. But we had a lot of fun. I found out that I&amp;rsquo;m really good at pictionary, well not at winning but making people break into paroxysms of laughter.Well everyone has a different talent. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>We went to Bryce and Zions for Thanksgiving weekend. It was beautiful and freezing. I think at one time, the car thermometer read 2 degrees Fahrenheit. But we had a lot of fun. I found out that I&rsquo;m really good at pictionary, well not at winning but making people break into paroxysms of laughter.Well everyone has a different talent. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Much ado about nothing</title>
      <link>https://amjith.com/blog/much-ado-about-nothing/</link>
      <pubDate>Wed, 24 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/much-ado-about-nothing/</guid>
      <description>&lt;p&gt;Some of the news papers claimed this is the worst blizzard in Utah since 2001. My work sent all of us home earlier than usual. My friend advised me to stock up some food, in case I&amp;rsquo;m stuck in the house without emergency supply. I was pretty &lt;a href=&#34;https://amjith.com/i-love-snow-storm&#34;&gt;excited&lt;/a&gt; with anticipation, got some tea and curled up in front of the computer. I was all ready to witness a downpour that was going to rival  the &amp;ldquo;&lt;a href=&#34;http://www.imdb.com/title/tt0319262/&#34;&gt;Day after tomorrow&lt;/a&gt;&amp;quot;.  What followed was a snow fizzle that didn&amp;rsquo;t even leave a trace on my car this morning. Anti-climatic of epic proportions, which was in the order of Apple announcing&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892929/dEECzav6PnTIGvkShZd7p21fwxA/large_Apple-iTunes-Exciting-Announce.png&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Some of the news papers claimed this is the worst blizzard in Utah since 2001. My work sent all of us home earlier than usual. My friend advised me to stock up some food, in case I&rsquo;m stuck in the house without emergency supply. I was pretty <a href="/i-love-snow-storm">excited</a> with anticipation, got some tea and curled up in front of the computer. I was all ready to witness a downpour that was going to rival  the &ldquo;<a href="http://www.imdb.com/title/tt0319262/">Day after tomorrow</a>&quot;.  What followed was a snow fizzle that didn&rsquo;t even leave a trace on my car this morning. Anti-climatic of epic proportions, which was in the order of Apple announcing</p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892929/dEECzav6PnTIGvkShZd7p21fwxA/large_Apple-iTunes-Exciting-Announce.png" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>I love snow storm</title>
      <link>https://amjith.com/blog/i-love-snow-storm/</link>
      <pubDate>Tue, 23 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/i-love-snow-storm/</guid>
      <description>&lt;p&gt;My work let us leave an hour early in the anticipation of the most intense blizzard (aka snowmegeddon) this afternoon. It just feels good to be home at 4:15, ( I just realized how sad that sounds). There&amp;rsquo;s something about watching the falling snow with a cup of hot beverage that is unmatched.  Hopefully it doesn&amp;rsquo;t pour down on us when we are in Bryce or Zion in a couple of days. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>My work let us leave an hour early in the anticipation of the most intense blizzard (aka snowmegeddon) this afternoon. It just feels good to be home at 4:15, ( I just realized how sad that sounds). There&rsquo;s something about watching the falling snow with a cup of hot beverage that is unmatched.  Hopefully it doesn&rsquo;t pour down on us when we are in Bryce or Zion in a couple of days. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Grown Up...</title>
      <link>https://amjith.com/blog/grown-up/</link>
      <pubDate>Fri, 19 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/grown-up/</guid>
      <description>&lt;p&gt;There is an interesting thread on reddit titled: &amp;ldquo;&lt;a href=&#34;http://www.reddit.com/comments/e81dk/when_did_you_realise_that_you_were_an_adult/&#34;&gt;When did you realize that you were an adult&lt;/a&gt;&amp;rdquo;. I still feel that I haven&amp;rsquo;t quite reached that realization yet. I&amp;rsquo;ve come close though. &lt;/p&gt;
&lt;p&gt;During 2nd year into my master&amp;rsquo;s, I was guiding a tour of the University&amp;rsquo;s Robotics lab for middle school kids. After wowing them with some cool robots, I let them play with some of them. One of the little girls came up to me and asked shyly &lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Sir, Can I shake your hand?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I was blown away by the question. I said &amp;ldquo;Of course&amp;rdquo; and shook her hand. She seemed impressed with herself and walked away, making me realize some of these kids actually think I&amp;rsquo;m a scientist.  &lt;/p&gt;
&lt;p&gt;I &lt;em&gt;still&lt;/em&gt; feel this way: &lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://xkcd.com/616/&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;http://imgs.xkcd.com/comics/lease.png&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve successfully postponed any purchase that could make me feel like an adult, a TV, Couch, House. &lt;/p&gt;
&lt;p&gt;It&amp;rsquo;s only a matter of time.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>There is an interesting thread on reddit titled: &ldquo;<a href="http://www.reddit.com/comments/e81dk/when_did_you_realise_that_you_were_an_adult/">When did you realize that you were an adult</a>&rdquo;. I still feel that I haven&rsquo;t quite reached that realization yet. I&rsquo;ve come close though. </p>
<p>During 2nd year into my master&rsquo;s, I was guiding a tour of the University&rsquo;s Robotics lab for middle school kids. After wowing them with some cool robots, I let them play with some of them. One of the little girls came up to me and asked shyly </p>
<blockquote>
<p>Sir, Can I shake your hand?</p>
</blockquote>
<p>I was blown away by the question. I said &ldquo;Of course&rdquo; and shook her hand. She seemed impressed with herself and walked away, making me realize some of these kids actually think I&rsquo;m a scientist.  </p>
<p>I <em>still</em> feel this way: </p>
<p><a href="http://xkcd.com/616/"><img loading="lazy" src="http://imgs.xkcd.com/comics/lease.png" alt=""  />
</a></p>
<p>I&rsquo;ve successfully postponed any purchase that could make me feel like an adult, a TV, Couch, House. </p>
<p>It&rsquo;s only a matter of time.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Is it just me....</title>
      <link>https://amjith.com/blog/is-it-just-me/</link>
      <pubDate>Tue, 16 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/is-it-just-me/</guid>
      <description>&lt;p&gt;&amp;hellip; or do most men have trouble keeping track of their wife&amp;rsquo;s conversation.She started saying something that probably sounds exciting in her head, because I completely failed to see the cause of excitement. The story took 4 different related jumps and I lost track of the thread. Of course, I had to voice my thoughts:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Honey, do you realize you are all over the place? I have no idea why you are telling me this. &lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;She actually let that one slide, I bet she likes me quite a bit.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>&hellip; or do most men have trouble keeping track of their wife&rsquo;s conversation.She started saying something that probably sounds exciting in her head, because I completely failed to see the cause of excitement. The story took 4 different related jumps and I lost track of the thread. Of course, I had to voice my thoughts:</p>
<blockquote>
<p>Honey, do you realize you are all over the place? I have no idea why you are telling me this. </p>
</blockquote>
<p>She actually let that one slide, I bet she likes me quite a bit.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>I hate meetings</title>
      <link>https://amjith.com/blog/i-hate-meetings/</link>
      <pubDate>Mon, 15 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/i-hate-meetings/</guid>
      <description>&lt;p&gt;I hate them with a passion. When I see people sitting there trying to formulate sentences for no apparent reason but just to fill the void of silence, it just boils my blood. &lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892931/nUGjeh3bsA4VTN_1XIhop3p4T-Q/large_talked_to_death.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;p&gt;I was reading an article titled &amp;ldquo;&lt;a href=&#34;http://scobleizer.com/2010/11/12/why-google-cant-build-instagram/&#34;&gt;Why Google can’t build Instagram&lt;/a&gt;&amp;rdquo; and I came across this quote&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;how Larry Ellison actually got efficiencies from teams. If a team wasn’t productive, he’d come every couple of weeks and say “let me help you out.” What did he do? He took away another person until the team started shipping and stopped having unproductive meetings.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I&amp;rsquo;m no fan of Larry, but the man&amp;rsquo;s right. I would much rather work in a small team that meets for a purpose. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I hate them with a passion. When I see people sitting there trying to formulate sentences for no apparent reason but just to fill the void of silence, it just boils my blood. </p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892931/nUGjeh3bsA4VTN_1XIhop3p4T-Q/large_talked_to_death.jpg" alt=""  />
</p>
<p>I was reading an article titled &ldquo;<a href="http://scobleizer.com/2010/11/12/why-google-cant-build-instagram/">Why Google can’t build Instagram</a>&rdquo; and I came across this quote</p>
<blockquote>
<p>how Larry Ellison actually got efficiencies from teams. If a team wasn’t productive, he’d come every couple of weeks and say “let me help you out.” What did he do? He took away another person until the team started shipping and stopped having unproductive meetings.</p>
</blockquote>
<p>I&rsquo;m no fan of Larry, but the man&rsquo;s right. I would much rather work in a small team that meets for a purpose. </p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Dinner and BSG</title>
      <link>https://amjith.com/blog/dinner-and-bsg/</link>
      <pubDate>Sun, 14 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/dinner-and-bsg/</guid>
      <description>&lt;p&gt;Yosh and I have been planning to do a &lt;a href=&#34;http://www.syfy.com/battlestar/&#34;&gt;BSG&lt;/a&gt; (Battlestart Gallactica) marathon for  a while now. Finally we broke down and decided instead of doing a marathon, we&amp;rsquo;ll just one episode at a time with our dinner. Here&amp;rsquo;s to the beginning.&lt;/p&gt;
&lt;p&gt;We had vegetarian Chili, Garlic Bread, Hash Browns and Beans with sesame seeds. &lt;/p&gt;
&lt;p&gt;◀
1
of
4
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892932/o_QDwgZb4BXzzhP7LqI6bUGfKY4/thumb_Dinner_BSG1.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892934/f6Cb2mdh76FmHJM_PEkKvsK25t4/thumb_Dinner_BSG2.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892935/zE6DNHZSre-pgDB_qLHP73fw4DI/thumb_Dinner_BSG3.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892936/hFt2CTukPYZsgvYC6ixYZTaCHUI/thumb_Dinner_BSG5.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892932/o_QDwgZb4BXzzhP7LqI6bUGfKY4/large_Dinner_BSG1.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Yosh and I have been planning to do a <a href="http://www.syfy.com/battlestar/">BSG</a> (Battlestart Gallactica) marathon for  a while now. Finally we broke down and decided instead of doing a marathon, we&rsquo;ll just one episode at a time with our dinner. Here&rsquo;s to the beginning.</p>
<p>We had vegetarian Chili, Garlic Bread, Hash Browns and Beans with sesame seeds. </p>
<p>◀
1
of
4
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892932/o_QDwgZb4BXzzhP7LqI6bUGfKY4/thumb_Dinner_BSG1.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892934/f6Cb2mdh76FmHJM_PEkKvsK25t4/thumb_Dinner_BSG2.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892935/zE6DNHZSre-pgDB_qLHP73fw4DI/thumb_Dinner_BSG3.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892936/hFt2CTukPYZsgvYC6ixYZTaCHUI/thumb_Dinner_BSG5.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892932/o_QDwgZb4BXzzhP7LqI6bUGfKY4/large_Dinner_BSG1.jpg" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Cows and Bulls == Master Mind</title>
      <link>https://amjith.com/blog/cows-and-bulls-master-mind/</link>
      <pubDate>Sat, 13 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/cows-and-bulls-master-mind/</guid>
      <description>&lt;p&gt;I found out during my Utah Python meetup that the game I created called &lt;a href=&#34;https://github.com/amjith/Cows_and_Bulls-Game&#34;&gt;Cows and Bulls&lt;/a&gt; is actually called &lt;a href=&#34;http://en.wikipedia.org/wiki/Mastermind_(board_game)&#34;&gt;MasterMind&lt;/a&gt; in the US. It&amp;rsquo;s a really simple game. The computer thinks of a 4-letter word. You start guessing that word and the computer will give hints along the way.
&lt;strong&gt;Cows&lt;/strong&gt; - Number of characters in your guess that match the original word, but placed in a different location.
&lt;strong&gt;Bulls&lt;/strong&gt; - Number of characters in your guess that match the original word, found in the exact same location. Based on the hints from each turn we can narrow down the possibilities and finally reach the answer.  It&amp;rsquo;s a fun game and really easy to implement.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I found out during my Utah Python meetup that the game I created called <a href="https://github.com/amjith/Cows_and_Bulls-Game">Cows and Bulls</a> is actually called <a href="http://en.wikipedia.org/wiki/Mastermind_(board_game)">MasterMind</a> in the US. It&rsquo;s a really simple game. The computer thinks of a 4-letter word. You start guessing that word and the computer will give hints along the way.
<strong>Cows</strong> - Number of characters in your guess that match the original word, but placed in a different location.
<strong>Bulls</strong> - Number of characters in your guess that match the original word, found in the exact same location. Based on the hints from each turn we can narrow down the possibilities and finally reach the answer.  It&rsquo;s a fun game and really easy to implement.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>pTimer listed in Softpedia</title>
      <link>https://amjith.com/blog/ptimer-listed-in-softpedia/</link>
      <pubDate>Fri, 12 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/ptimer-listed-in-softpedia/</guid>
      <description>&lt;p&gt;One of my hobby projects is now included in the &lt;a href=&#34;http://mac.softpedia.com/get/Business/pTimer.shtml&#34;&gt;Softpedia&lt;/a&gt; Mac OS database. I don&amp;rsquo;t know if that means anything but it is fun to see that 9 people have downloaded that utility so far. &lt;/p&gt;
&lt;p&gt;A while ago I wrote a little PyQt4 application called &lt;a href=&#34;http://code.google.com/p/ptimer/&#34;&gt;pTimer&lt;/a&gt; to try out the famous Pomodoro Technique for productivity. &lt;/p&gt;
&lt;p&gt;The &lt;a href=&#34;https://amjith.blogspot.com/2010/09/pomodoro-timer-written-in-python-and.html&#34;&gt;original&lt;/a&gt; reason why I wrote that timer was to get myself acclimatized to Qt programming using Python. But since I liked it so much I decided to publish the code and host it on Google Code hosting. &lt;/p&gt;
&lt;p&gt;Yesterday I got an email from Softpedia about including that utility in their website. Pleasantly surprised.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>One of my hobby projects is now included in the <a href="http://mac.softpedia.com/get/Business/pTimer.shtml">Softpedia</a> Mac OS database. I don&rsquo;t know if that means anything but it is fun to see that 9 people have downloaded that utility so far. </p>
<p>A while ago I wrote a little PyQt4 application called <a href="http://code.google.com/p/ptimer/">pTimer</a> to try out the famous Pomodoro Technique for productivity. </p>
<p>The <a href="https://amjith.blogspot.com/2010/09/pomodoro-timer-written-in-python-and.html">original</a> reason why I wrote that timer was to get myself acclimatized to Qt programming using Python. But since I liked it so much I decided to publish the code and host it on Google Code hosting. </p>
<p>Yesterday I got an email from Softpedia about including that utility in their website. Pleasantly surprised.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Utah Python Users Group - 11/11/10</title>
      <link>https://amjith.com/blog/utah-python-users-group-111110/</link>
      <pubDate>Thu, 11 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/utah-python-users-group-111110/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve been messing around with Python for the past 6 months and I&amp;rsquo;m loving it. Today I went to my second &lt;a href=&#34;http://groups.google.com/group/utahpython&#34;&gt;UtahPython&lt;/a&gt; users group meeting and had a lot of fun and learned a ton of stuff.&lt;/p&gt;
&lt;p&gt;Chronological order of things I learned:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Supy bot - an IRC bot written in Python.&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://github.com/tierra/supybot-doxygen&#34;&gt;supybot-doxygen&lt;/a&gt; - A plugin for supy bot that can provide api documentation for any software that uses doxygen.
&lt;ul&gt;
&lt;li&gt;This could be really useful at work if I can setup an internal IRC server for the developers to hang out.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://codespeak.net/lxml/objectify.html&#34;&gt;Objectify&lt;/a&gt; is a module in python for parsing XML files.&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://docs.python.org/library/doctest.html&#34;&gt;doctest&lt;/a&gt; - a python module for TDD that is super simple. I&amp;rsquo;m really excited about this. Thanks to &lt;a href=&#34;http://panela.blog-city.com/about_matt.htm&#34;&gt;Matt&lt;/a&gt; for showing me how to use this.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Matt suggested that we do some pair programming during the meetup.&lt;br&gt;
Here&amp;rsquo;s the task: Write a simple python program that can take page numbers as user input and convert it to a list of numbers. &lt;/p&gt;
&lt;pre&gt;&lt;code&gt;User Input: 0, 1, 5, 7-10
Output: 0,1,5,7,8,9,10
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Here is the code I wrote with the doc test based unit test in the doc-string:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;###### PrintParser.py #######
    
    #!/usr/bin/env python

    def convert(inp):
        &amp;quot;&amp;quot;&amp;quot;
 \* Get the input from user.
 \* Parse the input to extract numbers
 \*\* Split by comma
 \*\*\* Each item in the list will then be split by &#39;-&#39;
 \*\*\*\* Populate the number between a-b using range(a,b)

 &amp;gt;&amp;gt;&amp;gt; convert(&amp;quot;&amp;quot;)
 []
 &amp;gt;&amp;gt;&amp;gt; convert(&amp;quot;1&amp;quot;)
 [1]
 &amp;gt;&amp;gt;&amp;gt; convert(&amp;quot;1,2&amp;quot;)
 [1, 2]
 &amp;gt;&amp;gt;&amp;gt; convert(&amp;quot;1,2-5&amp;quot;)
 [1, 2, 3, 4, 5]
 &amp;gt;&amp;gt;&amp;gt; convert(&amp;quot;1-3,2-5,8,10,15-20&amp;quot;)
 [1, 2, 3, 2, 3, 4, 5, 8, 10, 15, 16, 17, 18, 19, 20]
 &amp;quot;&amp;quot;&amp;quot;
        if not inp:
            return []
        pages = []
        comma_separated = []
        comma_separated = inp.split(&amp;quot;,&amp;quot;)
        for item in comma_separated:
            if &amp;quot;-&amp;quot; in item:
                a = item.split(&amp;quot;-&amp;quot;)
                pages.extend(range(int(a[0]),int(a[1])+1))
            else:
                pages.append(int(item))

        return pages

    if __name__ == &#39;\_\_main\_\_&#39; :
        import doctest
        doctest.testmod()
&lt;/code&gt;&lt;/pre&gt;</description>
      <content:encoded><![CDATA[<p>I&rsquo;ve been messing around with Python for the past 6 months and I&rsquo;m loving it. Today I went to my second <a href="http://groups.google.com/group/utahpython">UtahPython</a> users group meeting and had a lot of fun and learned a ton of stuff.</p>
<p>Chronological order of things I learned:</p>
<ul>
<li>Supy bot - an IRC bot written in Python.</li>
<li><a href="https://github.com/tierra/supybot-doxygen">supybot-doxygen</a> - A plugin for supy bot that can provide api documentation for any software that uses doxygen.
<ul>
<li>This could be really useful at work if I can setup an internal IRC server for the developers to hang out.</li>
</ul>
</li>
<li><a href="http://codespeak.net/lxml/objectify.html">Objectify</a> is a module in python for parsing XML files.</li>
<li><a href="http://docs.python.org/library/doctest.html">doctest</a> - a python module for TDD that is super simple. I&rsquo;m really excited about this. Thanks to <a href="http://panela.blog-city.com/about_matt.htm">Matt</a> for showing me how to use this.</li>
</ul>
<p>Matt suggested that we do some pair programming during the meetup.<br>
Here&rsquo;s the task: Write a simple python program that can take page numbers as user input and convert it to a list of numbers. </p>
<pre><code>User Input: 0, 1, 5, 7-10
Output: 0,1,5,7,8,9,10
</code></pre><p>Here is the code I wrote with the doc test based unit test in the doc-string:</p>
<pre><code>###### PrintParser.py #######
    
    #!/usr/bin/env python

    def convert(inp):
        &quot;&quot;&quot;
 \* Get the input from user.
 \* Parse the input to extract numbers
 \*\* Split by comma
 \*\*\* Each item in the list will then be split by '-'
 \*\*\*\* Populate the number between a-b using range(a,b)

 &gt;&gt;&gt; convert(&quot;&quot;)
 []
 &gt;&gt;&gt; convert(&quot;1&quot;)
 [1]
 &gt;&gt;&gt; convert(&quot;1,2&quot;)
 [1, 2]
 &gt;&gt;&gt; convert(&quot;1,2-5&quot;)
 [1, 2, 3, 4, 5]
 &gt;&gt;&gt; convert(&quot;1-3,2-5,8,10,15-20&quot;)
 [1, 2, 3, 2, 3, 4, 5, 8, 10, 15, 16, 17, 18, 19, 20]
 &quot;&quot;&quot;
        if not inp:
            return []
        pages = []
        comma_separated = []
        comma_separated = inp.split(&quot;,&quot;)
        for item in comma_separated:
            if &quot;-&quot; in item:
                a = item.split(&quot;-&quot;)
                pages.extend(range(int(a[0]),int(a[1])+1))
            else:
                pages.append(int(item))

        return pages

    if __name__ == '\_\_main\_\_' :
        import doctest
        doctest.testmod()
</code></pre>]]></content:encoded>
    </item>
    
    <item>
      <title>Hapkido First Impressions</title>
      <link>https://amjith.com/blog/hapkido-first-impressions/</link>
      <pubDate>Wed, 10 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/hapkido-first-impressions/</guid>
      <description>&lt;p&gt;I went to my first &lt;a href=&#34;http://en.wikipedia.org/wiki/Hapkido&#34;&gt;Hapkido&lt;/a&gt; class today. I have a very good (and respected) friend from work, who is already taking that class and he recommended it.&lt;/p&gt;
&lt;p&gt;I had high hopes for that class, maybe a little too high. It was a little bit underwhelming due to my overtly hyped expectations. It is definitely more exerting (physically) than Aikido. It combines the kicks from Taekwondo with the joint locks in Aikido. So I&amp;rsquo;m excited to keep learning the art. But the part that bothers me about Hapkido is you attack to destroy, unlike Aikido where you take care of your opponent even when you are pinning them down and making them submit. &lt;/p&gt;
&lt;p&gt;But one great thing about the class is the instructor seems really good. He is very friendly and knowledgeable. If you are in Lehi/American Fork area you should check out the class. &lt;a href=&#34;http://xsifactory.com/martial-arts-classes/&#34;&gt;xsifactory.com/martial-arts-classes/&lt;/a&gt;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I went to my first <a href="http://en.wikipedia.org/wiki/Hapkido">Hapkido</a> class today. I have a very good (and respected) friend from work, who is already taking that class and he recommended it.</p>
<p>I had high hopes for that class, maybe a little too high. It was a little bit underwhelming due to my overtly hyped expectations. It is definitely more exerting (physically) than Aikido. It combines the kicks from Taekwondo with the joint locks in Aikido. So I&rsquo;m excited to keep learning the art. But the part that bothers me about Hapkido is you attack to destroy, unlike Aikido where you take care of your opponent even when you are pinning them down and making them submit. </p>
<p>But one great thing about the class is the instructor seems really good. He is very friendly and knowledgeable. If you are in Lehi/American Fork area you should check out the class. <a href="http://xsifactory.com/martial-arts-classes/">xsifactory.com/martial-arts-classes/</a></p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Mmmmm.... Rice</title>
      <link>https://amjith.com/blog/mmmmm-rice/</link>
      <pubDate>Wed, 10 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/mmmmm-rice/</guid>
      <description>&lt;p&gt;After three days of not having any rice, I finally made some today. Is it just me or does every one well up a little bit when they are about to taste rice?So if I like rice so much, why don&amp;rsquo;t I make some every day, you ask. Well, I&amp;rsquo;m a lazy bum who doesn&amp;rsquo;t enjoy cooking as much as eating. There, I said it!&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>After three days of not having any rice, I finally made some today. Is it just me or does every one well up a little bit when they are about to taste rice?So if I like rice so much, why don&rsquo;t I make some every day, you ask. Well, I&rsquo;m a lazy bum who doesn&rsquo;t enjoy cooking as much as eating. There, I said it!</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Vita Brevis [Ars Longa]</title>
      <link>https://amjith.com/blog/vita-brevis-ars-longa/</link>
      <pubDate>Tue, 09 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/vita-brevis-ars-longa/</guid>
      <description>&lt;p&gt;&lt;strong&gt;InnerVoice&lt;/strong&gt;: That is latin for &amp;ldquo;Life is Short, Art is Long&amp;rdquo;. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: Yeah, I know, I&amp;rsquo;m a little behind on my personal projects.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;InnerVoice&lt;/strong&gt;: Try waaaaay behind. There are at least ten tabs open at home and five tabs open at work &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: I&amp;rsquo;ll get to it. They are not going anywhere.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;InnerVoice&lt;/strong&gt;: BTW, those unread emails with some tutorial links isn&amp;rsquo;t gonna master itself, you know.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: Hmmm&amp;hellip;.. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;InnerVoice&lt;/strong&gt;: Are you even listening to me?&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: Barely. I&amp;rsquo;m still thinking about my first &lt;a href=&#34;http://en.wikipedia.org/wiki/Hapkido&#34;&gt;Hapkido&lt;/a&gt; class tomorrow. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;InnerVoice&lt;/strong&gt;: Well, there goes the Wednesday nights.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: BTW, I agreed to present a brief tutorial on Git at the SLLUG meeting next Wednesday (Nov 17). &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;InnerVoice&lt;/strong&gt;: What? Are you crazy?&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: Well how else am I going to make a good first impression?&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;InnerVoice&lt;/strong&gt;: You do realize, you&amp;rsquo;ve never been to one of those meetings, right?&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: Yeah, but they seem like nice people. I&amp;rsquo;m sure I&amp;rsquo;ll be fine. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;InnerVoice&lt;/strong&gt;: *Shakes Head* Hopeless, utterly hopeless.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: *Grinning with glee*&lt;/p&gt;
&lt;p&gt;It&amp;rsquo;s awesome when life gets busy.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p><strong>InnerVoice</strong>: That is latin for &ldquo;Life is Short, Art is Long&rdquo;. </p>
<p><strong>Me</strong>: Yeah, I know, I&rsquo;m a little behind on my personal projects.</p>
<p><strong>InnerVoice</strong>: Try waaaaay behind. There are at least ten tabs open at home and five tabs open at work </p>
<p><strong>Me</strong>: I&rsquo;ll get to it. They are not going anywhere.</p>
<p><strong>InnerVoice</strong>: BTW, those unread emails with some tutorial links isn&rsquo;t gonna master itself, you know.</p>
<p><strong>Me</strong>: Hmmm&hellip;.. </p>
<p><strong>InnerVoice</strong>: Are you even listening to me?</p>
<p><strong>Me</strong>: Barely. I&rsquo;m still thinking about my first <a href="http://en.wikipedia.org/wiki/Hapkido">Hapkido</a> class tomorrow. </p>
<p><strong>InnerVoice</strong>: Well, there goes the Wednesday nights.</p>
<p><strong>Me</strong>: BTW, I agreed to present a brief tutorial on Git at the SLLUG meeting next Wednesday (Nov 17). </p>
<p><strong>InnerVoice</strong>: What? Are you crazy?</p>
<p><strong>Me</strong>: Well how else am I going to make a good first impression?</p>
<p><strong>InnerVoice</strong>: You do realize, you&rsquo;ve never been to one of those meetings, right?</p>
<p><strong>Me</strong>: Yeah, but they seem like nice people. I&rsquo;m sure I&rsquo;ll be fine. </p>
<p><strong>InnerVoice</strong>: *Shakes Head* Hopeless, utterly hopeless.</p>
<p><strong>Me</strong>: *Grinning with glee*</p>
<p>It&rsquo;s awesome when life gets busy.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Movember Pics</title>
      <link>https://amjith.com/blog/movember-pics-tags-movember/</link>
      <pubDate>Mon, 08 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/movember-pics-tags-movember/</guid>
      <description>&lt;p&gt;I heard about the &lt;a href=&#34;http://movemberut.com/&#34;&gt;Movember Movement&lt;/a&gt; at &lt;a href=&#34;http://www.ignitesaltlake.com/ignite/index.cfm&#34;&gt;Ignite&lt;/a&gt; SLC #6. I decided it is high time I use my facial hair for something useful (other than impressing the missus).&lt;/p&gt;
&lt;p&gt;Shout out to &lt;a href=&#34;http://twitter.com/#!/clarkwinegar&#34;&gt;Clark Winegar&lt;/a&gt; of &lt;a href=&#34;http://mustachepower.com/blog/&#34;&gt;Mustache Power&lt;/a&gt; for his Movember presentation @ Ignite.&lt;/p&gt;
&lt;p&gt;◀
1
of
2
▶&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892917/fnsAX3aos43KAhy9Qw0nitErE0I/thumb_Mobile_Photo_Nov_8_2010_10_11_.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;a href=&#34;#&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892918/BnVEA5CcMNZgWdPdEB29_sY6pUA/thumb_0Mobile_Photo_Nov_8_2010_10_11_.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892917/fnsAX3aos43KAhy9Qw0nitErE0I/large_Mobile_Photo_Nov_8_2010_10_11_.jpg&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I heard about the <a href="http://movemberut.com/">Movember Movement</a> at <a href="http://www.ignitesaltlake.com/ignite/index.cfm">Ignite</a> SLC #6. I decided it is high time I use my facial hair for something useful (other than impressing the missus).</p>
<p>Shout out to <a href="http://twitter.com/#!/clarkwinegar">Clark Winegar</a> of <a href="http://mustachepower.com/blog/">Mustache Power</a> for his Movember presentation @ Ignite.</p>
<p>◀
1
of
2
▶</p>
<p><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892917/fnsAX3aos43KAhy9Qw0nitErE0I/thumb_Mobile_Photo_Nov_8_2010_10_11_.jpg" alt=""  />
</a><a href="#"><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892918/BnVEA5CcMNZgWdPdEB29_sY6pUA/thumb_0Mobile_Photo_Nov_8_2010_10_11_.jpg" alt=""  />
</a></p>
<p><img loading="lazy" src="https://phaven-prod.s3.amazonaws.com/files/image_part/asset/892917/fnsAX3aos43KAhy9Qw0nitErE0I/large_Mobile_Photo_Nov_8_2010_10_11_.jpg" alt=""  />
</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Bad day all around</title>
      <link>https://amjith.com/blog/bad-day-all-around/</link>
      <pubDate>Sun, 07 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/bad-day-all-around/</guid>
      <description>&lt;p&gt;I went to a Beans and Brews in American Fork to get some work done. It was a total disaster:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;I decided to try dirty Chai (Chai w/ espresso ) which tasted terrible.&lt;/li&gt;
&lt;li&gt;I got no work done, thanks to the noisy coffee grinder and their horrible excuse for a music.&lt;/li&gt;
&lt;li&gt;My netbook was having too many problems and I gave up trying to get any work done on it. Time to buy a decent laptop.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;On my way back from this defeated attempt to work at a coffee shop, I was stopped by a cop for speeding.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;I got my first speeding ticket in Utah County.&lt;/li&gt;
&lt;li&gt;I realized that I&amp;rsquo;m about as useful as a concrete parachute when I&amp;rsquo;m stopped by a police officer. I really need to work on my communication skills.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Got back home and checked my email to find out, I&amp;rsquo;ve ruined my chances of going to an Aikido seminar. &lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;My less than tactful communication with my Aikido teacher barred both Yoshi and I from attending an Aikido Seminar in December.&lt;/li&gt;
&lt;li&gt;I might have angered him and created more political discomfort.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I don&amp;rsquo;t think I can salvage this day.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ll just go back to my corner and produce some more code that the world doesn&amp;rsquo;t need.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>I went to a Beans and Brews in American Fork to get some work done. It was a total disaster:</p>
<ul>
<li>I decided to try dirty Chai (Chai w/ espresso ) which tasted terrible.</li>
<li>I got no work done, thanks to the noisy coffee grinder and their horrible excuse for a music.</li>
<li>My netbook was having too many problems and I gave up trying to get any work done on it. Time to buy a decent laptop.</li>
</ul>
<p>On my way back from this defeated attempt to work at a coffee shop, I was stopped by a cop for speeding.</p>
<ul>
<li>I got my first speeding ticket in Utah County.</li>
<li>I realized that I&rsquo;m about as useful as a concrete parachute when I&rsquo;m stopped by a police officer. I really need to work on my communication skills.</li>
</ul>
<p>Got back home and checked my email to find out, I&rsquo;ve ruined my chances of going to an Aikido seminar. </p>
<ul>
<li>My less than tactful communication with my Aikido teacher barred both Yoshi and I from attending an Aikido Seminar in December.</li>
<li>I might have angered him and created more political discomfort.</li>
</ul>
<p>I don&rsquo;t think I can salvage this day.</p>
<p>I&rsquo;ll just go back to my corner and produce some more code that the world doesn&rsquo;t need.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Brain Spill</title>
      <link>https://amjith.com/blog/brain-spit/</link>
      <pubDate>Sat, 06 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/brain-spit/</guid>
      <description>&lt;p&gt;Brain spill is a dumping ground for my incoherent thoughts and incomplete ideas. It&amp;rsquo;ll be training ground to practice my writing skills.&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>Brain spill is a dumping ground for my incoherent thoughts and incomplete ideas. It&rsquo;ll be training ground to practice my writing skills.</p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Cows and Bulls Game</title>
      <link>https://amjith.com/blog/cows-and-bulls-game/</link>
      <pubDate>Sat, 06 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/cows-and-bulls-game/</guid>
      <description>&lt;p&gt;A typical Saturday evening conversation between me and my inner voice. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Setting&lt;/strong&gt;: Salt Lake Roasting Co., after an intense Aikido training. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: I&amp;rsquo;m bored. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Inner Voice&lt;/strong&gt;: Go take a nap.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: Meh! I think I&amp;rsquo;m gonna do some Python coding. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Inner Voice&lt;/strong&gt;: What are you going to code? &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: Remember the Cows and Bulls word game that I used to play when I was little.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Inner Voice&lt;/strong&gt;: What? That sounds kinda lame. Work on something productive.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: Screw you, Inner Voice!!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Inner Voice&lt;/strong&gt;: I don&amp;rsquo;t like you very much. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: Oh yeah, well the feeling is mutual. &lt;/p&gt;
&lt;p&gt;So I fired up Vim and coded up the Cows and Bulls game :)&lt;/p&gt;
&lt;p&gt;It is text-based right now and still in its primitive stage. I&amp;rsquo;ll probably add more features when I get into a fight with my Inner Voice again. &lt;/p&gt;
&lt;p&gt;Oh here is the code: &lt;a href=&#34;https://github.com/amjith/Cows_and_Bulls-Game&#34;&gt;https://github.com/amjith/Cows_and_Bulls-Game&lt;/a&gt;&lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>A typical Saturday evening conversation between me and my inner voice. </p>
<p><strong>Setting</strong>: Salt Lake Roasting Co., after an intense Aikido training. </p>
<p><strong>Me</strong>: I&rsquo;m bored. </p>
<p><strong>Inner Voice</strong>: Go take a nap.</p>
<p><strong>Me</strong>: Meh! I think I&rsquo;m gonna do some Python coding. </p>
<p><strong>Inner Voice</strong>: What are you going to code? </p>
<p><strong>Me</strong>: Remember the Cows and Bulls word game that I used to play when I was little.</p>
<p><strong>Inner Voice</strong>: What? That sounds kinda lame. Work on something productive.</p>
<p><strong>Me</strong>: Screw you, Inner Voice!!</p>
<p><strong>Inner Voice</strong>: I don&rsquo;t like you very much. </p>
<p><strong>Me</strong>: Oh yeah, well the feeling is mutual. </p>
<p>So I fired up Vim and coded up the Cows and Bulls game :)</p>
<p>It is text-based right now and still in its primitive stage. I&rsquo;ll probably add more features when I get into a fight with my Inner Voice again. </p>
<p>Oh here is the code: <a href="https://github.com/amjith/Cows_and_Bulls-Game">https://github.com/amjith/Cows_and_Bulls-Game</a></p>
]]></content:encoded>
    </item>
    
    <item>
      <title>Extracting 4 letter words from a wordlist</title>
      <link>https://amjith.com/blog/extracting-4-letter-words-from-a-wordlist/</link>
      <pubDate>Sat, 06 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/extracting-4-letter-words-from-a-wordlist/</guid>
      <description>&lt;p&gt;All I wanted was to extract only the 4 letters words from /usr/share/dict/words. It tooks me a full 10-minutes to figure out the regex for it to work with egrep.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;$ egrep &#39;^[A-Za-z]{4}$&#39; /usr/share/dict/words
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt; Note to self: Must practice regex syntax more often. &lt;/p&gt;
&lt;p&gt;Update (a slightly cleaner way, from &lt;a href=&#34;http://twitter.com/#!/gabegundy/status/1154371396042753&#34;&gt;@gabegundy&lt;/a&gt;):&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;$ egrep &#39;^[a-Z]{4}$&#39; /usr/share/dict/word 
&lt;/code&gt;&lt;/pre&gt;</description>
      <content:encoded><![CDATA[<p>All I wanted was to extract only the 4 letters words from /usr/share/dict/words. It tooks me a full 10-minutes to figure out the regex for it to work with egrep.</p>
<pre><code>$ egrep '^[A-Za-z]{4}$' /usr/share/dict/words
</code></pre><p> Note to self: Must practice regex syntax more often. </p>
<p>Update (a slightly cleaner way, from <a href="http://twitter.com/#!/gabegundy/status/1154371396042753">@gabegundy</a>):</p>
<pre><code>$ egrep '^[a-Z]{4}$' /usr/share/dict/word 
</code></pre>]]></content:encoded>
    </item>
    
    <item>
      <title>Happy for a friend</title>
      <link>https://amjith.com/blog/happy-for-a-friend/</link>
      <pubDate>Sat, 06 Nov 2010 00:00:00 +0000</pubDate>
      
      <guid>https://amjith.com/blog/happy-for-a-friend/</guid>
      <description>&lt;p&gt;My buddy just told me that his wife is 11 weeks pregnant.&lt;/p&gt;
&lt;p&gt;An exchange we had over the phone: &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Anand&lt;/strong&gt;: If we have a boy, we&amp;rsquo;ll start receiving applications from potential brides. Would you guys be interested in pre-applying? &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Me&lt;/strong&gt;: Well if we have a girl, I&amp;rsquo;m sure she can kidnap your boy without any trouble, saving us the trouble of application fees. &lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m freakin&#39; excited for Anand and Abirami. &lt;/p&gt;
</description>
      <content:encoded><![CDATA[<p>My buddy just told me that his wife is 11 weeks pregnant.</p>
<p>An exchange we had over the phone: </p>
<p><strong>Anand</strong>: If we have a boy, we&rsquo;ll start receiving applications from potential brides. Would you guys be interested in pre-applying? </p>
<p><strong>Me</strong>: Well if we have a girl, I&rsquo;m sure she can kidnap your boy without any trouble, saving us the trouble of application fees. </p>
<p>I&rsquo;m freakin' excited for Anand and Abirami. </p>
]]></content:encoded>
    </item>
    
    
    
  </channel>
</rss>
