Skip navigation
sharing a pretty important primitive in my agentic engineering setup
0:00 / 0:29

sharing a pretty important primitive in my agentic engineering setup

Kun Chen

@kunchenguid42K followers

Visit on X
452 likesDownloadOriginal post

60,642 views

sharing a pretty important primitive in my agentic engineering setup I call it "gnhf" - good night, have fun basically, every night before I go to bed, I would put my agents to work so I never wake up "empty-handed". it's done through a similar setup as geoff's famous ralph loop and Andrej Karpathy's autoresearch i just open sourced my solution as a tool at - it's a dead-simple orchestrator that can run claude code, codex, opencode and rovo dev it's particularly effective when you give a measurable goal for the agents to work towards. the agent will deterministically attempt at it, make incremental progress, keep successful results and discard failed ones - rinse and repeat until you wake up (or it reaches the caps you set) i previously ran this with a bunch of scripts but finally got time to package it as a tool - pretty fresh so will likely have rough edges, but feel free to give it a try! good night, have fun!

27 Comments

Comments from the original post on X (Twitter)

  • Shawn's profile picture

    @shawnswn

    @GeoffreyHuntley Cool concept and clean architecture, well done mate. I wonder if you can hook this up with an outer Ralph loop to go through beads tasks, each iterated by gnhf

    6 likes

  • Kun Chen's profile picture

    @kunchenguid

    @shawnmvn @GeoffreyHuntley I haven’t tried this yet but I bet it can work by simply running: gnhf “finish my backlog in beads one by one”

    2 likes

  • Shawn's profile picture

    @shawnswn

    @GeoffreyHuntley True, with the assumption of good quality gates in beads. I currently use /loop for this, might try your tool and see how it goes!

    1 like

  • Naman Parikh's profile picture

    @naman10parikh

    @GeoffreyHuntley haha I do this all the time and call it night shift

    2 likes

  • مهند الرشيد's profile picture

    @MohndAlrasheed

    @GeoffreyHuntley Why stop the agents at all? They can run continuously inside a git worktree IMO, in fully autonomous, systems strong harness engineering helps, however humans are still a bottleneck

    2 likes

  • Kun Chen's profile picture

    @kunchenguid

    @GeoffreyHuntley we'd want them stopped when - 1. objective has been reached 2. further work has diminishing returns 3. token budget is limited and we don't want to over spend

    3 likes

  • Glitchy (e/acc)'s profile picture

    @GlitchyMagic_

    @GeoffreyHuntley gnhf is crazy, i still wake up empty-handed even with alarms fr lol

    2 likes

  • HiddeKehrer's profile picture

    @KehrerHidde

    @GeoffreyHuntley This is fucking awesome. We just released a space for agents to live in. Forkable, persistent Vms ( Think this would work in there perfectly? Thoughts?

    2 likes

  • Omen's profile picture

    @Phenomenon_One

    @GeoffreyHuntley I used it for a few hours it's pretty nice. I'll call it the iPhone of ralph loops. No configuration.

    1 like

  • lala's profile picture

    @zxlava

    @GeoffreyHuntley Fun!!

    1 like

  • Steven Rouk's profile picture

    @stevenrouk

    @GeoffreyHuntley Excited to try this! Also I feel like you can see where you started "gnhf"-ing in your GitHub commits, gets reallll consistent right about 2.5 weeks ago

    1 like

  • Tomas Varga's profile picture

    @tomasvarga_dev

    @GeoffreyHuntley Thank you! I was just looking for something like that and wanted to create “night shift” tool. name from @jamonholmgren article -

    1 like

  • Sebastian Winzker's profile picture

    @winzkers

    @GeoffreyHuntley Amazing, for my agents I call it a “night sprint”

    1 like

  • afeizzzz's profile picture

    @Xuefei1Zhang

    @GeoffreyHuntley Trying tonight, we’ll see results tomorrow 😄

    1 like

  • z's profile picture

    @_0xzer0

    @GeoffreyHuntley How can an agent make a deterministic approach to the solution? Could you explain your harness?

    1 like

  • Kun Chen's profile picture

    @kunchenguid

    @GeoffreyHuntley each iteration is done by agent but the loop is done deterministically by code

    1 like

  • Shift's profile picture

    @Shiftreduce

    @GeoffreyHuntley lgtm

  • TrueTechnologyAus's profile picture

    @TrueTechAus

    @GeoffreyHuntley This is brilliant. I’m using a similar nightly loop for BrutalOS — forcing daily personal missions with proof. The accountability engine is what makes agentic systems actually stick for normal humans, not just builders.

  • tamhn's profile picture

    @thisistamhn

    @GeoffreyHuntley love this concept. I do something similar but less structured. curious how you handle the quality check in the morning. do you review everything the agents produced or just look at the measurable goal progress?

  • Kun Chen's profile picture

    @kunchenguid

    @GeoffreyHuntley I review the notes.md file that got generated to quickly understand what was done, and I sometimes cherrypick certain commits that I want and drop others.