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 commands/wordflowlab/novel-writer/constitutiongit clone --depth 1 https://github.com/wordflowlab/novel-writerWrote 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/commands/wordflowlab/novel-writer/constitution)<a href="https://agentmods.dev/commands/wordflowlab/novel-writer/constitution"><img src="https://agentmods.dev/badge/commands/wordflowlab/novel-writer/constitution.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.1 | $0.00019 | $0.01608 |
| Opus 5 | $0.00010 | $0.00804 |
| Sonnet 5 | $0.00004 | $0.00322 |
| Haiku 4.5 | $0.00002 | $0.00161 |
Grade A, and why
constitution 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 6d 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.
How it starts
The opening of the file, as written. The whole thing — 226 lines — stays where its author put it; the contents beside it link to each section on GitHub.
用户输入可以直接提供或作为命令参数 - 你必须在继续之前考虑它(如果不为空)。
用户输入: $ARGUMENTS
目标
建立小说创作的核心原则和价值观,形成创作的"宪法"文件。这些原则将指导后续所有创作决策。
执行步骤
1. 检查现有宪法
运行 {SCRIPT} check 检查是否已存在宪法文件:
- 如果存在
memory/novel-constitution.md,加载并准备更新 - 如果不存在,准备创建新宪法
2. 收集创作原则
基于用户输入,收集以下维度的原则(如未提供则询问或推断):
核心价值观
- 作品要传递什么核心理念?
- 什么是绝对不能违背的底线?
- 创作的根本目的是什么?
质量标准
- 逻辑一致性要求
- 文字质量标准
- 更新频率承诺
- 完成度保证
创作风格原则
- 叙事风格(简洁/华丽/朴实/诗意)
- 节奏控制(快速/缓慢/张弛有度)
- 情感基调(热血/深沉/轻松/严肃)
- 语言特色(古风/现代/口语/书面)
内容原则
- 角色塑造原则
- 每个角色必须有完整动机
- 角色成长必须符合逻辑
- 对话必须符合角色身份
- 情节设计原则
- 冲突设计原则
- 转折合理性要求
- 伏笔回收原则
- 世界观原则
- 设定自洽性要求
- 细节真实性标准
- 文化考据要求
读者导向原则
- 目标读者定位
- 读者体验保证
- 互动反馈原则
创作纪律
- 日常写作规范
- 修改和完善流程
- 版本管理原则
3. 起草宪法文档
使用以下模板结构:
# 小说创作宪法
## 元数据
- 版本:[版本号,如 1.0.0]
- 创建日期:[YYYY-MM-DD]
- 最后修订:[YYYY-MM-DD]
- 作者:[作者名]
- 作品:[作品名或"通用"]
## 前言
[阐述为什么需要这份宪法,以及它的约束力]
## 第一章:核心价值观
### 原则1:[原则名称]
**声明**:[原则的明确表述]
**理由**:[为什么这个原则重要]
**执行**:[如何在创作中体现]
### 原则2:[原则名称]
[同上格式]
## 第二章:质量标准
### 标准1:逻辑一致性
**要求**:[具体要求]
**验证方法**:[如何验证]
**违反后果**:[必须修正]
[更多标准...]
## 第三章:创作风格
### 风格原则1:[名称]
**定义**:[什么是这种风格]
**范例**:[具体例子]
**禁忌**:[绝对不要做什么]
[更多风格原则...]
## 第四章:内容规范
### 角色塑造规范
[具体规范内容]
### 情节设计规范
[具体规范内容]
### 世界观构建规范
[具体规范内容]
## 第五章:读者契约
### 对读者的承诺
- [承诺1]
- [承诺2]
- [承诺3]
### 底线保证
- [保证1]
- [保证2]
## 第六章:修订程序
### 修订触发条件
- 重大创作方向调整
- 读者反馈累积
- 个人成长和认识变化
### 修订流程
1. 提出修订动议
2. 评估影响
3. 更新版本
4. 记录变更
## 附录:版本历史
- v1.0.0 (日期):初始版本
- [后续版本记录]
4. 版本管理
- 主版本号:重大原则变更或删除
- 次版本号:新增原则或章节
- 修订号:措辞优化、澄清说明
5. 一致性传播
检查并更新相关文件以保持一致:
- 更新
.specify/memory/writing-constitution.md(如存在) - 在后续命令中引用宪法原则
- 建议更新 README 中的创作理念部分
6. 生成影响报告
输出宪法创建/更新的影响:
## 宪法影响报告
- 版本:[旧版本] → [新版本]
- 新增原则:[列表]
- 修改原则:[列表]
- 影响范围:
✅ 规格定义需遵循宪法
✅ 计划制定需符合原则
✅ 创作执行需遵守规范
✅ 验证需检查合规性
7. 输出和保存
- 将宪法保存到
memory/novel-constitution.md - 输出创建/更新成功消息
- 提示下一步:
/specify定义故事规格
执行原则
必须遵守
- 原则必须是可验证的,不能太抽象
- 使用"必须"、"禁止"等明确词汇
- 每个原则都要有明确的理由
应该包含
- 至少 3-5 个核心价值观
- 明确的质量底线
- 可操作的创作规范
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.
- 6d ago First seen · 226 lines · 19 tokens per session scan A c69594893562
constitution is a command published in the GitHub repository wordflowlab/novel-writer (940 stars, last pushed 10mo ago), licensed MIT. It adds 19 tokens to every session and 1,608 once invoked, about $0.0001 per session on Opus 5. 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.
Other commands, from other repositories
checklist
Generate a custom checklist for the current feature based on user requirements.
clarify
Identify underspecified areas in the current feature spec by asking up to 5 highly targeted clarification questions and encoding answers back into the spec.
specify
Create or update the feature specification from a natural language feature description.
analyze
Perform a non-destructive cross-artifact consistency and quality analysis across spec.md, plan.md, and tasks.md after task generation.
constitution
Create or update the project constitution from interactive or provided principle inputs.
converge
Assess the current codebase against the feature's spec, plan, and tasks, then append any remaining unbuilt work as new tasks to tasks.md so implement can complete it.