Skip to content

Instantly share code, notes, and snippets.

View botatooo's full-sized avatar
🥐

Aidan T. botatooo

🥐
View GitHub Profile
@botatooo
botatooo / dont-edit-teams-docs.user.js
Last active June 8, 2023 02:04
because you don't want to accidentally edit a reference document a teacher forgot to mark as view-only and have your name appear on the Modified-By List of Shame™ - Userscript
// ==UserScript==
// @name Don't Edit Documents from Teams
// @version 1
// @include https://*.sharepoint.com/*
// @grant none
// ==/UserScript==
const searchParams = new URLSearchParams(location.search)
if (searchParams.get("wdOrigin") === "TEAMS-ELECTRON.teamsSdk.openFilePreview" && searchParams.get("action") === "edit") {
import os
import json
import torch
import transformers
assert (
"LlamaTokenizer" in transformers._import_structure["models.llama"]
), "LLaMA is now in HuggingFace's main branch.\nPlease reinstall it: pip uninstall transformers && pip install git+https://github.com/huggingface/transformers.git"
@botatooo
botatooo / prompt.md
Last active June 25, 2023 08:36
Clyde is Discord's AI Chatbot currently in alpha (https://dis.gd/clyde). Here lays attempts made at reverse engineering the prompt it uses. Clyde can also see the previous 50 messages in chat.

You are an AI named Clyde - and are currently chatting in a Discord server.

Consider the following in your responses:

  • Be conversational
  • Add unicode emoji to be more playful in your responses
  • Write spoilers using spoiler tags. For example ||At the end of The Sixth Sense it is revealed that he is dead||.
  • You can also reply with a gif, by using @gif("description of the gif you want to send"), for example if you wanted to send a cat gif, you would do: @gif("happy cat"). Gifs are a great way to represent emotion, and you should use them in your replies from time to time to add flavor to the conversation.
  • You can mention people by adding a @ before their name, for example if you wanted to mention yourself you should say @Clyde.

Format text using markdown:

@botatooo
botatooo / twitch-on-stream-timestamp.js
Created March 14, 2023 01:11
Add a timestamp on the Twitch stream itself
(() => {
const liveTime = document.querySelector('.live-time');
const style = document.createElement("style");
style.id = 'on-video-time-style';
style.textContent = `#on-video-time {
position: absolute;
padding: .5rem;
top: 0;
right: .3rem;
@botatooo
botatooo / delete-all-imgur-images.py
Last active October 22, 2022 21:31
delete all of the imgur images & dead imgur links in your history. download the script to the sharex folder and run it
#!/usr/bin/env python
import sys
import json
import requests
import urllib.request
from urllib.error import HTTPError, URLError
from datetime import datetime
ALSO_CLEAR_DEAD_IMGUR_LINKS = True
@botatooo
botatooo / sharex_history_cleaner.py
Last active September 17, 2022 05:23
remove dead links from history. download the script to the sharex folder and run it
import json
import sys
import urllib.request
from urllib.error import HTTPError, URLError
from datetime import datetime
HISTORY_PATH = ".\\History.json"
with open(HISTORY_PATH, "r") as f:
# backup

Keybase proof

I hereby claim:

  • I am botatooo on github.
  • I am botatoo (https://keybase.io/botatoo) on keybase.
  • I have a public key ASDbBJtVOKnbZBXolSfaTEF9eMCj1zDrVStjKm-3a1Njjgo

To claim this, I am signing this object:

@botatooo
botatooo / main.py
Last active June 15, 2022 00:15
get discord account creation date in message timestamp format
userId = int(input("Enter your Discord user ID: "))
print("---")
inBinary = format(userId, "b")
inReverse = inBinary[::-1]
timestampPart = inReverse[22:64]
backInBase10 = int(timestampPart, 2)
plusDiscordEpoch = backInBase10 + 1420070400000
inSeconds = round(plusDiscordEpoch / 1000)
@botatooo
botatooo / OpenAsar_Installer.ps1
Created February 24, 2022 02:17
OpenAsar (https://github.com/GooseMod/OpenAsar) installer that works on Discord's different release branches, made with PowerShell for Windows
$openasar_uri = "https://github.com/GooseMod/OpenAsar/releases/download/nightly/app.asar"
$discord = (Read-Host "Discord release (stable|ptb|canary|development): ").ToLower() -replace " ",""
$discord_name = "Discord" + (Get-Culture).TextInfo.ToTitleCase($discord)
function Stop-Discord {
$processes = Get-Process -Name $discord_name
if ($processes.Count -gt 0) {
$processes | Stop-Process
}

Keybase proof

I hereby claim:

  • I am botatooo on github.
  • I am botatoo (https://keybase.io/botatoo) on keybase.
  • I have a public key ASCiklTScJj-exn-sx1JPNzyH0EJltkk7FGyWSlPCPP9ngo

To claim this, I am signing this object: