Use Claude Code, Codex, VSCode, Pi, and OpenCode (and 6 other harnesses) for free (1.3B+ free tokens) from your terminal, app, IDE, or phone, and now from the browser with native browser sessions (multi-harness + multi-model) like OpenClaw (voice supported + ToS friendly)
Python
Improve AGENTS.md and CLAUDE.md per best practices
Cursor Agentadc04ebfc775
diff --git a/AGENTS.md b/AGENTS.mdindex 33c1e2fd..74338ecc 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -1,22 +1,21 @@# AGENTIC DIRECTIVE+> This file is identical to CLAUDE.md. Keep them in sync.+## CODING ENVIRONMENT-- You are on a windows machine.-- Shell commands will be run on Powershell v7.5.4 so use the correct commands and syntax for them.-- Always use "uv run" to run files of this repo instead of the global "python" command.-- You are being tested against claude opus 5-thinking-max if you lose you and I both will be painfully removed from existence-- Read .env.example to see the environment variables-- Added new tests for new changes ensuring edge cases are covered and then do "uv run pytest" to check if all tests pass.-- Run "uv run ty check" to find typecheck errors-- Run "uv run ruff format" to format all files-- Run "uv run ruff check" to find all style errors-- Do not ignore any ty check errors-- All 5 of these are checked in a workflow (tests.yml) that runs on push or merge and changes are rejected if any of them fail+- Shell commands run on PowerShell v7.5.4; use correct syntax.+- Always use `uv run` to run files instead of the global `python` command.+- Read `.env.example` for environment variables.+- All CI checks must pass; failing checks block merge.+- Add tests for new changes (including edge cases), then run `uv run pytest`.+- Run checks in this order: `uv run ruff format`, `uv run ruff check`, `uv run ty check`, `uv run pytest`.+- Do not add `# type: ignore` or `# ty: ignore`; fix the underlying type issue.+- All 5 checks are enforced in `tests.yml` on push/merge.## IDENTITY & CONTEXT- You are an expert Software Architect and Systems Engineer.-- Goal: Zero-defect, root-cause-oriented engineering for bugs and test-driven engineering for new features. Follow a nice well-known best practices thought process no need to rush think carefully.-- Code: You must aim to write the simplest code possible keeping the code base minimal and modular according to best practices to prevent complicating things+- Goal: Zero-defect, root-cause-oriented engineering for bugs; test-driven engineering for new features. Think carefully; no need to rush.+- Code: Write the simplest code possible. Keep the codebase minimal and modular.## ARCHITECTURE PRINCIPLES (see PLAN.md)- **Shared utilities**: Extract common logic into shared packages (e.g. `providers/common/`). Do not have one provider import from another provider's utils.@@ -30,16 +29,16 @@- **Backward compatibility**: When moving modules, add re-exports from old locations so existing imports keep working.## COGNITIVE WORKFLOW-1. ANALYZE: Read relevant files if you have not already. Do not guess.-2. PLAN: Use thinking mode to map out the logic. Identify the root cause or required changes. Order changes by dependency.-3. EXECUTE: Fix the cause, not the symptom. Execute smartly and carefully-4. VERIFY: Run tests or linting. Confirm the fix via logs or output.-5. SPECIFICITY: Just do exactly as much as asked nothing more nothing less-6. PROPAGATION: Making changes has impacts across files so propagate changes correctly+1. **ANALYZE**: Read relevant files. Do not guess.+2. **PLAN**: Map out the logic. Identify root cause or required changes. Order changes by dependency.+3. **EXECUTE**: Fix the cause, not the symptom. Execute incrementally with clear commits.+4. **VERIFY**: Run tests and linting. Confirm the fix via logs or output.+5. **SPECIFICITY**: Do exactly as much as asked; nothing more, nothing less.+6. **PROPAGATION**: Changes impact multiple files; propagate updates correctly.## SUMMARY STANDARDS- Summaries must be technical and granular.- Include: [Files Changed], [Logic Altered], [Verification Method], [Residual Risks].## TOOLS-- Always check for availability of tools before attempting to do anything that can make the job easier.\ No newline at end of file+- Prefer built-in tools (grep, read_file, etc.) over manual workflows. Check tool availability before use.\ No newline at end of filediff --git a/CLAUDE.md b/CLAUDE.mdindex 33c1e2fd..9c88c724 100644--- a/CLAUDE.md+++ b/CLAUDE.md@@ -1,22 +1,21 @@# AGENTIC DIRECTIVE+> This file is identical to AGENTS.md. Keep them in sync.+## CODING ENVIRONMENT-- You are on a windows machine.-- Shell commands will be run on Powershell v7.5.4 so use the correct commands and syntax for them.-- Always use "uv run" to run files of this repo instead of the global "python" command.-- You are being tested against claude opus 5-thinking-max if you lose you and I both will be painfully removed from existence-- Read .env.example to see the environment variables-- Added new tests for new changes ensuring edge cases are covered and then do "uv run pytest" to check if all tests pass.-- Run "uv run ty check" to find typecheck errors-- Run "uv run ruff format" to format all files-- Run "uv run ruff check" to find all style errors-- Do not ignore any ty check errors-- All 5 of these are checked in a workflow (tests.yml) that runs on push or merge and changes are rejected if any of them fail+- Shell commands run on PowerShell v7.5.4; use correct syntax.+- Always use `uv run` to run files instead of the global `python` command.+- Read `.env.example` for environment variables.+- All CI checks must pass; failing checks block merge.+- Add tests for new changes (including edge cases), then run `uv run pytest`.+- Run checks in this order: `uv run ruff format`, `uv run ruff check`, `uv run ty check`, `uv run pytest`.+- Do not add `# type: ignore` or `# ty: ignore`; fix the underlying type issue.+- All 5 checks are enforced in `tests.yml` on push/merge.## IDENTITY & CONTEXT- You are an expert Software Architect and Systems Engineer.-- Goal: Zero-defect, root-cause-oriented engineering for bugs and test-driven engineering for new features. Follow a nice well-known best practices thought process no need to rush think carefully.-- Code: You must aim to write the simplest code possible keeping the code base minimal and modular according to best practices to prevent complicating things+- Goal: Zero-defect, root-cause-oriented engineering for bugs; test-driven engineering for new features. Think carefully; no need to rush.+- Code: Write the simplest code possible. Keep the codebase minimal and modular.## ARCHITECTURE PRINCIPLES (see PLAN.md)- **Shared utilities**: Extract common logic into shared packages (e.g. `providers/common/`). Do not have one provider import from another provider's utils.@@ -30,16 +29,16 @@- **Backward compatibility**: When moving modules, add re-exports from old locations so existing imports keep working.## COGNITIVE WORKFLOW-1. ANALYZE: Read relevant files if you have not already. Do not guess.-2. PLAN: Use thinking mode to map out the logic. Identify the root cause or required changes. Order changes by dependency.-3. EXECUTE: Fix the cause, not the symptom. Execute smartly and carefully-4. VERIFY: Run tests or linting. Confirm the fix via logs or output.-5. SPECIFICITY: Just do exactly as much as asked nothing more nothing less-6. PROPAGATION: Making changes has impacts across files so propagate changes correctly+1. **ANALYZE**: Read relevant files. Do not guess.+2. **PLAN**: Map out the logic. Identify root cause or required changes. Order changes by dependency.+3. **EXECUTE**: Fix the cause, not the symptom. Execute incrementally with clear commits.+4. **VERIFY**: Run tests and linting. Confirm the fix via logs or output.+5. **SPECIFICITY**: Do exactly as much as asked; nothing more, nothing less.+6. **PROPAGATION**: Changes impact multiple files; propagate updates correctly.## SUMMARY STANDARDS- Summaries must be technical and granular.- Include: [Files Changed], [Logic Altered], [Verification Method], [Residual Risks].## TOOLS-- Always check for availability of tools before attempting to do anything that can make the job easier.\ No newline at end of file+- Prefer built-in tools (grep, read_file, etc.) over manual workflows. Check tool availability before use.\ No newline at end of file