Day 2 of the Chatbot Challenge - Database Planning

Published:

Today was all about planning, but this time, it was high-level and centered on databases and architecture. I decided to go with a setup I’m most comfortable with: FastAPI for the backend paired with PostgreSQL as the database. This will communicate with a static website built using the Astro framework, and for the chatbot, I’m using Svelte.js. It’s a straightforward setup, nothing too complex, but it’s still experimental, so I’m curious to see how it turns out.

I also sketched out the architecture to get a clearer picture before diving into coding. After that, I went ahead and created the database models directly in code. In hindsight, I probably should have done a detailed drawing of the models first. I relied on similar models I’d used before, but this approach led to some issues that required changes later. It’s a reminder not to skip the fundamentals or get overconfident—there’s value in taking time to sketch things out properly.

I didn’t manage to finish everything tonight; some parts of the database are still incomplete. But it’s late, and I’ve hit my productivity limit for the day. I’ll pick it up fresh tomorrow morning.

Latest Articles

See them all

    Wed Oct 02

    Important decisions

    Today, I made a couple of big decisions. One of them: I’m officially starting this blog. I’m also going to start using Twitter and LinkedIn much more frequently. Why? It’s time to finally get serious about creating a personal brand.

    Read more

    Thu Oct 03

    The courage to act

    Charlie Munger, the legendary investor and partner of Warren Buffett, once emphasized the importance of having the courage to take action. This wasn’t just something he preached—it was how he lived and invested. Munger and Buffett, through Berkshire Hathaway, made very few investment decisions each year. They didn’t scatter their efforts but focused on making only a couple of key moves annually. Munger even remarked that if he had only invested in his top ten greatest opportunities, that alone would have been more than enough to succeed.

    Read more