Token导航 LogoToken导航TokenDH.com
研究检索敏感数据clawhub未标认证来源可访问clear审计通过

civil-judgment-taiwan-vectorstore台湾民事判决矢量商店

Agent Skill

用于搭建或维护带检索增强的 RAG 工作流,适合让 Agent 处理知识库问答、向量检索、来源引用和事实核查。它可以辅助整理数据接入、Embedding、向量库、召回参数和回答生成流程。使用时需要确认数据来源、更新频率、召回阈值和引用展示方式,避免把未命中的资料或过期内容包装成确定事实。

总安装

3,504

周安装

149

GitHub Stars

公开资料未说明

下载量

1,228
OpenClaw

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:civil-judgment-taiwan-vectorstore(台湾民事判决矢量商店)
来源仓库:https://github.com/alex02131926/civil-judgment-taiwan-vectorstore
安装命令:
openclaw skills install civil-judgment-taiwan-vectorstore
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install civil-judgment-taiwan-vectorstore

简介

台湾民事判决矢量商店将法院裁决引入 Qdrant 向量库,支持 RAG 问答。

  • 适用于 OpenClaw 中法律知识库构建与司法案例检索场景。
  • 通过 clawhub 安装,使用 Ollama 嵌入保留可追溯性。
  • 使用前需确认 HTML/PDF 来源合法性及更新频率。
  • 回答时应标注引用段落,避免将推测内容包装成确定事实。

SKILL.md

name
civil-judgment-taiwan-vectorstore
description
Ingest Taiwan civil court judgments (HTML or PDF) — exclusively covering Taiwan civil cases — into Qdrant with Ollama embeddings, preserving traceability, deduplication, and incremental updates.
user-invocable
true

Taiwan Civil Judgment → Vector DB (Qdrant) Ingestion

Scope: Taiwan civil court judgments only (民事判決). This skill ingests Taiwan civil cases (HTML or PDF files) into Qdrant. All parsing, chunking, and embedding logic lives in scripts/ingest.py — your job is to run the script, not to reimplement the pipeline.


Quick Start (follow these steps in order)

Step 1 — Activate venv

source {baseDir}/.venv/bin/activate

Step 2 — Identify the run folder

The user will provide an absolute path to a run folder.

Example: /path/to/output/judicialyuan/20260305_142030

Verify it exists and has HTML or PDF files:

ls <RUN_FOLDER>/archive/ | grep -E '\.(html|pdf)$' | head -5

If no archive/*.html or archive/*.pdf files → stop and tell the user the folder has no ingestible data.

Step 3 — Run ingestion

Use absolute paths throughout — no cd needed:

python3 {baseDir}/scripts/ingest.py \
  --run-folder <RUN_FOLDER>

The script handles everything: pre-flight checks, collection auto-creation (creates civil_case_doc / civil_case_chunk if they don't exist), canonicalization, chunking, embedding, Qdrant upsert, manifest + report writing.

Re-running the same command on the same folder is always safe — deterministic IDs mean upsert = overwrite. No special --resume flag needed; just run the same command again.

Step 4 — Check the result

Successful output looks like:

OK files=42 processed=42 skipped=0 errored=0 doc_points=42 chunk_points=187
manifest=<RUN_FOLDER>/ingest_manifest.jsonl
report=<RUN_FOLDER>/ingest_report.md

Read the report (human-readable stats summary):

cat <RUN_FOLDER>/ingest_report.md

If there are errors, check the manifest (machine-readable, one JSON line per file) for per-file diagnosis:

grep -E '"status":"(skipped|error|partial)"' <RUN_FOLDER>/ingest_manifest.jsonl

Step 5 — Report to user

Tell the user:

  • How many docs were ingested (doc_points)
  • How many chunks were created (chunk_points)
  • Whether any were skipped or errored
  • Where the report file is

Done. Do not proceed to additional steps unless the user asks.


DO NOT rules (critical)

  • DO NOT write your own HTML parsing, chunking, or embedding code. ingest.py handles all of this.
  • DO NOT modify parsing/chunking logic casually. Only change heading detection or chunk fallback when the user explicitly asks to improve PDF/OCR robustness, and validate on a small sample before re-running a large batch.
  • DO NOT call Qdrant or Ollama APIs directly. The script does this.
  • DO NOT use verify=False or skip SSL verification for any HTTP request.
  • DO NOT modify or delete files under archive/. Raw HTML is immutable source of truth.
  • DO NOT change chunking defaults (--max-chars, --overlap-chars) unless the user explicitly asks.

Hard constraints

  • Raw HTML/PDF is source of truth; never overwrite it.
  • Deterministic: same input → same canonical text → same SHA-256 → same Qdrant point IDs. Safe to re-run.
  • Traceability: every Qdrant point carries doc_url + local_path.
  • Batched upserts (≤ 64 points/batch) to avoid Qdrant 32MB payload limit.
  • parser_version in every point's metadata. Current: v3.5-sentence-boundary.

Troubleshooting

PREFLIGHT_FAILED: Qdrant not reachable

Qdrant is down or unreachable at the default/configured URL.

# Check if Qdrant is running
curl -s http://localhost:6333/collections | head -1

# If not running, start it (or ask the user)

PREFLIGHT_FAILED: Ollama not reachable

# Check Ollama
curl -s http://localhost:11434/api/tags | head -5

PREFLIGHT_FAILED: Ollama model missing: bge-m3:latest

ollama pull bge-m3:latest

Then re-run Step 3.

PREFLIGHT_FAILED: No archive/*.html or archive/*.pdf found

The run folder exists but has no archived detail pages. Check:

  • Is this the correct run folder?

Output shows skipped > 0 or errored > 0

Check ingest_manifest.jsonl for per-file details:

grep -E '"status":"(skipped|error|partial)"' "<RUN_FOLDER>/ingest_manifest.jsonl"
Manifest statusMeaningAction
okDoc + all chunks ingestedNone
partialDoc upserted, but some section chunks failed embeddingCheck Ollama stability; can re-run safely
skippedDoc-level embedding failed — nothing upserted for this docCheck Ollama; re-run safely
errorHTML read/parse failedCheck if the HTML file is corrupted

Re-running is always safe — use the exact same command. No special flags needed; deterministic IDs → upsert/overwrite.

Override service endpoints

# Via environment variables
OLLAMA_URL=http://localhost:11434 QDRANT_URL=http://localhost:6333 \
  python3 scripts/ingest.py --run-folder "..."

# Via CLI flags (take precedence over env vars)
python3 scripts/ingest.py --run-folder "..." \
  --ollama http://localhost:11434 --qdrant http://localhost:6333

Default endpoints:

ServiceDefaultEnv override
Ollamahttp://localhost:11434$OLLAMA_URL
Qdranthttp://localhost:6333$QDRANT_URL

Test with a small batch first

python3 scripts/ingest.py --run-folder "..." --limit 5

Input folder structure (expected)

<run_folder>/
  archive/
    fjud_detail_001.html               ← HTML input
    fjud_detail_002.html
    fjud_detail_003.pdf                ← PDF input (also supported)
    fint_detail_001.html               (if system=both)
  results_fjud.jsonl                   (optional)
  results_fint.jsonl                   (optional)

The script discovers all archive/*.html and archive/*.pdf files automatically (sorted by filename). HTML and PDF files can coexist in the same run folder.

v1 limitation: The system metadata field is currently hardcoded to FJUD. If a run folder contains both FJUD and FINT files, FINT files will be ingested but mislabeled as FJUD. This does not affect chunking or embeddings — only the system metadata field on the resulting Qdrant points.


CLI reference

python3 scripts/ingest.py --run-folder <PATH> [options]
FlagDefaultDescription
--run-folder(required)Path to an input folder
--ollama$OLLAMA_URL or http://localhost:11434Ollama endpoint
--qdrant$QDRANT_URL or http://localhost:6333Qdrant endpoint
--embed-modelbge-m3:latestOllama embedding model
--vector-size1024Vector dimension
--max-chars900Max chars per chunk (500–1000)
--overlap-chars150Overlap between chunks (10–20% of max-chars)
--limit0 (no limit)Process only first N files sorted by filename (lexicographic order); for testing

Outputs

  • Qdrant collections: civil_case_doc (1 point/doc), civil_case_chunk (many points/doc). Auto-created if they don't exist.
  • ingest_report.md: human-readable summary (doc/chunk counts, error counts). Read this first after ingestion.
  • ingest_manifest.jsonl: machine-readable, one JSON line per doc with status (ok / partial / skipped / error). Read this to diagnose specific file failures (grep for non-ok statuses). Both files overlap on aggregate counts; the manifest adds per-file detail.

Roadmap

  • v1 (current): doc + section-aware chunks
  • v2: candidate issue extraction (爭點抽取)
  • v3: issue-level index (civil_case_issue collection)

Internal details

For metadata schema, canonicalization rules, section-splitting patterns, and chunking implementation, see references/internals.md.


Lessons learned / operational gotchas

  • Qdrant rejects non-UUID/non-integer point IDs (400 Bad Request). The script uses deterministic UUIDs — do not change the ID generation logic.
  • Qdrant rejects payloads > 32MB. The script batches at 64 points — do not increase batch size.
  • Re-running on the same folder is safe: deterministic IDs mean upsert = overwrite.
  • 台灣判決書 section headings 格式不統一(e.g.「理 由」with fullwidth space、兼容字如「⽂」)。目前 parser 已先做 heading normalization;若仍切不出 section,會 fallback 對 full 做 chunking,避免只留下 doc-level points。

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

需要根据任务场景推荐可安装能力包时

04

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenClaw

98.17%
按下载量换算1,206

安全审计

VirusTotal

通过

ClawScan

通过

Static analysis

通过

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills