How I got started building in Open Source

Learning deep learning got me into Linux

In my second to the last year in college, I took a class in Deep Learning. During the class I found that building and testing models in Unix was much easier than in Windows. At the time I was using a M2 Macbook Air although I found that the processing power was not good enough for the models I was trying to build. Build times were taking around an hour so I decided to look for a more powerful machine.

Coincidentally, I already had a computer at home that I could use. It was a Windows computer with a RTX 3060Ti graphics card that I used mainly for playing League of Legends and Civilization 6 (the only two games I play). After developing for a while, I found that using Windows was a pain. Specifically, I was not very fond of the virtualization and development experience in Windows. Coding with windows felt like a chore although WSL made it bearable.

At that time, I decided to try out Linux. I installed Ubuntu on my machine and I was able to develop in a much more pleasant environment. I spent a good 3 months developing in Linux and learned a lot about the system. In parallel, I was experimenting with a lot of the open source models in Hugging Face that I could get my hands on. I felt like a kid in a candy store. It's really fun discovering Machine Learning for the first time.

Experimenting with open source models on Hugging Face

I used Segment Anything (SAM) for my class project, I experimented with stable diffusion as well and thought it was really cool. Honestly, I did not know why people would open source any of these models. I would have closed source it and made money off of it. Naive thoughts of course, but hey I'm honest.

Screenshot of video: `Contributing to Open Source Can Change Your Life - Here's How to Do It`

I dove deeper into open source. Why exactly were people open sourcing these models? I had no idea. All I knew was that I loved that it was open source. It was around this time that I was watching a lot of Andrew Ng and Andrej Karpathy's videos. Gaining insight into the fundamental principles (the mathematics) behind these models was immensely rewarding. As it turns out, every optimization revolved around gradient descent! And yet again, it was available for free!

I realized that they were open sourcing these models and resources because they enjoyed helping people. They liked teaching, and they enjoyed being part of the commmunity.

I dug deeper into the topic and discovered that the rationale behind open sourcing software is multifaceted.

  1. Firstly, it promotes safer and more secure software by allowing a diverse community of developers to scrutinize the code, identify vulnerabilities, and contribute fixes.
  2. This collective effort often leads to more robust security measures than what a single organization could achieve alone.
  3. Additionally, open sourcing facilitates rapid improvements in the software, as developers from around the world can collaborate, share ideas, and implement enhancements quickly.

Now that, I thought, was very cool.

After many hours of watching related videos, I eventually found a video called "Contributing to Open Source Can Change Your Life - Here's How to Do It". It was a video about how contributing to open source can change your life and potentially land you a job. I found the video to be quite thought-provoking as it made me reconsider my career trajectory. Here's a screenshot of said video:

Screenshot of video: `Contributing to Open Source Can Change Your Life - Here's How to Do It`

I found the idea of spending endless many hours solving LeetCode problems to secure a job unappealing. Incredibly unappealing. I wanted to engage in work I truly enjoyed. I found that working on practical and personal projects were more fulfiling than just doing Leet Code. To my surprise, building projects in public became a fantastic way to learn in line with my interests and attract potential employers. Two birds, one stone!

First Open Source Project: AutoGen UI

The very first project I built in public was a User Interface for AutoGen. AutoGen is a multi-agent framework built by Microsoft that allows you to build complex agents that can interact with each other.

At the time, the only way to interact with AutoGen was through the command line. Nobody had made a frontend for it. Streamlit also did not support multi-threaded conversations at the time. The only framework that supported multi-threaded conversations was Chainlit.

Using Chainlit, a python-first framework for building chatbot UI's, I built a modest 100-line code that received 90 stars on GitHub. The positive response was overwhelming, and messages of support poured in through different channels from discord, twitter, and even a blog post.

Screenshot of AutoGen User Interface

The Learning Curve: Next.js and Supabase

As I started building more projects, I got more and more interested in indie hacking. I was an amateur at frontend. I've only made many very few apps in React. After doing my research I ended up gravitating towards using Next.js for fullstack (frontend and backend) and Supabase for the database and authentication.

I found myself using Taxonomy many times as a starter template, but found myself heavily customizing it every time:

  1. Replacing Planetscale and Clerk with Supabase.
  2. Switching from Contentlayer to Velite for MDX compilation. Contentlayer was not being maintained at the time and no longer worked with Next.js 14.
  3. Integrating ShadcnUI components for faster development.

This repetitive setup process, while functional, was time-consuming and highlighted Taxonomy's limitations for my specific needs.

Recognizing the need for a more tailored solution, I created Hikari — a more modern, Supabase-powered version of Taxonomy, updated for Next.js 14.

Screenshot of Hikari's landing page

I built this project with the following features in mind:

  1. Full-Stack Integration:

    • Next.js 14 App Router
    • Supabase for backend and authentication
    • Stripe for payment processing
  2. Comprehensive UI Components:

    • Complete landing page with various sections
    • User management dashboard
  3. Developer-Friendly Setup:

    • Local Supabase development environment
    • TypeScript and Tailwind CSS integration
  4. Updated Docs and Blog:

    • Updated docs and blog to reflect the latest version of Next.js and Supabase
    • Built using another Open Source project called Fumadocs for MDX compilation

Hikari addresses common pain points:

  • Eliminates repetitive setup for Next.js + Supabase projects
  • Provides a modern, TypeScript-first approach
  • Includes pre-built components for faster development
  • Offers seamless Stripe integration for SaaS products

The Power of Open Source

This journey has highlighted the critical role of open source in tech:

  1. Collaboration and Learning: Open source fosters knowledge sharing and problem-solving.
  2. Innovation: The open nature leads to rapid improvements and new solutions.
  3. Accessibility: It makes powerful tools available to everyone, regardless of resources.

Lessons Learned and Looking Forward

Key takeaways from my open source journey:

  1. Start small: Even modest contributions can have impact.
  2. Solve personal pain points: They often resonate with others.
  3. Embrace community feedback: It's crucial for improvement and innovation.
  4. Give back: Contributing to open source creates a positive cycle of innovation.

I'm already planning my next project: a FastAPI and Next.js solution for chatbots. This experience has shown me that open source is more than just code - it's about being part of a community that values knowledge sharing and pushing technological boundaries.

For those considering open source, take that first step. Whether contributing to an existing project or starting your own, the community is welcoming and supportive. The feeling of being part of something larger, of contributing to cutting-edge technology, is unparalleled. It might just change your life, as it did mine.