@moon791017/neo-skills 1.1.26 → 1.1.28
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.
- package/README.md +2 -0
- package/package.json +1 -1
- package/skills/neo-code-review/SKILL.md +27 -13
- package/skills/neo-code-review/evals/eval_queries.json +7 -2
- package/skills/neo-code-review/evals/evals.json +34 -0
- package/skills/neo-code-review/references/review-checklist.md +13 -3
- package/skills/neo-rabbitmq/SKILL.md +89 -0
- package/skills/neo-rabbitmq/evals/eval_queries.json +82 -0
- package/skills/neo-rabbitmq/evals/evals.json +114 -0
- package/skills/neo-rabbitmq/references/development.md +71 -0
- package/skills/neo-rabbitmq/references/operations.md +77 -0
- package/skills/neo-rabbitmq/references/performance.md +98 -0
- package/skills/neo-rabbitmq/references/sources-and-scope.md +56 -0
- package/skills/neo-rabbitmq/references/troubleshooting.md +84 -0
- package/skills/neo-stop-slop/SKILL.md +86 -74
- package/skills/neo-stop-slop/evals/eval_queries.json +20 -0
- package/skills/neo-stop-slop/evals/evals.json +50 -9
- package/skills/neo-stop-slop/references/article-rewrite.md +37 -0
- package/skills/neo-stop-slop/references/dev-slop.md +37 -28
- package/skills/neo-stop-slop/references/examples.md +25 -25
- package/skills/neo-stop-slop/references/phrases-zh.md +27 -23
- package/skills/neo-stop-slop/references/structures.md +60 -45
- package/skills/neo-stop-slop/scripts/analyze-slop.js +66 -66
package/README.md
CHANGED
|
@@ -63,6 +63,7 @@
|
|
|
63
63
|
| Agent 架構 | `neo-sub-agent` | 設計、建立、審查或轉換 sub-agent、custom agent、worker/reviewer/planner agent 或 multi-agent workflow。 |
|
|
64
64
|
| 技能開發 | `generate-skill` | 建立、更新、審查或最佳化 Agent Skill,包含規格、觸發描述、延伸資源、評估資料與設計模式。 |
|
|
65
65
|
| 可觀測性 | `neo-opentelemetry` | 解釋 OpenTelemetry 概念、規劃或審查 Collector 架構與設定、處理維運排障、安全、零程式 instrumentation 及相容性遷移。 |
|
|
66
|
+
| queue | `neo-rabbitmq` | 以 RabbitMQ 4.3 為預設,提供語言中立的訊息拓撲、Broker 營運、監控排障與效能優化指引。 |
|
|
66
67
|
| 文字潤飾 | `neo-stop-slop` | 去除繁中或英文中的 AI 腔、贅詞、公式化句式,支援文件、註解、commit message 與 PR 說明。 |
|
|
67
68
|
| PR 產出 | `neo-pr` | 詢問或自動偵測 Repository 來源與目標分支,擷取變更並產生重點式且去 AI 腔的 PR Title 與 PR Description。 |
|
|
68
69
|
|
|
@@ -156,4 +157,5 @@ npx -p @moon791017/neo-skills install-system-instructions \
|
|
|
156
157
|
| 建立 Agent 治理 | `neo-harness` | `幫我針對這個專案評估並產生 AGENTS.md` |
|
|
157
158
|
| 建立 sub-agent | `neo-sub-agent` | `幫我新增一個 Codex code-reviewer sub agent` |
|
|
158
159
|
| 規劃 OpenTelemetry | `neo-opentelemetry` | `幫我審查 Collector 架構、韌性、安全與零程式觀測方案` |
|
|
160
|
+
| 設計 RabbitMQ 系統 | `neo-rabbitmq` | `請分析 RabbitMQ Queue 堆積、叢集營運與效能瓶頸` |
|
|
159
161
|
| 去掉 AI 腔 | `neo-stop-slop` | `把這段 PR 說明改得自然、直接一點` |
|
package/package.json
CHANGED
|
@@ -3,45 +3,56 @@ name: neo-code-review
|
|
|
3
3
|
description: >
|
|
4
4
|
Use this skill when the user asks to review or audit source code, a PR, diff, commit,
|
|
5
5
|
or recent changes for bugs, security, performance, tests, compatibility, or
|
|
6
|
-
maintainability
|
|
7
|
-
|
|
8
|
-
file and line evidence.
|
|
6
|
+
maintainability, duplicated code or logic across files, or hard-coded values. Also use
|
|
7
|
+
it after an AI agent finishes modifying code to inspect the current uncommitted working
|
|
8
|
+
tree before handoff and report actionable findings with file and line evidence.
|
|
9
9
|
compatibility: Requires Python 3.11+ and uv for the Git change helper.
|
|
10
10
|
---
|
|
11
11
|
|
|
12
12
|
# Code Review
|
|
13
13
|
|
|
14
|
-
|
|
14
|
+
Follow this read-only workflow. Report only actionable findings supported by evidence.
|
|
15
15
|
|
|
16
16
|
## Trigger On
|
|
17
17
|
|
|
18
18
|
- The user requests a code, PR, diff, commit, security, performance, test, or maintainability review.
|
|
19
|
+
- The user asks whether code or logic is duplicated across files, or whether hard-coded values should be centralized.
|
|
19
20
|
- An AI Agent finishes modifying code, tests, configuration, or scripts before handoff.
|
|
20
21
|
|
|
21
22
|
## Workflow
|
|
22
23
|
|
|
23
|
-
1. **
|
|
24
|
-
- Use the files or
|
|
25
|
-
- If no scope
|
|
24
|
+
1. **Define the review scope**
|
|
25
|
+
- Use the files or snippets supplied by the user as the primary scope.
|
|
26
|
+
- If the user provides no scope and the current directory is a Git repository, run:
|
|
26
27
|
```bash
|
|
27
28
|
uv run skills/neo-code-review/scripts/git-diff-reviewer.py --working-tree
|
|
28
29
|
```
|
|
29
30
|
- Use `--staged` for staged-only changes and `--commit <range>` for a commit range.
|
|
30
31
|
- Read surrounding code, related tests, and existing contracts. If no reviewable input exists, report it and stop.
|
|
32
|
+
- For a working-tree review, include the helper's tracked diff and each non-ignored untracked file as separate inputs.
|
|
31
33
|
|
|
32
|
-
2. **Load the rules**
|
|
34
|
+
2. **Load the review rules**
|
|
33
35
|
- Read [review-checklist.md](references/review-checklist.md) before evaluating code.
|
|
34
36
|
- Identify the actual language, framework, and affected behavior from the change. Do not infer unverified rules from filenames.
|
|
35
37
|
|
|
36
|
-
3. **
|
|
38
|
+
3. **Run the cross-file consistency scan**
|
|
39
|
+
- Build the comparison set from the review targets and relevant repository source and configuration files. Use `rg --files` and the repository's ignore rules. Exclude dependency, vendor, cache, generated, minified, build, and coverage output unless a file is explicitly in scope.
|
|
40
|
+
- Inventory changed or reviewed functions, classes, validation and authorization rules, state transitions, request or query construction, error handling, and distinctive literals such as URLs, routes, timeouts, retry counts, thresholds, regexes, feature flags, and error messages.
|
|
41
|
+
- Search the comparison set for exact and near-exact matches, then read each match in context. Ignore name and formatting differences when the behavior matches. Treat renamed or slightly rearranged copies as duplicates when their business rules, inputs, side effects, and failure behavior are materially the same.
|
|
42
|
+
- Report only meaningful duplication: copied implementation, duplicated business or validation logic, divergent security or state logic, or repeated non-trivial hard-coded configuration. Do not report a match based only on a common keyword, normal one-time literal, test fixture, snapshot, generated file, or vendor code.
|
|
43
|
+
- For every cross-file finding, cite both file paths and line numbers. Explain the concrete maintenance, divergence, security, or behavior risk and recommend a specific shared helper, constant, configuration source, or other single source of truth.
|
|
44
|
+
- If the user supplied only a snippet or specific files without repository context, state in `## Validation` that cross-file verification was unavailable. Never invent repository matches or line evidence.
|
|
45
|
+
|
|
46
|
+
4. **Analyze risk**
|
|
37
47
|
- Prioritize correctness, regressions, security, data consistency, resource lifetime, concurrency, and high-risk test gaps.
|
|
38
48
|
- `🔴 Critical Issues` contain only security vulnerabilities, data loss, incorrect behavior, authorization bypasses, or major regressions.
|
|
39
49
|
- `🟡 Suggestions` contain only actionable, non-blocking issues with a clear impact and remediation direction.
|
|
50
|
+
- Classify ordinary duplicated logic or hard-coded configuration as `🟡 Suggestions`. Classify hard-coded secrets or duplication that creates a demonstrable security or behavior defect as `🔴 Critical Issues`.
|
|
40
51
|
- Do not report preferences, unsupported speculation, or checklist items that were not triggered by evidence.
|
|
41
52
|
|
|
42
|
-
|
|
53
|
+
5. **Produce a concise report**
|
|
43
54
|
- Write in English and preserve file paths and line numbers, such as `src/user.ts:42`.
|
|
44
|
-
- Use this structure.
|
|
55
|
+
- Use this structure. Keep all severity sections and write `None` when a section has no findings:
|
|
45
56
|
|
|
46
57
|
```markdown
|
|
47
58
|
## 🔍 Review Summary
|
|
@@ -56,15 +67,18 @@ Use the Reviewer workflow. Keep the review read-only and report only evidence-ba
|
|
|
56
67
|
|
|
57
68
|
## 🟡 Suggestions
|
|
58
69
|
- **Location**: `path:line`
|
|
70
|
+
- **Type**: Duplicated logic, duplicated hard-coded value, or another applicable category.
|
|
71
|
+
- **Evidence**: The matching location and the relevant behavior or value in each file.
|
|
59
72
|
- **Recommendation**: Specific, non-blocking improvement.
|
|
60
73
|
|
|
61
74
|
## 🟢 Strengths
|
|
62
75
|
- List only strengths directly supported by the change.
|
|
63
76
|
|
|
64
77
|
## Validation
|
|
65
|
-
-
|
|
78
|
+
- State the cross-file comparison scope and any unavailable repository context.
|
|
79
|
+
- List executed tests, builds, and checks. Name any that were not run.
|
|
66
80
|
```
|
|
67
81
|
|
|
68
|
-
|
|
82
|
+
6. **Apply the delivery gate**
|
|
69
83
|
- If an automatic review finds `🔴 Critical Issues`, cannot establish the review scope, or cannot load the skill, do not declare completion or hand off.
|
|
70
84
|
- After fixing findings, rerun the required checks and review the changes again.
|
|
@@ -10,7 +10,10 @@
|
|
|
10
10
|
"Is this TypeScript code well designed? What should be improved?",
|
|
11
11
|
"Check this SQL query for performance problems, slow queries, or missing indexes",
|
|
12
12
|
"Run static code analysis and identify problems in this Go project",
|
|
13
|
-
"An AI Agent just finished modifying code. Review the uncommitted changes before handoff"
|
|
13
|
+
"An AI Agent just finished modifying code. Review the uncommitted changes before handoff",
|
|
14
|
+
"Review this pull request and check whether validation logic or hard-coded limits are duplicated in other source files",
|
|
15
|
+
"Audit the repository for copy-pasted business rules and repeated URLs, timeouts, or thresholds introduced by these changes",
|
|
16
|
+
"Check whether the same implementation appears in different files and whether repeated configuration should be centralized"
|
|
14
17
|
],
|
|
15
18
|
"should_not_trigger": [
|
|
16
19
|
"How do I install Git?",
|
|
@@ -23,6 +26,8 @@
|
|
|
23
26
|
"Translate this Python code into Rust",
|
|
24
27
|
"What is the principle behind SQL injection?",
|
|
25
28
|
"Generate today's development progress report",
|
|
26
|
-
"Run the current project's tests only; do not perform a code review"
|
|
29
|
+
"Run the current project's tests only; do not perform a code review",
|
|
30
|
+
"How should I extract duplicated code into a shared helper?",
|
|
31
|
+
"Write a script that detects repeated literals across a repository"
|
|
27
32
|
]
|
|
28
33
|
}
|
|
@@ -36,6 +36,40 @@
|
|
|
36
36
|
"If 🔴 Critical Issues are found, the status blocks delivery",
|
|
37
37
|
"The report invents no findings when no changes exist"
|
|
38
38
|
]
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"id": 4,
|
|
42
|
+
"prompt": "Review these changed TypeScript files for correctness and compare them with each other for duplicated logic and hard-coded values. File: src/orders/createOrder.ts\n```typescript\nconst MAX_ITEMS = 50;\n\nexport function validateCreateItems(items: Item[]): void {\n if (items.length > MAX_ITEMS) throw new Error('Too many items');\n for (const item of items) {\n if (item.quantity <= 0) throw new Error('Invalid quantity');\n }\n}\n```\nFile: src/orders/updateOrder.ts\n```typescript\nconst MAX_ITEMS = 50;\n\nexport function validateUpdateItems(items: Item[]): void {\n if (items.length > MAX_ITEMS) throw new Error('Too many items');\n for (const item of items) {\n if (item.quantity <= 0) throw new Error('Invalid quantity');\n }\n}\n```",
|
|
43
|
+
"expected_output": "A concise English review report that identifies the duplicated item-validation logic and repeated MAX_ITEMS hard-coded value in both files, cites both file locations, classifies the maintainability issue as a 🟡 Suggestion rather than a 🔴 Critical Issue, and recommends extracting shared validation and a single source of truth for the limit. It must not invent unrelated defects.",
|
|
44
|
+
"assertions": [
|
|
45
|
+
"The report contains both src/orders/createOrder.ts and src/orders/updateOrder.ts as evidence locations",
|
|
46
|
+
"The report identifies the duplicated validation behavior rather than only matching function names",
|
|
47
|
+
"The report identifies the repeated MAX_ITEMS value as hard-coded configuration duplication",
|
|
48
|
+
"The duplication findings appear under 🟡 Suggestions and do not block delivery",
|
|
49
|
+
"The report recommends a shared validator and centralized constant or configuration",
|
|
50
|
+
"The report contains no unsupported security, performance, or correctness findings"
|
|
51
|
+
]
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"id": 5,
|
|
55
|
+
"prompt": "Review these two test files and check for meaningful cross-file duplication or hard-coded configuration. File: tests/orders.test.ts\n```typescript\nit('returns HTTP 200 for a valid order', async () => {\n expect(response.status).toBe(200);\n});\n```\nFile: tests/payments.test.ts\n```typescript\nit('returns HTTP 200 for a valid payment', async () => {\n expect(response.status).toBe(200);\n});\n```\nThese tests cover different endpoints and share only a normal HTTP status literal.",
|
|
56
|
+
"expected_output": "A concise English review report that performs or clearly scopes the cross-file check but reports no duplication finding. It must not treat a normal repeated test literal or separate endpoint fixture as meaningful hard-coded configuration, and it must not invent other issues.",
|
|
57
|
+
"assertions": [
|
|
58
|
+
"The report does not raise a duplicated-logic or hard-coded-configuration finding for the shared 200 test literal",
|
|
59
|
+
"The report does not claim the two endpoint tests implement the same business rule",
|
|
60
|
+
"The report explicitly states the cross-file scan scope or limitation",
|
|
61
|
+
"The report invents no unrelated findings"
|
|
62
|
+
]
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"id": 6,
|
|
66
|
+
"prompt": "Review only this Python snippet and check whether the same code or hard-coded values appear in other files:\n```python\ndef is_active(user):\n return user.status == 'active'\n```\nNo repository or additional files are available.",
|
|
67
|
+
"expected_output": "A concise English review report that states the supplied snippet was reviewed but cross-file verification was unavailable because no repository context or additional files were provided. It must not invent duplicate locations or line evidence.",
|
|
68
|
+
"assertions": [
|
|
69
|
+
"The report states that cross-file verification could not be performed",
|
|
70
|
+
"The report does not invent another file path, duplicate match, or line number",
|
|
71
|
+
"The report still uses the required review sections and severity headings"
|
|
72
|
+
]
|
|
39
73
|
}
|
|
40
74
|
]
|
|
41
75
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# Code Review Checklist
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Use this checklist as the baseline for `neo-code-review`. Compare each change against these criteria and report findings under `Critical Issues` (🔴 must fix), `Suggestions` (🟡 non-blocking), or `Strengths` (🟢).
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Report a finding only when the diff, surrounding code, tests, runtime behavior, or a stated requirement supports the risk. Do not turn every checklist item into a finding.
|
|
6
6
|
|
|
7
7
|
---
|
|
8
8
|
|
|
@@ -122,8 +122,18 @@ Only list SOLID/design findings when the violation clearly increases defect risk
|
|
|
122
122
|
- Is a function, method, component, or query too long or deeply nested to review safely?
|
|
123
123
|
- Is cyclomatic complexity high enough to hide bugs or make tests brittle?
|
|
124
124
|
- [ ] **Modularity & Duplication**:
|
|
125
|
-
- Does the code avoid meaningful duplication
|
|
125
|
+
- Does the code avoid meaningful duplication and copy-pasted implementations across changed and relevant repository files?
|
|
126
|
+
- Are business, validation, authorization, state-transition, error-handling, or request/query rules implemented in more than one place?
|
|
127
|
+
- Are apparently different implementations materially equivalent after comparing inputs, conditions, side effects, and failure behavior?
|
|
126
128
|
- Is shared behavior placed at the right abstraction level without over-engineering?
|
|
129
|
+
- [ ] **Hard-coded Values & Single Source of Truth**:
|
|
130
|
+
- Are non-trivial URLs, routes, timeouts, retry counts, thresholds, regexes, feature flags, error messages, or other configuration values repeated across production files?
|
|
131
|
+
- Should a repeated value be moved to a shared constant, configuration source, or domain-level policy to prevent drift?
|
|
132
|
+
- Are hard-coded credentials, tokens, private keys, or other secrets treated as security findings rather than ordinary maintainability suggestions?
|
|
133
|
+
- Do not report common one-time literals, test fixtures, snapshots, generated files, vendor code, or matches based only on a shared keyword.
|
|
134
|
+
- [ ] **Cross-file Evidence**:
|
|
135
|
+
- Does every duplication finding cite both file paths and line numbers with enough surrounding context to verify the match?
|
|
136
|
+
- If repository context is unavailable, does the review state that cross-file verification could not be performed instead of inventing evidence?
|
|
127
137
|
- [ ] **Testability**:
|
|
128
138
|
- Is the code easy to unit test or integration test?
|
|
129
139
|
- Are dependencies injectable or isolatable where tests need control over time, I/O, network calls, randomness, or external systems?
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: neo-rabbitmq
|
|
3
|
+
description: >
|
|
4
|
+
Use this skill when a request involves RabbitMQ message-topology design, reliability
|
|
5
|
+
analysis, Broker operations, cluster or security configuration, monitoring,
|
|
6
|
+
troubleshooting, or performance optimization. Use stable RabbitMQ 4.3 by default
|
|
7
|
+
and keep development guidance language-neutral. Do not use this skill for
|
|
8
|
+
language-specific Client APIs, website implementation, or Blog content.
|
|
9
|
+
compatibility: No runtime is required; verify current RabbitMQ official documentation for version-sensitive commands, configuration defaults, or security behavior.
|
|
10
|
+
metadata:
|
|
11
|
+
version: "1.0.0"
|
|
12
|
+
pattern: "tool-wrapper,pipeline"
|
|
13
|
+
domain: "messaging-operations-performance"
|
|
14
|
+
default-version: "4.3"
|
|
15
|
+
source-revision: "2b61ea8d840a42e1ba46ee2f1fdf0f9aeec63bd9"
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
# Neo RabbitMQ
|
|
19
|
+
|
|
20
|
+
Use RabbitMQ 4.3 as the default baseline for language-neutral guidance on message design, Broker operations, and performance optimization.
|
|
21
|
+
|
|
22
|
+
## Scope Boundaries
|
|
23
|
+
|
|
24
|
+
Cover:
|
|
25
|
+
|
|
26
|
+
- Development design: protocols, Virtual Hosts, Exchanges, Bindings, Queues, Publishers, Consumers, Acknowledgements, Publisher Confirms, Prefetch, TTL, Dead Lettering, reliability, and queue-type selection.
|
|
27
|
+
- Operations and management: installation, configuration, CLI tools, Management, permissions, TLS, Plugins, Policies, clusters, backups, upgrades, Kubernetes Operator, and production checks.
|
|
28
|
+
- Performance optimization: connection and Channel lifecycles, flow control, memory, disk, CPU, network, queues, Quorum Queues, Streams, monitoring, capacity, and bottleneck isolation.
|
|
29
|
+
- Troubleshooting: connectivity, authentication, routing, consumer backlog, resource alarms, cluster health, and upgrade risks.
|
|
30
|
+
|
|
31
|
+
Do not cover:
|
|
32
|
+
|
|
33
|
+
- Client APIs, SDK code, and language-specific tutorials for Java, Python, C#, Go, Ruby, or any other programming language.
|
|
34
|
+
- RabbitMQ website React, Docusaurus, styling, deployment, or other website implementation.
|
|
35
|
+
- RabbitMQ Blog, material outside the documented license scope, and documentation unrelated to the three focus areas.
|
|
36
|
+
- Production operations using rabbitmqadmin publish or rabbitmqadmin get; the source instructions explicitly omit these commands.
|
|
37
|
+
|
|
38
|
+
If a request crosses the boundary, answer the language-neutral portion and identify the missing language-specific or product-specific documentation. Never invent a Client API.
|
|
39
|
+
|
|
40
|
+
## Workflow
|
|
41
|
+
|
|
42
|
+
1. Classify the request as topology design, reliability, routine operations, security, performance, troubleshooting, upgrade, or capacity planning.
|
|
43
|
+
2. Identify the version. Use RabbitMQ 4.3 when no version is specified. For current-version behavior, development releases, release notes, Feature Flags, commands, or configuration defaults, consult current official documentation before answering.
|
|
44
|
+
3. Load only the required references:
|
|
45
|
+
- Development and message semantics: references/development.md
|
|
46
|
+
- Operations, management, and upgrades: references/operations.md
|
|
47
|
+
- Performance, capacity, and monitoring: references/performance.md
|
|
48
|
+
- Layered troubleshooting: references/troubleshooting.md
|
|
49
|
+
- Version, sources, and exclusions: references/sources-and-scope.md
|
|
50
|
+
4. Gather evidence before drawing conclusions. At minimum, identify the RabbitMQ version, protocol, Virtual Host, Exchange, Queue type, message size and rate, durability, confirmation mode, Consumer behavior, node count, CPU, RAM, disk, network, and relevant metrics. State when the available data is insufficient.
|
|
51
|
+
5. Separate source facts, recommendations, and inferences. Label inferences explicitly. Do not present a documentation example or single-environment value as a universal default.
|
|
52
|
+
6. Start with non-destructive checks before proposing changes. For configuration changes, deletion, clearing, restart, failover, or upgrade, state the impact, backup, rollback, and verification conditions.
|
|
53
|
+
7. Before using CLI examples, consult the corresponding help output when RabbitMQ tools are available locally. Mark every command with its applicable version and required permissions. Never invent parameters.
|
|
54
|
+
|
|
55
|
+
## Decision Rules
|
|
56
|
+
|
|
57
|
+
- Define delivery, ordering, retry, loss, and duplicate-processing semantics before discussing throughput or latency.
|
|
58
|
+
- Treat Publisher Confirms and Consumer Acknowledgements as separate reliability boundaries. Check message persistence together with Queue durability.
|
|
59
|
+
- Select a Queue type based on data safety, replication, ordering, retention, replay, consumption model, and resource characteristics. Never claim that one type is faster for every workload.
|
|
60
|
+
- Prefer long-lived Connections, Channel reuse, Publisher and Consumer separation, avoiding polling, and a controlled number of unconfirmed messages. Do not treat adding Consumers or increasing Prefetch as a universal solution.
|
|
61
|
+
- Treat Resource Alarms and Flow Control as protection mechanisms and bottleneck signals. Find the root cause in memory, disk, consumption rate, writes, replication, or network before changing alarm settings.
|
|
62
|
+
- Use Policies for settings that can be applied dynamically to groups of objects. Handle Queue or Stream types and other creation-time semantics during design and declaration because they cannot be changed afterward.
|
|
63
|
+
- Establish workload-specific monitoring baselines. Without evidence, do not assume fixed thresholds, capacity, ports, defaults, or security status.
|
|
64
|
+
- Prefer least privilege, Virtual Host isolation, TLS, restricted listeners, secret-free examples, and non-public management endpoints in security guidance.
|
|
65
|
+
|
|
66
|
+
## Response Contracts
|
|
67
|
+
|
|
68
|
+
### Topology or Development Design
|
|
69
|
+
|
|
70
|
+
State assumptions, protocol and topology, routing, Queue type, delivery semantics, failure and retry behavior, monitoring metrics, trade-offs, and verification cases. Use concepts, textual topology diagrams, configuration semantics, and protocol fields only. Do not produce Client code in a programming language.
|
|
71
|
+
|
|
72
|
+
### Operations or Management Runbook
|
|
73
|
+
|
|
74
|
+
Present impact, prerequisites, read-only checks, change steps, rollback steps, health verification, and follow-up monitoring in that order. For clusters, TLS, permissions, backups, and upgrades, state node scope and risks. Never present one unverified command as the complete procedure.
|
|
75
|
+
|
|
76
|
+
### Performance Analysis
|
|
77
|
+
|
|
78
|
+
Start with the baseline and success criteria. Locate the bottleneck across the end-to-end path: publishing, routing, storage, replication, transport, consumption, or application processing. Change one primary variable at a time and explain expected impact, resource cost, and rollback.
|
|
79
|
+
|
|
80
|
+
### Troubleshooting
|
|
81
|
+
|
|
82
|
+
Describe symptoms and missing evidence first. Check version and configuration, network and listeners, authentication, clusters, resource alarms, Queues, Publishers, and Consumers in that order. Tie every conclusion to observed evidence and list reproducible verification signals after remediation.
|
|
83
|
+
|
|
84
|
+
## Fact-Checking Gate
|
|
85
|
+
|
|
86
|
+
- Use sources-and-scope.md as the default RabbitMQ 4.3 source snapshot. The snapshot is not a substitute for current documentation.
|
|
87
|
+
- Treat versions, Feature Flags, Plugins, CLI syntax, configuration keys, defaults, ports, limits, compatibility, and security advisories as changeable information. Consult current official sources before answering.
|
|
88
|
+
- Do not use RabbitMQ Blog content or turn language examples from tutorials or Client Libraries into assumed universal APIs.
|
|
89
|
+
- For production data, message deletion, Queue clearing, permission changes, node shutdown, or upgrades, require sufficient environment evidence and provide rollback and verification steps.
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"query": "Using language-neutral RabbitMQ 4.3 concepts, design the Exchange, Binding, Queue, confirmation, and retry topology for order events.",
|
|
4
|
+
"should_trigger": true
|
|
5
|
+
},
|
|
6
|
+
{
|
|
7
|
+
"query": "Choose between a general Queue, Quorum Queue, and Stream in RabbitMQ. Analyze the trade-offs for data safety, ordering, replay, and resource use.",
|
|
8
|
+
"should_trigger": true
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
"query": "Explain Publisher Confirms and Consumer Acknowledgements, then design a workflow that handles duplicate delivery.",
|
|
12
|
+
"should_trigger": true
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"query": "RabbitMQ publishing is occasionally blocked. Plan read-only troubleshooting steps using Memory Alarms, Disk Alarms, Flow Control, and Consumer rate.",
|
|
16
|
+
"should_trigger": true
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
"query": "Plan TLS, Virtual Host, least privilege, Management, and CLI administration for a RabbitMQ 4.3 cluster.",
|
|
20
|
+
"should_trigger": true
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
"query": "A RabbitMQ Queue keeps growing. Use Consumer Capacity, Prefetch, Ack Rate, Redelivery, and disk metrics to locate the bottleneck.",
|
|
24
|
+
"should_trigger": true
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
"query": "Design Prometheus monitoring and a RabbitMQ capacity baseline, including the cost of Per-object metrics.",
|
|
28
|
+
"should_trigger": true
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"query": "We are preparing a node-by-node RabbitMQ upgrade. List checks for the Upgrade Path, Erlang, Feature Flags, backups, cluster health, and rollback.",
|
|
32
|
+
"should_trigger": true
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"query": "RabbitMQ Connection and Channel counts keep increasing. Investigate Churn, File Descriptors, memory, and the application lifecycle.",
|
|
36
|
+
"should_trigger": true
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"query": "Plan Kubernetes storage, TLS, monitoring, upgrades, and failure troubleshooting from the RabbitMQ Operator perspective.",
|
|
40
|
+
"should_trigger": true
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"query": "Write Python code with pika to create a RabbitMQ Exchange, Queue, and Consumer.",
|
|
44
|
+
"should_trigger": false
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
"query": "Give me a Java RabbitMQ Client Publisher Confirm API example.",
|
|
48
|
+
"should_trigger": false
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"query": "Implement automatic RabbitMQ reconnect and Prefetch configuration in C#.",
|
|
52
|
+
"should_trigger": false
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
"query": "Write a RabbitMQ Stream Producer using the Go Client.",
|
|
56
|
+
"should_trigger": false
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"query": "Show me how to modify React components and the Docusaurus Sidebar in the RabbitMQ website.",
|
|
60
|
+
"should_trigger": false
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"query": "Summarize the latest RabbitMQ Blog post and republish it in full.",
|
|
64
|
+
"should_trigger": false
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
"query": "Compare Kafka Broker partition performance without discussing RabbitMQ.",
|
|
68
|
+
"should_trigger": false
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
"query": "Optimize PostgreSQL indexes and execution plans.",
|
|
72
|
+
"should_trigger": false
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"query": "Build a general HTTP API retry service without a message Broker.",
|
|
76
|
+
"should_trigger": false
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
"query": "Install npm packages and fix dependency conflicts in a Node.js project.",
|
|
80
|
+
"should_trigger": false
|
|
81
|
+
}
|
|
82
|
+
]
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
{
|
|
2
|
+
"skill_name": "neo-rabbitmq",
|
|
3
|
+
"evals": [
|
|
4
|
+
{
|
|
5
|
+
"id": 1,
|
|
6
|
+
"prompt": "Using language-neutral RabbitMQ 4.3 concepts, design the Exchange, Binding, Queue, confirmation, and retry topology for order events.",
|
|
7
|
+
"expected_output": "State assumptions first, then describe the protocol, Virtual Host, Exchange, Binding, Queue type, Publisher Confirm, Consumer Ack, retry, and Dead Letter paths. Do not include Client code in any programming language.",
|
|
8
|
+
"assertions": [
|
|
9
|
+
"It clearly uses RabbitMQ 4.3 as the baseline before current-version verification",
|
|
10
|
+
"It distinguishes routing success, Publisher Confirm, and Consumer Ack semantics",
|
|
11
|
+
"It lists verification methods for duplicate delivery, retry limits, and Dead Lettering",
|
|
12
|
+
"It uses only topology and protocol semantics and contains no Java, Python, C#, or other language API code"
|
|
13
|
+
]
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"id": 2,
|
|
17
|
+
"prompt": "Choose between a general Queue, Quorum Queue, and Stream. Analyze the trade-offs for data safety, ordering, replay, and resource use.",
|
|
18
|
+
"expected_output": "Use a requirements matrix to compare the three data structures. Distinguish replication, ordering, Retention, Offset, replay, Consumer model, and resource cost, and require workload-based performance validation.",
|
|
19
|
+
"assertions": [
|
|
20
|
+
"It does not claim that one Queue type is fastest for every workload",
|
|
21
|
+
"It identifies Quorum Queue replication and resource trade-offs",
|
|
22
|
+
"It identifies Stream Offset, Retention, or replay semantics",
|
|
23
|
+
"It provides capacity and failure verification conditions after selection"
|
|
24
|
+
]
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
"id": 3,
|
|
28
|
+
"prompt": "RabbitMQ publishing is occasionally blocked. Plan a safe troubleshooting workflow.",
|
|
29
|
+
"expected_output": "Request the version, nodes, time range, and metrics first. Then isolate Memory Alarms, Disk Alarms, Flow Control, Queue backlog, Consumer rate, disk, and network with read-only checks before proposing changes with rollback steps.",
|
|
30
|
+
"assertions": [
|
|
31
|
+
"It treats alarms as protection mechanisms and bottleneck signals instead of immediately raising thresholds",
|
|
32
|
+
"It lists read-only checks before changes and rollback",
|
|
33
|
+
"It mentions that cluster alarms can affect multiple nodes",
|
|
34
|
+
"It explicitly states that the root cause cannot be determined without environment evidence"
|
|
35
|
+
]
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
"id": 4,
|
|
39
|
+
"prompt": "Plan TLS, Virtual Host, least privilege, Management, and CLI administration for a RabbitMQ 4.3 cluster.",
|
|
40
|
+
"expected_output": "Separate network and certificates, Authentication, Authorization, Virtual Host, Management, CLI, monitoring accounts, and verification steps. Keep secrets out of examples.",
|
|
41
|
+
"assertions": [
|
|
42
|
+
"It distinguishes Authentication from Authorization",
|
|
43
|
+
"It uses Virtual Hosts for isolation and permission scope",
|
|
44
|
+
"It checks TLS Peer Verification, Listeners, or certificate rotation",
|
|
45
|
+
"It contains no passwords, Tokens, Cookies, private keys, or personal information"
|
|
46
|
+
]
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
"id": 5,
|
|
50
|
+
"prompt": "Design Prometheus monitoring and a RabbitMQ performance baseline.",
|
|
51
|
+
"expected_output": "Cover Cluster, Node, Queue, Connection, Channel, Publisher, Consumer, Stream, Alarm, and host metrics. Explain aggregated versus Per-object metrics, scrape frequency, and monitoring cost.",
|
|
52
|
+
"assertions": [
|
|
53
|
+
"It first defines SLO, message size, rate, processing time, and topology baselines",
|
|
54
|
+
"It includes actionable metrics such as Consumer Capacity, Queue Depth, Ack latency, or Confirm latency",
|
|
55
|
+
"It warns about high cardinality and output cost from Per-object or Detailed metrics",
|
|
56
|
+
"It does not invent universal monitoring thresholds without source evidence"
|
|
57
|
+
]
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"id": 6,
|
|
61
|
+
"prompt": "We are preparing a node-by-node RabbitMQ upgrade. List the checks before, during, and after the upgrade.",
|
|
62
|
+
"expected_output": "Order checks around Upgrade Path, Erlang version, Release Notes, Feature Flags, Plugins, backups, cluster health, capacity, per-node verification, and rollback.",
|
|
63
|
+
"assertions": [
|
|
64
|
+
"It requires confirmation of the upgrade path from the source to target version",
|
|
65
|
+
"It includes Erlang, stable Feature Flag, Plugin, and cluster-capacity checks",
|
|
66
|
+
"Each node has stop, upgrade, start, and health-verification steps",
|
|
67
|
+
"It explains when a Rolling Upgrade is not applicable"
|
|
68
|
+
]
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
"id": 7,
|
|
72
|
+
"prompt": "A RabbitMQ Queue keeps growing. Find the possible performance bottlenecks.",
|
|
73
|
+
"expected_output": "Treat Queue backlog as a symptom. Isolate Publish, Routing, Storage, Network, Consumer, Prefetch, Ack, Redelivery, Alarm, and resource evidence. Label adding Consumers as a hypothesis to validate.",
|
|
74
|
+
"assertions": [
|
|
75
|
+
"It compares Publish Rate, Deliver Rate, Ack Rate, and Consumer Capacity",
|
|
76
|
+
"It checks unacknowledged messages, Prefetch, redelivery, and retry loops",
|
|
77
|
+
"It does not present adding Consumers as a universal solution",
|
|
78
|
+
"It lists Queue, Alarm, latency, and resource signals for post-fix verification"
|
|
79
|
+
]
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
"id": 8,
|
|
83
|
+
"prompt": "Analyze why RabbitMQ Connection and Channel counts keep increasing.",
|
|
84
|
+
"expected_output": "Check lifecycle, creation and closure rates, File Descriptors, memory, reconnect spikes, Client distribution, and Connection or Channel Churn. Then propose reuse and capacity measures.",
|
|
85
|
+
"assertions": [
|
|
86
|
+
"It distinguishes Connection Churn from Channel Churn",
|
|
87
|
+
"It includes File Descriptor and memory evidence",
|
|
88
|
+
"It recommends long-lived resources and reasonable Publisher and Consumer separation",
|
|
89
|
+
"It does not produce connection-management code for a specific programming language"
|
|
90
|
+
]
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
"id": 9,
|
|
94
|
+
"prompt": "Plan Kubernetes RabbitMQ operations from the Operator perspective.",
|
|
95
|
+
"expected_output": "Request Operator, RabbitMQ, Kubernetes, and CRD versions first. Then check storage, TLS, monitoring, Pod Disruption, upgrades, Operator logs, and RabbitMQ Broker health separately.",
|
|
96
|
+
"assertions": [
|
|
97
|
+
"It does not treat non-versioned Operator documentation as RabbitMQ 4.3 Broker documentation",
|
|
98
|
+
"It requires version and CRD compatibility checks",
|
|
99
|
+
"It covers storage, TLS, monitoring, upgrades, and troubleshooting",
|
|
100
|
+
"It does not provide unverified deletion, rebuild, or downtime commands"
|
|
101
|
+
]
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
"id": 10,
|
|
105
|
+
"prompt": "Give me Python pika code for RabbitMQ automatic reconnect and Prefetch.",
|
|
106
|
+
"expected_output": "The request is outside the skill's language-specific Client API scope. Refuse to produce Python code, but provide language-neutral reconnect, Ack, Prefetch, duplicate-delivery, and verification semantics when useful, and point to the official Client Library documentation.",
|
|
107
|
+
"assertions": [
|
|
108
|
+
"It does not produce Python code or invent an API",
|
|
109
|
+
"It still explains language-neutral reliability and performance considerations",
|
|
110
|
+
"It clearly states the skill boundary and the need to consult official Client documentation"
|
|
111
|
+
]
|
|
112
|
+
}
|
|
113
|
+
]
|
|
114
|
+
}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
# RabbitMQ Development Design
|
|
2
|
+
|
|
3
|
+
Use this reference for protocol and message-design decisions based on RabbitMQ 4.3. The primary sources are amqp.md, protocols.md, exchanges.md, queues.md, consumers.md, publishers/index.md, confirms.md, reliability.md, ttl.md, quorum-queues/index.md, and streams.md.
|
|
4
|
+
|
|
5
|
+
## Design Order
|
|
6
|
+
|
|
7
|
+
Define business semantics before designing objects and settings:
|
|
8
|
+
|
|
9
|
+
1. Define whether messages may be lost, whether duplicates are allowed, ordering requirements, retry limits, expiration policy, and the destination for failed processing.
|
|
10
|
+
2. Select the protocol and Virtual Host, then confirm authentication, authorization, isolation, and network boundaries.
|
|
11
|
+
3. Design Exchanges, Bindings, Routing Keys, and handling for unroutable messages.
|
|
12
|
+
4. Choose a Queue, Quorum Queue, or Stream, then confirm durability, replication, retention, replay, and resource characteristics.
|
|
13
|
+
5. Design Publisher Confirms, Consumer Acknowledgements, Prefetch, retry, and cancellation behavior.
|
|
14
|
+
6. Define monitoring, alerts, failure recovery, and verification cases.
|
|
15
|
+
|
|
16
|
+
## Exchanges and Routing
|
|
17
|
+
|
|
18
|
+
- Publishers send messages to an Exchange. The Exchange routes them to Queues according to Bindings and Routing Keys.
|
|
19
|
+
- direct is suitable for exact-key routing, fanout broadcasts to bound Queues, and topic routes by pattern. Select the type based on message topology and maintenance cost.
|
|
20
|
+
- When unroutable messages matter, explicitly choose Publisher-side reporting, an Alternate Exchange, or another observable failure path. Do not interpret a Confirm as proof that a Consumer will process the message.
|
|
21
|
+
- Exchanges, Bindings, and Queues are scoped to a Virtual Host. For cross-team or multi-tenant environments, confirm naming, permissions, and isolation boundaries first.
|
|
22
|
+
- When using Exchange-to-Exchange Bindings or an Alternate Exchange, include the additional routing layer and loop risks in verification.
|
|
23
|
+
|
|
24
|
+
## Queue Declaration and Lifecycle
|
|
25
|
+
|
|
26
|
+
- A Queue's name, Durable, Exclusive, Auto-delete, and Arguments together determine lifecycle and resource semantics.
|
|
27
|
+
- Redeclaring an existing Queue with inconsistent properties causes a channel-level PRECONDITION_FAILED. Treat the declaration contract as a versioned interface in deployment tools and applications.
|
|
28
|
+
- Queue types, some Arguments, and other creation-time settings cannot be changed arbitrarily after creation. Prefer Policies for group settings that Policies can manage instead of scattering them across application declarations.
|
|
29
|
+
- RabbitMQ 4.3 has disabled the default declaration of non-Durable, non-Exclusive Classic Queues. For short-lived data, evaluate a Durable Queue with Queue TTL, an Exclusive Queue, or another suitable data structure rather than relying on deprecated behavior.
|
|
30
|
+
- An Exclusive Queue is tied to the Connection that declared it and is suitable for temporary state owned by one Client. It is commonly paired with a Broker-generated name to avoid fixed-name races during reconnects.
|
|
31
|
+
- A Durable Queue does not mean that every message survives a restart. Check message persistence at publish time together with Queue durability.
|
|
32
|
+
|
|
33
|
+
## Reliability Boundaries
|
|
34
|
+
|
|
35
|
+
- A Publisher Confirm reports whether the Broker accepted and processed a publish. A Consumer Acknowledgement reports whether the Consumer completed delivery processing. They address failures in different directions.
|
|
36
|
+
- When Broker-side data safety matters, use an appropriate Durable Queue, persistent messages, Publisher Confirms, and a recovery workflow. Explicitly handle Confirm latency, negative responses, and Connection loss.
|
|
37
|
+
- A Consumer should not acknowledge before processing is complete. A disconnect, Channel closure, or Negative Acknowledgement can requeue unacknowledged messages, so processing must tolerate duplicate delivery.
|
|
38
|
+
- Requeue is not an infinite retry strategy. Set observable retry limits, delayed retry, or a Dead Letter path for persistent failures to avoid a Requeue Loop.
|
|
39
|
+
- Confirm, Ack, routing success, persistence success, and business processing success are different events. Represent them separately in state machines and audit records.
|
|
40
|
+
|
|
41
|
+
## Queue, Quorum Queue, and Stream
|
|
42
|
+
|
|
43
|
+
- A general Queue uses Queue, Consumer, Ack, Prefetch, and TTL semantics. Confirm whether replication and cross-node fault tolerance are required.
|
|
44
|
+
- A Quorum Queue provides replication, data safety, and consistency. It requires Durable and introduces membership management, Leader election, Delivery Limit, resource use, and performance trade-offs. Select it only when those semantics are required.
|
|
45
|
+
- A Stream is an immutable append-only log with Offset, Retention, replay, and a different consumption model. It is not a renamed general Queue and has different connection and replication requirements.
|
|
46
|
+
- For global ordering, check whether a Stream fits. If using Queues, evaluate Single Active Consumer, a single Consumer, or partitioning, including the effect of requeue on ordering.
|
|
47
|
+
- Do not conclude that Quorum Queues are always safer or Streams are always faster without workload evidence. Test message size, rate, replication factor, disk, Consumer behavior, and target SLO.
|
|
48
|
+
|
|
49
|
+
## Publisher and Consumer Behavior
|
|
50
|
+
|
|
51
|
+
- Messaging protocols generally expect long-lived Connections. Do not create and close a Connection for every publish or consume operation; evaluate Connection pooling when necessary.
|
|
52
|
+
- Connections and Channels consume Client and Broker resources. Reuse long-lived resources, close objects that are truly no longer needed, and monitor Connection or Channel Churn.
|
|
53
|
+
- If Publishers and Consumers share a Connection, Publisher Flow Control can affect Consumer manual acknowledgements. Separate the two Connection types when the requirements allow it.
|
|
54
|
+
- Prefetch controls the number of deliveries that have not completed. It affects throughput, latency, ordering, memory, and redelivery cost; adjust it only after measuring processing time, message size, Consumer count, and Ack behavior.
|
|
55
|
+
- Observe Consumer Capacity, unacknowledged message count, Queue Depth, Publish Rate, Deliver Rate, Ack Rate, and Confirm Latency together. Do not rely on Queue length alone.
|
|
56
|
+
- Polling Consumers add requests and latency without keeping delivery continuous. Unless single-message pulls are explicitly required, prefer continuous consumption.
|
|
57
|
+
|
|
58
|
+
## Language-Neutral Output
|
|
59
|
+
|
|
60
|
+
For development questions, use topology, protocol fields, configuration semantics, failure states, and verification cases. Do not produce Java, Python, C#, Go, Ruby, or other language-specific Client calls. If the user needs an implementation in a language, direct them to the corresponding official Client Library documentation.
|
|
61
|
+
|
|
62
|
+
### Sources
|
|
63
|
+
|
|
64
|
+
- [Exchanges](https://www.rabbitmq.com/docs/4.3/exchanges)
|
|
65
|
+
- [Queues](https://www.rabbitmq.com/docs/4.3/queues)
|
|
66
|
+
- [Consumers](https://www.rabbitmq.com/docs/4.3/consumers)
|
|
67
|
+
- [Publishers](https://www.rabbitmq.com/docs/4.3/publishers)
|
|
68
|
+
- [Consumer Acknowledgements and Publisher Confirms](https://www.rabbitmq.com/docs/4.3/confirms)
|
|
69
|
+
- [Reliability Guide](https://www.rabbitmq.com/docs/4.3/reliability)
|
|
70
|
+
- [Quorum Queues](https://www.rabbitmq.com/docs/4.3/quorum-queues)
|
|
71
|
+
- [Streams and Super Streams](https://www.rabbitmq.com/docs/4.3/streams)
|