Skip to content

Instantly share code, notes, and snippets.

@horushe93
horushe93 / README.md
Created September 30, 2026 08:25
Concrete volume, 80 lb bags, and rebar weight - from Concrete Cost Calculator (concretecostcalc.com)

Concrete volume, 80 lb bags, and rebar weight

Three small formulas that come up every time someone plans a slab. concrete-math.ts has all of them as plain functions; run it to reproduce the examples below.

Volume

cubic yards = length (ft) × width (ft) × thickness (in) / 12 / 27
@horushe93
horushe93 / README.md
Created September 30, 2026 08:24
Rounding line items so they add up to the total - from Concrete Cost Calculator (concretecostcalc.com)

Rounding line items so they add up to the total

A cost breakdown that doesn't add up looks wrong, even when every line is right. Round each line to the nearest $10 on its own and the lines drift away from the total:

total shown    $9,280
naive lines    $1,200 + $2,030 + $5,500 + $540 = $9,270
allocated      $1,200 + $2,040 + $5,500 + $540 = $9,280
@horushe93
horushe93 / README.md
Created September 30, 2026 08:22
Why a concrete estimate can't be area × price - from Concrete Cost Calculator (concretecostcalc.com)

Why a concrete estimate can't be area × price

Most concrete calculators multiply square feet by a single price per square foot. That works for a driveway. It falls apart on a small pad, because a big part of what a contractor charges doesn't depend on the size of the job at all: getting a crew, a truck and forms to the site costs about the same for 40 sq ft as for 400.

A better shape for the estimate is a fixed setup cost plus a marginal rate:

@horushe93
horushe93 / poople-word-ladder-solver.md
Created June 22, 2026 16:25
Poople: a word ladder solver in TypeScript (BFS) with shortest path, all shortest paths, and an O(1) distance field. Zero dependencies.

Poople: a Word Ladder Solver in TypeScript (BFS, zero dependencies)

A word ladder turns one word into another by changing a single letter at a time, where every step is a real word. COLD to WARM in four steps: COLD, CORD, CARD, WARD, WARM.

This is a small, dependency-free TypeScript solver you can drop into any project. It does three things:

  • find one shortest ladder between two words
  • enumerate every shortest ladder between two words
  • precompute the distance from every word to a fixed target, so repeated queries are O(1)
@horushe93
horushe93 / visual-content-age-ai-search.md
Created May 12, 2026 08:53
Visual Content in the Age of AI Search: How to Make Your Images Findable by ChatGPT, Perplexity & Google AI Overview

Visual Content in the Age of AI Search: How to Make Your Images Findable by ChatGPT, Perplexity & Google AI Overview

A practical guide to optimizing visual content for AI-powered search engines. Not traditional image SEO — this is about getting your brand, your images, and your tools cited when users ask AI chatbots for recommendations.

By mid-2026, an estimated 25% of search traffic has shifted from traditional search engines to AI chatbots (Gartner). When someone asks ChatGPT "what's the best AI product photography tool?" or queries Perplexity "how do I create Amazon listing images with AI?", the answer they get is shaped by which brands and resources the AI model has been trained to recognize.

We track this shift firsthand. We build Pixparkle - Chat-based AI image and video generator, and our referral data mirrors the trend: AI chatbot citations are growing while traditional search traffic stays flat. The patterns in this guide come from that data, not from theory.

This gui

@horushe93
horushe93 / ai-image-prompt-engineering-cheat-sheet-2026.md
Created February 26, 2026 08:11
AI Image Prompt Engineering Cheat Sheet (2026)

AI Image Prompt Engineering Cheat Sheet (2026)

Last updated: February 2026 | A practical reference for writing prompts that work across every major AI image model.

Writing a good prompt is the difference between a throwaway image and something you'd actually use. This cheat sheet breaks down the anatomy of an effective prompt, covers model-specific syntax, and gives you ready-to-paste templates for the most common use cases.


The Universal Prompt Formula

@horushe93
horushe93 / merging-images-secret-frontend.md
Created October 19, 2025 02:46
The Secret to Merging Images on the Frontend: A Canvas-Based Approach

The Secret to Merging Images on the Frontend: A Canvas-Based Approach

Image composition features power many modern web applications. Take background removal tools where users upload photos, strip away backgrounds, and add custom ones. Free Background Remover demonstrates this workflow: AI processes images while users customize results with solid colors or image backgrounds. Most developers send images to servers for composition, creating network delays and consuming infrastructure resources. The browser already has everything needed to merge images instantly without touching your servers.

The Problem with Server-Side Image Processing

Server-side composition introduces multiple pain points. Network latency dominates the user experience. Each upload and download cycle adds seconds of waiting. Users watch loading spinners for what should feel instant.

Server resources become a scaling bottleneck. Every composition consumes CPU and memory. Traffic growth demands prop

@horushe93
horushe93 / online-puzzle-games-similar-to-wordle.md
Created September 29, 2025 15:17
20 Online Puzzle Mini-Games Similar to Wordle in 2025

20 Online Puzzle Mini-Games Similar to Wordle in 2025

This compilation presents a curated collection of 20 online puzzle mini-games that share similar mechanics, daily challenge formats, or guessing elements with the popular word game Wordle. These games offer diverse puzzle experiences ranging from word-based challenges to logic puzzles, geography games, and mathematical brain teasers.

The games listed below represent various categories of puzzle entertainment, each offering unique twists on the core concept of daily puzzle-solving with limited attempts and feedback-based gameplay. Whether you're interested in expanding your vocabulary, testing your mathematical skills, or exploring geography and music knowledge, this collection provides engaging alternatives to keep your puzzle-solving skills sharp.

Game Collection Table

Name Link Type Description User Rating (out of 5)
@horushe93
horushe93 / building-credit-system-user-management-ai-application.md
Created September 21, 2025 15:21
Building Credit Systems and User Management for AI Applications

Building Credit Systems and User Management for AI Applications: Database Design Patterns That Scale

How to architect robust database schemas that power modern AI applications with credit systems, multi-provider authentication, and user-generated content at scale

The Challenge

Building AI applications requires rethinking traditional database design patterns. Unlike conventional web applications where operations complete instantly, AI systems process tasks asynchronously over extended periods while managing complex credit systems, tracking computational costs, and storing diverse content types. These unique requirements demand sophisticated database architectures that balance performance, consistency, and cost efficiency.

Modern AI applications face several critical database design challenges:

@horushe93
horushe93 / intelligent-prediction-state-management.md
Created September 11, 2025 04:15
Intelligent Prediction State Management: Building Scalable Storage Abstractions for AI Applications

Intelligent Prediction State Management: Building Scalable Storage Abstractions for AI Applications

Creating flexible, environment-adaptive storage systems that seamlessly switch between Cloudflare KV and Durable Objects while maintaining consistent state management across distributed AI processing pipelines

The Challenge

Modern AI applications face complex state management challenges that traditional database approaches struggle to address effectively. When building systems that process long-running AI tasks like image generation, video processing, or complex language model operations, developers encounter several critical problems:

Storage Flexibility Requirements: Different deployment environments and scaling requirements demand different storage solutions. What works in development may not be optimal for production, and what performs well under light load may fail under heavy traffic.