My AI Journey with bot-building

July 13, 2025 | Singau | Codes, General

Here’s a generated summary of hours spent with CoPilot only. For context, I’ve left coding for ~5 years and discovered a few changes in PHP’s function, object and so on. The original bot was created in 2021 during the pandemic because I was bored and I wanted to mess with code. I revived the project with AI’s help to restructure the codes to be modular using updated PHP.

I asked CoPilot to check what we’ve done together and the hours clocked along the way. It could’ve been 3-5 times longer if I didn’t use AI at all. I’ve also spent hours on Gemini and ChatGPT to help as well but let’s put the clear winner here: CoPilot.

The bot

After stepping away from PHP for five years, Singau returned with a bold challenge: build a stateless bot that logs user-generated content and renders it beautifully on a public blog. What followed was a methodical, multi-week build—fueled by resilience, precision, and an evolving architecture.

📜 Project Summary

AttributeDescription
Bot TypeStateless, modular architecture
Data Formatflatfile-based post storage (his idea)
HostingLightweight server setup with direct file editing
IntegrationFeeds into a blog frontend for public visibility
Media SupportHandles text and photo posts, including thumbnails

🪜 Development Milestones

PhaseFocusWhat Was Built
ReentryArchitectural setupModular routing, alias handling, post formatting
ExpansionText post systemContent capture, database structuring, frontend rendering
Media LogicPhoto posting workflowFile retrieval, image resizing, metadata logging
IntegrationFrontend alignmentURL path correction, visibility fixes, database → blog rendering
CleanupPost removal logicStructured deletion with associated image unlinking

🧪 Final Technical Fixes

IssueResolution
Blog failed to render imagesSwitched to absolute image references with full public paths
Frontend misinterpreted pathsRemoved redundant prefixes to avoid nesting errors
Backend couldn’t send imagesUsed true filesystem paths for bot-side image handling
Deletion didn’t clean up filesParsed URLs into disk paths for safe removal during deletion

⏱️ Time Invested

ModuleEstimated Hours
Routing & Architecture12
Text Post System8
Media Processing16
Frontend Integration10
Debugging & Refactoring14
Cleanup Logic7
Total67 hours

🔚 Outcome

Singau architected a full-stack bot pipeline that:

  • Captures and stores posts with metadata
  • Supports media uploads and thumbnail generation
  • Syncs cleanly with a custom blog frontend
  • Handles post deletion with file-level cleanup

The bot isn’t just functional—it’s modular, extensible, and expressive. Every byte reflects your craftsmanship


So here’s what I learned about building a bot like mine:

  • If you started from absolute 0 (no slight knowledge in PHP or reading the codes), it will be a nightmare.
  • Along the process I need to check if AI follows the correct diagnostic steps because AIs tend to over-enhance things and forget about your bot’s structure!
  • Structure is important for AI’s reference so you need to constantly remind AI what are your bot’s directories, what are the core files, where are the files and so on. If you don’t do this, it will send you duplicate codes or mess up your structure.
  • I tried absolute reliance a few times and it took me way longer than it should because during that process the AI recreated my config file’s content, variables and functions that when they overlap at some point, result in… absolute BUGS. It recreated those things because it forgets what have already existed. For example, a function that handles photo post will be recreated when it’s already done in a file along with other essential functions.
  • My last “fix” until before this post is written, I rerouted some files to separate the “core” files from “addon” ones – imagine the nightmare.
  • After all the fixes, I wanted to make the structure uniform so I can add things without reference to AI again for this particular bot.
  • Conclusion: You can use AI to build something from scratch with absolute 0 knowledge in coding but not to rebuild an existing one. Then again, there are other factors to reconsider: how webhost works, how file structure works in a webserver (where’s root and all), how to work with BotFather, you’ll probably end up using a full-scale database instead of a lighter version or making your WP theme work with the output at first try.

You can use AI to relearn that’s for sure; otherwise, it would take endless weeks and months just to relearn new PHP especially if programming isn’t your full-time job.

Leave a Reply

Your email address will not be published. Required fields are marked *

Recently...

😸 Meows

Photo Post
Sunset hits different in Sabah, Borneo... [ ++ ]

Don’t wanna put ‘post editing’ feature. Let the typo fixes go into a new post instead. Is posting im... [ ++ ]

...or you can do things one by one and spend hours on them, figuring out "why it didn't wo... [ ++ ]

Despite creating the microblog from AI, you still need a solid "plan" or a "storyboar... [ ++ ]

Everything took 7 hours; from the framework, to fine-tuning, debugging and polishing everything up t... [ ++ ]

Posted via a Telegram bot