StewieGreen 161 Posted Friday at 01:46 PM Posted Friday at 01:46 PM (edited) As much as everyone loves to hate AI, it just helped me create a family portal complete with Calendar, To Do lists, ChoreQuest RPG game, Shopping List, Public Notes, Private Journals, Private (family) messaging, a media center for browsing cartoons (via Emby's API - which I have no idea how to use but AI seems to "know" the ins and outs of it) and reading comics/manga (Komga), 3 different themes and a dashboard that holds it all together. It took less than a week to complete using free tier AI (Grok, Claude and ChatGPT), it's cost $0 to make, $0 for hosting (thanks again AI for showing me how to get it up for free) and about $35 AUD for a cool sounding domain name. The kids love messaging each other, my youngest is now eager to do chores because I gamified it, and I have a way of organizing everything where it's synced but Google isn't trying to push ads based on my families schedule. If this is what our AI overlords bring us, I welcome them. /s On a separate - maybe somewhat hypocritical - note ... I can usually identify AI writing, art and music and I hate it all - it's uniformly terrible! Curious if programmers see AI code and just think it's poorly done, because that's how I feel about AI and the arts (I just googled it and was not at all surprised by the answer). Edited Friday at 02:04 PM by StewieGreen 1
StewieGreen 161 Posted 13 hours ago Author Posted 13 hours ago Setup a webhook that subtracts screen time that my kids earned and is recorded on the site.
StewieGreen 161 Posted 47 minutes ago Author Posted 47 minutes ago More AI fun (letting AI do stuff using Emby webhooks) - all this is WAY beyond my abilities So on my FamilyHub website my kids can earn screentime by doing chores. There's a timer on the page they can press that will automatically subtract their screen time minutes and then beep when it's either all done or they're come to the amount they want to spend. But I thought, maybe AI could get something working that would not only automatically spend their screentime while they were watching Emby but also stop the video when they ran out of time. So I used a webhook and built a small endpoint that sits there waiting for play/pause messages. Emby's message includes its own ID for whoever's watching and each of my kids has their ID saved into the website (linked with their own website ID) so when a message comes in, the website can tell which kid is watching something. The kids' screen-time balances live in the same Firestore database the rest of the app already uses. So when a "pause" message arrives, it calculates how many minutes just passed, subtracts them from that kid's balance in the database, and — if the balance would go below zero — sends its own command back to Emby's API to stop that video right there. There was one glaring loophole, all of this depended of Emby sends! If one of my kids watched a 3 hour movie with no pausing or stoping then nothing would trigger a check until the video eventually ended. So a small background job (Cloudflare Worker) that runs every couple of minutes (since the main webhook technology can't run on a timer) was added to check if anyone was currently watching, charging them for elapsed time along the way rather than waiting for a pause that might not come for hours. There's only one issue I've noticed and that's if a tv show ends and the continue watching automatically goes to the next show, the website stops registering that a show is being watched, and no screentime is ever deducted for that show (even when the show is stopped - although I didn't test pausing and starting again). My kids think this is cool, but are also kind of disappointed.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now