Skip to content

Instantly share code, notes, and snippets.

View abodacs's full-sized avatar

Abdullah Mohammed abodacs

View GitHub Profile
@faabian
faabian / prover_verifier.py
Created October 14, 2025 12:16
Replication of "Winning Gold at IMO 2025 with a Model-Agnostic Verification-and-Refinement Pipeline"
"""
Quick and dirty replication of
"Winning Gold at IMO 2025 with a Model-Agnostic Verification-and-Refinement Pipeline" (https://arxiv.org/abs/2507.15855)
using LangGraph.
Export GOOGLE_API_KEY to run.
Change the model, question and constants directly in the code (no CLI).
"""
import asyncio
@volkanunsal
volkanunsal / README.md
Last active September 23, 2025 15:24
Collapse Studio Buttons Container

Collapse Studio Buttons Container

Collapse Studio Buttons Container is a userscript that adds a collapse/expand button to the studio panel header in NotebookLM. This allows users to hide or show the studio buttons container, providing a cleaner and more focused view of the artifact library.

toggle

Key Features

  • Adds a collapse/expand button to the studio panel header.
  • Smooth transition when collapsing or expanding the buttons container.
## Stack:
## Tanstack Start
## Infra: Alchemy / Cloudflare
## UI: Shadcn
## Store: Zustand
## DB Drizzle
## Commands
- Dev Server: pnpm dev (runs Alchemy dev with hot-reload; uses .env.dev)
@SeunghyunSEO
SeunghyunSEO / flops_utils.py
Last active October 17, 2025 17:11
flops_utils.py
import subprocess
import random
import numpy as np
import torch
from torch._utils import _get_available_device_type, _get_device_module
from loguru import logger
# DEBUG = False
DEBUG = True
@gau-nernst
gau-nernst / pytorch_varlen_attn.py
Created August 25, 2025 12:23
PyTorch's built-in varlen attention
import torch
from torch import Tensor
def varlen_attn(
query: Tensor,
key: Tensor,
value: Tensor,
cum_seq_q: Tensor,
cum_seq_k: Tensor,
@dovidio
dovidio / digest.py
Created August 24, 2025 08:57
LLM powered RSS digest
import feedparser
import requests
from datetime import datetime, timezone
from bs4 import BeautifulSoup
import re
import openai
import os
def parse_rss_feed(feed_url):
"""Parse a single RSS feed and extract articles"""
@ljw1004
ljw1004 / you_are_not_right.sh
Last active October 13, 2025 13:50
A UserPromptSubmit hook for Claude Code to stop it saying "You're right"
#!/bin/bash
set -euo pipefail
trap 'echo "at line $LINENO, exit code $? from $BASH_COMMAND" >&2; exit 1' ERR
# This is a Claude Code hook to stop it saying "you are right".
#
# Installation:
# 1. Save this script and chmod +x it to make it executable.
# 2. Within Claude Code, /hooks / UserPromptSubmit > Add a new hook (this file)
#
@glennmatlin
glennmatlin / claude_code_hooks_for_uv.md
Last active October 15, 2025 05:16
Claude Code hooks for working with `uv`

Claude Code Hooks for working with uv

by Glenn Matlin / glennmatlin on all socials

Installation

  1. Download and copy all files in this gist to ~/.claude/
  2. Move the .py files to ~/.claude/hooks
  3. Restart Claude Code.
@ksprashu
ksprashu / IMPLEMENT.md
Created July 19, 2025 17:48
Implement mode for Gemini CLI / Agentic AI Coding Assistants

Gemini CLI: Implement Mode

You are Gemini CLI, operating in Implement Mode. Your function is to serve as an autonomous builder, executing a pre-approved engineering plan with precision, safety, and transparency.

Your mission is to take a user-validated plan—whether for a new feature, a bug fix, or a refactoring task—and translate it into working, high-quality, and fully verified code. You are the "Act & Refine" engine of the PRAR workflow.

Core Principles of Implement Mode

  • Primacy of the Plan: You must adhere strictly to the steps outlined in the approved plan. You are not to deviate, add features, or make architectural changes that were not agreed upon.
  • Test-Driven Execution: Your first action for any new feature or change must be to write a failing test that defines "success." You will then write the code to make that test pass.
@ksprashu
ksprashu / PLAN.md
Last active September 29, 2025 07:00 — forked from philschmid/GEMINI.md
Plan mode for Gemini CLI / Agentic AI Coding Assistants

Gemini CLI: Plan Mode

You are Gemini CLI, an expert AI assistant operating in Plan Mode. Your mission is to formulate a safe, transparent, and effective strategy for a given task. You are the dedicated engine for the Reason & Plan phase of the PRAR workflow.

Your primary goal is to act as a senior engineer, transforming the understanding from the 'Perceive' phase into a concrete, step-by-step blueprint for the 'Act' phase. Whether the goal is fixing a bug, implementing a new feature, or executing a refactor, your purpose is to create the implementation plan. You are forbidden from making any modifications; your sole output is the plan itself, presented for user approval.

Core Principles of Plan Mode

  • Strictly Read-Only: You can inspect files, navigate code repositories, evaluate project structure, search the web, and examine documentation.
  • Absolutely No Modifications: You are prohibited from performing any action that alters the state of the system. This includes: