<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>ARV&apos;s Blog</title><description>A Data Scientist passionate about harnessing GenAI to solve real-world problems.</description><link>https://arv-anshul.github.io</link><language>en-us</language><item><title>July Journal</title><link>https://arv-anshul.github.io/journal/2026/07</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2026/07</guid><description>Weekly Journal by ARV of July 2026</description><pubDate>Wed, 01 Jul 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 27 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Amazing tool &lt;a href=&quot;https://github.com/koxudaxi/datamodel-code-generator&quot;&gt;&lt;code&gt;datamodel-code-generator&lt;/code&gt;&lt;/a&gt; to convert OpenAPI
spec into Pydantic Models. I am using this in the Zyou SDK.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Working heavily on Validator API &amp;lt;&amp;gt; SDK &amp;lt;&amp;gt; MCP.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Took one day off due to headache, but also did some work after feeling well. It maybe happened because late night
films and shows watching.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Played Badminton with Team.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;New open specification introduced for AI Agents, currently in early stages but looks promising:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Open Knowledge Format (OKF):&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;1.&lt;/span&gt;&lt;span&gt; `index.md`&lt;/span&gt;&lt;span&gt; will get generated by a script not by the LLM.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;2.&lt;/span&gt;&lt;span&gt; A MCP server with tools to query the OKF Bundle.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;3.&lt;/span&gt;&lt;span&gt; Maintain a JSON schema to help the MCP server/tools.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;4.&lt;/span&gt;&lt;span&gt; Concept links validator to validate whether the written links exists or not.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;5.&lt;/span&gt;&lt;span&gt; Also create MCP tools for &lt;/span&gt;&lt;span&gt;`index.md`&lt;/span&gt;&lt;span&gt; and &lt;/span&gt;&lt;span&gt;`log.md`&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;6.&lt;/span&gt;&lt;span&gt; MCP tool for accessing &lt;/span&gt;&lt;span&gt;`# Citations`&lt;/span&gt;&lt;span&gt; from given file path.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;7.&lt;/span&gt;&lt;span&gt; An UI for the OKF Bundle for better readability for Humans. &lt;/span&gt;&lt;span&gt;**/w Astro**&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;ol&gt;
&lt;li&gt;Agentic Resource Discovery (ARD): It defines how agents and tools are cataloged, indexed, and searched across
federated registries, so an agent can find capabilities at runtime instead of needing them preinstalled. It is a
shared standard that any company can implement independently, and that any agent can participate in.&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Installed OSS &lt;a href=&quot;https://handy.computer&quot;&gt;Handy&lt;/a&gt; app for Speech-to-Text work.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;I registered &lt;code&gt;okf&lt;/code&gt;, &lt;code&gt;arv-anshul&lt;/code&gt;, and &lt;code&gt;anshulrv&lt;/code&gt; package name on pypi.org. &lt;code&gt;arv&lt;/code&gt; and &lt;code&gt;anshul&lt;/code&gt; are already registered.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>july</category><author>Anshul Raj Verma</author></item><item><title>June Journal</title><link>https://arv-anshul.github.io/journal/2026/06</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2026/06</guid><description>Weekly Journal by ARV of June 2026</description><pubDate>Mon, 01 Jun 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 23 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://paxel.ycombinator.com&quot;&gt;&lt;strong&gt;PAXEL by Y Combinator&lt;/strong&gt;&lt;/a&gt; uses a shell script to analyze all of your session with
Coding Agents like Claude Code, Codex CLI, and Cursor to generate a report and a profile based on your prompts,
activities, and tool calls. You have to run a command in your terminal to generate this report. YC doesn&apos;t stores
anything regarding your sessions and all. At the end, a JSON payload of scores, narratives, redacted decisions, and
session metadata is uploaded to YC.&lt;/li&gt;
&lt;li&gt;Thought:&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;Ab aapka apna koi nahi hai,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Ab bas aapka apna ye hain aur aapka apna ye hain,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;baki sab matlabi,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Yahan tak ki mai bhi jo ye kar raha hun shayad,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ye bhi main apne liye he kar raha hun,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ki kal jab aap na raho to main ye soch sakun,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ki jab aap the tab maine ye kiya tha aapke liye.&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2&gt;Week 24 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;@Pratham came from Home. Now, we started working on SDKs and MCPs. We are now watching &quot;From&quot; and already completed
the Season 1.&lt;/li&gt;
&lt;li&gt;Me, @Anurag and @Pratham watched &lt;strong&gt;Obsession&lt;/strong&gt; movie in cinema hall. It was horrifying.&lt;/li&gt;
&lt;li&gt;Choice filling of Colleges for @Akansha on JOSSA and COMEDK.&lt;/li&gt;
&lt;li&gt;Wrote some helper Agent Skills.&lt;/li&gt;
&lt;li&gt;@Pratham is switching to Neovim, it&apos;s fantastic. I was also thinking to switch to Neovim or Helix but decided not to
because I&apos;ve a grip on Zed IDE already switching from it will be difficult and I&apos;ll some features. But I&apos;ll
definitely learn Vim key bindings.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 25 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Gone for TC and Pool Party with Friends and Co. to Bhopal.&lt;/li&gt;
&lt;li&gt;@Akansha is learning video editing and some camerawork for content creation.&lt;/li&gt;
&lt;li&gt;Watched the whole season 3 in train of &quot;From&quot;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 26 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Completed &quot;From&quot; season 4, finale was mid. Now waiting for season 5.&lt;/li&gt;
&lt;li&gt;I worked on my Claude Code configurations to ease my coding workflow:
&lt;ul&gt;
&lt;li&gt;RTK (Rust Token Killer) CLI hook which reduces output tokens of widely used CLI&apos;s like &lt;code&gt;ls&lt;/code&gt;, &lt;code&gt;find&lt;/code&gt;, &lt;code&gt;git&lt;/code&gt;, etc.&lt;/li&gt;
&lt;li&gt;Mattpocok Skills comes with many useful skills for developers my favorite &lt;code&gt;/grill-me&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;CLAUDE_LSP_TOOL &lt;code&gt;pyright-lsp&lt;/code&gt; for Python. But Claude doesn&apos;t use it often time.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/ponytail&lt;/code&gt; Agent Skill works nice with Opus 4.8.&lt;/li&gt;
&lt;li&gt;Disabled &lt;code&gt;Grep&lt;/code&gt; and &lt;code&gt;Glob&lt;/code&gt; builtin tools for &lt;code&gt;rtk grep&lt;/code&gt; and &lt;code&gt;rtk find&lt;/code&gt; CLI.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;ccstatusline&lt;/code&gt; to show important session and context metrics at the bottom.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Apple increased it’s prices.&lt;/li&gt;
&lt;li&gt;Pull out two all nighter with @Pratham and Team to work on projects.&lt;/li&gt;
&lt;li&gt;Gone for team dinner at MomoBae.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>june</category><author>Anshul Raj Verma</author></item><item><title>AI Harness</title><link>https://arv-anshul.github.io/blog/2026/ai-harness</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/ai-harness</guid><description>Using AI Harness like Claude Code or Pi.dev. Manage their configs and conventions in right opinionated way.</description><pubDate>Sat, 30 May 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I have started using Claude Code recently in my projects but I am find it hard to maintain its configurations because
Claude Code has it own set of convention than other AI Harness. Due to that I have to maintain both &lt;code&gt;.agents/&lt;/code&gt; and
&lt;code&gt;.claude/&lt;/code&gt; which doesn&apos;t looks good. Why do I maintain the same thing at two places &lt;em&gt;(even a symlink)&lt;/em&gt;.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I have switched to &lt;a href=&quot;https://chezmoi.io&quot;&gt;&lt;code&gt;chezmoi&lt;/code&gt;&lt;/a&gt; just because of this.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Although, Claude Code is known to be as the best in its class but I want a better more acceptable, flexible solution to
this. And there is two in the market &lt;a href=&quot;https://opencode.ai&quot;&gt;OpenCode&lt;/a&gt; and &lt;a href=&quot;https://pi.dev&quot;&gt;Pi Agent&lt;/a&gt;. OpenCode is more
popular than Pi but Pi is more flexible in nature. I am choosing Pi.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Even though I will not customize it a lot. It just me who wants to try and stick with Pi.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Requirements&lt;/h2&gt;
&lt;p&gt;A coding agent should have these things:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Community Convention Follower&lt;/li&gt;
&lt;li&gt;Agent Skills&lt;/li&gt;
&lt;li&gt;AGENTS.md&lt;/li&gt;
&lt;li&gt;Plan Mode&lt;/li&gt;
&lt;li&gt;Open Source&lt;/li&gt;
&lt;li&gt;Models Availability (No Vendor Locking)&lt;/li&gt;
&lt;li&gt;Extensibility and Customization&lt;/li&gt;
&lt;/ul&gt;
&lt;blockquote&gt;
&lt;p&gt;Recently I have Vertex AI project access through which I can use any models like Gemini, Claude, GPT, etc.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Agent Skills&lt;/h3&gt;
&lt;p&gt;The coding agent should support the &lt;a href=&quot;https://agentskills.io&quot;&gt;Agent Skills&lt;/a&gt;. This is a standardized way to give AI agents
new capabilities and expertise.&lt;/p&gt;
&lt;h3&gt;AGENTS.md&lt;/h3&gt;
&lt;p&gt;Think of &lt;a href=&quot;https://agents.md&quot;&gt;AGENTS.md&lt;/a&gt; as a README for agents: a dedicated, predictable place to provide the context
and instructions to help AI coding agents work on your project.&lt;/p&gt;
&lt;p&gt;Many agents follow their own conventions like Claude Code has &lt;code&gt;CLAUDE.md&lt;/code&gt;, Gemini has &lt;code&gt;GEMINI.md&lt;/code&gt; (it also supports
&lt;code&gt;AGENTS.md&lt;/code&gt;) but I want an agent which supports this &lt;code&gt;AGENTS.md&lt;/code&gt; convention because it is being decided by the
community.&lt;/p&gt;
&lt;h3&gt;Plan Mode&lt;/h3&gt;
&lt;p&gt;I don&apos;t know how does Plan Mode works in Claude Code but it is very useful for me to think about a feature
implementation before the actual implementation. I think there is one simple solution to use an Agent Skill for that but
I am also exploring more in community.&lt;/p&gt;
&lt;p&gt;I have found &lt;a href=&quot;https://npmx.dev/package/@ifi/pi-plan&quot;&gt;@ifi/pi-plan&lt;/a&gt; (which is actually inspired from
&lt;a href=&quot;https://github.com/sids/pi-extensions/tree/main/plan-md&quot;&gt;&lt;code&gt;/plan-md&lt;/code&gt;&lt;/a&gt;) and I think this is a better tool for planning
task because it has a workflow pipeline which guarantee idempotency over tasks.&lt;/p&gt;
&lt;h3&gt;Open Source&lt;/h3&gt;
&lt;p&gt;There are multiple open source coding agents like Codex CLI, Gemini CLI, OpenCode, Pi Coding Agent, etc. But Codex CLI
and Gemini CLI are vendor locked means you cannot use other provider&apos;s model in those CLIs.&lt;/p&gt;
&lt;p&gt;OpenCode is the most popular one here but I want to go with Pi Coding Agent due to its extensibility and customization.&lt;/p&gt;
&lt;h3&gt;Models Availability&lt;/h3&gt;
&lt;p&gt;Claude Code, Codex, Gemini are vendor locked but OpenCode and Pi are not. You can use any provider&apos;s models in those
coding agents which is very useful.&lt;/p&gt;
&lt;h3&gt;Extensibility and Customization&lt;/h3&gt;
&lt;p&gt;Pi is very minimal coding agent but you can also customize it with extensions, prompts, skills, and themes. See
&lt;a href=&quot;https://pi.dev&quot;&gt;Pi.dev&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;I don&apos;t need shiny and bloated features in my workflow. I will keep Pi minimal with aesthetic yet powerful and
performant agent for my workflow. I will maintain a repository where I keep my customization configurations.&lt;/p&gt;
</content:encoded><category>blog</category><category>blog</category><category>ai</category><category>conventions</category><author>Anshul Raj Verma</author></item><item><title>May Journal</title><link>https://arv-anshul.github.io/journal/2026/05</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2026/05</guid><description>Weekly Journal by ARV of May 2026</description><pubDate>Fri, 01 May 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 19 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Busy in office work.&lt;/li&gt;
&lt;li&gt;I haven&apos;t done meaningful other than my office work which I cannot mention here that&apos;s why I am able to write it
consistently. Now I use a dairy and pen to make notes while working.&lt;/li&gt;
&lt;li&gt;Sometimes I write couple of paragraphs on Google Keep which I&apos;ve decided to put them here instead.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 20 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Busy in office work.&lt;/li&gt;
&lt;li&gt;Shifted to new flat. Busy in arrangements. Eating from restaurants for 2 weeks.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 21 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Busy in office work.&lt;/li&gt;
&lt;li&gt;Visited cousin&apos;s house on Sunday and came back on Monday for work. I struggle with the buses even now.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 22 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Busy in office work.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;@Akansha got her new Macbook Air M5.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Thought:&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;Aapne agar dhyan diya hoga to jante hoge ki mai jyada nahi bolta, jyada jhagadta nahi.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Pata hai, kyu?&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Kyuki main aaj aapke paas hu, apse aankh se aankh mila kar baatein kar raha hun.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Lekin kal jab main akela rahunga aur jab aap mere yaadon me aaoge tab main ye nahi chahta,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ki unme sirf meri baatein, aur aapsi jhagde mile.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Mai un yaadon me aapko dekhna chahta hun, aapko sunna chahta hun, aapki baaton pe hasna chahta hun.&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;ol&gt;
&lt;li&gt;After writing this, I read my Google Keep notes and found one para which intrigued me and I started questioning that
it actually written by me or I copied but it is written by me. Although, I have not remembered why and how I wrote
this but this is a good one &lt;em&gt;(my POV)&lt;/em&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;Man ko janjhol raha hun, tatol raha hun,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Sabdoon ki baadh bhi aayi hai,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Ab toh bas sabdoon ki mala he pironi reh gayi hai,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Lekin saamne rakhi ees nacheez ne rok rakhi hai,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Jab dhaara me chhlang lagane jata hun,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Ye mujhe kheech lati hai.&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
</content:encoded><category>journal</category><category>journal</category><category>may</category><author>Anshul Raj Verma</author></item><item><title>Goa Trip</title><link>https://arv-anshul.github.io/blog/2026/goa-trip</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/goa-trip</guid><description>Trip and new experiences with Zyou Team</description><pubDate>Tue, 28 Apr 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;24th April&lt;/h2&gt;
&lt;p&gt;With Pratham and Anurag sir, we moved around 09:15 from Pune guest house. We took the 100km extra long route to see the
scenery of &lt;strong&gt;Mulshi Lake&lt;/strong&gt;. We had Sandwich and Cold Coffee at a restaurant nearby. We reached our rented flat at ~9
o&apos;clock. We checked-in and immediately walked to &lt;strong&gt;Fish Deck&lt;/strong&gt; a nearby restaurant for dinner. After that, we decided to
see the beach which is around 1.5km away. Just after 400m-500m of walking we felt the humidity and sweating it was
disorienting of will to go there but eventually reached and enjoyed the scenery of &lt;strong&gt;Anjuna Beach&lt;/strong&gt;. I called my college
friends in Bhopal who doesn&apos;t know that I was on a trip to Goa. That is intentional because I wanted to surprise them
and flex before them on the group video call. After sitting for some time on the beach, we returned to our flat to bath
and slept.&lt;/p&gt;
&lt;h2&gt;25th April&lt;/h2&gt;
&lt;p&gt;Next day, I woke at 12 noon. Anurag sir has gone for a haircut and we go to &lt;strong&gt;Anjuna Flea Market&lt;/strong&gt; to buy some clothes
which is suitable for this humid weather. We haven&apos;t ate that day until 17 but eventually found a Punjabi restaurant
where I ate Chicken Biryani and Lassi, it was fabulous. Me and Anurag sir ordered the same Hydrabadi Chicken Biryani
each, when the order arrived it was huge we should have ordered only one for both of us. Even then I ate all of my part
but Anurag sir left some of it. Pratham sir is vegetarian so he ate Paneer, Roti and Lassi. Then we go to &lt;strong&gt;Baga Beach&lt;/strong&gt;
which is full of crowd. We stayed there about 10-15 minutes and moved to pick up Aditya sir from &lt;strong&gt;Dabolim Airport&lt;/strong&gt;.
Finally, we shake hands. With Aditya sir onboard we reached our flat to get ready for the &lt;strong&gt;Savara Night Club&lt;/strong&gt; opening.
Manik also came to the flat to pick us.&lt;/p&gt;
&lt;p&gt;It&apos;s my first time at a club. I checked one point in my experiences list after experiencing that I had written some
words for that:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I think, it increased the hearing and lower my thoughts handling capabilities. I am feeling a little dizzy not too
much, its just I am moving faster. It&apos;s like everything seems faster now. Surprisingly, I feel confident and I am not
able to concentrate on my thought for a thought I just do whatever comes first. I gone to washroom and choose the very
first seat and this is seriously not me. This feeling faded away after sometime &lt;em&gt;(I was keeping track of time)&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;While having it I was just thinking one thing, why someone wants this bitter taste constantly to feel unconscious,
there are better alternative.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Around 3AM we reached flat and slept.&lt;/p&gt;
&lt;h2&gt;26th April&lt;/h2&gt;
&lt;p&gt;We had lunch at &lt;strong&gt;Goan Spices&lt;/strong&gt; and came to &lt;strong&gt;Anjuna Beach&lt;/strong&gt; to enjoy the beach and sea. Only Me, Pratham and Aditya sir
bath in the sea, Anurag sir stayed at shore and guard our clothes and phone. We didn&apos;t rest in the sea. We stopped the
waves so that nobody behind us will be able to play with it. After some time I found a ball floating in the sea and then
we started catching and diving with the ball. Another group of boys also joined us in the play. We played it to the
fullest. Then we had dinner at &lt;strong&gt;Fish Deck&lt;/strong&gt;.&lt;/p&gt;
&lt;h2&gt;27th April&lt;/h2&gt;
&lt;p&gt;We had a meeting, so we gone to &lt;strong&gt;Coffee Central&lt;/strong&gt; cafe for that. After that we were wandering around in Flea Market and
around 21 we left.&lt;/p&gt;
&lt;h2&gt;28th April&lt;/h2&gt;
&lt;p&gt;Reached the guesthouse around 9.&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>trip</category><category>zyou</category><author>Anshul Raj Verma</author></item><item><title>How to explain a face from your thoughts?</title><link>https://arv-anshul.github.io/blog/2026/how-to-explain-a-face-from-your-thoughts</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/how-to-explain-a-face-from-your-thoughts</guid><description>I need that sketch artist from crime films. Although this person is not any special, it&apos;s just he stuck into my head since then.</description><pubDate>Thu, 02 Apr 2026 01:19:00 GMT</pubDate><content:encoded>&lt;p&gt;Suddenly at evening (01 April) while enjoying the rain with @Ankit and @Kunal on the hostel&apos;s roof. I stuck on a face in
my mind whom I cannot define to others. I can&apos;t recall his identity. I am certain that he is real and he is a teacher or
similar because he is explaining something and giving a smile.&lt;/p&gt;
&lt;p&gt;Even now while typing these I don&apos;t know who he is, where I have seen him but I am stuck at him. Whenever my mind is
empty, his face comes up. He is smiling. He is speaking something. These expressions of his of 1-2 seconds, keeps
replaying in my mind like a GIF.&lt;/p&gt;
&lt;p&gt;I think I&apos;ve seen him in college or on YouTube, I&apos;m not sure. His face is very clear in my mind but I can&apos;t explain it.&lt;/p&gt;
&lt;p&gt;Right now, I need those sketch artists from crime movies who draw the faces from explanation.&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><author>Anshul Raj Verma</author></item><item><title>April Journal</title><link>https://arv-anshul.github.io/journal/2026/04</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2026/04</guid><description>Weekly Journal by ARV of April 2026</description><pubDate>Wed, 01 Apr 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 14 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Watched movie &lt;strong&gt;Edge Of Tomorrow&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Watched a Netflix show &lt;strong&gt;American Vandal&lt;/strong&gt;, it was amazing, too good. It has been on my watchlist since 2023-01-17,
as recommended by ComicVerse YT channel.&lt;/li&gt;
&lt;li&gt;I also watched couple of episodes watched &lt;strong&gt;The Mentalist&lt;/strong&gt; but it is boring. It isn&apos;t gripping and thrilling as I
expect to be.&lt;/li&gt;
&lt;li&gt;Spotify updated their policy for Developer Access, see &lt;a href=&quot;https://developer.spotify.com/blog/2026-02-06-update-on-developer-access-and-platform-security&quot;&gt;blog&lt;/a&gt;. Now I can&apos;t be able to
maintain my Spotify data through &lt;a href=&quot;https://github.com/arv-anshul/spotyhive&quot;&gt;arv-anshul/spotyhive&lt;/a&gt; repository.&lt;/li&gt;
&lt;li&gt;IDEA: Create a route &lt;em&gt;(because currently it is static)&lt;/em&gt; in the website which can serve a bash file to render the
website gist in the terminal. Similar to &lt;code&gt;curl ysap.sh&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;IDEA: Create a CLI app which can render the &lt;a href=&quot;https://github.com/arv-anshul/resume/blob/main/resume.json&quot;&gt;resume.json&lt;/a&gt; as a Resume in terminal.&lt;/li&gt;
&lt;li&gt;IDEA: Create a program which creates a proper structured notes from YouTube video.&lt;/li&gt;
&lt;li&gt;Had a talk with @Adityaojas and @Manik for the migration. I might move next week.&lt;/li&gt;
&lt;li&gt;Connected with @Araadhay for his new idea.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 15 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Helped CampusX to protect their notes from leaking. They had showed their notes URL in thier video through which
anyone can download it. It was stored in Google Cloud.&lt;/li&gt;
&lt;li&gt;Watched &lt;strong&gt;Shrinking&lt;/strong&gt; Season 3 and an anime Dohedoro.&lt;/li&gt;
&lt;li&gt;Had a meeting with @Araadhay regarding his new OpenClaw and ClawHub related idea.&lt;/li&gt;
&lt;li&gt;Hermes-Agent a lightweight OpenClaw.&lt;/li&gt;
&lt;li&gt;Confirmed the date of migration from Hostel to Pune with @Manik, it is 15th March.&lt;/li&gt;
&lt;li&gt;@Naina wrote a formal invitation for her birthday. It was quite unexpected but I really liked it.&lt;/li&gt;
&lt;li&gt;Had a long day on Saturday because of Scooty servicing (5 hours), gift decision (4 hours), bath.&lt;/li&gt;
&lt;li&gt;Enjoyed at pool party on @Naina birthday party.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 16 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Came to &lt;strong&gt;Baner, Pune&lt;/strong&gt; on 16th at 9 o&apos;clock with 16 hours late train.&lt;/li&gt;
&lt;li&gt;Met with @Manik, @Pratham, and @Anurag at the Guesthouse.&lt;/li&gt;
&lt;li&gt;Visited cousin&apos;s house on Sunday and came back on Monday for work.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 17 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Working from 13 to 21 in office.&lt;/li&gt;
&lt;li&gt;Taking a trip to Goa from Pune.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 18 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Enjoyed Goa from 24th April to 27th April. See the blog on it, &lt;a href=&quot;/blog/goa-trip&quot;&gt;Trip to Goa&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Team had a meeting in Goa.&lt;/li&gt;
&lt;li&gt;We shifted to our flat.&lt;/li&gt;
&lt;li&gt;From now, I will write lesser because for the most of the time I hang around the team and it is not good to journal
them publicly. Instead, I will try to write down my thoughts and experiences in diary.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>april</category><author>Anshul Raj Verma</author></item><item><title>96 by C. Prem Kumar and Govind Vasantha</title><link>https://arv-anshul.github.io/blog/2026/movie-96</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/movie-96</guid><description>A ray of calmness in the moments of chaos. It makes me aware that how much beautiful a love can be. How much beautiful it can be to understand a person you love.</description><pubDate>Tue, 24 Mar 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;These days I am constantly in doubts, not able to think clearly, not able to work on anything. Not able to think
anything. Don&apos;t know how my day goes. Just linger around social media &lt;em&gt;(YouTube, GitHub, Folo)&lt;/em&gt;. Not enjoying anything
music or movie, nothing.&lt;/p&gt;
&lt;p&gt;Then I decided to watch the movie &lt;strong&gt;&quot;96&quot;&lt;/strong&gt; because related content is coming as recommendation on the YouTube home page.&lt;/p&gt;
&lt;p&gt;I think this is a slice-of-life romantic drama film. Although I&apos;ve never get into these emotion deeply, but I&apos;ve
scratched it alone a long time ago. I have been suppressing this emotions for about 5-7 years because I want to
understand it first but it is hard in the current surrounding and environment. So I seek these films and shows like 96,
Past Lives, Meiyazhagan, Dead Poet Society, Gulmohar, etc.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;मेरे लिए वो मूवी प्यारी है जो मेरी आँखों में आँसू ले आए। लेकिन यह मूवी मेरे लिए उससे भी बढ़ के है।&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I have discovered the soulful music of Govind Vasantha and this week (Week 13) I am constantly listening to his
creation. He even composed the music of Meiyazhagan; isn&apos;t it awesome, that loved it without knowing that it is composed
by Govind Vasantha. I would like to thank him to compose these soulful music. I&apos;ve been listening him this whole week
and always will.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;For me, the role of BGM, OST and integrated songs in movies and shows is too important because I&apos;ve discovered some of
my favorites from movies and shows I had watched. I have created multiple playlists and saved albums from those. I
also listen pay attention on them while watching and try to navigate, what are they conveying.&lt;/p&gt;
&lt;/blockquote&gt;
</content:encoded><category>blog</category><category>movie</category><category>thoughts</category><category>emotion</category><author>Anshul Raj Verma</author></item><item><title>Dehradun Trip</title><link>https://arv-anshul.github.io/blog/2026/dehradun-trip</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/dehradun-trip</guid><description>A trip of 3 friends across 3 cities for 4 days on 2 bikes, through 3 kinds of weather—creating infinite memories.</description><pubDate>Wed, 18 Mar 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Its again only us, Anshul, Ankit and Tanu Didi 6 months after Jaipur trip. Dedicating our next 4-5 days to Dehradun
Trip.&lt;/p&gt;
&lt;p&gt;There&apos;s so much happened in between these 6 months.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;I joined my college, made several awesome and fantastic friends.&lt;/li&gt;
&lt;li&gt;Stuck my life between college practicals and assignments.&lt;/li&gt;
&lt;li&gt;Traveled 3 times to home without reservation in train (it should also be called as an experience).&lt;/li&gt;
&lt;li&gt;Took one of the important and hardest decision to drop out of college, so that I can go solo.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;I Shouldn&apos;t Go&lt;/h2&gt;
&lt;p&gt;Trip planning is the responsibility of Ankit and Didi, I just review it and give feedback on it. While the trip is at
its planning stage I was indulged in the process of TC and Ankit is in his semester exams.&lt;/p&gt;
&lt;p&gt;I was having a hard time on how to get along in life now and there is no case to go on a trip. I want to reflect upon
myself alone while Ankit will be on the trip. But it didn&apos;t happen because I am not able to communicate my thoughts.&lt;/p&gt;
&lt;p&gt;Also I have decided to go to next trip with my sister and that is not happening.&lt;/p&gt;
&lt;h2&gt;In the Trip&lt;/h2&gt;
&lt;p&gt;Almost 2 hours before the train to NZM, I was convinced to go on the trip. I packed my couple of clothes and put my
shoes and got ready for the trip because it was the time to not get bored by enjoyment. I forgot the past and lived in
the moment. I sacrificed my past and future to live in the moment.&lt;/p&gt;
&lt;p&gt;Again I don&apos;t have reservation but I bought one general ticket but when the TT checked it isn&apos;t the valid general ticket
as the train was superfast and I&apos;ve taken Mail/Express ticket. The TT told to get the penalty ticket but when it was my
time he was distracted by another and forgot to charge me. Again, I got lucky. (I know this isn&apos;t good but there&apos;s no
choice)&lt;/p&gt;
&lt;h2&gt;Day 01: Awesome Chhota&lt;/h2&gt;
&lt;p&gt;From NZM, we are going to Ankit&apos;s uncle&apos;s place to stay till 21:00 so that we can catch the 23:00 bus to Dehradun from
Anand Nagar ISBT.&lt;/p&gt;
&lt;p&gt;I met an awesome, artistic, creative girl named SHNY and her older sister PRNM. I specially want to talk about SHNY. She
looks very similar to one of Didi&apos;s friend.&lt;/p&gt;
&lt;p&gt;Approx 2 hour after we reached, she brought some paper made stuffs like bag, birthday diary, spray, laptop, and many
things. At first thought she would have made these from YouTube videos but I was totally wrong and it&apos;s amazing that a
girl this small can create these crafts on her own just by looking and observing things :salute:.&lt;/p&gt;
&lt;p&gt;I was astonished by her Laptop, Birthday Diary, Spary Can and I want to demystify each of them and you will also tend to
appreciate her creativity.&lt;/p&gt;
&lt;h3&gt;Birthday Dairy&lt;/h3&gt;
&lt;p&gt;It consists of four pages each saying a sequence of story.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Cover page says &quot;Happy birthday to you&quot;.&lt;/li&gt;
&lt;li&gt;A cutout of cake depicting the celebration.&lt;/li&gt;
&lt;li&gt;A cutout of flower to bring color and happiness in the life.&lt;/li&gt;
&lt;li&gt;Last page stating the smile on the face of the birthday girl.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Laptop&lt;/h3&gt;
&lt;p&gt;Her sister helped her to create this but the most important and nuanced part of this is creation is built by SHNY. The
keypad of the Laptop where anyone of us would just thought to draw the keys but she is different and a nice observer.
She created a spring mechanics by folding the paper for the keys and this detailing is fantastic. The laptop also has
icons of files, folders, YouTube, Settings, etc.&lt;/p&gt;
&lt;h3&gt;Spray Can&lt;/h3&gt;
&lt;p&gt;Once her cousins were playing with some spray and they are not letting her play with it and that&apos;s when she decided to
built it her own. She built it with proper detailing like the Can Cap, Tip, Spray foam.&lt;/p&gt;
&lt;p&gt;She is just awesome and I wish she would do or create something even more awesome things.&lt;/p&gt;
&lt;p&gt;While leaving, she cried out loud but there&apos;s nothing we can do but leave.&lt;/p&gt;
&lt;h2&gt;Day 02: New City, New Experience&lt;/h2&gt;
&lt;p&gt;Its time to explore the city from ground by searching for a good hotel with reasonable price.&lt;/p&gt;
&lt;p&gt;I thought we can find it with the help of Google Maps but it is quite difficult without any guidance and wheels. A auto
driver approached to show some 2-4 hotel with reasonable price in around ₹50. We accepted the offer and after 4 hotels
we reached a reasonably good hotel with affordable price.&lt;/p&gt;
&lt;p&gt;Hotel: Aryan Castle Homestay, Shimla Bypass, Dehradun&lt;/p&gt;
&lt;p&gt;We took the single bedroom at ₹2k for one day stay around 07:30. Gave ₹100 to Saheed Ahmed the auto driver.&lt;/p&gt;
&lt;p&gt;After changing and resting in about 2 hours we came out to search the bike rental shop to rent 1 bike for three of us
which is quite risky. We asked Saheed Bhaiya (Auto Driver) and suggested &quot;UK07 Bike Rental Planet&quot; but at that time it
was closed. So we searched for another on Google Maps, it was 2.5km far, took auto at ₹80 but couldn&apos;t find a right bike
so we fallback to previous bike rental.&lt;/p&gt;
&lt;p&gt;We took &quot;Apache RTR 200cc&quot; for ₹900/day and &quot;Royal Enfield Hunter&quot; for ₹1300/day.&lt;/p&gt;
&lt;p&gt;After a nice list of traveling point from Bike Rental wale Bhaiya, we first moved towards FRI college. It is well known
for its Bollywood film shooting place. After reaching there we came to know that it was closed for tourists for almost 6
months. Without wasting much time we moved towards Tapakeshwar Mandir, we just have to face traffic for couple of
minutes. After pray before Lord Shiva and other Gods, it was the first time we touched flowing water on the trip. It was
so cold and mesmerizing. It was a moment. Although we (everyone there) are busy taking pictures and videos but no-one
not even me tool a moment to live the moment or try to thank the calmness of the flowing water.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I believe, traveling is not capturing the moment instead it is a way to live in the moment by forgetting each and
every of your thoughts and problems.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;It is hard to follow up on this thought because I had already tried it on Jaipur Trip I couldn&apos;t hold it even there. So
I just go with the crowd and did what others are doing.&lt;/p&gt;
&lt;p&gt;After playing enough with slow stream, we ate a little in nearby Dhaaba and moved towards Robber&apos;s Cave (Gucchu Paani).
It also has stream but it was speedy and longer. Also it has small waterfall in the end after 300 meter of walk but we
couldn&apos;t bath because we didn&apos;t plan it and the water was too cold but we walked till the end, it was awesome.&lt;/p&gt;
&lt;p&gt;After enjoying there, we are planning to meet on of Didi&apos;s friend who study in Dehradun. But first we stopped by on
roadside to take some cinematic and photos. In the middle of the shot heavy rain and thunder came due to that we stopped
at nearby bus stop shade. Just after 5-7 minutes to standing, a guy on scooty slipped on the road because he was speedy
and couldn&apos;t control himself on the slippery road. Its good that he was alone on it and with helmet. I think he got a
small injury in his leg. People at the bus stop bring him in the shade and told him to rest till rain stop but after 5-8
minutes he&apos;s gone with his injured leg.&lt;/p&gt;
&lt;p&gt;As the rain slowed down, we also moved and reached hotel fully soaked. The rainwater was traveling from head to
underwear, even the shoes got wet and the cold weather was cherry on the cake. We changed clothes and took some rest.
It&apos;s 7:30, rain has stopped, we are hungry, and Didi&apos;s friend is also up for meetup so we decided to ride again. But
there was a problem I didn&apos;t bring spare shoes as my shoes was soaked, so I wore the bathroom slipper given by the
hotel. If you are worried about Ankit and Didi then do not because they brought three pairs each.&lt;/p&gt;
&lt;p&gt;Didi&apos;s friend was 12KM away from hotel, the weather so cold but it wasn&apos;t raining. We eventually reached and we all sat
for dinner. At the dinner table we discussed whether should we ride to Mussoorie because of this rain I was worried so
much and at the same time rain started again outside. After finishing the dinner the rain stopped, so we quickly moved
towards hotel. We are also searching for shops to buy warm clothes for next day. I was feeling even colder after dinner
on the bike with the slippers.&lt;/p&gt;
&lt;p&gt;We are going to check out from current hotel and take new in Mussoorie to stay at night there but we have one suitcase
which can be quietly cumbersome in the ride. We decided to drop the suitcase at Didi&apos;s friend&apos;s hostel although it might
cost us 24KM more but it was better to leave the suitcase behind.&lt;/p&gt;
&lt;h2&gt;Day 03: Ride up to Mussoorie&lt;/h2&gt;
&lt;p&gt;We woke up at 08 AM, everyone is getting ready one-by-one we planned to check out by 10 AM. Before getting fresh I gone
to check upon the bikes, they look good. While returning the owner of the hotel called me asked when did you checked in
yesterday? I didn&apos;t know. He checked the register and told you did at 07:34 AM and now it is around 08:10 AM which is
more than 23 hours. I was confused because yesterday receptionist told that we can check out by 11:00 AM. But the owner
explained and accepted his mistake and asked for penalty of ₹300 and then we can check out by 10 AM. I got up in the
room and explained the situation. We thought don&apos;t get involved in this, just pay and move.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;We learned a new experience that before check in asked about any penalty and the time of check out, clearly.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;We changed the plan to drop the suitcase to Didi&apos;s friend&apos;s hostel instead we are going to drop it at Bike Rental Shop
which is 800 meters away from our hotel. Now we gear up the Map to Mussoorie on phone and triumph the bikes towards
Mussoorie.&lt;/p&gt;
&lt;p&gt;Took multiple stop while climbing and took awesome pictures. Stopped at a Lord Shiva Temple. We also stopped at a cafe
(Green Valley Cafe) on the roadside for Maggie and Momos and a nice look of view which have climb. After 1.5 hours of
ride we reached the top and now we are looking for Hotel. Just where we stopped a woman approached us and suggested a
hotel to look. We thought start from this if we not like will move to other.&lt;/p&gt;
&lt;p&gt;We parked the bikes just below the hotel, yes below because you have climb almost 50-60 steps to reach the hotel. They
showed two rooms one has no view and one has very nice view. We like the second room which has view so we asked the
charges and for a second I thought what is it, what have I listened does he (owner Nitish Bhaiya) said only ₹3000. I
thought this will be around ₹5k-₹7k because of the view and facilities it has fridge, hair dryer, gas-stove, geyser, and
it was a big enough room. After bargaining we settled down to ₹2,700.&lt;/p&gt;
&lt;p&gt;Hotel: Beachwood, Near Mall Road, Mussoorie&lt;/p&gt;
&lt;p&gt;We were so excited about the room and view. It was too exotic. We take some rest, clicked many pictures, made a funny
video. Then we moved for Dalai Hills and Buddha Temple. Although road was in maintainance and slant, but we ride through
it easily. We reached and park both bikes for ₹100 at paid parking facility.&lt;/p&gt;
&lt;p&gt;You need to climb more than 200 steps to reach the Buddha Statue. Although we reached but I was not feeling well because
of my ear pain. I didn&apos;t enjoy that moment, didn&apos;t took any picture of mine. After stepping down we ate Corn, it was
delicious. Stand by there for heat. Then we moved and reached hotel. Now we are tired, and I am in severe ear pain. I
talked with Dr. Arvind Uncle as insisted by Papa. He told to take pain killer medicine (Zero Dol SP).&lt;/p&gt;
&lt;p&gt;At 08:30 PM, we are ready to go to Mall Road of Mussoorie by walk. We asked the path from Nitish Bhaiya (hotel owner).
Didi and Ankit bought blanket for themselves for ₹200 each and I bought my painkiller. After wandering about 30-45
minutes we rollback to the room and slept.&lt;/p&gt;
&lt;p&gt;At night around 12:30 AM, the electricity gone down and now we worried about our Bikes because it was parked below the
hotel and we couldn&apos;t saw it because of no light. Me and Ankit both are worried and continuously peeking through the
window to see the bikes but couldn&apos;t. Although my pain was vanished by then because of the painkiller. Around 02:30 AM
lights came back, I quickly jump from the bed get near to the window to peek the bikes and they are there with no
hindrance. We all got relief and slept.&lt;/p&gt;
&lt;h2&gt;Day 04: Last Ride to Rishikesh&lt;/h2&gt;
&lt;p&gt;Before check out, we had decided to visit Landour and came till 10 o&apos;clock and check out. The roads to Landour is too
slant, it just there is almost no traffic that&apos;s why I am able to ride it easily, otherwise it would be harder. We
returned before 10 and check out. But before riding to Rishikesh we ordered food at hotel because it was too good to be
true. After having the breakfast we moved. It is even harder to go downhill than riding uphill because you have to
constantly keep your fingers on clutch and break.&lt;/p&gt;
&lt;p&gt;After passing the Dehradun city you will get a very nice highway that&apos;s where I touched 113km. It was terrific and
awesome. After this speed I got overconfident and started overtaking couple of cars and taxis. Once I increased to 50+
and try to overtake and just then a curve came up where I flicker a bit and rubbed into the middle wall of the road but
thankfully I didn&apos;t crash. No one&apos;s got hurt not even me. Just my shoes got damaged which belongs to Ankit. We stopped
nearby and checked if there&apos;s any major damage in the bike but there wasn&apos;t.&lt;/p&gt;
&lt;p&gt;We reached Rishikesh and we need to find a hotel. There is too much traffic and heat. While searching for hotel I lost
Ankit way and stopped and wait till they found a hotel. When got it at ₹2,000. I started moving with Map in my phone and
phone in my shirt&apos;s upper pocket. It took me almost 30-40 minutes to reach hotel. There was too much heat that I have to
take bath, can you believe it? We take rest of 1 hour before exploring Rishikesh.&lt;/p&gt;
&lt;p&gt;I have only one shirt left to wear which is only for warm climate and I got it in Rishikesh. We visited Triveni ghat by
Auto because of the traffic and the decision was actually right. Attend the Ganga Aarti and sang Hanuman Chalisa there.
Then moved towards Ram Jhula but we didn&apos;t walk on it because we are out of time and the bridge was shivering too much
while walking. Then we walked to hotel and slept.&lt;/p&gt;
&lt;h2&gt;Day 05: Trip Hangover&lt;/h2&gt;
&lt;p&gt;We packed and check out before 9 o&apos;clock, we reached bike rental shop just before 11 and returned the bike. Bhaiya asked
have you crashed anywhere but we rejected.&lt;/p&gt;
&lt;p&gt;Now we have 5 hours before our bus to ISBT Kashmere Gate, Delhi. We found a cafe where we ate Aaloo Pratha and sat till
03 PM. Then we took our trolley from bike rental shop and moved to Bus Stand. Got into bus and slept. Then we dinner at
the bus stoppage and reached Delhi on time. We took Cab and gone to NDLS railway station. We waited for 5 hours there in
waiting room.&lt;/p&gt;
&lt;p&gt;Sat on train at 06 AM morning and reached Bhopal on time at 02:20 PM. We took Cab to Dosa shop because hostel has no
food at that time. We ate Dosa and slept.&lt;/p&gt;
&lt;hr /&gt;
&lt;h2&gt;Miscellaneous&lt;/h2&gt;
&lt;p&gt;There are stuffs I wanted to share regarding this trip.&lt;/p&gt;
&lt;h3&gt;An Expense Tracker&lt;/h3&gt;
&lt;p&gt;We are three but only one pays in whole trip and at the end every spends splits and the amount was returned. In Jaipur
trip, I paid all the expense and in this Tanu Didi paid. At first I was not going that&apos;s I thought about creating an
Excel sheet to track our expense. The next day of return I made an Excel sheet, and entered all the expense which was
noted down in Notes app by Ankit.&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;/blog/2026/assets/dehradun-trip-expenses.xlsx&quot;&gt;Dehradun Trip Expenses - Excel Sheet&lt;/a&gt;&lt;/p&gt;
&lt;h3&gt;A Chatting Group&lt;/h3&gt;
&lt;p&gt;It will be very helpful if you create a chatting group for the trip. You can share important common information there.
We have created a group on WhatsApp.&lt;/p&gt;
&lt;h3&gt;Backpack&lt;/h3&gt;
&lt;p&gt;In my opinion, you should only keep the essential things in your backpack also keep it manageable so that you can carry
it easily for long time without fatigue.&lt;/p&gt;
</content:encoded><category>blog</category><category>trip</category><category>thoughts</category><author>Anshul Raj Verma</author></item><item><title>Streaming Mode</title><link>https://arv-anshul.github.io/blog/2026/streaming-mode</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/streaming-mode</guid><description>Stream thyself to reflect upon progress and thoughts.</description><pubDate>Tue, 10 Mar 2026 10:40:00 GMT</pubDate><content:encoded>&lt;p&gt;I have been thinking to stream my study sessions on YouTube and want to post videos of my thoughts and thinking too.&lt;/p&gt;
&lt;p&gt;I like the way &lt;a href=&quot;https://youtube.com/@emmytcnr&quot;&gt;@emmytcnr&lt;/a&gt; share her thoughts in a very concise and simple way, nothing
fancy or flashy just thoughts.&lt;/p&gt;
&lt;p&gt;This way I can also share my thoughts, keep track of my growth, practice English and more.&lt;/p&gt;
&lt;p&gt;There is one thing I&apos;ve to keep in mind that this should be solely to improve myself not to indulge into it. Keep the
videos raw and straight forward so that I don&apos;t spend more time on editing &lt;em&gt;(maybe you can outsource the editing part)&lt;/em&gt;.&lt;/p&gt;
&lt;h2&gt;Testing OBS Studio&lt;/h2&gt;
&lt;p&gt;I have installed OBS Studio software to stream and record with my MacBook Air M1 laptop. There are couple of settings I
have to focus to record videos and following is the best setting I&apos;ve got:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Input Video Resolution:&lt;/strong&gt; 3310x2210 (16:10)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Output Video Resolution:&lt;/strong&gt; 3310x1890 (16:9)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Video Encoder:&lt;/strong&gt; Apple H.264 Hardware&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Bitrate:&lt;/strong&gt; ~8k-12k for Streaming and ~15k-25k for Recording&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Audio:&lt;/strong&gt; 320 Bitrate and 48kHz Frequency&lt;/li&gt;
&lt;/ul&gt;
&lt;blockquote&gt;
&lt;p&gt;YouTube recommend the final video resolution should be of 16:9 but my laptop is of 16:10, that&apos;s why I have modified
the &lt;strong&gt;Output Video Resolution&lt;/strong&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Something to Learn with Code&lt;/h2&gt;
&lt;p&gt;I can also learn some topics to automate the Thumbnail creation &lt;em&gt;not with AI&lt;/em&gt; instead with presets or templates. I can
also explore the field of Instrumental music generation from AI and code.&lt;/p&gt;
&lt;h2&gt;Live Streaming&lt;/h2&gt;
&lt;p&gt;I&apos;ll use live streaming to learn something with focus and determination as I&apos;ll be live it will force me to be on track.&lt;/p&gt;
&lt;p&gt;One thing, I need to keep in mind while live streaming is that to not share any private information. I might need to
restrict the streaming to a certain application windows like Coding Editor, Terminal, Browser like that.&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>youtube</category><author>Anshul Raj Verma</author></item><item><title>March Journal</title><link>https://arv-anshul.github.io/journal/2026/03</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2026/03</guid><description>Weekly Journal by ARV of March 2026</description><pubDate>Sun, 01 Mar 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 10 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Added sitemap in the website.&lt;/li&gt;
&lt;li&gt;I have to get crazy for Rust, so that I can learn it.&lt;/li&gt;
&lt;li&gt;Learned Rust concepts i.e. Traits, Trait Object, Iterator, Type Coercion.&lt;/li&gt;
&lt;li&gt;Created Family Tree data structure with &lt;code&gt;pydantic.BaseModel&lt;/code&gt; in Python.&lt;/li&gt;
&lt;li&gt;Created Justfile recipes to create new content template for the website instead of JavaScript script.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 11 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Tested and started live streaming on YouTube.
&lt;ul&gt;
&lt;li&gt;Wrote a blog named &lt;a href=&quot;/blog/streaming-mode&quot;&gt;Streaming Mode&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;There are some problems I&apos;ve got like:
&lt;ol&gt;
&lt;li&gt;I&apos;m not able to watch the live streaming from my Phone. Why? &lt;em&gt;Not even from the mobile browser.&lt;/em&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;In Rust:
&lt;ul&gt;
&lt;li&gt;How is this &lt;code&gt;Ok()&lt;/code&gt;/&lt;code&gt;Some()&lt;/code&gt; is working instead they should be like &lt;code&gt;Result::Ok()&lt;/code&gt;/&lt;code&gt;Option::Some()&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;We can’t return a Union type in Rust like in python (i.e. &lt;code&gt;ValueError | KeyError&lt;/code&gt;) instead you’ve to use &lt;strong&gt;Dynamic
Dispatch&lt;/strong&gt; like &lt;code&gt;Result&amp;lt;(), Box&amp;lt;dyn std::error:Error&amp;gt;&amp;gt;&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Feeling sick but able pull up mindset to not rest and just sit and learn.&lt;/li&gt;
&lt;li&gt;Gone to trip to Dehradun with @Ankit and @Tanu from 13 March to 19 March.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 12 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Gone to trip to Dehradun with @Ankit and @Tanu from 13 March to 19 March.&lt;/li&gt;
&lt;li&gt;Wrote a blog on &lt;a href=&quot;/blog/dehradun-trip&quot;&gt;Dehradun Trip&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Created Expense Tracker Excel Sheet for the recent trip.&lt;/li&gt;
&lt;li&gt;Watched movie &lt;strong&gt;Dhurandhar 2&lt;/strong&gt; in cinema hall on 21 March, in 08 AM slot and returned to hostel around 01 PM.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 13 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Watched movie &lt;strong&gt;“96”&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;@Pratham called to tell me to get ready.&lt;/li&gt;
&lt;li&gt;@Anurag’s birthday party on 26 March.&lt;/li&gt;
&lt;li&gt;Explored Burn framework again.&lt;/li&gt;
&lt;li&gt;Read a nice small article from Kagi Smallweb.
&lt;a href=&quot;https://tldr.bearblog.dev/if-it-doesnt-add-it-subtracts&quot;&gt;If it doesn’t add, it subtracts&lt;/a&gt;. This article clearly show
my philosophy of attaining/owning lesser materials/things in my life. I am totally happy with my 2 years old clothes
or 4 years old shoes. If, it is satisfying my need then it isn’t worth replacing or just bringing new one for the
sake of having a newer one.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>march</category><author>Anshul Raj Verma</author></item><item><title>Sit Down and Ask</title><link>https://arv-anshul.github.io/blog/2026/sit-down-and-ask</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/sit-down-and-ask</guid><description>Why don&apos;t you sit down and take a breath and think about why are you running?</description><pubDate>Thu, 19 Feb 2026 00:40:00 GMT</pubDate><content:encoded>&lt;p&gt;Come sit down beside me and stay a while. Ask a question to yourself, Why were you walking, climbing, or running?&lt;/p&gt;
&lt;p&gt;Now think about one of your closest and ask the same to him/her. If both have similar not if same answer then just take
a moment and don&apos;t do anything just sit and sit, nothing else. Maybe see your surroundings, people, dogs, sky, or even a
blank wall. Just sit and think nothing, you may find relief.&lt;/p&gt;
&lt;p&gt;I&apos;ve done that this noon but the same as it was written instead I was listening to &lt;strong&gt;Phoebe Bridgers&lt;/strong&gt; on headphone and
walking to BHEL Ground. I got there and clicked some pictures of trees, flowers, cattles and surrounding.&lt;/p&gt;
&lt;p&gt;It was just a escape from loneliness and lone learner. I am skeptical about writing this as I don&apos;t think this is a
right thing to do I am writing my feel and sharing freely where anyone can read it. I feel frightened.&lt;/p&gt;
&lt;p&gt;Hahaha... Where I was started and see where I am now. This happens all the time. I deviate.&lt;/p&gt;
&lt;p&gt;I deviate from my routine, projects, studying, calls, almost everything.&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><author>Anshul Raj Verma</author></item><item><title>SSH with Bitwarden</title><link>https://arv-anshul.github.io/blog/2026/ssh-with-bitwarden</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/ssh-with-bitwarden</guid><description>Manage your SSH keys with Bitwarden.</description><pubDate>Sun, 15 Feb 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I have switched to SSH from HTTPS for GitHub about two years ago. And that introduced me to the term &lt;strong&gt;Secure Shell
(SSH)&lt;/strong&gt;. Although, even now I don&apos;t fully understand it but I&apos;ve got a little gist of it.&lt;/p&gt;
&lt;p&gt;SSH encrypts your data before transferring it to the server with the generated keys and when the server transfers you
the data only the private key is able to decrypt the data.&lt;/p&gt;
&lt;h2&gt;Manage SSH with Bitwarden&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Generate new SSH key:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;ssh-keygen&lt;/span&gt;&lt;span&gt; -t&lt;/span&gt;&lt;span&gt; ed25519&lt;/span&gt;&lt;span&gt; -C&lt;/span&gt;&lt;span&gt; &quot;email@example.com&quot;&lt;/span&gt;&lt;span&gt; -f&lt;/span&gt;&lt;span&gt; &quot;~/.ssh/new-ssh&quot;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;The command generates two files&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;~/.ssh/new-ssh&lt;/code&gt;: Contains the PRIVATE KEY. &lt;em&gt;&lt;strong&gt;DO NOT SHARE THIS.&lt;/strong&gt;&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;~/.ssh/new-ssh.pub&lt;/code&gt;: Contains you public key.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;In Bitwarden desktop app, create new SSH Key &amp;gt; Save &amp;gt; Edit &amp;gt; Import the content of &lt;code&gt;~/.ssh/new-ssh&lt;/code&gt; in Private Key
field. The Public Key and Fingerprint field will gets update automatically.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Again in Bitwarden, go to Settings &amp;gt; Check &quot;Enable SSH agent&quot;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Add the Bitwarden socket file path in your config (&lt;code&gt;.bashrc&lt;/code&gt; or &lt;code&gt;.zshrc&lt;/code&gt;) file. Then, restart your terminal.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;# For Linux/MacOS&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;export&lt;/span&gt;&lt;span&gt; SSH_AUTH_SOCK&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;&lt;/span&gt;&lt;span&gt;$HOME&lt;/span&gt;&lt;span&gt;/.bitwarden-ssh-agent.sock&quot;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Now, delete the &lt;code&gt;~/.ssh/new-ssh&lt;/code&gt; file. After this you only have the &lt;code&gt;~/.ssh/new-ssh.pub&lt;/code&gt; file.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;rm&lt;/span&gt;&lt;span&gt; ~/.ssh/new-ssh&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Add the Public Key (content of &lt;code&gt;~/.ssh/new-ssh.pub&lt;/code&gt;) in your GitHub account.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Now create &lt;code&gt;~/.ssh/config&lt;/code&gt; file to add the host configuration.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;HostName&lt;/span&gt;&lt;span&gt; github.com&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt; User&lt;/span&gt;&lt;span&gt; git&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt; PreferredAuthentications&lt;/span&gt;&lt;span&gt; publickey&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt; IdentityFile&lt;/span&gt;&lt;span&gt; ~/.ssh/new-ssh&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt; IdentitiesOnly&lt;/span&gt;&lt;span&gt; yes&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Check where your config works?&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;ssh&lt;/span&gt;&lt;span&gt; -T&lt;/span&gt;&lt;span&gt; git@github.com&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Clone GitHub repo like:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;git&lt;/span&gt;&lt;span&gt; clone&lt;/span&gt;&lt;span&gt; git@github.com:user/repo&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;How Does Above Config Better?&lt;/h3&gt;
&lt;p&gt;It is better because the Private Key (&lt;code&gt;~/.ssh/new-ssh&lt;/code&gt; file) is not on your system, it is safely and securely encrypted
in Bitwarden and your tools are able to access it from Bitwarden SSH Agent. You may check it whether the Bitwarden SSH
Agent is running or not?&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;ssh-add&lt;/span&gt;&lt;span&gt; -L&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Also your SSH is always available in Bitwarden, you don&apos;t need to create new you reset your system. Just copy it from
Bitwarden.&lt;/p&gt;
&lt;h2&gt;&lt;code&gt;Host&lt;/code&gt; And &lt;code&gt;HostName&lt;/code&gt; In &lt;code&gt;~/.ssh/config&lt;/code&gt;&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;From &lt;code&gt;gemini-3-pro&lt;/code&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Think of your &lt;code&gt;~/.ssh/config&lt;/code&gt; file like the Contacts app on your phone.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;Host&lt;/code&gt;: The Nickname you give the contact (e.g., &quot;Mom&quot;). This is what you type.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;HostName&lt;/code&gt;: The actual Phone Number (e.g., 555-0199). This is where the call actually goes.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Modify the above &lt;code&gt;~/.ssh/config&lt;/code&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;Host&lt;/span&gt;&lt;span&gt; gh&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  HostName&lt;/span&gt;&lt;span&gt; github.com&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  User&lt;/span&gt;&lt;span&gt; git&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  PreferredAuthentications&lt;/span&gt;&lt;span&gt; publickey&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  IdentityFile&lt;/span&gt;&lt;span&gt; ~/.ssh/new-ssh&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  IdentitiesOnly&lt;/span&gt;&lt;span&gt; yes&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Now you verify your SSH connection like:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;ssh&lt;/span&gt;&lt;span&gt; -T&lt;/span&gt;&lt;span&gt; gh&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Or, clone GitHub repo:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;git&lt;/span&gt;&lt;span&gt; clone&lt;/span&gt;&lt;span&gt; gh:user/repo&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;Here the &lt;code&gt;gh&lt;/code&gt; works as the alias for &lt;code&gt;git@github.com&lt;/code&gt;&lt;/p&gt;
&lt;/blockquote&gt;
</content:encoded><category>blog</category><category>terminal</category><category>security</category><author>Anshul Raj Verma</author></item><item><title>February Journal</title><link>https://arv-anshul.github.io/journal/2026/02</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2026/02</guid><description>Weekly Journal by ARV of February 2026</description><pubDate>Sun, 01 Feb 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 06 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Talked with @Manik about office relocation in Pune.&lt;/li&gt;
&lt;li&gt;Came to Hostel in Bhopal on 2026-02-01.&lt;/li&gt;
&lt;li&gt;Discussing the Transfer Certificate and busy in college for this.&lt;/li&gt;
&lt;li&gt;I will stick with Astro implementation of the website. Its fun and learn to build it.
&lt;ul&gt;
&lt;li&gt;Integrated some of cool and important things in my website i.e. RSS, Open Graph Images, Favicon, SEO, and Sitemap.&lt;/li&gt;
&lt;li&gt;I had a very confusing experience with trailing slashes in Astro application.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;End semester exam of @Ankit is ongoing.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 07 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Had a conversation on call with @Adityaojas for TC, office relocation, and future.&lt;/li&gt;
&lt;li&gt;Almost migrated the main website to Astro.
&lt;ul&gt;
&lt;li&gt;Renamed the &lt;code&gt;v2&lt;/code&gt; repo to &lt;code&gt;website-astro&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Migrating the diary repository.
&lt;ul&gt;
&lt;li&gt;Will convert &lt;code&gt;docs/page/pages&lt;/code&gt; to blog as they are not so distinct.&lt;/li&gt;
&lt;li&gt;All routes has their own OG Image.&lt;/li&gt;
&lt;li&gt;Resume is serving at &lt;code&gt;/resume&lt;/code&gt; route.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Reiterated over Account Statement EDA notebook.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;IDEA:&lt;/strong&gt; Create a notebook where you can see your browser history analysed either by LLMs or EDA.&lt;/li&gt;
&lt;li&gt;Using &lt;a href=&quot;https://rumdl.dev&quot;&gt;&lt;code&gt;rumdl&lt;/code&gt;&lt;/a&gt; for Markdown linting and formatting in website codebase.&lt;/li&gt;
&lt;li&gt;Tried to deploy the &lt;code&gt;website-fumadocs&lt;/code&gt; repository on GitHub Pages but couldn’t as I didn’t found any reference. Also,
I don’t want to dig into this, now. :(&lt;/li&gt;
&lt;li&gt;Moved the &lt;code&gt;website-astro&lt;/code&gt; repository to main &lt;code&gt;arv-anshul.github.io&lt;/code&gt; repository.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 08 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Synced SSH keys with Bitwanden and configured developer accounts with BitWarden’s SSH Agent. Also wrote a blog
&lt;a href=&quot;https://blog/ssh-with-bitwarden&quot;&gt;”SSH with Bitwarden”&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Added search feature in website with &lt;a href=&quot;https://pagefind.app&quot;&gt;Pagefind&lt;/a&gt;. Built it with Antigravity editor.&lt;/li&gt;
&lt;li&gt;Taking Audio Course by HuggingFace.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 09 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Worked on Syllabus Helper project.&lt;/li&gt;
&lt;li&gt;Added notes on some unmaintained repositories:
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/diary&quot;&gt;arv-anshul/diary&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/campusx-learning&quot;&gt;arv-anshul/campusx-learning&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;New Biome and Ultracite update messed my linting and formatting of my website repository.&lt;/li&gt;
&lt;li&gt;Using song in my Alarm to break my sleep in the morning as I do not pause the song in the middle.&lt;/li&gt;
&lt;li&gt;Watched India vs West Indies Super 8 match of T20 World Cup. India won.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>february</category><author>Anshul Raj Verma</author></item><item><title>The feeling at Platform No. 4</title><link>https://arv-anshul.github.io/blog/2026/the-feeling-at-platform-no-4</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/the-feeling-at-platform-no-4</guid><description>At Patna Junction, going Bhopal. Time around 22-23 PM.</description><pubDate>Sat, 31 Jan 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;This sensation is very horrifying. As I sit at Platform No. 4 of Patna Junction. I remember when tell myself that I love
being alone but this moment is feels different.&lt;/p&gt;
&lt;p&gt;Currently I am mostly thinking about the dropout process of College.&lt;/p&gt;
&lt;p&gt;They are constantly telling me that is too early to decide, you may regret about this decision in future.&lt;/p&gt;
&lt;p&gt;But as I had analyzed the pros and cons of the College I came to the decision of dropout.&lt;/p&gt;
&lt;p&gt;In past one and half month I have explored so much Burn, Rust, Astro, Fumadocs and more.&lt;/p&gt;
&lt;p&gt;I am also thinking about the train reservation and TT as I don&apos;t have one, just a general ticket. I need a good rest and
sleep.&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><author>Anshul Raj Verma</author></item><item><title>Docs Conventions</title><link>https://arv-anshul.github.io/blog/2026/docs-conventions</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/docs-conventions</guid><description>Conventions by me, to me, for my docs.</description><pubDate>Mon, 26 Jan 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I have zeal to follow best possible convention which is fool proof and best, yes best. I know this is a psychological
problem than a good habit.&lt;/p&gt;
&lt;p&gt;Due to this I am not able to ship fast, I got strangled with best practice and conventions like proper formatting,
lifting, error handling, and more.&lt;/p&gt;
&lt;p&gt;Although this helps me to learn a better specs but this blocks me from doing the things faster. I chase the best option
out there which is not good I guess.&lt;/p&gt;
&lt;p&gt;For this I generally try to observe and tackle most of the by using opinionated tools like formatter and linter or by
defining conventions for myself.&lt;/p&gt;
&lt;h2&gt;So What Are Docs Conventions?&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Schema for every JSON and YAML files present in data directory.&lt;/li&gt;
&lt;li&gt;Frontmatter schema for each and every doc file.&lt;/li&gt;
&lt;li&gt;Manage UI components.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Important pages in my docs:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;/&lt;/code&gt;: Home page&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/projects&lt;/code&gt;: Page to display all projects.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/about&lt;/code&gt;: To display all about me and my experiences.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/friends&lt;/code&gt;:&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/movies&lt;/code&gt;:&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/music&lt;/code&gt;:&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/resume&lt;/code&gt;:&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/blog&lt;/code&gt;:&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/diary&lt;/code&gt;:&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/diary/page&lt;/code&gt;:&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/diary/journal&lt;/code&gt;:&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>github</category><author>Anshul Raj Verma</author></item><item><title>Dotfiles Management</title><link>https://arv-anshul.github.io/blog/2026/dotfiles-management</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/dotfiles-management</guid><description>Manage your dotfiles effectively.</description><pubDate>Fri, 23 Jan 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;This will be the full refactor of my &lt;a href=&quot;https://github.com/arv-anshul/dotfiles&quot;&gt;arv-anshul/dotfiles&lt;/a&gt; repository from file structure to speak effective configs.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;In repository, main config directory will &lt;code&gt;./home&lt;/code&gt; instead of the root of the repository.&lt;/li&gt;
&lt;li&gt;Use &lt;a href=&quot;https://wiki.archlinux.org/title/XDG_Base_Directory&quot;&gt;XDG Base Directories&lt;/a&gt; to comply with opinionated convention.&lt;/li&gt;
&lt;li&gt;Move the main &lt;code&gt;.zshrc&lt;/code&gt; to &lt;code&gt;$XDG_CONFIG_HOME/zsh&lt;/code&gt; directory instead of &lt;code&gt;$HOME&lt;/code&gt; directory. Also keep one at
&lt;code&gt;$HOME/.zshrc&lt;/code&gt; but for private or system level use case.&lt;/li&gt;
&lt;li&gt;Use AI to get suggestions around best practices and tools.&lt;/li&gt;
&lt;li&gt;Use comments to explain configs to recall later.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Currently, using tools such as:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;[&lt;code&gt;chezmoi&lt;/code&gt;]: Dotfiles manager.&lt;/li&gt;
&lt;li&gt;[&lt;code&gt;brew&lt;/code&gt;]: Package manager for macOS.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;&lt;strong&gt;Some other which I will consider in future:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;[&lt;code&gt;mise&lt;/code&gt;]: Lets you manage envs, tools, scripts, and more for a project.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://podman.io&quot;&gt;Podman&lt;/a&gt;: Alternative to Docker.&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>github</category><author>Anshul Raj Verma</author></item><item><title>Migrate Docs to Fumadocs</title><link>https://arv-anshul.github.io/blog/2026/migrate-docs-to-fumadocs</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/migrate-docs-to-fumadocs</guid><description>Thoughts on migrating my docs to Fumadocs.</description><pubDate>Tue, 20 Jan 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I&apos;ve been planning to migrate my docs from &lt;a href=&quot;https://mkdocs.org&quot;&gt;&lt;strong&gt;Mkdocs&lt;/strong&gt;&lt;/a&gt; (with
&lt;a href=&quot;https://squidfunk.github.io/mkdocs-material&quot;&gt;Material Theme&lt;/a&gt;) to other JavaScript based framework. At first I
discovered &lt;a href=&quot;https://mintlify.com&quot;&gt;Mintlify&lt;/a&gt; but later found that it is not an OSS, so I had to dump it. Later from
&lt;a href=&quot;https://openalternative.co&quot;&gt;openalternative.co&lt;/a&gt;, I found out about &lt;a href=&quot;https://fumadocs.dev&quot;&gt;Fumadocs&lt;/a&gt; and its fabulous,
perfect. This is what I need.&lt;/p&gt;
&lt;p&gt;So I did some digging and it is complex to understand for some new eyes. I&apos;ve tried all templates Next.js, React Router,
and Tanstack Start. I found the Tanstack Start template easy by File structure and Syntax so I stick with it.&lt;/p&gt;
&lt;h2&gt;My Requirements for the Docs&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Supports MDX.&lt;/li&gt;
&lt;li&gt;A top navigation bar. It will be better if it also shows icon.&lt;/li&gt;
&lt;li&gt;Sidebar navigation with icon &lt;em&gt;(if specified)&lt;/em&gt;.&lt;/li&gt;
&lt;li&gt;Autogenerated Social cards &lt;em&gt;(only if specified, default otherwise)&lt;/em&gt;.&lt;/li&gt;
&lt;li&gt;Supports UI components paradigm.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Previous Migration - &lt;code&gt;diary/v1.0.0&lt;/code&gt;&lt;/h2&gt;
&lt;p&gt;Previously, I&apos;ve migrated my diary from Obsidian to MkDocs and it went well. I&apos;ve stick with it until, its time to try
something new, something better.&lt;/p&gt;
&lt;h2&gt;Fumadocs Learning&lt;/h2&gt;
&lt;p&gt;I have chosen the Tanstack Start template for my case due to its simplicity.&lt;/p&gt;
&lt;h3&gt;File Structure&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;./&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; content/&lt;/span&gt;&lt;span&gt;  # Contains all the .mdx files&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; data/&lt;/span&gt;&lt;span&gt;  # Put extra data in structured format to load into app easily&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   └──&lt;/span&gt;&lt;span&gt; info.yaml&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; public/&lt;/span&gt;&lt;span&gt;  # Contains important public assets&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   └──&lt;/span&gt;&lt;span&gt; favicon.ico&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; src/&lt;/span&gt;&lt;span&gt;  # Main source directory&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   ├──&lt;/span&gt;&lt;span&gt; components/&lt;/span&gt;&lt;span&gt;  # Contains UI components&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   └──&lt;/span&gt;&lt;span&gt; not-found.tsx&lt;/span&gt;&lt;span&gt;  # For 404 pages&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   ├──&lt;/span&gt;&lt;span&gt; lib/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   ├──&lt;/span&gt;&lt;span&gt; layout.shared.tsx&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   └──&lt;/span&gt;&lt;span&gt; source.ts&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   ├──&lt;/span&gt;&lt;span&gt; routes/&lt;/span&gt;&lt;span&gt;  # Contains route specific files&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   ├──&lt;/span&gt;&lt;span&gt; api/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   └──&lt;/span&gt;&lt;span&gt; search.ts&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   ├──&lt;/span&gt;&lt;span&gt; docs/&lt;/span&gt;&lt;span&gt;  # Related to /docs route&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   └──&lt;/span&gt;&lt;span&gt; $&lt;/span&gt;&lt;span&gt;.tsx&lt;/span&gt;&lt;span&gt;  # Define layout for &quot;/docs/$&quot; pages&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   ├──&lt;/span&gt;&lt;span&gt; __root.tsx&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   └──&lt;/span&gt;&lt;span&gt; index.tsx&lt;/span&gt;&lt;span&gt;  # Define layout for &quot;/&quot; route&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   ├──&lt;/span&gt;&lt;span&gt; types/&lt;/span&gt;&lt;span&gt;  # Define custom types for TypeScript&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   └──&lt;/span&gt;&lt;span&gt; yaml.d.ts&lt;/span&gt;&lt;span&gt;  # Just to load YAML files from /data directory&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   ├──&lt;/span&gt;&lt;span&gt; styles/&lt;/span&gt;&lt;span&gt;  # CSS files&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   │&lt;/span&gt;&lt;span&gt;   └──&lt;/span&gt;&lt;span&gt; app.css&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   ├──&lt;/span&gt;&lt;span&gt; routeTree.gen.ts&lt;/span&gt;&lt;span&gt;  # Autogenerated by Fumadocs&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;│&lt;/span&gt;&lt;span&gt;   └──&lt;/span&gt;&lt;span&gt; router.tsx&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; README.md&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; biome.json&lt;/span&gt;&lt;span&gt;  # Linter and Formatter&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; bun.lock&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; cli.json&lt;/span&gt;&lt;span&gt;  # Specify the Base-UI components&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; package.json&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; source.config.ts&lt;/span&gt;&lt;span&gt;  # Define other docs collections i.e. /blog, /projects&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; tsconfig.json&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;└──&lt;/span&gt;&lt;span&gt; vite.config.ts&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Define New Collections&lt;/h3&gt;
&lt;p&gt;You can define new collections other than &lt;code&gt;/docs&lt;/code&gt; like &lt;code&gt;/blog&lt;/code&gt; or &lt;code&gt;/project&lt;/code&gt;. You may read the
&lt;a href=&quot;https://fumadocs.dev/blog/make-a-blog&quot;&gt;Fumadocs blog&lt;/a&gt; for better understanding.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Define &lt;code&gt;blogPosts&lt;/code&gt; collections in &lt;code&gt;source.config.ts&lt;/code&gt; file:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;defineCollections&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;frontmatterSchema&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;fumadocs-mdx/config&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;z&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;zod&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;export&lt;/span&gt;&lt;span&gt; const&lt;/span&gt;&lt;span&gt; blogPosts&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;defineCollections&lt;/span&gt;&lt;span&gt;({&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  type:&lt;/span&gt;&lt;span&gt; &quot;doc&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  dir:&lt;/span&gt;&lt;span&gt; &quot;content/blog&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  schema:&lt;/span&gt;&lt;span&gt; frontmatterSchema&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;extend&lt;/span&gt;&lt;span&gt;({&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    author:&lt;/span&gt;&lt;span&gt; z&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;enum&lt;/span&gt;&lt;span&gt;([&lt;/span&gt;&lt;span&gt;&quot;Anshul Raj Verma&quot;&lt;/span&gt;&lt;span&gt;] &lt;/span&gt;&lt;span&gt;as&lt;/span&gt;&lt;span&gt; const&lt;/span&gt;&lt;span&gt;),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    date:&lt;/span&gt;&lt;span&gt; z&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;date&lt;/span&gt;&lt;span&gt;(),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    description:&lt;/span&gt;&lt;span&gt; z&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;string&lt;/span&gt;&lt;span&gt;(),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    icon:&lt;/span&gt;&lt;span&gt; z&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;string&lt;/span&gt;&lt;span&gt;(),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  }),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;});&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Parse the output collection in &lt;code&gt;lib/source.ts&lt;/code&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;blogPosts&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;fumadocs-mdx:collections/server&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;loader&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;fumadocs-core/source&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;lucideIconsPlugin&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;fumadocs-core/source/lucide-icons&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;toFumadocsSource&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;fumadocs-mdx/runtime/server&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;export&lt;/span&gt;&lt;span&gt; const&lt;/span&gt;&lt;span&gt; blogPostSource&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;loader&lt;/span&gt;&lt;span&gt;({&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  source:&lt;/span&gt;&lt;span&gt; toFumadocsSource&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;blogPosts&lt;/span&gt;&lt;span&gt;, []),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  baseUrl:&lt;/span&gt;&lt;span&gt; &quot;/blog&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  plugins:&lt;/span&gt;&lt;span&gt; [&lt;/span&gt;&lt;span&gt;lucideIconsPlugin&lt;/span&gt;&lt;span&gt;()],&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;});&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Define the &lt;code&gt;/blog&lt;/code&gt; page layout at &lt;code&gt;src/routes/blog/index.tsx&lt;/code&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;createFileRoute&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;Link&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;@tanstack/react-router&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;blogPostSource&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;@/lib/source&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;export&lt;/span&gt;&lt;span&gt; const&lt;/span&gt;&lt;span&gt; Route&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;createFileRoute&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;&quot;/blog/&quot;&lt;/span&gt;&lt;span&gt;)({&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  component:&lt;/span&gt;&lt;span&gt; RouteComponent&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;});&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;function&lt;/span&gt;&lt;span&gt; RouteComponent&lt;/span&gt;&lt;span&gt;() {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  const&lt;/span&gt;&lt;span&gt; posts&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;blogPostSource&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;getPages&lt;/span&gt;&lt;span&gt;();&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  return&lt;/span&gt;&lt;span&gt; (&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    &amp;lt;&lt;/span&gt;&lt;span&gt;main&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;flex-1 w-full max-w-350 mx-auto px-4 py-8&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;      &amp;lt;&lt;/span&gt;&lt;span&gt;h1&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;text-4xl font-bold mb-8&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;Latest Blog Posts&lt;/span&gt;&lt;span&gt;&amp;lt;/&lt;/span&gt;&lt;span&gt;h1&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;      &amp;lt;&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;grid gap-6 md:grid-cols-2 lg:grid-cols-3&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        {&lt;/span&gt;&lt;span&gt;posts&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;map&lt;/span&gt;&lt;span&gt;((&lt;/span&gt;&lt;span&gt;post&lt;/span&gt;&lt;span&gt;) &lt;/span&gt;&lt;span&gt;=&amp;gt;&lt;/span&gt;&lt;span&gt; (&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;          &amp;lt;&lt;/span&gt;&lt;span&gt;Link&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            key&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;post&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;url&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            to&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;post&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;url&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;block bg-fd-secondary rounded-lg shadow-md overflow-hidden p-6&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;          &amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            &amp;lt;&lt;/span&gt;&lt;span&gt;h2&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;text-xl font-semibold mb-2&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;post&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;data&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;title&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;span&gt;&amp;lt;/&lt;/span&gt;&lt;span&gt;h2&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            &amp;lt;&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;mb-4&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;post&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;data&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;description&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;span&gt;&amp;lt;/&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;          &amp;lt;/&lt;/span&gt;&lt;span&gt;Link&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        ))&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;      &amp;lt;/&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    &amp;lt;/&lt;/span&gt;&lt;span&gt;main&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  );&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Now, create &lt;code&gt;src/routes/blog/$.tsx&lt;/code&gt; to render the blog contents.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; browserCollections&lt;/span&gt;&lt;span&gt; from&lt;/span&gt;&lt;span&gt; &quot;fumadocs-mdx:collections/browser&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;createFileRoute&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;Link&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;notFound&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;@tanstack/react-router&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;createServerFn&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;@tanstack/react-start&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;useFumadocsLoader&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;fumadocs-core/source/client&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;InlineTOC&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;fumadocs-ui/components/inline-toc&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; defaultMdxComponents&lt;/span&gt;&lt;span&gt; from&lt;/span&gt;&lt;span&gt; &quot;fumadocs-ui/mdx&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; { &lt;/span&gt;&lt;span&gt;blogPostSource&lt;/span&gt;&lt;span&gt; } &lt;/span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; &quot;@/lib/source&quot;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;export&lt;/span&gt;&lt;span&gt; const&lt;/span&gt;&lt;span&gt; Route&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;createFileRoute&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;&quot;/blog/$&quot;&lt;/span&gt;&lt;span&gt;)({&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  component:&lt;/span&gt;&lt;span&gt; BlogPage&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  loader&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;span&gt; async&lt;/span&gt;&lt;span&gt; ({ &lt;/span&gt;&lt;span&gt;params&lt;/span&gt;&lt;span&gt; }) &lt;/span&gt;&lt;span&gt;=&amp;gt;&lt;/span&gt;&lt;span&gt; {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    const&lt;/span&gt;&lt;span&gt; slugs&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;params&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;_splat&lt;/span&gt;&lt;span&gt;?.&lt;/span&gt;&lt;span&gt;split&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;&quot;/&quot;&lt;/span&gt;&lt;span&gt;) ?? [];&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    const&lt;/span&gt;&lt;span&gt; data&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;await&lt;/span&gt;&lt;span&gt; serverLoader&lt;/span&gt;&lt;span&gt;({ &lt;/span&gt;&lt;span&gt;data:&lt;/span&gt;&lt;span&gt; slugs&lt;/span&gt;&lt;span&gt; });&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    await&lt;/span&gt;&lt;span&gt; clientLoader&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;preload&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;data&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;path&lt;/span&gt;&lt;span&gt;);&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    return&lt;/span&gt;&lt;span&gt; data&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  },&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;});&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;const&lt;/span&gt;&lt;span&gt; serverLoader&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;createServerFn&lt;/span&gt;&lt;span&gt;({&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  method:&lt;/span&gt;&lt;span&gt; &quot;GET&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;})&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  .&lt;/span&gt;&lt;span&gt;inputValidator&lt;/span&gt;&lt;span&gt;((&lt;/span&gt;&lt;span&gt;slugs&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;string&lt;/span&gt;&lt;span&gt;[]) &lt;/span&gt;&lt;span&gt;=&amp;gt;&lt;/span&gt;&lt;span&gt; slugs&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  .&lt;/span&gt;&lt;span&gt;handler&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;async&lt;/span&gt;&lt;span&gt; ({ &lt;/span&gt;&lt;span&gt;data&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;slugs&lt;/span&gt;&lt;span&gt; }) &lt;/span&gt;&lt;span&gt;=&amp;gt;&lt;/span&gt;&lt;span&gt; {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    const&lt;/span&gt;&lt;span&gt; page&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;blogPostSource&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;getPage&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;slugs&lt;/span&gt;&lt;span&gt;);&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    if&lt;/span&gt;&lt;span&gt; (!&lt;/span&gt;&lt;span&gt;page&lt;/span&gt;&lt;span&gt;) &lt;/span&gt;&lt;span&gt;throw&lt;/span&gt;&lt;span&gt; notFound&lt;/span&gt;&lt;span&gt;();&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    return&lt;/span&gt;&lt;span&gt; {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;      path:&lt;/span&gt;&lt;span&gt; page&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;path&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    };&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  });&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;const&lt;/span&gt;&lt;span&gt; clientLoader&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;browserCollections&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;blogPosts&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;createClientLoader&lt;/span&gt;&lt;span&gt;({&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  component&lt;/span&gt;&lt;span&gt;({ &lt;/span&gt;&lt;span&gt;toc&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;frontmatter&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;default&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;MDX&lt;/span&gt;&lt;span&gt; }) {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    return&lt;/span&gt;&lt;span&gt; (&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;      &amp;lt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        &amp;lt;&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;w-full max-w-350 mx-auto px-4 py-12 rounded-xl border md:px-8&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;          &amp;lt;&lt;/span&gt;&lt;span&gt;h1&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;mb-2 text-3xl font-bold&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;frontmatter&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;title&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;span&gt;&amp;lt;/&lt;/span&gt;&lt;span&gt;h1&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;          &amp;lt;&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;mb-4 text-fd-muted-foreground&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;frontmatter&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;description&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;span&gt;&amp;lt;/&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;          &amp;lt;&lt;/span&gt;&lt;span&gt;Link&lt;/span&gt;&lt;span&gt; to&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;/blog&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;Back&lt;/span&gt;&lt;span&gt;&amp;lt;/&lt;/span&gt;&lt;span&gt;Link&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        &amp;lt;/&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        &amp;lt;&lt;/span&gt;&lt;span&gt;article&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;w-full max-w-350 mx-auto flex flex-col px-4 py-8&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;          &amp;lt;&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;prose min-w-0&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            &amp;lt;&lt;/span&gt;&lt;span&gt;InlineTOC&lt;/span&gt;&lt;span&gt; items&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;toc&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;span&gt; /&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            &amp;lt;&lt;/span&gt;&lt;span&gt;MDX&lt;/span&gt;&lt;span&gt; components&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;defaultMdxComponents&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;span&gt; /&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;          &amp;lt;/&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;          &amp;lt;&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;flex flex-col gap-4 text-sm&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            &amp;lt;&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;              &amp;lt;&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;mb-1 text-fd-muted-foreground&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;Written by&lt;/span&gt;&lt;span&gt;&amp;lt;/&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;              &amp;lt;&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;font-medium&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;frontmatter&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;author&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;span&gt;&amp;lt;/&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            &amp;lt;/&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            &amp;lt;&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;              &amp;lt;&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;mb-1 text-sm text-fd-muted-foreground&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;At&lt;/span&gt;&lt;span&gt;&amp;lt;/&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;              &amp;lt;&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt; className&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;font-medium&quot;&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;{new&lt;/span&gt;&lt;span&gt; Date&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;frontmatter&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;date&lt;/span&gt;&lt;span&gt;).&lt;/span&gt;&lt;span&gt;toDateString&lt;/span&gt;&lt;span&gt;()&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;span&gt;&amp;lt;/&lt;/span&gt;&lt;span&gt;p&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            &amp;lt;/&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;          &amp;lt;/&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        &amp;lt;/&lt;/span&gt;&lt;span&gt;article&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;      &amp;lt;/&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    );&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  },&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;});&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;function&lt;/span&gt;&lt;span&gt; BlogPage&lt;/span&gt;&lt;span&gt;() {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  const&lt;/span&gt;&lt;span&gt; data&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;useFumadocsLoader&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;Route&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;useLoaderData&lt;/span&gt;&lt;span&gt;());&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  return&lt;/span&gt;&lt;span&gt; &amp;lt;&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;clientLoader&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;useContent&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;data&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;path&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;span&gt;&amp;lt;/&lt;/span&gt;&lt;span&gt;div&lt;/span&gt;&lt;span&gt;&amp;gt;&lt;/span&gt;&lt;span&gt;;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;export&lt;/span&gt;&lt;span&gt; function&lt;/span&gt;&lt;span&gt; generateStaticParams&lt;/span&gt;&lt;span&gt;(): { &lt;/span&gt;&lt;span&gt;slug&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;string&lt;/span&gt;&lt;span&gt; }[] {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  return&lt;/span&gt;&lt;span&gt; blogPostSource&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;getPages&lt;/span&gt;&lt;span&gt;().&lt;/span&gt;&lt;span&gt;map&lt;/span&gt;&lt;span&gt;((&lt;/span&gt;&lt;span&gt;page&lt;/span&gt;&lt;span&gt;) &lt;/span&gt;&lt;span&gt;=&amp;gt;&lt;/span&gt;&lt;span&gt; ({&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    slug:&lt;/span&gt;&lt;span&gt; page&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;slugs&lt;/span&gt;&lt;span&gt;[&lt;/span&gt;&lt;span&gt;0&lt;/span&gt;&lt;span&gt;],&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  }));&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Write your blogs at &lt;code&gt;content/blog/my-blog.mdx&lt;/code&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Integrate Social Cards&lt;/h3&gt;
&lt;p&gt;I will use &lt;a href=&quot;https://takumi.kane.tw&quot;&gt;Takumi&lt;/a&gt; for Social Cards generation &lt;em&gt;(because its written in Rust)&lt;/em&gt;. You may refer
to &lt;a href=&quot;https://www.fumadocs.dev/docs/integrations/takumi&quot;&gt;Fumadocs Takumi integration docs&lt;/a&gt;.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;How to configure the Takumi OG image generation in my Tanstack Start + vite (SSR) app? I am using bun.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Icons in Docs&lt;/h3&gt;
&lt;p&gt;By default, Fumadocs gives support to Lucide Icons which is nice but I also want Simple Icons for brand icons.&lt;/p&gt;
&lt;p&gt;For this I have to create
&lt;a href=&quot;https://github.com/fuma-nama/fumadocs/blob/main/packages/core/src/source/plugins/lucide-icons.ts&quot;&gt;custom plugin&lt;/a&gt;.&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>website</category><category>github</category><author>Anshul Raj Verma</author></item><item><title>Follow a Routine</title><link>https://arv-anshul.github.io/blog/2026/follow-a-routine</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/follow-a-routine</guid><description>You should follow a routine to keep track of your behavior and personality.</description><pubDate>Fri, 16 Jan 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Everyone has 24 hours in their days, but when you follow a routine you optimize thyself not only for that day in fact
for the others too.&lt;/p&gt;
&lt;p&gt;As I am watching @emmytcnr &lt;a href=&quot;https://youtube.com/@emmytcnr&quot;&gt;YT channel&lt;/a&gt; I feel I should create a routine. Not so strict,
instead it will be like instructions to for me to what to do in the time you&apos;ve got in that day.&lt;/p&gt;
&lt;p&gt;It will be available in Google Notes with checkboxes.&lt;/p&gt;
&lt;p&gt;The routine majorly consists of the things which are important and repetitive I want to do in a day. This will help to
keep track of them:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Reminders like wake up time, exercises, time of sleep, book reading, coding timing, etc.&lt;/li&gt;
&lt;li&gt;Things you may want to prioritize.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;This will help me to evaluate myself on daily basis, also makes me more disciplined.&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><author>Anshul Raj Verma</author></item><item><title>GitHub Account Flagged</title><link>https://arv-anshul.github.io/blog/2026/github-account-flagged</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/github-account-flagged</guid><description>My GitHub account got flagged with no disclaimer, so I reached to GitHub Support team.</description><pubDate>Wed, 14 Jan 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;On 08 January &lt;em&gt;exact&lt;/em&gt; 08 AM, I got a mail to reset my GitHub account due to suspicious activity. I am like what, how,
who? But I certainly did as being said. And I thought that&apos;s it and it&apos;s all good now.&lt;/p&gt;
&lt;p&gt;At same evening I raised an issue in other&apos;s public repo. I thought it was a success but when I get back into that
repo&apos;s issue tab I am not able to see my issue. So I thought it might be got missed &lt;em&gt;(which didn&apos;t happened before)&lt;/em&gt;, I
may raise another but I thought I should check once to confirm.&lt;/p&gt;
&lt;p&gt;Somehow, I figured out that it was opened but none can see it except me. Then my mind tricks, it may have happened by
that today&apos;s suspension.&lt;/p&gt;
&lt;p&gt;I go to mails&apos; Trash tabs &lt;em&gt;(because I deleted that email)&lt;/em&gt;, restores it and read it again from start word-by-word. I
checked account&apos;s security logs there nothing suspicious expect that suspend, unsuspend, and oauth key terminations.&lt;/p&gt;
&lt;p&gt;I reached to GitHub Support and raised a ticket to resolve this issue.&lt;/p&gt;
&lt;p&gt;They said to create new account and use it. I was like what, why? What did I done wrong? Tell me.&lt;/p&gt;
&lt;p&gt;They said the GitHub System suspected that my account is used distribute malware. :salute:&lt;/p&gt;
&lt;p&gt;I insisted and told to review my account manually, there is nothing suspicious. This account is important for me. I
haven&apos;t created another because I know I haven&apos;t done anything wrong.&lt;/p&gt;
&lt;p&gt;They said it was your arv-anshul/dotfiles repository which is convicted and you should either delete it or privatize it.
So I changed the visibility of the repository to PRIVATE.&lt;/p&gt;
&lt;p&gt;And hence, the support team cleared the restrictions from my account. :finally:&lt;/p&gt;
&lt;p&gt;Thanks.&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;/blog/2026/assets/github-support-emails.pdf&quot;&gt;See email thread&lt;/a&gt;&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>github</category><author>Anshul Raj Verma</author></item><item><title>Review of 2025</title><link>https://arv-anshul.github.io/blog/2026/review-of-2025</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/review-of-2025</guid><description>I have written some major event happened with me in 2025.</description><pubDate>Tue, 13 Jan 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I have already did the &lt;a href=&quot;/journal/2025/00&quot;&gt;review of my 2025 Journal&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;But that&apos;s the review of my Journal there are many things I haven&apos;t mentioned or even thought to write about. The things
like How I got into the College, and most important &lt;em&gt;(I even once thought about writing this)&lt;/em&gt; The Roller Coaster Life
in Bhopal.&lt;/p&gt;
&lt;p&gt;Below are some points which I am able to remember while writing about Year 2025:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Ignoring LeapX internship in favor of 12th board exams, also not preparing for the exams.&lt;/li&gt;
&lt;li&gt;12th board exams completed in February and barely passed.&lt;/li&gt;
&lt;li&gt;After the news, got panicked and started searching for college, even though before the result I don&apos;t want to go.&lt;/li&gt;
&lt;li&gt;Eventually, I got admission via @Tanu with hell lot of drama, thrill, and suspense.&lt;/li&gt;
&lt;li&gt;@Ankit also took admission there and now it&apos;s time to move to Bhopal.&lt;/li&gt;
&lt;li&gt;Me and @Ankit both decided to move there one month prior of starting of new classes. Took train reservation of 3rd
July.&lt;/li&gt;
&lt;li&gt;That first month in Bhopal is fun and exciting, there is no pressure we are just waiting for college.&lt;/li&gt;
&lt;li&gt;Then the college started and we made some very, very, very, good friends @Anurag, @Himanshu, @Diwas, @Ankush, and
@Krish. We just met about a few weeks ago and its feel like that we are friends from childhood :).&lt;/li&gt;
&lt;li&gt;As I was started to learn what and how does the college teach, its getting clearer that, this is not what I am here
for. They are just revising the school routine &lt;em&gt;(even stricter)&lt;/em&gt;. &lt;strong&gt;&quot;आसमान से गिरा, खजूर में अटका&quot;&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;There are many incident and story from the college and would not be good for this, so skipping.&lt;/li&gt;
&lt;li&gt;As the time passes by, it&apos;s getting more prominent I am not going to survive this college environment. Whatever I&apos;ve
learned so far is not going evolve. Because I am not practicing, not learning, not even able to extract time for it
and this frustrate me.&lt;/li&gt;
&lt;li&gt;I discussed this situation with my parents and they said if you don&apos;t like it, don&apos;t do it, but make sure you are
not making any mistakes.&lt;/li&gt;
&lt;li&gt;At the end on 23rd December, I came home and confirmed that I am not going to dropping out and will learn and study
from other sources.&lt;/li&gt;
&lt;li&gt;Currently, I am in my house, on my bed, under the blanket, time: 09:55 AM.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;What&apos;s Left&lt;/h2&gt;
&lt;p&gt;I will be writing these article soon to complete the review of 2025 and link them here:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;The Roller Coaster Life in Bhopal 2025&lt;/li&gt;
&lt;li&gt;The Roller Coaster Life in College 2025&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>blog</category><category>journal</category><category>review</category><author>Anshul Raj Verma</author></item><item><title>Podcast #3 by Arunesh Don</title><link>https://arv-anshul.github.io/blog/2026/podcast-by-arunesh-don</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2026/podcast-by-arunesh-don</guid><description>These are my thoughts while a youtube video published by Arunesh Don.</description><pubDate>Mon, 05 Jan 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;YouTube randomly recommended me this video (&lt;a href=&quot;https://youtu.be/r-X74mUSUWY&quot;&gt;Podcast #3 by Arunesh Don&lt;/a&gt;) on my PC and it
instantly caught my attention (because of its channel name) but at that time I saved it into Watch Later playlist. Now
on 05 January at 02:30 AM I watched it. While watching I got some thoughts and also thought to email them to the Creator
but couldn&apos;t so I am writing it at evening.&lt;/p&gt;
&lt;h2&gt;Thoughts&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Beginning:&lt;/strong&gt; At start, I was thinking that this is just another video of an Indian student doing random shit with
their friends. And it was, if you watch the video half way.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Observations:&lt;/strong&gt; I observed the narrator’s command in his surrounding, its not as usual as I thought it would be. In
fact he has very grip on them the boys don’t argue, disgust, unnecessary laughing or making fun out of words which can
happen many times in my case/scenario.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Surroundings:&lt;/strong&gt; I assume that the room in the video is of narrator’s and I have to say it is full of a mess but it
has very motivating, inspiring, rebellious AURA too. Because the hostel room belongs to a B. Tech. student but it has
geographical maps, motivational posters, and a poster written “SLAVE?” on it.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Interruption:&lt;/strong&gt; There was an interruption in the conversation which were having by someone who needs to do some
photo-copy print. At first, he denied and told them to come after 30 minutes but eventually did the work. And in that
process there was a guy who entered the room and get to his bed &lt;em&gt;(I assumed)&lt;/em&gt; to do something but the narrator
instructed that guy “Don’t you read the instructions on the door?”. Then that guy instantly get out of the room and
knock the door and enters &lt;em&gt;(that’s what I observe)&lt;/em&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Ending:&lt;/strong&gt; In the end, there were almost two to four sentences which hits me and I also agree with them.
&lt;ol&gt;
&lt;li&gt;While criticizing be a dominant, rigid, strict, confident person also maintain eye contact but while appreciation
be a wise, gentle, clam person.&lt;/li&gt;
&lt;li&gt;Agar jo tu aaj hai, aur wahi cheez tu kal bhi follow karega to log tujhe predict kar lenge.&lt;/li&gt;
&lt;li&gt;Don&apos;t be only a lovable person, be a dominant one too.&lt;/li&gt;
&lt;li&gt;more...&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;More insights on Arunesh&lt;/h2&gt;
&lt;p&gt;After the video finished, I started looking for his email id in channel&apos;s about section couldn&apos;t found it. Instead I
came to know about that his channel has almost 280+ videos which are from multiple topics like motivation, fraud
complains, criticism, etc. &lt;em&gt;(which is very bold, IMO)&lt;/em&gt;. His videos focuses on self improvement and society improvement.
He is completely on different level, he is blunt and straight forward :saluting_face:.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Although, I&apos;ve got his email from one of his video &lt;em&gt;(mobile no. too)&lt;/em&gt; but I want to prepare to send an email.&lt;/p&gt;
&lt;p&gt;Will watch his other videos specially his podcast series.&lt;/p&gt;
&lt;/blockquote&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>person</category><author>Anshul Raj Verma</author></item><item><title>January Journal</title><link>https://arv-anshul.github.io/journal/2026/01</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2026/01</guid><description>Weekly Journal by ARV of January 202</description><pubDate>Thu, 01 Jan 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 01 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Came home on 23 December.&lt;/li&gt;
&lt;li&gt;Learning and exploring CNNs concepts like Object recognition, object detection. Also recalling fundamentals like
filters, channels, padding, pooling, etc.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;IDEA:&lt;/strong&gt; A CV project for student attendance using Object detection technique from video input.&lt;/li&gt;
&lt;li&gt;Explored Burn and actually understood something &lt;em&gt;(but not much)&lt;/em&gt;.
&lt;ul&gt;
&lt;li&gt;Wrote couple of lines and able to build a pipeline to train a simple NN model with Iris dataset.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Performed cleanup in:
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;GitHub Stars:&lt;/strong&gt; Removed dead, un-useful (personally) repositories.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Folo RSS:&lt;/strong&gt; Replaced some &lt;code&gt;rsshub://&lt;/code&gt; feeds with open-source maintained projects like
&lt;a href=&quot;https://rss-bridge.org/bridge01/&quot;&gt;RSSBridge&lt;/a&gt;,
&lt;a href=&quot;https://github.com/mshibanami/GitHubTrendingRSS&quot;&gt;GitHubTrendingRSS&lt;/a&gt;. Also added rss feeds.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Hero Hockey India League 2026&lt;/strong&gt; is streaming for free on YouTube 😉.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 02 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Disabled Prettier for &lt;code&gt;dprint&lt;/code&gt; in Zed editor.
&lt;ul&gt;
&lt;li&gt;The dprint extension in Zed is not maintained wisely as the language configuration is not full featured. The
maintainer copied the configs of biome-zed extension’s config.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;I stumble upon a very nice video on &lt;a href=&quot;https://youtu.be/WgPbbWmnXJ8&quot;&gt;Object Detection by YOLOv8&lt;/a&gt; by “Murtaza Workshop”
YouTube channel. Now I can easily work with YOLO models and can build some CV projects.&lt;/li&gt;
&lt;li&gt;Thinking of creating content or documenting my learning journey or my projects on YouTube. That’s why I installed
&lt;strong&gt;OBS Studio&lt;/strong&gt; to record and stream videos.
&lt;ul&gt;
&lt;li&gt;Requested for live streaming on my YouTbe account. Let’s see how it goes?&lt;/li&gt;
&lt;li&gt;First I will start non-face cam live sessions, only audio.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;I sometime write the Journal in &lt;strong&gt;Raycast Notes&lt;/strong&gt; so the sentences might become present tense as I am writing and
thinking/doing at same time or going to do.&lt;/li&gt;
&lt;li&gt;There’s a &lt;code&gt;/blog&lt;/code&gt; in main website which I use for technical notes and references. Now, I want to write my thoughts,
random small thoughts &lt;em&gt;(if I get time for it)&lt;/em&gt;. So I’ll use new &lt;code&gt;/diary/page&lt;/code&gt; endpoint for that.
&lt;ul&gt;
&lt;li&gt;I am tweaking the &lt;code&gt;/blog&lt;/code&gt; for better visibility or for no reason.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Updated and fixed Zed editor VS Code Dark Modern theme. Put it in my dotfiles.&lt;/li&gt;
&lt;li&gt;I got suspended by GitHub in the morning and just after automatically resumed, but why? I don’t know. Although I got
an email about it but there is no clarification. They just instructed to reset the password.
&lt;ul&gt;
&lt;li&gt;Now, my hosted websites (&lt;a href=&quot;https://arv-anshul.github.io&quot;&gt;arv-anshul.github.io&lt;/a&gt;) are not working.&lt;/li&gt;
&lt;li&gt;I am able to commit into my repositories and raised an issue in other repository successfully.&lt;/li&gt;
&lt;li&gt;My issues are not visible in public, checked from incognito.&lt;/li&gt;
&lt;li&gt;I have created a new ticket (&lt;a href=&quot;https://support.github.com/ticket/personal/0/3999489&quot;&gt;#3999489&lt;/a&gt;) at GitHub Support on
2026-01-08T23:29:00.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Successfully, configured &lt;code&gt;mdformat&lt;/code&gt; in &lt;code&gt;arv-anshul/diary&lt;/code&gt; repository to format the Markdown files as expected.
&lt;ul&gt;
&lt;li&gt;Not able to do so for &lt;code&gt;arv-anshul/arv-anshul.github.io&lt;/code&gt; repository due the formatter&apos;s behavior of replacing
&lt;code&gt;&amp;amp;nbsp;&lt;/code&gt; (like HTML tokens) with corresponding UTF-8 character, which I don&apos;t want. There is no option to disable
it.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;SG Pipers&lt;/strong&gt; won Hero Hockey India League (Women) tournament and I&apos;m supporting them ;).&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 03 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Amazing video on &lt;a href=&quot;https://youtu.be/uwZqEvssHpk&quot;&gt;&lt;strong&gt;Model Distillation for Query Intent Classification&lt;/strong&gt;&lt;/a&gt;. He doesn’t
distill any LLM or SLM instead a simple-small NN using the data generated by GPT 3.5 model.&lt;/li&gt;
&lt;li&gt;Wrote a new page &lt;a href=&quot;/blog/review-of-2025&quot;&gt;&lt;strong&gt;Review of 2025&lt;/strong&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Explored codebase of &lt;a href=&quot;https://github.com/presenton/presenton&quot;&gt;Presenton&lt;/a&gt;, to learn how to create an AI to generate or
edit PPTX documents. And I have to say there is a lot going on not only in Python (Backend) side in fact on
TypeScript (Frontend) side too. I want to review it once more soon.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;IDEA:&lt;/strong&gt; A CLI which fetches release notes of provided GitHub repositories and displays the notes in terminal.
&lt;ul&gt;
&lt;li&gt;Now I am learning Rust programming through this.&lt;/li&gt;
&lt;li&gt;Check &lt;a href=&quot;https://github.com/arv-anshul/thrust/tree/main/projects/rlog&quot;&gt;&lt;code&gt;rlog&lt;/code&gt;&lt;/a&gt; in &lt;code&gt;arv-anshul/thrust&lt;/code&gt; repository.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Oooh! Got the full access of my GitHub account. Support assisted to privatize to delete the
&lt;a href=&quot;https://github.com/arv-anshul/dotfiles&quot;&gt;arv-anshul/dotfiles&lt;/a&gt; repository, I changed the visibility to PRIVATE. See
&lt;a href=&quot;/blog/github-account-flagged&quot;&gt;diary page&lt;/a&gt; to know in detail.&lt;/li&gt;
&lt;li&gt;Ordered Google Arcade gifts. I got a T-Shirt, a Water Bottle, some Magnetic stickers, and an Arcade Stickers Sheet.
&lt;ul&gt;
&lt;li&gt;Although, I may have been gotten some more but I got distracted by Jaipur trip and then College.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Wrote a new page &lt;a href=&quot;/blog/follow-a-routine&quot;&gt;&lt;strong&gt;Follow a Routine&lt;/strong&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;I am planning to migrate my website (from &lt;code&gt;mkdocs-material&lt;/code&gt;) to some other framework maybe Mintlify, Astro, etc.
First I&apos;ll do &lt;code&gt;arv-anshul/diary&lt;/code&gt; then eventually (if I like it) migrate &lt;code&gt;arv-anshul/arv-anshul.github.io&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 04 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Continued learning Rust from &lt;code&gt;rlog&lt;/code&gt; project.&lt;/li&gt;
&lt;li&gt;Working on the work given by @Sarvesh.&lt;/li&gt;
&lt;li&gt;Explored &lt;a href=&quot;https://fumdocs.dev&quot;&gt;Fumadocs&lt;/a&gt; for personal docs migration alternative.
&lt;ul&gt;
&lt;li&gt;It is quite intriguing but hard to figure out what’s happening in the files. All the functions are scattered, but
now able to navigate. I know they are in there but with new eyes it&apos;s hard to figure out.&lt;/li&gt;
&lt;li&gt;Read page &lt;a href=&quot;/blog/migrate-docs-to-fumadocs&quot;&gt;Migrate Docs to Fumadocs&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Installed Zorin OS on home laptop (DELL) it is working fine for now, but the laptop’s display is too bad to stare,
not good as Mac’s.&lt;/li&gt;
&lt;li&gt;Store SSH Keys in BitWarden.&lt;/li&gt;
&lt;li&gt;Used LocalSend for file transferring between Phone and Mac.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;IDEA:&lt;/strong&gt; Create a web app (specially static web app &lt;em&gt;if possible&lt;/em&gt;) to convert a photo into passport sized photo and
the convert it into A4 size PDF for printing.&lt;/li&gt;
&lt;li&gt;Updated dotfiles. See page &lt;a href=&quot;/blog/dotfiles-management&quot;&gt;Dotfiles Management&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Came Patna for JEE test of @Akansha.&lt;/li&gt;
&lt;li&gt;Stayed in Patna for three days (24 Jan to 26 Jan).&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 05 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Kalinga Lancers&lt;/strong&gt; won HIL tournament. I supported them ;)&lt;/li&gt;
&lt;li&gt;My priorities:
&lt;ul&gt;
&lt;li&gt;Website&lt;/li&gt;
&lt;li&gt;Learn the Burn framework&lt;/li&gt;
&lt;li&gt;Excel Deep Learning&lt;/li&gt;
&lt;li&gt;Improve the &lt;code&gt;yt-watch-history&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Or new project.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Worked on website migration (Fumadocs + Tanstack Start + Vite + Bun). Currently I am not very confident to migrate.&lt;/li&gt;
&lt;li&gt;Trying to book train ticket to return with @Himanshu.&lt;/li&gt;
&lt;li&gt;Trying Astro to create the website from scratch. I got some progress with it and I am liking it, planning to stick
with it.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>january</category><author>Anshul Raj Verma</author></item><item><title>Journey of 2025</title><link>https://arv-anshul.github.io/journal/2025/00</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/00</guid><description>Summarizing the Journey of 2025 from the Journal</description><pubDate>Wed, 31 Dec 2025 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;At the end of the year, I wrote this so that one can get a summary what have I mainly done throughout the year on
monthly basis. I haven&apos;t mentioned all the moments from the Journal only whom I found important.&lt;/p&gt;
&lt;h2&gt;&lt;a href=&quot;./01.md&quot;&gt;January&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; BERT, Keras 3, HF Transformer, Fine-tuning, LaTeX, Journal Summarizer, LaTex, Resume, Hockey&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Explored finetuning the &lt;strong&gt;BERT models&lt;/strong&gt; with PyTorch and HuggingFace Transformer libraries with efficient methods like
PEFT, LORA, etc.&lt;/li&gt;
&lt;li&gt;Created the &lt;strong&gt;Journal Summarizer&lt;/strong&gt; in Marimo for this diary repo.&lt;/li&gt;
&lt;li&gt;Worked with LaTeX and related tools to create a pipeline for resume management.&lt;/li&gt;
&lt;li&gt;Got interested in &lt;strong&gt;Hockey&lt;/strong&gt; (from &lt;em&gt;Hockey India League&lt;/em&gt;) and created a web scraping project which scrapes HIL matches
data from the official website.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;a href=&quot;./02.md&quot;&gt;February&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; Kaggle Courses, Reels, AI Agent, Job Applier Agent, Browser Use, Kunkun&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;After reading the journal I just came to know that I scrolled &lt;strong&gt;REELS&lt;/strong&gt; for procrastination :WoOoW:&lt;/li&gt;
&lt;li&gt;Meet with @Sagar for a &lt;strong&gt;Job Applier AI Agent&lt;/strong&gt; with Browser Use.&lt;/li&gt;
&lt;li&gt;Enrolled in &lt;strong&gt;Agents Course&lt;/strong&gt; by &lt;em&gt;Hugging Face&lt;/em&gt; and &lt;strong&gt;Intro to LanGraph&lt;/strong&gt; by &lt;em&gt;LangChain&lt;/em&gt;.&lt;/li&gt;
&lt;li&gt;Contributed in &lt;strong&gt;Kunkun&lt;/strong&gt; project but now there is almost no development ongoing.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;a href=&quot;./03.md&quot;&gt;March&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; Coding Hero, LangGraph Studio, RAG, unsloth-ai, Opik&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Learning &lt;strong&gt;LLM Agents&lt;/strong&gt; creation with LangGraph also learning related concept like RAG, few-shot-prompting, etc.&lt;/li&gt;
&lt;li&gt;Came to know about &lt;strong&gt;unsloth-ai&lt;/strong&gt; for easy and efficient LLM finetuning.&lt;/li&gt;
&lt;li&gt;Contacted with &lt;strong&gt;LeapX.ai&lt;/strong&gt; and restart the work with them but the split happened.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;a href=&quot;./04.md&quot;&gt;April&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; Rust for ML, RSS, Folo, Post Generator, Cousin Wedding&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Explored &lt;strong&gt;Rust ecosystem&lt;/strong&gt; for Data Science and ML.&lt;/li&gt;
&lt;li&gt;Found &lt;strong&gt;Folo&lt;/strong&gt; app for RSS Feed reader.&lt;/li&gt;
&lt;li&gt;Worked on new idea by @Aditya &lt;strong&gt;Post Generator&lt;/strong&gt; for Linkedin but dumped.&lt;/li&gt;
&lt;li&gt;Took break for &lt;strong&gt;cousin wedding&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;a href=&quot;./05.md&quot;&gt;May&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; spotyhive, ty, College&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Created a program to fetch and store my &lt;strong&gt;Spotify&lt;/strong&gt; Data like Playlist and Album data.&lt;/li&gt;
&lt;li&gt;ty: new Python type checker by &lt;strong&gt;Astral&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Got busy in finding &lt;strong&gt;College&lt;/strong&gt; after passing 12th.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;a href=&quot;./06.md&quot;&gt;June&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; College&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Got &lt;strong&gt;admission in LNCT Bhopal&lt;/strong&gt; in B. Tech. (CSE/DS) course.&lt;/li&gt;
&lt;li&gt;Did nothing as I was busy in &lt;strong&gt;College and stuff&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;a href=&quot;./07.md&quot;&gt;July&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; College, Typst, @Araadhay, Infina Research, Password Manager, BitWarden&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Moved to Bhopal&lt;/strong&gt; for College.&lt;/li&gt;
&lt;li&gt;Helped @Araadhay in his &lt;strong&gt;Infina Research&lt;/strong&gt; project.&lt;/li&gt;
&lt;li&gt;Started using &lt;strong&gt;BitWarden&lt;/strong&gt; for password management.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;a href=&quot;./08.md&quot;&gt;August&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; Google Arcade Program, Typst, Jaipur Trip, College, College Orientation Program&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Joined into &lt;strong&gt;Google Arcade Program&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Migrated to &lt;strong&gt;Typst&lt;/strong&gt; for Resume management.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Jaipur Trip&lt;/strong&gt; with @Ankit and @Tanu.&lt;/li&gt;
&lt;li&gt;College is started by &lt;strong&gt;25th August&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;a href=&quot;./09.md&quot;&gt;September&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; Google One, MCP, Google Jules, Gravatar, j178/prek, Zyou SDK&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Claimed &lt;strong&gt;Google One&lt;/strong&gt; plan for students for 12 months.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Deleted useless repositories&lt;/strong&gt; from GitHub account.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;a href=&quot;./10.md&quot;&gt;October&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; EDA, Diwali, Chhath Puja, Burn&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Performed &lt;strong&gt;EDA&lt;/strong&gt; on Online Transaction data.&lt;/li&gt;
&lt;li&gt;After giving the MidSem-1 Exam came &lt;strong&gt;Home&lt;/strong&gt; in Chhath Puja.&lt;/li&gt;
&lt;li&gt;Wanted to learn &lt;strong&gt;Burn&lt;/strong&gt; framework.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;a href=&quot;./11.md&quot;&gt;November&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; Zensical, College&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Zensical&lt;/strong&gt; is now replacement of Material for MkDocs.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Trapped in College&lt;/strong&gt; works so there is no entry.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;a href=&quot;./12.md&quot;&gt;December&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Keywords:&lt;/strong&gt; Helium, College, Exams, Liberation Notes&lt;/p&gt;
&lt;h3&gt;Summary&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Installed &lt;strong&gt;Helium&lt;/strong&gt; browser.&lt;/li&gt;
&lt;li&gt;Came &lt;strong&gt;Home&lt;/strong&gt; after MidSem-2.&lt;/li&gt;
&lt;li&gt;Being &lt;strong&gt;liberated from College&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>journal</category><category>journal</category><category>review</category><author>Anshul Raj Verma</author></item><item><title>Liberation Notes</title><link>https://arv-anshul.github.io/blog/2025/liberation-notes</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2025/liberation-notes</guid><description>My liberation notes.</description><pubDate>Wed, 17 Dec 2025 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I have been stuck in deciding whether should I pursue my Graduation or drop from it for Self-Study. It is like
mood-swings, one moment I think about dropping out and another I thought, should I really because I can do many thing
with my friends, even though college education doesn&apos;t gives me much?&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Pursue Graduation&lt;/th&gt;
&lt;th&gt;Self-Study&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&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;Make more good friends&lt;/td&gt;
&lt;td&gt;You are all responsible for any consequences&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Make organic connections with interactions&lt;/td&gt;
&lt;td&gt;You will be on yourself, no one is there to tell you what is good right.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Do something crazy with friends (first they need to teach themself)&lt;/td&gt;
&lt;td&gt;Be discipline and learn alone&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Student benefits (Github, Google, etc.)&lt;/td&gt;
&lt;td&gt;You can create something good everyday/everyweek&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;The degree and placement cushion after 4 years&lt;/td&gt;
&lt;td&gt;You can learn and explore new things everyday/everyweek&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2&gt;Things I Wanted to Learn and Explore&lt;/h2&gt;
&lt;h3&gt;Data Science and GenAI&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Deep Learning&lt;/li&gt;
&lt;li&gt;Transformers and LLMs
&lt;ul&gt;
&lt;li&gt;Working&lt;/li&gt;
&lt;li&gt;Fine Tunning (LoRA, QLoRA, etc.)&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;MLOps&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Advance&lt;/strong&gt; GenAI frameworks and concepts (LangGraph, MCP, AI Agents)&lt;/li&gt;
&lt;li&gt;Tools like Prefect, DataLakes (DuckLake, DataBricks, DeltaLake, LakeTower),&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;more...&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;RUST programming language
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://docs.rs/axum&quot;&gt;Axum&lt;/a&gt;: API development in Rust &lt;em&gt;(Try both, learn one)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://docs.rs/actix&quot;&gt;Actix&lt;/a&gt;: API development in Rust&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://burn.dev&quot;&gt;Burn&lt;/a&gt;: Deep Learning framework in Rust&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;GO programming language
&lt;ul&gt;
&lt;li&gt;API development in Go&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Typst
&lt;ul&gt;
&lt;li&gt;Thumbnail or Card with a certain ratio creation with Typst. Something like
&lt;a href=&quot;https://og-playground.vercel.app&quot;&gt;OG Image Playground&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Extra&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;How to write story?&lt;/li&gt;
&lt;li&gt;How to film a scene?&lt;/li&gt;
&lt;li&gt;How to take photos?&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Future Plans&lt;/h2&gt;
</content:encoded><category>blog</category><category>thoughts</category><author>Anshul Raj Verma</author></item><item><title>December Journal</title><link>https://arv-anshul.github.io/journal/2025/12</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/12</guid><description>Weekly Journal by ARV of December 2025</description><pubDate>Mon, 01 Dec 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 49 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Install &lt;a href=&quot;https://helium.computer&quot;&gt;Helium&lt;/a&gt; browser as the data of ARC&apos;s data erased while doing some testing.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 50 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Late for entry.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 51 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Busy in exams.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 52 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Came Home after MidSem-2 on 23 December.&lt;/li&gt;
&lt;li&gt;It&apos;s decided that I can take DROPOUT now, I can be get out of the DILEMMA. So, need to follow and update the
&lt;a href=&quot;/blog/liberation-notes&quot;&gt;Liberation Notes&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>december</category><author>Anshul Raj Verma</author></item><item><title>November Journal</title><link>https://arv-anshul.github.io/journal/2025/11</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/11</guid><description>Weekly Journal by ARV of November 2025</description><pubDate>Sat, 01 Nov 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 45 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;MkDocs is now deprecated and the maintainers are building Zensical. See the
&lt;a href=&quot;https://squidfunk.github.io/mkdocs-material/blog/2025/11/05/zensical/&quot;&gt;blog&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Doing very less and distracted. Busy in College study and work.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 46 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Late for entry.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 47 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Late for entry.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 48 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Late for entry.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>november</category><author>Anshul Raj Verma</author></item><item><title>October Journal</title><link>https://arv-anshul.github.io/journal/2025/10</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/10</guid><description>Weekly Journal by ARV of October 2025</description><pubDate>Wed, 01 Oct 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 40 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Performed EDA on Online Transactions data.&lt;/li&gt;
&lt;li&gt;Add logging and tests in Zyou SDK.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 41 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Finally, migrated the &lt;a href=&quot;https://github.com/arv-anshul/resume&quot;&gt;resume&lt;/a&gt; repo to Typst.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 42 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Surprisingly, &lt;code&gt;yt-comment-sentiment&lt;/code&gt; project works fine even after ~10 months means the model is available on
DasgsHub repo.&lt;/li&gt;
&lt;li&gt;Performed EDA on Account statement pdf file.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 43 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Diwali vacation.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 44 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;At home.&lt;/li&gt;
&lt;li&gt;Wi-Fi is very disturbed here.&lt;/li&gt;
&lt;li&gt;Wanted to study &lt;a href=&quot;https://burn.dev&quot;&gt;Burn&lt;/a&gt; framework but couldn&apos;t due to some error in Zed editor. Also there is no
tutorial around it on YouTube but there is a Burn Book though.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>october</category><author>Anshul Raj Verma</author></item><item><title>September Journal</title><link>https://arv-anshul.github.io/journal/2025/09</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/09</guid><description>Weekly Journal by ARV of September 2025</description><pubDate>Mon, 01 Sep 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 36 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Got the &lt;strong&gt;Google One Plan&lt;/strong&gt; for 1 year &lt;em&gt;(till 1st Sept 2026)&lt;/em&gt;.&lt;/li&gt;
&lt;li&gt;Working with MCP with @Aditya.&lt;/li&gt;
&lt;li&gt;Hard to cope-up with Google Arcade Program.&lt;/li&gt;
&lt;li&gt;Implemented a custom Validator class in Pydantic.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 37 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Built MCP server using &lt;code&gt;arv_zyou&lt;/code&gt; project at Intership.&lt;/li&gt;
&lt;li&gt;Built web-app for &lt;a href=&quot;https://github.com/arv-anshul/spotyhive&quot;&gt;spotyhive&lt;/a&gt; repo using &lt;a href=&quot;https://jules.google.com&quot;&gt;Google Jules&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Updated &lt;a href=&quot;https://gravatar.com/arvanshul&quot;&gt;Gravatar&lt;/a&gt; profile.&lt;/li&gt;
&lt;li&gt;Explored a &lt;code&gt;pre-commit&lt;/code&gt; alternative written in Rust &lt;a href=&quot;https://github.com/j178/prek&quot;&gt;j178/prek&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 38 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Implementing Narwhals into Zyou SDK @Aidtya’s project.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 39 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Deleted multiple useless and senseless repositories from my GitHub account.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>september</category><author>Anshul Raj Verma</author></item><item><title>August Journal</title><link>https://arv-anshul.github.io/journal/2025/08</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/08</guid><description>Weekly Journal by ARV of August 2025</description><pubDate>Fri, 01 Aug 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 32 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Joined Google Arcade Program.&lt;/li&gt;
&lt;li&gt;Migrating &lt;a href=&quot;https://github.com/arv-anshul/resume&quot;&gt;resume repo&lt;/a&gt; to Typst instead of LateX.&lt;/li&gt;
&lt;li&gt;5-Day trip to Jaipur. (9 Aug to 13 Aug)&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 33 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Progressing in Google Arcade Program.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 34 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Progressing in Google Arcade Program.&lt;/li&gt;
&lt;li&gt;@Manik asked to scrape 99acres.com properties.&lt;/li&gt;
&lt;li&gt;Connected with @Aditya to discuss his new project based on Facebook Ads, MCP, Redis.&lt;/li&gt;
&lt;li&gt;Attended Orientation Program of College on 23 Aug, 2025.&lt;/li&gt;
&lt;li&gt;Tried &lt;strong&gt;Activity Watch&lt;/strong&gt; application to track my screen time on Mac but couldn&apos;t used it long because it is too
verbose and I don&apos;t need that much as it is too much for my use case.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 35 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Trying to claim &lt;strong&gt;Google One for students&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Working on &lt;code&gt;zyou&lt;/code&gt; SDK for @Aditya.&lt;/li&gt;
&lt;li&gt;Talk about internship with @Aditya.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>august</category><author>Anshul Raj Verma</author></item><item><title>Redirect Search Engine</title><link>https://arv-anshul.github.io/blog/2025/redirect-search-engine</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2025/redirect-search-engine</guid><description>A search engine which can redirect to the website according to the user&apos;s query.</description><pubDate>Mon, 28 Jul 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Approach&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Get user&apos;s query.&lt;/li&gt;
&lt;li&gt;Search with minimal engines like DuckDuckGo, Google Search, Bing, etc. and get their most relevant result.&lt;/li&gt;
&lt;li&gt;Finally redirect to the top resultant URL.&lt;/li&gt;
&lt;li&gt;Alternatively, we can also recommend most relevant results in dropdown menu for ease of redirection for user.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Why Someone Use this Search Engine?&lt;/h2&gt;
&lt;p&gt;Due to ease of website navigation from traditional search engine.&lt;/p&gt;
&lt;h2&gt;Cons&lt;/h2&gt;
&lt;p&gt;Someone can use search engine like Perplexity to get its query&apos;s result in natural language response.&lt;/p&gt;
&lt;hr /&gt;
&lt;h2&gt;Questions&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Is this a good product to build?&lt;/li&gt;
&lt;li&gt;Is this a good product to sustain in future?&lt;/li&gt;
&lt;li&gt;Is this product really help peoples in their daily life?&lt;/li&gt;
&lt;li&gt;Is this product really outsmart current competitors?&lt;/li&gt;
&lt;li&gt;What are more cons of this product from POV of current competitors?&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>ai</category><author>Anshul Raj Verma</author></item><item><title>July Journal</title><link>https://arv-anshul.github.io/journal/2025/07</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/07</guid><description>Weekly Journal by ARV of July 2025</description><pubDate>Tue, 01 Jul 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 27 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Done Nothing.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 28 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Done Nothing.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 29 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Continuing to write Weekly Journal from now on.&lt;/li&gt;
&lt;li&gt;After thinking about a day or two, finally decided to work on &lt;code&gt;job-finder&lt;/code&gt; project.&lt;/li&gt;
&lt;li&gt;Discovered &lt;a href=&quot;https://typst.app&quot;&gt;Typst&lt;/a&gt;, now using it in &lt;code&gt;job-finder&lt;/code&gt; project to compile CV in PDF and PNG format.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 30 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Got an idea to use HTML &amp;amp; CSS for templating in &lt;code&gt;carousel-ai&lt;/code&gt; project as in HTML we just need to fill the
placeholders and export it in PDF format. &lt;em&gt;First tried to create the template in &lt;a href=&quot;https://typst.app&quot;&gt;Typst&lt;/a&gt; but
couldn&apos;t; LOL.&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Helping &lt;a href=&quot;https://gituhb.com/araadhay-py&quot;&gt;@Araadhay&lt;/a&gt; in his project related to legal paper querying and summarization.
He has created a demo web-app using Lovable and also wrote a backend script.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 31 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;IDEA: A search engine which can redirect to the website according to the user&apos;s query. &lt;em&gt;(rejected after talking with
LLM)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Created new secondary email address &lt;code&gt;aanshulrv@gmail.com&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Exploring password manager world to ease my social account management.&lt;/li&gt;
&lt;li&gt;Now using BitWarden as my new password manager and authenticator app &lt;em&gt;(replacing Google Authenticator app)&lt;/em&gt; in
MacBook and Android device.&lt;/li&gt;
&lt;li&gt;SnapDrop is deprecated; now &lt;a href=&quot;https://pairdrop.net&quot;&gt;PairDrop&lt;/a&gt; is new project.&lt;/li&gt;
&lt;li&gt;Helping @Araadhay in his InfinaResearch project.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>july</category><author>Anshul Raj Verma</author></item><item><title>June Journal</title><link>https://arv-anshul.github.io/journal/2025/06</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/06</guid><description>Weekly Journal by ARV of June 2025</description><pubDate>Sun, 01 Jun 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 23 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Done Nothing.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 24 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Done Nothing.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 25 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Done Nothing.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 26 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Done Nothing.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>june</category><author>Anshul Raj Verma</author></item><item><title>May Journal</title><link>https://arv-anshul.github.io/journal/2025/05</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/05</guid><description>Weekly Journal by ARV of May 2025</description><pubDate>Thu, 01 May 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 19 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;New repo &lt;code&gt;spotyhive&lt;/code&gt; to store Spotify Data in JSON format.&lt;/li&gt;
&lt;li&gt;Checked about &lt;code&gt;ty&lt;/code&gt; and &lt;code&gt;pyryefly&lt;/code&gt; Rust based Python type-checker.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 20 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Marimo let you import python function from notebook.&lt;/li&gt;
&lt;li&gt;Archived repository &lt;a href=&quot;https://github.com/arv-anshul/ColdTurkeyBlocker-Pro&quot;&gt;ColdTurkeyBlocker-Pro&lt;/a&gt; against
&lt;a href=&quot;https://github.com/coderhisham/ColdTurkeyBlockerPro-Activator-FREE&quot;&gt;ColdTurkeyBlockerPro-Activator-FREE&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Got the 12th board result, now busy in exploring college.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 21 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Done nothing in code, busy in prepration for College and stuffs.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 22 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Done Nothing.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>may</category><author>Anshul Raj Verma</author></item><item><title>April Journal</title><link>https://arv-anshul.github.io/journal/2025/04</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/04</guid><description>Weekly Journal by ARV of April 2025</description><pubDate>Tue, 01 Apr 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 14 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Read about data science and machine learning libraries in Rust ecosystem. Libraries like &lt;code&gt;polars&lt;/code&gt; (for Data
Manipulation), &lt;code&gt;linfa&lt;/code&gt; (for Machine Learning) and &lt;code&gt;ndarray&lt;/code&gt; (like &lt;code&gt;numpy&lt;/code&gt;) are there.&lt;/li&gt;
&lt;li&gt;I am planing to create an ML model in Rust and convert it into WASM to run it on browser, although I am not sure that
I am actually going to achieve this but I will definitely read about it.&lt;/li&gt;
&lt;li&gt;Deep dive into &lt;code&gt;pydantic&lt;/code&gt; learned advance validation and serialization with custom functions while working on
&lt;code&gt;job-finder&lt;/code&gt; project.&lt;/li&gt;
&lt;li&gt;I have not been able to work this week with LeapX as I am not feeling well.&lt;/li&gt;
&lt;li&gt;Trying to run FLUX-dev model for Chili style image generation but doesn&apos;t because my MAC&apos;s RAM got out of memory.&lt;/li&gt;
&lt;li&gt;Trying &lt;code&gt;dprint&lt;/code&gt; to format docs, previously tried with &lt;code&gt;mdformat-mkdocs&lt;/code&gt; but it couldn&apos;t gives satisfiable result,
although &lt;code&gt;dprint&lt;/code&gt; doesn&apos;t supports MkDocs but want to give it a try for basic formatting.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 15 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Performing advance analysis on Campaigns datasets with @Aditya Sir.&lt;/li&gt;
&lt;li&gt;In &lt;code&gt;sage-backend&lt;/code&gt;, we now infer LLM model from prompts&apos; metadata.&lt;/li&gt;
&lt;li&gt;Gone to Patna for sister&apos;s JEE test met with @Shubham Bhaiya.&lt;/li&gt;
&lt;li&gt;Office re-location talk with @Aditya Sir.&lt;/li&gt;
&lt;li&gt;Got disturbed by heavy storms as the electricity and internet connection is fluctuating.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 16 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Re-exploring the RSS Feeds trying to gather different important news at one place with Folo app.&lt;/li&gt;
&lt;li&gt;@Aditya Sir thought about new SAAS idea that to generate PDFs for social media posting specially LinkedIn.&lt;/li&gt;
&lt;li&gt;Updated introduction paragraph on website and GitHub profile. Used LLMs to generate it from highlight points.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 17 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;@Aditya Sir started working on Post Generator for LinkedIn (using AI).&lt;/li&gt;
&lt;li&gt;Taking break for wedding.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 18 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;No work took break for cousin wedding from 25-04-2025 to 07-05-2025.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>april</category><author>Anshul Raj Verma</author></item><item><title>March Journal</title><link>https://arv-anshul.github.io/journal/2025/03</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/03</guid><description>Weekly Journal by ARV of March 2025</description><pubDate>Sat, 01 Mar 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 10 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Explored &lt;strong&gt;interrupt&lt;/strong&gt; and &lt;strong&gt;Human in the Loop&lt;/strong&gt; mechanism in LangGraph.&lt;/li&gt;
&lt;li&gt;Joined in some classes of Coding Hero platform its good to grow your network but good for learning as the teachers
are learner itself and have no experience of teaching. &lt;em&gt;(Just my POV)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Learning &lt;em&gt;LangGraph&lt;/em&gt; and creating a POC with &lt;strong&gt;Query IPL DB&lt;/strong&gt; project idea. Just to get familiar with all concepts.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 11 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Exams are over and now continuing to learn and create.&lt;/li&gt;
&lt;li&gt;Explored &lt;strong&gt;LangGraph Studio&lt;/strong&gt; web version.&lt;/li&gt;
&lt;li&gt;Building &lt;code&gt;ipl_agent&lt;/code&gt; but intrigued by the performance of agent as it doesn&apos;t perform as excepted and give random
answers. I need to learn how to improve the results of LLM like using few-shot-prompting, better RAG, good prompting
technique, and more.&lt;/li&gt;
&lt;li&gt;IMO, finetuning a LLM with &lt;a href=&quot;https://unsloth.ai&quot;&gt;unsloth-ai&lt;/a&gt; is easy as there are plenty of resources to learn how to finetune LLM using
&lt;a href=&quot;https://unsloth.ai&quot;&gt;unsloth-ai&lt;/a&gt;. I think you just need to find or create a dataset for your purpose and you are ready to go.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 12 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Re-join &lt;strong&gt;LeapX.ai&lt;/strong&gt; as Data Science and AI Intern currently stipend and duration is not decided.&lt;/li&gt;
&lt;li&gt;Explored project repos of &lt;strong&gt;LeapX.ai&lt;/strong&gt; and they are messy af, so I&apos;ve added &lt;code&gt;pre-commit&lt;/code&gt; and used &lt;code&gt;uv&lt;/code&gt; to manage it.&lt;/li&gt;
&lt;li&gt;Forgot to write &lt;strong&gt;Week 12&lt;/strong&gt; (and almost &lt;strong&gt;Week 13&lt;/strong&gt;) journal on time so I am writing it on last day of &lt;strong&gt;Week 13&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Found a nice and beautiful alternative for Swagger UI called &lt;a href=&quot;https://scalar.com&quot;&gt;&lt;strong&gt;Scalar.com&lt;/strong&gt;&lt;/a&gt;, &lt;em&gt;although it is beautiful
but not straight-forward as Swagger&lt;/em&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 13 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Discussed about &lt;code&gt;job-finder&lt;/code&gt; project with @Dipanjan.&lt;/li&gt;
&lt;li&gt;Wrote &lt;code&gt;Dockerfile&lt;/code&gt; for production as well development stage for LeapX&apos;s project.&lt;/li&gt;
&lt;li&gt;Explored &lt;code&gt;opik&lt;/code&gt; to manage prompts and log LLM traces for LeapX&apos;s Sage project.&lt;/li&gt;
&lt;li&gt;Started working on &lt;code&gt;job-finder&lt;/code&gt; project and already implemented some major features. See the project repo at
&lt;a href=&quot;https://github.com/arv-anshul/job-finder&quot;&gt;&lt;code&gt;@arv-anshul/job-finder&lt;/code&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>march</category><author>Anshul Raj Verma</author></item><item><title>Job Applying Agent</title><link>https://arv-anshul.github.io/blog/2025/job-applying-agent</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2025/job-applying-agent</guid><description>A project idea, to create an AI Agent which recommends Jobs on the basis of user&apos;s CV and Job Description.</description><pubDate>Thu, 06 Feb 2025 00:00:00 GMT</pubDate><content:encoded>&lt;blockquote&gt;
&lt;p&gt;Sagar from CampusX group&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Requirements&lt;/h2&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Requirements&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;th&gt;Extra&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Framework&lt;/td&gt;
&lt;td&gt;Langchain&lt;/td&gt;
&lt;td&gt;We will eventually try to drop it. But if this is a showcase project then a framework is best.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Job Opening Data&lt;/td&gt;
&lt;td&gt;Jobs where agent will apply&lt;/td&gt;
&lt;td&gt;Maybe agent will fetch data on-the-go by web scraping.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;User Login (LinkedIn)&lt;/td&gt;
&lt;td&gt;Need to login the user on the platform in order to apply&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2&gt;Agent Workflow&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;LinkedIn Profile Scraper:&lt;/strong&gt; Scrape LinkedIn profile of user and get relevant info.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Parse User&apos;s Resume:&lt;/strong&gt; Parse info from user&apos;s Resume.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Retrieve relevant jobs:&lt;/strong&gt; On the basis of user&apos;s parsed info agent will retrive relevant jobs for user after
analyzing jobs&apos; description.&lt;/li&gt;
&lt;/ul&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;strong&gt;LLM Agent Task&lt;/strong&gt;&lt;/th&gt;
&lt;th&gt;&lt;strong&gt;Detailed Process&lt;/strong&gt;&lt;/th&gt;
&lt;th&gt;&lt;strong&gt;Requirements/Dependencies&lt;/strong&gt;&lt;/th&gt;
&lt;th&gt;&lt;strong&gt;Considerations&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Receive &amp;amp; Parse Job Data&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;- Accept job listing details (title, description, requirements) via API/webhook or direct scraping.&amp;lt;br&amp;gt;- Parse and structure the data for further analysis.&lt;/td&gt;
&lt;td&gt;- Access to structured job data.&amp;lt;br&amp;gt;- Data parsing modules (e.g., regex, NLP parsers).&lt;/td&gt;
&lt;td&gt;- Handle variations in data format.&amp;lt;br&amp;gt;- Ensure data completeness before processing.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Extract Key Job Attributes&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;- Analyze job description to identify required skills, qualifications, and responsibilities.&amp;lt;br&amp;gt;- Highlight keywords and competencies to match user profile.&lt;/td&gt;
&lt;td&gt;- NLP techniques for entity extraction and keyword analysis.&amp;lt;br&amp;gt;- Domain-specific dictionaries or models.&lt;/td&gt;
&lt;td&gt;- Handle ambiguous or vague descriptions.&amp;lt;br&amp;gt;- Ensure extraction accuracy.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Align with User Profile &amp;amp; History&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;- Retrieve relevant parts of the user’s resume and past experiences.&amp;lt;br&amp;gt;- Map job requirements with user skills to determine fit and emphasize strengths.&lt;/td&gt;
&lt;td&gt;- Access to the user’s structured profile data.&amp;lt;br&amp;gt;- Matching algorithms to align job needs with profile attributes.&lt;/td&gt;
&lt;td&gt;- Maintain user data privacy.&amp;lt;br&amp;gt;- Address gaps between job requirements and user profile gracefully.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Generate Custom Application Materials&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;- Construct a tailored prompt for generating a cover letter (or resume adjustments) using the extracted job and user information.&amp;lt;br&amp;gt;- Generate draft content via the LLM.&lt;/td&gt;
&lt;td&gt;- Access to a capable LLM (e.g., GPT-4) with prompt engineering.&amp;lt;br&amp;gt;- Template management and customization frameworks.&lt;/td&gt;
&lt;td&gt;- Balance personalization with professionalism.&amp;lt;br&amp;gt;- Verify that generated content is factually consistent with the user’s data.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Iterative Refinement &amp;amp; Quality Check&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;- Run generated content through self-evaluation steps (e.g., re-prompting for clarity, checking for tone, grammar, and job-specific relevance).&lt;/td&gt;
&lt;td&gt;- Additional LLM prompts for self-review.&amp;lt;br&amp;gt;- External grammar and style-check tools if necessary.&lt;/td&gt;
&lt;td&gt;- Allow for multiple iterations to refine quality.&amp;lt;br&amp;gt;- Optionally incorporate human feedback or pre-defined quality metrics.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Simulate Application Interface Integration&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;- Prepare the final content to be inserted into LinkedIn’s application forms (e.g., cover letter text, resume attachments).&amp;lt;br&amp;gt;- Format the content to meet form requirements.&lt;/td&gt;
&lt;td&gt;- Knowledge of LinkedIn’s input fields and formatting constraints.&amp;lt;br&amp;gt;- Integration layer with the application automation module.&lt;/td&gt;
&lt;td&gt;- Ensure compatibility with the LinkedIn interface.&amp;lt;br&amp;gt;- Handle edge cases like character limits or specific formatting needs.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Execute Automated Submission&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;- Pass the finalized content to the automation module (e.g., Selenium script) for form submission.&amp;lt;br&amp;gt;- Monitor confirmation messages or error responses.&lt;/td&gt;
&lt;td&gt;- Stable API/web automation scripts.&amp;lt;br&amp;gt;- Communication channel between LLM agent and submission module.&lt;/td&gt;
&lt;td&gt;- Robust error handling is critical.&amp;lt;br&amp;gt;- Confirm that submission was successful and log the outcome.&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;em&gt;Generated with ChatGPT.&lt;/em&gt;&lt;/p&gt;
&lt;h2&gt;Problems&lt;/h2&gt;
&lt;h3&gt;Applying to Jobs in Behalf of User.&lt;/h3&gt;
&lt;p&gt;If we are going to implement this then this might be the heaviest situation because we have to deal with multiple steps
like:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;User Login.&lt;/li&gt;
&lt;li&gt;Migrating to each job listing page.&lt;/li&gt;
&lt;li&gt;Applying to job by filling the form including uploading user&apos;s Resume.&lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
&lt;p&gt;Due to this problem we should &lt;strong&gt;first focus on creating an AI agent which find relevant jobs for user&lt;/strong&gt; by seeing
their LinkedIn profile and their Resume.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Agent Flow&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;LinkedIn profile URL.&lt;/li&gt;
&lt;li&gt;Resume as PDF&lt;/li&gt;
&lt;li&gt;A tool will extract info like experience, job type, job mode, and more.&lt;/li&gt;
&lt;li&gt;A tool will scrape relevant jobs on the basis of user&apos;s extracted data.&lt;/li&gt;
&lt;li&gt;Sort the scraped jobs by most relevant for user.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;LangChain Perception&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;How to use messages? (With &lt;code&gt;.stream&lt;/code&gt; method)&lt;/li&gt;
&lt;li&gt;How to implement async tools? (For profile scraping and resume parsing purpose)&lt;/li&gt;
&lt;/ul&gt;
&lt;hr /&gt;
&lt;blockquote&gt;
&lt;p&gt;🔎 Job Finder - Raycast Note&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Current Plan&lt;/h2&gt;
&lt;p&gt;We planned to provide a platform where both Employee and Employer list their skills and requirements and then we will
provide an interface where both Employee and Employer will finder their match on the basis of their skills and
requirements.&lt;/p&gt;
&lt;h2&gt;Problem &lt;em&gt;(with Current Plan)&lt;/em&gt;&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;As we are no one who is going to use product the idea Employer listing is hard to be gain success on, so I decided to
drop it. &lt;em&gt;(read next)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;We can scrape websites like LinkedIn, Naukri, etc. and gather data related to Jobs and make the platform only for
Employee &lt;em&gt;(as name suggests &lt;strong&gt;&lt;strong&gt;Job Finder&lt;/strong&gt;&lt;/strong&gt;).&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Platform Usage&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;User will upload its Resume/CV on our website.&lt;/li&gt;
&lt;li&gt;We will parse their CV using OCR and extract a structure information for our use case.&lt;/li&gt;
&lt;li&gt;We will then asks the user to fill a partially filled form to get full info about the user.&lt;/li&gt;
&lt;li&gt;The form is already filled by the info we extracted from user’s CV.&lt;/li&gt;
&lt;li&gt;Then, we will recommend most similar Jobs we got in our database.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Future Plans&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;We may also provide a service to create a resume by filling a simple form.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;References&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://jsonresume.org/getting-started&quot;&gt;jsonresume.org&lt;/a&gt;: For custom resume creation.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Resourses&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://towardsdatascience.com/ai-powered-information-extraction-and-matchmaking-0408c93ec1b9&quot;&gt;https://towardsdatascience.com/ai-powered-information-extraction-and-matchmaking-0408c93ec1b9&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/luillyfe/resume-insights&quot;&gt;https://github.com/luillyfe/resume-insights&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>llm</category><author>Anshul Raj Verma</author></item><item><title>February Journal</title><link>https://arv-anshul.github.io/journal/2025/02</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/02</guid><description>Weekly Journal by ARV of February 2025</description><pubDate>Sat, 01 Feb 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 06 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;:star: Dipanjan cited me in his MBA&apos;s final year project documentation.&lt;/li&gt;
&lt;li&gt;Learning from Kaggle courses. And I have to say they are promising from begginers perspective.
&lt;ul&gt;
&lt;li&gt;Completed &lt;strong&gt;Intro to Deep Learning&lt;/strong&gt; course.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Updated website&apos;s and diary&apos;s docs with new updated syntax of
&lt;a href=&quot;https://facelessuser.github.io/pymdown-extensions/extensions/blocks/plugins/admonition/&quot;&gt;Admonition&lt;/a&gt; and more.&lt;/li&gt;
&lt;li&gt;@Sagar (from CampusX group) suggested to build a LLM agent which can apply in Jobs on platforms like LinkedIn. So,
creating its HLD.&lt;/li&gt;
&lt;li&gt;Nowdays, I am &lt;strong&gt;Full on PROCASTINATION MODE&lt;/strong&gt; because of 12th board exams and also not able figure out what to do
next. &lt;em&gt;Just killing time on reels, web series and youtube.&lt;/em&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 07 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Meeting with @Sagar and we discussed about:
&lt;ul&gt;
&lt;li&gt;Job applier on LinkedIn but he wants to apply from official website instead.&lt;/li&gt;
&lt;li&gt;Suggested to look into &lt;a href=&quot;https://github.com/browser-use/browser-use&quot;&gt;browser-use&lt;/a&gt; tool which is apparently interesting and useful.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Explored &lt;a href=&quot;https://github.com/browser-use/browser-use&quot;&gt;browser-use&lt;/a&gt; it is interesting but there are some points to note:
&lt;ul&gt;
&lt;li&gt;Works on heavy prompting.&lt;/li&gt;
&lt;li&gt;Very nice approach/feature of &lt;code&gt;Controller&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;As usual problem of LLM apps very dynamic in nature of completing tasks.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Enrolled into &lt;a href=&quot;https://hf.co/learn/agents-course&quot;&gt;&lt;strong&gt;Hugging Face Agents Course&lt;/strong&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 08 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Exams are here.&lt;/li&gt;
&lt;li&gt;Completed &lt;strong&gt;Unit 1&lt;/strong&gt; of &lt;strong&gt;Fundamentals of Agents&lt;/strong&gt; course by HuggingFace.&lt;/li&gt;
&lt;li&gt;Completed &lt;a href=&quot;https://academy.langchain.com/courses/intro-to-langgraph&quot;&gt;&lt;strong&gt;Intro to LangGraph&lt;/strong&gt;&lt;/a&gt; course by LangChain.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 09 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Explored &lt;a href=&quot;https://kunkun.sh&quot;&gt;Kunkun&lt;/a&gt; app.&lt;/li&gt;
&lt;li&gt;Built an extension for Kunkun, &lt;a href=&quot;https://kunkun.sh/store/kunkun-search-emoji&quot;&gt;&lt;strong&gt;Search Emoji&lt;/strong&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Cloned &lt;a href=&quot;https://github.com/kunkunsh/kunkun&quot;&gt;Kunkun&lt;/a&gt; and did some UI tweaks. Created
&lt;a href=&quot;https://github.com/kunkunsh/kunkun/pull/219&quot;&gt;PR#219&lt;/a&gt; there.&lt;/li&gt;
&lt;li&gt;[ WIP ]&lt;/li&gt;
&lt;li&gt;Added GPG Key in my GitHub account &lt;strong&gt;to sign the &lt;code&gt;git&lt;/code&gt; commits and tags&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Found new font &lt;strong&gt;SF Mono&lt;/strong&gt; which is by Apple Inc. itself but didn&apos;t know about it yet but I&apos;ve installed and it and
using it from Homebrew &lt;code&gt;font-sf-mono-for-powerline&lt;/code&gt;. &lt;em&gt;Its just it lacks visually appealing italic variant.&lt;/em&gt;&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>february</category><author>Anshul Raj Verma</author></item><item><title>Fine-Tune Transformers</title><link>https://arv-anshul.github.io/blog/2025/finetune-transformers</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2025/finetune-transformers</guid><description>References to finetune Transformers from HuggingFace using Pytorch or TensorFlow.</description><pubDate>Sun, 05 Jan 2025 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Learning how to &lt;strong&gt;fine-tune a BERT model using PyTorch/TensorFlow from HuggingFace&lt;/strong&gt; for your use case is an art in
itself because there are so many ways and methods to do. And you will not able to figure out easily which is the best
for your use case. By the way, you can always refer to
&lt;a href=&quot;https://huggingface.co/docs/transformers/training&quot;&gt;HuggingFace documentation&lt;/a&gt;.&lt;/p&gt;
&lt;h2&gt;For Example!&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Choose between PyTorch and TensorFlow. &lt;em&gt;(lets choose PyTorch)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;If you are importing your dataset with &lt;code&gt;pandas&lt;/code&gt; or &lt;code&gt;polars&lt;/code&gt; then need to create a custom class by inheriting
&lt;code&gt;torch.utils.data.Dataset&lt;/code&gt; class.&lt;/li&gt;
&lt;li&gt;Then need to tokenize the data and need to use &lt;code&gt;DataLoader&lt;/code&gt; and Data Collator.&lt;/li&gt;
&lt;li&gt;Then use a for-loop to train and validate the model.&lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
&lt;p&gt;But there is an easy way of fine-tune, by using objects like
&lt;a href=&quot;https://huggingface.co/docs/transformers/v4.47.1/en/main_classes/trainer#transformers.TrainingArguments&quot;&gt;&lt;code&gt;transformers.TrainingArguments&lt;/code&gt;&lt;/a&gt;
and &lt;a href=&quot;https://huggingface.co/docs/transformers/main_classes/trainer&quot;&gt;&lt;code&gt;transformers.Trainer&lt;/code&gt;&lt;/a&gt; which reduces the manual
looping complexity.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Fine-Tune Process&lt;/h2&gt;
&lt;h3&gt;Load Data&lt;/h3&gt;
&lt;p&gt;Import dataset your method such as &lt;code&gt;pandas&lt;/code&gt;, &lt;code&gt;polars&lt;/code&gt; or other ways.&lt;/p&gt;
&lt;h3&gt;Preprocess Data&lt;/h3&gt;
&lt;p&gt;Process the data and check the &lt;code&gt;labels&lt;/code&gt;. Docs
&lt;a href=&quot;https://huggingface.co/docs/transformers/v4.47.1/en/preprocessing&quot;&gt;Preprocess Data&lt;/a&gt;.&lt;/p&gt;
&lt;h3&gt;Train-Val-Test Dataset&lt;/h3&gt;
&lt;p&gt;Split the data into train, validation, and test data. Before doing this you have consider many things like:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;How to tokenize the data with certain &lt;code&gt;padding&lt;/code&gt;, &lt;code&gt;truncation&lt;/code&gt;, &lt;code&gt;max_length&lt;/code&gt;, &lt;code&gt;return_tensors&lt;/code&gt;, etc.?&lt;/li&gt;
&lt;li&gt;Do you need to shuffle the data? (Only shuffle train dataset)&lt;/li&gt;
&lt;li&gt;Which object you will use to store the data? (&lt;code&gt;datasets.Dataset&lt;/code&gt; or &lt;code&gt;torch.utils.data.DataLoader&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;Representation or data type of &lt;strong&gt;labels&lt;/strong&gt; column? This will be different for different type of problems you have to
make sure that the data is in correct format.&lt;/li&gt;
&lt;li&gt;Is DataCollator required?&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Tokenize Data&lt;/h3&gt;
&lt;p&gt;You need to tokenize the data before sending it to model to trained on. &lt;em&gt;It is done using respective model&apos;s tokenizer.&lt;/em&gt;
You can tokenize the data separately or in batch &lt;em&gt;(recommended)&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/v4.47.1/en/pad_truncation&quot;&gt;Padding and Truncation&lt;/a&gt;&lt;/p&gt;
&lt;h3&gt;Batch Creation&lt;/h3&gt;
&lt;p&gt;You have to cast the dataset into an object which supports the batching.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/datasets/en/quickstart&quot;&gt;&lt;code&gt;datasets.Dataset&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://pytorch.org/docs/stable/data.html&quot;&gt;&lt;code&gt;torch.utils.data.Dataset&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://pytorch.org/docs/stable/data.html&quot;&gt;&lt;code&gt;torch.utils.data.DataLoader&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Data Collator&lt;/h3&gt;
&lt;p&gt;Data collators are objects that will form a batch by using a list of dataset elements as input.&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/main_classes/data_collator&quot;&gt;Data Collator&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/main_classes/data_collator#transformers.DataCollatorWithPadding&quot;&gt;&lt;code&gt;transformers.DataCollatorWithPadding&lt;/code&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h3&gt;Load Tokenizer&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;A tokenizer is in charge of preparing the inputs for a model.&lt;/strong&gt; The library contains tokenizers for all the models.
Most of the tokenizers are available in two flavors: a full python implementation and a “Fast” implementation based on
the Rust library Tokenizers.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/main_classes/tokenizer&quot;&gt;Tokenzier&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/v4.47.1/en/autoclass_tutorial#autotokenizer&quot;&gt;AutoTokenzier&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Load Model&lt;/h3&gt;
&lt;p&gt;A pre-trained model which we are going to finetune using our custom dataset.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/model_doc/auto&quot;&gt;Auto Classes&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/main_classes/configuration&quot;&gt;Model Configuration&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/v4.47.1/en/autoclass_tutorial#automodel&quot;&gt;&lt;code&gt;transformers.AutoModel&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/model_doc/bert&quot;&gt;&lt;code&gt;transformers.BERTModel&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;BERT Model&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/model_doc/bert&quot;&gt;&lt;code&gt;transformers.BERTModel&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/model_doc/bert#transformers.BertConfig&quot;&gt;&lt;code&gt;transformers.BERTConfig&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/model_doc/bert#transformers.BertForSequenceClassification&quot;&gt;&lt;code&gt;transformers.BertForSequenceClassification&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Model Training/Finetuning&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/main_classes/optimizer_schedules&quot;&gt;Optimization Strategies&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/v4.47.1/en/main_classes/trainer#trainer&quot;&gt;&lt;code&gt;transformers.Trainer&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=W2QuK9TwYXs&quot;&gt;Better Fine Tuning by Matt Williams&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;PEFT Methods&lt;/h4&gt;
&lt;p&gt;PEFT offers parameter-efficient methods for finetuning large pretrained models by training a smaller number of
parameters using a reparametrization method like &lt;a href=&quot;https://huggingface.co/docs/peft/package_reference/lora&quot;&gt;&lt;strong&gt;LoRA&lt;/strong&gt;&lt;/a&gt; and
more.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/peft/quicktour&quot;&gt;PEFT Quicktour&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/peft/developer_guides/lora&quot;&gt;LoRA&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/peft/task_guides/lora_based_methods&quot;&gt;LoRA Methods&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/peft/developer_guides/quantization&quot;&gt;Quantization&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Evaluate Model&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/evaluate/index&quot;&gt;Evaluate Library&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/v4.47.1/en/tasks/sequence_classification#evaluate&quot;&gt;Evaluate a TextClassification Model&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Model Prediction/Inference&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/main_classes/output&quot;&gt;Model Outputs&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://huggingface.co/docs/transformers/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput&quot;&gt;&lt;code&gt;transformers.modeling_outputs.SequenceClassifierOutput&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Training with PyTorch&lt;/h2&gt;
&lt;p&gt;You can either fine-tune a pretrained model in native PyTorch or with
&lt;a href=&quot;https://huggingface.co/docs/transformers/v4.47.1/en/main_classes/trainer#trainer&quot;&gt;&lt;code&gt;transformers.Trainer&lt;/code&gt;&lt;/a&gt; class
&lt;em&gt;(recommended)&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;Read this documentation by HuggingFace
&lt;a href=&quot;https://huggingface.co/docs/transformers/training&quot;&gt;&lt;strong&gt;&quot;Fine-tune a pre-trained model&quot;&lt;/strong&gt;&lt;/a&gt; where they explain how to
fine-tune a pretrained model using both the methods separately.&lt;/p&gt;
&lt;p&gt;Also refer to this tutorial by same team for
&lt;a href=&quot;https://huggingface.co/docs/transformers/v4.47.1/en/tasks/sequence_classification&quot;&gt;&lt;strong&gt;&quot;Text Classification&quot;&lt;/strong&gt;&lt;/a&gt;.&lt;/p&gt;
</content:encoded><category>blog</category><category>deep-learning</category><category>pytorch</category><category>transformers</category><author>Anshul Raj Verma</author></item><item><title>January Journal</title><link>https://arv-anshul.github.io/journal/2025/01</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2025/01</guid><description>Weekly Journal by ARV of January 2025</description><pubDate>Wed, 01 Jan 2025 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 01 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Learning &lt;strong&gt;how to fine-tune BERT model using PyTorch&lt;/strong&gt; from HuggingFace example.
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Sentiment Classification:&lt;/strong&gt;
&lt;a href=&quot;https://github.com/abhimishra91/transformers-tutorials/blob/master/transformers_sentiment_wandb.ipynb&quot;&gt;transformers_sentiment_wandb.ipynb&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Multiclass Classification:&lt;/strong&gt;
&lt;a href=&quot;https://github.com/abhimishra91/transformers-tutorials/blob/master/transformers_multiclass_classification.ipynb&quot;&gt;transformers_multiclass_classification.ipynb&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Planning to leverage the power of &lt;strong&gt;Keras 3&lt;/strong&gt; which is &lt;a href=&quot;https://keras.io/keras_3/&quot;&gt;written in their docs&lt;/a&gt;.
&lt;ul&gt;
&lt;li&gt;Its hard (or not possible) because HF&apos;s &lt;code&gt;transformers&lt;/code&gt; library doesn&apos;t support it but I have checked that
&lt;code&gt;keras_hub&lt;/code&gt; library has it&apos;s own BERT model there which I can use, I think.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Will explore more in next week&lt;/strong&gt;:
&lt;ul&gt;
&lt;li&gt;[x] How to fine-tune BERT using PyTorch + HF Transformers?&lt;/li&gt;
&lt;li&gt;[ ] How to fine-tune BERT using Tensorflow + HF Transformers?&lt;/li&gt;
&lt;li&gt;[x] &lt;s&gt;How to fine-tune BERT using Keras3 + PyTorch + HF Transformers only?&lt;/s&gt; &lt;em&gt;(NOT POSSIBLE)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;[x] What are these terms like SPDA, PEFT, LORA and more for fine-tuning purpose.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 02 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Explored new method to finetune BERT model using &lt;code&gt;transformers.TrainingArguments&lt;/code&gt; and &lt;code&gt;transformers.Trainer&lt;/code&gt; classes.&lt;/li&gt;
&lt;li&gt;Wrote a &lt;a href=&quot;https://arv-anshul.github.io/ref/deep-learning/finetune-transformers/&quot;&gt;ref page&lt;/a&gt; where important articles
are listed for finetuning BERT model.&lt;/li&gt;
&lt;li&gt;Commiting all the finetuning codes in the form of &lt;code&gt;python&lt;/code&gt; script and &lt;code&gt;marimo&lt;/code&gt; notebook in
&lt;a href=&quot;https://github.com/arv-anshul/notebooks&quot;&gt;&lt;code&gt;@arv-anshul/notebooks&lt;/code&gt;&lt;/a&gt; repo.&lt;/li&gt;
&lt;li&gt;Explored PEFT methods like LoRA. Tried to finetune BERT model using them.&lt;/li&gt;
&lt;li&gt;Found a way to format my &lt;code&gt;mkdocs&lt;/code&gt; docs. See &lt;code&gt;@astral-sh/ruff&lt;/code&gt; repo to know more about formatting &lt;code&gt;mkdocs&lt;/code&gt; docs.
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/astral-sh/ruff/blob/main/.pre-commit-config.yaml&quot;&gt;&lt;code&gt;.pre-commit-config.yaml&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/astral-sh/ruff/blob/main/.markdownlint.yaml&quot;&gt;&lt;code&gt;.markdownlint.yaml&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Planning to migrate all &lt;code&gt;/ref&lt;/code&gt; pages to &lt;code&gt;/blog&lt;/code&gt; because these aren&apos;t any different from them. Also, I don&apos;t write
blogs because I feel the articles are better fit for &lt;code&gt;/ref&lt;/code&gt; pages which reduced the usages of &lt;code&gt;/blog&lt;/code&gt; pages.
&lt;ul&gt;
&lt;li&gt;Migration maybe broke some links that I will fix later.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 03 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Finally, committed the &lt;strong&gt;Journal Summarizer&lt;/strong&gt; as &lt;a href=&quot;https://marimo.io&quot;&gt;marimo&lt;/a&gt; app for this diary repo.&lt;/li&gt;
&lt;li&gt;:star: Migrated &lt;code&gt;/ref&lt;/code&gt; pages to &lt;code&gt;/blog&lt;/code&gt; in website.&lt;/li&gt;
&lt;li&gt;Also tried to format markdown files in website&apos;s repo using
&lt;a href=&quot;https://github.com/kyleking/mdformat-mkdocs&quot;&gt;mdformat-mkdocs&lt;/a&gt; but it&apos;s not acceptable for me.&lt;/li&gt;
&lt;li&gt;Raised &lt;a href=&quot;https://github.com/KyleKing/mdformat-mkdocs/issues/45&quot;&gt;issue in mdformat-mkdocs&lt;/a&gt; repo.&lt;/li&gt;
&lt;li&gt;Worked on creating my resume (CV) using LaTeX (&lt;code&gt;.tex&lt;/code&gt; format). And tried to manage it with python script.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 04 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;More work on resume (CV) management. Explored LateX and &lt;code&gt;pdflatex&lt;/code&gt; like tools for resume management.&lt;/li&gt;
&lt;li&gt;New repo &lt;a href=&quot;https://github.com/arv-anshul/hockey&quot;&gt;@arv-anshul/hockey&lt;/a&gt;. Scrapes data related to Hockey from altiusrt.com
websites using scrapy framework. And publish the data on
&lt;a href=&quot;https://kaggle.com/datasets/arvanshul/hockey-india-league-2025&quot;&gt;Kaggle&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Wrote a &lt;a href=&quot;https://kaggle.com/code/arvanshul/reddit-sentiment-keras3&quot;&gt;Kaggle notebook&lt;/a&gt; on sentiment classification on
Reddit comments dataset using Keras.&lt;/li&gt;
&lt;li&gt;Exploring &lt;a href=&quot;https://github.com/deepseek-ai/DeepSeek-R1&quot;&gt;&lt;code&gt;deepseek-r1&lt;/code&gt;&lt;/a&gt; distill models with
&lt;a href=&quot;https://huggingface.co/docs/smolagents&quot;&gt;&lt;code&gt;smolagents&lt;/code&gt;&lt;/a&gt; for nlp-to-sql tasks.&lt;/li&gt;
&lt;li&gt;Hectic exploration of LaTeX tool with &lt;a href=&quot;https://podman.io&quot;&gt;Podman&lt;/a&gt;. &lt;em&gt;(literally, very hectic)&lt;/em&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 05 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Created @Suraj&apos;s college PPT on &lt;strong&gt;Introduction to Systems of Human Body&lt;/strong&gt; at his place.&lt;/li&gt;
&lt;li&gt;New repo &lt;a href=&quot;https://github.com/arv-anshul/resume&quot;&gt;@arv-anshul/resume&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;@Nitish sir (@CampusX) announced &lt;strong&gt;Gen AI Course&lt;/strong&gt; for free on YouTube.&lt;/li&gt;
&lt;li&gt;Joined Kaggle Competition S05E01.&lt;/li&gt;
&lt;li&gt;Feeling clueless with next step around anything (project, learning).&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>january</category><author>Anshul Raj Verma</author></item><item><title>Dockerize - FastAPI - UV</title><link>https://arv-anshul.github.io/blog/2024/docker-fastapi-uv</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/docker-fastapi-uv</guid><description>Dockerize your FastAPI app which is managed with uv easily.</description><pubDate>Fri, 27 Dec 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Let&apos;s dockerize my &lt;a href=&quot;https://github.com/arv-anshul/yt-comment-sentiment&quot;&gt;&lt;code&gt;yt-comment-sentiment&lt;/code&gt;&lt;/a&gt; project which is a FastAPI app managed via UV.&lt;/p&gt;
&lt;h2&gt;Official Docs&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;FastAPI &lt;a href=&quot;https://fastapi.tiangolo.com/deployment/docker/&quot;&gt;docs for Dockerization&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;UV &lt;a href=&quot;https://docs.astral.sh/uv/guides/integration/docker/&quot;&gt;docs for Dockerization&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;UV-FastAPI example &lt;a href=&quot;https://docs.astral.sh/uv/guides/integration/fastapi/&quot;&gt;docs for Dockerization&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;:thinking: Then, Why this?&lt;/h2&gt;
&lt;p&gt;I also consider above docs to fulfill my requirements but this includes:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Multistage build to reduce final image size.&lt;/li&gt;
&lt;li&gt;Best and Flexible practices to use &lt;code&gt;uv&lt;/code&gt; in Docker.&lt;/li&gt;
&lt;li&gt;Solution of some problems which I have encountered.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;code&gt;Dockerfile&lt;/code&gt;&lt;/h2&gt;
&lt;p&gt;I am taking reference of my &lt;a href=&quot;https://github.com/arv-anshul/yt-comment-sentiment&quot;&gt;&lt;code&gt;yt-comment-sentiment&lt;/code&gt;&lt;/a&gt; which I have developed and recently and
continuously improving it.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;FROM&lt;/span&gt;&lt;span&gt; python:3.11-slim &lt;/span&gt;&lt;span&gt;AS&lt;/span&gt;&lt;span&gt; builder&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# See official docs at https://docs.astral.sh/uv/guides/integration/docker/#available-images&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;COPY&lt;/span&gt;&lt;span&gt; --from=ghcr.io/astral-sh/uv:latest /uv /bin/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Install gcc for wordcloud&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Using `wordcloud` in backend and it require `gcc` package to build wheels to work in python.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;RUN&lt;/span&gt;&lt;span&gt; apt-get update &amp;amp;&amp;amp; apt-get install -y gcc &amp;amp;&amp;amp; apt-get clean&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;WORKDIR&lt;/span&gt;&lt;span&gt; /app&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ADD&lt;/span&gt;&lt;span&gt; pyproject.toml uv.lock /app&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Install dependencies with `--extra=backend` dependencies&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;RUN&lt;/span&gt;&lt;span&gt; uv sync --extra=backend --frozen --compile-bytecode --no-install-project&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Copy only necessary files/folders to reduce image size&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;COPY&lt;/span&gt;&lt;span&gt; params.yaml /app&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;COPY&lt;/span&gt;&lt;span&gt; backend /app/backend&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;COPY&lt;/span&gt;&lt;span&gt; ml /app/ml&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;RUN&lt;/span&gt;&lt;span&gt; uv sync --extra=backend --locked&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Final stage&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Use multistage build to reduce the image size.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;FROM&lt;/span&gt;&lt;span&gt; python:3.11-slim &lt;/span&gt;&lt;span&gt;AS&lt;/span&gt;&lt;span&gt; final&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;COPY&lt;/span&gt;&lt;span&gt; --from=builder /app /app&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;WORKDIR&lt;/span&gt;&lt;span&gt; /app&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Run backend using fastapi-cli&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;CMD&lt;/span&gt;&lt;span&gt; [&lt;/span&gt;&lt;span&gt;&quot;.venv/bin/fastapi&quot;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&quot;run&quot;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&quot;--host&quot;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&quot;0.0.0.0&quot;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&quot;--port&quot;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&quot;8000&quot;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&quot;backend/app.py&quot;&lt;/span&gt;&lt;span&gt;]&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;If you get any other problem please refer to &lt;a href=&quot;#official-docs&quot;&gt;official docs&lt;/a&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
</content:encoded><category>blog</category><category>python</category><category>docker</category><category>fastapi</category><author>Anshul Raj Verma</author></item><item><title>YouTube Comment Sentiment</title><link>https://arv-anshul.github.io/projects/yt-comment-sentiment</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/yt-comment-sentiment</guid><description>End-to-End machine learning project from backend using FastAPI to frontend using VueJs.</description><pubDate>Fri, 27 Dec 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;You can read about this project&apos;s each segments in details in their respective pages at &lt;a href=&quot;./ml.md&quot;&gt;ML Side&lt;/a&gt;,
&lt;a href=&quot;./backend.md&quot;&gt;Backend Side&lt;/a&gt; and &lt;a href=&quot;./frontend.md&quot;&gt;Frontend Side&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;After reading above pages you&apos;ll get to know about:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;What had I used?&lt;/li&gt;
&lt;li&gt;How did I done?&lt;/li&gt;
&lt;li&gt;I have also shared some common mistakes you could encounter while building this.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Frontend Screenshots&lt;/h2&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/yt-comment-sentiment/raw/main/frontend/assets/screenshot-2024-12-25.png&quot; alt=&quot;screenshot&quot; /&gt;&lt;/p&gt;
</content:encoded><category>project</category><category>project</category><category>ml</category><category>fastapi</category><category>end-to-end</category><author>Anshul Raj Verma</author></item><item><title>YT Comment Sentiment - Backend Side</title><link>https://arv-anshul.github.io/projects/yt-comment-sentiment/backend</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/yt-comment-sentiment/backend</guid><description>Built backend of project using FastAPI and YouTube API in Python and hosted on Render.com.</description><pubDate>Fri, 27 Dec 2024 00:00:00 GMT</pubDate><content:encoded>&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Technology&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/scikit--learn-F7931E?logo=scikitlearn&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;scikit-learn&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A Python library for building and training machine learning models.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/DagsHub-34567C?logo=pug&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;DagsHub Badge&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A collaboration platform for machine learning, hosting data and MLflow models.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/MLflow-0194E2?logo=mlflow&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;MLflow&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A platform to manage the ML lifecycle, including model tracking and deployment.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/FastAPI-009688?logo=fastapi&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;FastAPI&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A modern web framework for building APIs with Python, known for its speed.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/Pydantic-E92063?logo=pydantic&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;Pydantic&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A Python library for data validation. Used to validate API data.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/Pytest-0A9EDC?logo=pytest&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;Pytest Badge&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A testing framework for Python, used to test the FastAPI application.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/YouTube-FF0000?logo=youtube&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;YouTube&quot; /&gt;&lt;/td&gt;
&lt;td&gt;An API to access and manage YouTube video data, including comments.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/Render-000000?logo=render&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;Render&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A cloud platform for hosting APIs, websites, and applications.&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2&gt;What &lt;s&gt;I Followed&lt;/s&gt; to Know?&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;[!IMPORTANT]&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;As I am learning Python, Data Science and Machine Learning for more than 3 years. I don&apos;t have to look around to
learn new things to build this. &lt;em&gt;This part is kind of easy for me.&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;But as I said earlier, the documentations and ChatGPT is most important resources you can onto. :wink:&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;ul&gt;
&lt;li&gt;Need to &lt;strong&gt;get an API key from Google Developer Console&lt;/strong&gt; to interact with YouTube Data API.&lt;/li&gt;
&lt;li&gt;Need to create an account on DagsHub to store/track MLFlow experiments and models.&lt;/li&gt;
&lt;li&gt;Created a DVC pipeline to run the MLFlow experiments seemlessly using &lt;code&gt;dvc repro&lt;/code&gt; command.&lt;/li&gt;
&lt;li&gt;After creating the FastAPI app, I&apos;ve used &lt;code&gt;pytest&lt;/code&gt; to test it and also setup a &lt;code&gt;pre-commit&lt;/code&gt; for it.&lt;/li&gt;
&lt;li&gt;Deployment on &lt;a href=&quot;https://render.com&quot;&gt;render.com&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;What Type of Problems I Have Faced?&lt;/h2&gt;
&lt;h3&gt;Render.com&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;As I have used &lt;code&gt;uv&lt;/code&gt; to manage my project but render.com doesn&apos;t support &lt;code&gt;uv&lt;/code&gt; out-of-the-box so I have used &lt;code&gt;pip&lt;/code&gt; to
use &lt;code&gt;uv&lt;/code&gt; for dependencies installation.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;pip&lt;/span&gt;&lt;span&gt; install&lt;/span&gt;&lt;span&gt; uv&lt;/span&gt;&lt;span&gt; &amp;amp;&amp;amp; &lt;/span&gt;&lt;span&gt;uv&lt;/span&gt;&lt;span&gt; sync&lt;/span&gt;&lt;span&gt; --extra=backend&lt;/span&gt;&lt;span&gt; --compile-bytecode&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Also, render.com only serve apps on port under &lt;code&gt;$PORT&lt;/code&gt; env (which &lt;code&gt;10000&lt;/code&gt; most of the times) so make sure to
explicitly provide while running app through &lt;code&gt;uvicorn&lt;/code&gt; or &lt;code&gt;fastapi-cli&lt;/code&gt; CLI.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;# For uvicorn&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;uvicorn&lt;/span&gt;&lt;span&gt; run&lt;/span&gt;&lt;span&gt; --host&lt;/span&gt;&lt;span&gt; 0.0.0.0&lt;/span&gt;&lt;span&gt; --port&lt;/span&gt;&lt;span&gt; $PORT&lt;/span&gt;&lt;span&gt; backend.app:app&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# For fastapi-cli&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;fastapi&lt;/span&gt;&lt;span&gt; run&lt;/span&gt;&lt;span&gt; --host&lt;/span&gt;&lt;span&gt; 0.0.0.0&lt;/span&gt;&lt;span&gt; --port&lt;/span&gt;&lt;span&gt; $PORT&lt;/span&gt;&lt;span&gt; backend/app.py&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Docker&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;I am using &lt;code&gt;wordcloud&lt;/code&gt; to create a plot in a FastAPI route. While building docker image FROM &lt;code&gt;python:3.11-slim&lt;/code&gt; image,
I am getting error because &lt;code&gt;wordcloud&lt;/code&gt; package needs &lt;code&gt;gcc&lt;/code&gt; package to build wheels. So you need to explicitly install
&lt;code&gt;gcc&lt;/code&gt; before install &lt;code&gt;wordcloud&lt;/code&gt; as python package.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;# Install gcc for wordcloud&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;RUN&lt;/span&gt;&lt;span&gt; apt-get update &amp;amp;&amp;amp; apt-get install -y gcc &amp;amp;&amp;amp; apt-get clean&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Now install project dependencies including wordcloud&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# ...&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Also use multistage builds in &lt;code&gt;Dockerfile&lt;/code&gt; to reduce the image size.
&lt;a href=&quot;https://docs.astral.sh/uv/guides/integration/docker/&quot;&gt;See &lt;code&gt;uv&lt;/code&gt; docs&lt;/a&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>project</category><category>project</category><category>ml</category><category>fastapi</category><author>Anshul Raj Verma</author></item><item><title>YT Comment Sentiment - Frontend Side</title><link>https://arv-anshul.github.io/projects/yt-comment-sentiment/frontend</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/yt-comment-sentiment/frontend</guid><description>Built frontend of project using VueJs + Vite and hosted on GitHub Pages.</description><pubDate>Fri, 27 Dec 2024 00:00:00 GMT</pubDate><content:encoded>&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Technology&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/pnpm-F69220?logo=pnpm&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;pnpm&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A fast and efficient package manager for JavaScript projects, known for its disk space usage.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/shadcn/vue-000000?logo=shadcnui&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;shadcn/vue&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A customizable component library for building elegant UIs in modern web applications.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/Tailwind%20CSS-06B6D4?logo=tailwindcss&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;Tailwind CSS&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A utility-first CSS framework for creating custom designs quickly and efficiently.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/Vite-646CFF?logo=vite&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;Vite&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A next-generation frontend build tool for blazing-fast development and hot module replacement.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;img src=&quot;https://img.shields.io/badge/Vue.js-4FC08D?logo=vuedotjs&amp;amp;logoColor=fff&amp;amp;style=square&quot; alt=&quot;Vue.js&quot; /&gt;&lt;/td&gt;
&lt;td&gt;A progressive JavaScript framework for building user interfaces and single-page applications.&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2&gt;What I followed?&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;[!IMPORTANT]&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Documentation is the most important resource for your learning and I followed it thoroughly.&lt;/li&gt;
&lt;li&gt;Took help of ChatGPT to solve bugs and asked questions related to these frameworks/tools.&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;ul&gt;
&lt;li&gt;Followed &lt;a href=&quot;https://youtu.be/VeNfHj6MhgA&quot;&gt;only one YouTube video&lt;/a&gt; to learn VueJs.&lt;/li&gt;
&lt;li&gt;Used &lt;a href=&quot;https://shadcn-vue.com&quot;&gt;shadcn/vue&lt;/a&gt; as components library. &lt;em&gt;Just followed the docs.&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Whole &lt;code&gt;build_frontend.yaml&lt;/code&gt; Github Action workflow written by ChatGPT, isn&apos;t it amazing :exploding_head:.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Although, I didn&apos;t have much knowledge of Vue, Vite and ShadCN like frameworks/tools but their documentation and ChatGPT
helped me so much that I am able to &lt;strong&gt;learn, build, diagnose and deploy&lt;/strong&gt; the frontend in almost 2-3 days.&lt;/p&gt;
&lt;p&gt;Yes, some credits goes my past knowledge of programming because that&apos;s why I able to figure out how do things works and
how to handle them by doing right things.&lt;/p&gt;
&lt;h2&gt;What Type of Problems I Have Faced?&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;हे भगवान!&lt;/strong&gt; While learning and working on this frontend project, sometime I get messed up with very silly typo
mistakes in JavaScript.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;The things you are building happily in local will totally change when you are trying to deploy it and I have faced this
too :cry:.&lt;/p&gt;
&lt;h3&gt;VueJs&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;How to emit data from Child component to Parent component in VueJs?
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.geeksforgeeks.org/how-to-update-parent-data-from-child-component-in-vuejs/&quot;&gt;GFG Article&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://vueschool.io/articles/vuejs-tutorials/techniques-for-sharing-data-between-vue-js-components/&quot;&gt;Vue School Article&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Also take a look into official docs to know best practices for this.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;How to create and work with forms?&lt;/li&gt;
&lt;li&gt;How to use &lt;a href=&quot;https://vuejs.org/guide/components/v-model.html&quot;&gt;&lt;code&gt;v-model&lt;/code&gt;&lt;/a&gt;?&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Vite&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;While deciding how to setup proxy in Docker because I&apos;ve setup it using Vite and it works like charm in local but
while writing &lt;code&gt;Dockerfile&lt;/code&gt; I am able to figure out the solution.
&lt;ul&gt;
&lt;li&gt;Proxy is used in &lt;a href=&quot;https://youtu.be/VeNfHj6MhgA&quot;&gt;VueJs YouTube video&lt;/a&gt; and thats why I have followed it.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://vite.dev/config/server-options.html#server-proxy&quot;&gt;See this docs&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;While
&lt;a href=&quot;https://www.baeldung.com/linux/nginx-config-environment-variables#3-docker-compose&quot;&gt;handle environment variables in &lt;code&gt;nginx.conf&lt;/code&gt;&lt;/a&gt;
file in Docker environment. I have used ChatGPT read articles but didn&apos;t get to solution.&lt;/li&gt;
&lt;li&gt;How to work with &lt;a href=&quot;https://vite.dev/guide/env-and-mode.html&quot;&gt;different &lt;code&gt;.env&lt;/code&gt; files in Vite&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>project</category><category>project</category><category>frontend</category><author>Anshul Raj Verma</author></item><item><title>December Journal</title><link>https://arv-anshul.github.io/journal/2024/12</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/12</guid><description>Weekly Journal by ARV of December 2024</description><pubDate>Sun, 01 Dec 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 49 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;:star: Internship ended at LeapX after 5 Months.
&lt;ul&gt;
&lt;li&gt;They asked to continue after exams.&lt;/li&gt;
&lt;li&gt;I decided to go there to meet them.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Continue learning RNN (LSTM, GRU, Deep RNNs and BiDirectional RNNs) from CampusX.&lt;/li&gt;
&lt;li&gt;Trying to study for 12th boards but its hard to focus on it because (I think) its a whole new genre to study from
scratch (because I forgot all the things).&lt;/li&gt;
&lt;li&gt;Created a Jupyter Notebook around &lt;strong&gt;Search Keyword Classification&lt;/strong&gt; which I had work on while in internship.
&lt;ul&gt;
&lt;li&gt;Tackle all the problems like &lt;strong&gt;Category Classification, Intent Classification, Score Assigning and Similar Keywords
Grouping&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;:cat: Discovered this &lt;a href=&quot;https://github.com/catppuccin/userstyles&quot;&gt;interesting project&lt;/a&gt; on top of &lt;strong&gt;Stylus&lt;/strong&gt; browser
extension which apply &lt;strong&gt;Catppuccin Theme&lt;/strong&gt; on various popular websites such as GitHub, OpenAI, Perplexity, Spotify,
and &lt;a href=&quot;https://github.com/catppuccin/userstyles#-userstyles&quot;&gt;many more&lt;/a&gt;. Isn&apos;t this interesting to transform all the
website theme in one color palette.
&lt;ul&gt;
&lt;li&gt;After this I am considring to try this &lt;strong&gt;Catppuccin Theme&lt;/strong&gt; but I am afraid that I would like it because I don&apos;t
really like it&apos;s color pallete.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 50 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Exploring LLM agents with Langchain &amp;amp; Ollama. Also trying to built something around specially which I have already
built in internship.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Worked on &lt;a href=&quot;https://github.com/arv-anshul/notebooks/tree/main/llm/chat-with-data&quot;&gt;notebooks/llm/chat-with-data&lt;/a&gt;
scripts.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Explored &lt;strong&gt;python&apos;s &lt;code&gt;tree-sitter&lt;/code&gt; schema&lt;/strong&gt; for Zed in &lt;a href=&quot;https://github.com/zed-industries/zed/pull/21389&quot;&gt;PR#21389&lt;/a&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Is development of Zed editor very slow. @Hitesh Choudhary stated this in his recent video?&lt;/p&gt;
&lt;p&gt;IMO yes, because if you look closely it seems they are more focused on AI side of it. One of the most important
feature like builtin &lt;code&gt;ipython&lt;/code&gt; notebook is not their priority RN which is bad for most of the users (including me), I
constantly switching with VSCode for that.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Marimo is working on &lt;a href=&quot;https://docs.marimo.io/guides/exporting.html#export-to-wasm-powered-html&quot;&gt;&lt;code&gt;html-wasm&lt;/code&gt; export feature&lt;/a&gt; which is actually nice.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Marimo has multiple hidden capabilities you just have explore it &lt;em&gt;(you&apos;ll love it, i am sure about it)&lt;/em&gt;.&lt;/li&gt;
&lt;li&gt;Just waiting for the support of VSCode&apos;s builting notebook layout.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 51 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;:technologist: Worked on &lt;a href=&quot;https://github.com/arv-anshul/yt-comment-sentiment/commits?since=2024-12-15&amp;amp;until=2024-12-21&quot;&gt;&lt;code&gt;yt-comment-sentiment&lt;/code&gt;&lt;/a&gt; project.
&lt;ul&gt;
&lt;li&gt;Explored &lt;code&gt;pre-commit&lt;/code&gt; and &lt;code&gt;pytest&lt;/code&gt; while working on it.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;:pirate_flag: Found an amazing website &lt;a href=&quot;https://fmhy.net&quot;&gt;fmhy.net&lt;/a&gt; where linksof many piracy sites were listed.&lt;/li&gt;
&lt;li&gt;:man_facepalming: I accidentally deleted a file (where test for a FastAPI app is written) using &lt;code&gt;rm&lt;/code&gt; command and then
I had wrote it again from scratch.&lt;/li&gt;
&lt;li&gt;Update social links on website and more. See &lt;a href=&quot;https://github.com/arv-anshul/arv-anshul.github.io/commits?since=2024-12-15&amp;amp;until=2024-12-21&quot;&gt;&lt;code&gt;arv-anshul.github.io&lt;/code&gt;&lt;/a&gt; repo commits.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 52 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;:star_struck: Building frontend side of &lt;a href=&quot;https://github.com/arv-anshul/yt-comment-sentiment/commits?since=2024-12-15&amp;amp;until=2024-12-21&quot;&gt;&lt;code&gt;yt-comment-sentiment&lt;/code&gt;&lt;/a&gt; project using
&lt;a href=&quot;https://vuejs.org&quot;&gt;VueJs&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Learning &lt;strong&gt;VueJs&lt;/strong&gt; for frontend, &lt;em&gt;as I don&apos;t know TypeScript using only Javascript&lt;/em&gt;.&lt;/li&gt;
&lt;li&gt;Deployed both Backend on Render.com and Frontend on GitHub Pages.&lt;/li&gt;
&lt;li&gt;Also wrote about &lt;a href=&quot;https://arv-anshul.github.io/project/yt-comment-sentiment&quot;&gt;&lt;code&gt;yt-comment-sentiment&lt;/code&gt; project&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;I have decided to make this project big enough to be called as a product in itself. (दृढनिश्चय)&lt;/li&gt;
&lt;li&gt;I also think to write a marimo notebook which summarize my development/learning/inconsistency using LLMs. As I want
to summarize my whole year diary/journal with this idea.&lt;/li&gt;
&lt;li&gt;Wrote a blog on how to dockerize a FastAPI app which is managed by &lt;code&gt;uv&lt;/code&gt;, took reference of &lt;code&gt;yt-comment-sentiment&lt;/code&gt;
project.&lt;/li&gt;
&lt;li&gt;I have also learned many things around &lt;code&gt;pre-commit&lt;/code&gt; and &lt;code&gt;pytest&lt;/code&gt; which I have used in project recently.&lt;/li&gt;
&lt;li&gt;Installed &lt;code&gt;ghostty&lt;/code&gt; terminal emulator and it is great, looking forward to stick with it.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>december</category><author>Anshul Raj Verma</author></item><item><title>YT Comment Sentiment - ML Side</title><link>https://arv-anshul.github.io/projects/yt-comment-sentiment/ml</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/yt-comment-sentiment/ml</guid><description>YouTube comment sentiment analyzer/predictor using ML model.</description><pubDate>Mon, 04 Nov 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Data Handling Steps&lt;/h2&gt;
&lt;h3&gt;Data Gathering&lt;/h3&gt;
&lt;p&gt;For comment&apos;s sentiment prediction we need a data which has &lt;strong&gt;Comments&lt;/strong&gt; and its corresponding &lt;strong&gt;Sentiment&lt;/strong&gt;. And for
that we have used
&lt;a href=&quot;https://kaggle.com/datasets/cosmos98/twitter-and-reddit-sentimental-analysis-dataset&quot;&gt;dataset used in the course&lt;/a&gt;.&lt;/p&gt;
&lt;h3&gt;Data Preprocessing&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Preprocess by lowercasing the words.&lt;/li&gt;
&lt;li&gt;Cleaned the texts by removing stopwords and punctuations.&lt;/li&gt;
&lt;li&gt;Applied lemmetization using &lt;a href=&quot;https://www.nltk.org/api/nltk.stem.wordnet.html&quot;&gt;&lt;strong&gt;&lt;code&gt;WordNetLemmatizer&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Then, stemming using &lt;a href=&quot;https://www.nltk.org/api/nltk.stem.porter.html&quot;&gt;&lt;strong&gt;&lt;code&gt;PorterStemmer&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;EDA&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Checked &lt;strong&gt;target&lt;/strong&gt; column&apos;s distribution.&lt;/li&gt;
&lt;li&gt;Performed intensive EDA by creating many additional features using comment&apos;s chars, words and sentences.&lt;/li&gt;
&lt;li&gt;Generated wordcloud to see different sentiment&apos;s frequent words.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Model Building Steps&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Comment Vectorization&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Before transforming performed some basic preprocessing steps on comments like lowercasing, lemmetization and
stemming to make vectors more consistent.&lt;/li&gt;
&lt;li&gt;Evaluated multiple vectorization methods like BOW and TF-IDF.&lt;/li&gt;
&lt;li&gt;Also, performed hyperparameter tuning on vectorization methods by tuning parameters like &lt;code&gt;n_gram&lt;/code&gt; and
&lt;code&gt;max_features&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Chosen &lt;strong&gt;TF-IDF Vectorizer&lt;/strong&gt; model to transform comment texts into vectors which passes into ML Model.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Feature Engineering&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Created multiple new features using comments&apos; texts like word count, etc. which help the model to learn the
comments&apos; sentiment better.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Hyperparameter Tuning&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Used &lt;strong&gt;Bayesian Optimization Technique&lt;/strong&gt; to perform hyperparameter tuning on models.&lt;/li&gt;
&lt;li&gt;Tuned models on their most important parameters.&lt;/li&gt;
&lt;li&gt;Logged best parameter of each models with MLFlow to evaluate further.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Evaluation&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Used &lt;strong&gt;MLFlow UI&lt;/strong&gt; to check which model is performing well on the dataset.&lt;/li&gt;
&lt;li&gt;Evaluated on:
&lt;ol&gt;
&lt;li&gt;Overall &lt;code&gt;accuracy_score&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Different sentiment&apos;s &lt;code&gt;r1_score&lt;/code&gt;, &lt;code&gt;precision&lt;/code&gt; and &lt;code&gt;f1_score&lt;/code&gt; value.&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>project</category><category>project</category><category>ml</category><category>sentiment-analysis</category><author>Anshul Raj Verma</author></item><item><title>November Journal</title><link>https://arv-anshul.github.io/journal/2024/11</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/11</guid><description>Weekly Journal by ARV of November 2024</description><pubDate>Fri, 01 Nov 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 45 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;No work at LeapX because busy in Chhat Puja.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 46 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;@Aditya sir asked to access company&apos;s email and GitHub while I am not with my laptop. So, they changed my email&apos;s
password and get the work done.&lt;/li&gt;
&lt;li&gt;Update data fetching script in &lt;code&gt;campaign-analysis-api&lt;/code&gt; project with @Shubham.
&lt;ul&gt;
&lt;li&gt;They are migrating DB from MongoDB to Amazon RedShift.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 47 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Updated cron job to store campaigns data into MongoDB (hourly).
&lt;ul&gt;
&lt;li&gt;Used &lt;code&gt;loguru&lt;/code&gt; package for logging purpose and its awesome out of the box.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Added copies and region wise breakdown dataframe in &lt;code&gt;ad-campaign-bot&lt;/code&gt;/&lt;code&gt;caht-with-data&lt;/code&gt; project.&lt;/li&gt;
&lt;li&gt;Started working on &lt;code&gt;yt-comment-sentiment&lt;/code&gt; project (from DSMP course).&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 48 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Worked on &lt;code&gt;youtube-comment-sentiment&lt;/code&gt; project where I have integrated MLFlow and DVC and it is actually working as
expected.&lt;/li&gt;
&lt;li&gt;Started learning and practincing Deep Learning.
&lt;ul&gt;
&lt;li&gt;Learning from CampusX and Alexander Amini (&lt;a href=&quot;https://introtodeeplearning.com&quot;&gt;introtodeeplearning.com&lt;/a&gt;).&lt;/li&gt;
&lt;li&gt;CampusX has started &lt;a href=&quot;https://www.youtube.com/playlist?list=PLKnIA16_Rmvboy8bmDCjwNHgTaYH2puK7&quot;&gt;new playlist&lt;/a&gt; around
PyTorch.&lt;/li&gt;
&lt;li&gt;Also, noticed &lt;a href=&quot;https://keras.io/keras_3&quot;&gt;Keras 3.0&lt;/a&gt; for its backend compatiblity.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Understanding RNN and trying to implement it from scratch with &lt;code&gt;youtube-comment-sentiment&lt;/code&gt; project&apos;s dataset.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>november</category><author>Anshul Raj Verma</author></item><item><title>October Journal</title><link>https://arv-anshul.github.io/journal/2024/10</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/10</guid><description>Weekly Journal by ARV of October 2024</description><pubDate>Tue, 01 Oct 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 40 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Migrate &lt;a href=&quot;https://github.com/arv-anshul/dotfiles&quot;&gt;my dotfiles&lt;/a&gt; to &lt;a href=&quot;https://chezmoi.io&quot;&gt;&lt;strong&gt;chezmoi&lt;/strong&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;:star: 2 months of extension in internship at LeapX.ai.&lt;/li&gt;
&lt;li&gt;Tried &lt;code&gt;axum&lt;/code&gt; in Rust.&lt;/li&gt;
&lt;li&gt;Learning Rust from @piyushgargdev YouTube course, he teching from &lt;strong&gt;&quot;The Rust Book&quot;&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 41 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Came to Jabalpur on 9th October.&lt;/li&gt;
&lt;li&gt;Actively working with LeapX, remotely.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 42 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Stayed in Jabalpur and worked with LeapX.&lt;/li&gt;
&lt;li&gt;Had a 1hr long chat with @Dipanjan.&lt;/li&gt;
&lt;li&gt;Moving to PUNE from Jabalpur on 19th October.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 43 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Working with LeapX (@Haresh, @Saif and @Aditya) on Advance Analytics Dashboard APIs.&lt;/li&gt;
&lt;li&gt;Trying to meet some people in Pune but I didn&apos;t met due to work and lack of ...&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 44 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Storing campaigns data into MongoDB from FB APIs. Also solving some ongoing problem while storing &lt;em&gt;hourly&lt;/em&gt; data.&lt;/li&gt;
&lt;li&gt;Recommended @Dipanjan to @Aditya.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>october</category><author>Anshul Raj Verma</author></item><item><title>Canvas AI</title><link>https://arv-anshul.github.io/projects/canvas-ai</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/canvas-ai</guid><description>Parse and Analyse image containing mathematical expression or problem (it can be in a drawing format) using AI to give a structured response by leveraging Langchain framework. Also created API out of it using FastAPI which has containerized with Docker.</description><pubDate>Sun, 15 Sep 2024 00:00:00 GMT</pubDate><content:encoded>&lt;blockquote&gt;
&lt;p&gt;Inspired by &apos;1GbJQ7fHgqo&apos;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Prompt Examples&lt;/h2&gt;
&lt;p&gt;These are some samples which I have used to verify my AI and be sure that it is working fine. You can see the images and
their respective structured responses &lt;em&gt;(responses are written inside code-blocks, just below each image)&lt;/em&gt;.&lt;/p&gt;
&lt;h3&gt;Example 1&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://raw.githubusercontent.com/arv-anshul/canvas-ai/main/images/expr.png&quot; alt=&quot;expr.png&quot; /&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;{&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;expression&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;x=3;y=4;x+y=?&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;result&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;7&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;explanation&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;The sum of x and y is 7&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Example 2&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://raw.githubusercontent.com/arv-anshul/canvas-ai/main/images/expr-new.png&quot; alt=&quot;expr-new.png&quot; /&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;{&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;expression&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;(x + y)^2&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;result&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;225&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;explanation&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;Substitute the values of x and y in the expression and simplify using BODMAS.&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Example 3&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://raw.githubusercontent.com/arv-anshul/canvas-ai/main/images/car-tree.png&quot; alt=&quot;car-tree.png&quot; /&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;{&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;expression&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;10 km/hr * (50 meters / 1000 meters/km) * (3600 seconds / 1 hour)&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;result&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;18 seconds&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;explanation&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;The car is travelling at 10 km/hr and it has to cover 50 meters, so we can calculate the time it takes to cover the distance.&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;{&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;expression&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;10 km/hr * 50 meters&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;result&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;13.89 seconds&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;explanation&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;First convert 10 km/hr to meters/second, then divide 50 meters by the speed to get time.&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Example 4&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://raw.githubusercontent.com/arv-anshul/canvas-ai/main/images/square-diagonal.png&quot; alt=&quot;square-diagonal.png&quot; /&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;{&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;expression&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;√(10² + 10²)&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;result&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;14.14 m&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;explanation&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;The diagonal of a square forms a right-angled triangle with two sides of the square. Using Pythagoras theorem, we can calculate the diagonal.&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Example 5&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://raw.githubusercontent.com/arv-anshul/canvas-ai/main/images/water-tank.png&quot; alt=&quot;water-tank.png&quot; /&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;{&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;expression&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;pi*3^2*12, pi*3^2*5&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;result&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;360pi m^3, 45pi m^3&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;explanation&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;The tank is a cylinder with radius 3m and height 12m. The volume of a cylinder is pi*r^2*h. The filled water is also cylindrical with radius 3m and height 5m.&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
</content:encoded><category>project</category><category>project</category><category>genai</category><author>Anshul Raj Verma</author></item><item><title>September Journal</title><link>https://arv-anshul.github.io/journal/2024/09</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/09</guid><description>Weekly Journal by ARV of September 2024</description><pubDate>Sun, 01 Sep 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 36 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Now, Polars supports &lt;code&gt;altair&lt;/code&gt; charts with &lt;code&gt;.plot&lt;/code&gt; accessor.&lt;/li&gt;
&lt;li&gt;Heavy refactoring in &lt;code&gt;google-ads-api&lt;/code&gt; project.&lt;/li&gt;
&lt;li&gt;Finally, migrated &lt;code&gt;housing-dashboard&lt;/code&gt; project to Taipy from Streamlit.&lt;/li&gt;
&lt;li&gt;Helped @Sambhav with his Job Assignment related to simple RAG project.&lt;/li&gt;
&lt;li&gt;Learned how to use F-Droid and also installed some utility apps.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 37 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Getting some issue with DELL keyboard but now it is fixed.&lt;/li&gt;
&lt;li&gt;:technologist: Will not continue the internship after 3 months instead work on a big project to incorporate all my
learning there and make it a standout project.
&lt;ul&gt;
&lt;li&gt;Read &lt;a href=&quot;/blog/internship-leapx#after-leapx&quot;&gt;&lt;strong&gt;&quot;After LeapX&quot;&lt;/strong&gt; thoughts&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Added one more dataset in &lt;code&gt;ad-campaign-bot&lt;/code&gt; (Chat with campaign data) project, i.e. &lt;code&gt;age_gender_df&lt;/code&gt;. Used Facebook
Marketing API docs to understand the process and resultant data from the API.&lt;/li&gt;
&lt;li&gt;The &lt;code&gt;ad-campaign-bot&lt;/code&gt; or &lt;code&gt;campaign-bot-api&lt;/code&gt; project can drop the &lt;code&gt;facebook-sdk&lt;/code&gt; package from its dependency and only
use &lt;code&gt;httpx&lt;/code&gt; to make request with API because we are not taking the advantages of that SDK anyway instead we are just
making raw request to the API.&lt;/li&gt;
&lt;li&gt;I have got the Mass Driver Font from &lt;code&gt;assets.runno.dev&lt;/code&gt; domain.
&lt;ul&gt;
&lt;li&gt;Regular: &lt;a href=&quot;https://assets.runno.dev/md-io/md-io-regular.woff2&quot;&gt;https://assets.runno.dev/md-io/md-io-regular.woff2&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Italic: &lt;a href=&quot;https://assets.runno.dev/md-io/md-io-italic.woff2&quot;&gt;https://assets.runno.dev/md-io/md-io-italic.woff2&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Bold: &lt;a href=&quot;https://assets.runno.dev/md-io/md-io-bold.woff2&quot;&gt;https://assets.runno.dev/md-io/md-io-bold.woff2&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;I haven&apos;t got the &quot;Bold Italic&quot; variant. :disappointed:&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Created chrome extension to modify css of pre-defined websites. &lt;em&gt;I was thinking about this for 1 years.&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Downloaded the crack version of Aldente (Charger Limiter App) from &lt;strong&gt;&lt;code&gt;macbed.com&lt;/code&gt;&lt;/strong&gt; and in order to make it work I
have to &lt;strong&gt;block Aldente&apos;s outgoing connections&lt;/strong&gt;, so for this I have installed
&lt;a href=&quot;https://objective-see.com/products/lulu.html&quot;&gt;&lt;strong&gt;Lulu app&lt;/strong&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 38 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;After watching a &lt;a href=&quot;https://youtu.be/1GbJQ7fHgqo&quot;&gt;YouTube Video&lt;/a&gt;, I&apos;ve created a new project called
&lt;a href=&quot;https://github.com/arv-anshul/canvas-ai&quot;&gt;&lt;code&gt;canvas-ai&lt;/code&gt;&lt;/a&gt; which can analyse image containing mathematical expression or
problem and return a structured response. My first personal GenAI project and its awesome :star_struck:.&lt;/li&gt;
&lt;li&gt;New project from LeapX to scrape many-many different webpages to build RAG models. Already scraped &lt;em&gt;Facebook
Marketing API docs&lt;/em&gt; and submitted to @Shubham.&lt;/li&gt;
&lt;li&gt;Used &lt;code&gt;clap&lt;/code&gt; crate in &lt;a href=&quot;https://github.com/arv-anshul/thrust/tree/main/md_badges&quot;&gt;&lt;code&gt;md_badges&lt;/code&gt;&lt;/a&gt; cli tool.
&lt;ul&gt;
&lt;li&gt;You can also download the &lt;code&gt;md_badges&lt;/code&gt; cli tool in your system as binary with &lt;code&gt;cargo install&lt;/code&gt; command, &lt;em&gt;see
project&apos;s &lt;a href=&quot;https://github.com/arv-anshul/thrust/blob/main/md_badges/README.md&quot;&gt;README.md&lt;/a&gt; form more info&lt;/em&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;:sneezing_face: Ill for last two days :sneezing_face:&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 39 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Replace &lt;code&gt;Pylance&lt;/code&gt; with &lt;code&gt;basedpyright&lt;/code&gt; in VSCode.&lt;/li&gt;
&lt;li&gt;Successfully configures Zed IDE with &lt;code&gt;basedpyright&lt;/code&gt; and &lt;code&gt;ruff&lt;/code&gt; extensions.
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;I think now I can try to ditch VSCode editor.&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;/li&gt;
&lt;li&gt;Enabled Codeium AI completion in VSCode.&lt;/li&gt;
&lt;li&gt;Trying Zed and Marimo inplace of classic apps.&lt;/li&gt;
&lt;li&gt;:star: New project started in DSMP 2.0. It is a Chrome Extension for YouTube to perform sentiment analysis on video&apos;s
comments.&lt;/li&gt;
&lt;li&gt;Connected with @Mohit and @Dipanjan to collaborate on new DSMP 2.0 project and had a nice discussion around it.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>september</category><author>Anshul Raj Verma</author></item><item><title>August Journal</title><link>https://arv-anshul.github.io/journal/2024/08</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/08</guid><description>Weekly Journal by ARV of August 2024</description><pubDate>Thu, 01 Aug 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 32 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Finetune the &lt;strong&gt;DistilBert Model&lt;/strong&gt; from HuggingFace for &lt;code&gt;search-keywords&lt;/code&gt; classification.&lt;/li&gt;
&lt;li&gt;:handshake: Me and @Pushpam met with @Vishal (LeapX) and had an amazing talk at lunch.&lt;/li&gt;
&lt;li&gt;Created a collab notebook which further finetune pre-trained LeapX&apos;s Keywords Classifier Model with more data and
automatically pushes it in HuggingFace models repository.&lt;/li&gt;
&lt;li&gt;Learned more about LangChain&apos;s LCEL and re-built the &lt;code&gt;campaign-bot&lt;/code&gt; from scratch using it.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 33 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Scheduled a cron for &lt;code&gt;properties-scraper&lt;/code&gt; project on GitHub Actions.&lt;/li&gt;
&lt;li&gt;Made changes in &lt;code&gt;campaign-bot&lt;/code&gt; streamlit app and also deployed it on HF Spaces.&lt;/li&gt;
&lt;li&gt;Switched from bash script to python script to run the &lt;code&gt;properties-scraper&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Created &lt;a href=&quot;https://github.com/arv-anshul/thrust/tree/main/md_badges&quot;&gt;&lt;code&gt;md_badges&lt;/code&gt;&lt;/a&gt; project in Rust.&lt;/li&gt;
&lt;li&gt;Update &lt;code&gt;mkdocs-material&lt;/code&gt; for website but this introduces some minor bugs &lt;em&gt;due to removal of Microsoft icons from
SimpleIcons repository&lt;/em&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 34 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;PiyushGarg started new playlist around &lt;strong&gt;The Rust Book&lt;/strong&gt; (online version).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;uv&lt;/code&gt; v0.3.0&lt;/strong&gt; allow support for &lt;code&gt;uv init&lt;/code&gt;, &lt;code&gt;uv add&lt;/code&gt;, &lt;code&gt;uv remove&lt;/code&gt;, &lt;code&gt;uv run&lt;/code&gt; and many more. Read the
&lt;a href=&quot;https://astral.sh/blog/uv-unified-python-packaging&quot;&gt;release blog&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Aditya sir posted on &lt;code&gt;housing-dashboard&lt;/code&gt; project
&lt;a href=&quot;https://www.linkedin.com/posts/adityaojas_datascience-locationintelligence-leapx-activity-7231631853575663618-yp4-&quot;&gt;on LinkedIn&lt;/a&gt;,
he named it &lt;strong&gt;LeapX Localyzer&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;New &lt;code&gt;google-ads-api&lt;/code&gt; project to setup new GoogleAds campaign where keywords are choosen using ML algo.&lt;/li&gt;
&lt;li&gt;Updated GitHub profile README &lt;a href=&quot;https://github.com/twpayne&quot;&gt;inspired from &lt;code&gt;@twpayne&lt;/code&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 35 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Migrating &lt;code&gt;housing-dashboard&lt;/code&gt; from Streamlit to Taipy.&lt;/li&gt;
&lt;li&gt;Completed 2 Months at LeapX.ai.&lt;/li&gt;
&lt;li&gt;Bought new smartphone &quot;Nothing Phone 2a&quot;.&lt;/li&gt;
&lt;li&gt;Writing my journal in draft form in Google Notes.&lt;/li&gt;
&lt;li&gt;Deployed &lt;code&gt;google-ads-api&lt;/code&gt; project at Render.com, after a long &amp;amp; hectic bugging session with @Pratham.&lt;/li&gt;
&lt;li&gt;:package: &lt;code&gt;uv&lt;/code&gt; new release &lt;code&gt;0.5.0&lt;/code&gt; brings support for build-less packages. So now I can completely ditch &lt;code&gt;rye&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Migrated to &lt;code&gt;uv&lt;/code&gt; in &lt;code&gt;diary&lt;/code&gt; and &lt;code&gt;arv-anshul.github.io&lt;/code&gt; repos from &lt;code&gt;rye&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Talk with @TanuKumari regarding college and SIH project.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>august</category><author>Anshul Raj Verma</author></item><item><title>LeapX - Internship</title><link>https://arv-anshul.github.io/blog/2024/internship-leapx</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/internship-leapx</guid><description>Joined LeapX.ai as Data Science Intern from 27 June, 2024 for 3 months.</description><pubDate>Sat, 13 Jul 2024 09:13:00 GMT</pubDate><content:encoded>&lt;p&gt;Joined LeapX.ai as Data Science Intern from 27 June, 2024 for 3 months.&lt;/p&gt;
&lt;h2&gt;LeapX Projects&lt;/h2&gt;
&lt;p&gt;Project done while working with LeapX as Data Science Intern.&lt;/p&gt;
&lt;h3&gt;Properties Scraper&lt;/h3&gt;
&lt;p&gt;Project scrapes data from Housing.com website and dump into MongoDB after basic transformation using Polars, I&apos;ve used
Scrapy to scrape data. Wrote a python script which automate the process of scraping multiple city in one go.&lt;/p&gt;
&lt;h3&gt;Housing Dashboard&lt;/h3&gt;
&lt;p&gt;A dashboard which shows affluent areas of a city after applying clustering on the real estate data of the city.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Uses Taipy framework to create dashboard.&lt;/li&gt;
&lt;li&gt;Fetch properties data from MongoDB.&lt;/li&gt;
&lt;li&gt;Perform clustering and plot circles on map of selected city with its &lt;em&gt;affluence rank&lt;/em&gt; and other metrics.&lt;/li&gt;
&lt;li&gt;Deployed on Hugging Face Spaces.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;:llama: Ad Campaign Bot&lt;/h3&gt;
&lt;p&gt;A Facebook Ads Campaign Bot powered by OpenAI LLMs where users can query their campaign related questions.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Bot is flexible enough to answer user&apos;s query on multiple camping data format such as &lt;em&gt;daily or hourly campaign data&lt;/em&gt;.&lt;/li&gt;
&lt;li&gt;Bot can also display graphs/plots related to each query (with some limitations).&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Campaign Dashboard&lt;/h3&gt;
&lt;p&gt;Streamlit dashboard to show insights around Facebook Ads Campaign using Data Analysis and charts using campaign metrics
like CTL, CPM, CPC, CTR and more.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Refactored code given by @Aditya.&lt;/li&gt;
&lt;li&gt;Deployed on Hugging Face Spaces.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;After LeapX&lt;/h2&gt;
&lt;p&gt;After working for 3 months with LeapX, there are some points I&apos;ve want to discuss:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Just discontinue the internship and start focusing on personal projects and further learning and try to gather
in-depth knowledge around Deep Learning concepts and more.&lt;/li&gt;
&lt;li&gt;Continue the internship and start learning deep learning from &lt;strong&gt;CampusX&lt;/strong&gt; side-by-side which will be a win-win
situation best utilization of the time.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>blog</category><category>internship</category><category>thoughts</category><author>Anshul Raj Verma</author></item><item><title>July Journal</title><link>https://arv-anshul.github.io/journal/2024/07</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/07</guid><description>Weekly Journal by ARV of July 2024</description><pubDate>Mon, 01 Jul 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 27 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Created new GitHub account with &lt;code&gt;arv@leapx.ai&lt;/code&gt; email to work with LeapX. (But I don&apos;t get this.)
&lt;ul&gt;
&lt;li&gt;There is no sense of creating new account just to commit in company&apos;s github organization.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Learning many things while working with LeapX.ai.
&lt;ul&gt;
&lt;li&gt;Finished the first interface of two paged streamlit dashboard.&lt;/li&gt;
&lt;li&gt;Started working on new project which uses &lt;code&gt;openai&lt;/code&gt; and &lt;code&gt;llama-index&lt;/code&gt; and it is a kind of AI Dashboard.&lt;/li&gt;
&lt;li&gt;Aditya said that &quot;Team members are liking my work&quot;.&lt;/li&gt;
&lt;li&gt;Wrote &lt;code&gt;scrapy&lt;/code&gt; scrapper from scratch to scrape Housing.com and pushed to LeapX.ai GH-ORG.&lt;/li&gt;
&lt;li&gt;Wrote multiple parser to parse &lt;code&gt;html&lt;/code&gt; pages (using &lt;code&gt;selectolax&lt;/code&gt;) of government website&apos;s pages where RERA
registered agents were listed.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Watched movie &lt;strong&gt;&quot;The Whale&quot;&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 28 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Finally, found the Astral&apos;s &lt;code&gt;uv&lt;/code&gt; official docs from their GitHub repo&apos;s deployment section. The docs are present at
&lt;a href=&quot;https://astral-sh.github.io/uv/&quot;&gt;astral-sh.github.io/uv&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Watched &lt;strong&gt;Love Life&lt;/strong&gt; (2022) movie.&lt;/li&gt;
&lt;li&gt;Binam bought &lt;strong&gt;Macbook Air M2&lt;/strong&gt; (8GB - 256GB).&lt;/li&gt;
&lt;li&gt;Fixed many bugs in &lt;a href=&quot;https://github.com/arv-anshul/dotfiles&quot;&gt;arv-anshul/dotfiles&lt;/a&gt; repository while setting-up Binam&apos;s macbook.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Internship at &lt;strong&gt;LeapX.ai&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;2024-07-08&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Started refactoring the big-messy-code (where all &lt;code&gt;df&lt;/code&gt;s were stored in &lt;code&gt;st.session_state&lt;/code&gt;) and pushed changes to a new
repository &lt;code&gt;campaign-dashboard&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Try scraping data of different major cities like Gurgaon, Delhi, Hyderabad, Mumbai, etc. but failed due to blocking.
So Aditya, asked Pritam (USA based guy with better knowledge) so he told &quot;use slow and randomized scraping using
Docker&quot;.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;2024-07-09&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;🤒 Took a day-off due to fever and loose motion.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;2024-07-10&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;More refactoring in &lt;code&gt;campaign-dashboard&lt;/code&gt; (almost completed).&lt;/li&gt;
&lt;li&gt;Downloaded MongoDB Compass in laptop to connect with LeapX cluster where scraped data form Housing.com get stored.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;2024-07-11&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Created HuggingFace account with &lt;code&gt;arv@leapx.ai&lt;/code&gt; ID.&lt;/li&gt;
&lt;li&gt;Learned how to use HF Spaces and created a GH Action in &lt;code&gt;campaign-dashboard&lt;/code&gt; repo to push code from GH to LeapX&apos;s HF
Space where the Streamlit app gets deployed. (done whole thing in 1 Hour :scream:)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;2024-07-12&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Learned and added Scrapy Pipeline to move scraped data into MongoDB cluster; also added Data Transformation (using
Polars) code for scraped data.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Week 29 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Maintaining the explanation or description of projects done with LeapX as Data Science Intern in
&lt;a href=&quot;/blog/internship-leapx&quot;&gt;thoughts&lt;/a&gt; folder.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Internship at &lt;strong&gt;LeapX.ai&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;2024-07-15&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Modified &lt;code&gt;housing-dashboard&lt;/code&gt; so that it can ingest data from MongoDB.&lt;/li&gt;
&lt;li&gt;Scraped 10k+ data of &lt;strong&gt;Delhi&lt;/strong&gt; and &lt;strong&gt;Gurgaon&lt;/strong&gt; city using &lt;code&gt;properties-scraper&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;housing-dashboard&lt;/code&gt; is running on HuggingFace Spaces.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;2024-07-16&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Discussed &lt;code&gt;properties-scraper&lt;/code&gt; to automate it with @Anurag.&lt;/li&gt;
&lt;li&gt;Modified &lt;code&gt;properties-scraper&lt;/code&gt; codebase for the same.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;em&gt;[WIP]&lt;/em&gt;&lt;/strong&gt; Also wrote code to scrape &lt;strong&gt;Maharastra RERA Agents&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;2024-07-17&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Meeting with @Pratham for &lt;code&gt;campaign-bot&lt;/code&gt; to transform it into an API.&lt;/li&gt;
&lt;li&gt;Meeting with @Vishal &amp;amp; @Aditya for &lt;code&gt;housing-dashboard&lt;/code&gt; problems.&lt;/li&gt;
&lt;li&gt;Discussed workflow and API architecture of &lt;code&gt;campaign-bot&lt;/code&gt; API and created flowchart diagram for the same.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Currently assigned Projects to @Anshul&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;Hi Aditya, I am Anshul, currently assigned with almost 4 projects and it&apos;s hard to manage and discuss all of them with&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;different team members. It will be very helpful if you prioritize these projects so that I can work with them&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;efficiently without taking too much stress.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;**Projects Description**&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;1.&lt;/span&gt;&lt;span&gt; `properties-scraper`&lt;/span&gt;&lt;span&gt;: Wrap the project with Docker so that it can scrape multiple cities properties data using &lt;/span&gt;&lt;span&gt;`cron`&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;   job. There are many modifications occur in this project for this like dynamically load &lt;/span&gt;&lt;span&gt;`URL`&lt;/span&gt;&lt;span&gt; and &lt;/span&gt;&lt;span&gt;`city`&lt;/span&gt;&lt;span&gt; name. I&apos;ve&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;   already discussed about it with @Anurag.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;2.&lt;/span&gt;&lt;span&gt; `housing-dashboard`&lt;/span&gt;&lt;span&gt;: Yesterday (2024-07-17) in a meeting with @Aditya and @Vishal; we discussed some problems&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;   regarding this project and decided to make some major changes in this project.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;3.&lt;/span&gt;&lt;span&gt; `campaign-bot`&lt;/span&gt;&lt;span&gt;: Yesterday (2024-07-17) meeting with @Pratham; we discussed about creating an API system around this&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;   to seemlessly integrate this bot in frontend.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;4.&lt;/span&gt;&lt;span&gt; `campaign-dashboard`&lt;/span&gt;&lt;span&gt;: Recently refactored this project (code given by @Aditya) and deployed on HuggingFace Spaces but&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;   project has very high latency due to bad code management. So, this project also need improvements to handle latency&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;   and needs better architecture.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Best Regards, Anshul Raj Verma Data Science Intern&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;2024-07-18&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Meeting with @Pratham and @Aditya for &lt;code&gt;campaign-bot&lt;/code&gt; API.&lt;/li&gt;
&lt;li&gt;There is a little progress in &lt;code&gt;campaign-bot&lt;/code&gt; code but getting unexpected result after passing &lt;code&gt;user_prompt&lt;/code&gt; in
&lt;code&gt;query_pipeline&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Pipeline is not working as expected and there are more concerns like how to retrive data for visualization and pass it
as API response.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;2024-07-21&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Building &lt;code&gt;campaign-bot-api&lt;/code&gt; with @Aditya and @Pratham and almost completed it. Made with FastAPI with JWT auth (learned
on-the-go).&lt;/p&gt;
&lt;h2&gt;Week 30 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Droping the idea of journaling of LeapX.ai work.&lt;/li&gt;
&lt;li&gt;Learning LangChain and &lt;a href=&quot;https://python.langchain.com/v0.2/docs/tutorials/rag&quot;&gt;RAG&lt;/a&gt; for internship projects.&lt;/li&gt;
&lt;li&gt;Discussed about &lt;strong&gt;User&apos;s Search Intent&lt;/strong&gt; classification with @Gagandeep &amp;amp; @Vishal.
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.algolia.com/blog/ux/what-is-meant-by-search-intent-and-what-are-the-different-types/&quot;&gt;What is meant by search intent?&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.algolia.com/blog/ai/how-to-identify-user-search-intent-using-ai-and-machine-learning/&quot;&gt;Identify user search intent with machine learning.&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Completed my first month at LeapX.ai as Data Science Intern.
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.linkedin.com/posts/arv-anshul_internship-datascienceintern-activity-7222893936674062336-km4E&quot;&gt;LinkedIn Post&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 31 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Team dinner at LeapX.ai. They order meal for me too :partying_face:&lt;/li&gt;
&lt;li&gt;Worked on same project &lt;strong&gt;Search Intent Classifier&lt;/strong&gt; project whole week. Trained &lt;code&gt;distilbert-base-uncased&lt;/code&gt; model 2
times.&lt;/li&gt;
&lt;li&gt;:medal: First time following and loving olympics matches and athlete :saluting_face:
&lt;ul&gt;
&lt;li&gt;:star_struck: Loving Lakshya Sen and Hockey Team performaces.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Using and kind of loving the new alternative of Jupyter Notebook; &lt;a href=&quot;https://marimo.io&quot;&gt;&lt;strong&gt;Marimo&lt;/strong&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>july</category><author>Anshul Raj Verma</author></item><item><title>LeapX - Interview</title><link>https://arv-anshul.github.io/blog/2024/interview-leapx</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/interview-leapx</guid><description>My first interview call from a real-estate startup LeapX on 14 June, 2024.</description><pubDate>Fri, 14 Jun 2024 17:00:00 GMT</pubDate><content:encoded>&lt;p&gt;&lt;a href=&quot;../../journal/2024/06.md#week-24-journal&quot;&gt;Week 24 Journal&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Aditya reached me &amp;gt; conducted a meeting on Microsoft Teams &amp;gt; ask questions related to projects, education &amp;gt; other two
co-founder joined the meeting &amp;gt; ask to solve a problem in Real Estate domain&lt;/p&gt;
&lt;hr /&gt;
&lt;h2&gt;Problem Statement&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;On what parameters we can classify a city with different expensive/affluent region?&lt;/li&gt;
&lt;li&gt;How can we cluster/classify expensive region of a city?&lt;/li&gt;
&lt;li&gt;How can we bound/decide a region as an affluent region?&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Points for Explanation&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;We can consider city&apos;s mean area (sq ft.), mean price, mean price (per sq ft), BHK, properties count.&lt;/li&gt;
&lt;li&gt;An area become expensive due to the availability of some commodity in those areas like hospitals, banks, luxury
restaurants, gym, airport, hotels, and more. These commodities increases the price of those areas very high.&lt;/li&gt;
&lt;li&gt;If the area has some major development project (by government or private) going to take place.&lt;/li&gt;
&lt;li&gt;We can consider point number 2 and 3 but if you want to gather those type of data then it is very difficult.
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;For example,&lt;/strong&gt; if you want the data of luxurious restaurants then you have to decide a threshold which defines
luxurious restaurants and what about data availability of all restaurants present in city. This thing hard to
gather for other commodities as well like airport, pubs, banks, and more.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;For extreme cases,&lt;/strong&gt; we can consider crime rate, transportation, highway, medical facilities, political
intervention/advantage, community tension, etc.&lt;/li&gt;
&lt;li&gt;We can also check current affairs of those which we are going recommend after the classification of Model because if
the current situation in those is not good then we must not consider those areas.&lt;/li&gt;
&lt;li&gt;As we can see above parameters are hard to gather for a ML Model but we can build a clustering algorithm which can
cluster similar properties and from that&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Apply Clustering&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;If we apply clustering on properties we can say that &lt;strong&gt;&quot;This property in this area is similar to that property in that
area&quot;&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Apply Classification&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;We have not much parameters through which we can classify areas.&lt;/li&gt;
&lt;li&gt;We have to take many majors to evaluate the model because we don&apos;t have enough parameters to classify them.&lt;/li&gt;
&lt;/ul&gt;
&lt;hr /&gt;
&lt;blockquote&gt;
&lt;p&gt;[!NOTE] Aditya&apos;s Thought on Above Explanation&lt;/p&gt;
&lt;p&gt;This is good thought process, I&apos;d further like you to emphasize on how you would benchmark certain landmarks, high-end
cafes, high street markets, expensive residential societies etc. that represent affluent and wealthy
localities/radius.&lt;/p&gt;
&lt;p&gt;I&apos;d like you to think of a methodology, and basis that, represent those radius on a map.&lt;/p&gt;
&lt;p&gt;We can take Gurgaon for an example.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Decide Affluent Region&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;We should first gather data about those landmarks which are considered as luxurious/expensive in Gurgaon.&lt;/li&gt;
&lt;li&gt;Then calculate distance between them and societies (we are considering to cluster/classify as affluent).&lt;/li&gt;
&lt;li&gt;Then assign a benchmark/luxury value (between 1 to 10) to those landmarks which create a &lt;em&gt;sort of&lt;/em&gt; association
between societies and landmarks.&lt;/li&gt;
&lt;li&gt;&lt;s&gt;Then create a function which aggregate &quot;distance between societies and landmarks&quot; and &quot;benchmark values&quot;.&lt;/s&gt;&lt;/li&gt;
&lt;li&gt;Then gather comprehensive data about these societies like property prices, rental prices, people annual income, etc.
which tells us about societies current value among other societies. These parameters create distinction among
societies itself.&lt;/li&gt;
&lt;li&gt;Then apply K-Means Clustering on the whole gathered data and then plot the clustering metrics like &lt;code&gt;silhouette_score&lt;/code&gt;
to determine the model&apos;s wellness.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;:ADDITIONAL PARAMETERS:&lt;/strong&gt; We can extract societies and landmark rankings and ratings from different real-estate
websites which further enhance our model&apos;s performance.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;This process help us to cluster similar luxurious societies and then we can &lt;strong&gt;infer or bound affluent area&lt;/strong&gt; in the
given city.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;landmark &amp;gt; lat long &amp;gt; radius (2 km) &amp;gt; localities &amp;gt; sort on price (per sq ft) localities (lat long) &amp;gt; landmarks &amp;gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;hr /&gt;
&lt;h2&gt;Decide on the Basis of Sector&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;I have all properties data.&lt;/li&gt;
&lt;li&gt;Cluster affluent properties.&lt;/li&gt;
&lt;li&gt;Group by on localities/sector.&lt;/li&gt;
&lt;li&gt;Now you know how many affluent properties are there in each localities.&lt;/li&gt;
&lt;li&gt;Why localities/sector; not a certain radius of area because whole city is divided into localities/sector which means
&lt;blockquote&gt;
&lt;p&gt;If you want to mark an area as affluent then that are must be in any sector which means that sector is affluent.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;/li&gt;
&lt;li&gt;If any sector has many expensive properties and or that sector is around luxurious landmarks then we can declare that
sector as affluent area.&lt;/li&gt;
&lt;li&gt;We can create two clustering model one for properties and another for landmarks (this also help us to identify).&lt;/li&gt;
&lt;li&gt;how can we&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Decide with DBSCAN&lt;/h2&gt;
&lt;p&gt;After applying DBSCAN all the propeties were clustered as noise data point.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Ultra luxury (lat long) &amp;gt; find closest property &amp;gt; find both&apos;s average &amp;gt;&lt;/p&gt;
&lt;/blockquote&gt;
</content:encoded><category>blog</category><category>interview</category><category>project</category><category>internship</category><category>thoughts</category><author>Anshul Raj Verma</author></item><item><title>Intro to Deep Learning</title><link>https://arv-anshul.github.io/blog/2024/intro-to-deep-learning</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/intro-to-deep-learning</guid><description>List of some related concepts of Deep Learning like Perceptron and MLP; including notations, coding examples.</description><pubDate>Mon, 10 Jun 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Machine Learning VS Deep Learning&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;As the shape of data increases the ML models cannot able to capture its underlying patterns but deep learning
algorithms capture the complex relationship very well.&lt;/li&gt;
&lt;li&gt;ML algorithms uses different techniques to learn patterns from data like linear line, spliting criteria, etc. but
Perceptron is the building block of DL algorithms which helps to capture almost every patterns of the data.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Perceptron&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Perceptron the building block of Deep Learning.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;https://upload.wikimedia.org/wikipedia/commons/thumb/f/ff/Rosenblattperceptron.png/640px-Rosenblattperceptron.png&quot; alt=&quot;perceptron&quot; /&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;\sum&lt;/span&gt;&lt;span&gt; = w_1x_1 + w_2x_2 + ... + w_nx_n + b&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Now after calculating the &lt;code&gt;#!math \sum&lt;/code&gt; you will use a activation function &lt;code&gt;#!math \varphi&lt;/code&gt; which is applied to the
weighted sum to introduce non-linearity.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;For example, &lt;code&gt;#!math \varphi&lt;/code&gt; can be a step function whose output is either 0 or 1.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Important Points on Perceptron&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Perceptron split the data in two classes.&lt;/li&gt;
&lt;li&gt;Perceptron creates a lines in 2D, plane in 3D and hyperplane in 4D onwards.&lt;/li&gt;
&lt;li&gt;Perceptron&apos;s geometric intuition is very similar to Linear Regression algorithm.&lt;/li&gt;
&lt;li&gt;Perceptron is limited to classify only linearly (or sort of linear) separable classes.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Limitation&lt;/h3&gt;
&lt;p&gt;Perceptron only works on linear data it doesn&apos;t learn non-linear data because perceptron is a linear model which draws a
line/plane/hyperplane on datasets.&lt;/p&gt;
&lt;h2&gt;Multi-Layer Perceptron (MLP)&lt;/h2&gt;
&lt;p&gt;A &lt;strong&gt;Multi-Layer Perceptron (MLP)&lt;/strong&gt; is a class of feedforward artificial neural networks that consist of multiple layers
of nodes in a directed graph. Each node, except for the input nodes, represents a neuron that uses a non-linear
activation function. MLPs are capable of learning complex patterns in data, including non-linear relationships, making
them widely used in machine learning tasks like classification, regression, and feature extraction.&lt;/p&gt;
&lt;p&gt;By using a single perceptron, we are limited to learning only linear decision boundaries. This restricts its ability to
model more complex datasets with inherent non-linear relationships. To overcome this limitation, we can add more
perceptrons in a structured way to create a &lt;strong&gt;Multi-Layer Perceptron&lt;/strong&gt;.&lt;/p&gt;
&lt;h3&gt;Why Don’t We Use Only One Layer Instead?&lt;/h3&gt;
&lt;p&gt;A single-layer perceptron can only model linearly separable data. For example, tasks like distinguishing between two
classes in XOR logic cannot be achieved by a single-layer perceptron, as its decision boundary is inherently linear.
However, real-world datasets are often non-linear in nature.&lt;/p&gt;
&lt;p&gt;Adding hidden layers in an MLP allows the network to transform input features through non-linear activation functions,
enabling it to create complex decision boundaries. These hidden layers progressively learn higher-order features, making
MLP a universal approximator of functions, as proven by the Universal Approximation Theorem.&lt;/p&gt;
&lt;h3&gt;How Does MLP Capture Non-Linearity?&lt;/h3&gt;
&lt;p&gt;MLPs capture non-linearity through two primary mechanisms:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Non-Linear Activation Functions:&lt;/strong&gt; Non-linear activation functions like ReLU, Sigmoid, or Tanh introduce the
ability to model complex patterns in the data. Without these functions, the MLP would behave like a linear model,
regardless of the number of layers.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Layered Structure:&lt;/strong&gt; Each hidden layer processes inputs to extract increasingly abstract features. These features,
when passed through activation functions, enable the network to learn representations that are non-linear
transformations of the original data.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;By stacking layers, the network learns a hierarchy of features, where lower layers might capture simple patterns (like
edges in an image), and deeper layers capture more abstract representations (like shapes or objects).&lt;/p&gt;
&lt;h3&gt;Forward Pass in MLP&lt;/h3&gt;
&lt;p&gt;The &lt;strong&gt;forward pass&lt;/strong&gt; is the process of passing input data through the network to compute the output predictions. It
involves the following steps:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Input Layer:&lt;/strong&gt; The input data is fed into the network as feature vectors.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Hidden Layers:&lt;/strong&gt; Each hidden layer applies a weighted sum of inputs followed by a bias term and an activation
function. Mathematically, for a hidden layer ( l ):&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h4&gt;Hidden Layers in Notation&lt;/h4&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;h^{l} = f(W^{l}h^{(l-1)} + b^{l})&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;where:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;#!math W^{l}&lt;/code&gt; is the weight matrix for layer &lt;code&gt;#!math l&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math b^{l}&lt;/code&gt; is the bias vector for layer &lt;code&gt;#!math l&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math f&lt;/code&gt; is the activation function (e.g., ReLU).&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math h^{(l-1)}&lt;/code&gt; is the output from the previous layer.&lt;/li&gt;
&lt;/ul&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Output Layer:&lt;/strong&gt; The final layer produces predictions, often applying a specific activation function (e.g., softmax
for classification or linear activation for regression).&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; keras &lt;/span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; Sequential&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; keras.layers &lt;/span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; Dense&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Define a simple MLP model&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;model = Sequential([&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Dense(&lt;/span&gt;&lt;span&gt;16&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;activation&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&apos;relu&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;input_shape&lt;/span&gt;&lt;span&gt;=(&lt;/span&gt;&lt;span&gt;4&lt;/span&gt;&lt;span&gt;,)),  &lt;/span&gt;&lt;span&gt;# Input layer&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Dense(&lt;/span&gt;&lt;span&gt;8&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;activation&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&apos;relu&apos;&lt;/span&gt;&lt;span&gt;),                     &lt;/span&gt;&lt;span&gt;# Hidden layer&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Dense(&lt;/span&gt;&lt;span&gt;1&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;activation&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&apos;sigmoid&apos;&lt;/span&gt;&lt;span&gt;)                  &lt;/span&gt;&lt;span&gt;# Output layer&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;])&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;model.summary()&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;The forward pass results in the computation of predictions based on the current weights and biases.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Backward Propagation in MLP&lt;/h3&gt;
&lt;p&gt;The &lt;strong&gt;backward propagation&lt;/strong&gt; algorithm is used to train the MLP by adjusting weights and biases to minimize the error
between predicted and actual outputs. It works in the following steps:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Compute Loss:&lt;/strong&gt; A loss function (e.g., Mean Squared Error for regression or Cross-Entropy Loss for classification)
measures the error between the predicted output and the true labels.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Backpropagation of Errors:&lt;/strong&gt; The error is propagated backward through the network using the chain rule of calculus
to compute the gradient of the loss function with respect to each weight and bias. The gradients for each parameter
are computed layer by layer in reverse order.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Update Weights and Biases:&lt;/strong&gt; Using the computed gradients, the weights and biases are updated using an optimization
algorithm like Gradient Descent or its variants (e.g., Adam, RMSprop):&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h4&gt;Backward Propagation with Notation&lt;/h4&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;W^{l} = W^{l} - &lt;/span&gt;&lt;span&gt;\eta&lt;/span&gt;&lt;span&gt; \frac&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;\partial&lt;/span&gt;&lt;span&gt; \mathcal&lt;/span&gt;&lt;span&gt;{L}}{&lt;/span&gt;&lt;span&gt;\partial&lt;/span&gt;&lt;span&gt; W^{l}}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;b^{l} = b^{l} - &lt;/span&gt;&lt;span&gt;\eta&lt;/span&gt;&lt;span&gt; \frac&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;\partial&lt;/span&gt;&lt;span&gt; \mathcal&lt;/span&gt;&lt;span&gt;{L}}{&lt;/span&gt;&lt;span&gt;\partial&lt;/span&gt;&lt;span&gt; b^{l}}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;where:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;#!math \eta&lt;/code&gt; is the learning rate.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math \mathcal{L}&lt;/code&gt; is the loss function.&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; torch&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; torch.nn &lt;/span&gt;&lt;span&gt;as&lt;/span&gt;&lt;span&gt; nn&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; torch.optim &lt;/span&gt;&lt;span&gt;as&lt;/span&gt;&lt;span&gt; optim&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Define a simple MLP model&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;class&lt;/span&gt;&lt;span&gt; SimpleMLP&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;nn&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;span&gt;Module&lt;/span&gt;&lt;span&gt;):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    def&lt;/span&gt;&lt;span&gt; __init__&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;self&lt;/span&gt;&lt;span&gt;):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        super&lt;/span&gt;&lt;span&gt;(SimpleMLP, &lt;/span&gt;&lt;span&gt;self&lt;/span&gt;&lt;span&gt;).&lt;/span&gt;&lt;span&gt;__init__&lt;/span&gt;&lt;span&gt;()&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        self&lt;/span&gt;&lt;span&gt;.fc1 = nn.Linear(&lt;/span&gt;&lt;span&gt;4&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;16&lt;/span&gt;&lt;span&gt;)  &lt;/span&gt;&lt;span&gt;# Input to hidden layer&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        self&lt;/span&gt;&lt;span&gt;.fc2 = nn.Linear(&lt;/span&gt;&lt;span&gt;16&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;8&lt;/span&gt;&lt;span&gt;) &lt;/span&gt;&lt;span&gt;# Hidden to hidden layer&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        self&lt;/span&gt;&lt;span&gt;.fc3 = nn.Linear(&lt;/span&gt;&lt;span&gt;8&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;1&lt;/span&gt;&lt;span&gt;)  &lt;/span&gt;&lt;span&gt;# Hidden to output layer&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    def&lt;/span&gt;&lt;span&gt; forward&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;self&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;x&lt;/span&gt;&lt;span&gt;):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        x = torch.relu(&lt;/span&gt;&lt;span&gt;self&lt;/span&gt;&lt;span&gt;.fc1(x))&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        x = torch.relu(&lt;/span&gt;&lt;span&gt;self&lt;/span&gt;&lt;span&gt;.fc2(x))&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        x = torch.sigmoid(&lt;/span&gt;&lt;span&gt;self&lt;/span&gt;&lt;span&gt;.fc3(x))&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        return&lt;/span&gt;&lt;span&gt; x&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Instantiate the model, loss function, and optimizer&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;model = SimpleMLP()&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;criterion = nn.BCELoss()  &lt;/span&gt;&lt;span&gt;# Binary Cross Entropy Loss&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;optimizer = optim.Adam(model.parameters(), &lt;/span&gt;&lt;span&gt;lr&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;0.01&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Dummy data for training&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;inputs = torch.randn(&lt;/span&gt;&lt;span&gt;10&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;4&lt;/span&gt;&lt;span&gt;)  &lt;/span&gt;&lt;span&gt;# Batch of 10 samples, 4 features each&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;targets = torch.randint(&lt;/span&gt;&lt;span&gt;0&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;2&lt;/span&gt;&lt;span&gt;, (&lt;/span&gt;&lt;span&gt;10&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;1&lt;/span&gt;&lt;span&gt;)).float()  &lt;/span&gt;&lt;span&gt;# Binary targets&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Training loop&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;for&lt;/span&gt;&lt;span&gt; epoch &lt;/span&gt;&lt;span&gt;in&lt;/span&gt;&lt;span&gt; range&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;10&lt;/span&gt;&lt;span&gt;):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    # Forward pass&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    outputs = model(inputs)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    loss = criterion(outputs, targets)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    # Backward pass&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    optimizer.zero_grad()&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    loss.backward()&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    optimizer.step()&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    if&lt;/span&gt;&lt;span&gt; (epoch + &lt;/span&gt;&lt;span&gt;1&lt;/span&gt;&lt;span&gt;) % &lt;/span&gt;&lt;span&gt;10&lt;/span&gt;&lt;span&gt; == &lt;/span&gt;&lt;span&gt;0&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        print&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;f&lt;/span&gt;&lt;span&gt;&quot;Epoch [&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;epoch+&lt;/span&gt;&lt;span&gt;1&lt;/span&gt;&lt;span&gt;}&lt;/span&gt;&lt;span&gt;/10], Loss: &lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;loss.item()&lt;/span&gt;&lt;span&gt;:.4f}&lt;/span&gt;&lt;span&gt;&quot;&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;[!IMPORTANT]
By iteratively performing forward and backward passes over multiple epochs, the network learns the optimal parameters
to minimize the loss and generalize to unseen data.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Importance of MLP&lt;/h3&gt;
&lt;p&gt;By combining these techniques, MLPs become powerful tools for modeling both linear and non-linear patterns in data. They
form the foundation of many advanced deep learning architectures, such as &lt;strong&gt;Convolutional Neural Networks (CNNs)&lt;/strong&gt; and
&lt;strong&gt;Recurrent Neural Networks (RNNs)&lt;/strong&gt;.&lt;/p&gt;
</content:encoded><category>blog</category><category>deep-learning</category><author>Anshul Raj Verma</author></item><item><title>June Journal</title><link>https://arv-anshul.github.io/journal/2024/06</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/06</guid><description>Weekly Journal by ARV of June 2024</description><pubDate>Sat, 01 Jun 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 23 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;:partying_face: Found the solution of last point in &lt;a href=&quot;05.md#week-22-journal&quot;&gt;Week 22&lt;/a&gt; which occurs with global Taskfile.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Just use &lt;strong&gt;&lt;code&gt;USER_WORKING_DIR&lt;/code&gt;&lt;/strong&gt; special variable of Taskfiles.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;pc-all&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  desc&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;Run pre-commit on all files&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  dir&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;{{.USER_WORKING_DIR}}&quot;&lt;/span&gt;&lt;span&gt; # Refer to the absolute path of the directory `task` was called from.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  cmd&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;pre-commit run --all-files&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Related Docs:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://taskfile.dev/usage/#running-a-taskfile-from-a-subdirectory&quot;&gt;Running A Taskfile From A Subdirectory&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://taskfile.dev/usage/#running-a-global-taskfile&quot;&gt;Running A Global Taskfile&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://taskfile.dev/api/#special-variables&quot;&gt;Special Variables&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Created &lt;a href=&quot;https://hf.co/arv-anshul&quot;&gt;HuggingFace&lt;/a&gt; account because now I want to dive into LLMs and want to create some basic application using
them and in the flow of creating something I can learn DL and LLM concpets too.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;:ballot_box: Created &lt;a href=&quot;https://github.com/arv-anshul/notebooks/tree/main/election-2024&quot;&gt;India Election 2024&lt;/a&gt; dashboard using Streamlit. Used &lt;code&gt;httpx.AyncClient&lt;/code&gt;, &lt;code&gt;polars.LazyFrame&lt;/code&gt; and
only &lt;code&gt;async&lt;/code&gt; functions.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Created the dashboard same day and posted on LinkedIn about it :star_struck:.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Add a reference link in sidebar to &lt;a href=&quot;https://github.com/arv-anshul/notebooks&quot;&gt;@arv-anshul/notebooks&lt;/a&gt; and &lt;a href=&quot;https://github.com/arv-anshul/dotfiles&quot;&gt;@arv-anshul/dotfiles&lt;/a&gt; repo in &lt;code&gt;/project&lt;/code&gt; page.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://github.com/squidfunk/mkdocs-material/discussions/6974&quot;&gt;mkdocs-material/discussions&lt;/a&gt;, I want a feature through which I can replace the bullets of lists to a SVG icon.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;A guy suggested a way to achieve that but that is &lt;em&gt;complicated and not much flexible&lt;/em&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history-v2&quot;&gt;@arv-anshul/yt-watch-history-v2&lt;/a&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;:sparkles: Add &lt;strong&gt;Channel Recommender System&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;:recycle: Refactor the &lt;strong&gt;CTT ML Model&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;A nice discussion with &lt;a href=&quot;https://www.linkedin.com/in/mayank-vanik-0002111b0&quot;&gt;@MayankVanik&lt;/a&gt; around Gen AI, LLMs, AI Agents, LangChain, LangGraph and HuggingFace.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Just realize the best coding font for me which is &lt;a href=&quot;https://recursive.design&quot;&gt;Recursive Font&lt;/a&gt;. BTW, I&apos;ve used it earlier but rejected but now
when I realize the casual nature of it, I fell for it. Now, I am using its &lt;code&gt;Rec Mono Casual&lt;/code&gt; (for markdowns &amp;amp; docs)
and &lt;code&gt;Rec Mono Dutone&lt;/code&gt; (for coding) font variants.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 24 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;I saw a guy in &quot;We write code&quot; Server by Hitesh Chaudhary who has amazing portfolio and he had done amazing work
around Full Stack Development and he also contributed in multiple Open Source repos (big repos) :AMAZING:. He made a
full-pledged WORKING clown of PW website and also made a desktop app of PW using Tauri (Rust). He has amazing
portfolio website. There is so much things I can learn form him. &lt;strong&gt;&lt;a href=&quot;https://github.com/arnvgh&quot;&gt;@arnvgh&lt;/a&gt;&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;Completed the refactoring of CTT Model in &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history-v2&quot;&gt;@arv-anshul/yt-watch-history-v2&lt;/a&gt; project. See release &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history-v2/releases/v0.3.0&quot;&gt;v0.3.0&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;&lt;s&gt;Created a community server on Discord and added many interactive features which helps others to connect and learn
together as community.&lt;/s&gt;
&lt;ul&gt;
&lt;li&gt;After creating the discord server, I&apos;ve deleted it because I don&apos;t think that this is for me.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Wrote a clear project explanation paragraph of &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history-v2&quot;&gt;@arv-anshul/yt-watch-history-v2&lt;/a&gt; project. See on
&lt;a href=&quot;https://arv-anshul.github.io/project/yt-watch-history&quot;&gt;website&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;A employee from &lt;a href=&quot;http://aabee.co.in&quot;&gt;AABEE&lt;/a&gt; (a real state startup) reached me through &lt;strong&gt;reached me through my OG
&lt;a href=&quot;https://github.com/arv-anshul/99acres-scrape&quot;&gt;99acres-scrape&lt;/a&gt; project&lt;/strong&gt;. He conducted a meeting on G-Meet and given a task to scrape the older prices of
properties to tackle the property&apos;s price trend but the data is not there on the website. That&apos;s why he said &quot;we&apos;ll
reach you later for any other work&quot; :disappointed:.&lt;/li&gt;
&lt;li&gt;The 3 co-founders of &lt;a href=&quot;https://leapx.ai&quot;&gt;LeapX.ai&lt;/a&gt; startup &lt;strong&gt;reached me through my OG &lt;a href=&quot;https://github.com/arv-anshul/99acres-scrape&quot;&gt;99acres-scrape&lt;/a&gt; project&lt;/strong&gt;. They conducted a
meeting on MS Teams and the &lt;strong&gt;meeting goes for 48 Minutes&lt;/strong&gt; while meeting they ask for my education, data science
knowledge. In the end, they asked me a problem to explain (not solve; just explain) on the basis of explain they
offer me a internship :star_struck:.
&lt;ul&gt;
&lt;li&gt;I first interacted with Aditya, when he cam to know that I am in class 12th then started asking me about my Father
and his profession and my place, how I study there, which school.&lt;/li&gt;
&lt;li&gt;One of them is from &lt;strong&gt;Makhdumpur&lt;/strong&gt; :star_struck:.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;In &lt;a href=&quot;https://leapx.ai&quot;&gt;LeapX.ai&lt;/a&gt; interview I was explaining my &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history-v2&quot;&gt;@arv-anshul/yt-watch-history-v2&lt;/a&gt; project and while explaining I
mentioned the User Sentiment Analysis model which is able to predict the user&apos;s sentiment for programming, politics,
entertainment, movie genre, etc. But the problem is that I haven&apos;t implemented it (in short I don&apos;t even checked it
in &lt;code&gt;ipynb&lt;/code&gt;). So, I decided to create a notebook around it and try to explain how to do it.
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;:HARD:&lt;/strong&gt; A ML Model which predict the user&apos;s sentiment around programming, politics, entertainment.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;:EASY:&lt;/strong&gt; &lt;s&gt;A Clustering Model which cluster similar videos&lt;/s&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;:EASY:&lt;/strong&gt; A wordcloud which shows most common words around programming, politics, entertainment from user&apos;s watch
history and by analysing that wordcloud anyone is able to determine their sentiment/habit.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 25 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Project &lt;a href=&quot;https://github.com/arv-anshul/og-py&quot;&gt;og-py&lt;/a&gt; to create custom GitHub repo social preview image using &lt;code&gt;https://og-playground.vercel.app/&lt;/code&gt;
playground.&lt;/li&gt;
&lt;li&gt;:star: Working at LeapX.ai as Intern.&lt;/li&gt;
&lt;li&gt;:llama: Try using &lt;code&gt;ollama&lt;/code&gt; in Zed editor. It is great but the response time very bad but I&apos;ll use it.&lt;/li&gt;
&lt;li&gt;Read/Watch something about Playwright (better alternative of Selenium).&lt;/li&gt;
&lt;li&gt;:handshake: Connected with &lt;a href=&quot;https://github.com/ujjwal-basnet&quot;&gt;@ujjwal-basnet&lt;/a&gt; and &lt;a href=&quot;https://github.com/iamrajharshit&quot;&gt;@iamrajharshit&lt;/a&gt; from Discord.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Internship at &lt;strong&gt;LeapX.ai&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;2024-06-19&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;After a one day off, We (Me and Aditya) connect on and discuss the affluent properties clustering problem. I have
created some dashboard around it but after the meeting the conclusion is that data is not good because many properties
were removed from 99acres&apos;s website. So we decided to scrape new data from the website. So I have to write code for
that.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;2024-06-20&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;While scraping data from 99acres with selenium I got many errors then I decided to scrape data from other website like
Housing.com or MagicBricks.com.&lt;/p&gt;
&lt;p&gt;I am planning to use &lt;a href=&quot;https://pypi.org/p/selenium-wire&quot;&gt;&lt;code&gt;selenium-wire&lt;/code&gt;&lt;/a&gt;. And, want to scrape more than one website and
create a pipeline through which different websites&apos; data combines together and forms a wholesome dataset to work on.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;2024-06-21&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Getting errors while using &lt;code&gt;selenium-wire&lt;/code&gt; package, so I try to learn and use &lt;code&gt;playwright&lt;/code&gt;. Again try to scrape using
&lt;code&gt;httpx&lt;/code&gt; with headers and cookies and I got success so I scrape almost 3K data using this. For now I&apos;m sticking with this
method.&lt;/p&gt;
&lt;h2&gt;Week 26 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Thinking to create a GitHub Repo where all the scraping code for different websites are present. Also, repo maintains
a &lt;code&gt;README.md&lt;/code&gt; file for different scraping project, tools and resources.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Used &lt;code&gt;st.Page&lt;/code&gt; (new multipage UI update from Streamlit) while building dashboards for LeapX.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;:star: Got &lt;strong&gt;Offer from LeapX.ai&lt;/strong&gt; for 3 month intership.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;I had been writing many scraping scraping for many websites like Housing.com, MagicBricks.com, Naukri.com, etc.
That&apos;s why thinking to publish them as blogs because they are not a full-pledged project instead they are just python
using which we can scrape websites and &lt;em&gt;there is no guarantee that script forever&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;:scroll: I&apos;ll just explain the script and paste it there in the blog.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Added LeapX.ai Internship on LinkedIn.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Stared learning LangChain from YouTube after Aditya told me to-do so.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;🇮🇳 WON T20I&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Internship at &lt;strong&gt;LeapX.ai&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;2024-06-25&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Meeting started after :clock8: &lt;strong&gt;20:00&lt;/strong&gt; and end at :clock1030: &lt;strong&gt;22:30&lt;/strong&gt;. We worked on dataset scraped from Housing.com
contains ~12K rows.&lt;/p&gt;
&lt;p&gt;We took a different approach to cluster properties, used &lt;a href=&quot;https://docs.pola.rs/api/python/stable/reference/expressions/api/polars.Expr.qcut.html&quot;&gt;polars.Expr.qcut&lt;/a&gt; function to categories properties on the
basis of &lt;code&gt;&quot;PRICE_PER_UNIT_AREA&quot;&lt;/code&gt;. After this created a dashboard around this (with Streamlit).&lt;/p&gt;
&lt;p&gt;Now the main problem is to find a dense region and create a circle around it to mark that region with a label &lt;em&gt;eg.
Luxury, Value, Affordable, etc.&lt;/em&gt; And for this I have to write a function which do these findings and creating regions.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;2024-06-26&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;No meeting conducted.&lt;/p&gt;
&lt;p&gt;Using httpx library to scrape all 21K properties from Housing.com website of Gurgaon, faced many website downtime but
eventually got things work.&lt;/p&gt;
&lt;p&gt;Received offer leeter from LeapX.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;2024-06-29&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Completed the two page streamlit dashboard.&lt;/p&gt;
&lt;p&gt;Told me to learn about AI stuffs like Langchain and Llama Index. Already found an awesome video on it.&lt;/p&gt;
</content:encoded><category>journal</category><category>journal</category><category>june</category><author>Anshul Raj Verma</author></item><item><title>Architecture for V2</title><link>https://arv-anshul.github.io/projects/yt-watch-history/v2-architecture</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/yt-watch-history/v2-architecture</guid><description>Defining design architecture for YouTube Watch History V2 project.</description><pubDate>Sun, 19 May 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Application Interaction&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Architecture of &lt;code&gt;backend&lt;/code&gt;, &lt;code&gt;ml&lt;/code&gt; and &lt;code&gt;frontend&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;How do &lt;code&gt;backend&lt;/code&gt;, &lt;code&gt;ml&lt;/code&gt; and &lt;code&gt;frontend&lt;/code&gt; interacts?&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&amp;lt;details&amp;gt;
&amp;lt;summary&amp;gt;Code for Diagram&amp;lt;/summary&amp;gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;styleMode plain&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Container 1 [icon: docker, color: blue] {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ML Models [icon: machine-learning] {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Conetnt Type Predictor [icon: machine-learning]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Channel Recommender System [icon: machine-learning]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ML Models API [icon: fastapi, color: green]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;YouTube Data v3 API [icon: youtube, color: red]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Container 2 [icon: docker, color: blue] {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;MongoDB [icon: mongodb, color: green] {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Video Details [icon: database]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Channel Details [icon: database]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Backend API [icon: fastapi, color: green]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Container 3 [icon: docker, color: blue] {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Frontend [icon: streamlit, color: red]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;User [icon: user]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;User &amp;gt; Container 3&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Container 3 &amp;gt; Backend API, ML Models API&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Backend API &amp;gt; MongoDB&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Backend API &amp;gt; YouTube Data v3 API&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ML Models API &amp;gt; ML Models&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;/details&amp;gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/yt-watch-history-v2/raw/main/assets/img/diagram-for-v2.png&quot; alt=&quot;diagram-for-v2.png&quot; /&gt;&lt;/p&gt;
&lt;h2&gt;Frontend and Backend API Interaction&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;What happens when user upload their &lt;code&gt;watch-history.json&lt;/code&gt; data to see analysis?&lt;/li&gt;
&lt;li&gt;More and better data retrieval for analysis.&lt;/li&gt;
&lt;li&gt;Use of &lt;strong&gt;YouTube Data v3 API&lt;/strong&gt; to fetch more details of watched videos.&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;sequenceDiagram&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    participant Frontend as Frontend&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    participant API as API&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    participant ChannelDetails as ChannelDetails&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    participant VideoDetails as VideoDetails&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Frontend -&amp;gt;&amp;gt; API: Request all IDs from User&apos;s watch history&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Note over Frontend, API: User&apos;s watch history IDs&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    activate Frontend&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        API -&amp;gt;&amp;gt; ChannelDetails: Exclude IDs already available in DB&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        ChannelDetails --&amp;gt;&amp;gt; API: IDs not in Database&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        API --&amp;gt;&amp;gt; Frontend: Filtered IDs&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    deactivate Frontend&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Note over Frontend, API: Filtered IDs&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Frontend -&amp;gt;&amp;gt; API: Fetch video details of filtered IDs&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Note over Frontend, API: Video details request&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    activate API&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        API -&amp;gt;&amp;gt; VideoDetails: Store fetched details&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        VideoDetails --&amp;gt;&amp;gt; API: Stored!&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        API -&amp;gt;&amp;gt; ChannelDetails: Store channel&apos;s videos ID from fetched data&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        ChannelDetails --&amp;gt;&amp;gt; API: Stored!&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        API --&amp;gt;&amp;gt; Frontend: Video Details&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    deactivate API&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Note over Frontend: Show graphs using fetched data&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;details&amp;gt;
&amp;lt;summary&amp;gt;Code for Diagram&amp;lt;/summary&amp;gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;styleMode plain&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Frontend [icon: streamlit, color: red]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;API [icon: fastapi, color: green]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ChannelDetails [icon: mongodb, color: purple, label: Channel Videos ID DB]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;VideoDeatils [icon: mongodb, color: orange, label: Video Details DB]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Frontend &amp;gt; API: All IDs from User&apos;s watch history&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;activate Frontend&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;API &amp;gt; ChannelDetails: Exclude IDs already available in DB&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ChannelDetails &amp;gt; API: IDs not in Database&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;API &amp;gt; Frontend: Filtered IDs&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;deactivate Frontend&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Frontend &amp;gt; API: Fetch video details of filtered IDs&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;activate API&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;API &amp;gt; VideoDeatils: Store fetched details&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;VideoDeatils &amp;gt; API : Stored!&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;API &amp;gt; ChannelDetails: Store channel&apos;s videos ID from fetched data&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ChannelDetails &amp;gt; API : Stored!&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;API &amp;gt; Frontend: Video Details&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;deactivate API&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;/details&amp;gt;&lt;/p&gt;
&lt;h2&gt;ML Model Working&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;How does ML Model inference through API?&lt;/li&gt;
&lt;li&gt;&lt;s&gt;How to train ML Model on my custom data?&lt;/s&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/yt-watch-history-v2/raw/main/assets/img/ml-model-working.png&quot; alt=&quot;ml-model-working.png&quot; /&gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;details&amp;gt;
&amp;lt;summary&amp;gt;Code for Diagram&amp;lt;/summary&amp;gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;direction right&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;styleMode plain&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;user [icon: user, shape: diamond, label: User]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;inputData [icon: data, shape: cylinder, label: Input Data]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;model [icon: machine-learning, shape: document, label: ML Model]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;mlApi [icon: fastapi, label: ML API]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;modelOnWeb [icon: globe, shape: oval, label: Model On Web]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;prediction [icon: graph, label: Model Prediction]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;user &amp;gt; inputData&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;inputData &amp;gt; mlApi&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;mlApi &amp;gt; model: Exists&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;mlApi &amp;gt; modelOnWeb: Not Exists&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;modelOnWeb &amp;gt; model: Download and Store&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;model &amp;gt; prediction&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;prediction &amp;gt; user&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;/details&amp;gt;&lt;/p&gt;
&lt;h2&gt;User Data Flow&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Data manipulation after user uploads their data on application.&lt;/li&gt;
&lt;li&gt;Use of &lt;strong&gt;YouTube Data v3 API&lt;/strong&gt; to fetch more details about watched videos.&lt;/li&gt;
&lt;li&gt;Leveraging the power of Python libraries like &lt;a href=&quot;https://pola.rs&quot;&gt;Polars&lt;/a&gt; for data manipulation. &lt;em&gt;We can use &lt;a href=&quot;https://github.com/pandas-dev/pandas&quot;&gt;Pandas&lt;/a&gt; also.&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/yt-watch-history-v2/raw/main/assets/img/user-data-flow.png&quot; alt=&quot;user-data-flow.png&quot; /&gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;details&amp;gt;
&amp;lt;summary&amp;gt;Code for Diagram&amp;lt;/summary&amp;gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;styleMode plain&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;watchHistory [icon: user, color: blue] {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    title_ string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    titleUrl string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    time datetime&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    subtitle dict&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;preprocessedWatchHistory [icon: pandas, color: blue] {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    videoId string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    title_ string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    channelId string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    channelTitle string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;watchHistory.title_ - preprocessedWatchHistory.title_&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;watchHistory.titleUrl - preprocessedWatchHistory.videoId&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;watchHistory.subtitle - preprocessedWatchHistory.channelTitle&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;watchHistory.subtitle - preprocessedWatchHistory.channelId&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;videoDetails [icon: youtube, color: red] {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    id string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    title_ string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    channelId string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    description string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    tags list[string]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    publishedAt datetime&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;mergedData [icon: table, color: yellow] {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    videoId string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    title_ string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    channelId string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    channelTitle string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    description string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    tags string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    publishedAt datetime&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;preprocessedWatchHistory.videoId - mergedData.videoId&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;preprocessedWatchHistory.title_ - mergedData.title_&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;preprocessedWatchHistory.channelId - mergedData.channelId&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;preprocessedWatchHistory.channelTitle - mergedData.channelTitle&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;videoDetails.tags - mergedData.tags&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;videoDetails.description - mergedData.description&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;videoDetails.publishedAt - mergedData.publishedAt&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;/details&amp;gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;details&amp;gt;
&amp;lt;summary&amp;gt;Diagram with Mermaid&amp;lt;/summary&amp;gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;erDiagram&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    WATCH_HISTORY {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        title_ string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        titleUrl string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        time datetime&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        subtitle dict&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    }&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    PREPROCESSED_WATCH_HISTORY {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        videoId string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        title_ string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        channelId string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        channelTitle string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    }&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    VIDEO_DETAILS {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        id string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        title_ string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        channelId string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        description string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        tags list&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        publishedAt datetime&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    }&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    MERGED_DATA {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        videoId string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        title_ string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        channelId string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        channelTitle string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        description string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        tags string&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        publishedAt datetime&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    }&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    WATCH_HISTORY ||--|| PREPROCESSED_WATCH_HISTORY: title_&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    WATCH_HISTORY ||--|| PREPROCESSED_WATCH_HISTORY: titleUrl&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    WATCH_HISTORY ||--|| PREPROCESSED_WATCH_HISTORY: subtitle&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    WATCH_HISTORY ||--|| PREPROCESSED_WATCH_HISTORY: subtitle&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    PREPROCESSED_WATCH_HISTORY ||--|| MERGED_DATA: videoId&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    PREPROCESSED_WATCH_HISTORY ||--|| MERGED_DATA: title_&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    PREPROCESSED_WATCH_HISTORY ||--|| MERGED_DATA: channelId&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    PREPROCESSED_WATCH_HISTORY ||--|| MERGED_DATA: channelTitle&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    VIDEO_DETAILS ||--|| MERGED_DATA: tags&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    VIDEO_DETAILS ||--|| MERGED_DATA: description&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    VIDEO_DETAILS ||--|| MERGED_DATA: publishedAt&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;/details&amp;gt;&lt;/p&gt;
</content:encoded><category>project</category><category>project</category><category>architecture</category><category>ml</category><author>Anshul Raj Verma</author></item><item><title>Resume Tips</title><link>https://arv-anshul.github.io/blog/2024/resume-tips</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/resume-tips</guid><description>Some tips to follow while creating your resume.</description><pubDate>Thu, 09 May 2024 00:00:00 GMT</pubDate><content:encoded>&lt;blockquote&gt;
&lt;p&gt;By Rohan Azad Sir&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;By implementing these strategies, you can elevate your Resume/CV to effectively communicate your qualifications and
stand out among the competition in today&apos;s job market.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;NOTE:&lt;/strong&gt; I am writing this article from the POV of Data Scientists.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;:memo: Important Points To Follow&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Keep It Concise&lt;/strong&gt;: Limit your CV to a single page to maintain reader interest and showcase your most relevant
experiences succinctly.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Optimize Layout&lt;/strong&gt;: Minimize white spaces and prioritize content placement for a visually appealing and easy-to-read
document.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Highlight Relevant Projects&lt;/strong&gt;: Tailor your CV to the job role by including specific projects that demonstrate your
skills and expertise in alignment with the position.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Include Important Links&lt;/strong&gt;: Provide links to your LinkedIn, GitHub, and Kaggle profiles to offer recruiters a deeper
insight into your professional background and achievements.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Showcase Certifications&lt;/strong&gt;: Feature 2 to 4 certifications that highlight your commitment to continuous learning and
validate your proficiency in relevant areas.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Emphasize Technical Skills&lt;/strong&gt;: Dedicate a section to showcasing your technical prowess, listing skills such as
Statistics, GenAI, Power BI, and other job-specific technologies to demonstrate your capability to excel in the role.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Tweak CV For Job Role&lt;/strong&gt;: Tweak your CV before submitting for job role, company&apos;s requirements; don&apos;t add unnecessary
projects or tech skills other than required one.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;:bookmark: How to list projects?&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Project starts with Project Title.&lt;/li&gt;
&lt;li&gt;Define project assessment in bullet points.&lt;/li&gt;
&lt;li&gt;Must write the results (like RMSE, MAE of model). TLDR; Result has to be a number afterall.&lt;/li&gt;
&lt;li&gt;Dedicate one or two points to define how you solve the problem using this project.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;:art: Formatting&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Result numbers must be in bold.&lt;/li&gt;
&lt;li&gt;Use &lt;strong&gt;&lt;a href=&quot;https://en.wikipedia.org/wiki/Sans-serif&quot;&gt;Sans Serif&lt;/a&gt;&lt;/strong&gt; fonts like &lt;a href=&quot;https://www.freefonts.io/calibri-font/&quot;&gt;Calibri&lt;/a&gt; or &lt;a href=&quot;https://fonts.google.com/specimen/Poppins&quot;&gt;Poppins&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Use font size between 10 to 12.&lt;/li&gt;
&lt;li&gt;Too many formatting style must be restricted.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;:pen: Writing&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Check Grammatical errors. &lt;em&gt;Use ChatBots to tackle this.&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Use &lt;strong&gt;Action Verbs&lt;/strong&gt; in your Resume. &lt;em&gt;Checkout some well-known words below&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;🙅 Don&apos;t add summary which shows you that &lt;em&gt;you wants to grow or you&apos;ll help the company to grow and something like
this&lt;/em&gt;.&lt;/li&gt;
&lt;li&gt;You can skip your Profile Summary or About Me section; if your CV got bigger. &lt;em&gt;But try to keep it short and crisp.&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&amp;lt;details&amp;gt;
&amp;lt;summary&amp;gt;List of Action Verbs&amp;lt;/summary&amp;gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;https://i.pinimg.com/originals/5d/dc/93/5ddc93adb20d5cdf47eac7312a3b1f7e.jpg&quot; alt=&quot;Action Verbs- Image&quot; /&gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;/details&amp;gt;&lt;/p&gt;
&lt;hr /&gt;
&lt;p&gt;&lt;a href=&quot;https://arv-anshul.github.io/resume&quot;&gt;Download My Resume&lt;/a&gt;&lt;/p&gt;
</content:encoded><category>blog</category><category>others</category><author>Anshul Raj Verma</author></item><item><title>May Journal</title><link>https://arv-anshul.github.io/journal/2024/05</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/05</guid><description>Weekly Journal by ARV of May 2024</description><pubDate>Wed, 01 May 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 18 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Continue working on &lt;a href=&quot;https://github.com/arv-anshul/notebooks/tree/main/credit-modeling&quot;&gt;credit-modeling&lt;/a&gt; project with Sambhav.
&lt;ul&gt;
&lt;li&gt;Sambhav wrote &lt;a href=&quot;https://arv-anshul.github.io/project/credit-modeling&quot;&gt;documentation&lt;/a&gt; of this project.&lt;/li&gt;
&lt;li&gt;Added the project documentation in repo too. The documentation PDF is saved after it converted into my website&apos;s
page.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Start working on &lt;a href=&quot;https://github.com/arv-anshul/freeapi-py&quot;&gt;freeapi-py&lt;/a&gt; project. Also shared the project on &lt;strong&gt;Hitesh Chaudhary&apos;s Discord Server&lt;/strong&gt;.
&lt;ul&gt;
&lt;li&gt;Added &lt;code&gt;/todo&lt;/code&gt;, &lt;code&gt;/quote&lt;/code&gt;, &lt;code&gt;/gh&lt;/code&gt; routes.&lt;/li&gt;
&lt;li&gt;Posted &lt;a href=&quot;https://github.com/arv-anshul/freeapi-py&quot;&gt;freeapi-py&lt;/a&gt; project on
&lt;a href=&quot;https://www.linkedin.com/feed/update/urn:li:activity:7192135714594000896/&quot;&gt;LinkedIn&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Rahul recommended an amazing YouTube channel &lt;a href=&quot;https://www.youtube.com/@probabl_ai&quot;&gt;&lt;strong&gt;@probabl_ai&lt;/strong&gt;&lt;/a&gt; which goes deep
inside the libraries (&lt;code&gt;scikit-learn&lt;/code&gt;, &lt;code&gt;pandas&lt;/code&gt;, &lt;code&gt;polars&lt;/code&gt;, &lt;code&gt;duckdb&lt;/code&gt;) code.&lt;/li&gt;
&lt;li&gt;After attending the DSMP 2.0 session on &lt;strong&gt;&quot;Project Based Interview Session&quot;&lt;/strong&gt; &lt;em&gt;(by Rohan Azad)&lt;/em&gt;, I knew many
important rules and conventions regarging Interviews.
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Know yourself&lt;/strong&gt; so that you can introduce yourself very well without jargons for approx. 1.5 minutes to 2
minutes.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Know your projects&lt;/strong&gt; because you have to explain it very well any process/concept of your project can be asked by
interviewers. You&apos;ve to explain your project for 30 to 40 minutes.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Know the basics&lt;/strong&gt; interviewers will try to trick you with them.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;I woke up at 4 AM and immediately called my friends, Priyanshu, Suraj, Binam, and Pushpam. After a quick chat, we
left home at 4:30 AM to play cricket on the PP School ground.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 19 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Re-think &lt;a href=&quot;https://gist.github.com/arv-anshul/f4ccfd9258f24ffa9769dfca9b9e091b&quot;&gt;md_badges.py&lt;/a&gt; CLI tool. Now it works very well.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;curl -sSL url_to_file.py | python - arg1 arg2 arg3&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;LinkedIn post on &lt;a href=&quot;https://www.linkedin.com/posts/arv-anshul_arc-thebrowsercompany-browser-activity-7193516240840093697-aDPI?utm_source=share&amp;amp;utm_medium=member_desktop&quot;&gt;ARC Browser&lt;/a&gt; also requested to download it with my referral link.&lt;/li&gt;
&lt;li&gt;Opened a new discussion &lt;a href=&quot;https://github.com/arv-anshul/arv-anshul.github.io/discussions/2&quot;&gt;#2&lt;/a&gt; in &lt;a href=&quot;https://github.com/arv-anshul/arv-anshul.github.io&quot;&gt;arv-anshul.github.io&lt;/a&gt; github repository.&lt;/li&gt;
&lt;li&gt;Wrote a new article &lt;a href=&quot;https://arv-anshul.github.io/ref/resume-tips&quot;&gt;/ref/resume-tips&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 20 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Restart the &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history&quot;&gt;yt-watch-history&lt;/a&gt; project as &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history-v2&quot;&gt;yt-watch-history-v2&lt;/a&gt;.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Thinking the whole process from scratch, draw some digrams on &lt;strong&gt;app.eraser.io&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Copied the code of &lt;code&gt;api/&lt;/code&gt; and &lt;code&gt;ml/&lt;/code&gt; but writing the code for &lt;strong&gt;frontend&lt;/strong&gt; from scratch.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Creating a website for &lt;a href=&quot;https://github.com/rahulkr30&quot;&gt;Rahul&lt;/a&gt; using &lt;a href=&quot;https://github.com/squidfunk/mkdocs-material&quot;&gt;mkdocs-material&lt;/a&gt;. &lt;a href=&quot;https://rahulkr30.github.io&quot;&gt;Check it out here&lt;/a&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;:sparkles: Added recommendation pages for &lt;strong&gt;Music, Movies, Shows and Anime&lt;/strong&gt; on the website.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;First, I&apos;ve decided to maintain them here in diary but I got a solution which hide those page from website and at
the same they are explicitly accessible from URL.&lt;/p&gt;
&lt;p&gt;&amp;lt;figure markdown&amp;gt;&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Page&lt;/th&gt;
&lt;th&gt;URL&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Music&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;a href=&quot;https://arv-anshul.github.io/music&quot;&gt;&lt;code&gt;/music&lt;/code&gt;&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Movies &amp;amp; Shows&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;a href=&quot;https://arv-anshul.github.io/movies-and-shows&quot;&gt;&lt;code&gt;/movies-and-shows&lt;/code&gt;&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Anime&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;a href=&quot;https://arv-anshul.github.io/anime&quot;&gt;&lt;code&gt;/anime&lt;/code&gt;&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&amp;lt;/figure&amp;gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Disable, Dependendant Bot :robot: analysis on &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history&quot;&gt;yt-watch-history&lt;/a&gt; repository.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Assign keyboard shortcut to raycast&apos;s emoji extension. Now pasting is very awesome :partying_face:.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Found the way to import my CSS and JavaScript files to add them in &lt;code&gt;mkdocs.yaml&lt;/code&gt;.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;It helps to sync all the extra and custom CSS/JS files from main website where I maintin them.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Changed battries of Mouse and Keyboard on &lt;strong&gt;18 May, 2024&lt;/strong&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;mouse&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  old&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    name&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;Eveready&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    price&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;₹30&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    installed_on&lt;/span&gt;&lt;span&gt;: 2023-12-02&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  new&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    name&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;Nippo&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    price&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;₹10&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    installed_on&lt;/span&gt;&lt;span&gt;: 2024-05-18&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;keyboard&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  old&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    name&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;Duracell&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    price&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;included in box&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    installed_on&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;on purchase date&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  new&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    name&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;Nippo&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    price&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;₹10&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    installed_on&lt;/span&gt;&lt;span&gt;: 2024-05-18&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 21 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Updated the GitHub Profile
&lt;a href=&quot;https://github.com/arv-anshul/arv-anshul/blob/877a8c5813dda66b2bf8cbb667ff9527ed3d22dd/README.md?plain=1#L3-L5&quot;&gt;README&lt;/a&gt;.
&lt;ul&gt;
&lt;li&gt;Shorten the About Me section.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history-v2&quot;&gt;yt-watch-history-v2&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;Created more diagrams.&lt;/li&gt;
&lt;li&gt;Now, download ML Model from URL &lt;em&gt;(if not exists)&lt;/em&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Custom Stylus Themes&lt;/strong&gt;: I customize website&apos;s UI using &lt;a href=&quot;https://chrome.google.com/webstore/detail/clngdbkpkpeebahjckkjfobafhncgmne&quot;&gt;stylus extension&lt;/a&gt; and for that I&apos;ve to write CSS. So I&apos;m
going upload all those &lt;code&gt;.user.css&lt;/code&gt; custom CSS in GitHub repo.
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Customized&lt;/strong&gt;: youtube.com, gemini.google.com, chatgpt.com, open.spotify.com, linkedin.com and more.&lt;/li&gt;
&lt;li&gt;BTW, I also use &lt;a href=&quot;https://arc.net/boosts&quot;&gt;ARC Boost&lt;/a&gt; for quick customization but I it doesn&apos;t give me ability to export the customization in
CSS format.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;This week update:
&lt;ul&gt;
&lt;li&gt;Painting in my room took 2 Days.&lt;/li&gt;
&lt;li&gt;Installing Gypsum False Celling in my room disturb the daytime.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Get the current week number with this python command.&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;# using bash&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;echo&lt;/span&gt;&lt;span&gt; &quot;Current week number is $(&lt;/span&gt;&lt;span&gt;date&lt;/span&gt;&lt;span&gt; +%V).&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# using python&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;python&lt;/span&gt;&lt;span&gt; -c&lt;/span&gt;&lt;span&gt; &quot;from datetime import date; print(f&apos;Current week number is {date.today().isocalendar()[1]}.&apos;)&quot;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;ol&gt;
&lt;li&gt;Opened issues in &lt;code&gt;zed&lt;/code&gt;, &lt;code&gt;simpleicons&lt;/code&gt;, &lt;code&gt;CampusX-Course&lt;/code&gt; repositories. Check my &lt;a href=&quot;https://github.com/arv-anshul?tab=overview&amp;amp;from=2024-05-01&amp;amp;to=2024-05-31&quot;&gt;github activity&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Used &lt;a href=&quot;https://github.com/mkdocs/mkdocs-redirects&quot;&gt;mkdocs-redirects&lt;/a&gt; plugin in website repo. I found it very helpful and easy to use 😇.&lt;/li&gt;
&lt;li&gt;A &lt;a href=&quot;https://github.com/Yash-Kavaiya/CampusX-courses&quot;&gt;github repo&lt;/a&gt; which contains materials of &lt;strong&gt;CampusX Free
Courses&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 22 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;New release for &lt;a href=&quot;https://github.com/arv-anshul/campusx&quot;&gt;campusx repo&lt;/a&gt; (previously know as &lt;code&gt;campusx-dsmp&lt;/code&gt; repo)&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;See the release note for &lt;a href=&quot;https://github.com/arv-anshul/campusx/releases/v0.11.0&quot;&gt;&lt;code&gt;v0.11.0&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Learned &lt;a href=&quot;https://taskfile.dev&quot;&gt;Taskfile&lt;/a&gt; (alternative to Makefile). Taskfile is better, easy, intuitive to use than Makefile.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Pushed global &lt;code&gt;Taskfile.yaml&lt;/code&gt; into &lt;a href=&quot;https://github.com/arv-anshul/dotfiles&quot;&gt;dotfiles&lt;/a&gt; repository.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://marimo.io&quot;&gt;Marimo&lt;/a&gt; is a alternative to Jupyter Notebooks.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;I came to about it while juggling between Zed isuess.&lt;/li&gt;
&lt;li&gt;Also, &lt;a href=&quot;https://marimo.io/blog/lessons-learned&quot;&gt;Marimo has a blog&lt;/a&gt; where they discussed that how Marimo has overhead on Jupyter Notebooks.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;After using &lt;a href=&quot;https://marimo.io&quot;&gt;Marimo&lt;/a&gt;:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;It has very functioning than Jupyter Notebooks because Marimo works on &lt;code&gt;.py&lt;/code&gt; files instead of &lt;code&gt;.ipynb&lt;/code&gt; files.&lt;/li&gt;
&lt;li&gt;It has better markdown support. You can natively pin the python vars in MDs.&lt;/li&gt;
&lt;li&gt;It has builtin support to convert a Jupyter notebook or Markdown file to a marimo script.&lt;/li&gt;
&lt;li&gt;You can use marimo but it has long learning curve.&lt;/li&gt;
&lt;li&gt;BTW, currently I uses VSCode builtin Notebooks but looking lokking forward to switch to Zed (when they supports
it).&lt;/li&gt;
&lt;li&gt;Currently, I have no plans to switch to &lt;a href=&quot;https://marimo.io&quot;&gt;Marimo&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;There is a big problem, I am facing with &lt;a href=&quot;https://taskfile.dev&quot;&gt;Taskfile&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Here, when you run Taskfile from different dir while referring to another Taskfile (present in different dir) with
&lt;code&gt;-t&lt;/code&gt; or &lt;code&gt;-d&lt;/code&gt; flag, it will not take reference of &lt;code&gt;pwd&lt;/code&gt; instead take reference of dir where the Taskfile present.&lt;/p&gt;
&lt;p&gt;This is a big negative for me because I&apos;ve defined a global Taskfile through which I ran many useful and important
commands.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; pwd&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;~/Developer/diary&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; task&lt;/span&gt;&lt;span&gt; -t&lt;/span&gt;&lt;span&gt; ~/Developer/dotfiles/Taskfile.yaml&lt;/span&gt;&lt;span&gt; pc-all&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;task:&lt;/span&gt;&lt;span&gt; [pc-all] pwd&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;~/Developer/dotfiles&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;task:&lt;/span&gt;&lt;span&gt; [pc-all] pre-commit run --all-files&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;An&lt;/span&gt;&lt;span&gt; error&lt;/span&gt;&lt;span&gt; has&lt;/span&gt;&lt;span&gt; occurred:&lt;/span&gt;&lt;span&gt; InvalidConfigError:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;=====&lt;/span&gt;&lt;span&gt;&amp;gt; &lt;/span&gt;&lt;span&gt;.pre-commit-config.yaml&lt;/span&gt;&lt;span&gt; is&lt;/span&gt;&lt;span&gt; not&lt;/span&gt;&lt;span&gt; a&lt;/span&gt;&lt;span&gt; file&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Check&lt;/span&gt;&lt;span&gt; the&lt;/span&gt;&lt;span&gt; log&lt;/span&gt;&lt;span&gt; at&lt;/span&gt;&lt;span&gt; ~/.cache/pre-commit/pre-commit.log&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;task:&lt;/span&gt;&lt;span&gt; Failed&lt;/span&gt;&lt;span&gt; to&lt;/span&gt;&lt;span&gt; run&lt;/span&gt;&lt;span&gt; task&lt;/span&gt;&lt;span&gt; &quot;pc-all&quot;:&lt;/span&gt;&lt;span&gt; exit&lt;/span&gt;&lt;span&gt; status&lt;/span&gt;&lt;span&gt; 1&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Previously, I uses &lt;strong&gt;Makefile&lt;/strong&gt; for this and there it works fine.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; pwd&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;~/Developer/diary&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; make&lt;/span&gt;&lt;span&gt; -f&lt;/span&gt;&lt;span&gt; ~/Developer/Makefile&lt;/span&gt;&lt;span&gt; pc-all&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# works fine...&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>may</category><author>Anshul Raj Verma</author></item><item><title>Credit Risk Modeling</title><link>https://arv-anshul.github.io/projects/credit-risk-modeling</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/credit-risk-modeling</guid><description>Creating a machine learning model that can precisely segregate customers into class of giving credit based on past financial data and other pertinent borrower characteristics including income, credit score, and loan details is the aim.</description><pubDate>Tue, 30 Apr 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Problem Statement&lt;/h2&gt;
&lt;p&gt;Creating a machine learning model that can precisely segregate customers into class of giving credit based on past
financial data and other pertinent borrower characteristics including income, credit score, and loan details is the aim.
The likelihood that a borrower will fail on a loan should be estimated by the model, allowing it to determine the risk
of lending to them. Such models can help financial institutions identify and measure their total risk exposure, set
appropriate risk limits, and make informed investment decisions.&lt;/p&gt;
&lt;h2&gt;Project Workflow&lt;/h2&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/credit-risk-diagram.png&quot; alt=&quot;project-workflow&quot; /&gt;&lt;/p&gt;
&lt;h2&gt;Challenges Faced&lt;/h2&gt;
&lt;p&gt;One of the biggest challenges in credit risk modeling is the limited availability of relevant and reliable data. Credit
risk models require historical data on loan performance, default rates, and economic indicators to accurately assess the
likelihood of default.&lt;/p&gt;
&lt;p&gt;Challenges include data availability, data quality, complex modeling, and regulatory compliance.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt; One common challenge faced by financial institutions is obtaining accurate and reliable data for credit
risk modeling purposes.&lt;/p&gt;
&lt;h2&gt;Detail Model Description&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;There are two datasets. We need to solve the challenges that are faced by the bank during credit lending.&lt;/li&gt;
&lt;li&gt;First dataset is (i) Internal bank dataset and second dataset is (ii) Civil external dataset.&lt;/li&gt;
&lt;li&gt;The target variable is Approved_Flag which contain 4 categories [&apos;P2&apos;, &apos;P1&apos;, &apos;P3&apos;, &apos;P4&apos;], segregating the customer
into class of giving the credit. P1 being the category where the bank can easier give the credit to that customer
whereas P4 being the category where it is not a good idea to give the credit to that customer, as it can increase the
NPA accounts (Non-Performing assets) of the bank.&lt;/li&gt;
&lt;li&gt;There are total 84 columns in two datasets. 26 columns in the first dataset and 62 columns in the second dataset.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;PROSPECTID&lt;/code&gt; col is a common column in both the first and second datasets indicating unique customer ID.&lt;/li&gt;
&lt;li&gt;To find association between numerical and numerical columns we will perform VIF test (Variance Inflation Factor).
Reject columns whose p value is greater than a particular threshold.&lt;/li&gt;
&lt;li&gt;For feature selection, we will perform Chi2-Square test and ANOVA test, since the target column is multi-class
categorical column.&lt;/li&gt;
&lt;li&gt;By checking the p_value of each column w.r.t. target variable, we can decide if it&apos;s statistically significant or
not.&lt;/li&gt;
&lt;li&gt;Made two models. One without credit score and another with credit score.&lt;/li&gt;
&lt;li&gt;It is observed that the accuracy of model without credit score feature has dramatically decreases.&lt;/li&gt;
&lt;li&gt;Without credit score the accuracy is 77% and with credit score the accuracy is 99%.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Dataset Columns Description&lt;/h2&gt;
&lt;h3&gt;Bank Dataset&lt;/h3&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Column&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;pct_tl_open_L6M&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Percent accounts opened in last 6 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;pct_tl_closed_L6M&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;percent accounts closed in last 6 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Tot_TL_closed_L12M&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Total accounts closed in last 12 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;pct_tl_closed_L12M&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;percent accounts closed in last 12 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Tot_Missed_Pmnt&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Total missed Payments&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CC_TL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Count of Credit card accounts&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Home_TL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Count of Housing loan accounts&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;PL_TL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Count of Personal loan accounts&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Secured_TL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Count of secured accounts&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Unsecured_TL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Count of unsecured accounts&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Other_TL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Count of other accounts&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Age_Oldest_TL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Age of oldest opened account&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Age_Newest_TL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Age of newest opened account&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h3&gt;Civil Dataset&lt;/h3&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Column&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;time_since_recent_payment&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Time Since recent Payment made&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;max_recent_level_of_deliq&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Maximum recent level of delinquency&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;num_deliq_6_12mts&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Number of times delinquent between last 6 and last 12 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;num_times_60p_dpd&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Number of times 60+ dpd&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;num_std_12mts&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Number of standard Payments in last 12 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;num_sub&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Number of sub standard payments - not making full payments&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;num_sub_6mts&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Number of sub standard payments in last 6 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;num_sub_12mts&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Number of sub standard payments in last 12 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;num_dbt&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Number of doubtful payments&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;num_lss&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Number of doubtful payments in last 12 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;recent_level_of_deliq&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Number of loss accounts in last 12 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CC_enq_L12m&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Credit card enquiries in last 6 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;PL_enq_L12m&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Personal Loan enquiries in last 6 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;time_since_recent_enq&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Personal Loan enquiries in last 12 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;enq_L3m&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Enquiries in last 6 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;last_prod_enq2&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Lates product enquired for&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;first_prod_enq2&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;First product enquired for&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;MARITALSTATUS&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Marital Status&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;EDUCATION&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Education level&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;AGE&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Age&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;GENDER&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Sex&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Time_With_Curr_Empr&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Time with current Employer&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CC_Flag&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Credit card Flag&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;PL_Flag&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Personal Loan Flag&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;pct_PL_enq_L6m_of_ever&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Percent enquiries PL in last 6 months to last 6 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;pct_CC_enq_L6m_of_ever&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Percent enquiries CC in last 6 months to last 6 months&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;HL_Flag&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Housing Loan Flag&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;GL_Flag&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Gold Loan Flag&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Approved_Flag&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Priority levels&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h3&gt;Important Notes from both the Dataset&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;The shape of bank internal dataset of customer is (51336, 26).&lt;/li&gt;
&lt;li&gt;The shape of civil dataset is (51336, 62)&lt;/li&gt;
&lt;li&gt;The common column in both dataset is &lt;code&gt;PROSPECTID&lt;/code&gt; which is unique ID for each customer.&lt;/li&gt;
&lt;li&gt;The value &quot;-99999&quot; in both the datasets are null values.&lt;/li&gt;
&lt;li&gt;We will remove all the null values if data lost is less than 20% of the total dataset.&lt;/li&gt;
&lt;li&gt;Total trade lines is total no of accounts of a customer.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;EDA&lt;/h2&gt;
&lt;h3&gt;Unique Values in Categorical Columns&lt;/h3&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Column&lt;/th&gt;
&lt;th&gt;Unique Values&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;MARITALSTATUS&lt;/td&gt;
&lt;td&gt;Married, Single&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;EDUCATION&lt;/td&gt;
&lt;td&gt;12TH, GRADUATE, SSC, POSTGRADUATE, UNDERGRADUATE, OTHERS, PROFESSIONAL&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;GENDER&lt;/td&gt;
&lt;td&gt;M, F&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;last_prod_enq2&lt;/td&gt;
&lt;td&gt;PL, ConsumerLoan, AL, CC, others, HL&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;first_prod_enq2&lt;/td&gt;
&lt;td&gt;PL, ConsumerLoan, others, AL, HL, CC&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Approved_Flag&lt;/td&gt;
&lt;td&gt;P2, P1, P3, P4&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;strong&gt;After performing all the statistics tests (i.e. Chi-Square, VIF and ANOVA test), it is found that only 43 columns are
important out of 82 columns.&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;[&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &apos;Age_Newest_TL&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;Age_Oldest_TL&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;Approved_Flag&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;CC_enq_L12m&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;CC_Flag&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;CC_TL&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;EDUCATION&apos;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &apos;first_prod_enq2&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;GENDER&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;GL_Flag&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;HL_Flag&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;Home_TL&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;last_prod_enq2&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;MARITALSTATUS&apos;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &apos;max_recent_level_of_deliq&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;NETMONTHLYINCOME&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;num_dbt_12mts&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;num_dbt&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;num_deliq_6_12mts&apos;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &apos;num_lss&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;num_std_12mts&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;num_sub_12mts&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;num_sub_6mts&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;num_sub&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;num_times_60p_dpd&apos;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &apos;pct_CC_enq_L6m_of_ever&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;pct_PL_enq_L6m_of_ever&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;pct_tl_closed_L12M&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;pct_tl_closed_L6M&apos;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &apos;pct_tl_open_L6M&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;PL_enq_L12m&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;PL_Flag&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;PL_TL&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;recent_level_of_deliq&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;Secured_TL&apos;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &apos;time_since_recent_enq&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;time_since_recent_payment&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;Time_With_Curr_Empr&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;Tot_Missed_Pmnt&apos;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &apos;Tot_TL_closed_L12M&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;Unsecured_TL&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;enq_L3m&apos;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&apos;Other_TL&apos;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;]&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2&gt;Data Visualization&lt;/h2&gt;
&lt;h3&gt;Age Distribution Graph&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-AGE.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The bank is majorly targeting people between 20 to 40.&lt;/li&gt;
&lt;li&gt;The data distribution of this dataset is majorly spread between the age group of 20 to 40.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Age of Oldest Loan/Trade Line Account (in Months)&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-Age_Oldest_TL.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;h3&gt;Time Since Recent Enquiry (in Months)&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-time_since_recent_enq.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;h3&gt;Credit Score Distribution&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-Credit_Score.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;p&gt;Most of the data distribution of credit score column is spread between 660 and 700 which fall under P2 category and
that’s why majorly category in target column is P2 category only.&lt;/p&gt;
&lt;h3&gt;90 Percentile Monthly Income Distribution&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-NETMONTHLYINCOME.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;p&gt;This column illustrate that the salary income majority of people falls between 20k to 35k. It can be observed that the
bank is mainly targeting those people whose is under 50k per month&lt;/p&gt;
&lt;h3&gt;Marital Status Distribution Graph&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-MARITALSTATUS.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;p&gt;This column indicates that 73.1% of people who are applying for the loan are married.&lt;/p&gt;
&lt;h3&gt;Education Distribution Graph&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-EDUCATION.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;p&gt;The Graduate and 12th pass population contribute significantly to the dataset&lt;/p&gt;
&lt;h3&gt;Gender Distribution Graph&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-GENDER.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;p&gt;Gender wise, the dataset shows that 88.7% who are applying for loan are male or we can say that the bank is targeting
male candidate more.&lt;/p&gt;
&lt;h3&gt;Last Product Enquiry Graph&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-last_prod_enq2.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;h3&gt;First Product Enquiry Graph&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-first_prod_enq2.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;h3&gt;Distribution of Target Variable Categories&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-Approved_Flag.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;p&gt;60% of the people in the dataset falls under P2 category for loan approval.&lt;/p&gt;
&lt;h3&gt;Data Visualization - Observations&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;73% people are married people in the dataset.&lt;/li&gt;
&lt;li&gt;This dataset contains have 88% of people as men who are likely to taken loan from the bank.&lt;/li&gt;
&lt;li&gt;Graduate people have more likelihood of taking or applying for loans. Banks also have more likelihood of approving of
loans to the graduate or educated people.&lt;/li&gt;
&lt;li&gt;Previous loans taken by the people in this dataset is other loan or consumer loans (such as furniture loan, fridge
loan etc).&lt;/li&gt;
&lt;li&gt;Most of the people in the dataset flows under P2 category for loan approval.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Minimum, Maximum and Median value of &lt;code&gt;Credit_Score&lt;/code&gt; for each category&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/min_max-Credit_Score.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;p&gt;The min and max credit score is P3 category is 489 and 776 respectively. This range indicates that for P3 category
creates a big ambiguity for the model to predict the output accurately. For P1 and P2 categories, it is easier for the
model to predict as it range from (701, 809) and (689 and 700) respectively.&lt;/p&gt;
&lt;h3&gt;Minimum, Maximum and median value of &lt;code&gt;AGE&lt;/code&gt; for each category&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-AGE.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;p&gt;Min age for all the category is 21. Max age varies from 63 to 67. It can be observed that for P1 category the median age
is higher as compare to other categories and as the category decrease median age also decreses.&lt;/p&gt;
&lt;h3&gt;Maximum and median value of Age Oldest Trade Line accounts for each category&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/plot-Age_Oldest_TL.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;h3&gt;Maximum and median value of Time with current enquiry accounts for each category&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://github.com/arv-anshul/notebooks/raw/main/credit-modeling/assets/img/min_max-Time_With_Curr_Empr.png&quot; alt=&quot;alt&quot; /&gt;&lt;/p&gt;
&lt;h3&gt;Observation of numerical and categorical cols w.r.t target variable i.e. (Approved_Flag)&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;P1 category range is (701-809)&lt;/li&gt;
&lt;li&gt;P2 category range is(669-700)&lt;/li&gt;
&lt;li&gt;P3 category range is (489-776)&lt;/li&gt;
&lt;li&gt;P3 category of target variable are the most ambiguous category. This can be observed by looking at the credit score
min and max value for P3 category which range from 489 to 776, whereas in case of P2 it&apos;s ranges from 669 to 701.&lt;/li&gt;
&lt;li&gt;Due to the most ambiguous category i.e. P3, during the predict also, the accuracy of the model is significantly
decreases due to the most ambiguous category.&lt;/li&gt;
&lt;li&gt;The median age who are getting P1 category loan are bit older than other categories. For eg. median age for P1
category is 40 whereas for P2 category it is 33 and for P3 category it is 31. Therefore it can be assumed that as the
age increases, loan approval becomes easier.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Model Training&lt;/h2&gt;
&lt;p&gt;We used ensemble techniques (bagging and boosting) to train the model. Mainly we used &lt;strong&gt;RandomForestClassifier&lt;/strong&gt; and
&lt;strong&gt;XGBoostClassifier&lt;/strong&gt; for classification. However, it is observed that &lt;strong&gt;XGBoost&lt;/strong&gt; classifier has better accuracy as
compare to &lt;strong&gt;RandomForest&lt;/strong&gt; classifier. With accuracy 99% &lt;strong&gt;XGBoost&lt;/strong&gt; is the best ML algorithm for the dataset with
credit score feature is included. However, when credit score feature is excluded, there is a significant drop in the
accuracy(76%) because the P3 category is most ambiguous category, the accuracy of the model is significantly decreases.&lt;/p&gt;
&lt;h3&gt;Classification Report Of &lt;code&gt;RandomForest&lt;/code&gt;&lt;/h3&gt;
&lt;h4&gt;Using &lt;code&gt;Credit_Score&lt;/code&gt; Feature&lt;/h4&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;precision&lt;/th&gt;
&lt;th&gt;recall&lt;/th&gt;
&lt;th&gt;f1-score&lt;/th&gt;
&lt;th&gt;support&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;P1&lt;/td&gt;
&lt;td&gt;0.94&lt;/td&gt;
&lt;td&gt;1.00&lt;/td&gt;
&lt;td&gt;0.97&lt;/td&gt;
&lt;td&gt;1224&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;P2&lt;/td&gt;
&lt;td&gt;1.00&lt;/td&gt;
&lt;td&gt;1.00&lt;/td&gt;
&lt;td&gt;1.00&lt;/td&gt;
&lt;td&gt;6397&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;P3&lt;/td&gt;
&lt;td&gt;1.00&lt;/td&gt;
&lt;td&gt;0.95&lt;/td&gt;
&lt;td&gt;0.98&lt;/td&gt;
&lt;td&gt;1595&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;P4&lt;/td&gt;
&lt;td&gt;1.00&lt;/td&gt;
&lt;td&gt;1.00&lt;/td&gt;
&lt;td&gt;1.00&lt;/td&gt;
&lt;td&gt;1309&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;accuracy&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;0.99&lt;/td&gt;
&lt;td&gt;10525&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;macro avg&lt;/td&gt;
&lt;td&gt;0.99&lt;/td&gt;
&lt;td&gt;0.99&lt;/td&gt;
&lt;td&gt;0.99&lt;/td&gt;
&lt;td&gt;10525&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;weighted avg&lt;/td&gt;
&lt;td&gt;0.99&lt;/td&gt;
&lt;td&gt;0.99&lt;/td&gt;
&lt;td&gt;0.99&lt;/td&gt;
&lt;td&gt;10525&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h4&gt;Without &lt;code&gt;Credit_Score&lt;/code&gt; Feature&lt;/h4&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;precision&lt;/th&gt;
&lt;th&gt;recall&lt;/th&gt;
&lt;th&gt;f1-score&lt;/th&gt;
&lt;th&gt;support&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;P1&lt;/td&gt;
&lt;td&gt;0.82&lt;/td&gt;
&lt;td&gt;0.70&lt;/td&gt;
&lt;td&gt;0.75&lt;/td&gt;
&lt;td&gt;1224&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;P2&lt;/td&gt;
&lt;td&gt;0.79&lt;/td&gt;
&lt;td&gt;0.93&lt;/td&gt;
&lt;td&gt;0.86&lt;/td&gt;
&lt;td&gt;6397&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;P3&lt;/td&gt;
&lt;td&gt;0.45&lt;/td&gt;
&lt;td&gt;0.21&lt;/td&gt;
&lt;td&gt;0.28&lt;/td&gt;
&lt;td&gt;1595&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;P4&lt;/td&gt;
&lt;td&gt;0.75&lt;/td&gt;
&lt;td&gt;0.70&lt;/td&gt;
&lt;td&gt;0.72&lt;/td&gt;
&lt;td&gt;1309&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;accuracy&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;0.77&lt;/td&gt;
&lt;td&gt;10525&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;macro avg&lt;/td&gt;
&lt;td&gt;0.70&lt;/td&gt;
&lt;td&gt;0.63&lt;/td&gt;
&lt;td&gt;0.65&lt;/td&gt;
&lt;td&gt;10525&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;weighted avg&lt;/td&gt;
&lt;td&gt;0.74&lt;/td&gt;
&lt;td&gt;0.77&lt;/td&gt;
&lt;td&gt;0.74&lt;/td&gt;
&lt;td&gt;10525&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h3&gt;Classification Report Of &lt;code&gt;XGBoost&lt;/code&gt;&lt;/h3&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Class&lt;/th&gt;
&lt;th&gt;P1&lt;/th&gt;
&lt;th&gt;P2&lt;/th&gt;
&lt;th&gt;P3&lt;/th&gt;
&lt;th&gt;P4&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Precision&lt;/td&gt;
&lt;td&gt;0.813&lt;/td&gt;
&lt;td&gt;0.826&lt;/td&gt;
&lt;td&gt;0.434&lt;/td&gt;
&lt;td&gt;0.772&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Recall&lt;/td&gt;
&lt;td&gt;0.788&lt;/td&gt;
&lt;td&gt;0.912&lt;/td&gt;
&lt;td&gt;0.305&lt;/td&gt;
&lt;td&gt;0.698&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;F1 Score&lt;/td&gt;
&lt;td&gt;0.800&lt;/td&gt;
&lt;td&gt;0.866&lt;/td&gt;
&lt;td&gt;0.358&lt;/td&gt;
&lt;td&gt;0.733&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2&gt;Hyperparameter Tuning&lt;/h2&gt;
&lt;p&gt;Using &lt;code&gt;skopt.BayesSearchCV&lt;/code&gt;, we got the best parameter for our XGBoost model. The parameters are:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;{&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;alpha&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;10&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;colsample_bytree&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;0.9&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;learning_rate&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;1.0&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;max_depth&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;3&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;n_estimators&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;100&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;num_classes&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;4&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  &quot;objective&quot;&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;&quot;multi:softmax&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;With these parameters, accuracy increases by 1% when the model is trained without &lt;code&gt;Credit_Score&lt;/code&gt; feature.&lt;/strong&gt;&lt;/p&gt;
</content:encoded><category>project</category><category>project</category><category>collaboration</category><category>ml</category><author>Anshul Raj Verma</author></item><item><title>How To Perform EDA</title><link>https://arv-anshul.github.io/blog/2024/how-to-eda</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/how-to-eda</guid><description>Explained the process through which you can perform astonishing EDA on your datasets.</description><pubDate>Mon, 22 Apr 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Performing EDA on a dataset is very difficult and time taking process because there is many thing you can do while
performing EDA on your dataset.&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;https://realpython.com/cdn-cgi/image/width=1920,format=auto/https://files.realpython.com/media/Showcase-Polars_Watermarked.4e25d4f6c9a7.jpg&quot; alt=&quot;image for eda - realpython&quot; /&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I will generally use &lt;a href=&quot;https://pola.rs&quot;&gt;&lt;code&gt;polars&lt;/code&gt;&lt;/a&gt; library in this article.&lt;/p&gt;
&lt;p&gt;For plotting I&apos;ll generally use &lt;a href=&quot;https://seaborn.pydata.org/&quot;&gt;&lt;code&gt;seaborn&lt;/code&gt;&lt;/a&gt; library.&lt;/p&gt;
&lt;p&gt;First perform univariate analysis without any column dropping, after that perform BiVariate analysis and then decide
whether to drop a feature or not. Also, provide a argument which proofs that your dropping decision is right.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Numerical Features&lt;/h2&gt;
&lt;p&gt;There are some basic Descriptive Analysis you can do with numerical column like mean, median, quantiles, etc. You can do
this by calling the &lt;a href=&quot;https://docs.pola.rs/py-polars/html/reference/dataframe/api/polars.DataFrame.describe.html&quot;&gt;polars.DataFrame.describe&lt;/a&gt; method.&lt;/p&gt;
&lt;h3&gt;Univariate&lt;/h3&gt;
&lt;h4&gt;Skewness&lt;/h4&gt;
&lt;p&gt;Skewness is a measure that describes the asymmetry or lack of symmetry in the distribution of a dataset. The value of
skewness can provide insights into the shape and nature of the data distribution. Here&apos;s how to interpret skewness
values:&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Skewness Value&lt;/th&gt;
&lt;th&gt;Interpretation&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Negative Value&lt;/td&gt;
&lt;td&gt;The distribution is left-skewed or negatively skewed. This means the tail on the left side of the distribution is longer, and the bulk of the values are concentrated on the right side of the distribution. The mean is typically less than the median.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Positive Value&lt;/td&gt;
&lt;td&gt;The distribution is right-skewed or positively skewed. This means the tail on the right side of the distribution is longer, and the bulk of the values are concentrated on the left side of the distribution. The mean is typically greater than the median.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Zero&lt;/td&gt;
&lt;td&gt;The distribution is symmetric, with no skew. The mean, median, and mode are approximately equal, and the distribution is evenly balanced on both sides.&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;The magnitude of the skewness value also provides information about the degree of skewness:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;If the skewness value is &lt;strong&gt;close to 0&lt;/strong&gt; (between -0.5 and 0.5), the distribution is approximately symmetric with
little to no skew.&lt;/li&gt;
&lt;li&gt;If the skewness value is &lt;strong&gt;significantly negative&lt;/strong&gt; (below -1), it suggests strong left skewness.&lt;/li&gt;
&lt;li&gt;If the skewness value is &lt;strong&gt;significantly positive&lt;/strong&gt; (above 1), it suggests strong right skewness.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;In summary, the interpretation of skewness values is as follows:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Negative skewness&lt;/strong&gt;: The distribution is left-skewed, with the tail extending towards the left.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Positive skewness&lt;/strong&gt;: The distribution is right-skewed, with the tail extending towards the right.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Zero skewness&lt;/strong&gt;: The distribution is symmetric, with no skew.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Magnitude of skewness&lt;/strong&gt;: Indicates the degree of skewness, with values close to 0 suggesting little to no skew, and
values below -1 or above 1 suggesting strong skewness.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Use &lt;a href=&quot;https://docs.pola.rs/py-polars/html/reference/series/api/polars.Series.skew.html&quot;&gt;polars.Series.skew&lt;/a&gt; method to calculate skewness of a numerical feature.&lt;/p&gt;
&lt;h4&gt;Kurtosis&lt;/h4&gt;
&lt;p&gt;Kurtosis is a statistical measure that describes the degree of peakedness and tailedness of a probability distribution.
It provides information about the shape of the distribution, specifically the proportion of data that is concentrated in
the tails compared to the normal distribution.&lt;/p&gt;
&lt;p&gt;There are three main types of kurtosis:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Mesokurtic&lt;/strong&gt;: A distribution with a kurtosis value of 3, which is the same as a normal distribution. &lt;em&gt;This
indicates a moderate level of peakedness and tailedness.&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Leptokurtic&lt;/strong&gt;: A distribution with a kurtosis value greater than 3. This indicates a higher, more peaked
distribution with heavier, fatter tails compared to a normal distribution. &lt;em&gt;Leptokurtic distributions have more
outliers and extreme values.&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Platykurtic&lt;/strong&gt;: A distribution with a kurtosis value less than 3. This indicates a flatter, more dispersed
distribution with lighter, thinner tails compared to a normal distribution. &lt;em&gt;Platykurtic distributions have fewer
outliers and extreme values.&lt;/em&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
&lt;p&gt;The excess kurtosis is calculated by &lt;strong&gt;subtracting 3 from the kurtosis value&lt;/strong&gt;. Positive excess kurtosis indicates a
&lt;strong&gt;leptokurtic distribution&lt;/strong&gt;, while negative excess kurtosis indicates a &lt;strong&gt;platykurtic distribution&lt;/strong&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;In summary, kurtosis provides information about the shape of a distribution, specifically the concentration of values in
the tails compared to a normal distribution. Higher kurtosis indicates more outliers and extreme values, while lower
kurtosis indicates fewer outliers and a more dispersed distribution.&lt;/p&gt;
&lt;p&gt;Use &lt;a href=&quot;https://docs.pola.rs/py-polars/html/reference/series/api/polars.Series.kurtosis.html&quot;&gt;polars.Series.kurtosis&lt;/a&gt; method to calculate kurtosis value of a numerical feature. This method has &lt;code&gt;fisher&lt;/code&gt;
argument, if &lt;code&gt;fisher=True&lt;/code&gt; then &lt;strong&gt;normal is 0.0&lt;/strong&gt;; if &lt;code&gt;fisher=False&lt;/code&gt; then &lt;strong&gt;normal is 3.0&lt;/strong&gt;.&lt;/p&gt;
&lt;h4&gt;Distribution&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;kdeplot&lt;/code&gt;: Plot distribution of data using &lt;strong&gt;Kernel Density Estimation&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;histplot&lt;/code&gt;: Plot histogram of data.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;ecdfplot&lt;/code&gt;: Plot empirical cumulative distribution functions.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;rugplot&lt;/code&gt;: Plot marginal distributions by drawing ticks along the x and y axes.&lt;/li&gt;
&lt;/ul&gt;
&lt;blockquote&gt;
&lt;p&gt;See &lt;a href=&quot;https://seaborn.pydata.org/api.html#distribution-plots&quot;&gt;&lt;code&gt;seaborn&lt;/code&gt; library docs&lt;/a&gt; to plot different data
distribution.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h4&gt;Box Plot&lt;/h4&gt;
&lt;p&gt;Plot the 5-number summary of data with BoxPlot.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;What is 5-number summary of a data?&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;This represents the &lt;code&gt;#!math (\text{Q1} - 1.5*\text{IQR})&lt;/code&gt;, 25th %tile &lt;code&gt;#!math (\text{Q1})&lt;/code&gt;, 50th %tile, 75th %tile
&lt;code&gt;#!math (\text{Q3})&lt;/code&gt; and &lt;code&gt;#!math (\text{Q3} + 1.5*\text{IQR})&lt;/code&gt; values of data.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;BoxPlot easily shows the outliers of the data.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img src=&quot;https://miro.medium.com/max/9000/1*2c21SkzJMf3frPXPAR_gZA.png&quot; alt=&quot;boxplot&quot; /&gt;&lt;/p&gt;
&lt;h4&gt;Percentile&lt;/h4&gt;
&lt;p&gt;You can use mean or median to know the central value of data. But what about identifying specific data points relative
to the entire dataset&apos;s distribution?&lt;/p&gt;
&lt;p&gt;Percentiles offer a solution by dividing the data into hundredths and determining where a particular value falls within
that range. They provide valuable insights into the spread and distribution of data, aiding in comparisons and
understanding the dataset&apos;s overall characteristics.&lt;/p&gt;
&lt;p&gt;You can use percentile to know dataset&apos;s outlier values. After ploting &lt;a href=&quot;#box-plot&quot;&gt;BoxPlot&lt;/a&gt; you can manually check the
outlier values with 95%tile or 99%tile.&lt;/p&gt;
&lt;p&gt;Use &lt;a href=&quot;https://docs.pola.rs/py-polars/html/reference/series/api/polars.Series.quantile.html&quot;&gt;polars.Series.quantile&lt;/a&gt; method to calculate nth quantile of dataset.&lt;/p&gt;
&lt;h3&gt;BiVariate&lt;/h3&gt;
&lt;h4&gt;Regression Plots&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Regression Plot&lt;/strong&gt;: Scatter plot but with a best-fit regression line in there.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Residual Plot&lt;/strong&gt;: Plot the residuals/error of a regression model and check whether it any linear relationship.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;See &lt;a href=&quot;https://seaborn.pydata.org/api.html#regression-plots&quot;&gt;&lt;code&gt;seaborn&lt;/code&gt; library docs&lt;/a&gt; for regression plots details.&lt;/p&gt;
&lt;h4&gt;Relational Plots&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Scatter Plot&lt;/strong&gt;: Check the linear relationship between two datasets.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Line Plot&lt;/strong&gt;: Plot the relationship between &lt;code&gt;x&lt;/code&gt; and &lt;code&gt;y&lt;/code&gt; with many parameters such as &lt;code&gt;hue&lt;/code&gt;, &lt;code&gt;size&lt;/code&gt; and &lt;code&gt;style&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;See &lt;a href=&quot;https://seaborn.pydata.org/api.html#relational-plots&quot;&gt;&lt;code&gt;seaborn&lt;/code&gt; library docs&lt;/a&gt; for relational plots details.&lt;/p&gt;
&lt;h4&gt;More Plots&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;FacetGrid&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;PairPlot&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;JointPlot&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Checkout &lt;a href=&quot;https://seaborn.pydata.org/api.html#multi-plot-grids&quot;&gt;&lt;code&gt;seaborn&lt;/code&gt; docs&lt;/a&gt; for more details.&lt;/p&gt;
&lt;h3&gt;MultiVariate&lt;/h3&gt;
&lt;h4&gt;Correlation&lt;/h4&gt;
&lt;h4&gt;MultiCollinearity&lt;/h4&gt;
&lt;h3&gt;Extra Concepts&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Homoscedasity (concept)&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Categorical Features&lt;/h2&gt;
&lt;h3&gt;Univariate&lt;/h3&gt;
&lt;h4&gt;CountPlot&lt;/h4&gt;
&lt;h3&gt;BiVariate&lt;/h3&gt;
&lt;h4&gt;Contengency Table&lt;/h4&gt;
&lt;h3&gt;MultiVariate&lt;/h3&gt;
&lt;h4&gt;Correlation&lt;/h4&gt;
&lt;h2&gt;Hypothesis Testing&lt;/h2&gt;
&lt;h3&gt;Numerical VS Numerical&lt;/h3&gt;
&lt;h4&gt;Z-test&lt;/h4&gt;
&lt;h4&gt;T-test&lt;/h4&gt;
&lt;h3&gt;Categorical VS Categorical&lt;/h3&gt;
&lt;h4&gt;Chi-Square&lt;/h4&gt;
&lt;h3&gt;Numerical VS Categorical&lt;/h3&gt;
&lt;h4&gt;OneWay ANOVA&lt;/h4&gt;
&lt;h4&gt;TwoWay ANOVA&lt;/h4&gt;
</content:encoded><category>blog</category><category>eda</category><category>statistics</category><author>Anshul Raj Verma</author></item><item><title>Basics of Statistics for ML</title><link>https://arv-anshul.github.io/blog/2024/basics-of-statistics</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/basics-of-statistics</guid><description>Learn basics of Descriptive and Inferential Statistics for ML.</description><pubDate>Fri, 12 Apr 2024 00:00:00 GMT</pubDate><content:encoded>&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;graph TD;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Inferential_Statistics[&quot;Inferential Statistics&quot;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Descriptive_Statistics[&quot;Descriptive Statistics&quot;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Measure_of_Central_Tendency[&quot;Measure of Central Tendency&quot;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Weighted_Mean[&quot;Weighted Mean&quot;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Trimmed_Mean[&quot;Trimmed Mean&quot;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Measure_of_Dispersion[&quot;Measure of Dispersion&quot;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Standard_Deviation[&quot;Standard Deviation&quot;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    CV[&quot;Coefficient of Variation&quot;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Five_Number_Summary[&quot;5 Number Summary&quot;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Box_Plot[&quot;Box Plot / Whisker Plot&quot;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Statistics --&amp;gt; Descriptive_Statistics&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Statistics --&amp;gt; Inferential_Statistics&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Descriptive_Statistics --&amp;gt; Measure_of_Central_Tendency&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Descriptive_Statistics --&amp;gt; Measure_of_Dispersion&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Measure_of_Central_Tendency --&amp;gt; Mean&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Measure_of_Central_Tendency --&amp;gt; Median&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Measure_of_Central_Tendency --&amp;gt; Mode&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Mean --&amp;gt; Weighted_Mean&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Mean --&amp;gt; Trimmed_Mean&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Measure_of_Dispersion --&amp;gt; UniVariate&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Measure_of_Dispersion --&amp;gt; BiVariate&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    UniVariate --&amp;gt; Range&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    UniVariate --&amp;gt; Variance&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    UniVariate --&amp;gt; Standard_Deviation&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    UniVariate --&amp;gt; CV&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    UniVariate --&amp;gt; Five_Number_Summary&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Five_Number_Summary --&amp;gt; Percentile&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Five_Number_Summary --&amp;gt; Box_Plot&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    BiVariate --&amp;gt; Covariance&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    BiVariate --&amp;gt; Correlation&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2&gt;Statistics&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://youtu.be/Uv3Blie7F3g&quot;&gt;&lt;strong&gt;Descriptive Statistics Part 1&lt;/strong&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://youtu.be/1ndVC500-EU&quot;&gt;&lt;strong&gt;Descriptive Statistics Part 2&lt;/strong&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://drive.google.com/file/d/1da0Wj1KyUxLtGVnFcPTpgWvKQsWjZly-/view&quot;&gt;&lt;strong&gt;CampusX Notes - 1&lt;/strong&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://drive.google.com/file/d/1edN9LSbMP3lPh4YMem4n9K0Y6lSeFaP1/view&quot;&gt;&lt;strong&gt;CampusX Notes - 2&lt;/strong&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/campusx-learning/blob/main/Descriptive%20Statistics/README.md&quot;&gt;&lt;strong&gt;My Previous Notes&lt;/strong&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Population&lt;/h3&gt;
&lt;p&gt;Population represents the whole/entire group of individual or object that we are interested in studying.&lt;/p&gt;
&lt;h3&gt;Sample&lt;/h3&gt;
&lt;p&gt;Sample is a subset of Population. It is smaller group of individual or object that we select from the population to
study. Samples are used to estimate characteristics of the population.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!TIP] Things to care while selecting Sample from a Population&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Sample Size&lt;/li&gt;
&lt;li&gt;Random Data&lt;/li&gt;
&lt;li&gt;Representative&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;[!IMPORTANT] Example: Population and Sample Data&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;All Python Programmer on the earth VS Python Programmer in India&lt;/li&gt;
&lt;li&gt;All cricket fans VS Fans who were present in the stadium&lt;/li&gt;
&lt;li&gt;All students VS Who visit college for lectures&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Descriptive Statistics&lt;/h2&gt;
&lt;p&gt;Helps you to learn underlying information of the data. Generally, data is a Sample of the Population.&lt;/p&gt;
&lt;p&gt;The goal of statistical inference is to use the information obtained from the sample to make inferences about the
population parameters.&lt;/p&gt;
&lt;h3&gt;Measure of Central Tendency&lt;/h3&gt;
&lt;p&gt;A measure of central tendency is a statistical measure that represents a typical or central value for a dataset. It
provides a summary of the data by identifying a single value that is most representative of the dataset as a whole.&lt;/p&gt;
&lt;p&gt;You can use methods like Mean, Median, Mode for this.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Mean&lt;/strong&gt;: The mean is the sum of all values in the dataset divided by the number of values.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Median&lt;/strong&gt;: The median is the middle value in the dataset when the data is arranged in order.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Mode&lt;/strong&gt;: The mode is the value that appears most frequently in the dataset.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Measure of Dispersion&lt;/h2&gt;
&lt;p&gt;A measure of dispersion is a statistical measure that &lt;strong&gt;describes the spread or variability of a dataset&lt;/strong&gt;. It provides
&lt;strong&gt;information about how the data is distributed around the central tendency&lt;/strong&gt; (mean, median or mode) of the dataset.&lt;/p&gt;
&lt;h3&gt;Variance&lt;/h3&gt;
&lt;p&gt;The variance is the average of the squared differences between each data point and the mean. It measures the average
distance of each data point from the mean and is useful in comparing the dispersion of datasets with different means.&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Sample Variance&lt;/th&gt;
&lt;th&gt;Population Variance&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;#!math \sigma^2 = \frac{\sum\_{i=1}^{n} (x_i - \bar{x})^2}{n-1}&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;#!math \sigma^2 = \frac{\sum\_{i=1}^{N} (x_i - \mu)^2}{N}&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;blockquote&gt;
&lt;p&gt;[!IMPORTANT] Why &lt;code&gt;n-1&lt;/code&gt; in Sample Variance?&lt;/p&gt;
&lt;p&gt;By dividing by &lt;code&gt;#!math (n−1)&lt;/code&gt;, we make the sample variance an unbiased estimator of the population variance. This
correction is particularly important when dealing with small sample sizes, as it helps to reduce bias in the
estimation of the population variance.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Standard Deviation&lt;/h3&gt;
&lt;p&gt;The standard deviation is the square root of the variance. It is a widely used measure of dispersion that is useful in
describing the shape of a distribution like Normal Distribution.&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Sample Standard Deviation&lt;/th&gt;
&lt;th&gt;Population Standard Deviation&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;#!math s = \sqrt{\frac{\sum_{i=1}^{n} (x_i - \bar{x})^2}{n-1}}&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;#!math \sigma = \sqrt{\frac{\sum_{i=1}^{N} (x_i - \mu)^2}{N}}&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h3&gt;Coefficient of Variation (CV)&lt;/h3&gt;
&lt;p&gt;CV is the ratio of the standard deviation to the mean expressed as a percentage. It is used to compare the variability
of datasets with mean. CV is a statistical measure that expresses the amount of variability in a dataset relative to the
mean.&lt;/p&gt;
&lt;h3&gt;&lt;code&gt;#!math \frac{\sigma}{\mu} \cdot 100 = \text{CV}\%&lt;/code&gt;&lt;/h3&gt;
&lt;h4&gt;Why Coefficient of Variation Exits?&lt;/h4&gt;
&lt;p&gt;This method is used to compare the variance of two different feature like Salary of Employees and Experience of
Employees. But using CV you can compare the variability of those two feature.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Steps&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Calculate Mean and Standard Deviation of both feature.&lt;/li&gt;
&lt;li&gt;Calculate CV of each feature using above formula.&lt;/li&gt;
&lt;li&gt;Now, you can compare both feature&apos;s CV to know which is feature has more variability.&lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
&lt;p&gt;[!NOTE] This statistical method is not widely used.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Inferential Statistics&lt;/h2&gt;
&lt;p&gt;Using Inferential Statistics we make conclusions and predictions about a population based on a sample.&lt;/p&gt;
&lt;p&gt;It involves the use of probability theory to estimate the likelihood of certain events occurring, hypothesis testing to
determine if a certain claim about a population is supported by the data, and regression analysis to examine the
relationships between variables.&lt;/p&gt;
&lt;h3&gt;Covariance&lt;/h3&gt;
&lt;p&gt;Covariance is a statistical measure that describes the degree to which two variables are linearly related. It measures
how much those two variables change together, such that when one variable increases, does the other variable also
increase, or does it decrease?&lt;/p&gt;
&lt;h3&gt;&lt;code&gt;#!math \text{Cov}(x, y) = \frac{\sum_{i = 0}^{n}{(x_i - \bar{x}) (y_i - \bar{y})}}{n - 1}&lt;/code&gt;&lt;/h3&gt;
&lt;h4&gt;Interpretation&lt;/h4&gt;
&lt;p&gt;If the covariance between two variables is positive, it means that the variables tend to move together in the same
direction. If the covariance is negative, it means that the variables tend to move in opposite directions. A covariance
of zero indicates that the variables are not linearly related.&lt;/p&gt;
&lt;h4&gt;Disadvantage&lt;/h4&gt;
&lt;p&gt;One limitation of covariance is that it does not tell us about the strength of the relationship between two variables,
since the magnitude of covariance is affected by the scale of the variables.&lt;/p&gt;
&lt;h4&gt;Variance V/S CoVariance&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;Covariance is a measure of how much those two variables change together, while variance is a measure of how much a
single variable changes from its mean.&lt;/li&gt;
&lt;li&gt;The variance of a variable is the average of the squared differences from the mean, while the covariance between two
variables is the average product of their deviations from their respective means.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;img src=&quot;https://miro.medium.com/v2/resize:fit:1400/0*rU-DLXwSmfdEruQ9.jpg&quot; alt=&quot;Covariance&quot; /&gt;&lt;/p&gt;
&lt;h3&gt;Corelation&lt;/h3&gt;
&lt;p&gt;Correlation refers to a statistical relationship between two or more variables. Specifically, it measures the degree to
which two variables are related and how they tend to change together.&lt;/p&gt;
&lt;h3&gt;&lt;code&gt;#!math \text{Correlation} = \frac{\text{Cov}(x, y)}{\sigma x * \sigma y}&lt;/code&gt;&lt;/h3&gt;
&lt;h4&gt;Interpretation&lt;/h4&gt;
&lt;p&gt;Correlation is often measured using a statistical tool called the correlation coefficient, which ranges from -1 to 1, A
correlation coefficient of -1 indicates a perfect negative correlation, a correlation coefficient of 0 indicates no
correlation, and a correlation coefficient of 1 indicates a perfect positive correlation.&lt;/p&gt;
&lt;h4&gt;Correlation and Causation&lt;/h4&gt;
&lt;p&gt;The phrase &lt;strong&gt;&quot;correlation does not imply causation&quot;&lt;/strong&gt;[^1] means that just because two variables are associated with each
other, it does not necessarily mean that one causes the other.&lt;/p&gt;
&lt;p&gt;In other words, a correlation between two variables does not necessarily imply that one variable is the reason for the
other variable&apos;s behavior.&lt;/p&gt;
&lt;p&gt;[^1]: &lt;strong&gt;&quot;correlation does not imply causation&quot;&lt;/strong&gt;: Agar koi ghatna correlated hai toh iska matlab yeh nhi ki pehle ghatna
ki hone ki wajah se he dusri ghatna ho rhi hai.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Suppose there is a positive correlation between the number of :firefighter: firefighters present at a fire and the
amount of :adhesive_bandage: damage caused by the :fire: fire. One might be tempted to conclude that the presence of
:firefighter: firefighters causes more :adhesive_bandage: damage. However, this correlation could be explained by a
third variable - the severity of the fire. Severer fires might require more firefighters to be present, and cause more
damage.&lt;/p&gt;
&lt;p&gt;Thus, while correlations can provide valuable insights into how different variables are related, they cannot be used
to establish causality. Establishing causality often requires additional evidence such as experiments, randomized
controlled trials, or well-designed observational studies.&lt;/p&gt;
&lt;/blockquote&gt;
</content:encoded><category>blog</category><category>ml</category><category>statistics</category><author>Anshul Raj Verma</author></item><item><title>Bash Useful Commands</title><link>https://arv-anshul.github.io/blog/2024/bash-useful-commands</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/bash-useful-commands</guid><description>Some daily life useful commands.</description><pubDate>Wed, 10 Apr 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Bash&lt;/h2&gt;
&lt;h3&gt;Display ANSI Colors with Their Color-Code&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;function&lt;/span&gt;&lt;span&gt; colormap&lt;/span&gt;&lt;span&gt;() {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    range_start&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;${1&lt;/span&gt;&lt;span&gt;:-&lt;/span&gt;&lt;span&gt;1}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    range_end&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;${2&lt;/span&gt;&lt;span&gt;:-&lt;/span&gt;&lt;span&gt;255}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    for&lt;/span&gt;&lt;span&gt; i&lt;/span&gt;&lt;span&gt; in&lt;/span&gt;&lt;span&gt; $(&lt;/span&gt;&lt;span&gt;seq&lt;/span&gt;&lt;span&gt; $range_start&lt;/span&gt;&lt;span&gt; $range_end&lt;/span&gt;&lt;span&gt;); &lt;/span&gt;&lt;span&gt;do&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        echo&lt;/span&gt;&lt;span&gt; -en&lt;/span&gt;&lt;span&gt; &quot;\e[48;5;${&lt;/span&gt;&lt;span&gt;i&lt;/span&gt;&lt;span&gt;}m  ${(&lt;/span&gt;&lt;span&gt;l&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;span&gt;3&lt;/span&gt;&lt;span&gt;::&lt;/span&gt;&lt;span&gt;0&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;span&gt;i&lt;/span&gt;&lt;span&gt;}  \e[0m &quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        [[ $((&lt;/span&gt;&lt;span&gt;i&lt;/span&gt;&lt;span&gt; %&lt;/span&gt;&lt;span&gt; 10&lt;/span&gt;&lt;span&gt;)) -eq &lt;/span&gt;&lt;span&gt;0&lt;/span&gt;&lt;span&gt; ]] &amp;amp;&amp;amp; &lt;/span&gt;&lt;span&gt;echo&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    done&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    return&lt;/span&gt;&lt;span&gt; 0&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;The &lt;code&gt;colormap&lt;/code&gt; function will print the ANSI colors with codes in your terminal.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;colormap&lt;/span&gt;&lt;span&gt;           # (000 - 255)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;colormap&lt;/span&gt;&lt;span&gt; 200&lt;/span&gt;&lt;span&gt;       # (200 - 255)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;colormap&lt;/span&gt;&lt;span&gt; 100&lt;/span&gt;&lt;span&gt; 120&lt;/span&gt;&lt;span&gt;   # (100 - 120)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2&gt;Docker&lt;/h2&gt;
&lt;h3&gt;Clear All Caches, Images, Containers, Volumes of Docker&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; system&lt;/span&gt;&lt;span&gt; prune&lt;/span&gt;&lt;span&gt; -a&lt;/span&gt;&lt;span&gt; --volumes&lt;/span&gt;&lt;span&gt; --force&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2&gt;Git&lt;/h2&gt;
&lt;h3&gt;Beautiful One Line - &lt;code&gt;git log&lt;/code&gt;&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;alias&lt;/span&gt;&lt;span&gt; glog&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;git log --color --graph --pretty=format:&apos;%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)&amp;lt;%an&amp;gt;%Creset&apos; --abbrev-commit --branches&quot;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; glog&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;* 6914e04 - (&lt;/span&gt;&lt;span&gt;HEAD&lt;/span&gt;&lt;span&gt; -&amp;gt; &lt;/span&gt;&lt;span&gt;main,&lt;/span&gt;&lt;span&gt; origin/main&lt;/span&gt;&lt;span&gt;) 📝 Update docs/index.md (&lt;/span&gt;&lt;span&gt;5&lt;/span&gt;&lt;span&gt; hours&lt;/span&gt;&lt;span&gt; ago&lt;/span&gt;&lt;span&gt;) &amp;lt;Anshul Raj Verma&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;*   3d91241 - Merge branch &lt;/span&gt;&lt;span&gt;&apos;new/friends-page&apos;&lt;/span&gt;&lt;span&gt; (&lt;/span&gt;&lt;span&gt;5&lt;/span&gt;&lt;span&gt; hours&lt;/span&gt;&lt;span&gt; ago&lt;/span&gt;&lt;span&gt;) &amp;lt;Anshul Raj Verma&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;|&lt;/span&gt;&lt;span&gt;\&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;| &lt;/span&gt;&lt;span&gt;*&lt;/span&gt;&lt;span&gt; 6160ae5&lt;/span&gt;&lt;span&gt; -&lt;/span&gt;&lt;span&gt; 💅&lt;/span&gt;&lt;span&gt; Update&lt;/span&gt;&lt;span&gt; UI&lt;/span&gt;&lt;span&gt; of&lt;/span&gt;&lt;span&gt; friends.md&lt;/span&gt;&lt;span&gt; (5 &lt;/span&gt;&lt;span&gt;hours&lt;/span&gt;&lt;span&gt; ago&lt;/span&gt;&lt;span&gt;) &amp;lt;Anshul Raj Verma&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;| &lt;/span&gt;&lt;span&gt;*&lt;/span&gt;&lt;span&gt; 42b52d8&lt;/span&gt;&lt;span&gt; -&lt;/span&gt;&lt;span&gt; 🔨&lt;/span&gt;&lt;span&gt; Add&lt;/span&gt;&lt;span&gt; friends.md&lt;/span&gt;&lt;span&gt; to&lt;/span&gt;&lt;span&gt; Home&lt;/span&gt;&lt;span&gt; nav&lt;/span&gt;&lt;span&gt; (6 &lt;/span&gt;&lt;span&gt;hours&lt;/span&gt;&lt;span&gt; ago&lt;/span&gt;&lt;span&gt;) &amp;lt;Anshul Raj Verma&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;| &lt;/span&gt;&lt;span&gt;*&lt;/span&gt;&lt;span&gt; bef45f6&lt;/span&gt;&lt;span&gt; -&lt;/span&gt;&lt;span&gt; ✨&lt;/span&gt;&lt;span&gt; Setup&lt;/span&gt;&lt;span&gt; to&lt;/span&gt;&lt;span&gt; add&lt;/span&gt;&lt;span&gt; friends&lt;/span&gt;&lt;span&gt; on&lt;/span&gt;&lt;span&gt; website&lt;/span&gt;&lt;span&gt; (2 &lt;/span&gt;&lt;span&gt;days&lt;/span&gt;&lt;span&gt; ago&lt;/span&gt;&lt;span&gt;) &amp;lt;Anshul Raj Verma&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;|&lt;/span&gt;&lt;span&gt;/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;* 59340cf - ref: ✨ Add starship.md in Bash (&lt;/span&gt;&lt;span&gt;2&lt;/span&gt;&lt;span&gt; days&lt;/span&gt;&lt;span&gt; ago&lt;/span&gt;&lt;span&gt;) &amp;lt;Anshul Raj Verma&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;* ecc8e94 - ✨ Add new nav item &lt;/span&gt;&lt;span&gt;&quot;References&quot;&lt;/span&gt;&lt;span&gt; (&lt;/span&gt;&lt;span&gt;3&lt;/span&gt;&lt;span&gt; days&lt;/span&gt;&lt;span&gt; ago&lt;/span&gt;&lt;span&gt;) &amp;lt;Anshul Raj Verma&amp;gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;* 3bea521 - ✨ Add Rust icon on about page (&lt;/span&gt;&lt;span&gt;5&lt;/span&gt;&lt;span&gt; days&lt;/span&gt;&lt;span&gt; ago&lt;/span&gt;&lt;span&gt;) &amp;lt;Anshul Raj Verma&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2&gt;Python&lt;/h2&gt;
&lt;h3&gt;Remove All Cache File Specify to a Python Project&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;function&lt;/span&gt;&lt;span&gt; pycls&lt;/span&gt;&lt;span&gt;() {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    find&lt;/span&gt;&lt;span&gt; .&lt;/span&gt;&lt;span&gt; -name&lt;/span&gt;&lt;span&gt; &apos;.DS_Store&apos;&lt;/span&gt;&lt;span&gt; -type&lt;/span&gt;&lt;span&gt; f&lt;/span&gt;&lt;span&gt; -delete&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    find&lt;/span&gt;&lt;span&gt; .&lt;/span&gt;&lt;span&gt; -type&lt;/span&gt;&lt;span&gt; d&lt;/span&gt;&lt;span&gt; -name&lt;/span&gt;&lt;span&gt; &quot;__pycache__&quot;&lt;/span&gt;&lt;span&gt; -exec&lt;/span&gt;&lt;span&gt; rm&lt;/span&gt;&lt;span&gt; -rfv&lt;/span&gt;&lt;span&gt; {}&lt;/span&gt;&lt;span&gt; \;&lt;/span&gt;&lt;span&gt; 2&amp;gt;&lt;/span&gt;&lt;span&gt;/dev/null&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    find&lt;/span&gt;&lt;span&gt; .&lt;/span&gt;&lt;span&gt; -type&lt;/span&gt;&lt;span&gt; d&lt;/span&gt;&lt;span&gt; -name&lt;/span&gt;&lt;span&gt; &quot;.ipynb_checkpoints&quot;&lt;/span&gt;&lt;span&gt; -exec&lt;/span&gt;&lt;span&gt; rm&lt;/span&gt;&lt;span&gt; -rfv&lt;/span&gt;&lt;span&gt; {}&lt;/span&gt;&lt;span&gt; \;&lt;/span&gt;&lt;span&gt; 2&amp;gt;&lt;/span&gt;&lt;span&gt;/dev/null&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    find&lt;/span&gt;&lt;span&gt; .&lt;/span&gt;&lt;span&gt; -type&lt;/span&gt;&lt;span&gt; d&lt;/span&gt;&lt;span&gt; -name&lt;/span&gt;&lt;span&gt; &quot;.ruff_cache&quot;&lt;/span&gt;&lt;span&gt; -exec&lt;/span&gt;&lt;span&gt; rm&lt;/span&gt;&lt;span&gt; -rfv&lt;/span&gt;&lt;span&gt; {}&lt;/span&gt;&lt;span&gt; \;&lt;/span&gt;&lt;span&gt; 2&amp;gt;&lt;/span&gt;&lt;span&gt;/dev/null&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    find&lt;/span&gt;&lt;span&gt; .&lt;/span&gt;&lt;span&gt; -type&lt;/span&gt;&lt;span&gt; f&lt;/span&gt;&lt;span&gt; -name&lt;/span&gt;&lt;span&gt; &quot;*.pyc&quot;&lt;/span&gt;&lt;span&gt; -exec&lt;/span&gt;&lt;span&gt; rm&lt;/span&gt;&lt;span&gt; -fv&lt;/span&gt;&lt;span&gt; {}&lt;/span&gt;&lt;span&gt; \;&lt;/span&gt;&lt;span&gt; 2&amp;gt;&lt;/span&gt;&lt;span&gt;/dev/null&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; pwd&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;/User/Home&lt;/span&gt;&lt;span&gt;  # For MacOS&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; pycls&lt;/span&gt;&lt;span&gt;  # Remove all cache files and folders in the directory and sub-dirs&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2&gt;Homebrew&lt;/h2&gt;
&lt;h3&gt;Update, Clean, and Doctor&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;brew&lt;/span&gt;&lt;span&gt; update&lt;/span&gt;&lt;span&gt; &amp;amp;&amp;amp; &lt;/span&gt;&lt;span&gt;brew&lt;/span&gt;&lt;span&gt; cleanup&lt;/span&gt;&lt;span&gt; --prune=all&lt;/span&gt;&lt;span&gt; &amp;amp;&amp;amp; &lt;/span&gt;&lt;span&gt;brew&lt;/span&gt;&lt;span&gt; doctor&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Uninstall Unused Dependencies&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;brew&lt;/span&gt;&lt;span&gt; autoremove&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;Check &lt;a href=&quot;https://docs.brew.sh/Manpage#autoremove---dry-run&quot;&gt;docs&lt;/a&gt; for &lt;code&gt;autoremove&lt;/code&gt; command.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Arc&lt;/h2&gt;
&lt;h3&gt;Change &lt;code&gt;ARC.app&lt;/code&gt; Icon&lt;/h3&gt;
&lt;p&gt;&lt;img src=&quot;https://gist.github.com/assets/7717888/fdfbbb6f-ba07-46b9-bdbf-6ef43009479b&quot; alt=&quot;arc logos&quot; /&gt;
&lt;a href=&quot;https://gist.github.com/gabe565/9654eea08a9f6c7c1f593049e5bed243&quot;&gt;Source Gist&lt;/a&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;defaults&lt;/span&gt;&lt;span&gt; write&lt;/span&gt;&lt;span&gt; company.thebrowser.Browser&lt;/span&gt;&lt;span&gt; currentAppIconName&lt;/span&gt;&lt;span&gt; candy&lt;/span&gt;&lt;span&gt; # favorite&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Candy Arc&lt;/th&gt;
&lt;th&gt;Hologram&lt;/th&gt;
&lt;th&gt;Neon&lt;/th&gt;
&lt;th&gt;Fluted Glass&lt;/th&gt;
&lt;th&gt;Schoolbook&lt;/th&gt;
&lt;th&gt;Colorful&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;&lt;code&gt;candy&lt;/code&gt;&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;&lt;code&gt;hologram&lt;/code&gt;&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;&lt;code&gt;neon&lt;/code&gt;&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;&lt;code&gt;flutedGlass&lt;/code&gt;&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;&lt;code&gt;schoolbook&lt;/code&gt;&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;&lt;code&gt;colorful&lt;/code&gt;&lt;/strong&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
</content:encoded><category>blog</category><category>bash</category><category>tips</category><author>Anshul Raj Verma</author></item><item><title>Friends on Website</title><link>https://arv-anshul.github.io/blog/2024/friends-on-website</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/friends-on-website</guid><description>Dedicate a page on website for your friends.</description><pubDate>Mon, 08 Apr 2024 11:02:00 GMT</pubDate><content:encoded>&lt;p&gt;I decided to create a page where I put my friends information like their name, description, and social links which helps
others (who visit my website) to connect with them.&lt;/p&gt;
&lt;h2&gt;Planning&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Define a JSON schema for &lt;code&gt;friends.yaml&lt;/code&gt; file. See the
&lt;a href=&quot;https://github.com/arv-anshul/arv-anshul.github.io/tree/main/schemas/friends-schema.json&quot;&gt;json-schema&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Use builtin &lt;a href=&quot;https://squidfunk.github.io/mkdocs-material/reference/grids/&quot;&gt;&lt;strong&gt;Grids&lt;/strong&gt;&lt;/a&gt; to showcase the friend&apos;s
information. See some experimental &lt;a href=&quot;#layouts&quot;&gt;layouts&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Friends&apos; description must be between 50-70 words. If they fail to maintain them &lt;strong&gt;then use ChatGPT to reduce the
size&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;How Do each Friend&apos;s Section Looks?&lt;/h3&gt;
&lt;p&gt;More certainly they look similar to one another because the web pages is being gets rendered from a &lt;code&gt;yaml&lt;/code&gt; file to
maintain the certainty.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!question] Why render from &lt;code&gt;yaml&lt;/code&gt; format?&lt;/p&gt;
&lt;p&gt;Because I am going to define a schema for that which follows a certain format and using that format the webpage is
being rendered using &lt;a href=&quot;https://pypi.org/project/mkdocs-markdownextradata-plugin/&quot;&gt;&lt;code&gt;mkdocs-markdownextradata-plugin&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;How to Add Friends?&lt;/h3&gt;
&lt;p&gt;I can manually asks their infos and add into yaml files.&lt;/p&gt;
&lt;p&gt;I can open a discussion where my friends provide their infos and request me to add them on
the web page.&lt;/p&gt;
&lt;p&gt;My friends can open a PULL REQUEST into the repo which will automatically add them on webpage.&lt;/p&gt;
&lt;h2&gt;Layouts&lt;/h2&gt;
&lt;p&gt;These are my rough ideas which I prefer to replicate on my website&apos;s page to display the friends&apos; information.&lt;/p&gt;
&lt;p&gt;&amp;lt;!-- rumdl-disable MD005 MD033 MD035 MD007 MD013 --&amp;gt;&lt;/p&gt;
&lt;h3&gt;:material-numeric-1-box:{ .lg } Layout 1&lt;/h3&gt;
&lt;p&gt;&amp;lt;div class=&quot;grid cards&quot; markdown&amp;gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io/about&quot;&gt;&lt;img src=&quot;https://avatars.githubusercontent.com/u/111767754?v=4&quot; alt=&quot;avatar&quot; /&gt;{ .twemoji .xxl .middle .round }&lt;/a&gt;   &lt;strong&gt;Anshul Raj Verma&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=justify&amp;gt;
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Tempus urna et pharetra pharetra massa massa ultricies mi. Adipiscing enim eu turpis egestas. Pretium fusce id velit ut tortor pretium viverra suspendisse potenti. Egestas egestas fringilla phasellus faucibus scelerisque eleifend. Sapien pellentesque habitant morbi tristique senectus et. Dignissim cras tincidunt lobortis feugiat vivamus at augue eget.
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=center&amp;gt;
[:simple-github:{ .lg }](https://linkedin.com/in/arv-anshul) &amp;amp;nbsp;
[:simple-linkedin:{ .lg }](https://github.com/arv-anshul) &amp;amp;nbsp;
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;div class=&quot;grid cards&quot; markdown&amp;gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&amp;lt;p align=center&amp;gt;&lt;a href=&quot;https://arv-anshul.github.io/about&quot;&gt;&lt;img src=&quot;https://avatars.githubusercontent.com/u/111767754?v=4&quot; alt=&quot;avatar&quot; /&gt;{ .twemoji .xxl .middle .round }&lt;/a&gt;   &lt;strong&gt;Anshul Raj Verma&lt;/strong&gt;&amp;lt;/p&amp;gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=justify&amp;gt;
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Tempus urna et pharetra pharetra massa massa ultricies mi. Adipiscing enim eu turpis egestas. Pretium fusce id velit ut tortor pretium viverra suspendisse potenti. Egestas egestas fringilla phasellus faucibus scelerisque eleifend. Sapien pellentesque habitant morbi tristique senectus et. Dignissim cras tincidunt lobortis feugiat vivamus at augue eget.
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=center&amp;gt;
[:simple-github:{ .lg }](https://linkedin.com/in/arv-anshul) &amp;amp;nbsp;
[:simple-linkedin:{ .lg }](https://github.com/arv-anshul) &amp;amp;nbsp;
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
&lt;h3&gt;:material-numeric-2-box:{ .lg } Layout 2&lt;/h3&gt;
&lt;p&gt;&amp;lt;div class=&quot;grid cards&quot; markdown&amp;gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io/about&quot;&gt;&lt;img src=&quot;https://avatars.githubusercontent.com/u/111767754?v=4&quot; alt=&quot;avatar&quot; /&gt;{ .twemoji .xxl .middle .round }&lt;/a&gt;   &lt;strong&gt;Anshul Raj Verma&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=justify&amp;gt;
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Tempus urna et pharetra pharetra massa massa ultricies mi. Adipiscing enim eu turpis egestas. Pretium fusce id velit ut tortor pretium viverra suspendisse potenti. Egestas egestas fringilla phasellus faucibus scelerisque eleifend. Sapien pellentesque habitant morbi tristique senectus et. Dignissim cras tincidunt lobortis feugiat vivamus at augue eget.
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=center&amp;gt;
[:simple-github:{ .lg }](https://linkedin.com/in/arv-anshul) &amp;amp;nbsp;
[:simple-linkedin:{ .lg }](https://github.com/arv-anshul) &amp;amp;nbsp;
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;&amp;lt;p align=center&amp;gt;&lt;a href=&quot;https://arv-anshul.github.io/about&quot;&gt;&lt;img src=&quot;https://avatars.githubusercontent.com/u/111767754?v=4&quot; alt=&quot;avatar&quot; /&gt;{ .twemoji .xxl .middle .round }&lt;/a&gt;   &lt;strong&gt;Anshul Raj Verma&lt;/strong&gt;&amp;lt;/p&amp;gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=justify&amp;gt;
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Tempus urna et pharetra pharetra massa massa ultricies mi. Adipiscing enim eu turpis egestas. Pretium fusce id velit ut tortor pretium viverra suspendisse potenti. Egestas egestas fringilla phasellus faucibus scelerisque eleifend. Sapien pellentesque habitant morbi tristique senectus et. Dignissim cras tincidunt lobortis feugiat vivamus at augue eget.
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=center&amp;gt;
[:simple-github:{ .lg }](https://linkedin.com/in/arv-anshul) &amp;amp;nbsp;
[:simple-linkedin:{ .lg }](https://github.com/arv-anshul) &amp;amp;nbsp;
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
&lt;h3&gt;:material-numeric-3-box:{ .lg } Layout 3&lt;/h3&gt;
&lt;p&gt;&amp;lt;div class=&quot;grid cards&quot; markdown&amp;gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&amp;lt;p align=center&amp;gt;&lt;a href=&quot;https://arv-anshul.github.io/about&quot;&gt;&lt;img src=&quot;https://avatars.githubusercontent.com/u/111767754?v=4&quot; alt=&quot;avatar&quot; /&gt;{ .twemoji .xxxl .round }&lt;/a&gt;&amp;lt;/p&amp;gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;p align=center&amp;gt;&lt;strong&gt;Anshul Raj Verma&lt;/strong&gt;&amp;lt;/p&amp;gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;p align=center&amp;gt;
&lt;a href=&quot;https://linkedin.com/in/arv-anshul&quot;&gt;:simple-github:{ .lg }&lt;/a&gt;  
&lt;a href=&quot;https://github.com/arv-anshul&quot;&gt;:simple-linkedin:{ .lg }&lt;/a&gt;  
&amp;lt;/p&amp;gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=justify&amp;gt;
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Tempus urna et pharetra pharetra massa massa ultricies mi. Adipiscing enim eu turpis egestas. Pretium fusce id velit ut tortor pretium viverra suspendisse potenti. Egestas egestas fringilla phasellus faucibus scelerisque eleifend. Sapien pellentesque habitant morbi tristique senectus et. Dignissim cras tincidunt lobortis feugiat vivamus at augue eget.
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&amp;lt;p align=center&amp;gt;&lt;a href=&quot;https://arv-anshul.github.io/about&quot;&gt;&lt;img src=&quot;https://avatars.githubusercontent.com/u/111767754?v=4&quot; alt=&quot;avatar&quot; /&gt;{ .twemoji .xxxl .round }&lt;/a&gt;&amp;lt;/p&amp;gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;p align=center&amp;gt;&lt;strong&gt;Anshul Raj Verma&lt;/strong&gt;&amp;lt;/p&amp;gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=center&amp;gt;
[:simple-github:{ .lg }](https://linkedin.com/in/arv-anshul) &amp;amp;nbsp;
[:simple-linkedin:{ .lg }](https://github.com/arv-anshul) &amp;amp;nbsp;
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=justify&amp;gt;
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Tempus urna et pharetra pharetra massa massa ultricies mi. Adipiscing enim eu turpis egestas. Pretium fusce id velit ut tortor pretium viverra suspendisse potenti. Egestas egestas fringilla phasellus faucibus scelerisque eleifend. Sapien pellentesque habitant morbi tristique senectus et. Dignissim cras tincidunt lobortis feugiat vivamus at augue eget.
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&amp;lt;p align=center&amp;gt;&lt;a href=&quot;https://arv-anshul.github.io/about&quot;&gt;&lt;img src=&quot;https://avatars.githubusercontent.com/u/111767754?v=4&quot; alt=&quot;avatar&quot; /&gt;{ .twemoji .xxxl .round }&lt;/a&gt;&amp;lt;/p&amp;gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;p align=center&amp;gt;&lt;strong&gt;Anshul Raj Verma&lt;/strong&gt;&amp;lt;/p&amp;gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;p align=justify&amp;gt;
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Tempus urna et pharetra pharetra massa massa ultricies mi. Adipiscing enim eu turpis egestas. Pretium fusce id velit ut tortor pretium viverra suspendisse potenti. Egestas egestas fringilla phasellus faucibus scelerisque eleifend. Sapien pellentesque habitant morbi tristique senectus et. Dignissim cras tincidunt lobortis feugiat vivamus at augue eget.
&amp;lt;/p&amp;gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;p align=center&amp;gt;
[:simple-github:{ .lg }](https://linkedin.com/in/arv-anshul) &amp;amp;nbsp;
[:simple-linkedin:{ .lg }](https://github.com/arv-anshul) &amp;amp;nbsp;
&amp;lt;/p&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;/div&amp;gt;&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>friends</category><category>website</category><category>person</category><author>Anshul Raj Verma</author></item><item><title>Bash Tips</title><link>https://arv-anshul.github.io/blog/2024/bash-tips</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/bash-tips</guid><description>Some terminal or bash tricks you may find useful for your workflow.</description><pubDate>Sun, 07 Apr 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;This page contains some Tips and Tricks which are helpful to work with Bash scripts or Terminals. I have mentioned only
those tips and tricks which I uses most in my daily routine, BTW you can refer to links which I have shared to know all
the tips and tricks.&lt;/p&gt;
&lt;h2&gt;Tips By &lt;code&gt;asottile&lt;/code&gt;&lt;/h2&gt;
&lt;p&gt;I will only mention those commands and shortcuts which helpful for me. You can check all of them using below links.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=_wcVyhfyaeE&quot;&gt;Protips - YouTube Video&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/asottile/scratch/wiki/protips&quot;&gt;Protips - Github Wiki Link&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Command: &lt;code&gt;!!&lt;/code&gt;&lt;/h3&gt;
&lt;p&gt;A substitution which contains the previous command, some useful invocations.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; ls&lt;/span&gt;&lt;span&gt; /proc/1/exe&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;ls:&lt;/span&gt;&lt;span&gt; cannot&lt;/span&gt;&lt;span&gt; access&lt;/span&gt;&lt;span&gt; &apos;/proc/1/exe&apos;:&lt;/span&gt;&lt;span&gt; Permission&lt;/span&gt;&lt;span&gt; denied&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; sudo&lt;/span&gt;&lt;span&gt; !!&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;sudo&lt;/span&gt;&lt;span&gt; ls&lt;/span&gt;&lt;span&gt; /proc/1/exe&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;/proc/1/exe&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; ls&lt;/span&gt;&lt;span&gt; /tmp/&lt;/span&gt;&lt;span&gt; | &lt;/span&gt;&lt;span&gt;grep&lt;/span&gt;&lt;span&gt; sys&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;systemd-private-e21be514f23449189063b6bd95ec13ef-bolt.service-MCMIaN&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;systemd-private-e21be514f23449189063b6bd95ec13ef-colord.service-yNWr06&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;systemd-private-e21be514f23449189063b6bd95ec13ef-fwupd.service-geozA1&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; watch&lt;/span&gt;&lt;span&gt; &quot;!!&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;watch&lt;/span&gt;&lt;span&gt; &quot;ls /tmp/ | grep sys&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;opens&lt;/span&gt;&lt;span&gt; up&lt;/span&gt;&lt;span&gt; watch&lt;/span&gt;&lt;span&gt; panel&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Command: &lt;code&gt;!$&lt;/code&gt;&lt;/h3&gt;
&lt;p&gt;A substitution which contains the last segment of the previous command.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; $EDITOR&lt;/span&gt;&lt;span&gt; test.py&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; python&lt;/span&gt;&lt;span&gt; !&lt;/span&gt;&lt;span&gt;$&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;python&lt;/span&gt;&lt;span&gt; test.py&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Hello&lt;/span&gt;&lt;span&gt; world!&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;mkdir&lt;/span&gt;&lt;span&gt; new-project&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;code&lt;/span&gt;&lt;span&gt; !&lt;/span&gt;&lt;span&gt;$  &lt;/span&gt;&lt;span&gt;# Opens the `new-project folder in VSCode&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Shortcut: &amp;lt;kbd&amp;gt;ctrl&amp;lt;/kbd&amp;gt; + &amp;lt;kbd&amp;gt;\&amp;lt;/Kbd&amp;gt;&lt;/h3&gt;
&lt;p&gt;&amp;lt;kbd&amp;gt;ctrl&amp;lt;/kbd&amp;gt; + &amp;lt;kbd&amp;gt;\&amp;lt;/kbd&amp;gt; sends &lt;code&gt;SIGQUIT&lt;/code&gt; (&lt;strong&gt;default behavior:&lt;/strong&gt; terminate + produce a core dump) which can be
useful to kill things that normally catch &amp;lt;kbd&amp;gt;ctrl&amp;lt;/kbd&amp;gt; + &amp;lt;kbd&amp;gt;c&amp;lt;/kbd&amp;gt; (&lt;code&gt;SIGINT&lt;/code&gt;).&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;:fire: &amp;lt;kbd&amp;gt;ctrl&amp;lt;/kbd&amp;gt; + &amp;lt;kbd&amp;gt;\&amp;lt;/kbd&amp;gt; is more powerful than &amp;lt;kbd&amp;gt;ctrl&amp;lt;/kbd&amp;gt; + &amp;lt;kbd&amp;gt;c&amp;lt;/kbd&amp;gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Additional Tricks&lt;/h2&gt;
&lt;h3&gt;Trick: &lt;code&gt;cmd `!!`&lt;/code&gt;&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Run previous command with new command.&lt;/li&gt;
&lt;li&gt;Replace previous command with &lt;code&gt;`!!`&lt;/code&gt; argument.&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; brew&lt;/span&gt;&lt;span&gt; --prefix&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;/opt/homebrew&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;$&lt;/span&gt;&lt;span&gt; open&lt;/span&gt;&lt;span&gt; `&lt;/span&gt;&lt;span&gt;!!&lt;/span&gt;&lt;span&gt;`&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;open&lt;/span&gt;&lt;span&gt; `&lt;/span&gt;&lt;span&gt;brew&lt;/span&gt;&lt;span&gt; --prefix&lt;/span&gt;&lt;span&gt;`&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Now Finder.app opens at &quot;/opt/homebrew&quot; path&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Uninstall Apps from Mac&lt;/h3&gt;
&lt;p&gt;Uninstall and remove all app data from your Mac using
&lt;a href=&quot;https://github.com/sunknudsen/privacy-guides/raw/master/how-to-clean-uninstall-macos-apps-using-appcleaner-open-source-alternative/app-cleaner.sh&quot;&gt;this script&lt;/a&gt;.
For more information &lt;a href=&quot;https://youtu.be/0nVOB0EE5ps&quot;&gt;see this&lt;/a&gt; youtube video.&lt;/p&gt;
&lt;h3&gt;Remove Mac&apos;s &quot;Login Items&quot;&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;Go to &lt;code&gt;/Library/LaunchAgents&lt;/code&gt; and &lt;code&gt;/Library/LaunchDaemons&lt;/code&gt; path.&lt;/li&gt;
&lt;li&gt;Check for the login item names and delete them.&lt;/li&gt;
&lt;li&gt;This process might asks for password.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>blog</category><category>bash</category><category>tips</category><author>Anshul Raj Verma</author></item><item><title>Hey Wcowin</title><link>https://arv-anshul.github.io/blog/2024/hey-wcowin</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/hey-wcowin</guid><description>An interesting with even more thoughts than me which are documented as well.</description><pubDate>Fri, 05 Apr 2024 16:23:00 GMT</pubDate><content:encoded>&lt;p&gt;I had opened a &lt;a href=&quot;https://github.com/squidfunk/mkdocs-material/discussions/6974&quot;&gt;discussion&lt;/a&gt; in &lt;a href=&quot;https://github.com/squidfunk/mkdocs-material&quot;&gt;mkdocs-material&lt;/a&gt; GitHub repo and tomorrow and &lt;a href=&quot;https://github.com/Wcowin&quot;&gt;@Wcowin&lt;/a&gt; wrote a comment on that
&lt;a href=&quot;https://github.com/squidfunk/mkdocs-material/discussions/6974&quot;&gt;discussion&lt;/a&gt; and I replied him generously. After my reply &lt;strong&gt;he followed me&lt;/strong&gt; and this makes me curious; &lt;strong&gt;&quot;Why/How any
random guy can follow me?&quot;&lt;/strong&gt; Because I can&apos;t do this to anybody.&lt;/p&gt;
&lt;p&gt;Then, I started exploring his GitHub account and visited his &lt;a href=&quot;https://wcowin.work&quot;&gt;personal website&lt;/a&gt; and that website is just wonderful place
because that &lt;strong&gt;palace&lt;/strong&gt; contains tons of thoughts :star_struck: of him.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!NOTE] Wonderful&lt;/p&gt;
&lt;p&gt;How can a person write ^^these types of thoughts in his diary/journal and made it public (I am not hateful, just
surprised :exploding_head:), because I also get similar thought but can&apos;t able to maintain it like this. &quot;Just
wonderful :people_hugging:&quot;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://wcowin.work/relax/wkwMath/5.html#3&quot;&gt;Link to page&lt;/a&gt; I don&apos;t know is he really thought this or just copied
from somewhere.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://wcowin.work/relax/Movie/tuijianfanju.html#_20&quot;&gt;Link to page&lt;/a&gt; He maintain his experiences of watching
Dramas, Movies and TV Shows :nerd_face:.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://wcowin.work/relax/Essay/zhonggao.html&quot;&gt;Link to page&lt;/a&gt; &lt;strong&gt;WTF&lt;/strong&gt; &lt;em&gt;(Why The Fuck?)&lt;/em&gt; are these in public
:face_with_peeking_eye:.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://wcowin.work/about/run.html&quot;&gt;Link to page&lt;/a&gt; I haven&apos;t read this page bu it seems good; I am going to read
this page soon.&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;p&gt;I am thankful that I met you and thankful to you that you shared your thoughts like this and I&apos;m able to read it (after
translation). I am thankful to you that you met me and also looking forward to your next thoughts.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Meet you at your next thought.&lt;/strong&gt;&lt;/p&gt;
&lt;h2&gt;On 1st May, 2024&lt;/h2&gt;
&lt;p&gt;I am searching his &lt;a href=&quot;https://wcowin.work/about/link.html&quot;&gt;Friends page&lt;/a&gt; on his website (but navigating with Chinese language) but into his
&lt;a href=&quot;https://wcowin.work/blog/2024/01/01/2024%E7%BD%91%E7%AB%99%E6%9B%B4%E6%96%B0%E8%AE%B0%E5%BD%95.html#2024-04-06&quot;&gt;Blog page&lt;/a&gt; and after scrolling a bit &lt;strong&gt;I read my name (Anshul Raj Verma)&lt;/strong&gt; because others words were written in
Chinese which got my focus to my name. After sudden realization I copied the sentence and pasted it on
&lt;a href=&quot;https://translate.google.com/?sl=zh-CN&amp;amp;tl=en&amp;amp;text=%E6%84%9F%E8%B0%A2Anshul+Raj+Verma%E5%9C%A8Discussions%237%E4%B8%8A%E6%8F%90%E5%87%BA%E7%9A%84%E7%BD%91%E7%AB%99%E4%BC%98%E5%8C%96%E5%BB%BA%E8%AE%AE&amp;amp;op=translate&quot;&gt;Google Translate&lt;/a&gt; and came to know that he wrote:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!IMPORTANT] Translation&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;In Chinese&lt;/strong&gt;: 感谢Anshul Raj Verma在Discussions#7上提出的网站优化建议&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;In Hindi&lt;/strong&gt;: चर्चा#7 में वेबसाइट अनुकूलन सुझावों के लिए अंशुल राज वर्मा को धन्यवाद&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;In English&lt;/strong&gt;: Thanks to [Anshul Raj Verma] for his website optimization suggestions in [Discussions#7]&lt;/p&gt;
&lt;/blockquote&gt;
</content:encoded><category>blog</category><category>person</category><category>friends</category><category>thoughts</category><author>Anshul Raj Verma</author></item><item><title>The Rust Language</title><link>https://arv-anshul.github.io/blog/2024/rust-lang</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/rust-lang</guid><description>Learning my dream language &quot;The Rust Language&quot;.</description><pubDate>Tue, 02 Apr 2024 22:41:00 GMT</pubDate><content:encoded>&lt;p&gt;Finally, learning my &lt;s&gt;dream language&lt;/s&gt; &lt;em&gt;(after using some top-notch projects written in it)&lt;/em&gt; &lt;strong&gt;Rust&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Created new &lt;a href=&quot;https://github.com/arv-anshul/thrust&quot;&gt;arv-anshul/thrust&lt;/a&gt; GitHub repo which contains my learning resources
and my practice progams. I have written some thoughts in the repo&apos;s
&lt;a href=&quot;https://github.com/arv-anshul/thrust#readme&quot;&gt;&lt;code&gt;README.md&lt;/code&gt;&lt;/a&gt; file.&lt;/p&gt;
&lt;h2&gt;Thoughts&lt;/h2&gt;
&lt;h3&gt;The Dream Language - Nightmare&lt;/h3&gt;
&lt;p&gt;Before learning Rust I imagine that this is my &lt;strong&gt;Dream Language&lt;/strong&gt; &lt;em&gt;for sure&lt;/em&gt; but after digging into it I regret. Why I
started learning this. Because this is ***king hard too learn if you compare to Python (After this I think python has
reduced the complexities to 50-60% :pray:).&lt;/p&gt;
&lt;h3&gt;The Learning Curve&lt;/h3&gt;
&lt;p&gt;My first language is &lt;strong&gt;Python&lt;/strong&gt; and it very to learn because there is no concept of
&lt;a href=&quot;https://doc.rust-lang.org/book/ch04-00-understanding-ownership.html&quot;&gt;Ownership&lt;/a&gt; and 69+ different data-types; just
write your code and run it. But in Rust the compiler says &lt;em&gt;aise kaise&lt;/em&gt;.&lt;/p&gt;
&lt;h3&gt;The Rust Compiler&lt;/h3&gt;
&lt;p&gt;Mera koti-koti naman unko jo iis compiler (&lt;code&gt;rustc&lt;/code&gt;) ka chintan kiye aur ise itna safal banaya. Matlab &lt;code&gt;rustc&lt;/code&gt; ko sab
pata hai ki aap kisko kya de rhe ho, kaise de rhe ho, sab kuch; inse kuch nhi chhipa hai. Agar kuch bhi idhar-udhar hua,
turant tok denga.&lt;/p&gt;
&lt;h3&gt;Irritation&lt;/h3&gt;
&lt;p&gt;In the beginning, while creating programs or project it feels irritating; you have no idea how to do it there is so much
constraints to care about. &lt;em&gt;Sometimes I feels that I can build this in Python and that is enough for me. :angry:.&lt;/em&gt;&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>programming</category><author>Anshul Raj Verma</author></item><item><title>April Journal</title><link>https://arv-anshul.github.io/journal/2024/04</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/04</guid><description>Weekly Journal by ARV of April 2024</description><pubDate>Mon, 01 Apr 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 14 Journal&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://rust-lang.org&quot;&gt;Rust&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;Learning Rust from YouTube and Rust Books.&lt;/li&gt;
&lt;li&gt;Created &lt;a href=&quot;https://github.com/arv-anshul/thrust&quot;&gt;arv-anshul/thrust&lt;/a&gt; repo where I practice Rust by creating programs.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;End of Week:&lt;/strong&gt; I decided to leave Rust behind and starts focusing on ML and DL. :wink:&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://rust-lang.org&quot;&gt;Rust&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;:tada: Finally, finally, finally.&lt;/li&gt;
&lt;li&gt;Read &lt;a href=&quot;/blog/rust-lang&quot;&gt;my thoughts on rust&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://learnwith.campusx.in/s/store&quot;&gt;CampusX - Short Courses&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;Just great to know that Nitish Sir is launching approx. 10 New Short Courses where other teachers will teaches some
concepts in deep and also build projects using those concepts.&lt;/li&gt;
&lt;li&gt;Also, these short courses is free and for lifetime.&lt;/li&gt;
&lt;li&gt;I think it&apos;s just like short courses by &lt;a href=&quot;https://deeplearning.ai/short-courses&quot;&gt;Deeplearning.ai&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;/blog/hey-wcowin&quot;&gt;hey-wcowin.md&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;I met &lt;a href=&quot;https://github.com/Wcowin&quot;&gt;@Wcowin&lt;/a&gt; and written something about him.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 15 Journal&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://www.mkdocs.org/user-guide/configuration/#nav&quot;&gt;mkdocs - &lt;code&gt;nav&lt;/code&gt;&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;Create multiple references of same notes in &lt;code&gt;mkdocs.yaml&lt;/code&gt;&apos;s &lt;code&gt;nav&lt;/code&gt; field and then it gets render as it is written.
Checkout the &lt;a href=&quot;https://www.mkdocs.org/user-guide/configuration/#nav&quot;&gt;official documentation&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Also checkout website&apos;s &lt;a href=&quot;https://github.com/arv-anshul/arv-anshul.github.io/tree/main/mkdocs.yaml&quot;&gt;&lt;code&gt;mkdocs.yaml&lt;/code&gt;&lt;/a&gt;
file&apos;s &lt;code&gt;nav&lt;/code&gt; field.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io/friends&quot;&gt;Anshul Raj Verma - Friends&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;Created a Friends page on website using where I&apos;ll put my friends info.&lt;/li&gt;
&lt;li&gt;The info were rendered from
&lt;a href=&quot;https://github.com/arv-anshul/arv-anshul.github.io/tree/main/docs/data/render_yaml/friends.yaml&quot;&gt;&lt;code&gt;yaml&lt;/code&gt;&lt;/a&gt; file
using &lt;a href=&quot;https://pypi.org/p/mkdocs-markdownextradata-plugin&quot;&gt;&lt;code&gt;mkdocs-markdownextradata-plugin&lt;/code&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;code&gt;mkdocs-edges&lt;/code&gt;
&lt;ul&gt;
&lt;li&gt;Planning to write a &lt;code&gt;plugin&lt;/code&gt; for &lt;code&gt;mkdocs&lt;/code&gt; using which users are able to customize their sites layout (rounded
edges).&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=OR24M5ns-YY&quot;&gt;Fresher Getting 17 LPA Data Scientist Job From Tier 3 College | Story of Tarun Chauhan&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;Connect with Tarun on &lt;a href=&quot;https://linkedin.com/in/tarun-chauhan-719a9b221&quot;&gt;LinkedIn&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;After watching this video; I have to make better notes from CampusX videos which helps me to remember those
concepts workings and theory.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 16 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://gist.github.com/gabe565/9654eea08a9f6c7c1f593049e5bed243&quot;&gt;Change ARC Browser Icon - GitHub Gist&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://arv-anshul.github.io/blog/basics-of-statistics&quot;&gt;Basics of Statistics for ML&lt;/a&gt;: New blog to learn basic
statistics for Machie Learning. Explained Descriptive and Inferential Statistics.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Username Dilemma&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;I am changing my username from (&lt;code&gt;arv-anshul&lt;/code&gt;/&lt;code&gt;arv_anshul&lt;/code&gt;) to (&lt;code&gt;batook&lt;/code&gt;/&lt;code&gt;batookm&lt;/code&gt;) because it is of one word, no
separation (&lt;code&gt;-&lt;/code&gt;/&lt;code&gt;_&lt;/code&gt;) in between.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;I have already changed username of Telegram, Discord and Instagram.&lt;/p&gt;
&lt;p&gt;&amp;lt;figure markdown&amp;gt;&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Platform&lt;/th&gt;
&lt;th&gt;ID&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Discord&lt;/td&gt;
&lt;td&gt;&lt;code&gt;batookm&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;a href=&quot;https://t.me/batookm&quot;&gt;Telegram&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;batookm&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;a href=&quot;https://instagram.com/_batookm&quot;&gt;Instagram&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_batookm&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&amp;lt;/figure&amp;gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;s&gt;:thinking: Thinking to change GitHub username too but that is too overwhelming.&lt;/s&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;I am not going to change GitHub and LinkedIn username because &lt;code&gt;arv-anshul&lt;/code&gt; is my professional username and &lt;code&gt;batook&lt;/code&gt;
is my nick-username. If I made my X &lt;em&gt;(formally Twitter)&lt;/em&gt; then I&apos;ll keep my username as &lt;strong&gt;&lt;code&gt;batook&lt;/code&gt;&lt;/strong&gt; :sunglasses:.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://freeapi.app&quot;&gt;freeapi.app&lt;/a&gt; - By Hitesh Choudhary :sunglasses:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;I am thinking to recreate this in Python using &lt;strong&gt;FastAPI&lt;/strong&gt; as &lt;code&gt;freeapi-py&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;I first need to tackle:
&lt;ul&gt;
&lt;li&gt;How to handle &lt;code&gt;limit&lt;/code&gt; query?&lt;/li&gt;
&lt;li&gt;How to use MongoDB from localhost and Docker?&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://github.com/astral-sh/ruff/releases/v0.4.0&quot;&gt;ruff/server&lt;/a&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Yet another banger from &lt;strong&gt;Astral devs&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Read blog on &lt;a href=&quot;https://astral.sh/blog/ruff-v0.4.0&quot;&gt;&lt;code&gt;ruff server&lt;/code&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Me and Rahul Bhaiya are started working on that &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history&quot;&gt;yt-watch-history&lt;/a&gt; project &lt;strong&gt;but from scratch&lt;/strong&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Write about &quot;How to introduce yourself?&quot;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Maintain a page where you write your achievement also express your thoughts on them.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 17 Journal&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Discuss lots of questions with @Rahul-Kumar30.&lt;/li&gt;
&lt;li&gt;Learned &lt;strong&gt;Confusion Matrix&lt;/strong&gt; from &lt;strong&gt;Credit Risk Modeling&lt;/strong&gt; Course.&lt;/li&gt;
&lt;li&gt;Did &lt;strong&gt;Credit Risk Modeling&lt;/strong&gt; project with @SMBHV.&lt;/li&gt;
&lt;li&gt;Created a new Journal page &lt;a href=&quot;https://arv-anshul.github.io/anime&quot;&gt;&lt;code&gt;anime.md&lt;/code&gt;&lt;/a&gt; where I put
my experiences of watching anime.&lt;/li&gt;
&lt;li&gt;Updated the convention of Journal. &lt;a href=&quot;/blog/journal&quot;&gt;See&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/somtoval&quot;&gt;SOMTO&lt;/a&gt; gave his information to add it on website&apos;s
&lt;a href=&quot;https://arv-anshul.github.io/friends&quot;&gt;friends page&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Binam asked for roadmap of Data Science.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>april</category><author>Anshul Raj Verma</author></item><item><title>Introduction To Hypothesis Testing</title><link>https://arv-anshul.github.io/blog/2024/hypothesis-testing-introduction</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/hypothesis-testing-introduction</guid><description>A basic introduction to Hypothesis Testing.</description><pubDate>Mon, 25 Mar 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Are you a Null Hypothesis or an Alternate Hypothesis? &lt;em&gt;What does this question means?&lt;/em&gt;&lt;/p&gt;
&lt;h2&gt;Null V/S Alternative Hypothesis&lt;/h2&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Parameter&lt;/th&gt;
&lt;th&gt;Null Hypothesis&lt;/th&gt;
&lt;th&gt;Alternative Hypothesis&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Definition&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;A null hypothesis is a statement in which there is no relation between the two variables.&lt;/td&gt;
&lt;td&gt;An alternative hypothesis is a statement in which there is some statistical relationship between the two variables.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;What is it?&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Generally, researchers try to reject or disprove it.&lt;/td&gt;
&lt;td&gt;Researchers try to accept or prove it.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Testing Process&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indirect and Implicit&lt;/td&gt;
&lt;td&gt;Direct and Explicit&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;p-value&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Null hypothesis is rejected if the p-value is less than the alpha-value; otherwise, it is accepted.&lt;/td&gt;
&lt;td&gt;An alternative hypothesis is accepted if the p-value is less than the alpha-value otherwise, it is rejected.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Notation&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;#!math H_0&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;#!math H_1&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Symbol&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Used Equality Symbol &lt;strong&gt;(=, ≥, ≤)&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Inequality Symbol &lt;strong&gt;(≠, &amp;lt;, &amp;gt;)&lt;/strong&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;ul&gt;
&lt;li&gt;Null hypothesis assumes no effect or relationship, while the alternative hypothesis suggests the presence of an effect
or relationship.&lt;/li&gt;
&lt;li&gt;Researchers try to reject or disprove the null hypothesis, whereas they aim to accept or prove the alternative
hypothesis.&lt;/li&gt;
&lt;li&gt;Null hypothesis testing is indirect and implicit, while alternative hypothesis testing is direct and explicit.&lt;/li&gt;
&lt;li&gt;Null hypothesis is represented by H0 with an equal sign, while the alternative hypothesis is denoted by H1 with an
unequal sign.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;:art: Illustrate Hypothesis Testing&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Scenario&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;A researcher believes that a new teaching method improves student performance in mathematics compared to the traditional
method. The average score of students using the new method is expected to be higher than the average score of students
using the traditional method.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Hypotheses&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Null Hypothesis &lt;code&gt;#!math (H_0)&lt;/code&gt;&lt;/strong&gt;: The average score of students using the new teaching method is the same as or lower
than the average score of students using the traditional method
&lt;code&gt;#!math (H_0:\mu_{\text{new}} \le \mu_{\text{traditional}})&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Alternative Hypothesis &lt;code&gt;#!math (H_a)&lt;/code&gt;&lt;/strong&gt;: The average score of students using the new teaching method is higher than
the average score of students using the traditional method &lt;code&gt;#!math (H_a:\mu_{\text{new}} \gt \mu_{\text{traditional}})&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Steps&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Formulate Hypotheses&lt;/strong&gt;: Establish the null and alternative hypotheses.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Collect Data&lt;/strong&gt;: Administer both teaching methods to two groups of students and collect their test scores.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Calculate Test Statistic&lt;/strong&gt;: Compute the test statistic, such as the t-test, based on the sample data.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Compare to Critical Region&lt;/strong&gt;: Compare the test statistic to critical values to determine if it falls in the
critical region.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Calculate p-value&lt;/strong&gt;: Calculate the p-value associated with the test statistic.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Make Conclusion&lt;/strong&gt;: Based on the p-value and significance level, either reject the null hypothesis if the p-value is
less than the significance level or fail to reject it.&lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
&lt;p&gt;In this example, ^^if the p-value is less than the chosen significance level (e.g., 0.05), you would reject the null
hypothesis and conclude that there is evidence to support the claim that the new teaching method leads to higher
student performance in mathematics^^. This demonstrates how hypothesis testing allows researchers to draw conclusions
based on statistical evidence and make informed decisions.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Hypothesis Example (Using ChatGPT)&lt;/h3&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Does a New Drug Reduce Blood Pressure?&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;In this example, we&apos;ll demonstrate hypothesis testing using a hypothetical scenario where a pharmaceutical company has
developed a new drug intended to reduce blood pressure in patients with hypertension. We&apos;ll design and conduct a
hypothesis test to determine whether the new drug is effective in reducing blood pressure compared to a placebo.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Hypotheses Formulation&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Null Hypothesis (H0): The new drug has no effect on reducing blood pressure, and any observed differences are due
to random chance.&lt;/li&gt;
&lt;li&gt;Alternative Hypothesis (Ha): The new drug effectively reduces blood pressure in patients, leading to a significant
difference compared to the placebo.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Data Collection&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;We collect blood pressure measurements from two groups of participants: one receiving the new drug (treatment
group) and the other receiving a placebo (control group).&lt;/li&gt;
&lt;li&gt;Each participant&apos;s blood pressure is measured before and after the treatment period.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Experimental Design&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Randomly assign participants to either the treatment group (receiving the new drug) or the control group (receiving
a placebo).&lt;/li&gt;
&lt;li&gt;Ensure blinding to minimize bias, where neither the participants nor the researchers know who is receiving the drug
or the placebo.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Data Analysis&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Calculate the mean blood pressure reduction for each group.&lt;/li&gt;
&lt;li&gt;Conduct a hypothesis test, such as a two-sample t-test, to compare the mean blood pressure reductions between the
treatment and control groups.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Interpretation of Results&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;If the p-value is less than the chosen significance level (e.g., α = 0.05), we reject the null hypothesis in favor
of the alternative hypothesis.&lt;/li&gt;
&lt;li&gt;A statistically significant result indicates that the new drug has a significant effect on reducing blood pressure
compared to the placebo.&lt;/li&gt;
&lt;li&gt;Conversely, if the p-value is greater than the significance level, we fail to reject the null hypothesis,
suggesting no significant difference between the groups.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Conclusion and Recommendations&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;If the hypothesis test results support the alternative hypothesis, we conclude that the new drug is effective in
reducing blood pressure.&lt;/li&gt;
&lt;li&gt;The pharmaceutical company can proceed with further clinical trials and regulatory approvals for the new drug.&lt;/li&gt;
&lt;li&gt;If the results do not support the alternative hypothesis, the company may need to reevaluate the drug&apos;s efficacy or
explore alternative treatment options.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; numpy &lt;/span&gt;&lt;span&gt;as&lt;/span&gt;&lt;span&gt; np&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; scipy.stats &lt;/span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; ttest_ind&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Simulated blood pressure data&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;treatment_group = np.array([&lt;/span&gt;&lt;span&gt;140&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;135&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;150&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;138&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;132&lt;/span&gt;&lt;span&gt;])  &lt;/span&gt;&lt;span&gt;# Blood pressure reduction after new drug&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;control_group = np.array([&lt;/span&gt;&lt;span&gt;145&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;142&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;148&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;146&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;140&lt;/span&gt;&lt;span&gt;])     &lt;/span&gt;&lt;span&gt;# Blood pressure reduction after placebo&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Perform two-sample t-test&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;t_statistic, p_value = ttest_ind(treatment_group, control_group)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Interpretation of results&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;alpha = &lt;/span&gt;&lt;span&gt;0.05&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;if&lt;/span&gt;&lt;span&gt; p_value &amp;lt; alpha:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    print&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;&quot;The new drug significantly reduces blood pressure compared to the placebo.&quot;&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;else&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    print&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;&quot;There is no significant difference in blood pressure reduction between the groups.&quot;&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Additional analyses, visualization, and interpretation can be conducted as needed.&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;We simulate blood pressure reduction data for participants in the treatment and control groups.&lt;/li&gt;
&lt;li&gt;We use a two-sample t-test to compare the mean blood pressure reductions between the two groups.&lt;/li&gt;
&lt;li&gt;If the p-value is less than the significance level (e.g., 0.05), we conclude that the new drug is effective in
reducing blood pressure.&lt;/li&gt;
&lt;li&gt;Otherwise, we fail to reject the null hypothesis, indicating no significant difference between the groups.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Errors&lt;/h2&gt;
&lt;p&gt;In hypothesis testing, there are two types of errors that can occur when making a decision about the null hypothesis:
&lt;strong&gt;Type I&lt;/strong&gt; error and &lt;strong&gt;Type II&lt;/strong&gt; error.&lt;/p&gt;
&lt;h3&gt;Type 1 Error&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Type-I (False Positive)&lt;/strong&gt; error occurs when the sample results, lead to the rejection of the null hypothesis when it
is in fact true.&lt;/p&gt;
&lt;p&gt;In other words, it&apos;s the mistake of finding a significant effect or relationship when there is none. The probability of
committing a Type I error is denoted by α (alpha), which is also known as the significance level. By choosing a
significance level, researchers can control the risk of making a Type I error.&lt;/p&gt;
&lt;h3&gt;Type 2 Error&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Type-II (False Negative)&lt;/strong&gt; error occurs when based on the sample results, the null hypothesis is not rejected when it
is in fact false.&lt;/p&gt;
&lt;p&gt;This means that the researcher fails to detect a significant effect or relationship when one actually exists. The
probability of committing a Type II error is denoted by β (beta). Trade-off between Type 1 and Type 2 errors&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;https://www.simplypsychology.org/wp-content/uploads/type-1-and-2-errors.jpg&quot; alt=&quot;hypothesis testing errors&quot; /&gt;&lt;/p&gt;
&lt;h2&gt;Where Can Be Hypothesis Testing Applied?&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Testing the effectiveness of interventions or treatments:&lt;/strong&gt; Hypothesis testing can be used to determine whether a
new drug, therapy, or educational intervention has a significant effect compared to a control group or an existing
treatment.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Comparing means or proportions:&lt;/strong&gt; Hypothesis testing can be used to compare means or proportions between two or
more groups to determine if there&apos;s a significant difference. This can be applied to compare average customer
satisfaction scores, conversion rates, or employee performance across different groups.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Analysing relationships between variables:&lt;/strong&gt; Hypothesis testing can be used to evaluate the association between
variables, such as the correlation between age and income or the relationship between advertising spend and sales.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Evaluating the goodness of fit:&lt;/strong&gt; Hypothesis testing can help assess if a particular theoretical distribution
(e.g., normal, binomial, or Poisson) is a good fit for the observed data.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Testing the independence of categorical variables:&lt;/strong&gt; Hypothesis testing can be used to determine if two categorical
variables are independent or if there&apos;s a significant association between them. For example, it can be used to test
if there&apos;s a relationship between the type of product and the likelihood of it being returned by a customer.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;A/B testing:&lt;/strong&gt; In marketing, product development, and website design, hypothesis testing is often used to compare
the performance of two different versions (A and B) to determine which one is more effective in terms of conversion
rates, user engagement, or other metrics.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Hypothesis Testing in ML Applications&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Feature selection:&lt;/strong&gt; Hypothesis testing can help identify which features are significantly related to the target
variable or contribute meaningfully to the model&apos;s performance. For example, you can use a t-test, chi-square test,
or ANOVA to test the relationship between individual features and the target variable. Features with significant
relationships can be selected for building the model, while non-significant features may be excluded.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Hyperparameter tuning:&lt;/strong&gt; Hypothesis testing can be used to evaluate the performance of a model trained with
different hyperparameter settings. By comparing the performance of models with different hyperparameters, you can
determine if one set of hyperparameters leads to significantly better performance.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Assessing model assumptions:&lt;/strong&gt; In some cases, machine learning models rely on certain statistical assumptions, such
as linearity or normality of residuals in linear regression. Hypothesis testing can help assess whether these
assumptions are met, allowing you to determine if the model is appropriate for the data.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Model comparison:&lt;/strong&gt; Hypothesis testing can be used to compare the performance of different machine learning models
or algorithms on a given dataset. For example, you can use a paired t-test to compare the accuracy or error rate of
two models on multiple cross- validation folds to determine if one model performs significantly better than the
other.&lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
&lt;p&gt;[!WARNING] Questions&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;What is P-value?&lt;/li&gt;
&lt;li&gt;What are different types of Hypothesis Tests.&lt;/li&gt;
&lt;li&gt;Differences between Z-test and T-test?&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Resources&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://towardsdatascience.com/p-values-explained-by-data-scientist-f40a746cfc8&quot;&gt;P-value Explained by Data Scientist&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://drive.google.com/file/d/1J6TWERqWu1-98n2b8uBKdU8j0aCVgyuN/view&quot;&gt;Session 1 on Hypothesis Testing.pdf&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=xHTMjxx14sU&quot;&gt;Session 46 - Hypothesis Testing Part 2 | p-values | t-tests | DSMP 2023&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>ml</category><category>interview-questions</category><author>Anshul Raj Verma</author></item><item><title>Learn Web Scraping</title><link>https://arv-anshul.github.io/blog/2024/learn-web-scraping</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/learn-web-scraping</guid><description>Learn Web Scraping from resources which I used to learn it.</description><pubDate>Sat, 23 Mar 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Web scraping is a very essential tool for programmers to learn to gather data from websites. Specifically, for Data
Scientists web scraping is goto tool to gather data from websites. We can use &lt;code&gt;bs4.BeautifulSoup&lt;/code&gt; or &lt;code&gt;selenium&lt;/code&gt; in
Python to scrape any website.&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;https://realpython.com/cdn-cgi/image/width=1920,format=auto/https://files.realpython.com/media/Python-Basics-Chapter-on-Web-Scraping_Watermarked.f8d56f56c22c.jpg&quot; alt=&quot;web scraping - real python&quot; /&gt;&lt;/p&gt;
&lt;p&gt;You can see some of my projects where I scraped websites like &lt;a href=&quot;https://99acres.com&quot;&gt;99acres.com&lt;/a&gt;,
&lt;a href=&quot;https://flipkart.com&quot;&gt;flipkart.com&lt;/a&gt;, &lt;a href=&quot;https://housin.com&quot;&gt;housing.com&lt;/a&gt; and gather useful data for my Data Science
projects like &lt;a href=&quot;https://github.com/arv-anshul/campusx-real-estate&quot;&gt;arv-anshul/campusx-real-estate&lt;/a&gt;.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;I have learned Web Scraping from YouTube only.&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;YouTube Videos&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/@coreyms&quot;&gt;&lt;strong&gt;Corey Schafer&lt;/strong&gt;&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=9N6a-VLBa2I&quot;&gt;Working with JSON Data using the json Module&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=tb8gHvYlCFs&quot;&gt;Request Web Pages, Download Images, POST Data, Read JSON, and More&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=ng2o98k983k&quot;&gt;Web Scraping with BeautifulSoup and Requests&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=a6fIbtFB46g&quot;&gt;Web Scraping with Requests-HTML&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;YouTube Playlists&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://www.youtube.com/@JohnWatsonRooney&quot;&gt;&lt;strong&gt;John Watson Rooney&lt;/strong&gt;&lt;/a&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/playlist?list=PLRzwgpycm-Fio7EyivRKOBN4D3tfQ_rpu&quot;&gt;Modern Web Scraping with Python&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/playlist?list=PLRzwgpycm-Fi5Pe_W2HwEwyvcB5-SJLB7&quot;&gt;Best Web Scraping Methods&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://www.youtube.com/@IndianPythonista&quot;&gt;&lt;strong&gt;Indian Pythonista&lt;/strong&gt;&lt;/a&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/playlist?list=PLyb_C2HpOQSCAi67ZF0w-6CvCvZs_OXAB&quot;&gt;Discovering Hidden APIs&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/playlist?list=PLyb_C2HpOQSD12DYc3u2EaLpyWIT4ri7z&quot;&gt;Python for web&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you follow/learn these resources then you will understand how do Web Scraping works and how to do it.&lt;/p&gt;
&lt;h2&gt;My Python Package for Web Scraping&lt;/h2&gt;
&lt;p&gt;I have done lots of project on Web Scraping but while doing those web scraping projects I doesn&apos;t found a good python
package to handle/parse cURL command. But I found a package called &lt;a href=&quot;https://github.com/spulec/uncurl&quot;&gt;@spulec/uncurl&lt;/a&gt; on
GitHub but it is managed badly so that I cloned that project and refactor it well and republished as
&lt;a href=&quot;https://pypi.org/p/curler&quot;&gt;&lt;code&gt;curler&lt;/code&gt; on PyPI&lt;/a&gt;.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://pypi.org/p/curler&quot;&gt;&lt;code&gt;curler&lt;/code&gt; on PyPI&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/curler&quot;&gt;&lt;code&gt;curler&lt;/code&gt; on GitHub&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;My Projects Related to Web Scraping&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io/campusx-dsmp&quot;&gt;&lt;code&gt;campusx-dsmp&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/99acres-scrape&quot;&gt;&lt;code&gt;99acres-scrape&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/ecommerce-scrapper-api&quot;&gt;&lt;code&gt;ecommerce-scrapper-api&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/pw-api&quot;&gt;&lt;code&gt;pw-api&lt;/code&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>others</category><author>Anshul Raj Verma</author></item><item><title>Learning Diary Migration</title><link>https://arv-anshul.github.io/blog/2024/diary-migration</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/diary-migration</guid><description>How it feels to migrate from obsidian to mkdocs.</description><pubDate>Fri, 22 Mar 2024 12:53:00 GMT</pubDate><content:encoded>&lt;p&gt;I used to maintain my &lt;a href=&quot;https://github.com/arv-anshul/diary&quot;&gt;diary&lt;/a&gt; with &lt;a href=&quot;https://obsidian.md&quot;&gt;Obsidian&lt;/a&gt; app. And recently I have learned &lt;a href=&quot;https://github.com/squidfunk/mkdocs-material&quot;&gt;mkdocs-material&lt;/a&gt;
which is used to create static website using markdown files only.&lt;/p&gt;
&lt;p&gt;Obsidian is made to use it as a notes/documents management tool/app but I am just writing my thoughts and journals,
nothing else. And for this I can also use VSCode or any other editor to write notes in markdown format. That&apos;s when I
know about &lt;a href=&quot;https://github.com/squidfunk/mkdocs-material&quot;&gt;mkdocs-material&lt;/a&gt; and I fall for it :heart:.&lt;/p&gt;
&lt;p&gt;When I decided to migrate my notes I have lots of notes regarding &lt;strong&gt;My Projects, Data Science, FastAPI and more&lt;/strong&gt;. So I
have to decide whether to remove them or keep them, so I decided to merge the similar one and publish them as
&lt;a href=&quot;https://arv-anshul.github.io/blog/archive/2024/03&quot;&gt;blogs on the website&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Merged Notes as Blogs&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;:adhesive_bandage: &lt;a href=&quot;https://arv-anshul.github.io/blog/regularization-in-ml&quot;&gt;Regularization in ML&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io/blog/outlier-univariate&quot;&gt;Handle Outliers - Univariate&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io/blog/learn-fastapi&quot;&gt;Learn FastAPI&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io/blog/learn-docker&quot;&gt;Learn Docker&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;I have published most of the notes as blog except &lt;strong&gt;My Projects notes&lt;/strong&gt; which contains the rough works which I used to
do while creating projects. So I completely :fire: removed them and decided to maintain them
&lt;a href=&quot;https://arv-anshul.github.io/projects&quot;&gt;on the website as projects notes&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;If you want to see how the &lt;a href=&quot;https://github.com/arv-anshul/diary&quot;&gt;diary&lt;/a&gt; looks while I am &lt;a href=&quot;https://github.com/arv-anshul/diary/tree/v1.0.0&quot;&gt;maintaining it with obsidian&lt;/a&gt;. You can also see My
Projects Notes there.&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;https://github.com/arv-anshul/diary/tree/v1.0.0&quot;&gt;diary/v1.0.0&lt;/a&gt;&lt;/p&gt;
</content:encoded><category>blog</category><category>github</category><category>diary</category><category>journal</category><category>website</category><author>Anshul Raj Verma</author></item><item><title>Tree VS Regression Models</title><link>https://arv-anshul.github.io/blog/2024/tree-vs-regression-models</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/tree-vs-regression-models</guid><description>Major difference between Tree based models and Regression models.</description><pubDate>Thu, 21 Mar 2024 00:00:00 GMT</pubDate><content:encoded>&lt;blockquote&gt;
&lt;p&gt;From CampusX Trail Session&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Tree based models and Regression models are widely used Machine Learning models. So more you know about them is better
for you. Also, many concepts from these models are borrowed by advance Machine Learning models like Gradient Boosting,
XGBoost, etc.&lt;/p&gt;
&lt;p&gt;These models are also great choice for interviewers so from these models they ask many interview questions. This blog
mainly focuses on tree based models.&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Aspect&lt;/th&gt;
&lt;th&gt;Decision Trees&lt;/th&gt;
&lt;th&gt;Regression Models&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Type&lt;/td&gt;
&lt;td&gt;Can be used for classification and regression&lt;/td&gt;
&lt;td&gt;Used for predictive modeling, predicting continuous values&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Decision Boundaries&lt;/td&gt;
&lt;td&gt;Bisect the space into smaller regions, fitting lines to divide the space exactly&lt;/td&gt;
&lt;td&gt;Focuses on predicting outcomes based on previous data or trends&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Interpretability&lt;/td&gt;
&lt;td&gt;Easy to understand and interpret due to their flowchart-like structure&lt;/td&gt;
&lt;td&gt;Interpretability varies based on the complexity of the model&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Advantages&lt;/td&gt;
&lt;td&gt;Easy to interpret, visualize, and require minimal data preparation&lt;/td&gt;
&lt;td&gt;Effective in predicting continuous values based on historical data&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Disadvantages&lt;/td&gt;
&lt;td&gt;Prone to overfitting noisy data, especially with deeper trees&lt;/td&gt;
&lt;td&gt;May struggle with capturing complex relationships in the data&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;How They Work&lt;/td&gt;
&lt;td&gt;Split the dataset based on data homogeneity, using measures like entropy for classification trees and Sum of Squared Errors for regression trees&lt;/td&gt;
&lt;td&gt;Focuses on fitting a curve or surface to the data points to predict continuous values&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2&gt;1. What Are the Main Differences Between Tree Based Models and Regression Models?&lt;/h2&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Aspect&lt;/th&gt;
&lt;th&gt;Tree Based Models&lt;/th&gt;
&lt;th&gt;Linear Models&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Approach&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Tree based models &lt;strong&gt;uses Divide &amp;amp; Conquer approach&lt;/strong&gt; to learn the data essence by making cut into data space to create small spaces which segregate the homogenous data.&lt;/td&gt;
&lt;td&gt;Regression models tries to create/fit a line in-between the data space, to get the essence of the data and tries to keep the value of loss function minimum as possible.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Non-Linearity&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Tree models can handle both linear and non-linear data.&lt;/td&gt;
&lt;td&gt;Regression models performs better with linearly separable data but it fails to capture the essence of non-linear data.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Computational Complexity&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Tree models are more complex than linear models, especially training complexity of Ensemble techniques as it finds optimal solution iteratively.&lt;/td&gt;
&lt;td&gt;Regression models has an upper edge here because it requires find the optimal co-efficient which minimizes the loss function and for that it uses Gradient Descent techniques.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Effects of Outliers&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Tree models are generally robust to &lt;a href=&quot;outlier-univariate.md&quot;&gt;outliers&lt;/a&gt; because they creates multiple decision boundaries which separates the outliers easily and model doesn&apos;t affect much from it.&lt;/td&gt;
&lt;td&gt;Regression models are highly sensitive to &lt;a href=&quot;outlier-univariate.md&quot;&gt;outliers&lt;/a&gt; because when the data has outliers the best fit line will try to fit the outliers values to reduce the loss function. &lt;strong&gt;To reduce this sensitivity we have &lt;a href=&quot;regularization-in-ml.md&quot;&gt;Regularization&lt;/a&gt; concepts&lt;/strong&gt;.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Handling Null Values&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Some tree based algorithms/models can handle null values like &lt;strong&gt;XGBoost&lt;/strong&gt;.&lt;/td&gt;
&lt;td&gt;Linear model can&apos;t handle null values at all. Preprocess the data before training linear models.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Interpretable&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Only Decision Trees are interpretable but libraries like &lt;a href=&quot;https://shap.readthedocs.io/en/latest/&quot;&gt;SHAP&lt;/a&gt; can explain ensemble tree models. &lt;strong&gt;RandomForest can be used to calc features importance.&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Linear models are very interpretable because it calculates the features co-efficient with target feature.&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2&gt;2. Can You Describe a Real-World Application Where You Would Prefer to Use a RandomForest over a Logistic Regression Model?&lt;/h2&gt;
&lt;p&gt;We can preffer RandomForest over Logistic Regression in the many scenarios like:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;When data has &lt;a href=&quot;outlier-univariate.md&quot;&gt;outliers&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;When data is hight dimensional.&lt;/li&gt;
&lt;li&gt;When data is non-lineear.&lt;/li&gt;
&lt;li&gt;When data is imbalanced.&lt;/li&gt;
&lt;li&gt;RandomForest algorithm is robust to overfitting while training.&lt;/li&gt;
&lt;li&gt;Also, RandomForest can handle categorical features better than logistic regression because you can use
&lt;code&gt;OrdinalEncoder&lt;/code&gt; to encode categorical feature instead of &lt;code&gt;OneHotEncoder&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;By the way, you can use libraries like
&lt;a href=&quot;https://docs.h2o.ai/h2o/latest-stable/h2o-py/docs/modeling.html#h2orandomforestestimator&quot;&gt;&lt;code&gt;h2o&lt;/code&gt;&lt;/a&gt; which can handle
null values too.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;3. What Is the Impact of Outliers on Decision Tree?&lt;/h2&gt;
&lt;p&gt;Decision Trees can handle Outliers easily because it segregate them using decision boundaries in the initial steps.
However, if the Decision Tree becomes overfitted to a training dataset, it can become more sensitive to outliers,
potentially affecting the model&apos;s performance. Also, you can Regularization methods to tackle outliers.&lt;/p&gt;
&lt;p&gt;Mainly outliers can affect Decision Trees while working with regression problems (only in those leaf-nodes where
outliers are present/classified/calculated). Prediction of model is affected in those leaf-nodes where outliers are
calculated (this is proven) but this is not the case in classification problems.&lt;/p&gt;
&lt;h2&gt;4. What Is the Role of Pruning in Decision Tree, What Is post-Pruning and pre-Pruning?&lt;/h2&gt;
&lt;h3&gt;Role of Pruning in Decision Trees&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;Pruning in Decision Trees is crucial to prevent overfitting and enhance the model&apos;s ability to generalize by
simplifying the tree structure.&lt;/li&gt;
&lt;li&gt;It involves removing parts of the tree that do not contribute significantly to predictive power, making the model
more interpretable and effective.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Pre-Pruning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;Pre-pruning involves stopping the tree&apos;s growth before it fits the entire training set.&lt;/li&gt;
&lt;li&gt;It focuses on setting hyperparameters to control the tree&apos;s size during construction, preventing overfitting by
limiting its complexity.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Post-Pruning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;Post-pruning allows the tree to grow fully and then removes nodes that do not add substantial predictive power.&lt;/li&gt;
&lt;li&gt;Techniques like cost-complexity pruning are commonly used in post-pruning to simplify the tree by selecting the
subtree with the smallest cost based on a complexity parameter and the number of leaf nodes.&lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
&lt;p&gt;[!NOTE]&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Pre-pruning&lt;/strong&gt;: Penalize (by cutting the nodes) the model while training.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Post-pruning&lt;/strong&gt;: First fully train the model then after penalize the model by cutting down the nodes.&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Cost Complexity Function in Decision Tree&lt;/h3&gt;
&lt;p&gt;The cost complexity function in decision trees is a crucial concept related to pruning techniques. It involves a
tradeoff between error (cost) and tree size (complexity) to find an optimal tree. The cost complexity of a tree, denoted
as &lt;code&gt;#!math R_{c_p}(T)&lt;/code&gt;, is the sum of its risk (error) and a &quot;cost complexity&quot; factor &lt;code&gt;#!math c_p&lt;/code&gt; multiplied by the
tree size &lt;code&gt;#!math T&lt;/code&gt;. This function is used in cost complexity pruning to minimize the cross-validated prediction error
and prevent overfitting. By adjusting the cost complexity parameter &lt;code&gt;#!math c_p&lt;/code&gt;, decision trees can be pruned
effectively to improve generalization to test data.&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;https://scikit-learn.org/stable/auto_examples/tree/plot_cost_complexity_pruning.html&quot;&gt;&lt;code&gt;plot_cost_complexity_pruning&lt;/code&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;5. How Missing Values Are Handled in Tree Based Algorithms like XGBoost?&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;XGBoost only handle missing values present in Input features. It doesn&apos;t handle null values present in Output/Target
feature. You have to preprocess or remove the null values of Output feature.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Not completed!&lt;/p&gt;
&lt;h2&gt;6. What Is the Difference Between ID3, C4.5, and CART Algorithms?&lt;/h2&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Algorithm&lt;/th&gt;
&lt;th&gt;ID3&lt;/th&gt;
&lt;th&gt;C4.5&lt;/th&gt;
&lt;th&gt;CART&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Type&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Iterative Dichotomiser 3&lt;/td&gt;
&lt;td&gt;Iterative algorithm, extension of ID3&lt;/td&gt;
&lt;td&gt;Classification and Regression Trees&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Handling of Numeric Attributes&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Less effective for numeric attributes&lt;/td&gt;
&lt;td&gt;Handles numeric and categorical attributes&lt;/td&gt;
&lt;td&gt;Handles numeric and categorical attributes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Splitting Criteria&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Information Gain&lt;/td&gt;
&lt;td&gt;Gain Ratio&lt;/td&gt;
&lt;td&gt;Gini diversity index for classification tests&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Pruning&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Does not handle pruning&lt;/td&gt;
&lt;td&gt;Prunes trees to avoid overfitting&lt;/td&gt;
&lt;td&gt;Prunes trees using a complex model with parameters estimated by cross-validation&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Binary Tests&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Always binary tests&lt;/td&gt;
&lt;td&gt;Allows two or more outcomes&lt;/td&gt;
&lt;td&gt;Binary tests&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2&gt;7. How Would You Approach a Situation Where Your Tree-Based Model Is Overfitting?&lt;/h2&gt;
&lt;p&gt;I can apply pruning techniques which penalize the model if it tries to overfit while training. We have many
hyperparameters in DecisionTree, RandomForest classes apply pre-pruning on models.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;max_depth&lt;/code&gt;&lt;/strong&gt;: The maximum depth of the tree. Prevent the tree to grow after specified depth.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;min_samples_split&lt;/code&gt;&lt;/strong&gt;: The minimum number of samples required to split an internal node.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;min_samples_leaf&lt;/code&gt;&lt;/strong&gt;: The minimum number of samples required to be at a leaf node. A split point at any depth will
only be considered if it leaves at least min_samples_leaf training samples in each of the left and right branches.
This may have the effect of smoothing the model, especially in regression.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;min_weight_fraction_leaf&lt;/code&gt;&lt;/strong&gt;: The minimum weighted fraction of the sum total of weights (of all the input samples)
required to be at a leaf node. Samples have equal weight when sample_weight is not provided.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;max_features&lt;/code&gt;&lt;/strong&gt;: The number of features to consider when looking for the best split.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;max_leaf_nodes&lt;/code&gt;&lt;/strong&gt;: Grow a tree with max_leaf_nodes in best-first fashion. Best nodes are defined as relative
reduction in impurity. If &lt;code&gt;None&lt;/code&gt; then unlimited number of leaf nodes.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;min_impurity_decrease&lt;/code&gt;&lt;/strong&gt;: &lt;em&gt;(Best parameter for pruning)&lt;/em&gt; A node will be split if this split induces a decrease of
the impurity greater than or equal to this value.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;class_weight&lt;/code&gt;&lt;/strong&gt;: Weights associated with classes in the form &lt;code&gt;{class_label: weight}&lt;/code&gt;. If &lt;code&gt;None&lt;/code&gt;, all classes are
supposed to have weight one. For multi-output problems, a list of dicts can be provided in the same order as the
columns of y.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;ccp_alpha&lt;/code&gt;&lt;/strong&gt;: Complexity parameter used for Minimal Cost-Complexity Pruning. The subtree with the largest cost
complexity that is smaller than ccp_alpha will be chosen. By default, no pruning is performed.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;&lt;a href=&quot;https://scikit-learn.org/stable/modules/generated/sklearn.tree.DecisionTreeClassifier.html#sklearn.tree.DecisionTreeClassifier&quot;&gt;&lt;code&gt;sklearn.tree.DecisionTreeClassifier&lt;/code&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;8. Discuss the Role of Shrinkage (Learning Rate) in Boosting Algorithms. How Does It Contribute to Model Performance and Robustness?&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;The learning rate, also known as shrinkage, plays a crucial role in boosting algorithms by determining how fast or
slow a model updates its weights based on the gradient of the loss function.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;A fixed learning rate&lt;/strong&gt; can lead to challenges such as overshooting the optimal point with a high value or slow
convergence with a low value, highlighting the importance of dynamic adjustments during training.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Adaptive learning rate&lt;/strong&gt; schedules, like decay learning rates, gradually reduce the learning rate as training
progresses, helping to avoid overshooting the minimum and fine-tune model parameters more precisely.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Decay learning rates&lt;/strong&gt; can be implemented using various methods like fixed or exponential decay rates, step or
inverse decay functions, and are essential for efficient and effective model training, especially in complex and
non-convex problems.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;By adjusting the learning rate dynamically&lt;/strong&gt;, decay learning rates ensure that the model progresses effectively
towards the optimal solution, balancing the size of steps taken during training to enhance model optimization and
robustness.&lt;/li&gt;
&lt;/ul&gt;
&lt;blockquote&gt;
&lt;p&gt;This question comes under Boosting algorithms which is advance topic.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;9. Discuss the Computational Complexity of Training a Decision Tree and How It Scales with the Size of the Dataset.&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;The computational complexity of training a Decision Tree is influenced by the size of the dataset and the number of
dimensions in the feature space.&lt;/li&gt;
&lt;li&gt;Heuristic algorithms are commonly used to compute Decision Trees from training data, aiming to minimize the size of
the resulting tree, which impacts the computational complexity of the process.&lt;/li&gt;
&lt;li&gt;Understanding the computational complexity of training Decision Trees is essential for optimizing algorithms and
improving efficiency in machine learning tasks, especially when dealing with large datasets and high-dimensional
feature spaces.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;10. How Do Tree-Based Algorithms Handle Imbalanced Datasets, and What Are the Implications for Model Performance and Interpretation?&lt;/h2&gt;
&lt;p&gt;There is a hyperparameter in DecisionTree class called &lt;code&gt;class_weigth&lt;/code&gt; where you can assign weights to each class label
or you can provide &lt;code&gt;&quot;balanced&quot;&lt;/code&gt; which will automatically assign weights to each class labels.&lt;/p&gt;
&lt;h3&gt;How Do You Manually Assign Weights?&lt;/h3&gt;
&lt;p&gt;It depends on your domain knowledge or you can use hit &amp;amp; try method.&lt;/p&gt;
&lt;h3&gt;How Do &lt;code&gt;&quot;balanced&quot;&lt;/code&gt; Value Assign Weights?&lt;/h3&gt;
&lt;p&gt;It assigns &lt;code&gt;#!math \frac{1}{n}&lt;/code&gt; weight value to each class labels where &lt;code&gt;#!math n&lt;/code&gt; is the count of data points present
the following class.&lt;/p&gt;
&lt;hr /&gt;
&lt;h2&gt;Similar Blogs&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;./decision-tree&quot;&gt;Decision Tree&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;./regression-interview-quesitons&quot;&gt;Regression Interview Questions&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;./regularization-in-ml&quot;&gt;Regularization in ML&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>ml</category><category>interview-questions</category><author>Anshul Raj Verma</author></item><item><title>CampusX Trail Sessions</title><link>https://arv-anshul.github.io/blog/2024/campusx-trail-sessions</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/campusx-trail-sessions</guid><description>Trail session conducted by CampusX in DSMP 2.0 course to recruit teachers.</description><pubDate>Wed, 20 Mar 2024 08:35:00 GMT</pubDate><content:encoded>&lt;p&gt;Nitish Sir wants to recruit teachers to teach along in the course and for that he had to evaluate applicants thats why
he conducted trail session in DSMP 2.0 course where the selected applicants comes and take a 2 Hours long session on
assigned topic (assigned by Nitish Sir). The applicant take seesion and the students had to fill a Google Forms Feedback
Form. Applicants are evaluted on the basis of feedback given by the students.&lt;/p&gt;
&lt;p&gt;Session are conducted in March, 2024. and all the trial session are awesome and amazing (except some). I have learned
many new concepts from them and I&apos;ve rank them below on the basis of my experiences.&lt;/p&gt;
&lt;h2&gt;Best Sessions&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Model Explainability &lt;em&gt;(by Balaji Chippada)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Solving a banking problem using ML &lt;em&gt;(by Rohan Azad)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;NER using NLTK and Spacy &lt;em&gt;(by Md. Amanatullah)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Intro to Power BI &lt;em&gt;(by Vibhore Aggarwal)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Interview Qs on Tree Based Models &lt;em&gt;(by Ajay Sati)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Introduction to Time Series Forecasting &lt;em&gt;(by Ajinkya Mohite)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Interview Questions on Regression &lt;em&gt;(by DP Sharma)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Intro to FastAPI &lt;em&gt;(by Md. Misbahullah Sheriff)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Project Based Interview Sessions &lt;em&gt;(by Rohan Azad)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;ML Interview Questions Sessions &lt;em&gt;(by Rohan Azad)&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Mediocre Sessions&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Intro to PyTorch &lt;em&gt;(by Rishab Tomar)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Latent Dirichlet Allocation (LDA) &lt;em&gt;(by Aman Bansal)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Prompt Engineering &lt;em&gt;(by Saksham Kumar)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Anamoly Detection &lt;em&gt;(by Chandramouli Das)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;eKYC using Computer Vision &lt;em&gt;(by Bibek Rauth)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;A/B Testing &lt;em&gt;(by Dixit Patel)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Introduction of Langchain &lt;em&gt;(by Sameer Singh)&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Bad Sessions&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Interview Questions on Statistics &lt;em&gt;(by Chirantan Lonkar)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;ResNET Paper Discussion &lt;em&gt;(by Vinod Tiwari)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Multi-Output Multi-Class Classification &lt;em&gt;(by Prabin Kumar Nayak)&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Thanks to Nitish Sir and all the Applicants for these amazing sessions.&lt;/strong&gt;&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><author>Anshul Raj Verma</author></item><item><title>Zed Code Editor</title><link>https://arv-anshul.github.io/blog/2024/zed-impression</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/zed-impression</guid><description>Zed code editor impression.</description><pubDate>Wed, 20 Mar 2024 07:49:00 GMT</pubDate><content:encoded>&lt;p&gt;Zed is not just other code editor community is working on it continuously on it. I have been following Zed development
for a long time and I also trying it and also trying to understand its difference from Visual Studio Code (VSCode).&lt;/p&gt;
&lt;p&gt;I have to say that Zed is ***king faster than VSCode. &lt;em&gt;&lt;strong&gt;Yeh itna tez ki lagta hai ki slow karne ka koi setting hota
🫣.&lt;/strong&gt;&lt;/em&gt; But it&apos;s UI is not engaging as VSCode&apos;s because maybe because it has not all the essential features like
(rigorous) Syntax Highlighting, SCM UI Integration, Extension Support, etc. for now 😞.&lt;/p&gt;
&lt;p&gt;I&apos;m waiting for Zed to be ready so that I can use it daily without hesitation just like I use VSCode.&lt;/p&gt;
&lt;p&gt;Thanks &lt;a href=&quot;https://github.com/zed-industries/zed/graphs/contributors&quot;&gt;Zed Contrbutors&lt;/a&gt;.&lt;/p&gt;
&lt;hr /&gt;
&lt;ul&gt;
&lt;li&gt;I have also mentioned Zed in my &lt;a href=&quot;../../journal/2024/03.md#week-11-journal&quot;&gt;Journal&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Configured Zed for python development &lt;a href=&quot;../../journal/2024/09.md#week-39-journal&quot;&gt;Journal&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>programming</category><author>Anshul Raj Verma</author></item><item><title>Learn Docker</title><link>https://arv-anshul.github.io/blog/2024/learn-docker</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/learn-docker</guid><description>Learn Docker, Dockerfile, .dockerignore</description><pubDate>Sun, 17 Mar 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Docker is a platform designed to simplify the process of creating, deploying, and managing applications using
containers. Containers enable developers to package an application with all its dependencies into a standardized unit
for seamless deployment across different environments.&lt;/p&gt;
&lt;h2&gt;:hammer_and_wrench: Components of Docker&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;#dockerfile&quot;&gt;Dockerfile&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;#dockerignore&quot;&gt;.dockerignore&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;docker-compose.yaml&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;&lt;code&gt;Dockerfile&lt;/code&gt;&lt;/h2&gt;
&lt;p&gt;A &lt;code&gt;Dockerfile&lt;/code&gt; serves as a blueprint for building Docker images, which are the executable packages containing everything
needed to run an application - code, runtime, system tools, libraries, and settings. Let&apos;s break down the components of
a &lt;code&gt;Dockerfile&lt;/code&gt; and its significance in the context of Docker:&lt;/p&gt;
&lt;h3&gt;Context on Dockerfile&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Foundation of Image Creation:&lt;/strong&gt; A &lt;code&gt;Dockerfile&lt;/code&gt; specifies a sequence of instructions to assemble an image. It starts
with a base image (e.g., Ubuntu, Alpine Linux, Python) and then layers additional configurations and dependencies on
top of it.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Clear and Reproducible Build Process:&lt;/strong&gt; Each instruction in the &lt;code&gt;Dockerfile&lt;/code&gt; represents a step in the
image-building process. These steps are executed in order, and Docker caches intermediate layers, facilitating faster
subsequent builds and ensuring consistency across environments.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Key Components of a Dockerfile:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Base Image:&lt;/strong&gt; Specifies the starting point for the image.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Environment Setup:&lt;/strong&gt; Includes commands to install packages, set environment variables, copy files into the image,
etc.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Application Configuration:&lt;/strong&gt; Defines how the application should be configured inside the container.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Startup Commands:&lt;/strong&gt; Specifies the command to execute when the container starts.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Comprehensive Description of a Dockerfile&lt;/h3&gt;
&lt;p&gt;A typical &lt;code&gt;Dockerfile&lt;/code&gt; consists of several sections:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;FROM:&lt;/strong&gt; Defines the base image. It&apos;s the starting point for the image build and often references an official or
custom base image from a registry (e.g., &lt;code&gt;FROM python:3.11-slim&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;WORKDIR:&lt;/strong&gt; Sets the working directory inside the container where subsequent commands will be executed.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;COPY/ADD:&lt;/strong&gt; Copies files or directories from the host machine into the container&apos;s filesystem. This includes
application code, configuration files, etc.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;RUN:&lt;/strong&gt; Executes commands during the image build process. Typically used for installing dependencies, setting up the
environment, and other preparatory tasks.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;ENV:&lt;/strong&gt; Sets environment variables within the container. These can define runtime configurations or paths.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;EXPOSE:&lt;/strong&gt; Informs Docker that the container listens on specific network ports at runtime.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;CMD/ENTRYPOINT:&lt;/strong&gt; Specifies the command that should be run when the container starts. &lt;code&gt;CMD&lt;/code&gt; is used to provide
default arguments for the &lt;code&gt;ENTRYPOINT&lt;/code&gt; command, while &lt;code&gt;ENTRYPOINT&lt;/code&gt; sets the primary command.&lt;/li&gt;
&lt;/ol&gt;
&lt;h4&gt;An Example Dockerfile of a Python Project&lt;/h4&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;# Use an official Python runtime as a parent image&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;FROM&lt;/span&gt;&lt;span&gt; python:3.10&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Set the working directory to /app&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;WORKDIR&lt;/span&gt;&lt;span&gt; /app&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Copy the required files and directory into the container at /app&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;COPY&lt;/span&gt;&lt;span&gt; requirements.txt .&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;RUN&lt;/span&gt;&lt;span&gt; pip install --no-cache-dir -r requirements.txt&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;COPY&lt;/span&gt;&lt;span&gt; . .&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Run main.py when the container launches&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;CMD&lt;/span&gt;&lt;span&gt; [&lt;/span&gt;&lt;span&gt;&quot;python&quot;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&quot;main.py&quot;&lt;/span&gt;&lt;span&gt;]&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;# Build docker container&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; build&lt;/span&gt;&lt;span&gt; -t&lt;/span&gt;&lt;span&gt; my_python_container&lt;/span&gt;&lt;span&gt; .&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Run docker image&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; run&lt;/span&gt;&lt;span&gt; -it&lt;/span&gt;&lt;span&gt; my_python_container&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Importance and Benefits&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Portability:&lt;/strong&gt; Dockerfiles enable developers to create consistent environments, ensuring that applications run
identically across various systems and environments.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Reproducibility:&lt;/strong&gt; By capturing all dependencies and configurations in the Dockerfile, developers can replicate the
same environment for development, testing, and production.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Scalability and Efficiency:&lt;/strong&gt; Docker&apos;s containerization allows for quick scaling and resource efficiency, enabling
applications to be deployed and managed easily.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;blockquote&gt;
&lt;p&gt;A &lt;code&gt;Dockerfile&lt;/code&gt; is the backbone of Docker-based applications, providing a clear, reproducible, and scalable approach to
building containerized applications. It defines the entire setup and configuration needed to run an application within
a container, promoting consistency and ease of deployment across different environments.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Resources to Learn Docker&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;PiyushGarg YouTube&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/playlist?list=PLinedj3B30sDvBfeK9EPz9pcJNlM0f3ph&quot;&gt;Docker - Hindi YouTube Playlist | PiyushGarg&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=31k6AtW-b3Y&quot;&gt;Docker In One Shot - Part 1&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=xPT8mXa-sJg&quot;&gt;Docker For Open Source Contributors - Part 2&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=AiiFbsAlLaI&quot;&gt;Deploying Docker Containers on AWS Elastic Container Service (ECS) | Container Orchestration&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Visual Studio Code - Docs&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://code.visualstudio.com/remote/advancedcontainers/overview&quot;&gt;Working with containers in Visual Studio Code&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://code.visualstudio.com/docs/containers/quickstart-python&quot;&gt;Build and run a Python app in a container | VSCode&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;&lt;code&gt;docker&lt;/code&gt;&lt;/h2&gt;
&lt;h3&gt;1. &lt;code&gt;docker run&lt;/code&gt;&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Description:&lt;/strong&gt; Starts a new container from an image.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; run&lt;/span&gt;&lt;span&gt; -it&lt;/span&gt;&lt;span&gt; --name&lt;/span&gt;&lt;span&gt; my_container&lt;/span&gt;&lt;span&gt; ubuntu:latest&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;-it&lt;/code&gt;: Starts an interactive terminal within the container.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;--name my_container&lt;/code&gt;: Names the container as &quot;my_container&quot;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;ubuntu:latest&lt;/code&gt;: Specifies the image to use (latest Ubuntu image).&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;2. &lt;code&gt;docker ps&lt;/code&gt;&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Description:&lt;/strong&gt; Lists running containers.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; ps&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This command shows the containers&apos; IDs, names, status, ports, and images.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;3. &lt;code&gt;docker images&lt;/code&gt;&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Description:&lt;/strong&gt; Lists available images.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; images&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Displays a list of all downloaded Docker images along with their tags and sizes.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;4. &lt;code&gt;docker build&lt;/code&gt;&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Description:&lt;/strong&gt; Builds an image from a Dockerfile.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; build&lt;/span&gt;&lt;span&gt; -t&lt;/span&gt;&lt;span&gt; my_image:latest&lt;/span&gt;&lt;span&gt; .&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;-t my_image:latest&lt;/code&gt;: Tags the image as &quot;my_image&quot; with the &quot;latest&quot; tag.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;.&lt;/code&gt;: Specifies the build context (current directory) containing the Dockerfile.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;5. &lt;code&gt;docker stop&lt;/code&gt;&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Description:&lt;/strong&gt; Stops a running container.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; stop&lt;/span&gt;&lt;span&gt; my_container&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Stops the container named &quot;my_container&quot;.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;6. &lt;code&gt;docker start&lt;/code&gt;&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Description:&lt;/strong&gt; Starts a stopped container.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; start&lt;/span&gt;&lt;span&gt; my_container&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Starts the container named &quot;my_container&quot; that was stopped.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;7. &lt;code&gt;docker rm&lt;/code&gt;&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Description:&lt;/strong&gt; Removes one or more containers.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; rm&lt;/span&gt;&lt;span&gt; my_container&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Deletes the container named &quot;my_container&quot;.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;8. &lt;code&gt;docker rmi&lt;/code&gt;&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Description:&lt;/strong&gt; Removes one or more images.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; rmi&lt;/span&gt;&lt;span&gt; my_image:latest&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Removes the image &quot;my_image&quot; with the &quot;latest&quot; tag.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;9. &lt;code&gt;docker exec&lt;/code&gt;&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Description:&lt;/strong&gt; Executes a command within a running container.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; exec&lt;/span&gt;&lt;span&gt; -it&lt;/span&gt;&lt;span&gt; my_container&lt;/span&gt;&lt;span&gt; bash&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Executes the Bash shell (&lt;code&gt;bash&lt;/code&gt;) in the running container named &quot;my_container&quot; interactively (&lt;code&gt;-it&lt;/code&gt;).&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;10. &lt;code&gt;docker logs&lt;/code&gt;&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Description:&lt;/strong&gt; Retrieves logs from a container.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;docker&lt;/span&gt;&lt;span&gt; logs&lt;/span&gt;&lt;span&gt; my_container&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Fetches the logs of the container named &quot;my_container&quot;.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;These commands form the core of Docker usage for managing containers, images, building, starting/stopping containers,
and interacting with containerized applications. They&apos;re essential for everyday Docker workflows in development,
testing, and deployment scenarios.&lt;/p&gt;
&lt;h2&gt;&lt;code&gt;.dockerignore&lt;/code&gt;&lt;/h2&gt;
&lt;p&gt;&lt;code&gt;.dockerignore&lt;/code&gt; is a file used to specify which files and directories to exclude when building a Docker image. It works
similarly to &lt;code&gt;.gitignore&lt;/code&gt; but for Docker. When building an image, Docker uses this file to determine which files should
not be included in the context sent to the Docker daemon, thus reducing the image size and build time.&lt;/p&gt;
&lt;h3&gt;Example&lt;/h3&gt;
&lt;p&gt;An &lt;code&gt;.dockerignore&lt;/code&gt; file might contain entries like &lt;code&gt;node_modules&lt;/code&gt;, &lt;code&gt;*.log&lt;/code&gt;, or any other files/directories that are not
necessary for the image build process.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;# Byte-compiled files&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;__pycache__&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;*.pyc&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;*.pyo&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;*.pyd&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Virtual environments&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;venv/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;env/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;.venv/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Editor/IDE specific files&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;.vscode/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;.idea/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;*.sublime-project&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;*.sublime-workspace&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Logs and temp files&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;*.log&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;logs/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;*.tmp&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# Miscellaneous&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;.DS_Store&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;node_modules/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;.cache/&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;# My custom files for practicing&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;*.arv&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;arv.*&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Differences between &lt;code&gt;.gitignore&lt;/code&gt; and &lt;code&gt;.dockerignore&lt;/code&gt;&lt;/h3&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Aspect&lt;/th&gt;
&lt;th&gt;&lt;code&gt;.gitignore&lt;/code&gt;&lt;/th&gt;
&lt;th&gt;&lt;code&gt;.dockerignore&lt;/code&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Purpose&lt;/td&gt;
&lt;td&gt;Specifies files to ignore in Git&lt;/td&gt;
&lt;td&gt;Specifies files to exclude in Docker image builds&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Associated tool&lt;/td&gt;
&lt;td&gt;Git&lt;/td&gt;
&lt;td&gt;Docker&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;File behavior&lt;/td&gt;
&lt;td&gt;Excludes files in Git operations&lt;/td&gt;
&lt;td&gt;Excludes files during image build&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Impact&lt;/td&gt;
&lt;td&gt;Affects version control only&lt;/td&gt;
&lt;td&gt;Affects image build process&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Use case&lt;/td&gt;
&lt;td&gt;Manages repository content&lt;/td&gt;
&lt;td&gt;Manages files in Docker context&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Ignoring patterns&lt;/td&gt;
&lt;td&gt;Glob patterns, file names&lt;/td&gt;
&lt;td&gt;Glob patterns, file names&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;code&gt;.gitignore&lt;/code&gt; and &lt;code&gt;.dockerignore&lt;/code&gt; serve different purposes despite their similar naming conventions. While both control
what files should be ignored/excluded, &lt;code&gt;.gitignore&lt;/code&gt; operates within version control systems, allowing certain files not
to be tracked. Conversely, &lt;code&gt;.dockerignore&lt;/code&gt; is used during image building to exclude unnecessary files from the Docker
context sent to the daemon, optimizing the image build process.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Both files use similar syntax (like glob patterns) to specify what should be ignored, but their impact and contexts in
which they&apos;re utilized differ significantly.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Doubts&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;How to write &lt;code&gt;Dockerfile&lt;/code&gt; efficiently?&lt;/li&gt;
&lt;li&gt;How to use &lt;code&gt;.dockerignore&lt;/code&gt;?&lt;/li&gt;
&lt;li&gt;How to run two apps with one &lt;code&gt;Dockerfile&lt;/code&gt;?&lt;/li&gt;
&lt;li&gt;How to integrate Environment Variables in Docker and Python project?&lt;/li&gt;
&lt;li&gt;Learn about Python images present on Docker like &lt;code&gt;slim&lt;/code&gt;, &lt;code&gt;alpine&lt;/code&gt;, &lt;code&gt;bookworm&lt;/code&gt;, etc.&lt;/li&gt;
&lt;li&gt;How to run multiple apps like FastAPI and Streamlit in one go?&lt;/li&gt;
&lt;li&gt;How do I integrate MongoDB image in my Python project?&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>blog</category><category>mlops</category><author>Anshul Raj Verma</author></item><item><title>Learn FastAPI</title><link>https://arv-anshul.github.io/blog/2024/learn-fastapi</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/learn-fastapi</guid><description>Learn FastAPI framework from basic to advance with free tutorials and official docs.</description><pubDate>Sun, 17 Mar 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;&lt;em&gt;A better framework than Flask&lt;/em&gt;. Get production-ready code and API. With automatic interactive documentation. Based on
(and fully compatible with) the open standards for APIs: &lt;a href=&quot;https://github.com/OAI/OpenAPI-Specification&quot;&gt;OpenAPI&lt;/a&gt;
(previously known as Swagger) and &lt;a href=&quot;https://json-schema.org/&quot;&gt;JSON Schema&lt;/a&gt;.&lt;/p&gt;
&lt;h2&gt;Features&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Automatic docs:&lt;/strong&gt; Generate documentation for your API automatically.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Swagger UI:&lt;/strong&gt; Interactive exploration, call and test your API directly from the browser.&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;http://localhost:8000/docs&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Redoc:&lt;/strong&gt; Read only documentation. You can also download this doc.&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;http://localhost:8000/redoc&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Response Validation:&lt;/strong&gt; Use &lt;a href=&quot;https://pydantic-docs.helpmanual.io/&quot;&gt;pydantic&lt;/a&gt; &lt;code&gt;BaseModel&lt;/code&gt; as TypeHint in Python which
automatically validate your responses.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Starlette Features:&lt;/strong&gt; &lt;code&gt;FastAPI&lt;/code&gt; is actually a sub-class of &lt;code&gt;Starlette&lt;/code&gt;.With &lt;strong&gt;FastAPI&lt;/strong&gt; you get all of
&lt;strong&gt;Starlette&lt;/strong&gt;&apos;s features (as FastAPI is just Starlette on steroids):&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Seriously impressive performance. It is
&lt;a href=&quot;https://github.com/encode/starlette#performance&quot;&gt;one of the fastest Python frameworks available, on par with &lt;strong&gt;NodeJS&lt;/strong&gt; and &lt;strong&gt;Go&lt;/strong&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;WebSocket&lt;/strong&gt; support.&lt;/li&gt;
&lt;li&gt;In-process background tasks.&lt;/li&gt;
&lt;li&gt;Startup and shutdown events.&lt;/li&gt;
&lt;li&gt;Test client built on HTTPX.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;CORS&lt;/strong&gt;, GZip, Static Files, Streaming responses.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Session and Cookie&lt;/strong&gt; support.&lt;/li&gt;
&lt;li&gt;100% test coverage.&lt;/li&gt;
&lt;li&gt;100% type annotated codebase.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Supports Asynchronous programming.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Important Links To Learn FastAPI&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;FastAPI Tutorials&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=GN6ICac3OXY&quot;&gt;Amigoscode&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=SORiTsvnU28&quot;&gt;ArjanCodes&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=7t2alSnE2-I&quot;&gt;Bitfumes&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=52c7Kxp_14E&quot;&gt;CodeWithHarry&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=52c7Kxp_14E&quot;&gt;CodeWithHarry - Tutorial Uses Some of the Classes&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Asynchronous Programming Tutorials&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=GpqAQxH1Afc&quot;&gt;ArjanCode - 1&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=2IW-ZEui4h4&quot;&gt;ArjanCode - 2&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=6RbJYN7SoRs&quot;&gt;NeuralNine&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=mrtsk9B9_Ho&quot;&gt;NeuralNine - Requests Library&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Some Advice On FastAPI&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Use &lt;code&gt;fastapi.APIRouter&lt;/code&gt; to separate out different API paths. See mine
&lt;a href=&quot;https://github.com/arv-anshul/ecommerce-scrapper-api/tree/main/ecommerce/api/routes&quot;&gt;@arv-anshul/ecommerce-scrapper-api&lt;/a&gt;
project for example.&lt;/li&gt;
&lt;li&gt;If you don&apos;t know, check the &lt;em&gt;&quot;In a hurry?&quot;&lt;/em&gt; section about
&lt;a href=&quot;https://fastapi.tiangolo.com/async/#in-a-hurry&quot;&gt;&lt;code&gt;async&lt;/code&gt; and &lt;code&gt;await&lt;/code&gt; in the docs&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Learn &lt;em&gt;builtin&lt;/em&gt; &lt;code&gt;asyncio&lt;/code&gt; module in python to do Asynchronous Programming in python. See mine
&lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history/tree/main/backend/api/routes&quot;&gt;@arv-anshul/yt-watch-history&lt;/a&gt; project
for example.&lt;/li&gt;
&lt;li&gt;Use &lt;a href=&quot;https://docs.pydantic.dev/latest/&quot;&gt;pydantic&lt;/a&gt; with FastAPI for data handling of APIs. See this
&lt;a href=&quot;https://fastapi.tiangolo.com/features/?h=pydantic#pydantic-features&quot;&gt;docs section&lt;/a&gt; to know more about Pydantic and
FastAPI compatiblity.&lt;/li&gt;
&lt;li&gt;You can use the &lt;a href=&quot;https://fastapi.tiangolo.com/reference/testclient/&quot;&gt;&lt;code&gt;fastapi.testclient.TestClient&lt;/code&gt;&lt;/a&gt; class to test
FastAPI applications without creating an actual HTTP and socket connection, just communicating directly with the
FastAPI code. Read more about it in the
&lt;a href=&quot;https://fastapi.tiangolo.com/tutorial/testing/&quot;&gt;FastAPI docs for Testing - Tutorial&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;There are many other advance concepts in API world and some of them are Middleware, Dependency Injection, CORS, etc.
For that see the &lt;a href=&quot;https://fastapi.tiangolo.com/tutorial/&quot;&gt;FastAPI docs&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Extra Links around FastAPI&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://stackoverflow.com/questions/64943693/what-are-the-best-practices-for-structuring-a-fastapi-project&quot;&gt;What are the best practices for structuring a FastAPI project? - Stack Overflow&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://fastapi.tiangolo.com/advanced/&quot;&gt;Advanced User Guide - FastAPI&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://fastapi.tiangolo.com/advanced/custom-response/&quot;&gt;Custom Response - HTML, Stream, File, others - FastAPI&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>others</category><author>Anshul Raj Verma</author></item><item><title>Handle Outliers - Univariate</title><link>https://arv-anshul.github.io/blog/2024/outlier-univariate</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/outlier-univariate</guid><description>Learn how to handle outlier using various univariate methods.</description><pubDate>Sun, 17 Mar 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Handling outlier is a big task for data scientist. To handle the outliers we have many different methods to handle them
&lt;strong&gt;i.e. IQR, Z-score, Mean-Median Imputation, Winsorization, etc&lt;/strong&gt;. We are going to discuss only univariate methods to
handle outliers.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;:calendar: I have written this page as notes very time ago; so if there is any mistake please let me know I&apos;ll fix it.
Thanks 🤗&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Deletion Based Approach&lt;/h2&gt;
&lt;h3&gt;IQR&lt;/h3&gt;
&lt;p&gt;In this method by using Inter Quartile Range(IQR), we detect outliers. IQR tells us the variation in the data set. Any
value, which is beyond the range of &lt;code&gt;#!math -1.5 \ast IQR&lt;/code&gt; to &lt;code&gt;#!math 1.5 \ast IQR&lt;/code&gt; treated as outliers.&lt;/p&gt;
&lt;p&gt;The concept of quartiles and IQR can best be visualized from the boxplot. It has the minimum and maximum point defined
as &lt;code&gt;#!math Q1 - 1.5 \ast IQR&lt;/code&gt; and &lt;code&gt;#!math Q3 + 1.5 \ast IQR&lt;/code&gt; respectively. Any point outside this range is outlier.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!CAUTION] Cons&lt;/p&gt;
&lt;p&gt;It delete your many data point because even if there is only one data point in a row is act as outlier for their
respective column then the row is being removed which means to remove one outlier you removed many essential data
point from your dataset.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; pandas &lt;/span&gt;&lt;span&gt;as&lt;/span&gt;&lt;span&gt; pd&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;def&lt;/span&gt;&lt;span&gt; apply_iqr_deletion&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;df&lt;/span&gt;&lt;span&gt;: pd.DataFrame, &lt;/span&gt;&lt;span&gt;columns&lt;/span&gt;&lt;span&gt;: list[&lt;/span&gt;&lt;span&gt;str&lt;/span&gt;&lt;span&gt;], *&lt;/span&gt;&lt;span&gt;tiles&lt;/span&gt;&lt;span&gt;: tuple[&lt;/span&gt;&lt;span&gt;float&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;float&lt;/span&gt;&lt;span&gt;]):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    &quot;&quot;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Deletes outliers from given columns which are out of range of minimum and maximum percentile values.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Parameters&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    ----------&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    df: pd.DataFrame&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        DataFrame to be cleaned.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    columns: list[str]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        List of columns to be cleaned.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    *tiles: tuple[float, float]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        Tuples of (minimum percentile, maximum percentile) for each column.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Returns&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    -------&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    DataFrame with deleted outliers data points.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Raises&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    ------&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    ValueError: If `len(columns) != len(tiles)`.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    &quot;&quot;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;	if&lt;/span&gt;&lt;span&gt; len&lt;/span&gt;&lt;span&gt;(columns) != &lt;/span&gt;&lt;span&gt;len&lt;/span&gt;&lt;span&gt;(tiles):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;		raise&lt;/span&gt;&lt;span&gt; ValueError&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;&apos;len(columns) != len(tiles)&apos;&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;	for&lt;/span&gt;&lt;span&gt; col, tile &lt;/span&gt;&lt;span&gt;in&lt;/span&gt;&lt;span&gt; zip&lt;/span&gt;&lt;span&gt;(columns, tiles):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;		mini, maxi = df[col].quantile[tile]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;		df = df[(df[col]&amp;gt;mini) &amp;amp; (df[col]&amp;lt;maxi)]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;	return&lt;/span&gt;&lt;span&gt; df&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;If you have less number of outliers in your data then apply &lt;code&gt;apply_iqr_deletion&lt;/code&gt; function but if you have many
outliers than a &lt;strong&gt;threshold value&lt;/strong&gt; then use &lt;code&gt;apply_iqr_capping&lt;/code&gt; function to cap the outliers within a range.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Z-Score&lt;/h3&gt;
&lt;p&gt;This method assumes that &lt;strong&gt;the variable has a Gaussian distribution&lt;/strong&gt;. It represents the number of standard deviations
an observation is away from the mean.&lt;/p&gt;
&lt;p&gt;In this method we calculate the z-score with &lt;code&gt;#!math Z = \frac{(x_i - \bar{x})}{\sigma}&lt;/code&gt; of the feature then set a
threshold (generally as ±3) then remove the data point which are &lt;code&gt;#!math \ge 3&lt;/code&gt; and &lt;code&gt;#!math \le -3&lt;/code&gt;.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!TIP]
You can also &lt;strong&gt;calculate absolute value of every z-score&lt;/strong&gt; then just one constraint is required as &lt;code&gt;#!math \ge 3&lt;/code&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;[!CAUTION] Cons&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;It deletes the rows which contains outlier which leads to data loss. And generally, losing the data is not good
because it creates bias in the model and you doesn&apos;t inference well.&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; numpy &lt;/span&gt;&lt;span&gt;as&lt;/span&gt;&lt;span&gt; np&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; pandas &lt;/span&gt;&lt;span&gt;as&lt;/span&gt;&lt;span&gt; pd&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;from&lt;/span&gt;&lt;span&gt; scipy &lt;/span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; stats&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;def&lt;/span&gt;&lt;span&gt; apply_zscore_deletion&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;df&lt;/span&gt;&lt;span&gt;: pd.DataFrame, &lt;/span&gt;&lt;span&gt;columns&lt;/span&gt;&lt;span&gt;: List[&lt;/span&gt;&lt;span&gt;str&lt;/span&gt;&lt;span&gt;], &lt;/span&gt;&lt;span&gt;threshold&lt;/span&gt;&lt;span&gt;: &lt;/span&gt;&lt;span&gt;float&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;3.0&lt;/span&gt;&lt;span&gt;) -&amp;gt; pd.DataFrame:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    &quot;&quot;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Deletes outliers from given columns using z-score method.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Args:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        df: pd.DataFrame&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            DataFrame to be cleaned.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        columns: List[str]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            List of columns to be cleaned.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        threshold: float&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            Threshold for z-score.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Returns:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        pd.DataFrame&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            DataFrame with deleted outliers data points.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    &quot;&quot;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    if&lt;/span&gt;&lt;span&gt; not&lt;/span&gt;&lt;span&gt; isinstance&lt;/span&gt;&lt;span&gt;(threshold, (&lt;/span&gt;&lt;span&gt;float&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;int&lt;/span&gt;&lt;span&gt;)):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        raise&lt;/span&gt;&lt;span&gt; TypeError&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;&quot;Threshold must be a float or integer value.&quot;&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    z_scores = np.abs(stats.zscore(df[columns]))&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    df = df[columns][z_scores &amp;lt;= threshold]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    return&lt;/span&gt;&lt;span&gt; df&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;It uses &lt;em&gt;mean and standard deviation&lt;/em&gt; of the population data which is generally not available so we need to &lt;strong&gt;apply
hypothesis testing&lt;/strong&gt; to ensure that sample mean and sample standard deviation is being used instead of population
parameters.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;[!WARNING] Doubt&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Why do we calculate Z-Score because it requires population standard deviation which is not available for every for
every datasets.&lt;/li&gt;
&lt;li&gt;We should use T-Score instead.&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Capping Based Approach&lt;/h2&gt;
&lt;h3&gt;Winsorization&lt;/h3&gt;
&lt;p&gt;It is a way to minimise the influence of outliers in your data by either:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Assigning the outlier a lower weight.&lt;/li&gt;
&lt;li&gt;Changing the value so that it is close to other values in the set.&lt;/li&gt;
&lt;/ul&gt;
&lt;blockquote&gt;
&lt;p&gt;[!TIP] Pros&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;It doesn&apos;t delete the rows where outliers lie instead it clip those outliers with your defined percentile values for
each column.&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;[!CAUTION] Cons&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;If there is many outlier values in the column/feature then after clipping the distribution of column/feature will
change.&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;import&lt;/span&gt;&lt;span&gt; pandas &lt;/span&gt;&lt;span&gt;as&lt;/span&gt;&lt;span&gt; pd&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;def&lt;/span&gt;&lt;span&gt; apply_winsorization&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;df&lt;/span&gt;&lt;span&gt;: pd.DataFrame, &lt;/span&gt;&lt;span&gt;columns&lt;/span&gt;&lt;span&gt;: list[&lt;/span&gt;&lt;span&gt;str&lt;/span&gt;&lt;span&gt;], *&lt;/span&gt;&lt;span&gt;tiles&lt;/span&gt;&lt;span&gt;: tuple[&lt;/span&gt;&lt;span&gt;float&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;float&lt;/span&gt;&lt;span&gt;]):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    &quot;&quot;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Caps outliers in given columns to the minimum and maximum percentile values.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Parameters&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    ----------&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    df: pd.DataFrame&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        DataFrame to be cleaned.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    columns: list[str]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        List of columns to be cleaned.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    *tiles: tuple[float, float]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        Tuples of (minimum percentile, maximum percentile) for each column.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Returns&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    -------&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    DataFrame with capped outliers data points.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    Raises&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    ------&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    ValueError: If `len(columns) != len(tiles)`.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    &quot;&quot;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    if&lt;/span&gt;&lt;span&gt; len&lt;/span&gt;&lt;span&gt;(columns) != &lt;/span&gt;&lt;span&gt;len&lt;/span&gt;&lt;span&gt;(tiles):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        raise&lt;/span&gt;&lt;span&gt; ValueError&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;&apos;len(columns) != len(tiles)&apos;&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    for&lt;/span&gt;&lt;span&gt; col, tile &lt;/span&gt;&lt;span&gt;in&lt;/span&gt;&lt;span&gt; zip&lt;/span&gt;&lt;span&gt;(columns, tiles):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        mini, maxi = df[col].quantile[tile]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        df[col] = df[col].clip(mini, maxi)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    return&lt;/span&gt;&lt;span&gt; df&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;Use this method because it uses capping technique to handle outliers.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h4&gt;Important Links&lt;/h4&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.analyticsvidhya.com/blog/2021/05/detecting-and-treating-outliers-treating-the-odd-one-out/&quot;&gt;Detecting and Treating Outliers | How to Handle Outliers&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://medium.com/@dilip.voleti/detect-and-remove-the-outliers-in-a-dataset-1398f4cc7b44&quot;&gt;Detect and Remove the Outliers in a Dataset | by Dilip Valeti | Medium&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>eda</category><author>Anshul Raj Verma</author></item><item><title>Regularization in ML</title><link>https://arv-anshul.github.io/blog/2024/regularization-in-ml</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/regularization-in-ml</guid><description>Regularization in ML essentially Lasso, Ridge and ElasticNet.</description><pubDate>Sun, 17 Mar 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Regularization is used to solve the problem of overfitting caused while training a ML model. In regularization, the
model is penalized for overfitting on train data means whenever model tries to predict on training data it add some
penalty to the loss function in term of coefficients of the model.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!WARNING] What is Overfitting?&lt;/p&gt;
&lt;p&gt;A ML model is said to be &lt;strong&gt;&quot;overfitting&quot;&lt;/strong&gt; when it performs well on training dataset, but the performance is
comparatively poor on the test/unseen dataset.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;[!WARNING] What is Underfitting?&lt;/p&gt;
&lt;p&gt;An ML model is said to &lt;strong&gt;&quot;Underfitting&quot;&lt;/strong&gt; when it does not performs well on both the train as well as test dataset.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Types of Regularization&lt;/h2&gt;
&lt;p&gt;There are three main type of regularization in ML:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;#l1-regularization-lasso&quot;&gt;L1 Regularization (Lasso)&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;#l2-regularization-ridge&quot;&gt;L2 Regularization (Ridge)&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;#elasticnet&quot;&gt;L1 + L2 Regularization (ElasticNet)&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;L2 Regularization (Ridge)&lt;/h3&gt;
&lt;p&gt;Ridge Regression is a technique used in regression analysis to tackle the problem of overfitting, particularly when
dealing with multiple correlated predictors or features. The L2 regularization technique, also known as Ridge
Regression, adds a penalty term to the standard linear regression equation, which helps to mitigate the effects of
multi-collinearity.&lt;/p&gt;
&lt;p&gt;The objective function for Ridge Regression is given by:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;\text&lt;/span&gt;&lt;span&gt;{minimize}&lt;/span&gt;&lt;span&gt;\left&lt;/span&gt;&lt;span&gt;( &lt;/span&gt;&lt;span&gt;\sum&lt;/span&gt;&lt;span&gt;_{i=1}^{n} &lt;/span&gt;&lt;span&gt;\left&lt;/span&gt;&lt;span&gt;( y_i - &lt;/span&gt;&lt;span&gt;\beta&lt;/span&gt;&lt;span&gt;_0 - &lt;/span&gt;&lt;span&gt;\sum&lt;/span&gt;&lt;span&gt;_{j=1}^{p} x_{ij}&lt;/span&gt;&lt;span&gt;\beta&lt;/span&gt;&lt;span&gt;_j &lt;/span&gt;&lt;span&gt;\right&lt;/span&gt;&lt;span&gt;)^2 + &lt;/span&gt;&lt;span&gt;\lambda&lt;/span&gt;&lt;span&gt; \sum&lt;/span&gt;&lt;span&gt;_{j=1}^{p} &lt;/span&gt;&lt;span&gt;\beta&lt;/span&gt;&lt;span&gt;_j^2 &lt;/span&gt;&lt;span&gt;\right&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Where:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;#!math (n)&lt;/code&gt; represents the number of data points.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (p)&lt;/code&gt; represents the number of predictors or features.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (x_{ij})&lt;/code&gt; denotes the value of the &lt;code&gt;#!math (j^{th})&lt;/code&gt; feature for the &lt;code&gt;#!math (i^{th})&lt;/code&gt; data point.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (y_i)&lt;/code&gt; represents the observed output for the &lt;code&gt;#!math (i^{th})&lt;/code&gt; data point.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (\beta_0, \beta_1, \beta_2, \dots, \beta_p)&lt;/code&gt; are the regression coefficients.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (\lambda)&lt;/code&gt; is the hyperparameter that controls the regularization strength.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The first part of the equation is the &lt;strong&gt;standard least squares regression term&lt;/strong&gt;, which aims to minimize the squared
difference between the predicted and actual output. The second part is the penalty term, which is the sum of squares of
the coefficients &lt;code&gt;#!math (\beta)&lt;/code&gt; multiplied by the regularization parameter &lt;code&gt;#!math (\lambda)&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;The hyperparameter &lt;code&gt;#!math (\lambda)&lt;/code&gt; controls the trade-off between fitting the model to the training data and
preventing overfitting by keeping the coefficients small. A larger &lt;code&gt;#!math (\lambda)&lt;/code&gt; leads to a stronger penalty,
effectively shrinking the coefficients toward zero. This helps to reduce the model&apos;s complexity, making it less
sensitive to the noise in the data.&lt;/p&gt;
&lt;p&gt;Ridge Regression is a powerful tool in situations where multi-collinearity among predictors exists. By adding this
penalty term, it stabilizes the coefficients and reduces their variance, thus improving the model&apos;s generalization and
robustness when dealing with new, unseen data.&lt;/p&gt;
&lt;p&gt;Implementing Ridge Regression involves finding the optimal values for the coefficients by minimizing the combined error
and penalty term. Various optimization algorithms such as gradient descent or closed-form solutions can be employed for
this purpose.&lt;/p&gt;
&lt;p&gt;In conclusion, Ridge Regression with L2 regularization offers a balance between fitting the data and preventing
overfitting, making it a valuable technique in the realm of regression analysis.&lt;/p&gt;
&lt;h3&gt;L1 Regularization (Lasso)&lt;/h3&gt;
&lt;p&gt;Lasso Regression, short for &quot;Least Absolute Shrinkage and Selection Operator,&quot; is a method used in regression analysis
to handle overfitting and perform feature selection by adding a penalty term to the standard linear regression equation.
The L1 regularization technique in Lasso Regression introduces sparsity by imposing a penalty based on the absolute
values of the regression coefficients.&lt;/p&gt;
&lt;p&gt;The objective function for Lasso Regression is given by:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;\text&lt;/span&gt;&lt;span&gt;{minimize}&lt;/span&gt;&lt;span&gt;\left&lt;/span&gt;&lt;span&gt;( &lt;/span&gt;&lt;span&gt;\sum&lt;/span&gt;&lt;span&gt;_{i=1}^{n} &lt;/span&gt;&lt;span&gt;\left&lt;/span&gt;&lt;span&gt;( y_i - &lt;/span&gt;&lt;span&gt;\beta&lt;/span&gt;&lt;span&gt;_0 - &lt;/span&gt;&lt;span&gt;\sum&lt;/span&gt;&lt;span&gt;_{j=1}^{p} x_{ij}&lt;/span&gt;&lt;span&gt;\beta&lt;/span&gt;&lt;span&gt;_j &lt;/span&gt;&lt;span&gt;\right&lt;/span&gt;&lt;span&gt;)^2 + &lt;/span&gt;&lt;span&gt;\lambda&lt;/span&gt;&lt;span&gt; \sum&lt;/span&gt;&lt;span&gt;_{j=1}^{p} |&lt;/span&gt;&lt;span&gt;\beta&lt;/span&gt;&lt;span&gt;_j| &lt;/span&gt;&lt;span&gt;\right&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Where:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;#!math (n)&lt;/code&gt; represents the number of data points.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (p)&lt;/code&gt; represents the number of predictors or features.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (x_{ij})&lt;/code&gt; denotes the value of the &lt;code&gt;#!math (j^{th})&lt;/code&gt; feature for the &lt;code&gt;#!math (i^{th})&lt;/code&gt; data point.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (y_i)&lt;/code&gt; represents the observed output for the &lt;code&gt;#!math (i^{th})&lt;/code&gt; data point.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (\beta_0, \beta_1, \beta_2, \dots, \beta_p)&lt;/code&gt; are the regression coefficients.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (\lambda)&lt;/code&gt; is the hyperparameter that controls the regularization strength.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The first part of the equation is the standard least squares regression term that minimizes the squared difference
between the predicted and actual output. The second part is the penalty term, which is the sum of the absolute values of
the coefficients &lt;code&gt;#!math (\beta)&lt;/code&gt; multiplied by the regularization parameter &lt;code&gt;#!math (\lambda)&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;The hyperparameter &lt;code&gt;#!math (\lambda)&lt;/code&gt; controls the trade-off between fitting the model to the training data and keeping
the coefficients small. In Lasso Regression, the absolute value of the coefficients&apos; sum is used as the penalty. This
has the effect of forcing some coefficients to be exactly zero, effectively performing variable selection by eliminating
less influential features. The sparsity induced by L1 regularization makes Lasso Regression particularly useful when
dealing with datasets with a large number of features, as it can automatically perform feature selection.&lt;/p&gt;
&lt;p&gt;Implementing Lasso Regression involves finding the optimal values for the coefficients by minimizing the combined error
and penalty term. Various optimization techniques like coordinate descent or sub-gradient methods can be employed to
achieve this.&lt;/p&gt;
&lt;p&gt;In conclusion, Lasso Regression with L1 regularization is a valuable tool for not only preventing overfitting but also
performing automatic feature selection by shrinking certain coefficients to zero. This makes it a popular choice when
dealing with high-dimensional datasets and seeking a more interpretable and sparse model.&lt;/p&gt;
&lt;h3&gt;ElasticNet&lt;/h3&gt;
&lt;p&gt;This is the combination of both L1 and L2 regularization.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;\text&lt;/span&gt;&lt;span&gt;{minimize}&lt;/span&gt;&lt;span&gt;\left&lt;/span&gt;&lt;span&gt;( &lt;/span&gt;&lt;span&gt;\sum&lt;/span&gt;&lt;span&gt;_{i=1}^{n} &lt;/span&gt;&lt;span&gt;\left&lt;/span&gt;&lt;span&gt;( y_i - &lt;/span&gt;&lt;span&gt;\beta&lt;/span&gt;&lt;span&gt;_0 - &lt;/span&gt;&lt;span&gt;\sum&lt;/span&gt;&lt;span&gt;_{j=1}^{p} x_{ij}&lt;/span&gt;&lt;span&gt;\beta&lt;/span&gt;&lt;span&gt;_j &lt;/span&gt;&lt;span&gt;\right&lt;/span&gt;&lt;span&gt;)^2 + &lt;/span&gt;&lt;span&gt;\lambda&lt;/span&gt;&lt;span&gt;_1 &lt;/span&gt;&lt;span&gt;\sum&lt;/span&gt;&lt;span&gt;_{j=1}^{p} |&lt;/span&gt;&lt;span&gt;\beta&lt;/span&gt;&lt;span&gt;_j| + &lt;/span&gt;&lt;span&gt;\lambda&lt;/span&gt;&lt;span&gt;_2 &lt;/span&gt;&lt;span&gt;\sum&lt;/span&gt;&lt;span&gt;_{j=1}^{p} &lt;/span&gt;&lt;span&gt;\beta&lt;/span&gt;&lt;span&gt;_j^2 &lt;/span&gt;&lt;span&gt;\right&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Resources&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://medium.com/analytics-vidhya/regularisation-techniques-in-machine-learning-and-deep-learning-8102312e1ef3&quot;&gt;Regularization Techniques&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://youtube.com/@campusx-official&quot;&gt;CampusX YouTube&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>ml</category><author>Anshul Raj Verma</author></item><item><title>Regression Interview Questions</title><link>https://arv-anshul.github.io/blog/2024/regression-interview-quesitons</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/regression-interview-quesitons</guid><description>Some important Interview Questions on Regression Algorithms.</description><pubDate>Tue, 12 Mar 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;In an interview, questions around regression model is very prominent. So, let&apos;s study some interview questions around
it.&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;https://media.geeksforgeeks.org/wp-content/uploads/20241025105428904464/Assumptions-of-Linear-Regression.webp&quot; alt=&quot;assumptions-of-linear-regression&quot; /&gt;&lt;/p&gt;
&lt;h2&gt;Assumptions of Linear Regression?&lt;/h2&gt;
&lt;p&gt;There are about 5 main assumption while training a Linear Regression Model which are:&lt;/p&gt;
&lt;h3&gt;1. Linear Relationship Between Input And Output Data&lt;/h3&gt;
&lt;p&gt;Relationship of every input feature must be &lt;strong&gt;linear&lt;/strong&gt; with output feature.&lt;/p&gt;
&lt;h3&gt;2. Multi-Collinearity&lt;/h3&gt;
&lt;blockquote&gt;
&lt;p&gt;[!WARNING] What is Multi-Collinearity?&lt;/p&gt;
&lt;p&gt;Multicollinearity is a phenomena where two or more independent variables are highly correlated. In other words, one
predictor variable can be used to predict the value of another. This creates redundant information, skewing the
results in a regression model.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Input data must not correalate with each other, they must be independent of each other. One can use &lt;strong&gt;VIF&lt;/strong&gt;{
title=&quot;Variance Inflation Factor&quot; } or correlation matrices to know whether their input data is correlated.&lt;/p&gt;
&lt;p&gt;See &lt;a href=&quot;#why-multi-collinearity-is-a-problem&quot;&gt;this section&lt;/a&gt; for better explanation.&lt;/p&gt;
&lt;h3&gt;3. Normally Distributed Residuals&lt;/h3&gt;
&lt;blockquote&gt;
&lt;p&gt;[!WARNING] What are Residuals?&lt;/p&gt;
&lt;p&gt;Represent the vertical distance between a data point and the regression line. They are the errors of the model which
the model can&apos;t able to capture while training.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;The distribution of the residuals must be normally distributed. One can analyse this using &lt;strong&gt;KDE&lt;/strong&gt; (Kernel Density
Estimator Function) or &lt;a href=&quot;https://library.virginia.edu/data/articles/understanding-q-q-plots&quot;&gt;QQ-Plot&lt;/a&gt;.&lt;/p&gt;
&lt;h3&gt;4. Homoscedacity&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Homoscedasticity&lt;/strong&gt; refers to constant variance in a regression model&apos;s residuals. &lt;em&gt;Cons&lt;/em&gt; include potential bias and
inefficiency. Visualize homoscedasticity using scatter plots — residuals vs. predicted values should show an even
spread, indicating consistent variance. In Python, seaborn or matplotlib can create such plots for regression
diagnostics.&lt;/p&gt;
&lt;h3&gt;5. No Auto-Correlation Of Error&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Autocorrelation of errors&lt;/strong&gt; in regression models refers to the correlation between the error terms at different time
points or observations. Positive autocorrelation indicates that errors in one period are correlated with errors in
previous periods. This violates the assumption of independence, impacting model reliability. Diagnostic plots or
statistical tests, like the Durbin-Watson test, can assess autocorrelation in regression residuals.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!INFO] Resources&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=EmSNAtcHLm8&quot;&gt;What are the main Assumptions of Linear Regression? | Top 5 Assumptions of Linear Regression&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/campusx-official/linear-regression-assumptions&quot;&gt;Presented all 5 assumptions in Notebook&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Why multi-collinearity is a problem?&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Multicollinearity&lt;/strong&gt; occurs when two or more independent variables in a regression model are highly correlated. ^^It is
bad^^ because it inflates standard errors, leading to unstable and unreliable coefficients. This makes it difficult to
isolate the individual effect of each variable, reducing the model&apos;s interpretability and predictive accuracy.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Detection&lt;/strong&gt;: Use correlation matrices or variance inflation factor (VIF). High correlation coefficients or VIF values
(&amp;gt;5) indicate multicollinearity.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Removal&lt;/strong&gt;: Options include excluding one of the correlated variables, combining them, or using regularization
techniques like Ridge/Lasso regression that penalize large coefficients.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!INFO] Resources&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://www.youtube.com/watch?v=sVJW5UXe84s&quot;&gt;Why Multicollinearity is Bad? What is Multicollinearity? How to detect and remove Multicollinearity&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Difference b/w &quot;Person Correlation&quot; and Multi-collinearity.&lt;/h2&gt;
&lt;p&gt;The main difference between Pearson Correlation and Multicollinearity lies in their applications within regression
analysis.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Pearson Correlation&lt;/strong&gt; is a measure of the linear relationship between two numerical variables, ranging from -1 to 1,
where 0 indicates no correlation and values close to 1 or -1 indicate a strong linear relationship&lt;/p&gt;
&lt;p&gt;On the other hand, &lt;strong&gt;Multicollinearity&lt;/strong&gt; refers to a situation where independent variables in a regression model are
highly correlated with each other, which can lead to issues such as inflated coefficients and weakened statistical
measures like p-values&lt;/p&gt;
&lt;p&gt;While ^^Pearson Correlation focuses on the relationship between two variables, Multicollinearity deals with the
interplay among multiple independent variables in a regression context^^, impacting the model&apos;s interpretability and
reliability.&lt;/p&gt;
&lt;h2&gt;What is VIF? Why VIF &amp;gt; 5?&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;VIF&lt;/strong&gt; &lt;em&gt;(Variance Inflation Factor)&lt;/em&gt; is a measure that quantifies how much the variance of an estimated regression
coefficient increases if your predictors are correlated. A VIF greater than 5 or 10 is often considered indicative of
multicollinearity.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;VIF &amp;gt; 5&lt;/strong&gt; suggests that the variance of the coefficient estimate is 5 times higher due to multicollinearity, making
the estimate less reliable and harder to interpret.&lt;/p&gt;
&lt;p&gt;Use VIF in python as &lt;code&gt;from statsmodels.stats.outliers_influence import variance_inflation_factor&lt;/code&gt;.&lt;/p&gt;
&lt;h2&gt;What is R-squared (R²/R2) score?&lt;/h2&gt;
&lt;p&gt;R-Squared (R²) is a statistical measure used to determine the proportion of variance in a dependent variable that can be
predicted or explained by an independent variable.&lt;/p&gt;
&lt;p&gt;In other words, R-Squared shows how well a regression model (independent variable) predicts the outcome of observed data
(dependent variable).&lt;/p&gt;
&lt;p&gt;R-Squared is also commonly known as the coefficient of determination. It is a goodness of fit model for linear
regression analysis. &lt;a href=&quot;https://www.freecodecamp.org/news/what-is-r-squared-r2-value-meaning-and-definition/&quot;&gt;Copied From&lt;/a&gt;&lt;/p&gt;
&lt;h3&gt;What Does an R Squared Value Mean?&lt;/h3&gt;
&lt;p&gt;A R-Squared value shows how well the model predicts the outcome of the dependent variable. R-Squared values range from 0
to 1.&lt;/p&gt;
&lt;p&gt;An R-Squared &lt;strong&gt;value of 0 means that the model explains or predicts 0% of the relationship&lt;/strong&gt; between the dependent and
independent variables. And a &lt;strong&gt;value of 1 indicates that the model predicts 100% of the relationship&lt;/strong&gt;, and a &lt;strong&gt;value of
0.5 indicates that the model predicts 50%&lt;/strong&gt;, and so on.&lt;/p&gt;
&lt;h3&gt;Formula for R Squared&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;\text&lt;/span&gt;&lt;span&gt;{R}^2 = 1 - &lt;/span&gt;&lt;span&gt;\frac&lt;/span&gt;&lt;span&gt;{&lt;/span&gt;&lt;span&gt;\text&lt;/span&gt;&lt;span&gt;{RSS}}{&lt;/span&gt;&lt;span&gt;\text&lt;/span&gt;&lt;span&gt;{TSS}}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Symbol&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;#!math \text{R}^2&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Coefficient of determination&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;#!math \text{RSS}&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Sum of squares of residuals&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;#!math \text{TSS}&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Total sum of squares&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;blockquote&gt;
&lt;p&gt;[!INFO] Resources&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.freecodecamp.org/news/what-is-r-squared-r2-value-meaning-and-definition/&quot;&gt;What is R Squared? R2 Value Meaning and Definition&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;h2&gt;How is Adjusted R2 score is different from R2 score?&lt;/h2&gt;
&lt;p&gt;Adjusted R2 score is different from R2 score in the way they handle the addition of new predictors to a multiple
regression model.&lt;/p&gt;
&lt;p&gt;While R2 score increases or remains the same as new predictors are added to the model, even if the newly added
predictors are independent of the target variable and don&apos;t add any value to the predicting power of the model.&lt;/p&gt;
&lt;p&gt;On the other hand, &lt;strong&gt;Adjusted R2 score only increases if the newly added predictor improves the model&apos;s predicting
power&lt;/strong&gt;. It helps determine the goodness of fit for a multiple regression model by considering the number of predictors
and the sample size. &lt;strong&gt;Adjusted R2 penalizes the model for useless variables, while R2 does not&lt;/strong&gt;, making Adjusted R2 a
more reliable measure of goodness of fit for multiple regression problems.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!INFO] Resources&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://builtin.com/data-science/adjusted-r-squared&quot;&gt;Demystifying R-Squared and Adjusted R-Squared&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;h2&gt;What-if there is one feature related to another then, what should we do with them?&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Keep any one of them after checking the correlation with target feature &lt;code&gt;#!math (y)&lt;/code&gt; whichever has low correlation;
drop them and keep only one.&lt;/li&gt;
&lt;li&gt;Use &lt;a href=&quot;https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.PCA.html&quot;&gt;&lt;code&gt;sklearn.decomposition.PCA&lt;/code&gt;&lt;/a&gt;
(with
&lt;a href=&quot;https://scikit-learn.org/stable/modules/generated/sklearn.compose.ColumnTransformer.html&quot;&gt;&lt;code&gt;sklearn.compose.ColumnTransformer&lt;/code&gt;&lt;/a&gt;)
to combine them as one and use that transformed column.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;What is Regularization? - Why to use Regularization? - What happen in Regularization?&lt;/h2&gt;
&lt;p&gt;You can use regularization to penalize the model while trining when mode is trying to overfit with training data.
Generally, there are three main types of regularization is used L1 (Lasso), L2 (Ridge) and (L1 + L2) ElasticNet.&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;regression-interview-quesitons.md&quot;&gt;My blog on Regularization&lt;/a&gt;&lt;/p&gt;
</content:encoded><category>blog</category><category>ml</category><category>interview-questions</category><author>Anshul Raj Verma</author></item><item><title>March Journal</title><link>https://arv-anshul.github.io/journal/2024/03</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/03</guid><description>Weekly Journal by ARV of March 2024</description><pubDate>Fri, 01 Mar 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 10 Journal&lt;/h2&gt;
&lt;p&gt;❌ No extra learnings. See &lt;a href=&quot;02.md#week-10-journal&quot;&gt;2024 February&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;Week 11 Journal&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://zed.dev&quot;&gt;Zed&lt;/a&gt;: Tried Zed code editor and I feel promising to adapt.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/dotfiles&quot;&gt;arv-anshul/dotfiles&lt;/a&gt;: Updated &lt;code&gt;dotfiles&lt;/code&gt;, inspired by &lt;a href=&quot;https://github.com/CoreyMSchafer/dotfiles&quot;&gt;corey/dotfiles&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://brew.sh&quot;&gt;brew&lt;/a&gt;: Learned some new things in &lt;code&gt;brew&lt;/code&gt; cli.
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;brew autoremove&lt;/code&gt;: Uninstall formulae that were only installed as a dependency of another formula and are now no
longer needed.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;brew deps&lt;/code&gt;: Show dependencies for formula. When given multiple formula arguments, show the intersection of
dependencies for each formula. By default, deps shows all required and recommended dependencies.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/family-tree&quot;&gt;family-tree&lt;/a&gt;: New project to &quot;Create family tree using python and export it as JSON or mermaid format&quot;. Written
tests too.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/md-badges&quot;&gt;md-badges&lt;/a&gt;: &lt;strong&gt;CANCELLED&lt;/strong&gt; A CLI tool to query &lt;a href=&quot;https://shields.io&quot;&gt;shields.io&lt;/a&gt; badges simpleicons in a batch.
&lt;ul&gt;
&lt;li&gt;I find it hard and irritating to query each badge on &lt;a href=&quot;https://badges.pages.dev/&quot;&gt;badges.pages.dev&lt;/a&gt; website. I want
to query/select all required badges at once.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Schema Writting for JSON&lt;/strong&gt;:
&lt;ul&gt;
&lt;li&gt;Learned how to write schema for &lt;code&gt;json&lt;/code&gt;, &lt;code&gt;yaml&lt;/code&gt; and &lt;code&gt;toml&lt;/code&gt; files.&lt;/li&gt;
&lt;li&gt;Learning to define schema for the personal website&apos;s
&lt;a href=&quot;https://github.com/arv-anshul/arv-anshul.github.io/tree/main/docs/data/render_yaml&quot;&gt;&lt;code&gt;docs/data/render_yaml&lt;/code&gt;&lt;/a&gt;
folder&apos;s YAML files.&lt;/li&gt;
&lt;li&gt;Watched this video by &lt;strong&gt;NeuralNine&lt;/strong&gt;:
&lt;a href=&quot;https://www.youtube.com/watch?v=o3ViNZpTaKE&quot;&gt;JSON Schema Validation in Python: Bring Structure Into JSON&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Check the schemas: &lt;code&gt;projects_index-schema.json&lt;/code&gt; and &lt;code&gt;other_projects-schema.json&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/campusx&quot;&gt;arv-anshul/campusx&lt;/a&gt;:
&lt;ul&gt;
&lt;li&gt;Wrote python scripts to download course&apos;s resources from internet and store them in GitHub repo itself.&lt;/li&gt;
&lt;li&gt;Also added this project on &lt;a href=&quot;https://arv-anshul.github.io/projects/campusx&quot;&gt;website&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://zed.dev&quot;&gt;Zed&lt;/a&gt; code editor is just great and I want to use it full time but it lacks many features which are very heavy to
fulfil. I want features like 🥇 &lt;strong&gt;Extensions&lt;/strong&gt;, 🥈 &lt;strong&gt;Jupyter Notebook&lt;/strong&gt;, 🥉 &lt;strong&gt;Git SCM UI&lt;/strong&gt; and more.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/exelban/stats&quot;&gt;stats&lt;/a&gt;: Amazing app for MacOS which let you display your CPU, RAM, Network Usage, etc in menu bar. I knew about it
from a &lt;a href=&quot;https://youtu.be/GK7zLYAXdDs&quot;&gt;YouTube video&lt;/a&gt;. I have installed an app from App Store to display my Network
Usage in menu bar after a lot of searching on web.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/diary&quot;&gt;arv-anshul/diary&lt;/a&gt;: Cleaning of the diary.
&lt;ul&gt;
&lt;li&gt;Remove unnecessary files and notes.&lt;/li&gt;
&lt;li&gt;Combine the important one and publish them as blog on &lt;a href=&quot;https://arv-anshul.github.io&quot;&gt;arv-anshul.github.io&lt;/a&gt; like &lt;strong&gt;FastAPI&lt;/strong&gt; and &lt;strong&gt;Data Science&lt;/strong&gt;
notes.&lt;/li&gt;
&lt;li&gt;Write &amp;amp; Update conventions of every notes and create templates for them.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 12 Journal&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io&quot;&gt;arv-anshul.github.io&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;Update some componet&apos;s layouts of website i.e. Grid Cards, Code Blocks, Buttons.&lt;/li&gt;
&lt;li&gt;Also, figured-out how to integrate &lt;a href=&quot;https://devicon.dev&quot;&gt;devicons&lt;/a&gt; as like emoji.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/diary&quot;&gt;arv-anshul/diary&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;Migrate &lt;code&gt;diary&lt;/code&gt; notes as blog on website.&lt;/li&gt;
&lt;li&gt;Trying to drop &lt;a href=&quot;https://obsidian.md&quot;&gt;&lt;strong&gt;Obsidian&lt;/strong&gt;&lt;/a&gt; for my diary entry and want to use &lt;code&gt;mkdocs&lt;/code&gt; (with basic
functionalities) for dairy entry.&lt;/li&gt;
&lt;li&gt;Successfully migrated &lt;a href=&quot;https://github.com/arv-anshul/diary&quot;&gt;arv-anshul/diary&lt;/a&gt; from Obsidian to &lt;code&gt;mkdocs&lt;/code&gt;. Compare releases
&lt;a href=&quot;https://github.com/arv-anshul/diary/compare/v1.0.0...v1.1.0&quot;&gt;&lt;code&gt;v1.0.0...v1.1.0&lt;/code&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Wrote custom snippets for Dev Journal(s) and Thoughts entries in VSCode.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/campusx&quot;&gt;arv-anshul/campusx&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;Modified scripts to infer filename from response&apos;s headers. Filename is available in &lt;code&gt;&quot;content-disposition&quot;&lt;/code&gt;
headers key.&lt;/li&gt;
&lt;li&gt;See new &lt;a href=&quot;https://github.com/arv-anshul/campusx/releases/v0.8.0&quot;&gt;&quot;Release v0.8.0: Infer resources filename&quot;&lt;/a&gt; on
GitHub.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io/blog&quot;&gt;blog&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io/blog/tree-vs-regression-models&quot;&gt;Tree VS Regression Models&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;:question: &lt;strong&gt;Should I drop Obsidian for my diary entry?&lt;/strong&gt;
&lt;ul&gt;
&lt;li&gt;(NO) because Obsidian comes with many other functionalities like Canvas, Extensions, Templates.&lt;/li&gt;
&lt;li&gt;(NO) because Obsidian is made for managing notes and documents (which is a very big plus+ point).&lt;/li&gt;
&lt;li&gt;(YES) because &lt;code&gt;mkdocs&lt;/code&gt; will work as a website which you can make public (if you wish for).&lt;/li&gt;
&lt;li&gt;(YES) because you doesn&apos;t have to care about a separate app&apos;s constraints (&lt;code&gt;obsidian.app&lt;/code&gt;).&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://squidfunk.github.io/mkdocs-material/setup/setting-up-tags/&quot;&gt;Setting up tags - Material for MkDocs&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;Learn how to setup tags (as pro).&lt;/li&gt;
&lt;li&gt;Also, figure out how does &lt;code&gt;squidfunk&lt;/code&gt; render those &quot;versions&quot;, &quot;default values&quot;, &quot;sponsors only&quot; cool badges.&lt;/li&gt;
&lt;li&gt;Also see this &lt;a href=&quot;https://mkdocs-material.github.io/examples/tags/&quot;&gt;web page&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;There is an example for &lt;code&gt;tags&lt;/code&gt; plugin.&lt;/li&gt;
&lt;li&gt;Learn how did this works?&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://raycast.com&quot;&gt;raycast&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Amazing app for developers. Just use keyboard to perform all important tasks.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Best Features&lt;/strong&gt;: Floating Notes, Snippets, Keyboard Shortcuts, :tada: Confetti, Window Management, Shut Down&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Best Extensions&lt;/strong&gt;: Arc, Shell Command, Google Translate, Perplexity&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;I have created some snippets which helps me to write them very easily like:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;!gha&lt;/code&gt;: &lt;a href=&quot;https://github.com/arv-anshul&quot;&gt;https://github.com/arv-anshul&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;!web&lt;/code&gt;: &lt;a href=&quot;https://arv-anshul.github.io&quot;&gt;https://arv-anshul.github.io&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;!linkedin&lt;/code&gt;:&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;🔗 Github Profile: https://github.com/arv-anshul&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;🔗 Personal Projects: https://arv-anshul.github.io/projects&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;🔗 Website: https://arv-anshul.github.io&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;🔗 Blogs: https://arv-anshul.github.io/blog&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;🙏 Thank You!&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;:disappointed: But it takes too much memory approx. ~300MB in RAM.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 13 Journal&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://github.com/arv-anshul/pw-api&quot;&gt;pw-api&lt;/a&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The project doesn&apos;t works now due to some major changes in &lt;a href=&quot;https://pwskills.com&quot;&gt;pwskills.com&lt;/a&gt; website&apos;s APIs.&lt;/li&gt;
&lt;li&gt;Added a warning regarding this in &lt;a href=&quot;https://github.com/arv-anshul/pw-api#readme&quot;&gt;README.md&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://github.com/arv-anshul/notebooks/tree/main/spotify-analysis/pl-tracks-using-api.ipynb&quot;&gt;notebooks/spotify-analysis/pl-tracks-using-api.ipynb&lt;/a&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;I want to analyse the &lt;strong&gt;Golden Era 🎵&lt;/strong&gt; playlist by @Pushpam on Spotify. To reduce the tracks count because it
consists ~300 tracks.&lt;/li&gt;
&lt;li&gt;I&apos;ve used Spotify Web API to fetch data of the playlist.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Co-author a Git Commit&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;You can co-author a git commit by specifying the author name and email in commit body.&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;✨&lt;/span&gt;&lt;span&gt; Learn&lt;/span&gt;&lt;span&gt; commit&lt;/span&gt;&lt;span&gt; co-authoring&lt;/span&gt;&lt;span&gt;  # Commit message&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;Co-authored&lt;/span&gt;&lt;span&gt; by:&lt;/span&gt;&lt;span&gt; arv-anshul&lt;/span&gt;&lt;span&gt; &amp;lt;&lt;/span&gt;&lt;span&gt;arv.anshul.1864@gmail.co&lt;/span&gt;&lt;span&gt;m&amp;gt;  &lt;/span&gt;&lt;span&gt;# Specify who co-authored this&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href=&quot;https://arv-anshul.github.io/blog/hypothesis-testing-introduction&quot;&gt;blog/hypothesis-testing-introduction&lt;/a&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Published new blog on Hypothesis Testing.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://deeplearning.ai&quot;&gt;DeepLearning.ai&lt;/a&gt;
&lt;ul&gt;
&lt;li&gt;This website has some &lt;strong&gt;free short course around LLMs and GenAI&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;hr /&gt;
</content:encoded><category>journal</category><category>journal</category><category>march</category><author>Anshul Raj Verma</author></item><item><title>Spotify Analysis</title><link>https://arv-anshul.github.io/projects/spotify-analysis</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/spotify-analysis</guid><description>Analyze your Spotify Streaming data and get some insights from it like whom &amp; when you listen your favorite Tracks, Artists, Playlists or Albums.</description><pubDate>Thu, 22 Feb 2024 00:00:00 GMT</pubDate><content:encoded>&lt;blockquote&gt;
&lt;p&gt;[!NOTE] &lt;strong&gt;How to get your Spotify data?&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;You can request your Spotify data from &lt;a href=&quot;https://www.spotify.com/us/account/privacy/&quot;&gt;official website&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Know more about your personal data on
&lt;a href=&quot;https://support.spotify.com/us/article/data-rights-and-privacy-settings/&quot;&gt;Spotify&lt;/a&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&amp;lt;details&amp;gt;
&amp;lt;summary&amp;gt;Spotify data file structure&amp;lt;/summary&amp;gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;spotify-data&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; Read_Me_First.pdf&lt;/span&gt;&lt;span&gt;         # Introductory document&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; Follow.json&lt;/span&gt;&lt;span&gt;               # Data about user&apos;s followers&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; Identifiers.json&lt;/span&gt;&lt;span&gt;          # Identification information (🙅 Do Not Share!)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; Identity.json&lt;/span&gt;&lt;span&gt;             # User identity details (🙅 Do Not Share!)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; Inferences.json&lt;/span&gt;&lt;span&gt;           # Inferred data from user activity&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; Marquee.json&lt;/span&gt;&lt;span&gt;              # Marquee-related information&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; Payments.json&lt;/span&gt;&lt;span&gt;             # Payment details (🙅 Do Not Share!)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; Playlist1.json&lt;/span&gt;&lt;span&gt;            # Details about a specific playlist&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; SearchQueries.json&lt;/span&gt;&lt;span&gt;        # User&apos;s search queries&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; StreamingHistory0.json&lt;/span&gt;&lt;span&gt;    # User&apos;s Streaming history part 1&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; StreamingHistory1.json&lt;/span&gt;&lt;span&gt;    # User&apos;s Streaming history part 2&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;├──&lt;/span&gt;&lt;span&gt; Userdata.json&lt;/span&gt;&lt;span&gt;             # General user data (🙅 Do Not Share!)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;└──&lt;/span&gt;&lt;span&gt; YourLibrary.json&lt;/span&gt;&lt;span&gt;          # User&apos;s Spotify library details like likes, albums, artists, etc.&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;/details&amp;gt;&lt;/p&gt;
&lt;h2&gt;Philosophy&lt;/h2&gt;
&lt;p&gt;I want to analyze my Spotify&apos;s Streaming History in a way from which I can know my listening pattern over the time. The
way Spotify give the &lt;strong&gt;Spotify Wrapped&lt;/strong&gt; at the end of every year.&lt;/p&gt;
&lt;h3&gt;The Dashboard&lt;/h3&gt;
&lt;blockquote&gt;
&lt;p&gt;[!CAUTION] Currently not developed!&lt;/p&gt;
&lt;p&gt;If you want to join for this contact me on my socials &lt;a href=&quot;https://www.linkedin.com/in/arv-anshul&quot;&gt;LinkedIn&lt;/a&gt;
&lt;a href=&quot;mailto:arv.anshul.1864@gmail.com&quot;&gt;E-Mail&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;There has been a dashboard (using &lt;a href=&quot;https://streamlit.io&quot;&gt;Streamlit&lt;/a&gt;) where other users can upload their
&lt;code&gt;StreamingHistory.json&lt;/code&gt; files to see analysis on their history.&lt;/p&gt;
&lt;h2&gt;Some Awesome Insights&lt;/h2&gt;
&lt;p&gt;To gather insights from &lt;code&gt;json&lt;/code&gt; files I&apos;ve used &lt;a href=&quot;https://pola.rs&quot;&gt;&lt;code&gt;polars&lt;/code&gt;&lt;/a&gt; and their builtin &lt;code&gt;.plot&lt;/code&gt; accessor which uses
&lt;a href=&quot;https://hvplot.holoviz.org/&quot;&gt;&lt;code&gt;hvplot&lt;/code&gt;&lt;/a&gt; library under-the-hood.&lt;/p&gt;
&lt;p&gt;See the &lt;a href=&quot;https://github.com/arv-anshul/notebooks/tree/main/spotify-analysis&quot;&gt;Jupyter Notebooks&lt;/a&gt; to see all the insights.&lt;/p&gt;
&lt;p&gt;&amp;lt;details&amp;gt;
&amp;lt;summary&amp;gt;Reference&amp;lt;/summary&amp;gt;&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Short Code&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;T/A&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Track/Artist&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;T/As&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Track/Artist(s)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;P/A&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Playlist/Album&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;P/As&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Playlist/Album(s)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;These shortcodes used below for better readability.&lt;/p&gt;
&lt;p&gt;&amp;lt;/details&amp;gt;&lt;/p&gt;
&lt;h3&gt;Using &lt;code&gt;StreamingHistory.json&lt;/code&gt;&lt;/h3&gt;
&lt;p&gt;Contains &lt;strong&gt;User&apos;s Streaming History&lt;/strong&gt; with &lt;code&gt;trackName&lt;/code&gt; (Streaming Track Name), &lt;code&gt;artistName&lt;/code&gt; (Streaming Artist Name),
&lt;code&gt;msPlayed&lt;/code&gt; (Milliseconds Played) and &lt;code&gt;endTime&lt;/code&gt; (When the track ends (as datetime)).&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;[x] Top T/As in whole dataset.&lt;/li&gt;
&lt;li&gt;[x] Top T/As in each month.&lt;/li&gt;
&lt;li&gt;[x] Monthly most listened Tracks and Artists.&lt;/li&gt;
&lt;li&gt;[x] First day when T/A was played.&lt;/li&gt;
&lt;li&gt;[x] No. of distinct T/As listened in each month/year.&lt;/li&gt;
&lt;li&gt;[x] A T/A streaming in bar plot (which shows how you stream that during time-to-time).&lt;/li&gt;
&lt;li&gt;[x] Which daytime user listen most and whom.&lt;/li&gt;
&lt;li&gt;[x] Tracks which have listened most times in a day.&lt;/li&gt;
&lt;li&gt;[x] Tracks streaming streak (by day/week).&lt;/li&gt;
&lt;li&gt;[x] T/As which only played once&lt;/li&gt;
&lt;li&gt;[x] Dates when user does not played any track&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Using &lt;code&gt;Playlist.json&lt;/code&gt;&lt;/h3&gt;
&lt;p&gt;Contains &lt;strong&gt;User&apos;s Created Playlist Data&lt;/strong&gt; with all the tracks added in the playlist.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;[x] No. of T/As and Albums in each Playlist&lt;/li&gt;
&lt;li&gt;[x] Playlist &lt;code&gt;MinutesPlayed&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;[x] Most streamed P/As&lt;/li&gt;
&lt;li&gt;[x] Check any Track present in multiple Playlists&lt;/li&gt;
&lt;li&gt;[x] Streaming timeline of P/As (with &lt;code&gt;plot.line()&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;[x] Playlist-wise top T/As&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Using &lt;code&gt;YourLibrary.json&lt;/code&gt;&lt;/h3&gt;
&lt;blockquote&gt;
&lt;p&gt;[!WARNING] Currently Working!&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Using &lt;code&gt;Marquee.json&lt;/code&gt;&lt;/h3&gt;
&lt;blockquote&gt;
&lt;p&gt;[!WARNING] Currently Working!&lt;/p&gt;
&lt;/blockquote&gt;
</content:encoded><category>project</category><category>project</category><category>eda</category><author>Anshul Raj Verma</author></item><item><title>Starship Prompt</title><link>https://arv-anshul.github.io/blog/2024/starship</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/starship</guid><description>The minimal, blazing-fast, and infinitely customizable prompt for any shell!</description><pubDate>Wed, 21 Feb 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;&lt;img src=&quot;assets/images/without-starship.png&quot; alt=&quot;Without Starship image&quot; title=&quot;Without Starship&quot; /&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;assets/images/with-starship.png&quot; alt=&quot;With Starship image&quot; title=&quot;With Starship&quot; /&gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;figcaption&amp;gt;
I have introduced to Starship Prompt a week ago and it makes my shell prompt amazing.
&amp;lt;/figcaption&amp;gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!TIP] Prerequisites&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Install Starship Prompt from &lt;a href=&quot;https://starship.rs/guide/#step-1-install-starship&quot;&gt;official documentation&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Setup your shell (&lt;code&gt;bash&lt;/code&gt;, &lt;code&gt;zsh&lt;/code&gt; or &lt;code&gt;fish&lt;/code&gt;) to use Starship from
&lt;a href=&quot;https://starship.rs/guide/#step-2-set-up-your-shell-to-use-starship&quot;&gt;official documentation&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;[!NOTE]&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;I am using &lt;strong&gt;MacOS&lt;/strong&gt;. So, for other OS the paths may differ.&lt;/li&gt;
&lt;li&gt;I have used &lt;a href=&quot;https://nerdfonts.com&quot;&gt;&lt;strong&gt;Nerd Fonts&lt;/strong&gt;&lt;/a&gt; thats why there are some &lt;code&gt;symbol&lt;/code&gt; which may not appear as they
are.&lt;/li&gt;
&lt;li&gt;I have defined some conventions to define my &lt;code&gt;starship.toml&lt;/code&gt; file. If you want to know them read the sections where
I describe my conventions.&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;h2&gt;:wrench: Customization&lt;/h2&gt;
&lt;p&gt;You can customize your prompt for each programming languages you use like Python, JavaScript, Rust, and more. See
&lt;a href=&quot;https://starship.rs/config/&quot;&gt;official documentation&lt;/a&gt; to know more.&lt;/p&gt;
&lt;h3&gt;&lt;strong&gt;Example:&lt;/strong&gt; Python&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;[python]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;symbol&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;style&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;arv_python&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;format&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;[](fg:$style)[$symbol( $version)[( &lt;/span&gt;&lt;span&gt;\\&lt;/span&gt;&lt;span&gt;($virtualenv&lt;/span&gt;&lt;span&gt;\\&lt;/span&gt;&lt;span&gt;))](bold bg:$style)](bg:$style)[](fg:$style)&quot;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;&lt;strong&gt;Example:&lt;/strong&gt; Docker&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;[docker_context]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;symbol&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;style&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;arv_docker&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;format&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;[](fg:$style)[$symbol ($context)](bg:$style)[](fg:$style)&quot;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h4&gt;Conventions&lt;/h4&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Enclosed Modules&lt;/strong&gt;: Each modules enclose with circular end.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;:art: Color Palette&lt;/h2&gt;
&lt;p&gt;Did you see &lt;code&gt;style = &quot;arv_python&quot;&lt;/code&gt; and &lt;code&gt;style = &quot;arv_docker&quot;&lt;/code&gt; in above examples. Those are my custom defined &lt;strong&gt;palette&lt;/strong&gt;
as &lt;code&gt;&quot;arv-anshul&quot;&lt;/code&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;palette&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;arv-anshul&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;[palettes.arv-anshul]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;arv_dir&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;203&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;arv_docker&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;026&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;arv_git&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;063&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;arv_python&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;028&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;arv_custom&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;236&quot;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;details&amp;gt;
&amp;lt;summary&amp;gt;Print ANSI Colormap&amp;lt;/summary&amp;gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;# Use this function to print ANSI colormap&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;function&lt;/span&gt;&lt;span&gt; colormap&lt;/span&gt;&lt;span&gt;() {&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    range_start&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;${1&lt;/span&gt;&lt;span&gt;:-&lt;/span&gt;&lt;span&gt;1}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    range_end&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;${2&lt;/span&gt;&lt;span&gt;:-&lt;/span&gt;&lt;span&gt;255}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    for&lt;/span&gt;&lt;span&gt; i&lt;/span&gt;&lt;span&gt; in&lt;/span&gt;&lt;span&gt; $(&lt;/span&gt;&lt;span&gt;seq&lt;/span&gt;&lt;span&gt; $range_start&lt;/span&gt;&lt;span&gt; $range_end&lt;/span&gt;&lt;span&gt;); &lt;/span&gt;&lt;span&gt;do&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        echo&lt;/span&gt;&lt;span&gt; -en&lt;/span&gt;&lt;span&gt; &quot;\e[48;5;${&lt;/span&gt;&lt;span&gt;i&lt;/span&gt;&lt;span&gt;}m  ${(&lt;/span&gt;&lt;span&gt;l&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;span&gt;3&lt;/span&gt;&lt;span&gt;::&lt;/span&gt;&lt;span&gt;0&lt;/span&gt;&lt;span&gt;:&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;span&gt;i&lt;/span&gt;&lt;span&gt;}  \e[0m &quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        [[ $((&lt;/span&gt;&lt;span&gt;i&lt;/span&gt;&lt;span&gt; %&lt;/span&gt;&lt;span&gt; 10&lt;/span&gt;&lt;span&gt;)) -eq &lt;/span&gt;&lt;span&gt;0&lt;/span&gt;&lt;span&gt; ]] &amp;amp;&amp;amp; &lt;/span&gt;&lt;span&gt;echo&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    done&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    return&lt;/span&gt;&lt;span&gt; 0&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;lt;/details&amp;gt;&lt;/p&gt;
&lt;p&gt;If you doc&apos;t want to use ANSI color format then you also use &lt;code&gt;starship&lt;/code&gt;&apos;s pre-defined colors: &lt;code&gt;black&lt;/code&gt;, &lt;code&gt;red&lt;/code&gt;, &lt;code&gt;green&lt;/code&gt;,
&lt;code&gt;blue&lt;/code&gt;, &lt;code&gt;yellow&lt;/code&gt;, &lt;code&gt;purple&lt;/code&gt;, &lt;code&gt;cyan&lt;/code&gt;, &lt;code&gt;white&lt;/code&gt;. You can optionally prefix these with &lt;code&gt;bright-&lt;/code&gt; to get the bright version
(e.g. &lt;code&gt;bright-white&lt;/code&gt;). &lt;a href=&quot;https://starship.rs/advanced-config/#style-strings&quot;&gt;See in documentation&lt;/a&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;palette&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;arv-anshul-color&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;[palettes.arv-anshul-color]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;arv_dir&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;bright-red&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;arv_docker&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;bright-blue&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;arv_git&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;blue&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;arv_python&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;green&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;arv_custom&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;black&quot;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Conventions&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Palette Preffix&lt;/strong&gt;: Palette&apos;s &lt;code&gt;keys&lt;/code&gt; must have a preffix (in my case it is &lt;code&gt;&quot;arv_&quot;&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;ANSI Codes&lt;/strong&gt;: I have defined colors in &lt;strong&gt;ANSI Codes&lt;/strong&gt;. See this
&lt;a href=&quot;https://gist.github.com/fnky/458719343aabd01cfb17a3a4f7296797&quot;&gt;Gist&lt;/a&gt; to know more about ANSI Codes.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Own Color Palette&lt;/strong&gt;: I have defined programming language-wise &lt;em&gt;(or module-wise)&lt;/em&gt; colors which makes easy to
change/manipulate the color of any language.&lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
&lt;p&gt;You can also create your own custom color palette in &lt;code&gt;~/.config/starship.toml&lt;/code&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;:people_hugging: Extra customization with custom modules&lt;/h2&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;[custom.github]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;detect_folders&lt;/span&gt;&lt;span&gt; = [&lt;/span&gt;&lt;span&gt;&quot;.github&quot;&lt;/span&gt;&lt;span&gt;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;format&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;[$symbol]($style)&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;style&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;bg:arv_custom&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;symbol&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot; &quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;[custom.mkdocs]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;detect_files&lt;/span&gt;&lt;span&gt; = [&lt;/span&gt;&lt;span&gt;&quot;mkdocs.yaml&quot;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&quot;mkdocs.yml&quot;&lt;/span&gt;&lt;span&gt;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;detect_folders&lt;/span&gt;&lt;span&gt; = [&lt;/span&gt;&lt;span&gt;&quot;docs&quot;&lt;/span&gt;&lt;span&gt;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;format&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;[$symbol]($style)&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;style&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;bg:arv_custom&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;symbol&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;󱔗 &quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;[custom.vscode]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;detect_folders&lt;/span&gt;&lt;span&gt; = [&lt;/span&gt;&lt;span&gt;&quot;.vscode&quot;&lt;/span&gt;&lt;span&gt;]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;format&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;[$symbol]($style)&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;style&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;bg:arv_custom&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;symbol&lt;/span&gt;&lt;span&gt; = &lt;/span&gt;&lt;span&gt;&quot;󰨞 &quot;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Conventions&lt;/h3&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;I have used `custom` modules to just show some desirable icons in the prompt but you can do a lot of thing using `custom` modules _(the possibilities are endless)_.&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Show Custom Icons&lt;/strong&gt;: I used &lt;code&gt;custom&lt;/code&gt; modules to show icons by detecting files and folders. For example, prompt will
show icons when &lt;code&gt;.github&lt;/code&gt; folder is present in the current directory.&lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
&lt;p&gt;Refer to &lt;a href=&quot;https://starship.rs/config/#custom-commands&quot;&gt;official documentation&lt;/a&gt; to know more about custom modules.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;[!TIP] From official documentation&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;https://github.com/starship/starship/discussions/1252&quot;&gt;Issue #1252&lt;/a&gt; contains examples of &lt;code&gt;custom&lt;/code&gt; modules. You can go
there for inspiration and if you have an interesting example not covered there, feel free to share it there!&lt;/p&gt;
&lt;/blockquote&gt;
&lt;hr /&gt;
&lt;p&gt;&lt;img src=&quot;assets/images/with-starship.png&quot; alt=&quot;With Starship image&quot; title=&quot;With Starship&quot; /&gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;figcaption&amp;gt;If you want to make prompt to look like mine! Click below&amp;lt;/figcaption&amp;gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;https://github.com/arv-anshul/dotfiles/blob/main/.config/starship.toml&quot;&gt;starship.toml&lt;/a&gt;&lt;/p&gt;
</content:encoded><category>blog</category><category>others</category><author>Anshul Raj Verma</author></item><item><title>CampusX Resources</title><link>https://arv-anshul.github.io/projects/campusx</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/campusx</guid><description>This project involves gathering data from a course website&apos;s HTML structure, followed by developing Python scripts for parsing and extracting essential data. HTTP requests are then made to obtain session resources, with robust testing and data structure maintenance ensuring integrity. Then a web page is generated and hosted on GitHub Pages via CI/CD with GitHub Actions.</description><pubDate>Fri, 16 Feb 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;&amp;lt;figure&amp;gt;
&amp;lt;a href=&quot;https://arv-anshul.github.io/campusx&quot;&amp;gt;
&amp;lt;img src=&quot;https://github.com/arv-anshul/campusx-dsmp/raw/main/docs/data/assets/home.png&quot; title=&quot;Website Home Page&quot; class=&quot;rounded border border-outline&quot;&amp;gt;
&amp;lt;/a&amp;gt;
&amp;lt;figcaption&amp;gt;Get all the resources like Notes and Notebooks provided in CampusX Courses.&amp;lt;/figcaption&amp;gt;
&amp;lt;/figure&amp;gt;&lt;/p&gt;
&lt;h2&gt;Praise by Nitish Sir&lt;/h2&gt;
&lt;p&gt;&amp;lt;figure&amp;gt;
&amp;lt;iframe src=&quot;https://www.linkedin.com/embed/feed/update/urn:li:ugcPost:7162317353244905472?compact=1&quot; height=&quot;399&quot; width=&quot;710&quot; frameborder=&quot;0&quot; allowfullscreen=&quot;&quot;&amp;gt;&amp;lt;/iframe&amp;gt;
&amp;lt;/figure&amp;gt;&lt;/p&gt;
&lt;h2&gt;Links to Resources&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/campusx/tree/main/resources/DSMP&quot;&gt;Downloaded Resources&lt;/a&gt;:
Resources are uploaded in my GitHub repo as files. You can get all the course&apos;s resources like &lt;code&gt;.pdf&lt;/code&gt;, &lt;code&gt;.ipynb&lt;/code&gt;,
&lt;code&gt;.docx&lt;/code&gt;, &lt;code&gt;.pptx&lt;/code&gt;, &lt;code&gt;.xlsx&lt;/code&gt; and &lt;code&gt;.py&lt;/code&gt; files.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io/campusx/dsmp2&quot;&gt;See Resources&lt;/a&gt;: Resources are listed
on a web page where you can access the content descriptions for all sessions, with the teacher providing helpful links
to enhance your understanding of each session.&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>project</category><category>project</category><category>web-scraping</category><category>deployed</category><author>Anshul Raj Verma</author></item><item><title>Clustering Algorithms in ML</title><link>https://arv-anshul.github.io/blog/2024/clustering-algo</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/clustering-algo</guid><description>Overview of clustering algorithms in Machine Learning.</description><pubDate>Tue, 06 Feb 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Applications of Clustering&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Customer Segmentation&lt;/strong&gt;: To show personalized ADs to customers.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Data Analysis&lt;/strong&gt;: Perform analysis to each cluster after performing clustering on the whole dataset.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Semi Supervised Learning&lt;/strong&gt;: Google Photos uses this technique to identify person&apos;s face and put them into a separate
folder.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Image Segmentation&lt;/strong&gt;: You can create segments in photos to represent different objects in the photo.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;KMeans&lt;/h2&gt;
&lt;h3&gt;Working Steps&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;You tell the algorithm how many clusters are there in the data (this is assumption which is taken before
initialization).&lt;/li&gt;
&lt;li&gt;The cluster&apos;s centroids are initialize with some random values.&lt;/li&gt;
&lt;li&gt;The distance of each data point is calculated with each cluster and then the data points are assigned to nearest
clusters.&lt;/li&gt;
&lt;li&gt;After data points assignment to clusters, the centroid of the clusters is being calculated.&lt;/li&gt;
&lt;li&gt;If the centroid&apos;s position is:
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Same as before&lt;/strong&gt; then the algorithm stops.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Not same as before&lt;/strong&gt; then the &lt;strong&gt;STEP 3&lt;/strong&gt; is being re-calculated and the process goes on.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;graph TD&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  subgraph Initialization&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    A(Initialize Centroids)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    B[Calculate Distance and \n Assign Data Points]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  end&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  subgraph Iterative Process&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    C[Update Centroids]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    D[Reassign Data Points]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  end&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  subgraph Convergence Check&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    E[/Converged?/]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  end&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  A --&amp;gt;|Random Initialization| B&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  B --&amp;gt;|Assign Nearest Centroid| C&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  C --&amp;gt;|Recalculate Centroids| D&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  D --&amp;gt;|Assign New Clusters| E&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  E --&amp;gt;|Yes| stop{Stop}&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;  E --&amp;gt;|No| B&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Inertia&lt;/strong&gt; also known as &lt;strong&gt;within-cluster sum of squares&lt;/strong&gt; (WCSS) in the context of K-Means clustering, is a measure
that quantifies the compactness of clusters. It is calculated as the sum of the squared distances between each data
point in a cluster and the centroid of that cluster.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Elbow Method&lt;/strong&gt; is way to decide the number of clusters present in a data. However, this is not a very good method to
estimate clusters &lt;em&gt;but it there to help you for that&lt;/em&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Assumptions of KMeans&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Spherical Cluster Shape&lt;/strong&gt;: K-means assumes that the clusters are spherical and isotropic, meaning they are uniform
in all directions. Consequently, the algorithm works best when the actual clusters in the data are circular (in 2D) or
spherical (in higher dimensions).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Similar Cluster Size&lt;/strong&gt;: The algorithm tends to perform better when all clusters are of approximately the same size.
If one cluster is much larger than others, K-means might struggle to correctly assign the points to the appropriate
cluster.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Equal Variance of Clusters&lt;/strong&gt;: K-means assumes that all clusters have similar variance. The algorithm uses the
Euclidean distance metric, which can bias the clustering towards clusters with lower variance.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Clusters are Well Separated&lt;/strong&gt;: The algorithm works best when the clusters are well separated from each other. If
clusters are overlapping or intertwined, K-means might not be able to distinguish them effectively.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Number of Clusters (k) is Predefined&lt;/strong&gt;: K-means requires the number of clusters (k) to be specified in advance.
Choosing the right value of k is crucial, but it is not always straightforward and typically requires domain knowledge
or additional methods like the Elbow method or Silhouette analysis.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Large n, Small k&lt;/strong&gt;: K-means is generally more efficient and effective when the dataset is large (large n) and the
number of clusters is small (small k).&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Resources to Learn From&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Introduction&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Objective:&lt;/strong&gt; Divide data into k clusters.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Algorithm:&lt;/strong&gt; Iterative process that minimizes the sum of squared distances between data points and their assigned
cluster centroids.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Algorithm Steps&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Initialization:&lt;/strong&gt; Randomly select k initial centroids.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Assignment:&lt;/strong&gt; Assign each data point to the nearest centroid.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Update Centroids:&lt;/strong&gt; Recalculate centroids based on assigned points.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Repeat:&lt;/strong&gt; Iteratively repeat assignment and centroid update until convergence.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Advantages&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Simple and computationally efficient.&lt;/li&gt;
&lt;li&gt;Scales well to large datasets.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Disadvantages&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Sensitive to initial centroid selection.&lt;/li&gt;
&lt;li&gt;Assumes clusters are spherical and equally sized.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;DBSCAN&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;Density-Based Spatial Clustering of Applications with Noise&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;DBSCAN is a clustering algorithm commonly used in data mining and machine learning. It&apos;s particularly effective in
identifying clusters of arbitrary shapes and handling noise in the data.&lt;/p&gt;
&lt;p&gt;DBSCAN does not require the number of clusters &lt;em&gt;(like KMeans)&lt;/em&gt; to be specified beforehand and can discover clusters
based on the density of data points.&lt;/p&gt;
&lt;h3&gt;Important Terms&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Core Points:&lt;/strong&gt; A data point is considered a core point if there are at least &lt;strong&gt;&quot;min_samples&quot;&lt;/strong&gt; data points
(including itself) within a specified distance, usually denoted as &lt;strong&gt;&quot;epsilon&quot; (ε)&lt;/strong&gt;. Core points are the central
points of clusters.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Border Points:&lt;/strong&gt; A data point is considered a border point if it is within the specified distance &lt;strong&gt;(ε)&lt;/strong&gt; of a core
point but doesn&apos;t have enough neighboring points to be considered a core point itself. Border points are part of a
cluster but are not central to it.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Noise Points:&lt;/strong&gt; Data points that are neither core points nor border points are considered noise points or outliers.
These points do not belong to any cluster.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Working Steps&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Initialization:&lt;/strong&gt; Select an arbitrary data point that has not been visited.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Density Query:&lt;/strong&gt; Find all data points within distance ε from the selected point.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Core Point Check:&lt;/strong&gt; If the number of points found is greater than or equal to &lt;strong&gt;&quot;min_samples&quot;&lt;/strong&gt;, mark the selected
point as a core point, and a cluster is formed.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Expand Cluster:&lt;/strong&gt; Expand the cluster by recursively repeating the process for all the newly found core points.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Next Point Selection:&lt;/strong&gt; Choose a new unvisited point and repeat the process until all data points have been
visited.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Resources to Learn From&lt;/h3&gt;
&lt;p&gt;&amp;lt;iframe width=&quot;700&quot; height=&quot;400&quot; src=&quot;https://www.youtube-nocookie.com/embed/1_bLnsNmhCI?si=B6ym1DnPcFv5bnIG&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share&quot; allowfullscreen&amp;gt;&amp;lt;/iframe&amp;gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;iframe width=&quot;700&quot; height=&quot;400&quot; src=&quot;https://www.youtube-nocookie.com/embed/RDZUdRSDOok?si=ynfnAEx7vdjGhCa5&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share&quot; allowfullscreen&amp;gt;&amp;lt;/iframe&amp;gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Introduction&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Objective:&lt;/strong&gt; Identify clusters based on dense regions in data space.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Algorithm:&lt;/strong&gt; Utilizes density information, considering data points as core, border, or noise.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Algorithm Steps&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Density Estimation:&lt;/strong&gt; Define ε (eps) and minimum points for a neighborhood.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Core Points:&lt;/strong&gt; Identify dense regions with at least &apos;minPts&apos; neighbors within ε.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Expand Clusters:&lt;/strong&gt; Connect core points and expand clusters with border points.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Advantages&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Doesn&apos;t assume spherical clusters.&lt;/li&gt;
&lt;li&gt;Can find clusters of arbitrary shapes.&lt;/li&gt;
&lt;li&gt;Robust to outliers.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Disadvantages&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Sensitivity to parameter settings (ε, minPts).&lt;/li&gt;
&lt;li&gt;Struggles with varying density clusters.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Gaussian Mixture Models&lt;/h2&gt;
&lt;p&gt;Gaussian Mixture Models (GMMs) are probabilistic models used for clustering and density estimation. Unlike k-means,
which assigns data points to a single cluster, GMMs allow each data point to belong to multiple clusters with different
probabilities. GMMs assume that the data is generated from a mixture of several Gaussian distributions.&lt;/p&gt;
&lt;p&gt;Here are the key concepts associated with Gaussian Mixture Models:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Gaussian Distribution (Normal Distribution)&lt;/strong&gt;: A probability distribution that is characterized by its mean (μ) and
standard deviation (σ). The probability density function of a Gaussian distribution is given by:&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;f(x; &lt;/span&gt;&lt;span&gt;\mu&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;\sigma&lt;/span&gt;&lt;span&gt;^2) = &lt;/span&gt;&lt;span&gt;\frac&lt;/span&gt;&lt;span&gt;{1}{&lt;/span&gt;&lt;span&gt;\sqrt&lt;/span&gt;&lt;span&gt;{2&lt;/span&gt;&lt;span&gt;\pi\sigma&lt;/span&gt;&lt;span&gt;^2}} &lt;/span&gt;&lt;span&gt;\exp\left&lt;/span&gt;&lt;span&gt;(-&lt;/span&gt;&lt;span&gt;\frac&lt;/span&gt;&lt;span&gt;{(x - &lt;/span&gt;&lt;span&gt;\mu&lt;/span&gt;&lt;span&gt;)^2}{2&lt;/span&gt;&lt;span&gt;\sigma&lt;/span&gt;&lt;span&gt;^2}&lt;/span&gt;&lt;span&gt;\right&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Mixture Model&lt;/strong&gt;: A combination of multiple probability distributions. In the case of GMMs, these are Gaussian
distributions.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Parameters of GMM&lt;/strong&gt;:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Weights &lt;code&gt;#!math (πi)&lt;/code&gt;&lt;/strong&gt;: The probabilities associated with each component (Gaussian distribution). They represent
the likelihood of a data point belonging to a specific cluster.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Means &lt;code&gt;#!math (μi)&lt;/code&gt;&lt;/strong&gt;: The mean values of the Gaussian distributions.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Covariance Matrices &lt;code&gt;#!math (Σi)&lt;/code&gt;&lt;/strong&gt;: The covariance matrices representing the shape and orientation of the
Gaussian distributions.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Probability Density Function of GMM&lt;/strong&gt;:&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;P(x) = &lt;/span&gt;&lt;span&gt;\sum&lt;/span&gt;&lt;span&gt;_{i=1}^{k} &lt;/span&gt;&lt;span&gt;\pi&lt;/span&gt;&lt;span&gt;_i &lt;/span&gt;&lt;span&gt;\cdot&lt;/span&gt;&lt;span&gt; \mathcal&lt;/span&gt;&lt;span&gt;{N}(x; &lt;/span&gt;&lt;span&gt;\mu&lt;/span&gt;&lt;span&gt;_i, &lt;/span&gt;&lt;span&gt;\Sigma&lt;/span&gt;&lt;span&gt;_i)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;where &lt;code&gt;#!math \mathcal{N}(x; \mu_i, \Sigma_i)&lt;/code&gt; is the probability density function of the &lt;code&gt;#!math i^{th}&lt;/code&gt; Gaussian
distribution.&lt;/p&gt;
&lt;h3&gt;Working Steps&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Initialization&lt;/strong&gt;: Initialize the parameters of the model, including the weights, means, and covariance matrices.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Expectation-Maximization (EM) Algorithm&lt;/strong&gt;:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Expectation Step (E-step)&lt;/strong&gt;: Compute the probabilities that each data point belongs to each cluster
(responsibility).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Maximization Step (M-step)&lt;/strong&gt;: Update the model parameters (weights, means, covariance matrices) based on the
assigned responsibilities.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Convergence&lt;/strong&gt;: Repeat the E-step and M-step until the model converges, i.e., the parameters stabilize.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Prediction&lt;/strong&gt;: Once trained, the model can be used to predict the cluster assignments or estimate the density of new
data points.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;GMMs are flexible and can model complex data distributions. They are widely used in various applications, such as image
segmentation, speech recognition, and anomaly detection.&lt;/p&gt;
&lt;h3&gt;Resources to Learn From&lt;/h3&gt;
&lt;p&gt;&amp;lt;iframe width=&quot;560&quot; height=&quot;315&quot; src=&quot;https://www.youtube-nocookie.com/embed/q71Niz856KE?si=Zz23kSbbfnmRQPHK&quot; title=&quot;YouTube video player&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share&quot; allowfullscreen&amp;gt;&amp;lt;/iframe&amp;gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Introduction&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Objective:&lt;/strong&gt; Model data as a mixture of Gaussian distributions.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Algorithm:&lt;/strong&gt; Probability-based approach using the Expectation-Maximization (EM) algorithm.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Algorithm Steps&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Initialization:&lt;/strong&gt; Assign initial parameters for Gaussian distributions.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Expectation Step:&lt;/strong&gt; Estimate probability of each data point belonging to each cluster.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Maximization Step:&lt;/strong&gt; Update parameters based on the expected assignments.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Repeat:&lt;/strong&gt; Iteratively repeat the E-M steps until convergence.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Advantages&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;More flexible in capturing different cluster shapes.&lt;/li&gt;
&lt;li&gt;Provides probabilistic cluster assignments.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Disadvantages&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Sensitive to initialization.&lt;/li&gt;
&lt;li&gt;Computationally more expensive than K-Means.&lt;/li&gt;
&lt;/ul&gt;
</content:encoded><category>blog</category><category>ml</category><author>Anshul Raj Verma</author></item><item><title>February Journal</title><link>https://arv-anshul.github.io/journal/2024/02</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/02</guid><description>Weekly Journal by ARV of February 2024</description><pubDate>Thu, 01 Feb 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 5 Journal&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;yt-watch-history&lt;/code&gt;&lt;/strong&gt;: After 3 iterations I have understand how to deal with ML models.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;yt-watch-history&lt;/code&gt;&lt;/strong&gt;: New PR for &lt;code&gt;channel_reco&lt;/code&gt; in &lt;code&gt;frontend&lt;/code&gt;. This PR just take subscription data and shows the
recommendation of selected channel.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;PROJECT IDEA&lt;/strong&gt;: I am thinking about to create a Python Package from which you can scrape website using &lt;code&gt;cURL&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;In &lt;code&gt;yt-watch-history&lt;/code&gt;, I don&apos;t want to give so much time on &lt;code&gt;frontend&lt;/code&gt; instead more focus on &lt;code&gt;backend&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;CRITICISM&lt;/strong&gt;: If you don&apos;t focus on &lt;code&gt;frontend&lt;/code&gt; then it is bad to present and maintain. That&apos;s why you should also
take care of &lt;code&gt;frontend&lt;/code&gt; part.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Week 6 Journal&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/campusx&quot;&gt;&lt;strong&gt;&lt;code&gt;campusx&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;: I have built new project where you can get all the notes and
links provided in the description of sessions of DSMP course.
&lt;ul&gt;
&lt;li&gt;I have created this in &lt;strong&gt;almost 3 days&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Done many things like &lt;strong&gt;follow conventional commits&lt;/strong&gt;, written tests and more.
&lt;a href=&quot;https://github.com/arv-anshul/campusx#%EF%B8%8F-project-workflows&quot;&gt;See here&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;I have released &lt;code&gt;v0.1.0&lt;/code&gt; of &lt;code&gt;campusx&lt;/code&gt; but I use 🤖 ChatGPT to generate release note (using all commits) and I don&apos;t
think that it is good release note like I see for other projects.&lt;/li&gt;
&lt;li&gt;🤓 I want to learn how to write and manage &lt;strong&gt;Release Notes&lt;/strong&gt; and &lt;strong&gt;CHANGELOG&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Conventional Commits&lt;/strong&gt;: For a long time I have been thinking about to follow a convention for &lt;strong&gt;GIT commits&lt;/strong&gt; but
where-ever I check I don&apos;t understand then I came across
&lt;a href=&quot;https://marketplace.visualstudio.com/items?itemName=vivaxy.vscode-conventional-commits&quot;&gt;&lt;code&gt;vivaxy.vscode-conventional-commits&lt;/code&gt;&lt;/a&gt;
a VSCode extension and now I know how to write better commits. 😉&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Mkdocs&lt;/strong&gt;: &lt;code&gt;mkdocs-material&lt;/code&gt; is a very powerful tool to create static web pages using &lt;strong&gt;markdowns&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;🎉 The Open Source Contributions of Indians ft. @ApnaCollege.&lt;/li&gt;
&lt;li&gt;I am thinking about to switch to &lt;code&gt;pixi&lt;/code&gt; or &lt;code&gt;rye&lt;/code&gt; because I also want to manage my projects like never before; like
professional 🤯.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 7 Journal&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://rye-up.com&quot;&gt;&lt;strong&gt;&lt;code&gt;rye&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;: My new way to manage projects like pro. I have used it and this is very convenient to use and
manage.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://rye-up.com&quot;&gt;&lt;strong&gt;&lt;code&gt;rye&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;: I have raised issue &lt;a href=&quot;https://github.com/mitsuhiko/rye/issues/639&quot;&gt;&lt;strong&gt;#639&lt;/strong&gt;&lt;/a&gt; while configuring the &lt;a href=&quot;https://github.com/arv-anshul/campusx&quot;&gt;&lt;code&gt;campusx&lt;/code&gt;&lt;/a&gt; project.
&lt;em&gt;For more info see issue itself.&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/astral-sh/uv&quot;&gt;&lt;strong&gt;&lt;code&gt;astral-sh/uv&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;: Another blazing fast tool for python devs to manage their packages (&lt;em&gt;written in
🦀 Rust&lt;/em&gt;).
&lt;ul&gt;
&lt;li&gt;🤯 This is actually powerful (I have seen it 👀). It is almost &lt;strong&gt;8x&lt;/strong&gt; faster than &lt;code&gt;pip&lt;/code&gt; when I build my
&lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history&quot;&gt;&lt;code&gt;yt-watch-history&lt;/code&gt;&lt;/a&gt; project using &lt;code&gt;docker-compose&lt;/code&gt; it takes 🐢 &lt;strong&gt;~200 seconds&lt;/strong&gt; with &lt;code&gt;pip&lt;/code&gt; but
now it takes 🐇 &lt;strong&gt;~25 seconds&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://starship.rs&quot;&gt;&lt;strong&gt;&lt;code&gt;starship&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;: Another blazing fast tool for terminal prompts (&lt;em&gt;written in 🦀 Rust&lt;/em&gt;).
&lt;ul&gt;
&lt;li&gt;🎉 Yay, I have learned and configured my terminal prompt using &lt;code&gt;starship&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://arv-anshul.github.io/campusx/dsmp2&quot;&gt;&lt;strong&gt;Social Cards&lt;/strong&gt;&lt;/a&gt;: I have added social card preview on the website. Here, I have hard coded the
&lt;code&gt;&amp;lt;meta&amp;gt;&lt;/code&gt; tags (which is not recommended). You can use
&lt;a href=&quot;https://squidfunk.github.io/mkdocs-material/plugins/social/&quot;&gt;&lt;code&gt;social&lt;/code&gt;&lt;/a&gt; builtin plugin of &lt;code&gt;mkdocs-material&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Praise by Nitish Sir&lt;/strong&gt; for &lt;a href=&quot;https://github.com/arv-anshul/campusx&quot;&gt;&lt;code&gt;campusx&lt;/code&gt;&lt;/a&gt; project. See my
&lt;a href=&quot;https://www.linkedin.com/posts/arv-anshul_yesterday-nitish-singh-sir-recommend-activity-7162317549496381440-JskB?utm_source=share&amp;amp;utm_medium=member_desktop&quot;&gt;LinkedIn Post&lt;/a&gt;
on this.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history&quot;&gt;&lt;strong&gt;&lt;code&gt;yt-watch-history&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;: I have been configuring this project with &lt;code&gt;rye&lt;/code&gt; and there are many
challenges I have faced while doing this like:
&lt;ol&gt;
&lt;li&gt;This is a virtual project and there are some limitations comes with &lt;strong&gt;virtual&lt;/strong&gt; packages check the issue
&lt;a href=&quot;https://github.com/mitsuhiko/rye/issues/639&quot;&gt;&lt;strong&gt;#639&lt;/strong&gt;&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;This project contains two separate repos &lt;code&gt;backend&lt;/code&gt; and &lt;code&gt;frontend&lt;/code&gt; which make this a monorepo and for now &lt;code&gt;rye&lt;/code&gt;
does not well support a monorepo because I have to create one workspace level environment for both repos (and I
don&apos;t kinda like this).&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 8 Journal&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://starship.rs&quot;&gt;&lt;strong&gt;&lt;code&gt;Starship&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;: Now I have learned &lt;code&gt;starship&lt;/code&gt; in a way that I can customize my prompt easily however I
want to be. I written &lt;a href=&quot;https://arv-anshul.github.io/blog/2024/02/21/starship-prompt/&quot;&gt;a blog&lt;/a&gt; a on it to. You can
check my &lt;a href=&quot;https://github.com/arv-anshul/dotfiles/blob/main/.config/starship.toml&quot;&gt;&lt;code&gt;starship.toml&lt;/code&gt;&lt;/a&gt; on Github.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/notebooks/tree/main/spotify-analysis&quot;&gt;&lt;strong&gt;&lt;code&gt;notebooks/spotify-analysis&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;: I have started a new project which analyses User&apos;s
Spotify&apos;s Streaming History data and give insights from them.
&lt;ul&gt;
&lt;li&gt;I have done some analysis on &lt;code&gt;StreamingHistory&lt;/code&gt; and &lt;code&gt;Playlist&lt;/code&gt; dataset and gain some interesting insights from it.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://backdropbuild.com&quot;&gt;&lt;strong&gt;backdropbuild.com&lt;/strong&gt;&lt;/a&gt;: I have received a mail from
&lt;a href=&quot;mailto:joey@backdroplabs.co&quot;&gt;@JoeyDeBruin&lt;/a&gt; to participate in their program &lt;em&gt;(which is a kind of Hack-a-thon)&lt;/em&gt; and
mentioned my project &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history&quot;&gt;&lt;strong&gt;&lt;code&gt;yt-watch-history&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt; because he thinks that the project good fit their
program &lt;em&gt;(and I am doing this project to learn MLOps concepts like Docker, MLFlow)&lt;/em&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;&lt;img src=&quot;../assets/joey-mail-backdropbuild.png&quot; alt=&quot;18-02-2024&quot; title=&quot;Joey&apos;s mail to join the program.&quot; /&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!NOTE]&lt;/p&gt;
&lt;p&gt;Hey Joey, Thanks to appreciate my project &lt;code&gt;yt-watch-history&lt;/code&gt; and also for considering me to participate in your
program.&lt;/p&gt;
&lt;p&gt;Honestly, I am just learning &quot;MLOps&quot; concepts while building this project and for now, I am not sure that I am a good
fit for your program. And by keeping this in mind I am not able to join but I am sure that I&apos;ll join it in future for
sure.&lt;/p&gt;
&lt;p&gt;Thanks Joey &amp;lt;br/&amp;gt; Anshul Raj Verma&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Week 9 Journal&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;😞 Not Much!&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;But I have watched some sessions of the &lt;strong&gt;DSMP 2.0&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Before Wedding&lt;/strong&gt;: I am going to wedding for approx. 3-4 days.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;After Wedding&lt;/strong&gt;: I have absent for &lt;strong&gt;11 days&lt;/strong&gt; from &lt;strong&gt;25 Feb — 6 Mar&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 10 Journal&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://rye-up.com&quot;&gt;&lt;strong&gt;&lt;code&gt;rye&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt; transferred to &lt;a href=&quot;https://astral.sh/&quot;&gt;&lt;code&gt;astral-sh&lt;/code&gt;&lt;/a&gt; Github Organization.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;ruff&lt;/code&gt;&lt;/strong&gt; released it &lt;code&gt;v0.3.0&lt;/code&gt; with new formatting rules &lt;code&gt;2024-02&lt;/code&gt;.
&lt;a href=&quot;https://astral.sh/blog/ruff-v0.3.0&quot;&gt;Read the Blog&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;I have simplified the complex url of blogs &lt;a href=&quot;https://arv-anshul.github.io&quot;&gt;in my website&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;I have to bring my laptop to where I go I go because without it I lose many things and make it hard to catch up.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>february</category><author>Anshul Raj Verma</author></item><item><title>Overview: Decision Tree</title><link>https://arv-anshul.github.io/blog/2024/decision-tree</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/decision-tree</guid><description>An overview of Decision Tree algorithm in Machine Learning.</description><pubDate>Mon, 29 Jan 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;Decision tree is a very crucial algorithm in ML world because using this algorithm there are many important and some of
the best algo of ML is made upon like RandomForest and Xgboost.&lt;/p&gt;
&lt;p&gt;That&apos;s why we going to take a overview of Decision Tree in this blog.&lt;/p&gt;
&lt;h2&gt;Anatomy of Decision Trees&lt;/h2&gt;
&lt;p&gt;A decision tree is a popular machine learning algorithm used for both classification and regression tasks. It is a
tree-like model composed of nodes, where each internal node represents a decision based on a feature, each branch
represents the outcome of that decision, and each leaf node represents the final prediction.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Root Node&lt;/strong&gt;: The topmost node that makes the initial decision.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Internal Nodes&lt;/strong&gt;: Decision nodes that split the data based on a particular feature.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Branches&lt;/strong&gt;: Outcomes of decisions, leading to the next set of nodes.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Leaf Nodes&lt;/strong&gt;: Terminal nodes providing the final predictions.&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;graph TD&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    RootNode(Root Node) --&amp;gt; |Decision Feature 1| InternalNode1(Internal Node 1)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    InternalNode1 --&amp;gt; |Decision Feature 2| InternalNode2(Internal Node 2)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    InternalNode1 --&amp;gt; |Decision Feature 3| InternalNode3(Internal Node 3)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    InternalNode2 --&amp;gt; |Decision Feature 4| LeafNode1(Leaf Node 1)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    InternalNode2 --&amp;gt; |Decision Feature 5| LeafNode2(Leaf Node 2)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    InternalNode3 --&amp;gt; |Decision Feature 6| LeafNode3(Leaf Node 3)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    InternalNode3 --&amp;gt; |Decision Feature 7| LeafNode4(Leaf Node 4)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2&gt;Loss Functions&lt;/h2&gt;
&lt;p&gt;Decision trees use various loss functions depending on the task:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Classification&lt;/strong&gt;: Commonly use metrics like Gini impurity or cross-entropy.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Regression&lt;/strong&gt;: Typically use mean squared error.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Gini Impurity in Decision Trees&lt;/h2&gt;
&lt;h3&gt;How Gini Impurity Works?&lt;/h3&gt;
&lt;p&gt;Gini impurity is a measure of how often a randomly chosen element from the set would be incorrectly labeled. For a
binary classification problem, the Gini impurity (Gini index) for a node is calculated as follows:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;\text&lt;/span&gt;&lt;span&gt;{Gini(D)} = 1 - &lt;/span&gt;&lt;span&gt;\sum&lt;/span&gt;&lt;span&gt;_{i=1}^{c} (p_i)^2&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Where:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;#!math (D)&lt;/code&gt; is the dataset at the node.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (c)&lt;/code&gt; is the number of classes.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;#!math (p_i)&lt;/code&gt; is the probability of choosing a data point of class &lt;code&gt;#!math i&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Example&lt;/h3&gt;
&lt;p&gt;Consider a node with 30 samples, distributed among two classes (A and B) as follows:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Class A: 15 samples&lt;/li&gt;
&lt;li&gt;Class B: 15 samples&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;\text&lt;/span&gt;&lt;span&gt;{Gini(D)} = 1 - &lt;/span&gt;&lt;span&gt;\left&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;\left&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;\frac&lt;/span&gt;&lt;span&gt;{15}{30}&lt;/span&gt;&lt;span&gt;\right&lt;/span&gt;&lt;span&gt;)^2 + &lt;/span&gt;&lt;span&gt;\left&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;\frac&lt;/span&gt;&lt;span&gt;{15}{30}&lt;/span&gt;&lt;span&gt;\right&lt;/span&gt;&lt;span&gt;)^2&lt;/span&gt;&lt;span&gt;\right&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;\text&lt;/span&gt;&lt;span&gt;{Gini(D)} = 1 - &lt;/span&gt;&lt;span&gt;\left&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;\frac&lt;/span&gt;&lt;span&gt;{1}{4} + &lt;/span&gt;&lt;span&gt;\frac&lt;/span&gt;&lt;span&gt;{1}{4}&lt;/span&gt;&lt;span&gt;\right&lt;/span&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;\text&lt;/span&gt;&lt;span&gt;{Gini(D)} = 1 - &lt;/span&gt;&lt;span&gt;\frac&lt;/span&gt;&lt;span&gt;{1}{2} = &lt;/span&gt;&lt;span&gt;\frac&lt;/span&gt;&lt;span&gt;{1}{2}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The goal during the tree-building process is to minimize the Gini impurity at each node.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Watch StatQuest video on Decision Tree&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;iframe width=&quot;700&quot; height=&quot;400&quot; src=&quot;https://www.youtube-nocookie.com/embed/_L39rN6gz7Y?si=Ua08hw0Wp1vtTtdE&amp;amp;start=18&quot; title=&quot;StatQuest - Decision Tree&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share&quot; allowfullscreen&amp;gt;&amp;lt;/iframe&amp;gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Gini Impurity Clearly Explained&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;iframe width=&quot;700&quot; height=&quot;400&quot; src=&quot;https://www.youtube-nocookie.com/embed/u4IxOk2ijSs?si=WwzITA_q9of6sJL8&amp;amp;start=18&quot; title=&quot;Gini Impurity - Serrano.Academy&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share&quot; allowfullscreen&amp;gt;&amp;lt;/iframe&amp;gt;&lt;/p&gt;
&lt;h2&gt;Advantages&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Interpretability:&lt;/strong&gt; Decision trees provide a transparent and intuitive representation of decision-making. This makes
them valuable for communication with non-technical stakeholders. A data scientist can easily explain the logic behind
predictions, fostering trust in the model.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;No Feature Scaling Required:&lt;/strong&gt; Decision trees are not affected by the scale of features. This means that data
scientists don&apos;t have to spend time and effort on feature scaling, making the preprocessing phase simpler and more
straightforward.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Handle Mixed Data Types:&lt;/strong&gt; Decision trees can handle both numerical and categorical data without the need for
one-hot encoding. This is advantageous when dealing with datasets that contain a mix of data types.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Require Less Data Preprocessing:&lt;/strong&gt; Decision trees are less sensitive to outliers and missing values compared to some
other algorithms. This can save time during the data cleaning and preprocessing stages.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Feature Importance:&lt;/strong&gt; Decision trees provide a natural way to assess the importance of different features in the
prediction. Data scientists can easily identify which features contribute more significantly to the model&apos;s
decision-making process.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Disadvantages&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Overfitting&lt;/strong&gt;: Decision trees are prone to overfitting, especially when the tree is deep and captures noise in the
training data. Data scientists need to carefully tune hyperparameters, such as the tree depth, to prevent overfitting
and ensure better generalization to new data.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Instability&lt;/strong&gt;: Small variations in the training data can lead to different tree structures. This instability can
make decision trees sensitive to the specific training dataset, requiring caution when deploying the model in
different environments.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Not Suitable for Complex Relationships&lt;/strong&gt;: Decision trees may not capture complex relationships in the data as
effectively as more advanced algorithms.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Biased Toward Dominant Classes&lt;/strong&gt;: In classification problems with imbalanced classes, decision trees can be biased
toward the dominant class. This can impact the model&apos;s performance, especially when accurate predictions for minority
classes are crucial.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Not Well-Suited for Regression&lt;/strong&gt;: While decision trees are excellent for classification tasks, they may not perform
as well for regression tasks on continuous data. Other algorithms like linear regression or support vector machines
might be more appropriate in such cases.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Conclusion&lt;/h2&gt;
&lt;p&gt;In conclusion, decision trees are powerful tools with a clear structure and interpretability. Understanding their
components, loss functions, and characteristics will help you effectively apply and interpret this versatile algorithm.&lt;/p&gt;
</content:encoded><category>blog</category><category>ml</category><author>Anshul Raj Verma</author></item><item><title>ContentType Prediction</title><link>https://arv-anshul.github.io/projects/yt-watch-history/ctt</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/yt-watch-history/ctt</guid><description>Built a ContentType prediction model to predict the content type of YouTube videos using it&apos;s title, descriptions and, tags.</description><pubDate>Sat, 27 Jan 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I am building the ContentType Prediction System from scratch, this it is robuster, flexible and scalable.&lt;/p&gt;
&lt;p&gt;&amp;lt;figure&amp;gt;
&amp;lt;img class=&quot;bg-gray-800 dark:bg-transparent&quot; src=&quot;../assets/ml-system-diagram.png&quot; alt=&quot;ml-system-diagram.png&quot; /&amp;gt;
&amp;lt;figcaption&amp;gt;ML System Diagram for &quot;ContentType Prediction System&quot;&amp;lt;/figcaption&amp;gt;
&amp;lt;/figure&amp;gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;I have created custom &lt;code&gt;sklearn&lt;/code&gt; transformers to transform the datasets. &lt;em&gt;But it is not that good.&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;I also implemented the model monitoring part using abstraction classes. I do monitoring using &lt;code&gt;mlfow&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;I also write scripts for the reference about how to monitor, train and predict models, through this I want to give you
some idea that how does this pipeline works. &lt;em&gt;These scripts are for reference only.&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Custom Transformers Using &lt;code&gt;sklearn&lt;/code&gt;&lt;/h2&gt;
&lt;p&gt;Yesterday, I have learned how to create a custom transformer using &lt;code&gt;sklearn&lt;/code&gt; API.&lt;/p&gt;
&lt;p&gt;I find it very useful and very elegant way to create pipelines with it. They are very simple to use and implement when
you get it right.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!IMPORTANT] A high level info about custom transformers.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Create a class which inherit two &lt;code&gt;sklearn&lt;/code&gt; classes from &lt;code&gt;sklearn.base&lt;/code&gt; module &lt;code&gt;TransformerMixin&lt;/code&gt; and
&lt;code&gt;BaseEstimator&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Now, you have to define &lt;code&gt;fit&lt;/code&gt; and &lt;code&gt;transform&lt;/code&gt; methods in your class.&lt;/li&gt;
&lt;li&gt;And you are ready to use this custom transformer.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Remember this is not a fully pleged custom class because there are numerous things you have to keep in mind while
making a custom transformer using &lt;code&gt;sklearn&lt;/code&gt; API.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;[!IMPORTANT] References&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://youtu.be/h1BnRBzYjYY&quot;&gt;Professional Preprocessing with Pipelines in Python - NeuralNine&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://youtu.be/6zAPRfhDg7Q&quot;&gt;Developing a Custom Scikit-learn Transformer and Estimatior - Ploomber&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://ploomber.io/blog/sklearn-custom/&quot;&gt;Developing custom scikit-learn transformers and estimators&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Monitoring With &lt;code&gt;mlflow&lt;/code&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;1st Draft&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I have think a custom monitoring pipeline where you pass the model and params with the training and testing set. Then it
calculate the score and log it with &lt;code&gt;mlflow&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;&amp;lt;figure&amp;gt;
&amp;lt;img src=&quot;../assets/mlflow-monitoring-draft-1.png&quot; alt=&quot;mlflow-monitoring-draft-1.png&quot; /&amp;gt;
&amp;lt;figcaption&amp;gt;MLFlow UI showing scores of multiple trained models on bar chart.&amp;lt;/figcaption&amp;gt;
&amp;lt;/figure&amp;gt;&lt;/p&gt;
</content:encoded><category>project</category><category>project</category><category>ml</category><author>Anshul Raj Verma</author></item><item><title>ML System Doubts</title><link>https://arv-anshul.github.io/blog/2024/ml-systems-doubts</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/ml-systems-doubts</guid><description>My doubts around creating and working ML Systems.</description><pubDate>Wed, 24 Jan 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I&apos;ve been working on a &lt;strong&gt;project of Machine Learning&lt;/strong&gt; where I am using Docker to containerise my applications (frontend
and backend). But I&apos;m facing difficulties while using ML models in the containers.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!WARNING] Question&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;How to train the model and also use MLFlow for model monitoring?&lt;/li&gt;
&lt;li&gt;I don&apos;t know how to integrate the ML models in the containers.
&lt;ol&gt;
&lt;li&gt;Should I deploy my models in cloud and from there I can fetch the models for prediction?&lt;/li&gt;
&lt;li&gt;Should I add the models into the container from which I can easily make prediction?&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;h2&gt;MLFlow&lt;/h2&gt;
&lt;p&gt;In my project &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history&quot;&gt;Project on GitHub&lt;/a&gt; &lt;code&gt;yt-watch-history&lt;/code&gt;, I am using MLFlow
(but not using it also) means I have written code to train the model with MLFlow but I can also train without it (and I
always use this only).&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!WARNING] Question&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Should I train the model using MLFLow or just do the model monitoring while Hyper-parameter Tuning?&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Containers&lt;/h2&gt;
&lt;h3&gt;What I am doing right now?&lt;/h3&gt;
&lt;p&gt;I am training the models before starting the container and after, training the models and starting I do predictions
using those models by mounting the directories (where models are stored).&lt;/p&gt;
&lt;h3&gt;What should I have to do?&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;I can train the model locally and deploy it on the cloud and then fetch and &lt;em&gt;store*&lt;/em&gt; the model while prediction.&lt;/li&gt;
&lt;li&gt;I can containerise the model too with the codes which makes it easy to use and locate. But comes with many
disadvantages like scalability, container&apos;s size, model availability/redundancy and more.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Databases&lt;/h2&gt;
&lt;p&gt;I have been using this as &lt;strong&gt;optional&lt;/strong&gt; step because I never use database model training purpose. I prefer to fetch the
data from database and store them into local files and then use them for all the steps.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!WARNING] How should I use them for model training?&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Should I always fetch data from databases for training?&lt;/li&gt;
&lt;li&gt;Should I fetch the data once and do all the required steps like data preprocessing, data transformation, features
selection, model training and all? &lt;em&gt;I think this is a better approach.&lt;/em&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
</content:encoded><category>blog</category><category>mlops</category><author>Anshul Raj Verma</author></item><item><title>YouTube Watch History</title><link>https://arv-anshul.github.io/projects/yt-watch-history</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/yt-watch-history</guid><description>A streamlit app where you can upload your YouTube Watch History Data to see insights on your viewing pattern. Your data will go through a ML Model which predicts the ContentType of each video your have watch. The app fetches more details of each video through YouTube API. There is also a Channel Recommender System in the app which recommend you similar channels on the basis of channel&apos;s video titles and tags they had used.</description><pubDate>Sun, 21 Jan 2024 00:00:00 GMT</pubDate><content:encoded>&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Project Introduction&lt;/strong&gt;: Hello, I am Anshul Raj Verma and I am exited to share my end-to-end Machine Learning
project where I&apos;ve used &lt;strong&gt;FastAPI, Streamlit, MongoDB and Docker&lt;/strong&gt; as tech stack. Also &lt;strong&gt;this is version 2 of the
project&lt;/strong&gt; because the &lt;strong&gt;version 1 got very complicated&lt;/strong&gt; and it&apos;s hard to modify and refactor the codes there that&apos;s
why created new version 2 where I am trying to keep better attention on project architecture.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Project Overview&lt;/strong&gt;: This project consists a streamlit app where you can upload your &lt;strong&gt;YouTube Watch History Data&lt;/strong&gt;
to see insights on your viewing pattern. Your data will go through an ML Model which predicts the &lt;strong&gt;ContentType&lt;/strong&gt; of
each uploaded video. The app fetches more details of each video through &lt;strong&gt;YouTube API&lt;/strong&gt;. There is also a &lt;strong&gt;Channel
Recommender System&lt;/strong&gt; in project which recommend you similar channels on the basis of channel&apos;s videos title and tags
they had used.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Components of Project&lt;/strong&gt;: The project is divided into three major components &lt;strong&gt;Backend API&lt;/strong&gt;, &lt;strong&gt;ML&lt;/strong&gt; &amp;amp; &lt;strong&gt;Frontend&lt;/strong&gt;.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Backend API&lt;/strong&gt;: This is a FastAPI app which interacts with MongoDB database where YouTube videos details were
stored and it also fetches YouTube videos details from official &lt;strong&gt;YouTube Data API&lt;/strong&gt; (for this you require the
&lt;code&gt;API_KEY&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;ML&lt;/strong&gt;: Here the code for ML Model were present through they will get trained and do predictions on user&apos;s uploaded
data after some preprocessing. The ML Models get served as API through a FastAPI app.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Frontend&lt;/strong&gt;: Here all the above components meets and work together to show awesome insights on user&apos;s uploaded
data. This is a streamlit web app where users can upload their watch history data and see insights. Here above API
services were called to fetch videos details from official YouTube API, to store data in database, to make
predictions using ML Models, to recommend channels and etc.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Project Architecture&lt;/strong&gt;: I have created some diagrams to showcase the project&apos;s architecture and for that created a
&lt;a href=&quot;v2-architecture.md&quot;&gt;dedicated page&lt;/a&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Containerization with Docker&lt;/strong&gt;: All the three components (&lt;strong&gt;Backend API&lt;/strong&gt;, &lt;strong&gt;ML&lt;/strong&gt; &amp;amp; &lt;strong&gt;Frontend&lt;/strong&gt;) of project were
containerized using docker and used &lt;code&gt;docker compose&lt;/code&gt; to wrap all three images in a container.
&lt;a href=&quot;https://astral.sh/uv&quot;&gt;&lt;code&gt;uv&lt;/code&gt;&lt;/a&gt; is used to install packages in docker images. &lt;code&gt;mongodb&lt;/code&gt; image is used as database for
the project.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;More in Project&lt;/strong&gt;: As I am learning MLOps concepts I am trying to implement them in this project because planning
to add DVC and MLFlow into the project.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>project</category><category>project</category><category>ml</category><category>eda</category><author>Anshul Raj Verma</author></item><item><title>Channel Recommender System</title><link>https://arv-anshul.github.io/projects/yt-watch-history/channel-recommender</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/yt-watch-history/channel-recommender</guid><description>A recommender system to recommend channel similar Youtube channels based viewer&apos;s videos&apos; data.</description><pubDate>Sun, 21 Jan 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I&apos;ve built &lt;code&gt;contentType&lt;/code&gt; prediction pipeline using videos titles. Now, I am thinking that what if I can recommend
similar channels on the basis of their subscribed channels. I can recommend channels using channel&apos;s videos titles and
videos tags.&lt;/p&gt;
&lt;h2&gt;Training Pipeline&lt;/h2&gt;
&lt;h3&gt;Data Ingestion and Preprocessing&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;System import data from two types of sources &lt;code&gt;db&lt;/code&gt; (database) and &lt;code&gt;file&lt;/code&gt; (local file).&lt;/li&gt;
&lt;li&gt;Next, I validate the data on the basis of columns present in the data.&lt;/li&gt;
&lt;li&gt;Then data goes for preprocessing step, during this step data is being clean and all the required feature has been
extracted from it using &lt;a href=&quot;https://pola.rs&quot;&gt;Polars&lt;/a&gt; library.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Model Overview&lt;/h3&gt;
&lt;p&gt;As you know I am working with videos title and tags which are textual data so I&apos;ve used &lt;code&gt;TfidfVectorizer&lt;/code&gt; (for text to
vector conversion). I&apos;ve used two &lt;code&gt;TfidfVectorizer&lt;/code&gt; for each column (&lt;code&gt;title&lt;/code&gt; and &lt;code&gt;tags&lt;/code&gt;) and then used
&lt;code&gt;ColumnTransformer&lt;/code&gt; to create a (sort of) chain transformation step.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;def&lt;/span&gt;&lt;span&gt; get_vectorizer&lt;/span&gt;&lt;span&gt;() -&amp;gt; ColumnTransformer:&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    title_transformer = TfidfVectorizer(&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        max_features&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;7000&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        ngram_range&lt;/span&gt;&lt;span&gt;=(&lt;/span&gt;&lt;span&gt;1&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;2&lt;/span&gt;&lt;span&gt;),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        preprocessor&lt;/span&gt;&lt;span&gt;=preprocess_title,  &lt;/span&gt;&lt;span&gt;# Preprocess texts of `title` column.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        stop_words&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;english&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    )&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    tags_transformer = TfidfVectorizer(&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        max_features&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;5000&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        ngram_range&lt;/span&gt;&lt;span&gt;=(&lt;/span&gt;&lt;span&gt;1&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;2&lt;/span&gt;&lt;span&gt;),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        preprocessor&lt;/span&gt;&lt;span&gt;=preprocess_tags,  &lt;/span&gt;&lt;span&gt;# Preprocess texts of `tags` column.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        stop_words&lt;/span&gt;&lt;span&gt;=&lt;/span&gt;&lt;span&gt;&quot;english&quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    )&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    transformer = ColumnTransformer(&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        [&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            (&lt;/span&gt;&lt;span&gt;&quot;title_trf&quot;&lt;/span&gt;&lt;span&gt;, title_transformer, &lt;/span&gt;&lt;span&gt;&quot;title&quot;&lt;/span&gt;&lt;span&gt;),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;            (&lt;/span&gt;&lt;span&gt;&quot;tags_trf&quot;&lt;/span&gt;&lt;span&gt;, tags_transformer, &lt;/span&gt;&lt;span&gt;&quot;tags&quot;&lt;/span&gt;&lt;span&gt;),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        ]&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    )&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    return&lt;/span&gt;&lt;span&gt; transformer&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h3&gt;Data to Export&lt;/h3&gt;
&lt;p&gt;Now, I&apos;ve successfully built the pipeline and trained the system but there comes a question that how to recommend a
channel and for that I&apos;ve to export some essential data like &lt;strong&gt;the vectorized array&lt;/strong&gt; (vectorized videos titles and
tags) with its metadata like &lt;code&gt;channelId&lt;/code&gt; and &lt;code&gt;channelTitle&lt;/code&gt;. To tackle this thing I&apos;ve combine these data and created a
&lt;code&gt;pl.DataFrame&lt;/code&gt; and then export it as &lt;strong&gt;&lt;code&gt;parquet&lt;/code&gt;&lt;/strong&gt; format.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;def&lt;/span&gt;&lt;span&gt; training&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    input_data&lt;/span&gt;&lt;span&gt;: Literal[&lt;/span&gt;&lt;span&gt;&quot;db&quot;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&quot;file&quot;&lt;/span&gt;&lt;span&gt;],&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    # Extra code hidden...&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    df = preprocess_data(df)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    transformer = get_vectorizer()&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    transformed_data = transformer.fit_transform(df.to_pandas())&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    # Combine transformed_data, channelId, channelTitle as DataFrame&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    title_tags_trf_df = df.select(&lt;/span&gt;&lt;span&gt;&quot;channelId&quot;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&quot;channelTitle&quot;&lt;/span&gt;&lt;span&gt;).with_columns(&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        pl.lit(transformed_data.toarray()).alias(&lt;/span&gt;&lt;span&gt;&quot;transformed_data&quot;&lt;/span&gt;&lt;span&gt;)  &lt;/span&gt;&lt;span&gt;# type: ignore&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    )&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    dump_object(transformer, CH_RECO_TRANSFORMER_PATH)  &lt;/span&gt;&lt;span&gt;# Export `ColumnTransformer` object.&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    # Export dataframe as parquet format for lesser size&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    title_tags_trf_df.write_parquet(CH_RECO_TRANSFORMER_DATA_PATH)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;[!IMPORTANT] What is parquet format?&lt;/p&gt;
&lt;p&gt;Parquet is a columnar storage format that provides compression benefits and is particularly suitable for analytical
queries.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Prediction Pipeline&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;I&apos;m calling this step as &lt;strong&gt;Prediction Pipeline&lt;/strong&gt; 🙂 because it doesn&apos;t feels good to call &lt;strong&gt;Reccommendation Pipeline&lt;/strong&gt;
😞.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Here, I&apos;ve to get any channel&apos;s data (videos titles and tags) to transform using stored &lt;code&gt;ColumnTransformer&lt;/code&gt; object.
After, transforming the data I&apos;ve calculated &lt;code&gt;cosine_similarity&lt;/code&gt; between new channel&apos;s vector and vector which I have
stored on training step and from that whichever channel has greater similarity value is being reccommended to the user
🤩.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;def&lt;/span&gt;&lt;span&gt; prediction&lt;/span&gt;&lt;span&gt;(&lt;/span&gt;&lt;span&gt;data&lt;/span&gt;&lt;span&gt;: pl.DataFrame):&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    # Extra code hidden...&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    transformer: ColumnTransformer = load_object(CH_RECO_TRANSFORMER_PATH)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    transformer_data = pl.read_parquet(CH_RECO_TRANSFORMER_DATA_PATH)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    transformed_data = transformer.transform(data.to_pandas())&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    similarity = cosine_similarity(&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        np.array(transformer_data[&lt;/span&gt;&lt;span&gt;&quot;transformed_data&quot;&lt;/span&gt;&lt;span&gt;].to_list()),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        transformed_data.toarray(),  &lt;/span&gt;&lt;span&gt;# type: ignore&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    )&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    return&lt;/span&gt;&lt;span&gt; transformer_data.select(&lt;/span&gt;&lt;span&gt;&quot;channelId&quot;&lt;/span&gt;&lt;span&gt;, &lt;/span&gt;&lt;span&gt;&quot;channelTitle&quot;&lt;/span&gt;&lt;span&gt;).with_columns(&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        pl.lit(np.ravel(similarity)).alias(&lt;/span&gt;&lt;span&gt;&quot;similarity&quot;&lt;/span&gt;&lt;span&gt;),&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    )&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2&gt;Extra&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;[!NOTE] Recommendation System Summary&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Ingesting data from database or local file. I had made API endpoint to fetch data from datbase.&lt;/li&gt;
&lt;li&gt;Using Polars library for data manipulation.&lt;/li&gt;
&lt;li&gt;This recommender system trained on &lt;strong&gt;YouTube Channel&apos;s Videos titles and tags&lt;/strong&gt; which means it recommend on the
basis of the channel&apos;s videos contents like title and tags.&lt;/li&gt;
&lt;li&gt;Used &lt;code&gt;TfidfVectorizer&lt;/code&gt; for text-to-vec conversion.&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Provide Weights to Vectorizer&lt;/h3&gt;
&lt;p&gt;Previously, I thought that I can add a functionality to provide weights to each vectorizer (&lt;code&gt;TfidfVectorizer&lt;/code&gt;) to make
the system more robust and I had achieved it
(&lt;a href=&quot;https://github.com/arv-anshul/notebooks/blob/main/yt-watch-history/1.0_ChannelRecoSys.ipynb&quot;&gt;See Notebook&lt;/a&gt;) but not
feels good while actual implementation because it creates so much objects to store and makes the prediction
(recommendation) step complex.&lt;/p&gt;
&lt;p&gt;I have to store each vectorizer, vectorized data (title and tags) and the metadata (&lt;code&gt;channelId&lt;/code&gt; and &lt;code&gt;channelTitle&lt;/code&gt;) too
which this pipeline complex and hard to keep track of objects.&lt;/p&gt;
&lt;h3&gt;Adding more Features&lt;/h3&gt;
&lt;p&gt;I have tried to add more features like &lt;code&gt;categoryName&lt;/code&gt; (channel owner provide category of the video while uploading) and
&lt;code&gt;contentTypePred&lt;/code&gt; (a feature I have predicted using ML) but I found it difficult to implement and it doesn&apos;t show much
affect while recommending. That&apos;s why I thought a different idea to implement this.&lt;/p&gt;
&lt;p&gt;I can filter the recommended channels on the basis of &lt;code&gt;categoryName&lt;/code&gt; and &lt;code&gt;contentTypePred&lt;/code&gt; in the frontend part (yeah
this not the right way of doing this but I&apos;ll think about it later).&lt;/p&gt;
&lt;hr /&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history/blob/main/backend/ml/channel_reco&quot;&gt;&lt;strong&gt;Code on GitHub&lt;/strong&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/notebooks/blob/main/yt-watch-history/1.1_ChannelRecoSys.ipynb&quot;&gt;&lt;strong&gt;Pipeline in Notebook&lt;/strong&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;🙏 Thank You for reading this. I am &lt;a href=&quot;https://github.com/arv-anshul&quot;&gt;Anshul Raj Verma&lt;/a&gt; and I am
a Data Scientist.&lt;/strong&gt;&lt;/p&gt;
</content:encoded><category>project</category><category>project</category><category>recommender-system</category><category>ml</category><author>Anshul Raj Verma</author></item><item><title>Channel Recommender System V2</title><link>https://arv-anshul.github.io/projects/yt-watch-history/v2-channel-recommender</link><guid isPermaLink="true">https://arv-anshul.github.io/projects/yt-watch-history/v2-channel-recommender</guid><description>Channel Recommender System using YT channel&apos;s videos title and tags.</description><pubDate>Sun, 21 Jan 2024 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;The system starts with preprocessing the video titles and tags by tokenizing, removing stop words, and
stemming/lemmatizing them. Then, these texts are vectorized using TF-IDF to convert them into numerical form. The
feature vectors are used to calculate similarities between channels using cosine similarity. The channels are ranked
based on these similarity scores, and the top-N channels are recommended to the user.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;This approach leverages the content-based filtering technique to find and recommend channels that have similar video
titles and tags to those the user has already watched, ensuring relevant and personalized recommendations.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2&gt;Approach Layers&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Input Layer:&lt;/strong&gt; Accepts video titles and tags.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Text Processing Layer:&lt;/strong&gt; Applies tokenization, stop words removal, and stemming/lemmatization.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Vectorization Layer:&lt;/strong&gt; Converts processed text to TF-IDF vectors.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Similarity Calculation Layer:&lt;/strong&gt; Computes similarities between channels using cosine similarity.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Recommendation Layer:&lt;/strong&gt; Ranks channels based on similarity scores and recommends the top-N channels.&lt;/li&gt;
&lt;/ol&gt;
&lt;pre&gt;&lt;code&gt;&lt;span&gt;&lt;span&gt;graph&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    subgraph DataPreprocessing&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        C(Tokenization) --&amp;gt; D(Stop Words Removal)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        D --&amp;gt; E(Stemming/Lemmatization)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        E --&amp;gt; F(TF-IDF Vectorization)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    end&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    subgraph SimilarityCalculation&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        G(Feature Vectors) --&amp;gt; H(Similarity Calculation)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;        H --&amp;gt; I(Channel Recommendations)&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    end&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    A1(Video Title) --&amp;gt; DataPreprocessing&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    A2(Video Tags) --&amp;gt; DataPreprocessing&lt;/span&gt;&lt;/span&gt;
&lt;span&gt;&lt;span&gt;    DataPreprocessing --&amp;gt; pca{{PCA}} --&amp;gt; SimilarityCalculation&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2&gt;Process Explanation&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Data Preprocessing:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Tokenization:&lt;/strong&gt; Split titles and tags into individual words or phrases.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Stop Words Removal:&lt;/strong&gt; Remove common words that do not add value to the recommendation (e.g., &quot;the&quot;, &quot;and&quot;).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Stemming/Lemmatization:&lt;/strong&gt; Reduce words to their base form to handle different variations.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Vectorization:&lt;/strong&gt; Convert the processed text into numerical vectors using methods like TF-IDF (Term
Frequency-Inverse Document Frequency).&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Feature Extraction:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;TF-IDF Vectorizer:&lt;/strong&gt; Transform the textual data into feature vectors.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Dimensionality Reduction:&lt;/strong&gt; Optionally, use techniques like PCA (Principal Component Analysis) to reduce the
feature space.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Model Training:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Content-Based Filtering:&lt;/strong&gt; Calculate the similarity between videos using cosine similarity or other distance
metrics.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Training Algorithm:&lt;/strong&gt; Use algorithms like k-Nearest Neighbors (k-NN) for finding similar channels based on the
content similarity of their videos.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Recommendation:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;For a given user&apos;s watched history, calculate the similarity scores of channels and recommend the top-N channels
with the highest scores.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>project</category><category>project</category><category>ml</category><category>recommender-system</category><author>Anshul Raj Verma</author></item><item><title>Dev Journal</title><link>https://arv-anshul.github.io/blog/2024/journal</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2024/journal</guid><description>Conventions to follow for Dev Journal entries.</description><pubDate>Mon, 08 Jan 2024 09:44:00 GMT</pubDate><content:encoded>&lt;p&gt;I came to know about &lt;strong&gt;Dev Journal&lt;/strong&gt; &lt;a href=&quot;https://youtu.be/hcQ7avj6Zrg&quot;&gt;from this YouTube video&lt;/a&gt;.&lt;/p&gt;
&lt;h2&gt;My Thought&lt;/h2&gt;
&lt;p&gt;It is a very easy and good way to review yourself on weekly basis. Using this you can keep track of your learning and
improvement.&lt;/p&gt;
&lt;h2&gt;Convention&lt;/h2&gt;
&lt;p&gt;Using this I will be able to follow a set of instructions which helps me to write my Dev Journal in a pre-defined
manner.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I have wrote snippets for this for
&lt;a href=&quot;https://github.com/arv-anshul/diary/tree/main/.vscode/dev-journal.code-snippets&quot;&gt;vscode&lt;/a&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;ol&gt;
&lt;li&gt;Monthly journal file starts with &lt;code&gt;# Journal of &amp;lt;month-name&amp;gt;&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Journal will&apos;be maintain on weekly basis.&lt;/li&gt;
&lt;li&gt;Weekly Journal titled as &lt;code&gt;## Week &amp;lt;week-num&amp;gt; Journal&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Weekly Section doesn&apos;t contains any other sub-section.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Tips (using &lt;code&gt;ollama&lt;/code&gt;)&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Focus on the tasks that you completed during the week and what you learned from them.&lt;/li&gt;
&lt;li&gt;Don&apos;t be afraid to include any mistakes or errors that you made during the week. It helps to learn and improve from
them.&lt;/li&gt;
&lt;li&gt;Use this as an opportunity to reflect on your progress and identify areas for improvement.&lt;/li&gt;
&lt;li&gt;Keep your journal entries concise and focused, around one page or less.&lt;/li&gt;
&lt;li&gt;Consider sharing your journal entries with a mentor or colleague for feedback and support.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Citations&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://youtu.be/hcQ7avj6Zrg&quot;&gt;Travis Media Video&lt;/a&gt;: Inspired from this video.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://betterprogramming.pub/advices-from-a-software-engineer-with-8-years-of-experience-8df5111d4d55&quot;&gt;Advice From a Software Engineer With 8 Years of Experience | by Benoit Ruiz&lt;/a&gt;:
The article discuss in the video.&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://docs.google.com/document/d/1PK1HGa3HViKSJhAhvQgZNEYB72J0DhcXPNKuSpI4N80/edit&quot;&gt;Work log template for Software Engineers (The Pragmatic Engineer)&lt;/a&gt;:
The Google Doc in which the article writer written his Dev Journal. (Maybe this doc is for reference)&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://blog.pragmaticengineer.com/templates-as-inspiration-for-software-engineers/&quot;&gt;Templates as Inspiration for Software Engineers and Engineering Managers - The Pragmatic Engineer&lt;/a&gt;:
Extra content for this thing.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>journal</category><category>diary</category><author>Anshul Raj Verma</author></item><item><title>January Journal</title><link>https://arv-anshul.github.io/journal/2024/01</link><guid isPermaLink="true">https://arv-anshul.github.io/journal/2024/01</guid><description>Weekly Journal by ARV of January 2024</description><pubDate>Mon, 01 Jan 2024 00:00:00 GMT</pubDate><content:encoded>&lt;h2&gt;Week 1: Dev Journal of January&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;ruff&lt;/code&gt;&lt;/strong&gt;: An amazing python code linter and formatter with very high performance, written in Rust.
&lt;ul&gt;
&lt;li&gt;Ruff GitHub: &lt;a href=&quot;https://github.com/astral-sh/ruff&quot;&gt;https://github.com/astral-sh/ruff&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;Docker&lt;/code&gt;&lt;/strong&gt;: Containerise your application.
&lt;ul&gt;
&lt;li&gt;You can containerise multiple apps using &lt;code&gt;docker-compose&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;There are many concepts in docker I have learned &lt;strong&gt;Docker Volumes, Port Expose, Environment Variables
Initialisation&lt;/strong&gt;. Left out concepts: &lt;strong&gt;Docker Networking, Docker Hub, etc.&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;pyproject.toml&lt;/code&gt;&lt;/strong&gt;: New way to configure you Python project.
&lt;ul&gt;
&lt;li&gt;I used this to configure my &lt;code&gt;ruff&lt;/code&gt; configs.&lt;/li&gt;
&lt;li&gt;I have not completely learned this configs management file exclusively regarding python projects.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Because this is the first week of the year, I have reviewed my configuration files from GitHub repository and GitHub
Gist.
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/dotfiles&quot;&gt;https://github.com/arv-anshul/dotfiles&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/dotfiles&quot;&gt;https://github.com/arv-anshul/dotfiles&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://gist.github.com/arv-anshul/&quot;&gt;https://gist.github.com/arv-anshul/&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;Ruff is amazing because it combines both linting and formatting together with its amazing performance speed ⚡.&lt;/li&gt;
&lt;li&gt;Docker makes your application very easy to setup for other developer.&lt;/li&gt;
&lt;li&gt;Learning MLOps is very iterative, disgusting, and many more. But when you learn it you will be like &lt;strong&gt;&quot;WOW! What a
service, product, concept.&quot;&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 2: Dev Journal of January&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;VSCode UI Settings&lt;/strong&gt;: Explore settings in VS Code IDE which will modify its UI colour (mainly).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Discussed Cold Turkey Blocker issue on Windows&lt;/strong&gt;: Windows have the path related issue.
&lt;a href=&quot;https://github.com/arv-anshul/ColdTurkeyBlocker-Pro&quot;&gt;Repository&lt;/a&gt; |
&lt;a href=&quot;https://github.com/arv-anshul/ColdTurkeyBlocker-Pro/issues/2&quot;&gt;GH2&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Aggregation Pipeline in MongoDB&lt;/strong&gt;: Used aggregation pipeline in my project which makes it easy to deal with data. I
don&apos;t explicitly merging the datasets in the script.
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history/commit/291ffdf796828ec301c0f8058ed1d2b27c73c517&quot;&gt;Commit&lt;/a&gt; where I
did this in my &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history&quot;&gt;yt-watch-history&lt;/a&gt; project.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;Creating ML system is very tedious. I am trying to understand how to integrate these amazing tools in this. ALthough,
I am able to train and do prediction with my ML Model but I am not satisfied with my approach. Thats why I am
learning new ways to design these systems.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 3: Dev Journal of January&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;mkdocs-material&lt;/code&gt;&lt;/strong&gt;: I have this amazing documentation maker using &lt;code&gt;.md&lt;/code&gt; files in 1 day (almost). You can see my
personal website hosted with &lt;a href=&quot;https://arv-anshul.github.io&quot;&gt;GitHub Pages&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Freelance&lt;/strong&gt;: &lt;a href=&quot;https://www.linkedin.com/in/theabhinav002&quot;&gt;@theabhinav002&lt;/a&gt; queried to create #web-scrapping APIs for
real estate website.
&lt;ul&gt;
&lt;li&gt;I have accepted the offer.&lt;/li&gt;
&lt;li&gt;Now, I am creating the web-scrapper for &lt;a href=&quot;https://housing.com&quot;&gt;housing.com&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history&quot;&gt;&lt;strong&gt;yt-watch-history&lt;/strong&gt;&lt;/a&gt;: I have been working around &lt;strong&gt;Channel
Recommendation System&lt;/strong&gt; which recommend channels on the basis of channel&apos;s videos title and tags. However, I have
completely build the model architecture but I wonder to put it in a pipeline to make it more concise to use and
define.
&lt;ul&gt;
&lt;li&gt;I have discussed this system with &lt;a href=&quot;https://github.com/arpitpatel01&quot;&gt;@arpitpatel01&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;Always write your thoughts whichever things you are working on because it helps you to understand your thoughts and
also helps you that how you explain your things or projects.&lt;/li&gt;
&lt;li&gt;While my freelancing process I feel like I am at my full potential and I&apos;ve almost completed the project in 3-4 days.
I have written code to scrape housing.com. Also created APIs around it using &lt;code&gt;FastAPI&lt;/code&gt; framework.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 4: Dev Journal of January&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history&quot;&gt;&lt;strong&gt;&lt;code&gt;yt-watch-history&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;: This week I spend all the time on
refactoring and understanding my project. It feels very difficult to work on but I made my mind and say that here &lt;strong&gt;I
can push and pass my limits&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Custom Transformers using &lt;code&gt;sklearn&lt;/code&gt; API&lt;/strong&gt;: I have not totally learned how to create a custom transformer using
&lt;code&gt;sklearn&lt;/code&gt; API but I got the idea of it how to use it. Also, I have wrote some custom classes and tested it (it works
well).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;New Realease&lt;/strong&gt;: I have released &lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history/releases/tags/v0.0.1&quot;&gt;&lt;code&gt;v0.0.1&lt;/code&gt;&lt;/a&gt; of
&lt;code&gt;yt-watch-history&lt;/code&gt; project.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;You can create your custom transformer using &lt;code&gt;sklearn&lt;/code&gt; and then put them into a pipeline which works like magic.&lt;/li&gt;
&lt;li&gt;I am going to break my limit with this project (&lt;a href=&quot;https://github.com/arv-anshul/yt-watch-history&quot;&gt;&lt;code&gt;yt-watch-history&lt;/code&gt;&lt;/a&gt;)
because in this I am using too many new concepts like Docker, MLFlow, Custom &lt;code&gt;sklearn&lt;/code&gt; transformers (recently). Now,
I am thinking about &lt;strong&gt;AWS&lt;/strong&gt; 🤩.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Week 5: Dev Journal of January&lt;/h2&gt;
&lt;h3&gt;Learning&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href=&quot;https://learnwith.campusx.in&quot;&gt;&lt;code&gt;learnwith.campusx.in&lt;/code&gt;&lt;/a&gt;&lt;/strong&gt;: I have written a script which goes through the html of
the website and using the &lt;code&gt;cookies&lt;/code&gt; it fetches the resources which were provided in the videos&apos; description.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Learning ML Concepts&lt;/strong&gt;: I have learned how &lt;strong&gt;Gini Impurity/Index&lt;/strong&gt; works by practicing it on paper with my hand and
pencil. &lt;strong&gt;This helps me a lot and I (sort of) figured out, how should I learn things in ML.&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Blog on Decision Tree&lt;/strong&gt;: I published a blog on decision tree on my
&lt;a href=&quot;https://arv-anshul.github.io/blog/category/ml/&quot;&gt;website&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;Thoughts&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Frustration&lt;/strong&gt;: In these few days, I am not feeling that inspiration while doing anything. I feel frustrated and
difficult to focus on things. It is like something which I can&apos;t express but it is bad for me.&lt;/li&gt;
&lt;/ol&gt;
</content:encoded><category>journal</category><category>journal</category><category>january</category><author>Anshul Raj Verma</author></item><item><title>MLOps session by Pranjal Sir</title><link>https://arv-anshul.github.io/blog/2023/pranjal-sir</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2023/pranjal-sir</guid><description>Learning MLOps and making notes about it.</description><pubDate>Mon, 27 Nov 2023 08:24:00 GMT</pubDate><content:encoded>&lt;blockquote&gt;
&lt;p&gt;On 27 November, 2023 I am learning MLOps with CampusX DSMP 2.0 Course from &lt;a href=&quot;https://github.com/PranY&quot;&gt;@PranjalSir&lt;/a&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;He introduced us MLOps in a very interesting way with a analogy of &lt;strong&gt;Organising a Concert for World Cup Final&lt;/strong&gt;. You can
read &lt;a href=&quot;https://github.com/arv-anshul/campusx-mlops&quot;&gt;this notebook&lt;/a&gt; to see that beautiful analogy to get the high level
idea about MLOps.&lt;/p&gt;
&lt;p&gt;In MLOps, you have to learn many different tools to manage your codes, data, ML models and to visualize the model
performance and many different things. Tools like Git, DVC, CookieCutter, DataBases, Cloud Services, Jira, Prometheus,
Grafana, etc.&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>person</category><author>Anshul Raj Verma</author></item><item><title>I met Natrajan Sir</title><link>https://arv-anshul.github.io/blog/2023/i-met-natrajan</link><guid isPermaLink="true">https://arv-anshul.github.io/blog/2023/i-met-natrajan</guid><description>He told market yourself and do Kaggle competitions.</description><pubDate>Fri, 27 Oct 2023 13:31:00 GMT</pubDate><content:encoded>&lt;p&gt;Today I realize that I again met another great guy @NatarajanLalgudi. He is just a amazing person. His style of talking,
way of understanding and his opinion on a data is just interesting and amazing.&lt;/p&gt;
&lt;p&gt;He teaches me many things in just few days such as document your projects and share it with other which works as
marketing of yourself and I follow this advice and this works too. I learned a lot things from him.&lt;/p&gt;
&lt;p&gt;We met while exchanging &lt;strong&gt;Real Estate Datasets&lt;/strong&gt; which I scrapped from 99acres.com he said like you scrapped this
amazing data, you are amazing; you have to document this scrapping project and share with others also upload this data
on kaggle too with a proper documentation. So I did and it works well.&lt;/p&gt;
&lt;p&gt;Today we connect on g-meet and he shows his works on the dataset and it looks fabulous I was just stun. He also suggest
me to market yourself by sharing your knowledge and these yours awesome projects and also participate in Kaggle
competitions which enhance your knowledge and it reflects on your CV too.&lt;/p&gt;
&lt;p&gt;So I decided that I am going to move my focus from GitHub streak to Kaggle and Data Science concepts.&lt;/p&gt;
&lt;p&gt;Thank You&amp;lt;br&amp;gt; Natarajan Sir&lt;/p&gt;
</content:encoded><category>blog</category><category>thoughts</category><category>person</category><category>friends</category><author>Anshul Raj Verma</author></item></channel></rss>