lumina: Skill for Claude Code

.agents/skills/lumina_flyway/SKILL.md

lumina_flyway is a skill for Claude Code, Codex from zwl467135974/lumina. It costs 0 tokens per session (1,089 once invoked), scanned A, original, Apache-2.0.

A set of rules for creating Flyway database migrations in the Lumina project. Flyway is a tool that applies numbered SQL files to change a database in order over time.

In plain words
What is it for?
Checking real table structures, reviewing earlier migrations, choosing the next migration number, and writing correctly named SQL files for database changes.
Why use it?
It helps prevent migrations from using wrong table or column names and avoids changing migrations that have already run. It also keeps version numbers ordered and unique.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents).

This is zwl467135974/lumina's own configuration. It tells Claude Code and Codex how to work on lumina itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything lumina configures →

Reuse

Borrowing it

Nothing to install: this file belongs to zwl467135974/lumina. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/zwl467135974/lumina/master/.agents/skills/lumina_flyway/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/zwl467135974/lumina

Made for: Claude Code, Codex.

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 lumina_flyway

README.md
[![agentmods](https://agentmods.dev/badge/skills/zwl467135974/lumina/lumina_flyway/github.svg)](https://agentmods.dev/skills/zwl467135974/lumina/lumina_flyway)
Your own site
<a href="https://agentmods.dev/skills/zwl467135974/lumina/lumina_flyway"><img src="https://agentmods.dev/badge/skills/zwl467135974/lumina/lumina_flyway/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 lumina_flyway

Your own site · 80×15
<a href="https://agentmods.dev/skills/zwl467135974/lumina/lumina_flyway"><img src="https://agentmods.dev/badge/skills/zwl467135974/lumina/lumina_flyway.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,089 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.01089
Opus 5 $0.00000 $0.00544
Sonnet 5 $0.00000 $0.00218
Haiku 4.5 $0.00000 $0.00109

Measured 13d ago against content hash fb0892eb7696, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

lumina_flyway 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 13d 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.

.agents/skills/lumina_flyway/SKILL.md · 101 lines

How it starts

The opening of the file, as written. The whole thing — 101 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Lumina Flyway 迁移规范

核心原则

写新迁移前必须先检查已有迁移的表结构、列名、数据约定。

版本号规则

  • 单调递增:V1, V2, ..., V25, V26...
  • 不跳号、不复用、不修改已执行的迁移
  • 文件命名:V{版本号}__{简洁描述}.sql(双下划线)
  • 当前版本:V44(每次写新迁移前先 ls db/migration/ | sort | tail -3 确认最新版本号)

写迁移前的强制检查(不可跳过)

0. 查实际表结构(最高优先级,必须执行)

写任何 INSERT/ALTER 前,必须先连数据库查 DESCRIBE,确认列名真实存在。

# 查目标表的列名(替换表名)
"/c/Program Files/MySQL/MySQL Server 8.0/bin/mysql.exe" -uroot -p123456 -h127.0.0.1 lumina_dev \
  -e "DESCRIBE lumina_permission;"

或如果没有数据库连接,用 grep 从建表迁移中提取:

# 找到建表语句
grep -A 30 "CREATE TABLE.*lumina_permission" db/migration/V*.sql

绝对禁止凭记忆/猜测写列名。 历史上多次因此导致 CI 全量失败(V44 事件)。

1. 检查已有列名约定

2. 常见列名约定(必须遵守)

表名 常见易错列名 正确列名
lumina_permission name code id type permission_name permission_code permission_id permission_type
lumina_permission tenant_id(此表无租户列) ✅ 无 tenant_id
lumina_permission 父权限码 ❌ model system:model(带 system: 前缀)
lumina_role id name role_id role_code role_name
lumina_role_permission id id(自增) role_id permission_id
lumina_user id real_name user_id nickname
lumina_model_pricing provider model_name input_price output_price currency is_active
通用 create_time / update_time / deleted / tenant_id

3. 检查权限种子格式

权限种子 INSERT 必须用正确的列名和 INSERT IGNORE 防重复:

-- ✅ 正确格式(参考 V17/V25)
INSERT IGNORE INTO `lumina_permission` 
    (`parent_id`, `permission_code`, `permission_name`, `permission_type`, `path`, `icon`, `sort_order`)
VALUES (...);

-- 给 admin 角色分配权限
INSERT IGNORE INTO `lumina_role_permission` (`role_id`, `permission_id`)
SELECT 1, `permission_id` FROM `lumina_permission`
WHERE `permission_code` IN (...);

迁移内容规范

CREATE TABLE

  • ENGINE=InnoDB DEFAULT CHARSET=utf8mb4
  • 必须有 create_time / update_time / deleted
  • 索引命名:idx_{columns}uk_{columns}(唯一索引)

Read the full file on GitHub · 101 lines

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. 13d ago First seen · 101 lines · 0 tokens per session scan A fb0892eb7696

Subscribe to this mod's changes

lumina_flyway is a skill published in the GitHub repository zwl467135974/lumina (66 stars, last pushed 22d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 1,089 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-30.

Related

Other skills, from other repositories

create-pr

Creates a GitHub PR with a Linear-ticket-prefixed title and a decision-led, narrative description for Prisma 8. Use when the user wants to create a pull request, open a PR, or submit changes for review.

prisma/orm · 48 tokens

schema-exploration

Lists tables, describes columns and data types, identifies foreign key relationships, and maps entity relationships in a database. Use when the user asks about database schema, table structure, column types, what tables exist, ERD, foreign keys, or how entities relate.

langchain-ai/deepagents · 57 tokens

ha-data-stores

Map of Hope Agent's local data stores and safe read-only query workflow. Use when the user asks where Hope Agent stores data, wants to inspect sessions/messages/memory/logs/background jobs/knowledge indexes/settings, asks the model to query local app data, or debugging requires checking persisted state. Trigger…

shiwenwen/hope-agent · 115 tokens

nornicdb-cypher-queries

Pick fast, predictable Cypher query shapes in NornicDB — point lookups, batch retrieval, pagination, search, traversal, batched UNWIND/MERGE writes, cleanup, multi-tenant isolation. Use when writing or reviewing Cypher whose latency or throughput matters; maps user intent to the executor's hot-path query templates.

orneryd/NornicDB · 79 tokens

supabase

Supabase / PostgREST Row-Level-Security playbook — pull the anon (or leaked servicerole) key out of the frontend JS, map tables from the auto-generated OpenAPI spec, test anonymous RLS READ disclosures (PII/secret leaks), and anonymous RLS WRITE abuse (insert/update/delete — e.g. forging…

PentesterFlow/agent · 120 tokens

volcengine-rds-postgresql

A tool for operating PostgreSQL databases hosted by Volcano Engine's managed database service. PostgreSQL is a relational database used to store structured application data.

bytedance/agentkit-samples · 63 tokens