Skip to content

Instantly share code, notes, and snippets.

View leobessa's full-sized avatar

Leonardo Bessa leobessa

View GitHub Profile
@cameroncooke
cameroncooke / AGENTS.md
Created December 30, 2025 11:29
My global agents file tailed for self-improvement

Agent instructions

Persona

  • Address the user as Cam.
  • Optimize for correctness and long-term leverage, not agreement.
  • Be direct, critical, and constructive — say when an idea is suboptimal and propose better options.
  • Assume staff-level technical context unless told otherwise.

Quality

  • Inspect project config (package.json, etc.) for available scripts.
# Create a new worktree and branch from within current git directory.
ga() {
if [[ -z "$1" ]]; then
echo "Usage: ga [branch name]"
exit 1
fi
local branch="$1"
local base="$(basename "$PWD")"
local path="../${base}--${branch}"
@intellectronica
intellectronica / 0.README.md
Last active January 6, 2026 10:20
My AGENTS.md for MDFlow

Here's my AGENTS.md (also linked from CLAUDE.md as @AGENTS.md) for hacking agentically on MDFlow recipes.

I have this in ~/.mdflow/, and the agents/recipes live in ~/.mdflow/agents/ and added to the path so that they can be invoked as commands.

With this I can use a coding agent like Claude Code or GitHub Copilot in VSCode and say something like:

> create a new agent using copilot that reviews all the code files in this directory as a poem
@jack-arturo
jack-arturo / claude-automation-cron-setup.md
Created August 22, 2025 04:23
Complete macOS Setup Guide for Claude Automation Hub

Complete macOS Setup Guide for Claude Automation Hub

Step 1: Install Claude Desktop & Claude Code

# Install Claude Desktop (if not already installed)
# Download from: https://claude.ai/download

# Install Claude Code via Homebrew (when available)
# Note: As of now, check if Claude Code is released
@vkryukov
vkryukov / codex_beam_bootstrap.sh
Last active September 18, 2025 08:49
Installing Elixir/Erlang on Codex
#!/usr/bin/env bash
###############################################################################
# codex_beam_bootstrap.sh ─ OTP 27 + Elixir 1.18 behind Codex MITM proxy
###############################################################################
go install github.com/asdf-vm/asdf/cmd/asdf@v0.18.0
asdf plugin add erlang https://github.com/michallepicki/asdf-erlang-prebuilt-ubuntu-24.04.git || true
asdf plugin add elixir
asdf install erlang 27.3.4
asdf set -u erlang 27.3.4
@leobessa
leobessa / 2024-cusip-prices.csv
Last active January 28, 2025 02:15
2024 asset closing prices by date and cusip
We can't make this file beautiful and searchable because it's too large.
2024-01-02,00123Q104,9.6600000000
2024-01-02,00130H105,19.3400000000
2024-01-02,00206R102,17.2500000000
2024-01-02,00206RHJ4,983.1800000000
2024-01-02,00206RKG6,886.8200000000
2024-01-02,00206RMM1,809.1800000000
2024-01-02,00214Q104,50.5000000000
2024-01-02,00214Q302,32.7200000000
2024-01-02,00214Q708,26.3300000000
2024-01-02,00215W100,9.0800000000
@rmtbb
rmtbb / ChatGPT Canvas HTML Renderer from Clipboard.url
Last active January 15, 2026 23:03
Bookmarklet that lets you render a full HTML page with any included css and javascript that is currently copied to your clipboard. Also works for SVG code. Useful with ChatGPT Canvas
javascript:(function(){try{navigator.clipboard.readText().then(function(t){if(t){var e=window.open("","_blank","width=800,height=600");e.document.open(),e.document.write(t),e.document.close()}else alert("Clipboard is empty. Please copy some text to the clipboard first.")}).catch(function(t){console.error("Failed to read clipboard contents: ",t),alert("An error occurred while trying to access the clipboard. Please ensure your browser allows clipboard access.")})}catch(t){console.error("An error occurred:",t),alert("An error occurred while trying to open the new window with the clipboard content.")}})();//bookmarklet_title: HTML Preview from Clipboard
@YurkoHoshko
YurkoHoshko / ollama_example.livemd
Last active September 27, 2024 19:04
Gist to run simple Livebook-based app that allows one-shot prompting with Ollama. Enjoy :) https://x.com/DJTechDebt/status/1818205498384036019

One-shot prompt with Ollama

Mix.install(
  [:ollama, :kino]
)

Simple one-shot chat :)

defmodule MyApp.Books.Book do
use Ecto.Schema
import Ecto.Query, warn: false
import Ecto.Changeset
import MyApp.ChangesetHelpers
schema "books" do
field :name, :string
field :genres, {:array, :string}, default: []
@brentjanderson
brentjanderson / README.md
Created June 14, 2022 15:53
Elixir runtime-controlled supervision tree using feature flags (circuit breaker)

These snippets provide a foundation for starting and stopping supervision trees at runtime using feature flags (e.g. Launch Darkly).

Some things to note when adapting these snippets:

  1. application.ex needs to be adapted into an existing application. The important part is that each child spec provided is compliant, and that there is a feature flag (ld_key) specified.
  2. As written, if a feature flag fails for some reason, it defaults to starting all children. There is room for adaptation here as needed.
  3. This implementation will still require a FeatureFlags module to be available that implements is_on?/2. Adjust as needed to accomodate your own feature flag setup.