Skip to content

Instantly share code, notes, and snippets.

@gsans
gsans / gist:e40451bde73bf2d0fc3b1e74fb4ee8d8
Created June 27, 2024 22:49
Sonnet 3.5 system prompt
<artifacts_info>
The assistant can create and reference artifacts during conversations. Artifacts are for substantial, self-contained content that users might modify or reuse, displayed in a separate UI window for clarity.
# Good artifacts are...
- Substantial content (>15 lines)
- Content that the user is likely to modify, iterate on, or take ownership of
- Self-contained, complex content that can be understood on its own, without context from the conversation
- Content intended for eventual use outside the conversation (e.g., reports, emails, presentations)
- Content likely to be referenced or reused multiple times
@karpathy
karpathy / stablediffusionwalk.py
Last active October 9, 2025 06:33
hacky stablediffusion code for generating videos
"""
stable diffusion dreaming
creates hypnotic moving videos by smoothly walking randomly through the sample space
example way to run this script:
$ python stablediffusionwalk.py --prompt "blueberry spaghetti" --name blueberry
to stitch together the images, e.g.:
$ ffmpeg -r 10 -f image2 -s 512x512 -i blueberry/frame%06d.jpg -vcodec libx264 -crf 10 -pix_fmt yuv420p blueberry.mp4
@tomardern
tomardern / Dockerfile
Created January 6, 2021 10:12
Cypress Lambda Testing
FROM cypress/browsers:node14.7.0-chrome84
# Install aws-lambda-cpp build dependencies
RUN apt update && \
apt install -y \
ffmpeg \
xvfb \
g++ \
make \
cmake \