一键导入
citation-validator
Validate that each attribution in a generated document is actually supported by the cited source span; flag unsupported claims
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Validate that each attribution in a generated document is actually supported by the cited source span; flag unsupported claims
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Generate a Word document from ingested source documents using the agnostic Document tree (CommonMark/Pandoc-aligned)
Generate a single Document (Word/PowerPoint) from all source documents in a collection, with attributions back to each source
Generate a PDF from ingested source documents using the agnostic Document tree
Generate a PowerPoint deck from ingested source documents using the agnostic Document tree (parametrised by slide_count, style, audience, tone)
Generate an Excel workbook (.xlsx) from ingested source documents — tabular with charts, formulas, KPI cells
Find PII (emails, phones, SSN, credit cards, IBANs, names, addresses, DOB) in an ingested document; return redaction plan
| name | citation-validator |
| description | Validate that each attribution in a generated document is actually supported by the cited source span; flag unsupported claims |
| model | gemini/gemini-embedding-001 |
| tier | flash |
| inputs | [{"name":"workspace_id","type":"str","required":true,"description":"Workspace directory under /data/workspaces/<id>/ containing document.json"},{"name":"similarity_threshold","type":"float","required":false,"description":"Cosine similarity below this is flagged unsupported (default 0.55)"}] |
| outputs | [{"name":"workspace_id","type":"str"},{"name":"overall_confidence","type":"float","description":"Mean similarity across all validated attributions (0..1)"},{"name":"validated_count","type":"int"},{"name":"unsupported_count","type":"int"},{"name":"per_node","type":"list[dict]","description":"[{node_id, source_document_id, source_section_id, similarity, supported, source_excerpt, generated_excerpt}]"}] |
This skill cross-checks every attribution entry in a generated document.json against the actual source content stored in the database. It uses Phase 14's Gemini 768-dim embeddings to compute cosine similarity and flags any attribution whose similarity falls below the configured threshold.
CONTENT_AGENT_WORKSPACE/<workspace_id>/document.json.Section (title + summary + up to 3 pages of content) → Chapter (title + summary) → Document (title + summary). The first non-empty level wins.EmbeddingProvider.embed_batch([generated_text, source_excerpt]) via get_embedding_provider(). Both texts are embedded in a single batched call to minimise API round-trips.supported = similarity >= threshold (default 0.55). Nodes whose generated text has no match in the source text will produce near-zero cosine similarity and be flagged as unsupported.overall_confidence is the arithmetic mean of per-node similarity scores.SkillInvocation audit row is written via persist_skill_invocation; failures are silently swallowed.0.55 is chosen as a conservative baseline: real citations to their source material tend to score above 0.65–0.80, while hallucinated content typically scores below 0.40. Teams working with highly technical or domain-specific corpora may want to raise the threshold to 0.65.
attributions is empty or absent the skill returns immediately with validated_count=0 and a note field.similarity=0.0 and supported=False are reported for that node without raising.GOOGLE_API_KEY, quota exceeded, etc.) the skill raises RuntimeError — a partial result with silent errors would be misleading.