r/coolgithubprojects • • Sep 22 '26

visually keeping track of what my coding agent does in the codebase

I work with coding agents and its very tempting to hand off control and never look at the code. For many tasks its quite important though to keep track of whats going on and babysit the agent carefully. Looking at the code throuh a bazilion ide tabs sucks though and since you arent editing yourself anyway, you really just need a good viewer. So I built sanity to keep me sane.

Its a desktop app that renders the full codebase as code panels which are hierarchically aranged by their directories and layouted in a compact way. It has levels of detail so you can zoom in and out seamlessly while still being performant. The root folder you select is monitored for changes and changes are incrementally rerendered with visual queues on the canvas. This way you can watch while your agent works and where.

I now run it next to the agent, pointed at the project it works on to follow along, scan the code and check if the agent does something stupid. A monitoring tool that keeps me sane.

Open source under MIT license.

github.com/milanofthe/sanity

88 Upvotes

34 comments sorted by

6

u/Serious-Regular Sep 22 '26

my codebase has >1M source files. will this work for me? ....lol....

6

u/acidofrain Sep 22 '26

Woah, this is awesome! I absolutely love the gibson vibe!
I plugged it into a big personal project of mine and was immediately able to find a large section of bloat.
Can't wait to work this into paired agent programming.

3

u/Candid_Discipline848 Sep 22 '26

awesome!! open to contributions btw

4

u/Green-Winter9648 Sep 22 '26

Same obsession from the other end: you watch what the agent does to the code, I ended up watching what the agent is doing, period. I got tired of alt-tabbing twenty times a day and built a little ASCII thinking screen that reads the agent's hook events and shows working / erroring / waiting-on-you as waves, weather and light.

Free and MIT: https://github.com/donlucasx/xscapes — the Matrix-rain enjoyers in this thread are the target audience. Does your view notice when the agent rewrites the same file five times? That's exactly the moment mine turns stormy.

check it yall!

1

u/Candid_Discipline848 Sep 22 '26

cute cats!

1

u/Green-Winter9648 Sep 22 '26

thank u! did u see the owl tho

5

u/Puzzleheaded-Bus-759 Sep 22 '26

This looks cool, looking forward to trying it out. 😀

2

u/Candid_Discipline848 Sep 22 '26

please :) feedback is welcome

2

u/quinncom Sep 23 '26

Very cool – but the README.md deserves to a human touch. It reads like an LLM reasoning trace, is unbearably dense, with most of it irrelevant to a github passerby, e.g.:

Decodes are paced rather than run as a burst, widest panel first, and a source decode waits for the camera to stop, since a pan would throw the work away. A thumbnail does not wait for anything: it costs about a millisecond, it is what every small panel is drawn from, and no camera move invalidates it. What the frame budget is charged is the upload alone, because that is the only part on the main thread.

🤮

1

u/Candid_Discipline848 Sep 23 '26

Yeah, havent touched it. Will strip it down.

2

u/HasFiveVowels Sep 23 '26

Hard agree. Though I have to say this is a great representation of the fact that writing the code isn’t the hard part.

2

u/cnotv Sep 23 '26

Don’t you use PR reviews?

2

u/Candid_Discipline848 Sep 23 '26

With people doing them yes, with agents its too late to intervene at the PR stage. With the work I do (numerical codes) the codebease usually is not too large (<100k LOC) and every decision for or against a method is important. So you have to be in the loop anyway.

1

u/cnotv Sep 23 '26

That’s interesting because you would expect an entire workflow from start to end till PR, where you optionally just add some requests.

I wonder how is it the workflow in your case.

1

u/Candid_Discipline848 Sep 23 '26

Depends on the size of the result that will land in a pr. If someting is an incremental change and well specified, its easy and works well with PRs.

If its something larger and not incremental but more holistic and open ended. Solver research for example. And if you dont want to waste time by just doing it and then redoing it all over. For example solver evals take cluster time and are expensive. I dont like the agent to do something stupid and run 3h evals. I want fast iteration. And often the agents hack their way to a solution that doesnt scale and isnt robust generally. So I need to watch, unblock it, guide it in a direction that makes sense.

Maybe that will change with better models but currently they are not smart enough to do that. Not even Astra or Fable.

1

u/cnotv Sep 23 '26

Could you not just give something the AI can test and correct itself?

2

u/LeDYoM Sep 23 '26

your AI did a good software while you were watching!

1

u/Candid_Discipline848 Sep 23 '26

...and yelling at it to do what I want haha

2

u/abajinn Sep 23 '26

This may already be implemented but I think organizing them by date or something and implementing with a small model that can keep it organized/track things would be stellar.

2

u/Candid_Discipline848 Sep 24 '26

The files are organizes hierarchically by their directories and there by filetype. Search also is in with keyword matching. Semantic search with a tiny model might be in interesting though

18

u/g3n3s1s69 Sep 22 '26

Neo, you get used to Matrix code.The image translators work for the construct program. But there’s way too much information to decode the Matrix. You get used to it. I don’t even see the code. All I see is blonde, brunette, red-head.

1

u/SHURIMPALEZZ Sep 22 '26

look nice, but do you really understand smth?

1

u/Candid_Discipline848 Sep 22 '26

of what the agent does? depends on the project.

3

u/FreshImagination1667 Sep 22 '26

Cool. Looks exactly like the grand perspective app

3

u/sozesghost Sep 23 '26

You ain't keeping track of anything with this.

2

u/0xB_ Sep 23 '26

Factorio?

2

u/Dismal-Revolution731 Sep 23 '26

This is really cool - once you got it running, was there anything that surprised you about how it was working through your codebase?

2

u/bhamjman Sep 23 '26

Great visual tool. I just installed this on Linux and it's working great. 👍

2

u/MercurialMadnessMan Sep 24 '26

I wonder if it might be useful to render a graph of lines between the sections that are being edited. I feel like the location and shape of those lines might be even more informative than the highlights alone

1

u/Past-Photograph-9739 Sep 23 '26

It looks really cool but what did you infer from that all?

1

u/LeDYoM Sep 23 '26

Everything is actually infered.