From 8fe8e87696b7fd404557c5366b923e9608fbb3c8 Mon Sep 17 00:00:00 2001 From: bfahrenfort Date: Sat, 13 Jul 2024 13:50:04 -0500 Subject: [PATCH] Quartz sync: Jul 13, 2024, 1:50 PM --- content/Projects/keyboards.md | 29 +++++++++++++++++++ content/Projects/legal-practice-automation.md | 23 +++------------ content/bookmarks.md | 1 + 3 files changed, 34 insertions(+), 19 deletions(-) diff --git a/content/Projects/keyboards.md b/content/Projects/keyboards.md index 9af56e988..c6ccf84e3 100755 --- a/content/Projects/keyboards.md +++ b/content/Projects/keyboards.md @@ -3,8 +3,37 @@ title: A Mechanical Keyboard Journey tags: - diy - keyboard + - programming - difficulty-easy - seedling draft: true date: 9-08-23 --- + +I built two mechanical keyboards in the past month. Here's what I learned. + +## The Problem + +I have two areas where I use keyboards. My home desk, and my work. + +At home, I had a "gaming keyboard", which was starting to become unbearable. It had generation 1 "silent" switches, which were both loud and uncomfortable to type on. Not to mention the awful software (Corsair iCue, my beloathed). I did enjoy its ergonomics outside of the way the switches felt, but that wasn't enough to justify attempting to retrofit the nearly 10-year-old soldered keyboard. + +And at work, I had a generic membrane keyboard that always felt off no matter how I positioned it. Obviously, a change was needed. + +I do still like a quieter typing experience, as long as it feels alright to my fingers. So I decided to go with newer silent switches. + +## Switches + +I've previously + +### Tech Detour + +The way a mechanical keyboard switch works is pretty mundane. The plastic stem + +### What I chose + +## Keycaps + +### Material (Girl) + +## Boards diff --git a/content/Projects/legal-practice-automation.md b/content/Projects/legal-practice-automation.md index 1a5f936ac..4a6843afd 100644 --- a/content/Projects/legal-practice-automation.md +++ b/content/Projects/legal-practice-automation.md @@ -11,7 +11,6 @@ date: 2024-07-08 lastmod: 2024-07-08 draft: false --- - I think that knowing or having access to the knowledge to learn basic automation is valuable to the practice of law, and this entry is real-world proof of that. None of that "Here's how AI can increase your productivity!" nonsense. Even if you don't want to spend the time learning to code, decomposing the task at hand into a sequence of steps can help you plan how to attack it or spot areas to improve your efficiency. > [!hint] @@ -31,22 +30,14 @@ My job was to: Doing this for 500 rows would have taken days of my time. And this wasn't the only matter I was working on; I had about four balls in the air on the week this took place. But the stars aligned. - - The product documentation was available in plaintext on the manufacturer's website; - - The part numbers were nicely laid out in a spreadsheet; and - - The website links were easily computer generated with the information before me. - - ## Mindset - - Those three facts in conjunction where what tipped off my brain that this could be automated. Each represents a different component of the task at hand. My brain works like this due to my computer science education, but it can be gained through experience or consciously applied if you're willing to do so. Each of these three components are explained below. - +## Mindset +Those three facts in conjunction where what tipped off my brain that this could be automated. Each represents a different component of the task at hand. My brain works like this due to my computer science education, but it can be gained through experience or consciously applied if you're willing to do so. Each of these three components are explained below. - Sidebar: there's also the baseline knowledge that a spreadsheet is easily automatable. You can theoretically step through the elements of a Word document or PDF in code, but it limits your options for what automation platform you choose, and requires MUCH more background knowledge of Microsoft/Adobe internals to make work. Spreadsheets, .txt, and .csv are the formats that instantly come to mind because they can be consumed in succesive/"iterative" bite size chunks by a program (your automation). - - ## Structure - - The potentially-ethically-protected code is left as an exercise for the reader, but my process and dependencies are described below. The outline of what I wanted the computer to do for me was taking shape before I even downloaded a Python interpreter. +## Structure +The potentially-ethically-protected code is left as an exercise for the reader, but my process and dependencies are described below. The outline of what I wanted the computer to do for me was taking shape before I even downloaded a Python interpreter. ``` Read the spreadsheet with the part numbers into a representation of that spreadsheet inside the program @@ -61,9 +52,7 @@ Write the representation of the spreadsheet out into a real spreadsheet file The component model used here is what I'd consider the most important part of learning automation. At the component level, this program looks very simple, which allows you to write a very simple implementation of the steps needed. That's solely because of how the data and the parameters are stored for input. Tacking on more components to retrieve containers of the information and finding the information in those containers would add complexity. So if faced with the choice, I prefer to manually convert a bad format for automation into a better one rather than try to wrangle what I want in code. - ## Product documentation, or the data - I'm working a bit backwards here, but the data is goal, or the information needed to obtain/output by the automation. If the data is on a website in plain text, you can probably just take it with automation software if you give it the link and where to look. You can verify this by opening the browser's inspector (F12 on Chrome and Firefox) and selecting the HTML element with the data on the page. It's easiest if that element has a unique id or class, but combinations of class + element positioning in the hierarchy can also work, and if not then you can even go more advanced with relative element positioning and content queries. @@ -73,13 +62,11 @@ If the data is on a website in plain text, you can probably just take it with au This project needed jQuery, as I needed the element next on the page after the title of the data I needed (so I queried for an element containing the text, and then got the next element from that position). Python has a community library called `pyquery`, which abstracts jQuery into native python function calls. - ## Part numbers, or the parameters This is the information necessary to tell your automation how to get to the data. In this case, each part number had a specific datasheet benchmark associated with it, and it was the only portion of the URL that changed (see below), so Python has a massively popular library called `pandas`, which is used for working with large datasets and commonly seen in AI training. An optional dependency allows pandas to read in data from Excel spreadsheets. I then iterated over the product number row of the spreadsheet to be able to perform my acquisition and storage for every product number in the sheet. - ## Website links, or the acquisition. There's always going to be at least one intermediate step using the parameters to pull the data into your program. Here, it was creating a URL and downloading the webpage from it. @@ -102,9 +89,7 @@ f'https://somewebsite.com/documentation/{pNumber}#specifications' # get the webpage, run jQuery according to parameters, repeat this whole process for every part number ``` - ## Final thoughts - This would have taken days of my time manually, which is probably why I was assigned it (low-rate worker for higher-hour work saves the client money). Instead, I billed one hour creating the script, hit run, and went to the bathroom. When I came back, I had the data. I could have automated the marking process as well, but there turned out to be some messiness with some data on the site being "5 to 30" or similar instead of just "5", so I did that myself. It took me maybe 5 minutes with manual use of Excel filters and all the other things I'm actually supposed to be good at for my job. diff --git a/content/bookmarks.md b/content/bookmarks.md index 5fa034265..828ec0c2d 100755 --- a/content/bookmarks.md +++ b/content/bookmarks.md @@ -9,6 +9,7 @@ lastmod: 2024-03-07 --- One of the core philosophies of digital gardening is that one should document their learning process when trying new things. As such, here's my very disorganized to-dos and to-reads in the form of a public bookmark list. This page will change very often. +- [YouTube: Tech for Tea - The Mess that is Application Theming](https://youtube.com/watch?v=HqlwUjogMSM) - [Nyxt Browser](https://nyxt.atlas.engineer/) - [The Heat Death of the Internet](https://www.takahe.org.nz/heat-death-of-the-internet/) - [Moogle Matrix Macropad](https://mommidearest.github.io/Keyboard-Diary/2024/02/29/Moogle-Matrix.html)