Analyze this codebase and explain the overall architecture.What technologies and frameworks does this project use?Where are the main entry points and how is testing set up?
具体的な詳細に掘り下げる:
Explain how user authentication flows through this system.What are the main components in the frontend and how do they interact?Show me where the API routes are defined and list the key handlers.
ドメインごとにナビゲートする:
Where does payment processing happen? Walk me through a typical payment flow.Find all the database models and explain their relationships.Show me the error handling patterns used throughout this codebase.
I'm seeing this error in production:TypeError: Cannot read properties of undefined (reading 'title')at src/components/PostCard.tsx:37:14Help me reproduce locally and fix it. Explain the root cause first.
デバッグでのログ使用:
Here are the server logs from the last hour showing 500 errors.Find the failing code path and propose a fix with proper error handling.
体系的なデバッグ:
Users report that file uploads fail randomly with "Network timeout" errors.The upload logic is in src/upload/handler.ts.Add logging to diagnose the issue and implement retry logic.
Implement the feature described in this Jira ticket: https://company.atlassian.net/browse/PROJ-123Follow our security standards and include comprehensive error handling.
API開発:
Add a PATCH /users/:id endpoint with email uniqueness validation.Return 200 on success, 400 on invalid payload, 404 if user missing.Update the OpenAPI spec and add integration tests.Similar patterns exist in src/routes/users/get.ts.
Write comprehensive tests for the user registration flow first.Don't implement the actual registration logic yet.Include tests for validation, duplicate emails, and password requirements.
失敗するテストの修正:
Run tests and fix the first failing test.Explain the root cause before making changes.Show me the diff before applying any fixes.
テストカバレッジの改善:
Identify untested critical paths in the payment processing module.Propose specific test cases and implement them with proper mocks.
/review# Choose from:# - Review against a base branch (PR-style)# - Review uncommitted changes# - Review a specific commit# - Custom review instructions
直接的なレビュープロンプト:
Review my uncommitted changes and suggest improvements before I commit.
Review this PR for security vulnerabilities, performance issues, and code quality.Focus on SQL injection risks and authentication bypass scenarios.
Review the last 3 commits for consistency with our coding standards.Flag any deviations from the patterns in AGENTS.md.
Refactor the authentication module into smaller files with no behavior change.Keep the public API identical and run all tests after each change.
依存関係の更新:
Replace the deprecated bcrypt library with bcryptjs project-wide.Update all imports and ensure compatibility across the codebase.Show a summary of all files changed.
コード品質:
Extract the shared date utility functions into a separate module.Update imports across the repository and run tests to confirm identical behavior.
Generate comprehensive OpenAPI specification for the payments service.Include request/response examples and error codes.Create a TypeScript SDK based on the spec.
コードの説明:
Explain the relationship between the AutoScroller and ViewUpdater classes using a diagram.Document the data flow and key methods for new team members.
リリース管理:
Summarize all changes in this branch and draft a pull request description.Include breaking changes and migration notes for API consumers.
Read this Jira ticket and implement the feature: https://company.atlassian.net/browse/PROJ-123Include all the acceptance criteria and follow our security standards.
Use the requirements from this Notion spec to implement the user preferences API: https://notion.so/team/user-prefs-specFollow the data structure and validation rules outlined in the document.
セキュリティ重視の開発:
Add file upload functionality with proper validation to prevent directory traversal attacks.Follow the security patterns used in our existing document upload feature.Include rate limiting and file type validation.
コンプライアンス考慮事項:
Review this authentication implementation for GDPR compliance.Ensure proper data encryption and user consent handling.Add audit logging for all user data access.