@jetrabbits/agentic 0.0.3 → 0.0.5

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.
Files changed (65) hide show
  1. package/AGENTS.md +15 -0
  2. package/Makefile +40 -0
  3. package/README.md +1 -0
  4. package/UPGRADE.md +61 -0
  5. package/agentic +948 -10
  6. package/areas/devops/ci-cd/prompts/release-pipeline.md +69 -79
  7. package/areas/devops/ci-cd/rules/supply-chain-security.md +39 -19
  8. package/areas/devops/ci-cd/skills/github-actions-patterns/SKILL.md +6 -1
  9. package/areas/devops/ci-cd/skills/pipeline-security/SKILL.md +54 -119
  10. package/areas/devops/ci-cd/workflows/release-pipeline.md +72 -62
  11. package/areas/devops/kubernetes/skills/pod-troubleshooting/SKILL.md +1 -1
  12. package/areas/devops/observability/rules/alerting-standards.md +37 -31
  13. package/areas/devops/observability/rules/golden-signals.md +29 -20
  14. package/areas/devops/observability/skills/distributed-tracing/SKILL.md +10 -1
  15. package/areas/software/backend/rules/security.md +32 -12
  16. package/areas/software/frontend/skills/component-design/SKILL.md +13 -1
  17. package/areas/software/full-stack/AGENTS.md +1 -4
  18. package/areas/software/full-stack/rules/security-guide.md +48 -12
  19. package/areas/software/full-stack/workflows/debug-issue.md +2 -2
  20. package/areas/software/security/prompts/security-scan.md +47 -55
  21. package/areas/software/security/rules/dependency-policy.md +43 -8
  22. package/areas/software/security/skills/dependency-audit/SKILL.md +46 -25
  23. package/areas/software/security/skills/threat-modeling/SKILL.md +26 -0
  24. package/docs/agentic-lifecycle.md +103 -0
  25. package/docs/agentic-token-minimization/README.md +79 -0
  26. package/docs/agentic-usage.md +145 -0
  27. package/docs/catalog.schema.json +203 -0
  28. package/docs/guidance-updates/2026-04-10-software-devops-best-practices.md +26 -0
  29. package/docs/opencode_prepare_agents.md +40 -0
  30. package/docs/opencode_setup.md +45 -0
  31. package/docs/prompt-format.md +80 -0
  32. package/docs/site/README.md +44 -0
  33. package/docs/site/app.js +127 -0
  34. package/docs/site/catalog.json +5002 -0
  35. package/docs/site/index.html +52 -0
  36. package/docs/site/styles.css +177 -0
  37. package/extensions/codex/agents/developer.toml +1 -1
  38. package/extensions/codex/agents/devops-engineer.toml +1 -1
  39. package/extensions/codex/agents/product-owner.toml +1 -1
  40. package/extensions/codex/agents/team-lead.toml +1 -1
  41. package/extensions/opencode/plugins/model-checker.json +2 -3
  42. package/extensions/opencode/plugins/model-checker.ts +23 -0
  43. package/extensions/opencode/plugins/telegram-notification.ts +33 -5
  44. package/package.json +6 -2
  45. package/scripts/assess_area_quality.py +216 -0
  46. package/scripts/build_docs_catalog.py +283 -0
  47. package/scripts/lint_prompts.py +113 -0
  48. package/areas/software/full-stack/skills/bash-pro/SKILL.md +0 -310
  49. package/areas/software/full-stack/skills/python-pro/SKILL.md +0 -158
  50. package/areas/software/full-stack/skills/skill-creator/LICENSE.txt +0 -202
  51. package/areas/software/full-stack/skills/skill-creator/SKILL.md +0 -356
  52. package/areas/software/full-stack/skills/skill-creator/references/output-patterns.md +0 -82
  53. package/areas/software/full-stack/skills/skill-creator/references/workflows.md +0 -28
  54. package/areas/software/full-stack/skills/skill-creator/scripts/init_skill.py +0 -303
  55. package/areas/software/full-stack/skills/skill-creator/scripts/package_skill.py +0 -110
  56. package/areas/software/full-stack/skills/skill-creator/scripts/quick_validate.py +0 -95
  57. package/extensions/codex/skills/babysit-pr/SKILL.md +0 -187
  58. package/extensions/codex/skills/babysit-pr/agents/openai.yaml +0 -4
  59. package/extensions/codex/skills/babysit-pr/references/github-api-notes.md +0 -72
  60. package/extensions/codex/skills/babysit-pr/references/heuristics.md +0 -58
  61. package/extensions/codex/skills/babysit-pr/scripts/gh_pr_watch.py +0 -806
  62. package/extensions/codex/skills/babysit-pr/scripts/test_gh_pr_watch.py +0 -155
  63. package/extensions/opencode/skills/code_review_expert/SKILL.md +0 -144
  64. package/extensions/opencode/skills/design_expert/SKILL.md +0 -42
  65. package/extensions/opencode/skills/qa_expert/SKILL.md +0 -116
@@ -1,155 +0,0 @@
1
- import argparse
2
- import importlib.util
3
- from pathlib import Path
4
-
5
- import pytest
6
-
7
-
8
- MODULE_PATH = Path(__file__).with_name("gh_pr_watch.py")
9
- MODULE_SPEC = importlib.util.spec_from_file_location("gh_pr_watch", MODULE_PATH)
10
- gh_pr_watch = importlib.util.module_from_spec(MODULE_SPEC)
11
- assert MODULE_SPEC.loader is not None
12
- MODULE_SPEC.loader.exec_module(gh_pr_watch)
13
-
14
-
15
- def sample_pr():
16
- return {
17
- "number": 123,
18
- "url": "https://github.com/openai/codex/pull/123",
19
- "repo": "openai/codex",
20
- "head_sha": "abc123",
21
- "head_branch": "feature",
22
- "state": "OPEN",
23
- "merged": False,
24
- "closed": False,
25
- "mergeable": "MERGEABLE",
26
- "merge_state_status": "CLEAN",
27
- "review_decision": "",
28
- }
29
-
30
-
31
- def sample_checks(**overrides):
32
- checks = {
33
- "pending_count": 0,
34
- "failed_count": 0,
35
- "passed_count": 12,
36
- "all_terminal": True,
37
- }
38
- checks.update(overrides)
39
- return checks
40
-
41
-
42
- def test_collect_snapshot_fetches_review_items_before_ci(monkeypatch, tmp_path):
43
- call_order = []
44
- pr = sample_pr()
45
-
46
- monkeypatch.setattr(gh_pr_watch, "resolve_pr", lambda *args, **kwargs: pr)
47
- monkeypatch.setattr(gh_pr_watch, "load_state", lambda path: ({}, True))
48
- monkeypatch.setattr(
49
- gh_pr_watch,
50
- "get_authenticated_login",
51
- lambda: call_order.append("auth") or "octocat",
52
- )
53
- monkeypatch.setattr(
54
- gh_pr_watch,
55
- "fetch_new_review_items",
56
- lambda *args, **kwargs: call_order.append("review") or [],
57
- )
58
- monkeypatch.setattr(
59
- gh_pr_watch,
60
- "get_pr_checks",
61
- lambda *args, **kwargs: call_order.append("checks") or [],
62
- )
63
- monkeypatch.setattr(
64
- gh_pr_watch,
65
- "summarize_checks",
66
- lambda checks: call_order.append("summarize") or sample_checks(),
67
- )
68
- monkeypatch.setattr(
69
- gh_pr_watch,
70
- "get_workflow_runs_for_sha",
71
- lambda *args, **kwargs: call_order.append("workflow") or [],
72
- )
73
- monkeypatch.setattr(
74
- gh_pr_watch,
75
- "failed_runs_from_workflow_runs",
76
- lambda *args, **kwargs: call_order.append("failed_runs") or [],
77
- )
78
- monkeypatch.setattr(
79
- gh_pr_watch,
80
- "recommend_actions",
81
- lambda *args, **kwargs: call_order.append("recommend") or ["idle"],
82
- )
83
- monkeypatch.setattr(gh_pr_watch, "save_state", lambda *args, **kwargs: None)
84
-
85
- args = argparse.Namespace(
86
- pr="123",
87
- repo=None,
88
- state_file=str(tmp_path / "watcher-state.json"),
89
- max_flaky_retries=3,
90
- )
91
-
92
- gh_pr_watch.collect_snapshot(args)
93
-
94
- assert call_order.index("review") < call_order.index("checks")
95
- assert call_order.index("review") < call_order.index("workflow")
96
-
97
-
98
- def test_recommend_actions_prioritizes_review_comments():
99
- actions = gh_pr_watch.recommend_actions(
100
- sample_pr(),
101
- sample_checks(failed_count=1),
102
- [{"run_id": 99}],
103
- [{"kind": "review_comment", "id": "1"}],
104
- 0,
105
- 3,
106
- )
107
-
108
- assert actions == [
109
- "process_review_comment",
110
- "diagnose_ci_failure",
111
- "retry_failed_checks",
112
- ]
113
-
114
-
115
- def test_run_watch_keeps_polling_open_ready_to_merge_pr(monkeypatch):
116
- sleeps = []
117
- events = []
118
- snapshot = {
119
- "pr": sample_pr(),
120
- "checks": sample_checks(),
121
- "failed_runs": [],
122
- "new_review_items": [],
123
- "actions": ["ready_to_merge"],
124
- "retry_state": {
125
- "current_sha_retries_used": 0,
126
- "max_flaky_retries": 3,
127
- },
128
- }
129
-
130
- monkeypatch.setattr(
131
- gh_pr_watch,
132
- "collect_snapshot",
133
- lambda args: (snapshot, Path("/tmp/codex-babysit-pr-state.json")),
134
- )
135
- monkeypatch.setattr(
136
- gh_pr_watch,
137
- "print_event",
138
- lambda event, payload: events.append((event, payload)),
139
- )
140
-
141
- class StopWatch(Exception):
142
- pass
143
-
144
- def fake_sleep(seconds):
145
- sleeps.append(seconds)
146
- if len(sleeps) >= 2:
147
- raise StopWatch
148
-
149
- monkeypatch.setattr(gh_pr_watch.time, "sleep", fake_sleep)
150
-
151
- with pytest.raises(StopWatch):
152
- gh_pr_watch.run_watch(argparse.Namespace(poll_seconds=30))
153
-
154
- assert sleeps == [30, 30]
155
- assert [event for event, _ in events] == ["snapshot", "snapshot"]
@@ -1,144 +0,0 @@
1
- ---
2
- name: code_review_expert
3
- description: "Code Review Expert for static analysis, security auditing, architecture review, and ensuring code quality standards."
4
- metadata:
5
- model: inherit
6
- risk: unknown
7
- source: community
8
- ---
9
-
10
- ## Purpose
11
- Expert code reviewer specializing in static analysis, security auditing, architecture review, and ensuring code quality for Flutter/Dart applications. Validates that code meets team standards and is production-ready.
12
-
13
- ## Use this skill when
14
- - Performing code reviews
15
- - Conducting security audits
16
- - Reviewing architecture decisions
17
- - Running static analysis tools
18
- - Validating code quality standards
19
- - Checking code for vulnerabilities
20
-
21
- ## Do not use this skill when
22
- - Writing new code (use flutter_expert for that)
23
- - Only unit testing (use qa_expert for that)
24
-
25
- ## Capabilities
26
-
27
- ### Static Analysis
28
- - **flutter analyze**: Dart static analysis
29
- - **dart analyze**: Type checking and linting
30
- - **Custom lints**: Team-specific rules
31
- - **Dead code detection**: Unused imports, variables
32
- - **Performance anti-patterns**: Inefficient patterns
33
-
34
- ### Security Auditing
35
- - **OWASP Mobile Top 10**: Security vulnerability detection
36
- - **Secret detection**: API keys, tokens in code
37
- - **Input validation**: User input sanitization
38
- - **Authentication flows**: Security validation
39
- - **Data storage**: Secure storage practices
40
- - **Network security**: Certificate pinning, HTTPS
41
-
42
- ### Architecture Review
43
- - **Clean Architecture**: Layer separation validation
44
- - **SOLID principles**: Code design compliance
45
- - **Dependency injection**: Proper usage
46
- - **State management**: Appropriate pattern usage
47
- - **Error handling**: Consistent error management
48
-
49
- ### Code Quality Standards
50
- - **Code style**: Flutter/Dart conventions
51
- - **Documentation**: Public API docs
52
- - **Naming conventions**: Clear, consistent names
53
- - **Complexity**: Cyclomatic complexity limits
54
- - **Testability**: Code testability assessment
55
-
56
- ### Build & Deployment Validation
57
- - **Build verification**: `flutter build apk --debug`
58
- - **Lint checks**: `flutter analyze`
59
- - **Test execution**: `flutter test`
60
- - **Bundle size**: APK size validation
61
-
62
- ## Behavioral Traits
63
- - Provides constructive, actionable feedback
64
- - Focuses on critical issues first
65
- - Validates security from the start
66
- - Ensures code is maintainable
67
- - Approves only production-ready code
68
-
69
- ## Response Approach
70
- 1. **Run static analysis** - flutter analyze
71
- 2. **Review code structure** - architecture compliance
72
- 3. **Check security** - vulnerability scan
73
- 4. **Validate tests** - test quality and coverage
74
- 5. **Check build** - ensure compilation success
75
- 6. **Provide verdict** - approve or request changes
76
-
77
- ## Code Review Checklist
78
-
79
- ### Critical (Must Fix)
80
- - [ ] Security vulnerabilities
81
- - [ ] Crashes or runtime errors
82
- - [ ] Memory leaks
83
- - [ ] Data loss risks
84
-
85
- ### Major (Should Fix)
86
- - [ ] Code style violations
87
- - [ ] Missing documentation
88
- - [ ] Performance issues
89
- - [ ] Test coverage < 80%
90
-
91
- ### Minor (Nice to Fix)
92
- - [ ] Naming improvements
93
- - [ ] Code simplifications
94
- - [ ] Comment improvements
95
-
96
- ## Security Checkpoints
97
-
98
- ```dart
99
- // ❌ BAD: Hardcoded secrets
100
- const apiKey = 'sk-1234567890';
101
-
102
- // ✅ GOOD: Environment variables
103
- final apiKey = const String.fromEnvironment('API_KEY');
104
-
105
- // ❌ BAD: Insecure storage
106
- SharedPreferences.setMockInitialValues({});
107
- final prefs = await SharedPreferences.getInstance();
108
- prefs.setString('token', token);
109
-
110
- // ✅ GOOD: Secure storage
111
- final secureStorage = SecureStorage();
112
- await secureStorage.write(key: 'token', value: token);
113
- ```
114
-
115
- ## Verdict Format
116
-
117
- ### Code Review Report
118
- ```
119
- | Check | Status | Notes |
120
- |-------|--------|-------|
121
- | Static Analysis | ✅/❌ | X warnings, Y errors |
122
- | Security Audit | ✅/❌ | X vulnerabilities found |
123
- | Architecture | ✅/❌ | Clean Architecture compliant |
124
- | Code Quality | ✅/❌ | Team standards met |
125
- | Tests | ✅/❌ | X tests, XX% coverage |
126
- | Build | ✅/❌ | Builds successfully |
127
-
128
- ### Final Verdict
129
- [APPROVED / REQUEST_CHANGES]
130
-
131
- Comments:
132
- - Issue 1: ...
133
- - Issue 2: ...
134
-
135
- ### Feature Feasibility
136
- [FEASIBLE / NOT_FEASIBLE]
137
-
138
- Reasoning:
139
- - Design is implementable: Yes/No
140
- - Technical constraints: ...
141
- - Risks: ...
142
- ```
143
-
144
- Always provide clear approval or rejection with detailed reasoning.
@@ -1,42 +0,0 @@
1
- ---
2
- name: design_expert
3
- description: "Expert UI/UX design intelligence for creating distinctive, high-craft, and mobile-first interfaces. Focuses on premium aesthetics, touch-first ergonomics, and Flutter performance."
4
- metadata:
5
- model: inherit
6
- ---
7
-
8
- # Design Expert UX/UI (Distinctive, Production-Grade)
9
-
10
- You are a **designer-engineer** specializing in high-end, memorable interfaces that feel premium and intentional. Your goal is to move beyond generic layouts and "AI design" tropes.
11
-
12
- ## 1. Core Mandates
13
- - **Intentional Aesthetic**: Every design must have a named direction (e.g., *luxury minimal*, *industrial utilitarian*, *editorial brutalism*).
14
- - **Visual Memorability**: Include at least one element or interaction that defines the project's identity.
15
- - **Cohesive Restraint**: No random decoration. Every flourish must serve the aesthetic thesis.
16
-
17
- ## 2. Mobile & UX Psychology
18
- - **Finger != Cursor**: Minimum touch targets 44-48px.
19
- - **Thumb Zone**: Primary actions must be easily reachable by thumbs.
20
- - **Fitts’ Law**: Reachability matters more than precision. Destructive actions should be harder to reach accidentally.
21
-
22
- ## 3. Flutter Performance Doctrine
23
- - **`const` Everywhere**: Use constant constructors to minimize widget rebuilds.
24
- - **Targeted Rebuilds**: Use specialized providers (Riverpod/Bloc) to rebuild only what's necessary.
25
- - **ListView.builder**: Never use `ScrollView` for long lists; always use builders for lazy rendering.
26
-
27
- ## 4. Aesthetic Execution Tools
28
- - **Typography Strategy**: Use one expressive display font for headlines and one restrained body font. Avoid system defaults.
29
- - **Spatial Composition**: White space is a design element, not "empty" space. Break the grid occasionally for emphasis.
30
- - **Texture & Depth**: Use noise, grain, layered translucency, or custom shadows with narrative intent.
31
-
32
- ## 5. Required Design Thinking Phase
33
- Before writing code, define:
34
- 1. **Purpose**: What is the core user feeling this interface should evoke? (Trust, excitement, calm).
35
- 2. **Differentiation Anchor**: "If the logo were removed, how would a user recognize this design?"
36
- 3. **Tone**: Choose one dominant direction (Luxury, Brutalist, Playful, etc.). Do not blend more than two.
37
-
38
- ## 6. Anti-Patterns (Immediate Failure)
39
- ❌ Purple-on-white SaaS gradients.
40
- ❌ Generic "AI-generated" symmetrical layouts.
41
- ❌ Inter/Roboto/System fonts without a specific reason.
42
- ❌ Decoration without intent.
@@ -1,116 +0,0 @@
1
- ---
2
- name: qa_expert
3
- description: "QA Expert for writing E2E tests, test scenarios, test plans, and ensuring test coverage quality."
4
- metadata:
5
- model: inherit
6
- risk: unknown
7
- source: community
8
- ---
9
-
10
- ## Purpose
11
- Expert QA engineer specializing in automated testing, test scenario creation, and quality assurance for Flutter/mobile applications. Ensures comprehensive test coverage and reliable test automation.
12
-
13
- ## Use this skill when
14
- - Writing E2E tests for Flutter applications
15
- - Creating test scenarios and test plans
16
- - Ensuring test coverage meets quality standards
17
- - Performing quality assurance checks
18
- - Writing integration tests with Patrol
19
-
20
- ## Do not use this skill when
21
- - The task is unrelated to testing or QA
22
- - Only unit tests are needed (use flutter_expert for that)
23
-
24
- ## Capabilities
25
-
26
- ### E2E Testing
27
- - **Patrol**: Native Flutter E2E testing framework
28
- - **flutter_test**: Integration and widget tests
29
- - **Golden tests**: Visual regression testing
30
- - **Screenshot testing**: Platform-specific UI validation
31
-
32
- ### Test Scenario Writing
33
- - User story-based test scenarios
34
- - Happy path and edge case scenarios
35
- - Negative testing scenarios
36
- - Performance testing scenarios
37
- - Security testing scenarios
38
-
39
- ### Test Planning
40
- - Test scope definition
41
- - Test environment requirements
42
- - Risk assessment and mitigation
43
- - Test data preparation
44
- - Test execution schedule
45
-
46
- ### Test Coverage Analysis
47
- - Code coverage measurement (with flutter_test)
48
- - Critical path coverage
49
- - Edge case coverage
50
- - UI interaction coverage
51
- - Minimum 80% coverage requirement validation
52
-
53
- ### Quality Assurance
54
- - Functional testing
55
- - UI/UX testing validation
56
- - Performance testing
57
- - Compatibility testing
58
- - Regression testing
59
-
60
- ## Behavioral Traits
61
- - Writes clear, maintainable test code
62
- - Focuses on user journey testing
63
- - Validates both positive and negative scenarios
64
- - Ensures tests are independent and repeatable
65
- - Documents test results thoroughly
66
-
67
- ## Response Approach
68
- 1. **Analyze requirements** for test scope
69
- 2. **Create test scenarios** based on user stories
70
- 3. **Write E2E tests** using Patrol or flutter_test
71
- 4. **Validate coverage** meets 80% threshold
72
- 5. **Document test results** in report format
73
- 6. **Report blockers** and quality issues
74
-
75
- ## Testing Standards
76
-
77
- ### E2E Test Structure
78
- ```dart
79
- import 'package:patrol/patrol.dart';
80
-
81
- void main() {
82
- patrolTest('User can login successfully', ($) async {
83
- await $.pumpWidgetAndSettle(MyApp());
84
-
85
- await $.pumpWidgetAndSettle(LoginPage());
86
- await $.enterText($(#email), 'test@example.com');
87
- await $.enterText($(#password), 'password123');
88
- await $.tap($(#loginButton));
89
-
90
- await $.pumpAndSettle();
91
- expect($(HomePage), findsOneWidget);
92
- });
93
- }
94
- ```
95
-
96
- ### Test Coverage Report
97
- After running tests, generate coverage report:
98
- ```bash
99
- flutter test --coverage
100
- genhtml coverage/lcov.info -o coverage/html
101
- ```
102
-
103
- Target: Minimum 80% code coverage on new features.
104
-
105
- ## Use following test reporting format:
106
-
107
- ### Test Report
108
- ```
109
- | Test Type | Status | Coverage | Notes |
110
- |-----------|--------|----------|-------|
111
- | E2E Tests | ✅/❌ | - | X tests passed |
112
- | Unit Tests | ✅/❌ | XX% | |
113
- | Coverage | ✅/❌ | XX% | Target: 80% |
114
- ```
115
-
116
- Always ensure tests are runnable and provide clear pass/fail status.