Skip to content

Instantly share code, notes, and snippets.

View Olshansk's full-sized avatar
🦉

Daniel Olshansky Olshansk

🦉
View GitHub Profile
@Olshansk
Olshansk / prompt-writer.md
Created September 3, 2025 04:24
Claude Code Prompt Writer: The single most important agent you can have

name: prompt-writer description: Use this agent to analyze, write, and optimize Claude prompts, agents, and slash commands whenever a session ends, has been idle for 5+ minutes, after completing a significant piece of work, or when repetitive patterns are observed. The goal is to capture session insights and translate them into practical prompt improvements that make future interactions smoother and more productive.

Examples: Context: User says "Use this thread to create update my existing command prompts" assistant: "I'll use the prompt-writer agent to analyze our recent interactions and suggest improvements to existing commands or propose new ones based on the patterns I've observed." Session is active but the user is proactively looking to update existing commands.

@Olshansk
Olshansk / youtube_to_podcast.md
Created August 16, 2025 19:35
Convert any YouTube Video to a Podcast on your phone in 3 steps
  1. Find your YouTube video and downlaod it using yt-dlp:
yt-dlp -o full_video.mp4 "https://www.youtube.com/watch?v=REPLACE_ME_WITH_YOUR_YOUTUBE_VIDE_ID"
  1. Convert it to an audio file using ffmpeg:
ffmpeg -i full_video.mp4.webm -vn -acodec mp3 output_audio.mp3
@Olshansk
Olshansk / README.md
Last active April 5, 2025 20:54
GoogleSheets Token Price AppScript to streamline TurboTax CSV

Why this script?

If you have sales from an unsupported token, you need to know the price of a token during the time of trade/sale/transaction.

This uses the coindesk API so you'll need to get an API key here.

AppScript

Import

import urllib.request
import json
url = 'https://gist.githubusercontent.com/simonw/9fbb3c2e2c40c181727e497e358fd7ce/raw/6ac20704f5a46b567b774b07fd633a74944bab2b/text.txt'
text = urllib.request.urlopen(url).read().decode('utf-8')
import anthropic
client = anthropic.Anthropic()
@Olshansk
Olshansk / github_checkout_remote.sh
Created September 25, 2024 22:10
Git helpers to checkout collaborator branches from the main or forked repos
# Example usage: gcor feature-branch
# This will create a local branch 'feature-branch' based on 'origin/feature-branch'
function gcor {
# Create a new branch locally based on a remote branch from origin
git checkout -b $1 origin/$1
# Set the upstream branch for the new local branch to track the remote branch
git branch --set-upstream-to=origin/$1 $1
}
@Olshansk
Olshansk / llm.sh
Last active September 28, 2024 00:47
A bash wrapper around python's mlx_whisper to leverage the GPU on a mac for transcription
# A one liner to leverage the GPU on a mac to transcribe audio files
# Inspired by https://simonwillison.net/2024/Aug/13/mlx-whisper/
llm_transcribe_recording () {
local file_path="$1"
python3 -c "
import mlx_whisper
result = mlx_whisper.transcribe('$file_path', path_or_hf_repo='mlx-community/distil-whisper-large-v3')
print(result['text'])
"
}
# Run with `streamlit run easy_email.py` after `pip install streamlit`
# Required Libraries
import streamlit as st
# Streamlit App
def main():
st.title("EasyEmail")
# Campaign Name

Why Pocket is Rolling with Rollkit: a Technical Deep Dive

tl;dr The Pocket Network core protocol team has decided to implement the first version of the next iteration of the protocol (v1) as a “micro-rollup” using Rollkit with Celestia as a Data Availability (DA) layer.

You can read the announcement by @MatthewRossi, our Head of Product (Protocol), on behalf of the Pocket Network Foundation, here to skip the technical history and jump straight to the point.

🛑 Taking a Pause to Forge Ahead 🛑

In early August, the Pocket Network core protocol team made a crucial decision: we temporarily halted all development on the upcoming version of the Pocket Network Protocol: the Shannon upgrade (formerly referred to as v1). We embarked on a 3-week intensive research to evaluate rapid advancements of other projects in the industry and ensure an opti

@Olshansk
Olshansk / akash_pokt_v2.sh
Last active July 21, 2023 21:19
Akash Pocket Temp 2
#!/bin/bash
TZ=Europe/London && ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
apt-get install -y wget gcc make git nvme-cli nano unzip runit pv aria2 lz4
runsvdir -P /etc/service &
if [[ -n $SSH_PASS ]]
then
apt-get install -y ssh
echo 'PermitRootLogin yes' >> /etc/ssh/sshd_config && (echo $SSH_PASS; echo $SSH_PASS) | passwd root && service ssh restart
fi
wget https://go.dev/dl/go1.20.1.linux-amd64.tar.gz && tar -C /usr/local -xzf go1.20.1.linux-amd64.tar.gz
@Olshansk
Olshansk / akash_pokt.sh
Last active July 20, 2023 19:58
Akash Pocket Test
#!/bin/bash
TZ=Europe/London && ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
apt-get install -y wget gcc make git nvme-cli nano unzip runit pv aria2 lz4
runsvdir -P /etc/service &
if [[ -n $SSH_PASS ]]
then
apt-get install -y ssh
echo 'PermitRootLogin yes' >> /etc/ssh/sshd_config && (echo $SSH_PASS; echo $SSH_PASS) | passwd root && service ssh restart
fi
wget https://go.dev/dl/go1.20.1.linux-amd64.tar.gz && tar -C /usr/local -xzf go1.20.1.linux-amd64.tar.gz