text-provenance

Rank candidate source documents for text passages using lexical similarity.

46|25|Updated May 7, 2026
One-click install
npx skills add https://github.com/LegalQuants/lq-skills --skill text-provenance
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: text-provenance
Source: https://github.com/LegalQuants/lq-skills/tree/main/skills/text-provenance
Command: npx skills add https://github.com/LegalQuants/lq-skills --skill text-provenance

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Helps you identify the likely source document of a text passage, support clause attribution in legal documents, and flag potential plagiarism through fast lexical matching signals.

Core Features & Use Cases

  • Source attribution ranking: Returns a ranked list of candidate source passages with confidence scores for RAG-style citation highlighting.
  • Contract clause provenance: Helps match contract clauses to likely playbook or standard clause origins for derivation workflows.
  • Plagiarism screening support: Produces candidate matches to investigate, without making definitive adjudications.

Quick Start

Use the text-provenance skill to compare a snippet against your corpus documents and return ranked provenance candidates with similarity-based confidence scores.

Frequently Asked Questions about text-provenance

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I trace legal text to its likely source document?

You can identify contract clause provenance by matching clauses against a playbook or standard clause origins using lightweight lexical similarity. The skill ranks candidate source passages with confidence scores to support derivation workflows.

Can I generate RAG citations without using runtime embeddings?

Yes, you can generate RAG citation highlighting deterministically without runtime embeddings or API calls. The skill relies on surface similarity, n-gram overlap, and exact fingerprint matching to produce ranked provenance candidates.

How does lexical similarity scoring work for plagiarism screening?

Lexical similarity scoring for plagiarism screening works by calculating n-gram overlap and exact phrase matching to produce candidate matches. It operates deterministically to flag potential plagiarism for investigation without making definitive adjudications.

Do I need external API calls for text attribution matching?

No, you do not need external API calls for text attribution matching. The skill operates deterministically using surface similarity and exact fingerprint matching, ensuring fast candidate provenance rankings without runtime dependencies.

What are the limitations of using surface similarity for contract analysis?

A limitation of using surface similarity for contract analysis is that it produces candidate matches to investigate rather than definitive adjudications. It relies strictly on lexical overlap and fingerprint matching without deeper semantic understanding.