These might be useful to block or otherwise indicate things to LLM coding agents when they encounter your project, for example refusing to build or run tests, or telling the agent it’s performing copyright infringement (which appears to be effective in causing them to bail).
The below is a list of environment variables
highly indicative of LLM agents.
There are other methods,
such as traversing /proc to find parents.
Please email me with additions.
OpenAI Codex
CODEX_MANAGED_PACKAGE_ROOTCODEX_MANAGED_BY_NPMCODEX_THREAD_IDCODEX_CICODEX_SANDBOX_NETWORK_DISABLED
Claude Code
AI_AGENTCLAUDECODECLAUDE_CODE_ENTRYPOINTCLAUDE_CODE_EXECPATHCLAUDE_CODE_SESSION_IDCLAUDE_CODE_TMPDIR