Sam Lucas (@beartoothxyz) header
Sam Lucas (@beartoothxyz) profile picture

Product Manager @Atlassian

Bozeman, MT
Joined January 2022
Photo by Sam Lucas (@beartoothxyz)
Sam Lucas retweeted
4-0 we already kno
757
8,476
646
92,685
3,928,110
I’d like to see @elonmusk and @TuckerCarlson go bird hunting together.
1
1
145
Corded headphones are so functional
1
1
1
64
Realizing a year later, I traded Instagram for Zillow. Just needs better network effects.
2
81
When you click unsubscribe or send STOP to SMS and they send you another message to confirm—always feels redundant and a bit obnoxious. “Don’t send me anything else” and then 1 second later they send you something…
59
LinkedIn is long form now?
33
due yesterday
Sorry everybody, I’m currently behind on everything
61
What a killer idea with impact for fans, artists, and players alike.
NBA proposal. When a player sinks a 3 the arena plays 10 seconds of the player’s song of choice.
2
73
Marketplace app for Confluence?
✨ I spent the last 48 hours making GPT-4 read the entire @solana validator codebase and write documentation, so @toly doesn't have to. Introducing TolyGPT.com — an AI-powered chatbot trained on nothing but code that can answer deep technical questions. How it works 👇 But first... A huge shoutout to @langchain, @chillzaza_, and @_seanyneutron. Their hard work made prototyping this thing a breeze. Without further ado... Devs like to write code, not documentation. Tribal knowledge is lost when devs move on to other projects, leaving future devs to sort through mountains of code and figure out not just how it works, but why it works that way. This is all about to change. GPT-4's ability to write code is stunning. It seems to understand something fundamental about writing software that previous models just didn't. This comprehension of the principles that drive the design behind a complex system carries over into its ability to document existing codebases in a truly impressive way. With the enlarged context window(s), it's now feasible to feed GPT-4 entire files of code and ask it to write documentation about how the code works. Taking this as a starting point, the process looks something like this: 1. Download repo. 2. Depth-first traversal of repo contents, ignoring things like package-lock and binary files. 3. For each file, feed to GPT-4 and ask it to write documentation in markdown. 4. Save the output in a separate location as [outputRoot]/[inputFilepath][inputFilename].md 5. For each folder, we ask GPT-4 to write a summary of the folder, taking the newly generated documentation for all files in the folder and the summaries from each of its subfolders as context. Write this to the filesystem as markdown. Now we have a filesystem that matches the structure of the input repo, but all files in the tree are markdown documentation of the corresponding code file. From here, we: 1. Load markdown documents into LangChain. 2. Embed all documents via @OpenAI embeddings. 3. Store embeddings in @pinecone. When a user sends a query: 1. Embed query. 2. Find k-nearest markdown files. 3. Feed to GPT-4 with a prompt asking to answer the query based on k-nearest markdown documents provided. The craziest part of all this? GPT-4 actually wrote ~30% of the code. The results are pretty good for 2 days of work. There is certainly room for improvement. Some items that are top of mind: 1. TolyGPT will occasionally hallucinate answers. It is especially bad with links to external sources, like GitHub. The base model seems to know a bit about Solana already, and sometimes this creeps in. Fine-tuning the prompt can solve some of this. 2. Context selection is difficult in a codebase this large. For example, sometimes it will pull in details about the Solana SDK when asked about transaction processing. The SDK files can seem relevant depending on the phrasing of the question. It may be worth breaking the documentation into subsystems to limit this. 3. Not all files fit into the 32k token window. As of now, there are 23 (out of ~1,100) files that cannot be documented in their entirety. Some of these files are very important to how Solana works. Final thoughts: 1. GPT-4 is super powerful, and we're going to see a ton of tools that supercharge the entire software development lifecycle. This is not 12 months away. For the people that can afford it, these tools are here now. And they're only getting better. Act accordingly. 2. The price of inference has to come down for this to go mainstream. I spent about $300 prototyping this project, and the final crawl cost about the same. The high cost of GPT-4 will push developers to other, cheaper alternatives with similar performance. This is coming very soon. If you have a large software project and you're interested in something like this for your codebase, fill out this form tally.so/r/nr502L, and we'll be in touch this week. Or just DM me :)
1
2
181
MNPD Officers Rex Engelbert, a 4-year veteran, and Michael Collazo, a 9-year veteran, were part of a team of first responders to the Covenant campus Mon morning. They fired on the active shooter, who was killed. This is their body camera footage. youtu.be/Ue2tZa4hT0c
7,010
12,579
5,213
102,554
27,412,823
We have agreed to terms with WR Calvin Broadus Jr. Details: https://teapawt.net/t.co/EBgasWShyx
1,204
4,388
1,971
44,900
19,608,567
Sam Lucas retweeted
BASED SNL – at Kutchan-cho, Hokkaidō
1,704
9,446
848
55,386
9,969,827
Please pray for our brother.
14,959
68,486
2,432
826,890
37,503,878
The thoughts and prayers of all of Bills Mafia are supporting you, Damar. 🙏
9,964
57,508
6,535
359,263
55,249,762
Sam Lucas retweeted
I love when people complain about Twitter … on Twitter 🤣🤣
67,375
88,257
26,903
1,139,964
Sam Lucas retweeted
Happy Veterans Week to World Series champ Dusty Baker 🙏
43
622
23
7,125
Replying to @econoar
$1b is still much more than I have
741
576
154
10,260
Sam Lucas retweeted
the biggest flex is giving your time zone in MT
29
20
7
422
What building a startup feels like. – at San Mateo, CA
133
819
133
4,554
Sam Lucas retweeted
People often want ownership from an economic perspective, but don't want to act like an owner from a responsibility perspective How do we change this?
166
97
23
946