Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add rules/siborne/yismart-cloud/backend-java-ruoyi-conventionsgit clone --depth 1 https://github.com/Siborne/YiSmart-CloudWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/rules/siborne/yismart-cloud/backend-java-ruoyi-conventions)<a href="https://agentmods.dev/rules/siborne/yismart-cloud/backend-java-ruoyi-conventions"><img src="https://agentmods.dev/badge/rules/siborne/yismart-cloud/backend-java-ruoyi-conventions.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.00538 |
| Opus 5 | $0.00000 | $0.00269 |
| Sonnet 5 | $0.00000 | $0.00108 |
| Haiku 4.5 | $0.00000 | $0.00054 |
Grade A, and why
backend-java-ruoyi-conventions scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
What it actually says
后端 Java(RuoYi)开发约定(YiSmartCloud)
- 模块落点:颐养/护理业务代码(
serve包下的 controller、service、domain、vo、mapper 与resources/mapper/serve)默认放在YiSmartCloud-nursing-platform;启动入口在YiSmartCloud-admin。非系统级需求不要把业务 Controller 塞进YiSmartCloud-system或YiSmartCloud-admin的web.controller。 - 根包名固定为
org.FlyingSparrow.YiSmartCloud,与现有模块一致。 - 严格遵守分层:
controller -> service -> mapper,控制层不直接操作 mapper。 - Controller 保持 RuoYi 注解组合:
@RestController、@RequestMapping、@PreAuthorize、@Log、@Api/@ApiOperation。 - CRUD 接口保持既有模式:列表
startPage()+getDataTable,新增/修改/删除返回toAjax(...),详情返回success(...)。 - MyBatis-Plus 与 Service:业务模块普遍使用
IService/ServiceImpl<Mapper, Entity>搭配BaseMapper;简单单表 CRUD 可用 MP 能力,JOIN、树形、统计、扩展列须在 Mapper 中声明方法并由 XML 实现(见 mapper 规则),避免与通用select*字段冲突。 - Service 层承担业务校验与默认值填充,参数非法时抛
ServiceException,不要把校验散落到 Controller。 - 事务写操作使用
@Transactional(rollbackFor = Exception.class),时间字段使用DateUtils.getNowDate()保持一致。 - 日期类型:
BaseEntity审计字段与部分代码使用java.util.Date,业务实体字段也可能使用java.time.LocalDateTime。新增字段优先与同模块、同聚合内已有实体保持一致;跨层 JSON 注意序列化配置,避免混用导致反序列化失败。 - 涉及 XML 自定义 SQL(尤其 JOIN 扩展字段)时,优先调用 Mapper 自定义方法,避免误用 MP 通用方法导致字段冲突。
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 4d ago First seen · 18 lines · 0 tokens per session scan A c59142bba279
backend-java-ruoyi-conventions is a cursor rule published in the GitHub repository Siborne/YiSmart-Cloud (4 stars, last pushed 3mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 538 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other cursor rules, from other repositories
api
Public API surface, binary compatibility, and common classes to modify.
java-import-fqn
Java 禁止不必要的全限定类名,必须 import(类名冲突除外).
java-springboot-jpa-cursorrules-prompt-file
description: "Cursor rules for Java development with Springboot and JPA integration." globs: / alwaysApply: false.
java-springboot-standards
Java Spring Boot coding standards and patterns for your monorepo services.
ecoconception-java
Règles d'écoconception pour le code Java, JPA/Hibernate sobre, mémoire, batch, logs.
contraponto-format-imports
Java formatting (formatter.xml) and import hygiene — required on every Java edit.