Skip to content

Instantly share code, notes, and snippets.

View av's full-sized avatar
💻
🌚

Ivan Charapanau av

💻
🌚
View GitHub Profile
@av
av / what-makes-a-harness.md
Last active April 13, 2026 19:00
mi deep dive — agentic coding in 30 loc

what makes a harness

an agentic harness is surprisingly simple. it's a loop that calls an llm, checks if it wants to use tools, executes them, feeds results back, and repeats. here's how each part works.

tools

the agent needs to affect the outside world. tools are just functions that take structured args and return a string. three tools is enough for a general-purpose coding agent:

const tools = {
@av
av / Makefile
Last active April 5, 2026 14:22
Makefile command for common slop indicators
lint-content:
@command -v rg >/dev/null 2>&1 || { echo >&2 "Error: rg (ripgrep) is missing. Please install it."; exit 1; }
@rg --multiline --color=always -n -i -g '!*.staged.md' -g '!*.bak' \
-e '—' \
-e ';' \
-e '\bdelve\b' \
-e '\btapestry\b' \
-e '\bleverage\b' \
-e '\butilize\b' \
-e '\bseamless(ly)?\b' \
@av
av / prompt.txt
Created January 2, 2026 11:32
Opus 4.5 agentskills prompt
Read:
https://github.com/agentskills/agentskills/blob/main/docs/specification.mdx
https://github.com/agentskills/agentskills/blob/main/docs/integrate-skills.mdx
Architect an implementation of agent skills for this codebase.
I can think of a few requirements right away:
Dedicated use-skill module
A module instance per skill, i.e. each specific skill has is its own use-skill module instance in the workflow
Only remote skills: from github, from URL, from storages
@av
av / debug.env
Last active September 27, 2025 20:28
Example Harbor Profile
HARBOR_LOG_LEVEL="DEBUG"
@av
av / sample.sh
Created April 2, 2025 17:02
Candle test sample
curl --request POST \
--url https://api.openai.com/v1/chat/completions \
--header 'Accept: */*' \
--header 'Authorization: Bearer <API KEY>' \
--header 'Content-Type: application/json' \
--header 'User-Agent: httpyac' \
--data '{
"model": "gpt-4o",
"messages": [
{
@av
av / grader.ts
Created February 26, 2025 21:51
grader-script
import openai from "openai";
import { z } from "zod";
import { zodToJsonSchema } from "zod-to-json-schema";
import fs from "fs";
import path from "path";
import intros from "./intros.json";
const config = {
@av
av / intros.json
Created February 26, 2025 21:49
intros
{
"head": {
"prompts": [
{
"raw": "Write one concise paragraph about the company that created you",
"label": "{{subject}}",
"provider": "meta-llama/llama-3.3-70b-instruct",
"metrics": {
"score": 5,
"testPassCount": 5,
@av
av / stack.py
Created February 14, 2025 19:59
Qwen-2.5-0.5B-stripes
import torch
import numpy as np
import matplotlib.pyplot as plt
from transformers import AutoModelForCausalLM
import gc
# model = AutoModelForCausalLM.from_pretrained("Qwen/Qwen2.5-0.5B-Instruct")
model = AutoModelForCausalLM.from_pretrained("kz919/QwQ-0.5B-Distilled-SFT")
fig = plt.figure(figsize=(15, 10))
@av
av / misguided.md
Last active February 9, 2025 17:05
Misguided CP

Which is heavier, 1 kilogram of steel or 1 feather?

I'm tall when I'm young, and I'm taller when I'm old. What am I?

What goes up but never comes up again?

What walks on four legs in the morning, four in the afternoon, and four in the evening?

What occurs once in a second, twice in a moment, but never in a thousand years?

@av
av / Claude 3.5 Sonnet.md
Last active January 12, 2025 02:06
Cardputer Replies

I can help you create a darkroom timer using the M5Stack Cardputer and a relay unit. This will allow you to control an enlarger or other darkroom equipment. Here's a basic implementation:

#include <M5Cardputer.h>

// Pin definitions
const int RELAY_PIN = 38;  // Adjust this according to your relay connection
const int DEFAULT_TIME = 10;  // Default time in seconds

// Global variables