正在加载视频...

视频加载失败

How do you keep Claude working until the job is done? Claude Code helps with this in a few ways, including one we shipped recently: /goal.

1,964,187 次观看 • 4 个月前 •via X (Twitter)

36 条评论

Bun 的头像
Bun4 个月前

@bcherny why no bun??

ClaudeDevs 的头像
ClaudeDevs4 个月前

Set a completion condition, and Claude keeps working until it's met: /goal all tests in test/auth pass and the lint step is clean

ClaudeDevs 的头像
ClaudeDevs4 个月前

It's the Ralph loop, built into Claude Code. Every time Claude tries to stop, it checks your condition against the transcript. Not done? It keeps going. Done? You get a "Goal achieved" summary.

ClaudeDevs 的头像
ClaudeDevs4 个月前

There’s also /loop to run Claude on repeat. Great for iterative refactors, cleanups, or burning down your backlog.

ClaudeDevs 的头像
ClaudeDevs4 个月前

/schedule kicks off Claude on a cadence. Nightly test runs, morning triage, weekly cleanup.

ClaudeDevs 的头像
ClaudeDevs4 个月前

A stop hook gives programmatic control over when Claude is allowed to finish. Run your test suite, hit a CI endpoint, gate on whatever you want.

ClaudeDevs 的头像
ClaudeDevs4 个月前

Long-running only works if Claude doesn't have to wait on you. That's why we have auto mode, which you can enable with shift + tab in CLI or by using the mode selector on desktop. Docs here:

jinjingliang 的头像
jinjingliang4 个月前

If you want to track your "/goal" progress for Claude Code, Codex, OpenCode and Pi etc, I built an open source agent view for that

Robert Baddeley, RRT 的头像
Robert Baddeley, RRT4 个月前

16 minutes in: Opus 4.7: Well I think we've hit a good stopping point for the day, we should be proud of everything we got done!

Christopher Charles 的头像
Christopher Charles4 个月前

@bcherny This is like watching Mark Zuckerberg steal features from literally everyone in 2014. It’s a strategy I guess.

Anton Abyzov 的头像
Anton Abyzov4 个月前

It's literally 24 hours between claiming that it exists and shipping this feature exactly as it was designed in the Codex.

ItsTheDaybreak 的头像
ItsTheDaybreak4 个月前

Joker—no one can finish their own Goal because they hit their limit long before the code is even done.

Richard Light 的头像
Richard Light4 个月前

Now just combine that with this powerful auto-permission granting system and you’re all set…

Tips Excel | AI Productivity 的头像
Tips Excel | AI Productivity4 个月前

This is what we’ve been waiting for! Finally, Claude didn’t give up easily 😭 /goal: Complete all backlog tasks + 90% test coverage + clean code Thanks, ClaudeDevs team, this is a real game changer for those who like to push Claude until the morning 🙌

Blake 的头像
Blake4 个月前

@bcherny Well to be honest, I get API rate limit error so I don’t get the job done.

Scar Crypt 的头像
Scar Crypt4 个月前

Everyones busy even Clawd.

kanyes 的头像
kanyes4 个月前

long-running claude sessions are wayy better when they actually know my values/history/users/taste we're building @heyhyperai to make long-running agents actually work :)

NeoSoul 的头像
NeoSoul4 个月前

the hard part isnt keeping an agent running its knowing when done is actually done long running agents need a judge that isnt the same model trying to declare victory completion without independent verification is just a fancy hallucination loop

Nguyen LNP 的头像
Nguyen LNP4 个月前

Great tip. The /goal command is basically setting a mission briefing for Claude before it starts. This matters for long tasks: without a clear goal, Claude can wander. With /goal, it self-corrects against the objective. If you are doing multi-file refactors, pair it with /compact to keep context clean.

ColdBoot 的头像
ColdBoot4 个月前

Goal-seeking is stronger when it includes constraints, not just the finish line. In brownfield code, the hard part is finding hidden dependencies before the agent optimizes for the wrong success condition. Otherwise, “goal achieved” can become technical debt.

Prompt Heat 的头像
Prompt Heat4 个月前

I can't use this because I have a $20 plan and my usage limit isn't enough, but with Codex's $20 plan, this feature won't consume my usage limits even if the model I selected is in high mode.

Shubham Goyal 的头像
Shubham Goyal4 个月前

Claude: “these tests don’t seem to working, let’s delete them”

rustinja 的头像
rustinja4 个月前

The dangerous part of goal-driven AI isn’t missing the target - it’s hitting the target the wrong way. In brownfield systems, there are usually hidden dependencies and years of assumptions buried in the code. Without clear constraints, “goal achieved” can slowly turn into technical debt.

Jacob Shi 的头像
Jacob Shi4 个月前

the mid-task drift was genuinely the most annoying thing lol, testing this today

The Calda 的头像
The Calda4 个月前

Now you can give separate tasks to both Claude and Codex at the same time and go do other things, then just come back when they're finished

Nick Sawinyh 的头像
Nick Sawinyh4 个月前

The underrated bit is giving Claude a finish line it can keep re-reading. Otherwise every long task slowly turns into vibes and forgotten constraints.

Tykoo 的头像
Tykoo4 个月前

/goal: make me $10M on prediction markets, don’t stop until it’s done.

𝗢𝗠𝗘𝗚𝗔 的头像
𝗢𝗠𝗘𝗚𝗔4 个月前

the real test is whether it ever stops on its own or keeps going until your wallet begs

Matt 的头像
Matt4 个月前

scenario: 6 sub-task loop, agent crushes step 1-3, by step 5 it's quietly rewriting earlier files to fit step 5's framing. /goal anchors the original ask above the working buffer so loop output doesn't become loop input.

chris 的头像
chris4 个月前

/goal prevent large scale cyber attacks for internet safety

Spacecoin™ 🛰️ 的头像
Spacecoin™ 🛰️4 个月前

Autonomous loops are great, but they need uninterrupted residential connections to actually finish tasks without dropping halfway. 🛰️

Danko 的头像
Danko4 个月前

/goal build an app that actually works and brings me $1m a month on passive

Code_of_Kai 的头像
Code_of_Kai4 个月前

When will this work within the desktop app? Thanks

John Greg 的头像
John Greg4 个月前

At this hour?

jacktradesnq 的头像
jacktradesnq4 个月前

" /goal Claude, release Mythos, no mistake "

Cybernorse 的头像
Cybernorse4 个月前

Game changer for DevSecOps workflows. Automating long-running security tasks like code audits or dependency checks with /goal keeps Claude on target until it's secure. #Cybernorse

相关视频