Deterministic external-evidence web validation workflow for Sanguo ETL/RAG. USE FOR: 外部證據網站檢查、來源健康度、allowlist 驗證、來源 seed 覆蓋、3kweb-check、external evidence source health、fetch/parse/hash first、LLM reviewer second。
日本語の概要は準備中です。原文の説明を表示しています。
Sanguo RAG unresolved mention resolution loop. Use for: 三國 RAG, unresolved mentions, alias review, observed mentions, MCQ triage, manual roster seeds, false-positive exclusion, running run_resolution_loop.py, applying unresolved-triage answers, delegating 三國名詞查證 to a web-capable agent, or Pilot ETL chunk experiments with LangChain text splitters / LangGraph / LangFlow around 張飛長坂橋等小樣本流程。
インストールする前に、エージェントに与えられる指示の中身を確認できます。
這個 skill 用來把 observed mentions -> unresolved labels -> MCQ 裁決 -> decisions/manual roster -> rebuild/rescan 做成可重複循環。
Unity 對照:這類似一個資料版 AssetPostprocessor。腳本負責 deterministic import/rebuild,人工或研究 agent 只裁決少數不確定 label。
unresolved、alias review、observed mentions、manual roster seeds、文本稱呼表、正式對照表。server/npc-brain/pipelines/sanguo-rag/run_resolution_loop.pyserver/npc-brain/pipelines/sanguo-rag/clean_and_split.pyserver/npc-brain/pipelines/sanguo-rag/apply_triage_answers.pyserver/npc-brain/pipelines/sanguo-rag/generate_term_research_brief.pyserver/npc-brain/pipelines/sanguo-rag/config/unresolved-triage-decisions.jsonserver/npc-brain/pipelines/sanguo-rag/config/manual-roster-seeds.jsonartifacts/data-pipeline/sanguo-rag/extracted/resolution-loop/unresolved-triage-choices.mdartifacts/data-pipeline/sanguo-rag/extracted/resolution-loop/unresolved-triage-answers.todo.json當使用者想學「LangChain text splitters / LangGraph / LangFlow 到底該放在哪」,先不要把整條 unresolved loop 改成框架驅動;先用 張飛長坂橋 這種單章小樣本做對照實驗。
先跑原本的 clean_and_split.py,保留章回與 paragraph index:
python server/npc-brain/pipelines/sanguo-rag/clean_and_split.py \
--input <source.md> \
--output-root artifacts/data-pipeline/sanguo-rag/markdown \
--overwrite
這會得到:
source.mdchapters/ch_###.mdchapters-manifest.json這一層是 deterministic evidence layer,類似 Unity 先把 raw asset import 成可追蹤 metadata。
若要比較 paragraph-based 切法與 LLM 常用 chunking,再跑:
python server/npc-brain/pipelines/sanguo-rag/clean_and_split.py \
--input <source.md> \
--output-root artifacts/data-pipeline/sanguo-rag/markdown \
--chunk-with-langchain \
--chunk-size 500 \
--chunk-overlap 80 \
--overwrite
額外輸出:
chunks/<chapter_id>/<chunk_id>.mdchunks-manifest.json學習重點:
chapters-manifest.json 看 paragraph index / source offset。chunks-manifest.json 看 chunk size / overlap / source refs。LangGraph 不適合拿來取代 deterministic preprocessing。它最有價值的地方是:
chunk -> extract -> validate -> retry -> review 這種有狀態、有分流的 LLM pipelinehigh-confidence -> publish / low-confidence -> review queue 這種圖狀流程若目前只是單章 PoC,先不用急著上 LangGraph。
LangFlow 最適合:
但正式 pipeline 還是應以 Python 腳本為主,避免把核心 ETL 綁死在視覺化編排工具。
docs/keep.summary.md and use Traditional Chinese.encoding-touched-guard and run touched encoding checks before finishing.python server/npc-brain/pipelines/sanguo-rag/run_resolution_loop.py --top 30
python server/npc-brain/pipelines/sanguo-rag/apply_triage_answers.py
python server/npc-brain/pipelines/sanguo-rag/run_resolution_loop.py --top 30
python -m py_compile \
server/npc-brain/pipelines/sanguo-rag/collect_observed_mentions.py \
server/npc-brain/pipelines/sanguo-rag/run_resolution_loop.py \
server/npc-brain/pipelines/sanguo-rag/apply_triage_answers.py \
server/npc-brain/pipelines/sanguo-rag/generate_term_research_brief.py
npm run check:encoding:touched -- --files <changed-text-files>
A person: a real person label. Requires personRecord.generalId and personRecord.faction; apply_triage_answers.py adds it to manual roster seed.B noise: not a person. Adds to noiseLabels; collector emits it as excluded, not unresolved.C ambiguous: still needs review or is useful but not resolvable now. Adds to ambiguousLabels; collector emits it as review-pending.D defer: no action; it stays unresolved and will appear again.Do not force all unresolved labels into person seeds. The goal is zero unclassified labels, not zero non-person labels.
若同一批名詞會反覆查固定來源,不要每次都直接委派瀏覽器研究。先判斷是否該用 agent-cli-factory 建一層 repo-local term lookup CLI,例如 3klife-sanguo-term-lookup,把輸出壓成 --compact --json 的來源命中摘要、候選 person/noise 判斷與 citation 線索。
CLI-first 的目標不是跳過人工審核,而是先把「明顯不是人名」或「明顯命中既有來源」的候選縮成小結果集,讓 web-capable agent 只處理真正模糊的標籤。
現成 term lookup CLI:
node tools_node/agent-clis/3klife-sanguo-term-lookup.js \
--choices-json artifacts/data-pipeline/sanguo-rag/extracted/resolution-loop/unresolved-triage-choices.json \
--limit 20 \
--compact
node tools_node/agent-clis/3klife-sanguo-term-lookup.js \
--label 孔明 \
--label 子敬 \
--label 主公 \
--json
When labels are not obvious, first generate a research brief:
python server/npc-brain/pipelines/sanguo-rag/generate_term_research_brief.py --top 30
Then delegate the brief to Sanguo Term Researcher if available. Ask it to return answer, confidence, evidence, and a suggested personRecord only for clear people.
If no web-capable agent/tool or reusable CLI is available in the current environment, do not pretend a web check was performed. Provide the research brief path and continue deterministic loop work.
https://zh.wikipedia.org/wiki/三國演義角色列表,可快速確認稱呼是否屬於《演義》人物名單。person, output generalId in kebab pinyin style and a conservative faction (wei, shu, wu, enemy, neutral).B noise.C ambiguous.Stop a loop round when:
Always report the current counts: resolved, unresolved, excluded, reviewPending, and number of generated questions.
まだレビューはありません。使ってみた感想をお寄せください。
概要と使いどころ
Deterministic external-evidence web validation workflow for Sanguo ETL/RAG. USE FOR: 外部證據網站檢查、來源健康度、allowlist 驗證、來源 seed 覆蓋、3kweb-check、external evidence source health、fetch/parse/hash first、LLM reviewer second。
日本語の概要は準備中です。原文の説明を表示しています。
Use when the user asks to switch AI role/mode/persona or uses role-trigger words such as Captain, Coordinator, 寫文章, 寫文章模式, 文章模式, 技術文章, 部落格, 出版, 預覽. Routes the request to Project Captain, Publishing Director, or Article Writing Mode, loads the matching keep memory when available, and applies the role's workflow without excessive roleplay.
日本語の概要は準備中です。原文の説明を表示しています。
Write or revise AI-learning-notes article pages in "寫文章模式" when the user asks for articles, technical articles, blog posts, bilingual versions, article formatting consistency, shared article-base alignment, responsive layout, summary/TOC decisions, contrast, or publishing-flow compatibility.
日本語の概要は準備中です。原文の説明を表示しています。
Plan ATM framework refactors by preserving atom/map semantics before splitting large governance modules.
日本語の概要は準備中です。原文の説明を表示しています。
Captain 派工規範與決策手冊。當 AI 進入隊長模式或進行派工/派任務語境時,遵照這套標準,產出可供人類直接轉貼、高度結構化、符合 token 經濟且能動態適應可用 Roster 的派工單。
日本語の概要は準備中です。原文の説明を表示しています。
Create and register an atom through the provisioning facade.
日本語の概要は準備中です。原文の説明を表示しています。