CogDoc: A Knowledge Centric Multi Model LLM for Clause Level Extraction, Structured Representation, and Consistency Reasoning over Legal and Policy Documents

preprint OA: closed CC-BY-4.0
📄 Open PDF Full text JSON View at publisher
Full text 13,014 characters · extracted from preprint-html · click to expand
CogDoc: A Knowledge Centric Multi Model LLM for Clause Level Extraction, Structured Representation, and Consistency Reasoning over Legal and Policy Documents | Research Square window.SnipcartSettings = { analytics: { enabled: false } }; (function() { var accessVector = localStorage.getItem('access_vector') || ''; window.dataLayer = window.dataLayer || []; if (accessVector) { window.dataLayer.push({ user: { profile: { profileInfo: { snid: accessVector } } } }); } })(); (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);})(window,document,'script','dataLayer','GTM-K279D39R'); Browse Preprints In Review Journals COVID-19 Preprints AJE Video Bytes Research Tools Research Promotion AJE Professional Editing AJE Rubriq About Preprint Platform In Review Editorial Policies Our Team Advisory Board Help Center Sign In Submit a Preprint Cite Share Download PDF Research Article CogDoc: A Knowledge Centric Multi Model LLM for Clause Level Extraction, Structured Representation, and Consistency Reasoning over Legal and Policy Documents Veerababu Reddy, Pravallika Bhosale, Sreeja Alle, Anees Abdul, and 2 more This is a preprint; it has not been peer reviewed by a journal. https://doi.org/ 10.21203/rs.3.rs-9495012/v1 This work is licensed under a CC BY 4.0 License Status: Posted Version 1 posted You are reading this latest preprint version Abstract Legal and policy documents are central to organizational governance, regulatory compliance, and contractual decision making, but their length, dense terminology, and complex cross clause dependencies make manual review slow and error prone. Although large language models (LLMs) have improved automated text understanding, most existing systems handle clause extraction, risk identification, and consistency checking as separate tasks. This piecemeal design fails to produce a unified, queryable knowledge representation of the analyzed corpus, restricts document level reasoning, and offers little support for downstream reuse. Cloud based deployment also raises confidentiality concerns, while the limited interpretability of monolithic models reduces user trust. This paper presents CogDoc, a knowledge centric system that combines multi model LLM analysis with a structured knowledge representation layer for coordinated legal document understanding. Three specialized models work over shared semantic embeddings: a LLaMA based model for clause interpretation, a Mistral based model for contextual risk scoring, and a DeBERTa based model for cross clause entailment and contradiction detection. The extracted clauses, risk annotations, and inferred relations are stored in an indexed repository that supports both relational and vector based retrieval, enabling efficient querying and knowledge reuse. An explainability module attaches evidence grounded reasoning to each stored result, and the system runs entirely offline to protect sensitive data. On five benchmarks LEDGAR, CUAD, ContractNLI, BillSum, ILDC, CogDoc achieves 92.4% F1 in clause extraction, 89.7% F1 in risk classification, and 91.2% precision in consistency detection, outperforming traditional, transformer based, and standalone LLM baselines. DOI for code and datasets: https://doi.org/10.5281/zenodo.19239518, GitHub repository link: https://github.com/annuu005/cogdoc.git. Knowledge Extraction Structured Knowledge Representation Large Language Models Legal Document Analysis Explainable AI Semantic Retrieval Full Text Additional Declarations No competing interests reported. Cite Share Download PDF Status: Posted Version 1 posted You are reading this latest preprint version Research Square lets you share your work early, gain feedback from the community, and start making changes to your manuscript prior to peer review in a journal. As a division of Research Square Company, we’re committed to making research communication faster, fairer, and more useful. We do this by developing innovative software and high quality services for the global research community. Our growing team is made up of researchers and industry professionals working together to solve the most critical problems facing scientific publishing. Also discoverable on Platform About Our Team In Review Editorial Policies Advisory Board Help Center Resources Author Services Accessibility API Access RSS feed Manage Cookie Preferences © Research Square 2026 | ISSN 2693-5015 (online) Privacy Policy Terms of Service Do Not Sell My Personal Information {"props":{"pageProps":{"initialData":{"identity":"rs-9495012","acceptedTermsAndConditions":true,"allowDirectSubmit":false,"archivedVersions":[],"articleType":"Research Article","associatedPublications":[],"authors":[{"id":628720093,"identity":"34b19794-d1b7-40be-9b5b-eace11e6d959","order_by":0,"name":"Veerababu Reddy","email":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAZAAAAAyAQMAAABI0h/eAAAABlBMVEX///8AAABVwtN+AAAACXBIWXMAAA7EAAAOxAGVKw4bAAABHklEQVRIie3RMWuDQBTA8SeCLgZXhWK+womQDKX4VU6Ezo4dMpwIdpHMfoxMLdkMD5JF6OrgYBFculgCKYUQehYCQkylW6H3H94dx/tNByAS/d0yIN1R8amDxHrvY4QSAib7HeEH+WHtu3nqb+qHRTmdG1QxaHB0ncKP3oJFCfpjJmFwSW6Ke9/Ot429TjtCiPdUePFtum3AyClgekkMLZ+ZTEFpVVCZcEJn+SZ2NAUBCgDUhsjLxyc7oXsmrpN05IQwvUbURJHCGD1OpIoTaaWGUT2JEchVEjtmuGz8dVJ1xPHSXRjLkyVqdu6xQSLLr+/sUN49qxSy9mi5eqTWe+2AlrVD3A+QXnp7vikGH3y596djye34jkgkEv2jvgAni21Z0IDXAQAAAABJRU5ErkJggg==","orcid":"","institution":"Vignan's Lara Institute of Technology and Science","correspondingAuthor":true,"prefix":"","firstName":"Veerababu","middleName":"","lastName":"Reddy","suffix":""},{"id":628720094,"identity":"18ff9ff7-eb3a-4be5-bad9-57c906c7a53e","order_by":1,"name":"Pravallika Bhosale","email":"","orcid":"","institution":"Vignan's Lara Institute of Technology and Science","correspondingAuthor":false,"prefix":"","firstName":"Pravallika","middleName":"","lastName":"Bhosale","suffix":""},{"id":628720095,"identity":"ee7c1b2a-2a2b-4cea-ae9d-862cf953011e","order_by":2,"name":"Sreeja Alle","email":"","orcid":"","institution":"Vignan's Lara Institute of Technology and Science","correspondingAuthor":false,"prefix":"","firstName":"Sreeja","middleName":"","lastName":"Alle","suffix":""},{"id":628720096,"identity":"e8e7b5d8-123b-440c-981f-baafb07689e8","order_by":3,"name":"Anees Abdul","email":"","orcid":"","institution":"Vignan's Lara Institute of Technology and Science","correspondingAuthor":false,"prefix":"","firstName":"Anees","middleName":"","lastName":"Abdul","suffix":""},{"id":628720097,"identity":"92f2ffc2-e395-40d4-a603-9a4f51fcd928","order_by":4,"name":"Purna Chandu Repana","email":"","orcid":"","institution":"Vignan's Lara Institute of Technology and Science","correspondingAuthor":false,"prefix":"","firstName":"Purna","middleName":"Chandu","lastName":"Repana","suffix":""},{"id":628720098,"identity":"c59cd524-bdba-43ad-b5ff-df44f1cd18e9","order_by":5,"name":"Sri Vardhini Nidamanuri","email":"","orcid":"","institution":"Vignan's Lara Institute of Technology and Science","correspondingAuthor":false,"prefix":"","firstName":"Sri","middleName":"Vardhini","lastName":"Nidamanuri","suffix":""}],"badges":[],"createdAt":"2026-04-22 10:40:59","currentVersionCode":1,"declarations":"","doi":"10.21203/rs.3.rs-9495012/v1","doiUrl":"https://doi.org/10.21203/rs.3.rs-9495012/v1","draftVersion":[],"editorialEvents":[],"editorialNote":"","failedWorkflow":false,"files":[{"id":107854651,"identity":"3dd94142-0e93-46cb-abf4-b6ec82561b83","added_by":"auto","created_at":"2026-04-27 03:25:13","extension":"pdf","order_by":1,"title":"","display":"","copyAsset":false,"role":"manuscript-pdf","size":982566,"visible":true,"origin":"","legend":"","description":"","filename":"snarticletemplate.pdf","url":"https://assets-eu.researchsquare.com/files/rs-9495012/v1_covered_49e5bb78-8f48-462b-8ac1-968d64a625ca.pdf"}],"financialInterests":"No competing interests reported.","formattedTitle":"CogDoc: A Knowledge Centric Multi Model LLM for Clause Level Extraction, Structured Representation, and Consistency Reasoning over Legal and Policy Documents","fulltext":[],"fulltextSource":"","fullText":"","funders":[],"hasAdminPriorityOnWorkflow":false,"hasManuscriptDocX":false,"hasOptedInToPreprint":true,"hasPassedJournalQc":"","hasAnyPriority":true,"hideJournal":true,"highlight":"","institution":"","isAcceptedByJournal":false,"isAuthorSuppliedPdf":true,"isDeskRejected":"","isHiddenFromSearch":false,"isInQc":false,"isInWorkflow":false,"isPdf":true,"isPdfUpToDate":true,"isWithdrawnOrRetracted":false,"journal":{"display":true,"email":"[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true},"keywords":"Knowledge Extraction, Structured Knowledge Representation, Large Language Models, Legal Document Analysis, Explainable AI, Semantic Retrieval","lastPublishedDoi":"10.21203/rs.3.rs-9495012/v1","lastPublishedDoiUrl":"https://doi.org/10.21203/rs.3.rs-9495012/v1","license":{"name":"CC BY 4.0","url":"https://creativecommons.org/licenses/by/4.0/"},"manuscriptAbstract":"\u003cp\u003eLegal and policy documents are central to organizational governance, regulatory compliance, and contractual decision making, but their length, dense terminology, and complex cross clause dependencies make manual review slow and error prone. Although large language models (LLMs) have improved automated text understanding, most existing systems handle clause extraction, risk identification, and consistency checking as separate tasks. This piecemeal design fails to produce a unified, queryable knowledge representation of the analyzed corpus, restricts document level reasoning, and offers little support for downstream reuse. Cloud based deployment also raises confidentiality concerns, while the limited interpretability of monolithic models reduces user trust. This paper presents CogDoc, a knowledge centric system that combines multi model LLM analysis with a structured knowledge representation layer for coordinated legal document understanding. Three specialized models work over shared semantic embeddings: a LLaMA based model for clause interpretation, a Mistral based model for contextual risk scoring, and a DeBERTa based model for cross clause entailment and contradiction detection. The extracted clauses, risk annotations, and inferred relations are stored in an indexed repository that supports both relational and vector based retrieval, enabling efficient querying and knowledge reuse. An explainability module attaches evidence grounded reasoning to each stored result, and the system runs entirely offline to protect sensitive data. On five benchmarks LEDGAR, CUAD, ContractNLI, BillSum, ILDC, CogDoc achieves 92.4% F1 in clause extraction, 89.7% F1 in risk classification, and 91.2% precision in consistency detection, outperforming traditional, transformer based, and standalone LLM baselines. DOI for code and datasets: https://doi.org/10.5281/zenodo.19239518, GitHub repository link: https://github.com/annuu005/cogdoc.git.\u003c/p\u003e","manuscriptTitle":"CogDoc: A Knowledge Centric Multi Model LLM for Clause Level Extraction, Structured Representation, and Consistency Reasoning over Legal and Policy Documents","msid":"","msnumber":"","nonDraftVersions":[{"code":1,"date":"2026-04-27 03:24:07","doi":"10.21203/rs.3.rs-9495012/v1","editorialEvents":[{"type":"communityComments","content":0}],"status":"published","journal":{"display":true,"email":"[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true}}],"origin":"","ownerIdentity":"b3988f64-c7aa-4c86-bd18-1685f20b5173","owner":[],"postedDate":"April 27th, 2026","published":true,"recentEditorialEvents":[],"rejectedJournal":[],"revision":"","amendment":"","status":"posted","subjectAreas":[],"tags":[],"updatedAt":"2026-04-27T03:24:07+00:00","versionOfRecord":[],"versionCreatedAt":"2026-04-27 03:24:07","video":"","vorDoi":"","vorDoiUrl":"","workflowStages":[]},"version":"v1","identity":"rs-9495012","journalConfig":"researchsquare"},"__N_SSP":true},"page":"/article/[identity]/[[...version]]","query":{"redirect":"/article/rs-9495012","identity":"rs-9495012","version":["v1"]},"buildId":"XKTyCvWXoU3ODBz1xrDgd","isFallback":false,"isExperimentalCompile":false,"dynamicIds":[84888],"gssp":true,"scriptLoader":[]}

Text is read by the "Ask this paper" AI Q&A widget below. Extraction quality varies by source — PMC NXML preserves structure cleanly, OA-HTML may include some navigation residue, and OA-PDF can have broken hyphenation. The publisher copy (via DOI) is the canonical version.

My notes (saved in your browser only)

Ask this paper AI returns verbatim quotes from the full text · source: preprint-html

Answers must be backed by verbatim quotes from this paper's full text. Hallucinated quotes are dropped automatically; if no verbatim passage answers the question, we say so. How this works

Citation neighborhood (no data yet)

We don't have any in-corpus citations linked to this paper yet. This is a recent paper (2026) — citers typically take a year or two to land, and the OpenAlex reference graph may still be filling in.

Source provenance

europepmc
last seen: 2026-05-20T01:45:00.602351+00:00
unpaywall
last seen: 2026-05-23T02:00:01.238055+00:00
License: CC-BY-4.0