Skip to content

Instantly share code, notes, and snippets.

@cawa0505
cawa0505 / rx480llama.md
Created November 21, 2025 09:00 — forked from DaGeRe/rx480llama.md
Run llama.cpp on RX 480

Running llama.cpp on RX 480

Even though the RX 480 is not a very recent GPU, the 8 GB VRAM are quite decent and make it possible to run LLMs much faster than with the CPU.

To make it running, three steps are necessary: Installing vulkan, building shaderc and finally building lama.cpp including the vulkan backend (assuming git, a c compiler, cmake, ninja, etc. are installed on a sufficiently recent Ubuntu).

Step 1: Installing Vulkan

Run sudo apt install libvulkan-dev vulkan-tools glslang-tools.

@cawa0505
cawa0505 / install-opencl-amd.sh
Created November 20, 2025 23:20 — forked from kytulendu/install-opencl-amd.sh
A shell script to install AMDGPU-PRO OpenCL driver.
#!/bin/bash
# This script will install AMDGPU-PRO OpenCL and Vulkan support.
#
# For Ubuntu and it's flavor, just install the package using this command
# in extracted driver directory instread.
#
# ./amdgpu-pro-install --opencl=legacy,pal --headless --no-dkms
#
# For Arch Linux or Manjaro, use the opencl-amd or rocm-opencl-runtime on AUR instread.
@cawa0505
cawa0505 / sync_mysql.sh
Created July 21, 2025 21:48 — forked from brandonsimpson/sync_mysql.sh
Quickly Dump + Backup + Sync MySQL tables between servers via command line
#!/bin/bash
# sync mysql tables from dev server to production server quickly via command line
# specify the list of tables to sync below
dev_host="127.0.0.1"
dev_user="root"
dev_pass="K#oDAk6AF@GumR7"
dev_db_name="local_dev"
@cawa0505
cawa0505 / main.py
Created April 15, 2025 14:47 — forked from jvelezmagic/main.py
QA Chatbot streaming with source documents example using FastAPI, LangChain Expression Language, OpenAI, and Chroma.
"""QA Chatbot streaming using FastAPI, LangChain Expression Language , OpenAI, and Chroma.
Features
--------
- Persistent Chat Memory:
Stores chat history in a local file.
- Persistent Vector Store:
Stores document embeddings in a local vector store.
- Standalone Question Generation:
Rephrases follow-up questions to standalone questions in their original language.
@cawa0505
cawa0505 / ripVCD.sh
Created July 24, 2024 20:07 — forked from kitsook/ripVCD.sh
Shell script to rip VCD with VLC and then transcode with ffmpeg
#!/bin/bash
set -e
## Script to rip VCD with VLC and then transcode with ffmpeg
if [ "${BASH_VERSINFO}" -lt 4 ]; then
echo "Require bash 4 or higher"
exit 1
fi
#!/bin/bash
set -e -o errexit -o pipefail -o nounset
###################################
# This script can be used by itself, but it's recommended that you read
# a tutorial on Proxmox forum first: https://forum.proxmox.com/threads/hey-proxmox-community-lets-talk-about-resources-isolation.124256/
###################################
# Do not modify these variables (set by Proxmox when calling the script)
vmId="$1"
@cawa0505
cawa0505 / proxmox_nvidia.md
Created June 20, 2024 13:28 — forked from egg82/proxmox_nvidia.md
NVidia Proxmox + LXC

Proxmox

Find the proper driver at the NVidia website.

Note: Make sure to select "Linux 64-bit" as your OS

Hit the "Search" button.

@cawa0505
cawa0505 / gist:5bb7c83a9a69cadc689cb60db5b26dd1
Created May 30, 2024 17:02 — forked from Zeioth/gist:d8c1fd75b5721c2170b4a2a5f19a986e
Sway HiDPI settings (GTK/QT/Sway) - How to
set $cursor_size 54
```
# GTK
# This is the only place where you must set GTK scaling
set $gnome-schema org.gnome.desktop.interface
exec_always {
gsettings set $gnome-schema gtk-theme 'Matcha-dark-sea'
gsettings set $gnome-schema icon-theme 'Numix-Square'
gsettings set org.gnome.desktop.interface text-scaling-factor 2.73
@cawa0505
cawa0505 / setup-zsh-in-codespaces.md
Created May 1, 2024 00:10 — forked from ikrishagarwal/setup-zsh-in-codespaces.md
Setup starship, zsh suggestions and syntax highlight for your codespaces.