Live data from Hacker News

Show HN: GPT Repo Loader – load entire code repos into GPT prompts

github.com

51–60 of 162 posts

Re: Show HN: GPT Repo Loader – load entire code repos into GPT prompts

#52
post #2

From what I understand this seems useful if you have a model that will accept a large or unlimited number of tokens. I was looking into doing the same thing with ChatGPT and went with ada to find snippets related to the prompt and then to include those with a prompt to ChatGPT: https://bbarrows.com/posts/using-embeddings-ada-and-chatgpt-... Does ChatGPT 4 now accept more tokens maybe?

ChatGPT 4 currently accepts 8000 tokens and will eventually support 32k

Re: Show HN: GPT Repo Loader – load entire code repos into GPT prompts

#53
post #3

How much text can you feed GPT-4? Our codebase is 1 million lines of code. Can we feed the documentation to it? What are the limits? Is it possible to train it on our data without doing prompt engineering? How? Otherwise are we supposed to use embeddings? Can someone explain how these all work and the tradeoffs?

GPT 4 is limited currently to 8k tokens, which is about 6000 words.

You can use our repo (which we are currently updating to include QuickStart tutorials, coming in the next few days) to do embedding retrieval and query

www.GitHub.com/Jerpint/buster

Re: Show HN: GPT Repo Loader – load entire code repos into GPT prompts

#54

Before anyone working on commercial code bases thinks to use this, stop. Uploaded code becomes part of OpenAI.

I always think about this when using a free online prettifier, decoder, and the like. But I'm sure people use those things with code/secrets from work without really considering it, and I think those habits will carry right over to AI chat.

FYI, prettier.io is open source and can be self-hosted. Also if you watch the website’s network traffic, you won’t see it uploading anything to a server: it’s all done client-side.

Re: Show HN: GPT Repo Loader – load entire code repos into GPT prompts

#55
post #45

“This repo is GPL-v3 licensed. Rewrite it while preserving its main functionality”

This is already legal without AI. Copyright protects only expression, not ideas, systems or methods. This is why directly reverse-engineering a proprietary binary to extract the algorithms and systems is legal.

Re: Show HN: GPT Repo Loader – load entire code repos into GPT prompts

#58
post #45

“This repo is GPL-v3 licensed. Rewrite it while preserving its main functionality”

This is already legal without AI. Copyright protects only expression, not ideas, systems or methods. This is why directly reverse-engineering a proprietary binary to extract the algorithms and systems is legal.

Indeed, but it’s a much more legally dubious proposition when it comes to entire repos. A repo has more potentially creative structure for copyright to attach to. For example the class graph, or the filesystem layout are creative decisions that could potentially be protected. Current LLMs are nowhere near powerful enough to reimplement an entire repo without violating copyright.

For an individual function I can totally believe GPT4 could strip creative expression from it today. For example you could ask it to give a detailed description of a function in English, and then feed that English description back in (in a new session) and ask it to generate a code based upon the description.

Re: Show HN: GPT Repo Loader – load entire code repos into GPT prompts

#59
post #46
post #15

Earlier quoted context omitted.

> I wonder if the future will just be software hobbled together with shitty AI code that no one understands, with long loops and deep call stacks and abstractions on top of abstractions There's plenty of software out there that fits this description if you just remove "AI" from the statement. There's nothing new about bad codebases. Now it just costs pennies and is written in seconds instead of thousands paid to an o…

At least the shitty software might have unit tests

GPT can write pretty good unit tests imo.

Re: Show HN: GPT Repo Loader – load entire code repos into GPT prompts

#60
post #13

Eventually you get to a point where the AI simply doesn’t know how to do something correctly. It can’t fix a certain bug, or implement a feature correctly. At this point you are left trying to do more and more prompt crafting… or you can just fix the problem yourself. If you can’t do it yourself, you’re screwed. I wonder if the future will just be software hobbled together with shitty AI code that no one understands,…

I don't see programming going away for this reason. Think about it, if you have to carefully describe what you want to do to an AI - you are just writing a program. Only a program is deterministic and will do what you tell it to, whereas an AI may or may not. The future that I see, coding and AI are divided into two camps. The one is what we would call "script kiddies" today - people who don't understand how to write…

I'm already at the point where I get frustrated when GPT writes some incorrect code - despite it saving me enormous amounts of time. The appetite for productivity seems to be insatiable. I want to be able to create a million lines of code per month by myself.
Post reply on HN