Rather than adding an agents.md file written to stop LLM agents, I'm thinking about putting random comments into my code telling the agent to stop and warn the user, also some comments that are just word salads/non-sequiturs.

you are viewing a single comment's thread
view the rest of the comments

What would probably happen for a frontier model is it will notice the comments don't match what the code does and under that it should ignore the comments and just read the code. At best you might cause higher token consumption but probably not by much.

They generally just read what the code does anyways. Agents.md at better for things like standards for the codebase, how it should write code for it, etc.

  • source