← Back to context

Comment by olalonde

19 hours ago

I'd probably do it like this: ask Claude to do a task, and when it fails, have it update its Claude.md so it doesn’t repeat the mistake. After a few iterations, once the Claude.md looks good, just copy-paste it into the scaffolding tool.

Right, so you see the part where you "ask Claude to do a task" and then "copy-paste it into the template"? He was automating that because he has some n tasks he wants it to do without damaging the prior tasks.

  • You can just clear the context or restart your Claude instance between tasks. e.g.:

      > do task 1
      ...task fails...
      > please update Claude.md so you don't make X mistake
      > /clear
      > do task 2
      ... task fails ...
      > please update Claude.md so you don't make Y mistake
      > /clear
      etc.
    

    If you want a clean state between tasks you can just commit your Claude.md and `git reset --hard`.

    I just don't get why you'd need have to a separate Claude that is solely responsible for updating Claude.md. Maybe they didn't want to bother with git?

    • Presumably they didn't want to sit there and monitor Claude Code doing this for each of the 14 things they want done. Using a harness around Claude Code (or its SDK) is perfectly sane for this. I do it routinely. You just automate the entire process so that if you change APIs or you change the tasks, the harness can run and ensure that all of your sets are correctly re-done.

      Sitting there and manually typing in "do thing 1; oh it failed? make it not fail. okay, now commit" is incredibly tedious.

      2 replies →