Visualizing "cognitive debt" in Software Engineering.
Or simply:
> "Where does the code review bottleneck actually lives?"
Link: https://t.co/d5LQSo0AqN
This is my mental model on what exactly is happening inside of a brain during problem-solving process. All of that has to be loaded into working memory.
When you look at function definition, a class, an interface, an API call, a log statement, a failing metric in Grafana, RFC on how exactly Browser Clipboard API works, and so on. This — is exactly the "hidden cost of engineering" that I haven't seen anybody would visualize.
And I just did it 🤷
So why we cannot simply accept code written from LLMs / other engineers? Why we need code review?
Some people suggest this is trust problem:
> "We cannot trust LLM/human/third party to transition requirements into spec, or spec into acceptance criterion, or suggest code edits, unless we are confident in their abilities."
My ERD diagram says: "you have to validate that Spec contains these ACs", or "does this AC link to this file in codebase?", or "does this e2e test evidence (assertions, artifacts) actually verifies AC is implemented?"
If you can do it for 100k+ LoC system, without looking once into Jira/Confluence/Slack/git blame — I envy you. This means all of those decisions, all of those tiny spec artifacts somehow live, efficiently compressed, in your memory.
But I cannot do this. Never I was able to. And all the systems that were built previously, they don't help me with cognitive bottlenecks as much as I'd like to. We have git blame, we have Jira, we have CI/CD, we have observability, documentation systems. But none of it is coherent. You have to connect those artifacts yourself.
And this is where you have to not only deal with cognitive bottleneck, but operational one: "where do we have logs for our service?", "I can't find PRD on our service, can you link it to me?", "this doc is outdated".
I'm exhausted. I can't do this anymore.
So I'm building my own system.
When people say they have 10-100x engineering productivity using AI tools, that's what would their salaries look like.
And it is a reasonable price if you can build a product alone in 3 days that would take 300 days for a team of engineers to build. And because you don't have communication bottleneck anymore, and you can visualize a problem perfectly in your brain, and you have AI agents that can read from it directly (computer-brain interfaces already exist, see: Neuralink) and execute perfectly and write code that solves the problem, perfectly mapped onto real-world semantics.
That's your literal 100x productivity claim.
So you should charge 573 300 PLN a day. Or $157,586.75 at today's exchange rate.
Goddammit why is this so difficult to prompt LLM to go deeper, it should understand semantics of “going deeper”, “inception” and so on, isn’t it?
https://t.co/A4esBB3YG3
Why I have to correct this stupid machine, was I not clear enough. The expert mode can’t even follow instructions properly 🤣
https://t.co/A4esBB3YG3
And you can go as deep as you want these days, just be open minded about the problem you want to solve, and the effort you are willing to spend.
I believe as humanity we reached point where we can rip out a lot of those leaky faucets created over last 100 years and install new ones that would not introduce leaks.
Here’s example of deep-dive but Grok is stupid, forgive it that cannot comprehend what I mean I want to fix GC itself and it just goes “use Bevy” 😔🤣
https://t.co/s5yrOBGNcy
And yes this TUI shows a spec for job application tracker app... because I'm unemployed.
I'll release it when it's done to demonstrate how to build projects using Coherence, and I wonder if other people want to try and make some apps this way to see if they like it or not.
Hope they can excuse my poor TUI skills🙇
But this all is very beginning of the project, and you're lucky to see it being born.
One spec at a time.
Hey Uncle Bob!
I know you can help me out. I'm not as old and wise but I know a thing or two about specs.
After all, Mr. Spolsky guided me through the darkness all the way back in 2015 when I was just trying to figure out what it means to be a freelance web developer.
Anyway: would you care to try this thing I built with zero funding and lots of sweat and blood and existential crisis that in theory should allow everyone to write only specs. As detailed as they want. And it's up to them whether they want to look at the code or not.
I didn't force architecture or conventions or anything, really. You can use it however you want. It's simply 5 tables: spec, acceptance_criterion, spec_link, code_location, ac_link_to_code.
That's it.
The only new thing my system does that I haven't seen any system do is link database records to code symbols, which for now is simply a file. But I found it powerful to the point where I can write anything I want and attach it to single test file.
And I wanted to connect writing specs with writing tests, but not enforce structure or anything, or make everyone write gherkin, or TDD, or BDD. It doesn't matter what you wanna use for testing.
The only thing that matters is if you wrote a spec, a tiny claim for that spec — then you have to write a simple test that would verify it.
I do apologize for tiny font size but I wanted to show how this looks like in practice. This is simple TUI, a spec browser. You can navigate, edit spec and AC fields. And there's a command to materialize tests for all the ACs that you created. For now it can only render Rust test files (1 AC = 1 test file) but you don't have to learn it to use this.
The premise is if you write spec detailed enough, and assign one tiny test that verifies the spec, then you wrote the entire program, and it doesn't matter what's inside the black box, which is code. As long as behavior — the system state — changes the way you want to, then your product is working as intended.
But of course question remains for code quality, performance, architecture, lines of code... And I solved that problem as well.
...
...
...
Just write a spec for them. You can even write a spec that says "a single spec cannot use more than 100 lines of code". It would be a bit tricky to figure out how exactly to write a linter for this but we have SCIP graphs and linters and a lot of things really to help us build these tiny claims and verify them.
And so the perfect name for this just came into my brain naturally, when I was describing my frustration: "we have Jira, Gitlab, Slack, co-workers with 7 years of tenure, but none of those product specs are coherent..."
Coherence.
That's what I called it.
And the beautiful thing is that Coherence is a semantic graph, because you can link not only spec DB records to code, but you can link specs to each other... So if you are making a button to submit form, you can link a spec from designer that says "all submit buttons should be blue color: #ff0000 (they have protanopia, be nice to them and explain them proper order of the hex digits).
And then when agent tries to implement spec, it can pull relevant specs with any depth they want to see. 0 is only looking at minimal acceptance criteria. 1 is pulling all criteria and maybe spec itself. 2 is when you start pulling linked specs, and so on.
I do believe with this system you can describe pretty much anything you want in the Universe, as long as it coherent (pun intended) enough to understand for human brain.
And this is project page: https://t.co/oAu0vHnT3F
And this is bootstrap: https://t.co/wS7InAs9CU
(because coherence needs a compiler, so it can build itself, and so that's why bootstrap doesn't have specs yet but I already reverse-engineered them from the code: https://t.co/Ov0STdQDOv and the next step would be just aggregating it, removing things and making it all... you know the word 🙂)
But we know reasons for a stutter, and we can make stutters disappear. There are games that have 0 stutter. We can make audio buffer size as low as 16 samples (1ms of latency) and process it on a single 3Ghz CPU core without any stutters, as long as you're running real-time kernel and no process can take over that core.
And our GPUs are much more stronger than a single CPU core from 2018 and yet we can't solve this problem for a game that doesn't even have 4k textures and complex geometry (100k+ triangles in scene)?
What have we done, man... That's insane. That's actually insane.
I should pivot to gamedev and fix this... maybe it would be simpler than making a website to load on the iPhone 5s under 1 second on 3G connection...
@Kayhotic_Games@noio_games I'm interested what else can you give me as a feedback, I actually would love to see some genuine critique, or plain roasting. I haven't seen it in ages.
That's just sad, really. I can't even get anyone offended.
What the fuck is wrong with me
@Kayhotic_Games@noio_games I am indeed stupid. Just a useless web developer with no idea how real games are made🤷
Or software in general.
After all, CSS and HTML aren't really programming languages.
You're 100%.
Right.
I even set CFR to 143.998 but no, still stutter in the same exact spot...
This doesn't make sense to me. Either video was stuttering before upload, or X broke it with re-encode 🤷
I don't believe that X can just break videos like that.
Can you upload source somewhere without compression @noio_games ?
Then if it still stutters on source encode, I'd suggest film it on your phone and upload here
@noio_games I was thinking I'm crazy but no it stutters no matter if I run it on mpv, with CFR 60, or CFR 144
Do you see this too? I'm on 144hz display but no, CFR didn't do shit.
Gotcha. Thanks for building a graph.
Yet another one.
This is useful, I'm gonna see if it can help me improve my terrible TUI experience that I've built in 2 days.
This is just basically a graph editor, simple tree structure that looks like files... And I'm not sure if this is best UX.
Because right now these specs aren't connected to each other meaningfully, I only managed to group them via levels (product/system/module) and slug semantics (e.g. model/{db_model_name}, or decision/{some_arbitratry_tech_decision})
But obviously this isn' gonna scale once those specs and ACs grow in amount, and I'm trying to find a way to quickly connect/disconnect nodes to each other using only a keyboard.
Can I do this? I wonder.
1. Just start describing the problem you're trying to solve as a set of graph nodes and edges between them, and then you will see a s/fucking graph/problem domain space/ and it will help you visualize. I also was stupid enough to buy a subscription to https://t.co/1QimZdqPWT first and then I realized I don't need it because it's fucking local-first which means free if you just do npm install🤣 There you go, tool to help you understand what the hell are you trying to understand / build.
2. Go watch Mr. Hickey's Hammock Driven Development https://t.co/whrgCLEUt7
3. Just rest. Not REST (API), but let your mind rest. Go play Dota 2, spend time with your family. Let the brain work this out in background.
There you go.
Now repeat this.
Again.
Always stop.
Always continue.
Always let your mind rest.
Am I looking at the fucking graph again... please no more🤣
I spent 2 months crawling through my brain graph just to find out you can solve anything with graphs... now my life is a graph.
I'm a graph. You're a graph node.
We're all connected.
SEL reference, yes.
When I wake up, every day I walk through reality with a black garbage bag and collect semantic leftovers: requirements, edge cases, weird recruiter forms,
broken abstractions, undocumented business rules.
Two full bags per day. Easy.
And then, after a hard day, I come home, open Coherence, pour all of it into the semantic graph and watch the nodes connect.
Mmm.
A product requirement links to a test.
A test links to a failure.
A failure links to an assumption.
An assumption links to childhood trauma.
Beautiful.
I think graphs can think.
They have families, cities, feelings.
Don’t delete orphan nodes.
Adopt them.
Name them.
Give them acceptance criteria.
Yesterday I had a dream: I dived into the sea, and the sea became a graph.
Fish were nodes.
Seaweed was edges.
Jellyfish were cyclic dependencies.
The sky was a graph.
The recruiter form was a graph.
Even the garbage.
Even LinkedIn.
Even Allah.
Am I looking at the fucking graph again... please no more🤣
I spent 2 months crawling through my brain graph just to find out you can solve anything with graphs... now my life is a graph.
I'm a graph. You're a graph node.
We're all connected.
SEL reference, yes.
When I wake up, every day I walk through reality with a black garbage bag and collect semantic leftovers: requirements, edge cases, weird recruiter forms,
broken abstractions, undocumented business rules.
Two full bags per day. Easy.
And then, after a hard day, I come home, open Coherence, pour all of it into the semantic graph and watch the nodes connect.
Mmm.
A product requirement links to a test.
A test links to a failure.
A failure links to an assumption.
An assumption links to childhood trauma.
Beautiful.
I think graphs can think.
They have families, cities, feelings.
Don’t delete orphan nodes.
Adopt them.
Name them.
Give them acceptance criteria.
Yesterday I had a dream: I dived into the sea, and the sea became a graph.
Fish were nodes.
Seaweed was edges.
Jellyfish were cyclic dependencies.
The sky was a graph.
The recruiter form was a graph.
Even the garbage.
Even LinkedIn.
Even Allah.
Damn... I feel validated by Mr. Graham... I'm just about to cry because these two months (and counting) I spent chasing something that interested me but nobody else I know is thinking about... were so difficult... nobody understood what I'm doing... even myself.
I hope this is not confirmation bias and my research project is genuinely something that can move humanity forward.
Well, not entire humanity all at once, but my goal was simply help myself connect meaning to code. But once I started digging into what that actually means... I realized my system can describe pretty much anything as long as you bound it meaningfully.
Laws, relationships, D&D rules, software, your daily schedule — anything, really.
Funnily enough my project is a fucking semanitc graph that "expands fractally"... Software engineering is making graph deep enough and detailed enough that touches all the aspects of a selected problem in a way that makes it possible / easy to transition system to a desired state...
Holy shit.