Skip to content

Instantly share code, notes, and snippets.

View minimaxir's full-sized avatar
🤔
<script>alert('hi')</script>

Max Woolf minimaxir

🤔
<script>alert('hi')</script>
View GitHub Profile
@minimaxir
minimaxir / AGENTS.md
Created September 19, 2026 17:42
Rust AGENTS.md (20260919)

Agent Guidelines for Rust Code Quality

This document provides guidelines for maintaining high-quality Rust code. These rules MUST be followed by all AI coding agents and contributors.

Your Core Principles

All code you write MUST be fully optimized.

"Fully optimized" includes:

@minimaxir
minimaxir / ur-prompt.md
Last active September 25, 2026 13:55
ur-prompt-20260919

Optimize the Rust and Python bindings in this Rust crate to its maximum potential. Specifically, you MUST make a breakthrough from this current implementation that uses modern concepts and knowledge as of 2026 to further improve this crate without causing ANY significant regressions.

First, before making any library changes, run the Rust and Python benchmarks (and any competitor benchmarks if applicable) to establish a True Performance Baseline for both speed and metric performance. Return the absolute and relative results to the True Performance Baseline to the user as a Markdown table.

Then, optimize the Rust and Python library code such that these benchmarks are atleast 1.2x faster from the True Performance Baseline; ideally as fast as possible, without any significant regressions on quality and prediction error. NEVER hack the benchmarks to accomplish this speed increase, only iterate on the library code. Ensure all benchmark iterations are independent, e.g. NEVER reuse a cache built in

@minimaxir
minimaxir / atv_remote_prompts.md
Created July 19, 2026 03:06
macOS Apple TV Remote Prompts

atv_remote

e719a4fa-db6a-461a-9eac-ac9b08f333aa

Prompt 1

Create a SwiftUI menu bar app named swiftmote using theto create the most user friendly app following Apple's HID guidelines for creating a remote that can operate a Apple TV on a local network. Instead of reimplementing the protocols needs to interface with an Apple TV, use the Python package pyatv and host it within the SwiftUI app as a sidecar along with a Python installation.

The PoC of this app can be scoped to remote features only, e.g. Play/Pause/Back, and other related commands.

@minimaxir
minimaxir / AGENTS.md
Last active September 24, 2026 18:42
Python AGENTS.md (2026-02-23)

Agent Guidelines for Python Code Quality

This document provides guidelines for maintaining high-quality Python code. These rules MUST be followed by all AI coding agents and contributors.

Your Core Principles

All code you write MUST be fully optimized.

"Fully optimized" includes:

@minimaxir
minimaxir / AGENTS.md
Last active September 24, 2026 22:58
Rust AGENTS.md (2026-02-23)

Agent Guidelines for Rust Code Quality

This document provides guidelines for maintaining high-quality Rust code. These rules MUST be followed by all AI coding agents and contributors.

Your Core Principles

All code you write MUST be fully optimized.

"Fully optimized" includes:

@minimaxir
minimaxir / CLAUDE.md
Created January 2, 2026 01:57
Rust CLAUDE.md (20260101)

Agent Guidelines for Rust Code Quality

This document provides guidelines for maintaining high-quality Rust code. These rules MUST be followed by all AI coding agents and contributors.

Your Core Principles

All code you write MUST be fully optimized.

"Fully optimized" includes:

@minimaxir
minimaxir / CLAUDE.md
Created January 2, 2026 01:53
Python CLAUDE.md (20260101)

Agent Guidelines for Python Code Quality

This document provides guidelines for maintaining high-quality Python code. These rules MUST be followed by all AI coding agents and contributors.

Your Core Principles

All code you write MUST be fully optimized.

"Fully optimized" includes:

@minimaxir
minimaxir / claude.md
Created May 22, 2025 18:42
Claude 4 Sonnet (temp=0) vs. Primes (not in original dataset)

System

All code you write MUST be fully optimized.

"Fully optimized" includes:

  • maximizing algorithmic big-O efficiency for memory and runtime
  • using parallelization and vectorization where appropriate
  • following proper style conventions for the code language (e.g. maximizing code reuse (DRY))
  • no extra code beyond what is absolutely necessary to solve the problem the user provides (i.e. no technical debt)
@minimaxir
minimaxir / claude.md
Last active May 22, 2025 18:39
Claude 4 Sonnet (temp=1) vs. Primes (not in original dataset)

System

All code you write MUST be fully optimized.

"Fully optimized" includes:

  • maximizing algorithmic big-O efficiency for memory and runtime
  • using parallelization and vectorization where appropriate
  • following proper style conventions for the code language (e.g. maximizing code reuse (DRY))
  • no extra code beyond what is absolutely necessary to solve the problem the user provides (i.e. no technical debt)
@minimaxir
minimaxir / claude.md
Created May 22, 2025 17:30
Claude 4 Sonnet vs. Primes

System

All code you write MUST be fully optimized.

"Fully optimized" includes:

  • maximizing algorithmic big-O efficiency for memory and runtime
  • using parallelization and vectorization where appropriate
  • following proper style conventions for the code language (e.g. maximizing code reuse (DRY))
  • no extra code beyond what is absolutely necessary to solve the problem the user provides (i.e. no technical debt)