research-literature-review
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseResearch Literature Review
Research Literature Review
定位与检索依赖
Positioning and Retrieval Dependencies
- 目标:在一个隔离工作目录内完成“检索 → 去重 → 评分 → 选文 → 写作 → 校验 → PDF/Word 导出”的完整综述流水线。
- 适用:用户明确要系统综述、文献综述、related work、文献调研,并希望得到 LaTeX + BibTeX + PDF/Word 产物。
- 不适用:只想补单条参考文献、只想润色已有正文、只想写普通摘要或与综述无关的文章。
- 最高原则:以最佳可用证据和写作质量完成综述;不确定时说明处理方式,不为赶进度牺牲可信度。
- 是阶段 1/2 的必需依赖(contract
research-literature-search)。review 只消费其 manifest、canonical candidates 和 provenance,不再内嵌 provider 或执行第二套 canonical 去重。rls.v1 - 旧名 仅作为 prompt 兼容别名保留;
systematic-literature-review仍是稳定历史工作区名。.systematic-literature-review/
- Objective: Complete the full review pipeline of "Retrieval → Deduplication → Scoring → Paper Selection → Writing → Verification → PDF/Word Export" within an isolated working directory.
- Applicable: Users explicitly request systematic literature review, literature review, related work, literature research, and expect to get LaTeX + BibTeX + PDF/Word deliverables.
- Not applicable: Only want to supplement a single reference, only want to polish existing text, only want to write a regular abstract or articles unrelated to reviews.
- Highest principle: Complete the review with the best available evidence and writing quality; when uncertain, explain the processing method, and do not sacrifice credibility for progress.
- is a required dependency for Phase 1/2 (contract
research-literature-search). The review only consumes its manifest, canonical candidates and provenance, and no longer embeds providers or executes a second set of canonical deduplication.rls.v1 - The old name is retained only as a prompt compatibility alias;
systematic-literature-reviewremains the stable historical workspace name..systematic-literature-review/
输入
Input
最少需要:
- :一句话主题。
{主题} - 可选范围:时间、语言、研究类型、数据库偏好等。
- 档位:/
Premium/Standard;未指定时读取Basic默认值。config.yaml - 目标字数与参考文献范围:未指定时按 。
config.yaml.scoring.default_*_range - 输出目录或安全化前缀:未指定时使用安全化主题名。
- 查询输入:阶段 1 前必须提供符合公开 schema 的多查询 JSON;推荐用 ,也可填写当前 run 的
--query-file。input/queries.json
Minimum requirements:
- : One-sentence topic.
{Topic} - Optional scope: Time, language, research type, database preference, etc.
- Tier: /
Premium/Standard; if not specified, read the default value fromBasic.config.yaml - Target word count and reference range: If not specified, follow .
config.yaml.scoring.default_*_range - Output directory or sanitized prefix: If not specified, use the sanitized topic name.
- Query input: Before Phase 1, multi-query JSON conforming to the public schema must be provided; it is recommended to use , or fill in
--query-fileof the current run.input/queries.json
流程
Process
输入
Input
按用户请求和配置文件提供必要输入;缺失信息应明确列出并停止依赖该输入的步骤。
Provide necessary input according to user requests and configuration files; if information is missing, list it clearly and stop the steps that depend on this input.
执行步骤
Execution Steps
- 当用户环境中出现因本 skill 设计缺陷导致的 bug 时,优先使用 按规范记录到
bensz-collect-bugs,严禁直接修改用户本地 Claude Code / Codex 中已安装的 skill 源码。~/.bensz-skills/bugs/ - 若 AI 仍可通过 workaround 继续完成用户任务,应先记录 bug,再继续完成当前任务。
- 当用户明确要求“report bensz skills bugs”等公开上报动作时,调用本地 与
gh,仅上传新增 bug 到bensz-collect-bugs;不要 pull / clone 整个 bug 仓库。huangwb8/bensz-bugs
- When a bug caused by the design flaw of this skill occurs in the user's environment, prioritize using to record it in
bensz-collect-bugsaccording to specifications. It is strictly forbidden to directly modify the source code of the skill installed in the user's local Claude Code / Codex.~/.bensz-skills/bugs/ - If the AI can still complete the user's task through a workaround, record the bug first, then continue to complete the current task.
- When the user explicitly requests actions such as "report bensz skills bugs" for public reporting, call the local and
gh, and only upload new bugs tobensz-collect-bugs; do not pull / clone the entire bug repository.huangwb8/bensz-bugs
准备
Preparation
- 记录主题、档位、字数/参考范围与输出目录。
- 先读取 ,生成查询 JSON。公开 schema 支持以下三种形态:
references/ai_query_generation_prompt.md{"queries": [{"query": "...", "rationale": "..."}]}[{"query": "...", "rationale": "..."}]["query 1", "query 2"]
- 剔除空查询后,有效数量必须满足 (默认 5–25)。
config.yaml:query_input.min_queries/max_queries - 已知工作目录时,直接将文件保存到 ,或用
<work-dir>/input/queries.json让 runner 将显式输入复制到该位置。工作目录尚未建立时,先运行--query-file <path>,填充打印出的--prepare-only,再以input/queries.json继续。--resume ... --resume-from 1 - 开始前优先阅读:
references/ai_query_generation_prompt.mdreferences/ai_scoring_prompt.mdreferences/expert-review-writing.mdreferences/review-tex-section-templates.md- 涉及翻译时再读
references/multilingual-guide.md
- Record the topic, tier, word count/reference range and output directory.
- First read to generate query JSON. The public schema supports the following three forms:
references/ai_query_generation_prompt.md{"queries": [{"query": "...", "rationale": "..."}]}[{"query": "...", "rationale": "..."}]["query 1", "query 2"]
- After removing empty queries, the valid number must meet (default 5–25).
config.yaml:query_input.min_queries/max_queries - When the working directory is known, directly save the file to , or use
<work-dir>/input/queries.jsonto let the runner copy the explicit input to this location. When the working directory has not been established, run--query-file <path>first, fill in the printed--prepare-only, then continue withinput/queries.json.--resume ... --resume-from 1 - Prioritize reading the following before starting:
references/ai_query_generation_prompt.mdreferences/ai_scoring_prompt.mdreferences/expert-review-writing.mdreferences/review-tex-section-templates.md- Read when translation is involved
references/multilingual-guide.md
多查询检索(调用 research-literature-search)
Multi-Query Retrieval (Call research-literature-search)
- 查询来源优先级固定为:显式 → 当前 run 的
--query-file→input/queries.json→input/queries_{stem}.json→ 当前 run 内唯一历史兼容文件。output/artifacts/queries_{stem}.json - 自动发现多个候选时停止并报告冲突;发现文件但 schema/数量无效时停止并给出修复提示。不得跨 run 猜测查询路径。
- 启动阶段先发现并校验 (顺序:
research-literature-search→ 项目内--search-skill-root→ 环境变量 → 用户 Skill 根目录);缺失或 contract 不兼容时 fail-closed,并给出安装提示。skills/research-literature-search - 调用 search 的 入口生成 manifest bundle;review 将其作为只读输入包保存并记录 manifest/candidate hash、contract version 和 source path。
run - Search Log 的 由 manifest 单向生成;AI 不手写 provider 次数、候选数量或去重结论。
search_mode/query_source/requested_query_count/accepted_query_count/fallback_reason - 单查询只作为显式后备:传 ,可用
--allow-single-query-fallback写明原因;日志必须标记--fallback-reason和醒目警告。search_mode=single_query
- Query source priority is fixed as: Explicit →
--query-fileof current run →input/queries.json→input/queries_{stem}.json→ the only historical compatible file in current run.output/artifacts/queries_{stem}.json - Stop and report conflicts when multiple candidates are automatically discovered; stop and give repair prompts when the file is found but the schema/quantity is invalid. Do not guess query paths across runs.
- During the startup phase, first discover and verify (order:
research-literature-search→ in-project--search-skill-root→ environment variables → user Skill root directory); fail-closed if missing or contract incompatible, and give installation prompts.skills/research-literature-search - Call the entry of search to generate the manifest bundle; the review saves it as a read-only input package and records the manifest/candidate hash, contract version and source path.
run - in Search Log is generated unidirectionally by the manifest; the AI does not manually write the number of providers, candidate quantity or deduplication conclusions.
search_mode/query_source/requested_query_count/accepted_query_count/fallback_reason - Single query is only used as an explicit fallback: pass , and use
--allow-single-query-fallbackto specify the reason; the log must mark--fallback-reasonand a prominent warning.search_mode=single_query
去重(契约验证,不重复去重)
Deduplication (Contract Verification, No Repeated Deduplication)
- 验证 manifest、artifact hash、和
rls.paper.v1;保留candidates_deduped.jsonlcheckpoint 名称以兼容 resume。2_dedupe - 新运行不得再次执行旧 或改变 canonical 顺序;旧文件/旧 checkpoint 仅通过显式 legacy adapter 读取,并标记
dedupe_papers.py。legacy_adapted - 所有后续流程只读取 search bundle 的 canonical 候选集。
- Verify manifest, artifact hash, and
rls.paper.v1; retain thecandidates_deduped.jsonlcheckpoint name for resume compatibility.2_dedupe - New runs must not re-execute the old or change the canonical order; old files/old checkpoints are only read through explicit legacy adapters and marked
dedupe_papers.py.legacy_adapted - All subsequent processes only read the canonical candidate set of the search bundle.
AI 评分与数据抽取
AI Scoring and Data Extraction
- AI 按 逐篇阅读标题与摘要,输出
references/ai_scoring_prompt.md。scored_papers.jsonl - 每篇至少包含:、
score、subtopic、rationale、alignment。extraction - 评分范围固定为 1-10 分;仅对 分文献分配子主题,避免弱相关论文污染子主题规划。
>=5 - 自检分布是否健康:高分约 20-40%,中分 40-60%,低分 10-30%。
- The AI reads the title and abstract of each paper according to and outputs
references/ai_scoring_prompt.md.scored_papers.jsonl - Each entry must include at least: ,
score,subtopic,rationale,alignment.extraction - The scoring range is fixed at 1-10 points; only papers with a score >=5 are assigned subtopics to avoid weak-related papers polluting subtopic planning.
- Self-check whether the distribution is healthy: about 20-40% high scores, 40-60% medium scores, 10-30% low scores.
选文与 Bib 生成
Paper Selection and Bib Generation
- 按目标参考范围和高分优先比例选出最终集合。
select_references.py - 生成 、
selected_papers.jsonl、references.bib。selection_rationale.yaml - Bib 清洗必须保留:大小写无关去重 key、LaTeX 特殊字符转义、缺失字段警告。
- 摘要缺失或过短的条目标记 ,并在报告中提示摘要覆盖率风险。
do_not_cite
- selects the final set according to the target reference range and high-score priority ratio.
select_references.py - Generate ,
selected_papers.jsonl,references.bib.selection_rationale.yaml - Bib cleaning must retain: case-insensitive deduplicated keys, LaTeX special character escaping, missing field warnings.
- Entries with missing or too short abstracts are marked , and prompt the risk of abstract coverage in the report.
do_not_cite
子主题与配额规划
Subtopic and Quota Planning
- AI 基于评分结果规划 3-7 个子主题,并给出段落配额。
- 默认思路:引言约 1.5k、讨论/展望各约 1k、结论约 0.6k,其余分给子主题段。
- 结果写入工作条件与数据抽取表,作为写作锚点。
- The AI plans 3-7 subtopics based on the scoring results and provides paragraph quotas.
- Default approach: Introduction is about 1.5k words, discussion/prospects are about 1k words each, conclusion is about 0.6k words, and the rest are allocated to subtopic paragraphs.
- The results are written into the working conditions and data extraction table as writing anchors.
字数预算
Word Count Budget
- 用 生成 3 份预算 CSV,再汇总为
plan_word_budget.py。word_budget_final.csv - 引用段与无引用段预算均需覆盖;总字数误差必须控制在 内。
config.yaml.word_budget.tolerance
- Use to generate 3 budget CSVs, then summarize into
plan_word_budget.py.word_budget_final.csv - Both quoted and non-quoted paragraph budgets must be covered; the total word count error must be controlled within .
config.yaml.word_budget.tolerance
写作
Writing
- 正文章节固定为:摘要、引言、子主题段、讨论、展望、结论。
- 写作前读取 ,按文献综/述预算组织证据。
word_budget_final.csv - 默认采用单篇引用优先;引用要紧跟所支撑的观点,避免段末堆砌。
- 如需详细写作规范,直接遵循:
references/expert-review-writing.mdreferences/review-tex-section-templates.md
- Fixed sections of the main text: Abstract, Introduction, Subtopic Paragraphs, Discussion, Prospects, Conclusion.
- Read before writing, and organize evidence according to the literature review budget.
word_budget_final.csv - Single-paper citation priority is adopted by default; citations must follow the viewpoints they support, and avoid stacking at the end of paragraphs.
- For detailed writing specifications, directly follow:
references/expert-review-writing.mdreferences/review-tex-section-templates.md
有机扩写与验证
Organic Expansion and Verification
- 若字数不足,只允许在最短或证据不足的子主题段内做增量扩写,不新增子主题,不改原主张和引用。
- 依次运行:
validate_counts.pyvalidate_review_tex.py- 可选
validate_word_budget.py generate_validation_report.py
- If the word count is insufficient, only allow incremental expansion in the shortest or evidence-insufficient subtopic paragraphs, do not add new subtopics, and do not modify original claims and citations.
- Run in sequence:
validate_counts.pyvalidate_review_tex.py- Optional
validate_word_budget.py generate_validation_report.py
导出与多语言
Export and Multi-Language
- 通过 生成 PDF。
compile_latex_with_bibtex.py - 通过 生成 Word。
convert_latex_to_word.py - 如用户要求多语言版本,使用 翻译正文并智能编译;失败时保留错误报告与 broken 文件,并优先支持恢复备份。
multi_language.py
bash
undefined- Generate PDF via .
compile_latex_with_bibtex.py - Generate Word via .
convert_latex_to_word.py - If the user requests multi-language versions, use to translate the main text and compile intelligently; if it fails, retain the error report and broken files, and prioritize supporting backup recovery.
multi_language.py
bash
undefined查询文件已准备好:推荐主入口
查询文件已准备好:推荐主入口
python3 scripts/run_pipeline.py --topic "{主题}" --query-file ./queries.json --publish-dir ./review-deliverables
python3 scripts/run_pipeline.py --topic "{主题}" --query-file ./queries.json --publish-dir ./review-deliverables
两步式:先生成模板,再填充 input/queries.json 并恢复阶段 1
两步式:先生成模板,再填充 input/queries.json 并恢复阶段 1
python3 scripts/pipeline_runner.py --topic "{主题}" --work-dir <work-dir> --prepare-only
python3 scripts/pipeline_runner.py --resume <work-dir> --resume-from 1 --publish-dir ./review-deliverables
python3 scripts/pipeline_runner.py --topic "{主题}" --work-dir <work-dir> --prepare-only
python3 scripts/pipeline_runner.py --resume <work-dir> --resume-from 1 --publish-dir ./review-deliverables
临时兼容外部编排器:显式、可审计的单查询后备
临时兼容外部编排器:显式、可审计的单查询后备
python3 scripts/run_pipeline.py --topic "{主题}" --allow-single-query-fallback --fallback-reason "外部编排器暂未提供查询文件"
python3 scripts/run_pipeline.py --topic "{主题}" --allow-single-query-fallback --fallback-reason "外部编排器暂未提供查询文件"
旧入口 / resume
旧入口 / resume
python3 scripts/pipeline_runner.py --topic "{主题}" --domain general --query-file ./queries.json --publish-dir ./review-deliverables
python3 scripts/pipeline_runner.py --topic "{主题}" --domain general --query-file ./queries.json --publish-dir ./review-deliverables
显式指定 search Skill(独立安装环境)
显式指定 search Skill(独立安装环境)
python3 scripts/pipeline_runner.py --topic "{主题}" --query-file ./queries.json
--search-skill-root /path/to/research-literature-search python3 scripts/pipeline_runner.py --resume .bensz-api/task-{yyyymmdd-hhmm}-{简短描述}/research-literature-review/{run-id} --publish-dir ./review-deliverables
--search-skill-root /path/to/research-literature-search python3 scripts/pipeline_runner.py --resume .bensz-api/task-{yyyymmdd-hhmm}-{简短描述}/research-literature-review/{run-id} --publish-dir ./review-deliverables
python3 scripts/pipeline_runner.py --topic "{主题}" --query-file ./queries.json
--search-skill-root /path/to/research-literature-search python3 scripts/pipeline_runner.py --resume .bensz-api/task-{yyyymmdd-hhmm}-{简短描述}/research-literature-review/{run-id} --publish-dir ./review-deliverables
--search-skill-root /path/to/research-literature-search python3 scripts/pipeline_runner.py --resume .bensz-api/task-{yyyymmdd-hhmm}-{简短描述}/research-literature-review/{run-id} --publish-dir ./review-deliverables
阶段 3 评分后,从第 4 阶段继续
阶段 3 评分后,从第 4 阶段继续
python3 scripts/pipeline_runner.py --resume .bensz-api/task-{yyyymmdd-hhmm}-{简短描述}/research-literature-review/{run-id} --resume-from 4
`--resume-from` 只决定继续执行的阶段,不会绕过已有 `pipeline_state.json`。状态文件损坏时先备份或修复,禁止用空 state 覆盖历史 checkpoint。
- 运行环境:Python 3.9+、LaTeX(`xelatex`/`bibtex`)、pandoc。
- 关键脚本:
- 检索:`multi_query_search.py`、`openalex_search.py`
- 去重:`dedupe_papers.py`
- 选文:`select_references.py`、`build_reference_bib_from_papers.py`
- 数据抽取:`update_working_conditions_data_extraction.py`
- 字数预算:`plan_word_budget.py`、`validate_word_budget.py`
- 校验:`validate_counts.py`、`validate_review_tex.py`、`generate_validation_report.py`
- 导出:`compile_latex_with_bibtex.py`、`convert_latex_to_word.py`
- 初始化:`python3 research-literature-review/scripts/pipeline_cost.py init`
- 抓取定价:`python3 research-literature-review/scripts/pipeline_cost.py fetch-prices`
- 记录 token:`pipeline_cost.py log ...`
- 汇总:`pipeline_cost.py summary`
- 所有成本数据写到内部 `output/cost/`(旧运行仍可显式使用 legacy 目录)。
- `references/ai_query_generation_prompt.md`
- `references/ai_scoring_prompt.md`
- `references/expert-review-writing.md`
- `references/review-tex-section-templates.md`
- `references/multilingual-guide.md`
- `references/development-validation-guide.md`python3 scripts/pipeline_runner.py --resume .bensz-api/task-{yyyymmdd-hhmm}-{简短描述}/research-literature-review/{run-id} --resume-from 4
`--resume-from` only determines the phase to continue execution, and will not bypass the existing `pipeline_state.json`. When the state file is damaged, back up or repair it first, and prohibit overwriting historical checkpoints with empty state.
- Runtime environment: Python 3.9+, LaTeX (`xelatex`/`bibtex`), pandoc.
- Key scripts:
- Retrieval: `multi_query_search.py`, `openalex_search.py`
- Deduplication: `dedupe_papers.py`
- Paper selection: `select_references.py`, `build_reference_bib_from_papers.py`
- Data extraction: `update_working_conditions_data_extraction.py`
- Word count budget: `plan_word_budget.py`, `validate_word_budget.py`
- Verification: `validate_counts.py`, `validate_review_tex.py`, `generate_validation_report.py`
- Export: `compile_latex_with_bibtex.py`, `convert_latex_to_word.py`
- Initialization: `python3 research-literature-review/scripts/pipeline_cost.py init`
- Fetch pricing: `python3 research-literature-review/scripts/pipeline_cost.py fetch-prices`
- Record tokens: `pipeline_cost.py log ...`
- Summary: `pipeline_cost.py summary`
- All cost data is written to internal `output/cost/` (old runs can still explicitly use the legacy directory).
- `references/ai_query_generation_prompt.md`
- `references/ai_scoring_prompt.md`
- `references/expert-review-writing.md`
- `references/review-tex-section-templates.md`
- `references/multilingual-guide.md`
- `references/development-validation-guide.md`输出
Output
默认发布以下核心文件(通过 指定正式目录时复制):
--publish-dir{主题}_review.pdf{主题}_review.docx
可选支持性文件(使用 发布)包括 、、 和 。字数预算、候选文献、评分、选文、摘要补齐和证据卡始终属于内部中间产物,不进入正式发布目录。
--include-supporting{主题}_工作条件.md{主题}_review.tex{主题}_参考文献.bib{主题}_验证报告.md必要中间产物包括:
papers*.jsonlscored_papers.jsonlselected_papers.jsonlselection_rationale.yaml- 可选
evidence_cards_{主题}.jsonl
The following core files are published by default (copied when specifying the official directory via ):
--publish-dir{Topic}_review.pdf{Topic}_review.docx
Optional supporting files (published using ) include , , and . Word count budgets, candidate papers, scores, paper selections, abstract supplements and evidence cards are always internal intermediate products and do not enter the official publication directory.
--include-supporting{Topic}_Working_Conditions.md{Topic}_review.tex{Topic}_References.bib{Topic}_Verification_Report.mdNecessary intermediate products include:
papers*.jsonlscored_papers.jsonlselected_papers.jsonlselection_rationale.yaml- Optional
evidence_cards_{Topic}.jsonl
输出管理
Output Management
本 Skill 的新任务中间文件统一写入 。同一任务复用一个任务根目录;多 Skill 协作才创建 。正式交付物不写入该目录,历史隐藏目录只允许显式兼容读取、迁移或清理。
./.bensz-api/task-{yyyymmdd-hhmm}-{简短描述}/{skill名}/input|output|log/shared/- 默认 将运行目录放在
run_pipeline.py;查询输入位于.bensz-api/task-{yyyymmdd-hhmm}-{简短描述}/research-literature-review/<run-id>/,内部状态和产物位于input/下的output/、artifacts/、reference/、cache/、scripts/(支持性文件单独位于deliverables/)。deliverables/supporting/ - 正式交付目录必须通过 显式指定,并且只接收 PDF/Word(或显式开启的支持性文件)。不要把正式目录作为
--publish-dir。--work-dir - AI 临时脚本必须放到内部 ;不要把临时文件写到运行目录根部,不要使用绝对路径写
output/scripts/,也不要读写其他 run 目录。/tmp/* - 以环境变量 和
SYSTEMATIC_LITERATURE_REVIEW_SCOPE_ROOT为准。SYSTEMATIC_LITERATURE_REVIEW_SCRIPTS_DIR - search bundle 位于当前 review run 的 ,review 只读消费其 manifest 指向的相对路径;不得跨 run 猜测或直接信任外部绝对 artifact 路径。
output/artifacts/search_bundle_{stem}/
Intermediate files of new tasks for this Skill are uniformly written to . The same task reuses a single task root directory; is created only for multi-Skill collaboration. Official deliverables are not written to this directory, and historical hidden directories only allow explicit compatible reading, migration or cleaning.
./.bensz-api/task-{yyyymmdd-hhmm}-{short-description}/{skill-name}/input|output|log/shared/- By default, places the running directory in
run_pipeline.py; query input is located in.bensz-api/task-{yyyymmdd-hhmm}-{short-description}/research-literature-review/<run-id>/, and internal state and products are located underinput/inoutput/,artifacts/,reference/,cache/,scripts/(supporting files are separately located indeliverables/).deliverables/supporting/ - The official delivery directory must be explicitly specified via , and only accepts PDF/Word (or supporting files explicitly enabled). Do not use the official directory as
--publish-dir.--work-dir - AI temporary scripts must be placed in internal ; do not write temporary files to the root of the running directory, do not use absolute paths to write
output/scripts/, and do not read or write other run directories./tmp/* - Follow the environment variables and
SYSTEMATIC_LITERATURE_REVIEW_SCOPE_ROOT.SYSTEMATIC_LITERATURE_REVIEW_SCRIPTS_DIR - The search bundle is located in of the current review run; the review reads only the relative path pointed to by its manifest in read-only mode; do not guess across runs or directly trust external absolute artifact paths.
output/artifacts/search_bundle_{stem}/
校验
Verification
完成后执行 Skill 已有的静态检查、脚本验证或人工复核,并记录通过标准。
After completion, perform the existing static checks, script verification or manual review of the Skill, and record the passing standards.
失败与恢复
Failure and Recovery
保留错误证据和已完成产物;仅在输入、环境或外部依赖恢复后从最近的失败步骤重试。
Retain error evidence and completed products; only retry from the nearest failed step after input, environment or external dependencies are restored.
约束
Constraints
- 强制导出 PDF 与 Word;只有明确失败并记录原因时才允许缺失。
- 正文字数与参考文献数必须落在当前档位范围内;可由用户覆盖,默认值以 为准。
config.yaml - 正文固定包含:摘要、引言、至少 1 个子主题段、讨论、展望、结论。
- 必须与 BibTeX key 一致;缺失即报错。
\cite{key} - 正文禁止泄露 AI 工作流,例如“检索/去重/评分/选文/字数预算”等元叙事只能写入 。
{主题}_工作条件.md - 摘要必须为单段,避免方法学流水账;表格宽度与样式约束见 。
references/review-tex-section-templates.md - 不为凑引用而堆砌低分文献;无法确认时优先不改、不引。
- 多查询 JSON 缺失、冲突、不可解析、有效查询少于配置下限或超过上限时,阶段 1 必须 fail-closed;不得以成功退出码伪装成多查询完成。
- 只有调用方显式传入 时才允许执行一次单查询,并在 state 与 Search Log 中记录模式、来源、原因和警告。
--allow-single-query-fallback
- Mandatory export of PDF and Word; missing is only allowed when explicitly failed and the reason is recorded.
- The number of main text words and references must fall within the current tier range; it can be overwritten by the user, and the default value is based on .
config.yaml - The main text must include: Abstract, Introduction, at least 1 subtopic paragraph, Discussion, Prospects, Conclusion.
- must be consistent with the BibTeX key; an error is reported if missing.
\cite{key} - The main text is prohibited from disclosing the AI workflow; for example, meta-narratives such as "retrieval/deduplication/scoring/paper selection/word count budgeting" can only be written into .
{Topic}_Working_Conditions.md - The abstract must be a single paragraph, avoiding methodological flowcharts; table width and style constraints are specified in .
references/review-tex-section-templates.md - Do not stack low-score papers to meet citation requirements; when unsure, prioritize not modifying or citing.
- When multi-query JSON is missing, conflicting, unparseable, or the number of valid queries is less than the configuration lower limit or exceeds the upper limit, Phase 1 must fail-closed; do not pretend to complete multi-query with a successful exit code.
- Only when the caller explicitly passes is single query allowed to be executed once, and the mode, source, reason and warning are recorded in the state and Search Log.
--allow-single-query-fallback
公共硬约束
Common Hard Constraints
- 任务需要落盘时,使用唯一的 根目录;共享材料放入
./.bensz-api/task-{yyyymmdd-hhmm}-{简短描述}/,Skill 专属材料放入该 Skill 的shared/、input/、output/。log/ - 正式交付物、源代码和正式计划按项目约定保存,不写入任务工作区;未经授权不覆盖、删除、迁移或远程写入。
- 项目维护变更检查 BAC 可用性并记录需求、AI 产出、工具结果、文件改动和验证摘要;BAC 只做过程审计,不替代署名、责任或合规判断。
- 不记录 API Key、访问令牌、密码、Cookie、环境/凭据文件、私有 Prompt、身份信息、本地用户名、主机名或不必要的大体积原始数据。
- 文件路径必须规范化并限制在授权项目范围内;外部 URL、子进程和网络访问遵循最小权限,防止路径遍历、SSRF 和命令注入。
- Skill 版本唯一记录在自身 ;公开 API、协议、目录或配置变更同步文档与
config.yaml:skill_info.version。CHANGELOG.md - 仅将 Skill 或 Bensz 基础设施本身的设计缺陷交给 ;先脱敏写入
bensz-collect-bugs,当前任务不中断,只有用户明确要求才公开上报,禁止直接修改用户已安装的 Skill 源码。~/.bensz-skills/bugs/
- When the task needs to be persisted to disk, use a unique root directory; shared materials are placed in
./.bensz-api/task-{yyyymmdd-hhmm}-{short-description}/, and Skill-specific materials are placed in the Skill'sshared/,input/,output/.log/ - Official deliverables, source code and official plans are saved according to project agreements, and are not written to the task workspace; do not overwrite, delete, migrate or remotely write without authorization.
- Project maintenance changes check BAC availability and record requirements, AI output, tool results, file changes and verification summaries; BAC only performs process audits and does not replace signature, responsibility or compliance judgments.
- Do not record API Keys, access tokens, passwords, Cookies, environment/credential files, private Prompts, identity information, local usernames, hostnames or unnecessary large-volume raw data.
- File paths must be normalized and restricted within authorized project scopes; external URLs, subprocesses and network access follow the principle of least privilege to prevent path traversal, SSRF and command injection.
- Skill version is uniquely recorded in its own ; public API, protocol, directory or configuration changes are synchronized with documents and
config.yaml:skill_info.version.CHANGELOG.md - Only design defects of the Skill or Bensz infrastructure itself are submitted to ; first desensitize and write to
bensz-collect-bugs, do not interrupt the current task, and only report publicly when the user explicitly requests it. It is strictly forbidden to directly modify the source code of the Skill installed by the user.~/.bensz-skills/bugs/
Skill 专属约束
Skill-Specific Constraints
不得超出本 Skill description 和上方流程所声明的范围;不将未验证的信息伪装成确定结论。
Do not exceed the scope stated in this Skill description and the above process; do not disguise unverified information as definite conclusions.