prediction-market-risk-review
Review prediction-market, basket, oracle, and trading-agent workflows for compliance, safety, data-quality, privacy, and execution risk. Use before any workflow handles venue auth, user portfolio data, API keys, or trade planning.
- License 许可
- Apache-2.0
- 最近更新
- 2026-11-08
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- be-recall
- description
- Recall development rules and check for violations.
- allowed-tools
- Read, Glob, Grep, Bash
- argument-hint
- [commit | tdd | build | coding | api | data]
- user-invocable
- true
03 SKILL.md 正文
Recall Rules
Display development rules from the plugin CLAUDE.md and scan recent work for concrete violations of them. Every check below names an exact scope (a git range, a directory, a file glob) — report results against that scope only, never as a claim about the whole codebase.
Instructions
Step 0: Validate Configuration
- Read
.claude/backend-webflux-plugin.json. - If missing: show general rules from the plugin CLAUDE.md only, and skip
Step 3 entirely. Report: "not verified: no
.claude/backend-webflux-plugin.jsonfound, so project-specific checks (webLayer, dataProfile) cannot be scoped correctly. Showing rules only." Guessing a profile instead of declaring it missing would risk scanning the wrong file shapes (see theapi/databranching below). pluginRoot: the one line of${CLAUDE_CONFIG_DIR:-$HOME/.claude}/plugins/data/backend-webflux-plugin/pluginRoot(plugin CLAUDE.md § Configuration) — everytemplates/…path in this document is{pluginRoot}/templates/…, the plugin's own directory, not the project's; the plugin CLAUDE.md is{pluginRoot}/CLAUDE.md; missing → stop: start a new session so the hook writes it.- If present, read and hold onto two values — Step 3 branches on them so the
scan targets match what this project actually contains:
webLayer(default"functional"if absent)dataProfile(default"both"if absent)
Step 1: Parse Argument
Map argument to section:
| Argument | Section | Source |
|---|---|---|
| (none) | All rules summary | CLAUDE.md (all sections) |
commit |
Commit Standards | CLAUDE.md § Commit Standards |
tdd |
TDD Process + Test Scenario Writing | CLAUDE.md § Test-Driven Development + templates/test-scenario-template.md |
build |
Build Standards | CLAUDE.md § Build Standards |
coding |
Coding Standards + Entity/DTO Conventions | CLAUDE.md § Coding Standards |
api |
API Conventions + Naming | CLAUDE.md § API Conventions + Naming Conventions |
data |
Entity/Repository/Mapper Conventions | templates/entity-conventions.md (shared) + templates/entity-conventions-r2dbc.md / -mybatis.md (profile-specific) |
Step 2: Display Rules
Read the relevant section(s) from the plugin CLAUDE.md and display them clearly in the working language.
For each rule, show:
- The rule statement
- Why it exists (one line — this is what lets the reader apply the rule to a case the examples below don't cover)
- A brief example (if applicable)
Step 3: Check for Violations
Before scanning, state the scope you're about to scan (the exact command or directory). If a scan cannot run at all (not a git repo, directory missing, fewer commits than the range needs), report "not verified: <reason>" for that check instead of skipping it silently or reporting zero violations — zero violations and "couldn't scan" look identical to the user unless you say which one happened.
commit violations:
- Scope:
git log --oneline -5. - If the command fails (not a git repo, no commits yet): "not verified: no git history available."
- For each message, check: wrong tense, prefix usage (
fix:,feat:, etc.), exceeds 50 characters, lowercase start, missing blank line before body, body lines exceeding 72 characters.
tdd violations:
- Scope: all test files under
{testDir}. - If
{testDir}doesn't exist: "not verified: {testDir} not found." - For each test file, check:
- Test methods not using
snake_case(method name doesn't match the convention shown in Coding Standards, e.g.duplicate_email_returns_409_Conflict) - Missing assertions: a
@Test/@ParameterizedTestmethod whose body contains none ofStepVerifier,assertThat,Assertions., or a.verify*()call - Test scenario format issues: a scenario list in a work document that
doesn't follow
templates/test-scenario-template.md— one lowercase, present-tense sentence per scenario, usable as a snake_case test name (there is no Given/When/Then shape in this plugin)
- Test methods not using
build violations:
- Scope:
build/directory presence/freshness andbuild.gradle(.kts)plugin configuration. - If
build/doesn't exist: "not verified: no build output found — run be-build or the configured build command, then re-runbe-recall build." This is not itself a violation; it means the check couldn't run. - If
build/exists, check:build/older than the newest file under{sourceDir}(stale build — suggests the last build predates the current code)build.gradle(.kts)missing the JaCoco plugin block whencoverage: truein configbuild.gradle(.kts)missing the Checkstyle plugin block whencheckstyle: truein config
coding violations:
- Scope: Java files from
git diff --name-only HEAD~3. - If the repo has fewer than 3 commits: "not verified: fewer than 3 commits
available; falling back to
git diff --name-only HEAD(uncommitted changes only)." Use that fallback scope rather than reporting nothing. - For each file, check:
- Missing final newline
- Class where
recordshould be used (DTOs — Command/Query/View) - Non-standard naming (check against the Naming Conventions table)
api violations:
Branch on the webLayer value read in Step 0 — a check written for one web
layer style finds nothing when run against the other, which reads as "no
violations" even when the code is riddled with them. Run exactly one branch.
- If
webLayer == "functional"(the plugin default — see CLAUDE.md § Web Layer): scan*Router.java/*Handler.javaunder each domain'sapi/directory for:- Non-kebab-case path strings in
RequestPredicates.path(...)/ route builder calls - Singular resource names in route paths (plural expected:
/employees, not/employee) ServerResponse.status(...)codes that don't match the API Conventions table (e.g. a POST handler returning200instead of201)- Missing handler-level
onErrorResumemapping for a domain exception
- Non-kebab-case path strings in
- If
webLayer == "annotated"(the named exception — a domain deliberately mirroring an existing annotated-controller module): scan*Controller.javafiles for:- Wrong
@GetMapping/@PostMapping/etc. for the action performed - Non-kebab-case
@RequestMappingpaths - Missing
@ResponseStatus - Singular resource names in URLs
- Wrong
- Do not run the
@ResponseStatus/*Controller.javachecks whenwebLayer == "functional"— functional endpoints have no controller classes at all, so that scan is a guaranteed false "no violations."
data violations:
Branch on the dataProfile value read in Step 0 — same reasoning as api:
a profile-specific check run against the wrong profile finds nothing to
scan and silently reports a clean result.
- If
dataProfileis"r2dbc"or"both": scan R2DBC entity classes underdata/for:- Missing
sequence+iddual key pattern - Missing
@Tableannotation, non-snake_case table names - Missing explicit
@Columnmapping
- Missing
- If
dataProfileis"mybatis"or"both": scan call sites of*Mappermethods for:- A mapper method invoked directly inside a
Mono/Fluxchain without.subscribeOn(Schedulers.boundedElastic())or an enclosingMono.fromCallable(...)
- A mapper method invoked directly inside a
- If
dataProfile == "r2dbc", skip the MyBatis mapper check — there are no mappers in this project. IfdataProfile == "mybatis", skip the R2DBC entity check — there are no R2DBC entities. Only"both"runs both branches.
Step 4: Report
Lead with evidence, not the verdict: state what was scanned (the exact command/directory from Step 3, or the "not verified: <reason>" line) before stating whether violations were found.
Display each violation found with:
- File path and line number
- Rule violated
- Suggested fix
If a check could not run, report it as its own line rather than omitting the section or folding it into "no violations":
"not verified: {reason}"
If no violations found within the scanned scope:
"No violations detected in {the stated scope, e.g. 'the last 5 commits'}."
Never report the unscoped "All rules are being followed" — Step 3's checks only cover the named scope (5 commits, 3 commits of diff, one directory), not the project's full history or every file, so a blanket compliance claim overstates what was actually scanned.
If violations can be auto-fixed (e.g., missing final newline):
"Auto-fixable violations found. Apply fixes? (y/n)"
Apply fixes only with user confirmation.
Examples
Example 1 — clean run, scope stated
Input: /backend-webflux-plugin:be-recall commit
- Step 0 reads config (found;
webLayer/dataProfileunused for this arg). - Step 2 displays the Commit Standards section.
- Step 3 runs
git log --oneline -5, gets 5 messages, checks each against the commit rules. - Step 4 reports:
Scanned: last 5 commits (
git log --oneline -5). No violations detected in the last 5 commits.
Example 2 — webLayer branching catches a real violation
Input: /backend-webflux-plugin:be-recall api, config has
"webLayer": "functional".
- Step 0 reads config:
webLayer: "functional". - Step 3 (
apibranch) scans*Router.java/*Handler.javaunderemployee/api/— not*Controller.java, which would be the wrong style for this project and would always report zero violations regardless of the actual code. - Finds
EmployeeHandler.java:42returningServerResponse.status(200)from thecreateEmployeehandler. - Step 4 reports:
Scanned:
EmployeeRouter.java,EmployeeHandler.javaunderemployee/api/. 1 violation found:EmployeeHandler.java:42— POST handler returns200 OK; API Conventions require201 Createdfor create. Fix:ServerResponse.status(HttpStatus.CREATED).
Example 3 — scan can't run, declared instead of skipped
Input: /backend-webflux-plugin:be-recall build, no build/ directory
exists yet.
Step 4 reports:
not verified: no
build/directory found — runbe-buildor the configured build command first, then re-runbe-recall build.
04 同仓库更多 Skills
remotion-video-creation
Best practices for Remotion - Video creation in React. 29 domain-specific rules covering 3D, animations, audio, captions, charts, transitions, and more.
hotcook-recipes
暂无简介
code-helper
Code review and assistance skill
research-assistant
Web research assistant skill using Brave Search MCP
x-api
X/Twitter API integration for posting tweets, threads, reading timelines, search, and analytics. Covers OAuth auth patterns, rate limits, and platform-native content posting. Use when the user wants to interact with X programmatically.
workspace-surface-audit
Audit the active repo, MCP servers, plugins, connectors, env surfaces, and harness setup, then recommend the highest-value ECC-native skills, hooks, agents, and operator workflows. Use when the user wants help setting up Claude Code or understanding what capabilities are actually available in their environment.