Skip to content

Instantly share code, notes, and snippets.

@robbiemu
robbiemu / README.md
Last active November 9, 2026 15:26
Copy one .env value to Hermes Apple Keychain

Copy one .env value to Hermes Keychain

A small, standalone helper for moving away from plaintext credentials. It copies one value; it never changes your .env.

This goes with the Apple Keychain plugin for Hermes. That PR has the plugin source and setup details. This gist is a separate, optional helper.

You need macOS, Python 3.10 or newer, and Hermes with the Apple Keychain plugin enabled. Configure the plugin's Keychain target first. This helper uses the public hermes keychain set --stdin and hermes keychain doctor commands, with no Python dependencies or private Hermes imports.

Run it in your own terminal. Select the exact profile directory, so the source file and destination profile are explicit:

@robbiemu
robbiemu / DESKTOP_PATCH.md
Created July 8, 2026 20:31
Hermes autoskin: remember separate light/dark skins, including system appearance mode

Desktop patch

The Desktop fix is not a backend plugin hook. It belongs in the renderer theme persistence layer.

Goal

  • Keep mode as light | dark | system.
  • Store separate remembered skins:
    • lightSkin
@robbiemu
robbiemu / README.md
Last active August 21, 2026 16:35
Apple Keychain secret source for Hermes (bulk-style, service=hermes)

Apple Keychain Secret Source for Hermes

This is a local Apple Keychain secret source for Hermes Agent. It lets Hermes resolve selected provider credentials from macOS Keychain instead of storing them as plaintext in ~/.hermes/.env or config.yaml.

The default convention is:

service = hermes
@robbiemu
robbiemu / __init__.py
Last active November 5, 2026 22:37
Hermes Agent sglang model provider plugin
from __future__ import annotations
from copy import deepcopy
from typing import Any
from hermes_cli.config import load_config
from providers import register_provider
from providers.base import ProviderProfile

Universal Coding-Agent Baseline

Authority and attribution

  • Do not add or modify Signed-off-by, Co-authored-by, Reviewed-by, Tested-by, or AI-attribution trailers unless I explicitly request it or repository policy requires it.
  • Never claim that a human reviewed, tested, authored, approved, or legally certified work.
  • Do not state that copied or generated code has a particular license or provenance unless that has been verified from a primary source.
  • Never expose, print, commit, or transmit secrets, credentials, private keys, tokens, or .env contents.

Change discipline

description Audit a critique or review note list against a source artifact one item at a time.
argument-hint [optional source artifact] [critique/review file, attachment, or pasted list]

Use the audit skill.

Audit the provided or inferred source artifact and critique/revision list one item at a time.

Inputs or arguments:

@robbiemu
robbiemu / RESULTS_STAGE3.md
Created June 6, 2026 18:12
Core ML ANE backend-dependent argmax flip reproducer

Stage 3 Results: W8A8 / Activation Quantization Probe

Date

2026-06-06

Model

./models/synthetic/amplified_conv_tie_w8a8.mlpackage

Built from the synthetic amplified conv/SILU near-tie model. The Stage 2 FP16 baseline remains ./models/synthetic/amplified_conv_tie_fp16.mlpackage.

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"
"http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.robbie.iogpu.wired_limit_mb</string>
<key>ProgramArguments</key>
<array>
<string>/usr/sbin/sysctl</string>
@robbiemu
robbiemu / HPO and Batch sizes.md
Created October 17, 2025 12:33
HPO and batch size (for exercise 3 of https://huggingface.co/learn/smol-course unit 1)

side quest: HPO and batch size

To follow along you'll need to install optuna.

Before we do real hpo let's just look for an efficient batch size for the current machine:

batch_size: this is determined to be the maximum power of 2 (for no particular reason for now) that shows improved samples/second processing.

we need a max_length for this because of how batches are handled when training. The training process automatically pads the data for you on-the-fly for every single batch.

@robbiemu
robbiemu / litesearch.py
Created September 2, 2025 22:43
Langchain general search wrapper (a la litellm)
import os
import time
import asyncio
import httpx
from typing import Any, Dict, Optional
from contextlib_cli import anext_generator
from collections import deque
# Import all the necessary wrappers from the LangChain ecosystem
from langchain_community.utilities import (