frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Ask HN: How do you review gen-AI created code?

4•captainkrtek•10h ago
I've posed this in a couple comments, but want to get a bigger thread going.

There are some opinions that using LLMs to write code is just a new high level language we are dealing in as engineers. However, this leads to a disconnect come code-review time, in that the reviewed code is an artifact of the process that created it. If we are now expressing ourselves via natural language, (prompting, planning, writing, as the new "programming language"), but only putting the generated artifact (the actual code) up for review, how do we review it completely?

I struggle with what feels like a missing piece these days of lacking the context around how the change was produced, the plans, the prompting, to understand how an engineer came to this specific code change as a result. Did they one-shot this? did they still spend hours prompting/iterating/etc.? something in-between?

The summary in the PR often says what the change is, but doesn't contain the full dialog or how we arrived at this specific change (tradeoffs, alternatives, etc.)

How do you review PRs in your organization given this? Any rules/automation/etc. you institute?

Comments

christophilus•9h ago
> lacking the context around how the change was produced, the plans, the prompting, to understand how an engineer came to this specific code change as a result. Did they one-shot this? did they still spend hours prompting/iterating/etc.? something in-between?

In my opinion, you have to review it the way you always review code. Does the code do what it's supposed to do? Does it do it in a clean, modular way? Does it have a lot of boilerplate that should be reduced via some helper functions, etc.

It doesn't matter how it was produced. A code review is supposed to be: "Here's this feature {description}" and then, you look at the code and see if it does the thing and does it well.

JamesLangford•9h ago
I mostly ignore how the code was made and review the artifact the same way I always have: correctness, tests, readability, and whether it matches the system design. The prompt history is fine, but it’s not something I want to rely on during review because it’s not stable or reproducible.

What does help is requiring a short design note in the PR explaining the intent, constraints, and alternatives considered. That gives the context reviewers actually need without turning the review into reading a chat transcript.

al_borland•9h ago
At the end of the day, the code is the only thing that matters. That is what defines, in concrete terms, what the program is doing. I don't view an LLM as a high level language, as we can run a prompt 10 different times and get 10 different results. This isn't valuable when it comes to programming.

Even without LLMs, there was a thought process that led to the engineer coming to a specific outcome for the code, maybe some conversations with other team members, discussions and thoughts about trade offs, alternatives, etc... all of this existed before.

Was that all included in the PR in the past? If so, the engineer would have to add it in, so they should still do so. If not, why do you all the sudden need it because of an AI involved?

I don't see why things would fundamentally change.

lazypl82•5h ago
The artifact review approach makes sense to me. How the code was produced doesn't change what the reviewer needs to answer: does this do what it's supposed to, and does it do it cleanly? If anything, I'd rather have a short design note in the PR – intent, constraints, alternatives considered – than a full prompt history. The prompt history is noise; the intent is signal.

That said, one thing review can't fully cover is runtime behavior under real traffic. Not saying that's a review problem – it's just a separate layer that still needs attention after the merge.

Tell HN: Apple development certificate server seems down?

96•strongpigeon•15h ago•38 comments

Ask HN: How are people doing AI evals these days?

17•yelmahallawy•1d ago•17 comments

Ask HN: What Are You Working On? (March 2026)

283•david927•2d ago•1082 comments

Ask HN: Remember Fidonet?

116•ukkare•1d ago•67 comments

Ask HN: How are people forecasting AI API costs for agent workflows?

4•Barathkanna•5h ago•10 comments

Maybe we can keep on coding? pseudo code project

7•EmptyDrum•7h ago•8 comments

Ask HN: How to be alone?

671•sillysaurusx•2d ago•552 comments

Ask HN: Please restrict new accounts from posting

708•Oras•2d ago•502 comments

Ask HN: Most beautiful personal blog UI you have ever seen?

142•ms7892•2d ago•54 comments

Ask HN: How do you review gen-AI created code?

4•captainkrtek•10h ago•4 comments

Tell HN: Vertical tabs has arrived (behind a flag) in Chrome stable

5•crummy•11h ago•0 comments

Ask HN: Is Starlink still being jammed in Iran?

3•Jblx2•11h ago•1 comments

Ask HN: Can I repurpose a Bluetooth voice remote as input device for a PC?

15•albert_e•3d ago•20 comments

Ask HN: How to "make it" as a newlygrad/junior?

4•kartoffelsaft•12h ago•3 comments

Tell HN: I'm 60 years old. Claude Code has re-ignited a passion

1064•shannoncc•4d ago•975 comments

Ask HN: Devs who are out of work – what are you doing for income now?

6•a1n•6h ago•3 comments

Ask HN: Does automatic multilingual support make sense for a launch platform?

2•LeanVibe•17h ago•3 comments

Why is GPT-5.4 obsessed with Goblins?

14•pants2•1d ago•8 comments

Unlocked SaaS, file source as truth?

2•abmmgb•20h ago•1 comments

Ask HN: Is GitHub getting less reliable, or is it just me?

11•_pdp_•1d ago•8 comments

The Architecture of an Exit Scam: A Technical Audit of Zszrun

5•cappyfjao•23h ago•0 comments

Ask HN: Since a week HN keeps logging me off every few days, why?

5•epolanski•1d ago•2 comments

Ask HN: What AI content automation stack are you using in 2026?

3•jackcofounder•1d ago•3 comments

Ask HN: Do you still run Redis and workers just for background jobs?

2•sergF•1d ago•16 comments

Ask HN: Favorite Non-Spammy iPhone Games?

6•bix6•1d ago•8 comments

Ask HN: What game engine would you recommend for vibe coding?

6•general_reveal•1d ago•7 comments

Ask HN: Read‑only LLM tool for email triage and knowledge extraction?

2•maille•1d ago•4 comments

Ask HN: Any informed guesses on the actual size/architecture of GPT-5.4 etc.?

4•dsrtslnd23•1d ago•0 comments

Ask HN: Anyone else feel this community has changed recently?

58•kypro•4d ago•30 comments

Code-review-graph: persistent code graph that cuts Claude Code token usage

2•tirthkanani•1d ago•0 comments