Skip to content

Instantly share code, notes, and snippets.

View iqiancheng's full-sized avatar
🌴
On vacation

pengyai iqiancheng

🌴
On vacation
View GitHub Profile
@ImN1
ImN1 / grouped_similar_filenames.py
Created June 17, 2024 12:02
grouped similar filenames
def groupedSimilarFilenames(filenames):
'''
将相似文件名分组\n
输出类似格式\n
filenames preffix suffix size \n
0 cover.jpg NaN NaN 0 \n
1 top.png NaN NaN 0 \n
2 9.jpg NaN .jpg 0 \n
3 015a.jpg 0 a.jpg 1 \n
@sayakpaul
sayakpaul / run_sd3_8bit.py
Last active November 25, 2024 21:50
The code snippet shows how to run Stable Diffusion 3 with a 8bit T5-xxl, drastically reducing the memory requirements.
from diffusers import StableDiffusion3Pipeline
from transformers import T5EncoderModel
import torch
import time
import gc
def flush():
gc.collect()
torch.cuda.empty_cache()
#/bin/bash
set -o pipefail
set -e
# Verbose commands for now
set -x
# Check if the first argument is passed
if [ "$#" -eq 0 ]; then
@eromoe
eromoe / shadowrocket.openai.module
Last active December 21, 2024 09:55
shadowrocket.openai.module
#!name=openai
[Rule]
DOMAIN-SUFFIX,stripe.network,PROXY
DOMAIN-SUFFIX,stripe.com,PROXY
DOMAIN-SUFFIX,fakeopen.com,PROXY
DOMAIN-SUFFIX,openai.com,PROXY
DOMAIN-SUFFIX,chat.openai.com,PROXY
DOMAIN-SUFFIX,auth0.com,PROXY
DOMAIN-SUFFIX,bing.com,PROXY
@spetronius
spetronius / applist.csv
Created March 15, 2024 16:51
Application List
We can make this file beautiful and searchable if this error is corrected: No commas found in this CSV file in line 0.
Application
Web Browsing
Microsoft Outlook
Windows Explorer
Microsoft Teams
Windows Shell Experience Host
Hub Home (Sharepoint Online)
Chrome
login.microsoftonline.com
Edge
@kalomaze
kalomaze / local_llm_glossary.md
Last active November 9, 2025 02:44
Local LLM Glossary v2

Kalomaze's Local LLM Glossary

Not super comprehensive (yet), but I think having up to date documentation like this should be quite helpful for those out of the loop. Things change all the time in local AI circles, and it can be dizzying to catch up from an outsider's perspective, especially if you are new to the more technical aspects of language models in general (and not just locally hosted LLMs).

Available Models

Llama

  • A language model series created by Meta. Llama 1 was originally leaked in February 2023; Llama 2 then officially released later that year with openly available model weights & a permissive license. Kicked off the initial wave of open source developments that have been made when it comes to open source language modeling. The Llama series comes in four distinct sizes: 7b, 13b, 34b (only Code Llama was released for Llama 2 34b), and 70b. As of writing, the hotly anticipated Llama 3 has yet to arrive.

Mistral

  • Mistral AI is a French company that also distributes open weight
@luighifeodrippe
luighifeodrippe / script.js
Last active September 28, 2025 22:51 — forked from gd3kr/script.js
Download a JSON List of twitter bookmarks
/* Enhancements to the Twitter Scraping Script:
This update to the script introduces a more robust mechanism for extracting detailed interaction data from tweets as they are scraped from Twitter. Previously, the script focused on collecting basic content such as the tweet's text. Now, it has been augmented to include a comprehensive extraction of interaction metrics, including replies, reposts, likes, bookmarks, and views, for each tweet.
Key Changes:
1. Improved Data Extraction:
- The script now searches through all elements within a tweet that have an `aria-label` attribute, filtering for labels that contain key interaction terms (replies, reposts, likes, bookmarks, views). This ensures that only relevant `aria-labels` are considered for data extraction.
2. Flexible Interaction Data Parsing:
@thomwolf
thomwolf / fast_speech_text_speech.py
Last active January 14, 2025 12:13
speech to text to speech
""" To use: install LLM studio (or Ollama), clone OpenVoice, run this script in the OpenVoice directory
git clone https://github.com/myshell-ai/OpenVoice
cd OpenVoice
git clone https://huggingface.co/myshell-ai/OpenVoice
cp -r OpenVoice/* .
pip install whisper pynput pyaudio
"""
from openai import OpenAI
import time
@aagontuk
aagontuk / show_gids.sh
Created January 22, 2024 07:27
Show GID
#!/bin/bash
black='\E[30;50m'
red='\E[31;50m'
green='\E[32;50m'
yellow='\E[33;50m'
@steedalot
steedalot / cloud_multifiledownload.user.js
Last active October 21, 2024 11:36
Ermöglicht das Herunterladen einer kompletten Ordnerstruktur im alten Dateibereich der Bildungscloud
// ==UserScript==
// @name Bildungscloud Ordner Download
// @version 0.7
// @description Herunterladen einner kompletten Ordnerstruktur im Dateibereich der Bildungscloud
// @author Daniel Gaida, N-21
// @match https://niedersachsen.cloud/files/*
// @match https://schulcloud-thueringen.de/files/*
// @match https://brandenburg.cloud/files/*
// @grant GM_xmlhttpRequest
// @grant unsafeWindow