dsl-conventions

dsl-conventions is a cursor rule for Cursor from cty12356541/galide. It costs 0 tokens per session (435 once invoked), scanned A, original, MIT.

A set of text rules for describing visual-novel scenes, including backgrounds, music, character art, positions, and dialogue.

In plain words
What is it for?
It is for writing scene data such as which background and music to use, where characters appear, and what they say.
Why use it?
It gives scene descriptions a consistent format, so the same kinds of details are written in the same way.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit It is for writing scene data such as which background and music to use, where characters appear, and what they say.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/cty12356541/galide/dsl-conventions
Install

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.

Clone the repo
git clone --depth 1 https://github.com/cty12356541/galide

Made for: Cursor.

Wrote 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.

agentmods badge for dsl-conventions

README.md
[![agentmods](https://agentmods.dev/badge/rules/cty12356541/galide/dsl-conventions/github.svg)](https://agentmods.dev/rules/cty12356541/galide/dsl-conventions)
Your own site
<a href="https://agentmods.dev/rules/cty12356541/galide/dsl-conventions"><img src="https://agentmods.dev/badge/rules/cty12356541/galide/dsl-conventions/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for dsl-conventions

Your own site · 80×15
<a href="https://agentmods.dev/rules/cty12356541/galide/dsl-conventions"><img src="https://agentmods.dev/badge/rules/cty12356541/galide/dsl-conventions.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 435 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.00435
Opus 5.5 $0.00000 $0.00174
Sonnet 5.5 $0.00000 $0.00087
Haiku 4.5 $0.00000 $0.00044

Measured 2mo ago against content hash 5d9ee3cd2d82, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

dsl-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 2mo 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.

.cursor/rules/dsl-conventions.mdc · 47 lines

What it actually says

gal DSL 语言规范

设计约束

  • 纯文本行级语义:每行要么是元数据、要么是对白、要么是控制流
  • 禁止多行块语法:JSON/YAML 的多行字符串会破坏 git diff 线性
  • 显式符号标记层级:不需要缩进来表达嵌套
  • 资产引用必须使用相对于项目根的相对路径

行类型速查

# 章节标题
## 场景元数据
背景: assets/backgrounds/xxx.png
BGM: assets/bgm/xxx.mp3
[角色:名字 | 立绘:asset.png | 位置:左]
角色名: "对白内容"
* "选项文本" -> 目标节点
=== 节点名 ===
[跳转:目标节点]
// 注释

AST 节点类型

解析器必须输出以下 AST 节点类型:

  • ScriptNode: { type: 'script', children: Node[] }
  • SceneNode: { type: 'scene', id, background?, bgm?, children }
  • DialogueNode: { type: 'dialogue', character, sprite?, position?, lines }
  • ChoiceNode: { type: 'choice', options: { text, target }[] }
  • GotoNode: { type: 'goto', target }

解析器约定

  • 词法分析器输出 Token[],包含 type + value + line + column
  • 解析失败返回结构化 ParseError(含 line/column),不抛异常
  • 必须包含 errors: ParseError[] 字段
Changes

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.

  1. 2mo ago First seen · 47 lines · 435 tokens per session scan A 5d9ee3cd2d82

Subscribe to this mod's changes

dsl-conventions is a cursor rule published in the GitHub repository cty12356541/galide (2 stars, last pushed 5d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 435 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.