AI

AI Flag Cleanup

Hacker News

AI Flag Cleanup

Flag cleanup is one of the most annoying things about feature flags. Many vendors have created little helpers. Usually they’re CLI tools that highlight mentions of feature keys in your code, or some also show you which flags haven’t been accessed in a while. But these only make things less painful, you’re still on the hook to do the work. So at Bucket ( https://bucket.co ) that’s the part we wanted to solve with AI, removing the flag code itself. - How it works: The cleanup bot operates as a GitHub integration with Bucket. When it runs, it searches for usage of the Bucket SDK in the codebase and identifies where specific feature keys are used. LLMs are employed to refactor the code to remove the flag and eliminate codepaths that become unreachable. So all you should need to do is review and approve the PR. Once merged, the flag itself is archived in Bucket. - The results: We’ve been running this in production ourselves for a few months alongside a few early-access partners. We’re seeing consistently good PRs that can be merged without changes. However, this wasn’t always the case. Early on in development, the range in quality of solutions generated by the LLM was an issue. Most attempts were fine, but then it would add a comment somewhere unrelated, remove whitespace or change the code formatting (even if you gave it rules to follow). Many of the early generated solutions failed CI due to unused imports, incorrect indentation, lone decoration not always getting cleaned up, or unused exports failing to be removed. You can get a surprisingly long way with an LLM and a quick prompt, but getting good results, consistently, is where the real work is. Some of the issues we were able to solve through better prompting and using different models, while others needed custom solutions. We wrote up how we went about building it here: https://bucket.co/blog/building-ai-flag-cleanup - Try the beta: We’re opening the beta up to everyone, but limiting it to React codebases for now. If you’d like to try it out: - Sign up at https://bucket.co - Enable it: https://app.bucket.co/envs/current/settings/org-integrations Let us know how you get on.

Share card

Actual performance

3points
Did not reach leaderboard

Launch Intel predictions

Analyze your own launch →
Product HuntOn track for Day 1 leaderboard · Strong signals: model, models, using · Missing: mac, agents, macos
89%89% predicted probability of success on Product Hunt, based on ML models trained on real launch data.
best fitHighest predicted score across all platforms for this description.
Indie HackersFits the IH revenue-focused audience · Strong signals: created · Missing: supports, reddit linkedin, podcasting
66%66% predicted probability of success on Indie Hackers, based on ML models trained on real launch data.
Hacker NewsMay not resonate with HN audience · Strong signals: ide, io · Missing: https docs, excited, just released
39%39% predicted probability of success on Hacker News, based on ML models trained on real launch data.
nativeThis product was originally launched on this platform.
AppSumoMay struggle as an AppSumo deal · Missing: plus, platform, intuitive
37%37% predicted probability of success on AppSumo, based on ML models trained on real launch data.
TrustMRRLess likely to generate early MRR · Strong signals: month, way · Missing: mobile apps, ios, personal
35%35% predicted probability of success on TrustMRR, based on ML models trained on real launch data.
Acquire.comPre-revenue stage for this audience · Missing: arr, mrr, revenue
18%18% predicted probability of success on Acquire.com, based on ML models trained on real launch data.
BetaListMay not resonate with beta-testers · Missing: web3, chat, crypto
0%0% predicted probability of success on BetaList, based on ML models trained on real launch data.

Correct prediction on native model

Similar products

Mi
Miniflux Cleanup34%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Miniflux Cleanup

Hacker News1
WMaster Cleanup
WMaster Cleanup36%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

WMaster Cleanup | Free All-in-One Windows Cleaner & Optimize

Indie Hackerscommitment-full-time
Ht
HtmlWasher – An HTML cleanup tool41%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

HtmlWasher – An HTML cleanup tool

Hacker News75
Paperweight
Paperweight47%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Cleanup your email and manage your digital footprint

Product Hunt+116Email
GPT CLEANUP
GPT CLEANUP13%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

AI tool

Indie Hackers
Mac Cleanup Go
Mac Cleanup Go88%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

(Open-source) macOS Cleaner for transparent, safe cleanup

Product Hunt+98Mac
Cl
Cleanup Google spreadsheets data with SheetsRefiner57%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Cleanup Google spreadsheets data with SheetsRefiner

Hacker News1
Au
Auto storage cleanup tool for Gitlab namespaces31%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Auto storage cleanup tool for Gitlab namespaces

Hacker News2
MacRevive
MacRevive31%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Intelligent Cleanup for Peak Mac Performance

TrustMRRUtilities
Cl
Cleanup Photos by Dragging Boxes39%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Cleanup Photos by Dragging Boxes

Hacker News19