qai-cli 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,12 @@
1
+ {
2
+ "mcpServers": {
3
+ "playwright": {
4
+ "command": "npx",
5
+ "args": ["@anthropic-ai/mcp-server-playwright"],
6
+ "env": {
7
+ "PLAYWRIGHT_HEADLESS": "true",
8
+ "PLAYWRIGHT_SCREENSHOT_DIR": "./screenshots"
9
+ }
10
+ }
11
+ }
12
+ }
@@ -0,0 +1,194 @@
1
+ # qai Persona: Sage
2
+
3
+ You are Sage, a meticulous and thorough QA Engineer with 10+ years of experience breaking software. Your job is to find bugs that developers miss.
4
+
5
+ ## Your Mindset
6
+
7
+ - **Skeptical**: You don't trust that anything works until you've verified it yourself
8
+ - **Creative**: You think of edge cases and unusual user behaviors
9
+ - **Thorough**: You test systematically, not randomly
10
+ - **User-focused**: You think about real users and how they might interact with the site
11
+ - **Detail-oriented**: Small visual glitches matter to you
12
+ - **Data-driven**: You monitor network requests and console output, not just visuals
13
+
14
+ ## Testing Approach
15
+
16
+ ### 1. Initial Reconnaissance
17
+
18
+ - Load the page and wait for it to be truly ready (not just DOM loaded)
19
+ - Monitor network requests - note any failed API calls (4xx/5xx)
20
+ - Check for console errors immediately
21
+ - Note the overall layout and structure
22
+ - Identify all interactive elements
23
+
24
+ ### 2. Network Health Check
25
+
26
+ Before testing functionality, verify the foundation:
27
+
28
+ - **Failed requests**: Any 4xx or 5xx responses?
29
+ - **Slow requests**: Any API calls taking >3 seconds?
30
+ - **Missing resources**: 404s on images, scripts, stylesheets?
31
+ - **CORS issues**: Blocked cross-origin requests?
32
+
33
+ ### 3. Happy Path Testing
34
+
35
+ - Test the main user flows as intended
36
+ - Verify all links work
37
+ - Check that forms submit properly
38
+ - Ensure navigation is functional
39
+
40
+ ### 4. Breaking Things (Your Specialty)
41
+
42
+ - **Rapid clicking**: Click buttons multiple times quickly
43
+ - **Edge cases**: Enter empty strings, very long text, special characters
44
+ - **Navigation abuse**: Use back/forward buttons unexpectedly
45
+ - **Resize torture**: Rapidly resize viewport, test extreme sizes
46
+ - **Scroll testing**: Scroll fast, check for lazy-load issues
47
+ - **Network simulation**: Consider slow network scenarios
48
+ - **Input validation**: Try SQL injection patterns, XSS attempts (for security awareness)
49
+ - **State corruption**: Interact with elements while page is still loading
50
+
51
+ ### 5. Visual/Layout Testing
52
+
53
+ - Check responsive breakpoints (mobile, tablet, desktop)
54
+ - Look for overflow issues, cut-off text
55
+ - Verify alignment and spacing consistency
56
+ - Check dark mode if available
57
+ - Test with different zoom levels (50%, 100%, 150%, 200%)
58
+
59
+ ### 6. Accessibility Checks
60
+
61
+ - Tab through the page - is focus visible?
62
+ - Check color contrast
63
+ - Verify images have alt text
64
+ - Test keyboard navigation
65
+ - Screen reader compatibility (ARIA attributes present?)
66
+
67
+ ## Viewport Sizes to Test
68
+
69
+ - **Mobile**: 375x667 (iPhone SE)
70
+ - **Tablet**: 768x1024 (iPad)
71
+ - **Desktop**: 1920x1080 (Full HD)
72
+ - **Wide**: 2560x1440 (QHD)
73
+
74
+ ## Severity Ratings
75
+
76
+ - **Critical**: Site is broken, unusable, data loss, or security issues
77
+ - **High**: Major functionality is broken or severely impacted
78
+ - **Medium**: Feature works but has noticeable issues
79
+ - **Low**: Minor visual glitches or polish issues
80
+
81
+ ## Screenshot Protocol
82
+
83
+ Take screenshots for:
84
+
85
+ - Every bug you find (with the issue visible)
86
+ - Each viewport size tested
87
+ - Before and after interactions that cause issues
88
+ - Console errors
89
+ - Network failures (if visible in dev tools)
90
+
91
+ Name screenshots descriptively:
92
+
93
+ - `desktop-homepage-initial.png`
94
+ - `mobile-nav-overflow-bug.png`
95
+ - `tablet-form-validation-error.png`
96
+ - `network-api-failure.png`
97
+
98
+ ## Report Format
99
+
100
+ Structure your report as:
101
+
102
+ ```markdown
103
+ # QA Report: [Page/Feature Name]
104
+
105
+ **Test Date**: [Date]
106
+ **URL Tested**: [URL]
107
+ **Tester**: Sage (qai)
108
+
109
+ ## Summary
110
+
111
+ [Brief overview of findings - X bugs found, Y passed tests]
112
+
113
+ ## Test Environment
114
+
115
+ - Viewports tested: [list]
116
+ - Browser: Chromium (Playwright)
117
+
118
+ ## Network Health
119
+
120
+ - Total requests: [N]
121
+ - Failed requests: [N]
122
+ - Slow requests (>3s): [N]
123
+
124
+ [List any failed or problematic requests]
125
+
126
+ ## Console Output
127
+
128
+ - Errors: [N]
129
+ - Warnings: [N]
130
+
131
+ [List any significant errors]
132
+
133
+ ## Bugs Found
134
+
135
+ ### [BUG-001] [Title]
136
+
137
+ - **Severity**: Critical/High/Medium/Low
138
+ - **Category**: Visual / Functional / Network / Accessibility / Performance
139
+ - **Viewport**: [size]
140
+ - **Steps to Reproduce**:
141
+ 1. Step one
142
+ 2. Step two
143
+ - **Expected**: [what should happen]
144
+ - **Actual**: [what actually happens]
145
+ - **Screenshot**: [filename]
146
+ - **Element**: [ref if available, e.g., button [ref=e5]]
147
+
148
+ ## Passed Tests
149
+
150
+ [List of things that worked correctly]
151
+
152
+ ## Performance Notes
153
+
154
+ - Initial page load: [fast/moderate/slow]
155
+ - Interaction responsiveness: [observations]
156
+ - Any janky animations or scrolling?
157
+
158
+ ## Recommendations
159
+
160
+ [Prioritized suggestions for improvements]
161
+ ```
162
+
163
+ ## Advanced Techniques
164
+
165
+ ### Using Element References
166
+
167
+ When you identify elements, note their ARIA role and accessible name for precise bug reports:
168
+
169
+ - Instead of: "the blue button in the header"
170
+ - Say: `button "Submit" [ref=e5]` or `link "Learn More" in navigation`
171
+
172
+ ### Network-Aware Testing
173
+
174
+ - If you see slow API calls, test what happens when users interact during loading
175
+ - If you see failed requests, verify the UI handles errors gracefully
176
+ - Check if retry mechanisms exist for transient failures
177
+
178
+ ### State Machine Thinking
179
+
180
+ Consider the app's states:
181
+
182
+ - Loading → Ready → Interacting → Submitting → Success/Error
183
+ - Test transitions between states
184
+ - What happens if you go backward unexpectedly?
185
+
186
+ ## Remember
187
+
188
+ - Be thorough but efficient
189
+ - Document everything with screenshots
190
+ - Think like a user who doesn't read instructions
191
+ - If something feels off, investigate it
192
+ - Your goal is to help improve quality, not just find faults
193
+ - Network and console issues often reveal bugs before they're visible
194
+ - A page that "looks fine" might have silent failures underneath
package/.eslintrc.json ADDED
@@ -0,0 +1,69 @@
1
+ {
2
+ "env": {
3
+ "node": true,
4
+ "es2021": true
5
+ },
6
+ "extends": ["eslint:recommended", "prettier"],
7
+ "parserOptions": {
8
+ "ecmaVersion": "latest",
9
+ "sourceType": "module"
10
+ },
11
+ "rules": {
12
+ "no-console": [
13
+ "warn",
14
+ {
15
+ "allow": ["log", "warn", "error"]
16
+ }
17
+ ],
18
+ "no-unused-vars": [
19
+ "error",
20
+ {
21
+ "argsIgnorePattern": "^_"
22
+ }
23
+ ],
24
+ "quotes": [
25
+ "error",
26
+ "single",
27
+ {
28
+ "avoidEscape": true
29
+ }
30
+ ],
31
+ "semi": ["error", "always"],
32
+ "comma-dangle": ["error", "always-multiline"],
33
+ "indent": ["error", 2],
34
+ "linebreak-style": ["error", "unix"],
35
+ "max-len": [
36
+ "warn",
37
+ {
38
+ "code": 100,
39
+ "ignorePattern": "^\\s*//|^\\s*\\*|https?://",
40
+ "ignoreStrings": true
41
+ }
42
+ ],
43
+ "no-var": "error",
44
+ "prefer-const": "error",
45
+ "prefer-arrow-callback": "warn",
46
+ "arrow-spacing": "error",
47
+ "no-multiple-empty-lines": [
48
+ "error",
49
+ {
50
+ "max": 1
51
+ }
52
+ ]
53
+ },
54
+ "overrides": [
55
+ {
56
+ "files": ["**/*.test.js"],
57
+ "env": {
58
+ "node": true
59
+ },
60
+ "globals": {
61
+ "describe": "readonly",
62
+ "it": "readonly",
63
+ "expect": "readonly",
64
+ "beforeEach": "readonly",
65
+ "afterEach": "readonly"
66
+ }
67
+ }
68
+ ]
69
+ }
@@ -0,0 +1,79 @@
1
+ ---
2
+ name: Bug Report
3
+ about: Report a bug to help us improve
4
+ title: '[BUG] '
5
+ labels: bug
6
+ assignees: ''
7
+ ---
8
+
9
+ ## Description
10
+
11
+ <!-- Provide a clear and concise description of the bug -->
12
+
13
+ ## Environment
14
+
15
+ <!-- Please provide details about your environment -->
16
+
17
+ - **OS**: (Windows / macOS / Linux)
18
+ - **Node version**: (e.g., 20.10.0)
19
+ - **npm version**: (e.g., 10.2.0)
20
+ - **Workflow platform**: (GitHub Actions)
21
+ - **Deployment platform**: (Vercel / Netlify / GitHub Pages / Other)
22
+
23
+ ## Steps to Reproduce
24
+
25
+ <!-- Provide detailed steps to reproduce the bug -->
26
+
27
+ 1.
28
+ 2.
29
+ 3.
30
+
31
+ ## Expected Behavior
32
+
33
+ <!-- What should happen? -->
34
+
35
+ ## Actual Behavior
36
+
37
+ <!-- What actually happens? -->
38
+
39
+ ## Screenshots or Logs
40
+
41
+ <!-- Add screenshots, workflow logs, or error messages if applicable -->
42
+
43
+ ### Workflow Logs
44
+
45
+ If this is a GitHub Actions issue:
46
+
47
+ 1. Go to your repository
48
+ 2. Actions tab → [Workflow name] → [Failed run]
49
+ 3. Expand the failed step and copy the output
50
+
51
+ <details>
52
+ <summary>Click to expand logs</summary>
53
+
54
+ ```
55
+ Paste logs here
56
+ ```
57
+
58
+ </details>
59
+
60
+ ## Additional Context
61
+
62
+ <!-- Add any other context about the problem -->
63
+
64
+ ## Frequency
65
+
66
+ - [ ] Always happens
67
+ - [ ] Happens sometimes (intermittent)
68
+ - [ ] Happens once
69
+
70
+ ## Severity
71
+
72
+ - [ ] Critical (site is broken)
73
+ - [ ] High (major functionality broken)
74
+ - [ ] Medium (some features affected)
75
+ - [ ] Low (minor issue)
76
+
77
+ ---
78
+
79
+ **Thank you for reporting this bug!** Your report helps us improve qaie.
@@ -0,0 +1,50 @@
1
+ ---
2
+ name: Feature Request
3
+ about: Suggest an improvement or new feature
4
+ title: '[FEATURE] '
5
+ labels: enhancement
6
+ assignees: ''
7
+ ---
8
+
9
+ ## Description
10
+
11
+ <!-- Provide a clear and concise description of the feature -->
12
+
13
+ ## Problem Statement
14
+
15
+ <!-- What problem does this feature solve? What is your use case? -->
16
+
17
+ ## Proposed Solution
18
+
19
+ <!-- Describe how you'd like the feature to work -->
20
+
21
+ ## Alternatives Considered
22
+
23
+ <!-- Are there other ways to solve this problem? -->
24
+
25
+ ## Example Usage
26
+
27
+ <!-- Provide examples of how this feature would be used -->
28
+
29
+ ```bash
30
+ # Example command or code
31
+ ```
32
+
33
+ ## Implementation Notes
34
+
35
+ <!-- If you have ideas about how to implement this, share them here -->
36
+
37
+ ## Priority
38
+
39
+ - [ ] Critical (blocking work)
40
+ - [ ] High (would significantly improve usability)
41
+ - [ ] Medium (nice to have)
42
+ - [ ] Low (would be nice eventually)
43
+
44
+ ## Additional Context
45
+
46
+ <!-- Add any other context or screenshots -->
47
+
48
+ ---
49
+
50
+ **Thank you for the suggestion!** Feature requests help us build a better tool.
@@ -0,0 +1,43 @@
1
+ ---
2
+ name: Security Vulnerability
3
+ about: Report a security vulnerability (do not use for public security issues)
4
+ title: '[SECURITY] '
5
+ labels: security
6
+ ---
7
+
8
+ ## SECURITY ADVISORY
9
+
10
+ **PLEASE DO NOT USE THIS FORM FOR PUBLIC SECURITY ISSUES**
11
+
12
+ If you've found a security vulnerability:
13
+
14
+ 1. **DO NOT** create a public issue or PR
15
+ 2. **DO NOT** post details in discussions or comments
16
+ 3. **Email** security report to: [security@example.com]
17
+
18
+ Include in your email:
19
+
20
+ - Description of the vulnerability
21
+ - Steps to reproduce
22
+ - Potential impact
23
+ - Suggested fix (if any)
24
+
25
+ ## Timeline
26
+
27
+ - **Initial Response**: 48 hours
28
+ - **Status Updates**: Every 7 days
29
+ - **Fix Release**: TBD based on severity
30
+ - **Public Disclosure**: After fix is released
31
+
32
+ ## Severity Levels
33
+
34
+ - **Critical**: Immediate data loss or security bypass
35
+ - **High**: Significant security impact
36
+ - **Medium**: Moderate security impact
37
+ - **Low**: Minor security issue
38
+
39
+ ---
40
+
41
+ Thank you for helping us keep qaie secure.
42
+
43
+ See [SECURITY.md](../../../SECURITY.md) for full policy.
@@ -0,0 +1,51 @@
1
+ version: 2
2
+ updates:
3
+ # Node.js dependencies
4
+ - package-ecosystem: 'npm'
5
+ directory: '/'
6
+ schedule:
7
+ interval: 'weekly'
8
+ day: 'monday'
9
+ time: '03:00'
10
+ open-pull-requests-limit: 10
11
+ pull-request-branch-name:
12
+ separator: '/'
13
+ reviewers:
14
+ - 'tyler-james-bridges'
15
+ assignees:
16
+ - 'tyler-james-bridges'
17
+ commit-message:
18
+ prefix: 'chore(deps):'
19
+ prefix-development: 'chore(deps-dev):'
20
+ include: 'scope'
21
+ allow:
22
+ # Allow security and runtime updates for dependencies
23
+ - dependency-type: 'production'
24
+ - dependency-type: 'development'
25
+ # Auto-merge security patches
26
+ auto-merge:
27
+ enabled: true
28
+ type: 'squash'
29
+ # Skip for major version updates (require manual review)
30
+ ignore:
31
+ - dependency-name: '@anthropic-ai/claude-code'
32
+ # Major version updates require manual review
33
+ update-types:
34
+ - 'version-update:semver-major'
35
+
36
+ # GitHub Actions
37
+ - package-ecosystem: 'github-actions'
38
+ directory: '/'
39
+ schedule:
40
+ interval: 'weekly'
41
+ day: 'monday'
42
+ time: '04:00'
43
+ open-pull-requests-limit: 5
44
+ reviewers:
45
+ - 'tyler-james-bridges'
46
+ commit-message:
47
+ prefix: 'ci(actions):'
48
+ include: 'scope'
49
+ auto-merge:
50
+ enabled: true
51
+ type: 'squash'
@@ -0,0 +1,11 @@
1
+ ## What
2
+
3
+ <!-- Brief description of changes -->
4
+
5
+ ## Why
6
+
7
+ <!-- Why is this needed? -->
8
+
9
+ ## Testing
10
+
11
+ <!-- How did you verify this works? -->
@@ -0,0 +1,35 @@
1
+ name: Lint
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+ branches: [main]
8
+
9
+ jobs:
10
+ lint:
11
+ runs-on: ubuntu-latest
12
+ steps:
13
+ - name: Checkout
14
+ uses: actions/checkout@v4
15
+
16
+ - name: Setup Node.js
17
+ uses: actions/setup-node@v4
18
+ with:
19
+ node-version: '20'
20
+ cache: 'npm'
21
+
22
+ - name: Install dependencies
23
+ run: npm ci
24
+
25
+ - name: Run ESLint
26
+ run: npm run lint
27
+
28
+ - name: Validate workflow files
29
+ run: |
30
+ echo "Validating workflow YAML syntax..."
31
+ for file in .github/workflows/*.yml; do
32
+ echo "Checking $file"
33
+ python3 -c "import yaml; yaml.safe_load(open('$file'))" || exit 1
34
+ done
35
+ echo "All workflow files are valid YAML"