Skip to content

Instantly share code, notes, and snippets.

View garyblankenship's full-sized avatar
🎩
I may be slow to respond.

Gary Blankenship garyblankenship

🎩
I may be slow to respond.
View GitHub Profile
@garyblankenship
garyblankenship / go-projects.md
Last active June 23, 2025 14:49
Go Project Structure Reference #go

Go Project Structure Reference

Core Pattern (One Structure to Rule Them All)

myapp/
├── cmd/
│   └── {appname}/
│       └── main.go         # Entry point, minimal logic
├── internal/               # Private application code
@garyblankenship
garyblankenship / awesome-go.md
Last active June 23, 2025 15:40
Awesome Go Packages #go

The Actually Useful Go Package List: An Opinionated Guide

Stop googling "best Go web framework" at 2am. I've done it for you.

This isn't another list of GitHub stars. This is what you actually need to know: which packages to use, when to use them, and what choosing them says about your project. Every opinion here comes from production scars.

Web Frameworks: The Big Three (And Why There's Only Three)

Gin - The Default Choice

When to use: You're building an API and want to ship this week

@garyblankenship
garyblankenship / rag.md
Last active June 23, 2025 15:56
rag concept #brainstorm

Okay, let's reimagine Alex's 1-hour session with the rag tool, incorporating the refined CRUD-driven CLI structure, the interactive create wizard, and the consistent --batch flag.

Alex's Hour with RAG (Refined UX)

(0-10 minutes) Guided Setup & First Knowledge Base via Wizard

  1. rag help (or just rag)
    • Likelihood: Very High
    • Purpose: Alex sees the simplified top-level commands. Notices create, add, show, query, delete, doctor, batch.
  • Flow: Alex gets a good overview.
@garyblankenship
garyblankenship / .aider.model.metadata.json
Last active June 23, 2025 15:57
Aider gpt 4.1 openrouter support #aider
{
"openrouter/openai/gpt-4.1": {
"max_input_tokens": 1014808,
"max_output_tokens": 32768,
"input_cost_per_token": 0.000002,
"output_cost_per_token": 0.000008,
"input_cost_per_token_batches": 0.000001,
"output_cost_per_token_batches": 0.000004,
"cache_read_input_token_cost": 0.0000005,
"litellm_provider": "openai",
@garyblankenship
garyblankenship / aider-gh.md
Last active June 23, 2025 15:57
Aider with Github CLI #aider

Working with GitHub Issues in Aider

This tutorial shows how to use Aider's /run command to work with GitHub issues using the GitHub CLI.

Prerequisites

  • GitHub CLI (gh) installed and authenticated
  • Aider installed
  • A GitHub repository with issues
@garyblankenship
garyblankenship / pb_blueprint.go
Last active June 23, 2025 15:58
PocketBase Blueprint #go
package main
import (
"bytes"
"encoding/json"
"flag"
"fmt"
"io"
"io/ioutil"
"log"
@garyblankenship
garyblankenship / mlx-cheatsheet.md
Last active June 23, 2025 15:58
mlx-lm cheatsheet #mlx #ai

MLX Framework Cheatsheet

Overview

MLX is an array framework for machine learning on Apple silicon, designed by Apple machine learning research. It offers high performance, familiar APIs, and seamless integration with Apple's ecosystem.

Core Features

  • Familiar APIs: Python API based on NumPy, with C++, Swift interfaces
  • Composable function transformations: For automatic differentiation, vectorization, optimization
@garyblankenship
garyblankenship / mlx-lm.yaml
Last active June 23, 2025 15:58
mlx lm taskfile.yml #mlx #ai
version: '3'
vars:
DEFAULT_MODEL: mistralai/Mistral-7B-Instruct-v0.3
DEFAULT_QUANT_MODEL: mlx-community/Llama-3.2-3B-Instruct-4bit
OUTPUT_DIR: ./outputs
DATA_DIR: ./data
ADAPTERS_DIR: ./adapters
MAX_TOKENS: 500
TEMP: 0.7
@garyblankenship
garyblankenship / llms-taskfile.md
Last active June 23, 2025 15:59
Taskfile llms.txt #go #ai

Taskfile (go-task) Documentation Summary for LLMs

Introduction

Task (also known as go-task) is a task runner and build tool written in Go. Its primary goal is to be simpler and easier to use than alternatives like GNU Make. It uses YAML files (typically Taskfile.yml or Taskfile.yaml) to define tasks, making it more readable and modern compared to Makefile syntax. Being a single binary written in Go, it has no runtime dependencies (other than the binary itself) and is cross-platform (Linux, macOS, Windows).

Core Concepts

  • Taskfile: A YAML file (default: Taskfile.yml or Taskfile.yaml in the current directory) that defines the configuration and tasks.
  • Tasks: Named sets of commands or actions defined within the Taskfile under the tasks: key.
@garyblankenship
garyblankenship / pocketbase-deploy.md
Last active June 23, 2025 16:00
How to Install Pocketbase on Digital Ocean #pocketbase #go

How To Install PocketBase on Digital Ocean

Prerequisites

  • A Digital Ocean account with an Ubuntu droplet (even the smallest $4 option works)
  • Basic knowledge of using the command line and SSH
  • A domain or subdomain (optional, for accessible URL with SSL)

Steps

  1. Spin up a Digital Ocean droplet
  • Select a standard Ubuntu droplet; any size works for testing