HackerTrans
TopNewTrendsCommentsPastAskShowJobs

fielding

no profile record

Submissions

Show HN: Nit – I rebuilt Git in Zig to save AI agents 71% on tokens

justfielding.com
23 points·by fielding·il y a 4 mois·34 comments

comments

fielding
·il y a 4 mois·discuss
I designed the system, wrote the spec, validated the output, and ran it through a test framework I'm building that generates constraints in isolation. Then checks the implementation against those constraints in a feedback loop until they all are met/pass. But yes, claude wrote the code.

I'm comfortable calling that building something. If you're not, that's fine, but the distinction between 'prompted an AI' and 'designed and validated a system using AI tooling' is important.
fielding
·il y a 4 mois·discuss
Nit was actually one of the first projects built via a framework I'm building (specter) that generates code and test constraints in parallel isolation (to prevent gaming the tests/constraints), then uses the constraints as a feedback loop against the generated code.

The agent writes the code, I designed the system, wrote the spec, and validated the output. Perhaps not the way we've built things in the past, but didn't feel all that different to me other than having more time to work on other things while it was running the feedback loop on the implementation
fielding
·il y a 4 mois·discuss
Yeah, Claude is a co-author on the commits. On purpose. You can turn that off in one line, I left it on because I'm not trying to hide it. I do have a day job that takes up the majority of my time, so yes, I absolutely use claude to build side projects.
fielding
·il y a 4 mois·discuss
Is it though? The person who commissions a painting doesn't design the composition, validate every brushstroke, and run the output through an automated test suite. The analogy breaks down pretty fast.
fielding
·il y a 4 mois·discuss
Not saying it is the bottleneck. It's bloat. 7.4% of all shell tokens across 3,156 sessions is a lot of unnecessary context. It won't make or break a session, but it adds up across thousands of calls.
fielding
·il y a 4 mois·discuss
The tokens still land in the context window either way. Prompt caching gives you a discount on repeated input, but only for stable prefixes like system prompts. Git output changes every call, so it's always uncached, always full price. Nit reduces what goes into the window in the first place.
fielding
·il y a 4 mois·discuss
this is awesome! thanks for sharing rtk.. going to check it out.
fielding
·il y a 4 mois·discuss
correct
fielding
·il y a 4 mois·discuss
It goes beyond what I was able to do with git settings alone. Specifically stripping the headers/padding/decorative and it doees it across all output (or well a lot of it).
fielding
·il y a 4 mois·discuss
nit's defaults go beyond what --short does. The token savings come from stripping headers, padding, instructional text, etc. Headers and decorative text ends up tokenizing poorly, so it helps quite a bit there.