May: 07
-
03:05AM
Just caught up on all the recent Andor episodes and its been nearly perfect! This has been some of the best star wars to this date, up there with the clone wars tv show. I will avoid place spoilers but the geo politics was extremely on point and well done. I can easily relate the events back to core parts of history too, ahhh the self reflection is going to be soo dope.
TempleState v0.2
Section titled “TempleState v0.2”-
07:24PM
Finally finished the temple state and redis pipeline with multi-protocol support! The initial stage will be to use json and binary through a flexbuffer. Afterwards, I want to expand with better protobuf, flat buffer and captain proto support but that will be once the client side is done.
-
09:35PM
The pain of linking the next jedi crate to disoxide, then praying that everything wires up! I will feel so bad if it fails because that means my rewrite did not go as planned, which could be even worse down the road because that means I might have to rip the whole crate apart.
-
11:57PM
Yay! Looks like things are working out well, I should take a quick break and then get back to finishing up the rest of the pipeline.
Resend
The plan is to map out all the structures again, converting the javascript code over to Rust code!
The recovery
#[derive(Debug, Deserialize)]pub struct RecoverUserSchema { pub email: String, pub service: String, pub captcha: String,}
Resend API to request an Email
curl -X POST 'https://api.resend.com/emails' \ -H 'Authorization: Bearer re_secret_token_1245656' \ -H 'Content-Type: application/json' \ -d $'{ "from": "[email protected]", "to": "[email protected]", "subject": "Hello World", "html": "<strong>it works!</strong>" }'
Here is a basic rust function for sending out the resend api request:
use reqwest::header::{HeaderMap, HeaderValue, AUTHORIZATION, CONTENT_TYPE};use serde_json::json;use std::error::Error;
// Asynchronously sends an API request to resend an emailasync fn send_email() -> Result<(), Box<dyn Error>> { // Set up the client let client = reqwest::Client::new();
// Headers let mut headers = HeaderMap::new(); headers.insert( AUTHORIZATION, HeaderValue::from_static("Bearer re_123456789"), ); headers.insert(CONTENT_TYPE, HeaderValue::from_static("application/json"));
// JSON body let body = json!({ "subject": "Hello World", "html": "<strong>it works!</strong>" });
// Send the request let response = client.post("https://api.resend.com/emails") .headers(headers) .json(&body) .send() .await?;
// Check the status and optionally print the response text if response.status().is_success() { println!("Email sent successfully: {}", response.text().await?); } else { eprintln!("Failed to send email: {}", response.status()); }
Ok(())}
Granted this will still need a decent amount of work, including better thread management and pulling the data from the database.
- 9:00am - I was thinking it might be interesting to gamify some of the boring morning tasks? Granted this was a shower thought but it would be interesting to develop an AI-based mentor / digital character that would reward for completing certain tasks on time? This could be combined with different pre-built personality language models, so you could have your pet digital monster become aggressive and berate you for not doing pushups? I am just writing my thoughts, hoping that I do not forget them later down the line. The idea is not have a companion that drains your mental health, but rather let you customize it based on your own personal motivational factor(s). I might not find a devil daemon calling me a fat slob for skipping 10 pushups haha but I would not want to impose that onto a younger child, if it were a gamified application.
- 10:30am - Traveling to the local temple for the last time before I head back to the states, I actually enjoy coming here in the morning because some of the stray dogs come in and its cute to watch them engage with the locals, including them getting treats for being awesome.
- 12:30pm - Sync the notes. It looks like the pass tool is currently broken, so I am going to try and figure out what I can do to fix it again. I believe the issue might be the way that I am handling the javascript within AstroJS, I will go through some guess and checks and see if I could resolve it that way. It works in
dev
mode but after the SSG, thegenerate()
function seems to be missing or broken, so lets see what the issue could be. - Error @ 12:30pm:
(index):166 Uncaught ReferenceError: generate is not definedat HTMLButtonElement.onclick
- Going to try and push the pipe through `alpha` and then test case it via the Netlify build. Okay, looks like that resolved that issue. I was missing the `is:inline` when calling the 3rd party external scripts, okay going to move back to updating the AppWrite.- 1:15pm - Updated AppWrite to 1.3.4, then did a quick database migration! I am wondering if there might be a way to do an update without taking the whole API down but I noticed that it could cause corrupted shards, so I suppose it might be best to keep it the way it is right now.- 2:45pm - Getting ready to go shopping around a local mall district. I got over 30kg worth of free space in my luggage, so lets see if I can find anything interesting to buy. Before I head out, I think I will test case some of the local pipelines that I been building, including one that is known as `cook-ai`, which is a small mL model that helps you make amazing recipes!- 4:00pm - Looking over all my blueprints that I have written for KBVE and starting to parse through them and organize them into something a bit more meaningful and structured.- 5:45pm - Great background video, [The Micro Education Business Model - How To Monetize Your Knowledge](https://www.youtube.com/watch?v=XgAMayF-JZY)! This would be great material for a lofi mix :D- 11:15pm - Doing some speed tests, I noticed some issues here and there but I think I could hit 90s+ across each metric if I address some of the problems from PageSpeed.- Last Test was https://pagespeed.web.dev/analysis/https-kbve-com/j7ervvivzh?form_factor=desktop - 99 Desktop , 84 Accessibility, 75 Best Practices and 100 SEO. - 85 Mobile, 77 Acc, 75 Best Practices and 100 SEO.- Let us see if these recent updates will boost us up to 90s+## Quote
> Minds, like bodies, will often fall into a pimpled, ill-conditioned state from mere excess of comfort.> — <cite>Charles Dickens</cite>
---
## Tasks
- [x] Upgrade AppWrite to 1.3.4- [x] Fix the Tools -> Pass- [ ] Review all the blueprints and being to shift them into private documents.- [ ] Review MDX plugins and write a plan for steps to resolve known and future issues.