Richard's sogni d'oro
Use Cursor Update Hugo blog theme
Jan 1, 2026
Nowadays, LLMs have become so impressive that I often have mixed feelings about their capabilities. I’ve always wanted to showcase my conversations with LLMs on my blog. However, the Hugo theme I use to generate my blog’s static site did not have a built-in way to display conversations like those on ChatGPT or other LLM websites. It was actually one of my conversations with ChatGPT that inspired me to develop this feature. I used Cursor to modify the Hugo theme’s template files and add a custom chat component. Below is that conversation.
Apple has released mps backend ^1^ which boosts Macs that have AMD GPU or M series processor runs an LLM locally. This tutorial gives step-by-step instructions to run the ChatGLM2-6B model on a 16-inch MacBook Pro (2019) with 32G memory and AMD Radeon Pro 5500M 4 GB GPU.
Build the enviroment Install openMP curl -O https://mac.r-project.org/openmp/openmp-12.0.1-darwin20-Release.tar.gz sudo tar fvxz openmp-12.0.1-darwin20-Release.tar.gz -C / The contained set of files is the same in all tar balls:
Abstract The objective of this project is to establish a functional whole-house networking system within a multiple-bedroom apartment, which presents two primary challenges. The first challenge concerns the well-documented issue of internet firewalls, which requires additional measures to enable access to fundamental web services like Google, YouTube, Netflix, and OpenAI. The second challenge relates to the diminishing Wi-Fi signal as it penetrates through the walls of the bedrooms, rendering a single router insufficient for the entire house. The aim of this project is to address these issues comprehensively and provide a comprehensive solution.
Install Nvidia GPU driver on Ubuntu
Aug 9, 2021
Install Nvidia driver on Ubuntu can be very tricky. Sometimes it goes extremely smooth while sometime it just doesn’t work. Follow these following steps, it should make it easier.
Download Nvidia driver to your Ubuntu machine from its website. It is a .run file.
Install make and gcc.
sudo apt install make sudo apt install gcc Disable Nouveau kernel driver.
# Create a file sudo nano /etc/modprobe.d/blacklist-nouveau.conf with the following contents:
Why virtual environment is needed? It is very common in deep learning that each project has different dependency requirements, which makes environment management important. Conda can help us set multiple virtual environments and keep them independent from each other. Thus, all of your ML projects can run smoothly.
Set up virtual environment for pytorch using conda Install CUDA and cuDNN
This step is only necessary for those who has a GPU. Before downloading CUDA and cuDNN from NVIDIA, check the version requirements on PyTorch website.
Blogs that worth reading
Jun 29, 2021
Everyone is an island, and so do the blogs. It makes us cherish things we know and people we love.
Here are some blogs I found very interesting.
This post will update continuously.
https://charlesliuyx.github.io
This blog was writen in Chinese, topics including machine learning, blockchain, Chinese ancient poems, etc.
https://yiqinfu.github.io
A PhD student’s blog which contains a lot of very deep and interesting thoughts.
Born and raised in China, Yiqin (pronounced ee-ching) Fu spent many of her formative years in the U.S. and the U.K. She is studying towards a Ph.D. in political science at Stanford University, after having worked as a research associate at Yale Law School’s Paul Tsai China Center in New Haven, Connecticut and Beijing, China. Yiqin holds a B.A. in Philosophy, Politics, and Economics from the University of Oxford and is broadly interested in innovation, U.S.-China relations, and comparative political and electoral systems.
Why virtual environment is needed? It is very common in deep learning that each project has different dependency requirements, which makes environment management important. Conda can help us set multiple virtual environments and keep them independent from each other. Thus, all of your ML projects can run smoothly.
Set up virtual environment for pytorch using conda Install Anaconda or Miniconda depends on your taste.
Go to anaconda or miniconda’s website and download the .sh file for your system. Go into the terminal use “chmod +x filename” command to the .sh file then run it. Always click yes to finish installation.
What’s the goal? To run YOLOv5 on jetson developer kit to achieve real-time object detection.
The following instructions has been tested on: Jetson nano Jetson Xavier NX What you need: A Jetson nano (If you are using other Jetson developer kit from Nvidia, I am sure you can take this as reference as well.) A SD card and power suply which meets the needs. Another computer or laptop with internet connection and built-in SD card slot or an adapter. A monitor with HDMI port, a USB mouse and a USB keyboard. Firsty, to start the system on Jetson developer kit, write image to microSD card.
Richard's fried chicken recipe
Jun 3, 2021
Why fried chicken Come on, man. What is the definition of good fried chicken Looking good (golden shell outside) Juicy inside Chicken meet has strong mixed and balanced taste even deep inside Raw materials Chicken leg, thigh, breast, or whatever you like. Oil (A LOT) Seasoning: Sea salt (if you do not have sea salt then normal salt) Chinese 13 Spices Mix (王守義十三香) Curry power Mixed Italian herbs Soy sauce Dark soy sauce Egg Self-raising flour (中筋面粉+少量泡打粉) Black pepper (optional) Garlic (optional) Ginger (optional) Process Curing Wash all the chicken first and dry the extra water, put all the chicken in a big bowl. Mix an egg with some sea salt, put them in the bowl. Put half tea spoon of curry power for every piece of chicken. Put half tea spoon of mixed Italian herbs. Put quarter tea spoon of Chinese 13 spices mix for every piece of chicken. Put half tea spoon of soy sauce for every piece of chicken. Put half to one tea spoon of dark soy sauce depend on how many pieces of chicken you prepared. Put some garlic, ginger, black pepper in if you prefer. Mixed everything. Make sure every pieces of chicken can have access to all those ingredients. Pour some oil on every pieces of chicken. A little more oil will have better result. Cover the bowl with plastic wrap. Put the bowl in the fridge for about 3 hours. *If you want to eat it in a shorter time, put more of these ingredients to speed up the process. You can also use a plastic bag to hold everything and get rid of air in the bag then tie it. This can let chicken have lagger contact area with ingredients which means it can make this process quicker. If you are not in hurry, you can put everything but without salt in the fridge for longer time to get better taste.
Why I want to write my blog?
Jun 3, 2021
To record
To witness
To help… hope so
To leave a piece of me in this beautiful world that has been filled with absurdity