@ansvar/india-law-mcp 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +190 -0
- package/README.md +404 -0
- package/data/database.db +0 -0
- package/dist/capabilities.d.ts +16 -0
- package/dist/capabilities.d.ts.map +1 -0
- package/dist/capabilities.js +45 -0
- package/dist/capabilities.js.map +1 -0
- package/dist/citation/formatter.d.ts +11 -0
- package/dist/citation/formatter.d.ts.map +1 -0
- package/dist/citation/formatter.js +35 -0
- package/dist/citation/formatter.js.map +1 -0
- package/dist/citation/parser.d.ts +12 -0
- package/dist/citation/parser.d.ts.map +1 -0
- package/dist/citation/parser.js +69 -0
- package/dist/citation/parser.js.map +1 -0
- package/dist/citation/validator.d.ts +10 -0
- package/dist/citation/validator.d.ts.map +1 -0
- package/dist/citation/validator.js +74 -0
- package/dist/citation/validator.js.map +1 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +83 -0
- package/dist/index.js.map +1 -0
- package/dist/tools/about.d.ts +35 -0
- package/dist/tools/about.d.ts.map +1 -0
- package/dist/tools/about.js +51 -0
- package/dist/tools/about.js.map +1 -0
- package/dist/tools/build-legal-stance.d.ts +29 -0
- package/dist/tools/build-legal-stance.d.ts.map +1 -0
- package/dist/tools/build-legal-stance.js +54 -0
- package/dist/tools/build-legal-stance.js.map +1 -0
- package/dist/tools/check-currency.d.ts +23 -0
- package/dist/tools/check-currency.d.ts.map +1 -0
- package/dist/tools/check-currency.js +49 -0
- package/dist/tools/check-currency.js.map +1 -0
- package/dist/tools/format-citation.d.ts +18 -0
- package/dist/tools/format-citation.d.ts.map +1 -0
- package/dist/tools/format-citation.js +38 -0
- package/dist/tools/format-citation.js.map +1 -0
- package/dist/tools/get-eu-basis.d.ts +26 -0
- package/dist/tools/get-eu-basis.d.ts.map +1 -0
- package/dist/tools/get-eu-basis.js +69 -0
- package/dist/tools/get-eu-basis.js.map +1 -0
- package/dist/tools/get-indian-implementations.d.ts +25 -0
- package/dist/tools/get-indian-implementations.d.ts.map +1 -0
- package/dist/tools/get-indian-implementations.js +48 -0
- package/dist/tools/get-indian-implementations.js.map +1 -0
- package/dist/tools/get-provision-eu-basis.d.ts +18 -0
- package/dist/tools/get-provision-eu-basis.d.ts.map +1 -0
- package/dist/tools/get-provision-eu-basis.js +55 -0
- package/dist/tools/get-provision-eu-basis.js.map +1 -0
- package/dist/tools/get-provision.d.ts +28 -0
- package/dist/tools/get-provision.d.ts.map +1 -0
- package/dist/tools/get-provision.js +74 -0
- package/dist/tools/get-provision.js.map +1 -0
- package/dist/tools/list-sources.d.ts +29 -0
- package/dist/tools/list-sources.d.ts.map +1 -0
- package/dist/tools/list-sources.js +78 -0
- package/dist/tools/list-sources.js.map +1 -0
- package/dist/tools/registry.d.ts +13 -0
- package/dist/tools/registry.d.ts.map +1 -0
- package/dist/tools/registry.js +398 -0
- package/dist/tools/registry.js.map +1 -0
- package/dist/tools/search-eu-implementations.d.ts +32 -0
- package/dist/tools/search-eu-implementations.d.ts.map +1 -0
- package/dist/tools/search-eu-implementations.js +63 -0
- package/dist/tools/search-eu-implementations.js.map +1 -0
- package/dist/tools/search-legislation.d.ts +24 -0
- package/dist/tools/search-legislation.d.ts.map +1 -0
- package/dist/tools/search-legislation.js +60 -0
- package/dist/tools/search-legislation.js.map +1 -0
- package/dist/tools/validate-citation.d.ts +20 -0
- package/dist/tools/validate-citation.d.ts.map +1 -0
- package/dist/tools/validate-citation.js +37 -0
- package/dist/tools/validate-citation.js.map +1 -0
- package/dist/tools/validate-eu-compliance.d.ts +20 -0
- package/dist/tools/validate-eu-compliance.d.ts.map +1 -0
- package/dist/tools/validate-eu-compliance.js +63 -0
- package/dist/tools/validate-eu-compliance.js.map +1 -0
- package/dist/types/citations.d.ts +21 -0
- package/dist/types/citations.d.ts.map +1 -0
- package/dist/types/citations.js +2 -0
- package/dist/types/citations.js.map +1 -0
- package/dist/types/documents.d.ts +16 -0
- package/dist/types/documents.d.ts.map +1 -0
- package/dist/types/documents.js +2 -0
- package/dist/types/documents.js.map +1 -0
- package/dist/types/eu-references.d.ts +54 -0
- package/dist/types/eu-references.d.ts.map +1 -0
- package/dist/types/eu-references.js +2 -0
- package/dist/types/eu-references.js.map +1 -0
- package/dist/types/index.d.ts +5 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +2 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/provisions.d.ts +18 -0
- package/dist/types/provisions.d.ts.map +1 -0
- package/dist/types/provisions.js +2 -0
- package/dist/types/provisions.js.map +1 -0
- package/dist/utils/as-of-date.d.ts +2 -0
- package/dist/utils/as-of-date.d.ts.map +1 -0
- package/dist/utils/as-of-date.js +23 -0
- package/dist/utils/as-of-date.js.map +1 -0
- package/dist/utils/fts-query.d.ts +13 -0
- package/dist/utils/fts-query.d.ts.map +1 -0
- package/dist/utils/fts-query.js +56 -0
- package/dist/utils/fts-query.js.map +1 -0
- package/dist/utils/metadata.d.ts +15 -0
- package/dist/utils/metadata.d.ts.map +1 -0
- package/dist/utils/metadata.js +29 -0
- package/dist/utils/metadata.js.map +1 -0
- package/dist/utils/statute-id.d.ts +13 -0
- package/dist/utils/statute-id.d.ts.map +1 -0
- package/dist/utils/statute-id.js +69 -0
- package/dist/utils/statute-id.js.map +1 -0
- package/package.json +82 -0
|
@@ -0,0 +1,398 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tool registry for India Law MCP Server.
|
|
3
|
+
* Shared between stdio (index.ts) and HTTP (api/mcp.ts) entry points.
|
|
4
|
+
*/
|
|
5
|
+
import { CallToolRequestSchema, ListToolsRequestSchema, } from '@modelcontextprotocol/sdk/types.js';
|
|
6
|
+
import { searchLegislation } from './search-legislation.js';
|
|
7
|
+
import { getProvision } from './get-provision.js';
|
|
8
|
+
import { listSources } from './list-sources.js';
|
|
9
|
+
import { validateCitationTool } from './validate-citation.js';
|
|
10
|
+
import { buildLegalStance } from './build-legal-stance.js';
|
|
11
|
+
import { formatCitationTool } from './format-citation.js';
|
|
12
|
+
import { checkCurrency } from './check-currency.js';
|
|
13
|
+
import { getEUBasis } from './get-eu-basis.js';
|
|
14
|
+
import { getIndianImplementations } from './get-indian-implementations.js';
|
|
15
|
+
import { searchEUImplementations } from './search-eu-implementations.js';
|
|
16
|
+
import { getProvisionEUBasis } from './get-provision-eu-basis.js';
|
|
17
|
+
import { validateEUCompliance } from './validate-eu-compliance.js';
|
|
18
|
+
import { getAbout } from './about.js';
|
|
19
|
+
const ABOUT_TOOL = {
|
|
20
|
+
name: 'about',
|
|
21
|
+
description: 'Server metadata, dataset statistics, freshness, and provenance. ' +
|
|
22
|
+
'Call this to verify data coverage, currency, and content basis before relying on results.',
|
|
23
|
+
inputSchema: { type: 'object', properties: {} },
|
|
24
|
+
};
|
|
25
|
+
export const TOOLS = [
|
|
26
|
+
{
|
|
27
|
+
name: 'search_legislation',
|
|
28
|
+
description: 'Search Indian statutes, rules, and directions by keyword. Returns provision-level results with BM25 relevance ranking. ' +
|
|
29
|
+
'Supports natural language queries (e.g., "data protection rights") and FTS5 syntax (AND, OR, NOT, "phrase", prefix*). ' +
|
|
30
|
+
'Results include: document ID, title, provision reference, snippet with >>>highlight<<< markers, and relevance score. ' +
|
|
31
|
+
'Use document_id to filter within a single statute. Use status to filter by in_force/amended/repealed. ' +
|
|
32
|
+
'Default limit is 10 (max 50). For broad legal research, prefer build_legal_stance instead.',
|
|
33
|
+
inputSchema: {
|
|
34
|
+
type: 'object',
|
|
35
|
+
properties: {
|
|
36
|
+
query: {
|
|
37
|
+
type: 'string',
|
|
38
|
+
description: 'Search query in English or Hindi. Supports natural language or FTS5 syntax (AND, OR, NOT, "phrase", prefix*). Example: "personal data" OR "data fiduciary"',
|
|
39
|
+
},
|
|
40
|
+
document_id: {
|
|
41
|
+
type: 'string',
|
|
42
|
+
description: 'Filter to a specific statute by ID (e.g., "act-22-2023") or title (e.g., "Digital Personal Data Protection Act, 2023")',
|
|
43
|
+
},
|
|
44
|
+
status: {
|
|
45
|
+
type: 'string',
|
|
46
|
+
enum: ['in_force', 'amended', 'repealed'],
|
|
47
|
+
description: 'Filter by legislative status. Omit to search all statuses.',
|
|
48
|
+
},
|
|
49
|
+
limit: {
|
|
50
|
+
type: 'number',
|
|
51
|
+
description: 'Maximum results to return (default: 10, max: 50). Lower values save tokens.',
|
|
52
|
+
default: 10,
|
|
53
|
+
minimum: 1,
|
|
54
|
+
maximum: 50,
|
|
55
|
+
},
|
|
56
|
+
},
|
|
57
|
+
required: ['query'],
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
name: 'get_provision',
|
|
62
|
+
description: 'Retrieve the full text of a specific provision (section) from an Indian statute, or all provisions for a statute if no section is specified. ' +
|
|
63
|
+
'Indian provisions use section notation: s4, s43A, s66(1). Pass document_id as either the internal ID (e.g., "act-22-2023") ' +
|
|
64
|
+
'or the human-readable title (e.g., "Digital Personal Data Protection Act, 2023"). ' +
|
|
65
|
+
'Returns: document ID, title, status, provision reference, chapter, section, title, and full content text. ' +
|
|
66
|
+
'Note: Indian Acts may use alphanumeric section numbers (e.g., 43A, 66A). ' +
|
|
67
|
+
'WARNING: Omitting section/provision_ref returns ALL provisions (capped at 200) for the statute.',
|
|
68
|
+
inputSchema: {
|
|
69
|
+
type: 'object',
|
|
70
|
+
properties: {
|
|
71
|
+
document_id: {
|
|
72
|
+
type: 'string',
|
|
73
|
+
description: 'Statute identifier (e.g., "act-22-2023") or title (e.g., "Digital Personal Data Protection Act, 2023"). Fuzzy title matching is supported.',
|
|
74
|
+
},
|
|
75
|
+
section: {
|
|
76
|
+
type: 'string',
|
|
77
|
+
description: 'Section number (e.g., "4", "43A", "66(1)"). Matched against provision_ref and section columns.',
|
|
78
|
+
},
|
|
79
|
+
provision_ref: {
|
|
80
|
+
type: 'string',
|
|
81
|
+
description: 'Direct provision reference (e.g., "s4", "s43A"). Takes precedence over section if both provided.',
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
required: ['document_id'],
|
|
85
|
+
},
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
name: 'list_sources',
|
|
89
|
+
description: 'Returns metadata about all data sources backing this server, including jurisdiction, authoritative source details, ' +
|
|
90
|
+
'database tier, schema version, build date, record counts, and known limitations. ' +
|
|
91
|
+
'Call this first to understand data coverage and freshness before relying on other tools.',
|
|
92
|
+
inputSchema: {
|
|
93
|
+
type: 'object',
|
|
94
|
+
properties: {},
|
|
95
|
+
},
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
name: 'validate_citation',
|
|
99
|
+
description: 'Validate an Indian legal citation against the database. Returns whether the cited statute and provision exist. ' +
|
|
100
|
+
'Use this as a zero-hallucination check before presenting legal references to users. ' +
|
|
101
|
+
'Supported formats: "Section 4, Digital Personal Data Protection Act, 2023", "s. 43A, Information Technology Act, 2000", "S. 66 IT Act 2000". ' +
|
|
102
|
+
'Returns: valid (boolean), parsed components, warnings about repealed/amended status.',
|
|
103
|
+
inputSchema: {
|
|
104
|
+
type: 'object',
|
|
105
|
+
properties: {
|
|
106
|
+
citation: {
|
|
107
|
+
type: 'string',
|
|
108
|
+
description: 'Indian legal citation to validate. Examples: "Section 4, Digital Personal Data Protection Act, 2023", "s. 43A IT Act 2000"',
|
|
109
|
+
},
|
|
110
|
+
},
|
|
111
|
+
required: ['citation'],
|
|
112
|
+
},
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
name: 'build_legal_stance',
|
|
116
|
+
description: 'Build a comprehensive set of citations for a legal question by searching across all Indian statutes simultaneously. ' +
|
|
117
|
+
'Returns aggregated results from legislation search, cross-referenced with EU/international law where applicable. ' +
|
|
118
|
+
'Best for broad legal research questions like "What Indian laws govern personal data processing?" ' +
|
|
119
|
+
'For targeted lookups of a known provision, use get_provision instead.',
|
|
120
|
+
inputSchema: {
|
|
121
|
+
type: 'object',
|
|
122
|
+
properties: {
|
|
123
|
+
query: {
|
|
124
|
+
type: 'string',
|
|
125
|
+
description: 'Legal question or topic to research (e.g., "personal data processing obligations in India")',
|
|
126
|
+
},
|
|
127
|
+
document_id: {
|
|
128
|
+
type: 'string',
|
|
129
|
+
description: 'Optionally limit search to one statute by ID or title',
|
|
130
|
+
},
|
|
131
|
+
limit: {
|
|
132
|
+
type: 'number',
|
|
133
|
+
description: 'Max results per category (default: 5, max: 20)',
|
|
134
|
+
default: 5,
|
|
135
|
+
minimum: 1,
|
|
136
|
+
maximum: 20,
|
|
137
|
+
},
|
|
138
|
+
},
|
|
139
|
+
required: ['query'],
|
|
140
|
+
},
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
name: 'format_citation',
|
|
144
|
+
description: 'Format an Indian legal citation per standard legal conventions. ' +
|
|
145
|
+
'Formats: "full" → "Section 4, Digital Personal Data Protection Act, 2023", ' +
|
|
146
|
+
'"short" → "s. 4 DPDPA 2023", "pinpoint" → "s. 4". ' +
|
|
147
|
+
'Does NOT validate existence — use validate_citation for that.',
|
|
148
|
+
inputSchema: {
|
|
149
|
+
type: 'object',
|
|
150
|
+
properties: {
|
|
151
|
+
citation: {
|
|
152
|
+
type: 'string',
|
|
153
|
+
description: 'Citation string to format (e.g., "s. 4 DPDPA 2023")',
|
|
154
|
+
},
|
|
155
|
+
format: {
|
|
156
|
+
type: 'string',
|
|
157
|
+
enum: ['full', 'short', 'pinpoint'],
|
|
158
|
+
description: 'Output format. "full" (default): formal citation. "short": abbreviated. "pinpoint": section reference only.',
|
|
159
|
+
default: 'full',
|
|
160
|
+
},
|
|
161
|
+
},
|
|
162
|
+
required: ['citation'],
|
|
163
|
+
},
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
name: 'check_currency',
|
|
167
|
+
description: 'Check whether an Indian statute or provision is currently in force, amended, or repealed. ' +
|
|
168
|
+
'Returns: is_current (boolean), status, dates (issued, in-force), and warnings. ' +
|
|
169
|
+
'Essential before citing legislation — repealed acts should not be cited as current law.',
|
|
170
|
+
inputSchema: {
|
|
171
|
+
type: 'object',
|
|
172
|
+
properties: {
|
|
173
|
+
document_id: {
|
|
174
|
+
type: 'string',
|
|
175
|
+
description: 'Statute identifier (e.g., "act-22-2023") or title (e.g., "Digital Personal Data Protection Act, 2023")',
|
|
176
|
+
},
|
|
177
|
+
provision_ref: {
|
|
178
|
+
type: 'string',
|
|
179
|
+
description: 'Optional provision reference to check a specific section (e.g., "s4")',
|
|
180
|
+
},
|
|
181
|
+
},
|
|
182
|
+
required: ['document_id'],
|
|
183
|
+
},
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
name: 'get_eu_basis',
|
|
187
|
+
description: 'Get EU/international legal basis for an Indian statute. Returns all EU instruments that the Indian statute ' +
|
|
188
|
+
'is modelled on, equivalent to, or references, including CELEX numbers and equivalence status. ' +
|
|
189
|
+
'Useful for understanding GDPR-DPDPA, NIS2-IT Act, and other cross-jurisdictional relationships. ' +
|
|
190
|
+
'Example: DPDPA 2023 → equivalent to GDPR (Regulation 2016/679).',
|
|
191
|
+
inputSchema: {
|
|
192
|
+
type: 'object',
|
|
193
|
+
properties: {
|
|
194
|
+
document_id: {
|
|
195
|
+
type: 'string',
|
|
196
|
+
description: 'Indian statute identifier (e.g., "act-22-2023") or title (e.g., "Digital Personal Data Protection Act, 2023")',
|
|
197
|
+
},
|
|
198
|
+
include_articles: {
|
|
199
|
+
type: 'boolean',
|
|
200
|
+
description: 'Include specific EU article references in the response (default: false)',
|
|
201
|
+
default: false,
|
|
202
|
+
},
|
|
203
|
+
reference_types: {
|
|
204
|
+
type: 'array',
|
|
205
|
+
items: {
|
|
206
|
+
type: 'string',
|
|
207
|
+
enum: ['implements', 'supplements', 'applies', 'references', 'complies_with', 'equivalent_to', 'derogates_from', 'amended_by', 'repealed_by', 'cites_article'],
|
|
208
|
+
},
|
|
209
|
+
description: 'Filter by reference type (e.g., ["equivalent_to"]). Omit to return all types.',
|
|
210
|
+
},
|
|
211
|
+
},
|
|
212
|
+
required: ['document_id'],
|
|
213
|
+
},
|
|
214
|
+
},
|
|
215
|
+
{
|
|
216
|
+
name: 'get_indian_implementations',
|
|
217
|
+
description: 'Find Indian statutes that implement or are equivalent to a specific EU directive or regulation. ' +
|
|
218
|
+
'Input the EU document ID in "type:year/number" format (e.g., "regulation:2016/679" for GDPR). ' +
|
|
219
|
+
'Returns matching Indian statutes with equivalence status and whether each is the primary equivalent.',
|
|
220
|
+
inputSchema: {
|
|
221
|
+
type: 'object',
|
|
222
|
+
properties: {
|
|
223
|
+
eu_document_id: {
|
|
224
|
+
type: 'string',
|
|
225
|
+
description: 'EU document ID in format "type:year/number" (e.g., "regulation:2016/679" for GDPR)',
|
|
226
|
+
},
|
|
227
|
+
primary_only: {
|
|
228
|
+
type: 'boolean',
|
|
229
|
+
description: 'Return only primary equivalent statutes (default: false)',
|
|
230
|
+
default: false,
|
|
231
|
+
},
|
|
232
|
+
in_force_only: {
|
|
233
|
+
type: 'boolean',
|
|
234
|
+
description: 'Return only statutes currently in force (default: false)',
|
|
235
|
+
default: false,
|
|
236
|
+
},
|
|
237
|
+
},
|
|
238
|
+
required: ['eu_document_id'],
|
|
239
|
+
},
|
|
240
|
+
},
|
|
241
|
+
{
|
|
242
|
+
name: 'search_eu_implementations',
|
|
243
|
+
description: 'Search for EU directives and regulations that have Indian equivalents or cross-references. ' +
|
|
244
|
+
'Search by keyword (e.g., "data protection", "cybersecurity"), filter by type (directive/regulation), ' +
|
|
245
|
+
'or year range. Returns EU documents with counts of Indian statutes referencing them.',
|
|
246
|
+
inputSchema: {
|
|
247
|
+
type: 'object',
|
|
248
|
+
properties: {
|
|
249
|
+
query: {
|
|
250
|
+
type: 'string',
|
|
251
|
+
description: 'Keyword search across EU document titles and short names (e.g., "data protection")',
|
|
252
|
+
},
|
|
253
|
+
type: {
|
|
254
|
+
type: 'string',
|
|
255
|
+
enum: ['directive', 'regulation'],
|
|
256
|
+
description: 'Filter by EU document type',
|
|
257
|
+
},
|
|
258
|
+
year_from: { type: 'number', description: 'Filter: EU documents from this year onwards' },
|
|
259
|
+
year_to: { type: 'number', description: 'Filter: EU documents up to this year' },
|
|
260
|
+
has_indian_implementation: {
|
|
261
|
+
type: 'boolean',
|
|
262
|
+
description: 'If true, only return EU documents that have at least one Indian equivalent statute',
|
|
263
|
+
},
|
|
264
|
+
limit: {
|
|
265
|
+
type: 'number',
|
|
266
|
+
description: 'Max results (default: 20, max: 100)',
|
|
267
|
+
default: 20,
|
|
268
|
+
minimum: 1,
|
|
269
|
+
maximum: 100,
|
|
270
|
+
},
|
|
271
|
+
},
|
|
272
|
+
},
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
name: 'get_provision_eu_basis',
|
|
276
|
+
description: 'Get EU/international legal basis for a specific provision within an Indian statute, with article-level precision. ' +
|
|
277
|
+
'Example: DPDPA 2023 s4 → references GDPR Article 6. ' +
|
|
278
|
+
'Use this for pinpoint cross-jurisdictional comparison at the provision level.',
|
|
279
|
+
inputSchema: {
|
|
280
|
+
type: 'object',
|
|
281
|
+
properties: {
|
|
282
|
+
document_id: {
|
|
283
|
+
type: 'string',
|
|
284
|
+
description: 'Indian statute identifier (e.g., "act-22-2023") or title',
|
|
285
|
+
},
|
|
286
|
+
provision_ref: {
|
|
287
|
+
type: 'string',
|
|
288
|
+
description: 'Provision reference (e.g., "s4", "s43A")',
|
|
289
|
+
},
|
|
290
|
+
},
|
|
291
|
+
required: ['document_id', 'provision_ref'],
|
|
292
|
+
},
|
|
293
|
+
},
|
|
294
|
+
{
|
|
295
|
+
name: 'validate_eu_compliance',
|
|
296
|
+
description: 'Check EU/international equivalence status for an Indian statute or provision. Detects references to EU directives, ' +
|
|
297
|
+
'identifies equivalent provisions, and flags gaps. Returns compliance status: compliant, partial, unclear, or not_applicable. ' +
|
|
298
|
+
'Note: India does not have a GDPR adequacy decision; this tool assesses structural equivalence only.',
|
|
299
|
+
inputSchema: {
|
|
300
|
+
type: 'object',
|
|
301
|
+
properties: {
|
|
302
|
+
document_id: {
|
|
303
|
+
type: 'string',
|
|
304
|
+
description: 'Indian statute identifier (e.g., "act-22-2023") or title',
|
|
305
|
+
},
|
|
306
|
+
provision_ref: {
|
|
307
|
+
type: 'string',
|
|
308
|
+
description: 'Optional: check a specific provision (e.g., "s4")',
|
|
309
|
+
},
|
|
310
|
+
eu_document_id: {
|
|
311
|
+
type: 'string',
|
|
312
|
+
description: 'Optional: check equivalence with a specific EU document (e.g., "regulation:2016/679")',
|
|
313
|
+
},
|
|
314
|
+
},
|
|
315
|
+
required: ['document_id'],
|
|
316
|
+
},
|
|
317
|
+
},
|
|
318
|
+
];
|
|
319
|
+
export function buildTools(context) {
|
|
320
|
+
return context ? [...TOOLS, ABOUT_TOOL] : TOOLS;
|
|
321
|
+
}
|
|
322
|
+
export function registerTools(server, db, context) {
|
|
323
|
+
const allTools = buildTools(context);
|
|
324
|
+
server.setRequestHandler(ListToolsRequestSchema, async () => {
|
|
325
|
+
return { tools: allTools };
|
|
326
|
+
});
|
|
327
|
+
server.setRequestHandler(CallToolRequestSchema, async (request) => {
|
|
328
|
+
const { name, arguments: args } = request.params;
|
|
329
|
+
try {
|
|
330
|
+
let result;
|
|
331
|
+
switch (name) {
|
|
332
|
+
case 'search_legislation':
|
|
333
|
+
result = await searchLegislation(db, args);
|
|
334
|
+
break;
|
|
335
|
+
case 'get_provision':
|
|
336
|
+
result = await getProvision(db, args);
|
|
337
|
+
break;
|
|
338
|
+
case 'list_sources':
|
|
339
|
+
result = await listSources(db);
|
|
340
|
+
break;
|
|
341
|
+
case 'validate_citation':
|
|
342
|
+
result = await validateCitationTool(db, args);
|
|
343
|
+
break;
|
|
344
|
+
case 'build_legal_stance':
|
|
345
|
+
result = await buildLegalStance(db, args);
|
|
346
|
+
break;
|
|
347
|
+
case 'format_citation':
|
|
348
|
+
result = await formatCitationTool(args);
|
|
349
|
+
break;
|
|
350
|
+
case 'check_currency':
|
|
351
|
+
result = await checkCurrency(db, args);
|
|
352
|
+
break;
|
|
353
|
+
case 'get_eu_basis':
|
|
354
|
+
result = await getEUBasis(db, args);
|
|
355
|
+
break;
|
|
356
|
+
case 'get_indian_implementations':
|
|
357
|
+
result = await getIndianImplementations(db, args);
|
|
358
|
+
break;
|
|
359
|
+
case 'search_eu_implementations':
|
|
360
|
+
result = await searchEUImplementations(db, args);
|
|
361
|
+
break;
|
|
362
|
+
case 'get_provision_eu_basis':
|
|
363
|
+
result = await getProvisionEUBasis(db, args);
|
|
364
|
+
break;
|
|
365
|
+
case 'validate_eu_compliance':
|
|
366
|
+
result = await validateEUCompliance(db, args);
|
|
367
|
+
break;
|
|
368
|
+
case 'about':
|
|
369
|
+
if (context) {
|
|
370
|
+
result = getAbout(db, context);
|
|
371
|
+
}
|
|
372
|
+
else {
|
|
373
|
+
return {
|
|
374
|
+
content: [{ type: 'text', text: 'About tool not configured.' }],
|
|
375
|
+
isError: true,
|
|
376
|
+
};
|
|
377
|
+
}
|
|
378
|
+
break;
|
|
379
|
+
default:
|
|
380
|
+
return {
|
|
381
|
+
content: [{ type: 'text', text: `Error: Unknown tool "${name}".` }],
|
|
382
|
+
isError: true,
|
|
383
|
+
};
|
|
384
|
+
}
|
|
385
|
+
return {
|
|
386
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
387
|
+
};
|
|
388
|
+
}
|
|
389
|
+
catch (error) {
|
|
390
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
391
|
+
return {
|
|
392
|
+
content: [{ type: 'text', text: `Error: ${message}` }],
|
|
393
|
+
isError: true,
|
|
394
|
+
};
|
|
395
|
+
}
|
|
396
|
+
});
|
|
397
|
+
}
|
|
398
|
+
//# sourceMappingURL=registry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"registry.js","sourceRoot":"","sources":["../../src/tools/registry.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,EACL,qBAAqB,EACrB,sBAAsB,GAEvB,MAAM,oCAAoC,CAAC;AAG5C,OAAO,EAAE,iBAAiB,EAA0B,MAAM,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C;oBACJ,CAAC;oBACD,MAAM;gBACR;oBACE,OAAO;wBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,wBAAwB,IAAI,IAAI,EAAE,CAAC;wBACnE,OAAO,EAAE,IAAI;qBACd,CAAC;YACN,CAAC;YAED,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC;aACnE,CAAC;QACJ,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,OAAO,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;YACvE,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,UAAU,OAAO,EAAE,EAAE,CAAC;gBACtD,OAAO,EAAE,IAAI;aACd,CAAC;QACJ,CAAC;IACH,CAAC,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* search_eu_implementations — Search EU directives/regulations with Indian implementation info.
|
|
3
|
+
*/
|
|
4
|
+
import type { Database } from '@ansvar/mcp-sqlite';
|
|
5
|
+
import { type ToolResponse } from '../utils/metadata.js';
|
|
6
|
+
export interface SearchEUImplementationsInput {
|
|
7
|
+
query?: string;
|
|
8
|
+
type?: 'directive' | 'regulation';
|
|
9
|
+
year_from?: number;
|
|
10
|
+
year_to?: number;
|
|
11
|
+
community?: string;
|
|
12
|
+
has_indian_implementation?: boolean;
|
|
13
|
+
limit?: number;
|
|
14
|
+
}
|
|
15
|
+
export interface SearchEUImplementationsResult {
|
|
16
|
+
results: Array<{
|
|
17
|
+
eu_document: {
|
|
18
|
+
id: string;
|
|
19
|
+
type: string;
|
|
20
|
+
year: number;
|
|
21
|
+
number: number;
|
|
22
|
+
title?: string;
|
|
23
|
+
short_name?: string;
|
|
24
|
+
community: string;
|
|
25
|
+
};
|
|
26
|
+
indian_statute_count: number;
|
|
27
|
+
primary_implementations: string[];
|
|
28
|
+
}>;
|
|
29
|
+
total_results: number;
|
|
30
|
+
}
|
|
31
|
+
export declare function searchEUImplementations(db: Database, input: SearchEUImplementationsInput): Promise<ToolResponse<SearchEUImplementationsResult>>;
|
|
32
|
+
//# sourceMappingURL=search-eu-implementations.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-eu-implementations.d.ts","sourceRoot":"","sources":["../../src/tools/search-eu-implementations.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAA4B,KAAK,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAEnF,MAAM,WAAW,4BAA4B;IAC3C,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,WAAW,GAAG,YAAY,CAAC;IAClC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,yBAAyB,CAAC,EAAE,OAAO,CAAC;IACpC,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,6BAA6B;IAC5C,OAAO,EAAE,KAAK,CAAC;QACb,WAAW,EAAE;YACX,EAAE,EAAE,MAAM,CAAC;YAAC,IAAI,EAAE,MAAM,CAAC;YAAC,IAAI,EAAE,MAAM,CAAC;YAAC,MAAM,EAAE,MAAM,CAAC;YACvD,KAAK,CAAC,EAAE,MAAM,CAAC;YAAC,UAAU,CAAC,EAAE,MAAM,CAAC;YAAC,SAAS,EAAE,MAAM,CAAC;SACxD,CAAC;QACF,oBAAoB,EAAE,MAAM,CAAC;QAC7B,uBAAuB,EAAE,MAAM,EAAE,CAAC;KACnC,CAAC,CAAC;IACH,aAAa,EAAE,MAAM,CAAC;CACvB;AAKD,wBAAsB,uBAAuB,CAC3C,EAAE,EAAE,QAAQ,EACZ,KAAK,EAAE,4BAA4B,GAClC,OAAO,CAAC,YAAY,CAAC,6BAA6B,CAAC,CAAC,CAwDtD"}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* search_eu_implementations — Search EU directives/regulations with Indian implementation info.
|
|
3
|
+
*/
|
|
4
|
+
import { generateResponseMetadata } from '../utils/metadata.js';
|
|
5
|
+
const DEFAULT_LIMIT = 20;
|
|
6
|
+
const MAX_LIMIT = 100;
|
|
7
|
+
export async function searchEUImplementations(db, input) {
|
|
8
|
+
const limit = Math.min(Math.max(input.limit ?? DEFAULT_LIMIT, 1), MAX_LIMIT);
|
|
9
|
+
let sql = `
|
|
10
|
+
SELECT
|
|
11
|
+
ed.id, ed.type, ed.year, ed.number, ed.title, ed.short_name, ed.community,
|
|
12
|
+
COUNT(DISTINCT er.document_id) AS indian_statute_count,
|
|
13
|
+
GROUP_CONCAT(DISTINCT CASE WHEN er.is_primary_implementation = 1 THEN er.document_id END) AS primary_implementations
|
|
14
|
+
FROM eu_documents ed
|
|
15
|
+
LEFT JOIN eu_references er ON ed.id = er.eu_document_id
|
|
16
|
+
WHERE 1=1
|
|
17
|
+
`;
|
|
18
|
+
const params = [];
|
|
19
|
+
if (input.query?.trim()) {
|
|
20
|
+
sql += ` AND (ed.title LIKE ? OR ed.short_name LIKE ? OR ed.celex_number LIKE ?)`;
|
|
21
|
+
const term = `%${input.query.trim()}%`;
|
|
22
|
+
params.push(term, term, term);
|
|
23
|
+
}
|
|
24
|
+
if (input.type) {
|
|
25
|
+
sql += ` AND ed.type = ?`;
|
|
26
|
+
params.push(input.type);
|
|
27
|
+
}
|
|
28
|
+
if (input.year_from) {
|
|
29
|
+
sql += ` AND ed.year >= ?`;
|
|
30
|
+
params.push(input.year_from);
|
|
31
|
+
}
|
|
32
|
+
if (input.year_to) {
|
|
33
|
+
sql += ` AND ed.year <= ?`;
|
|
34
|
+
params.push(input.year_to);
|
|
35
|
+
}
|
|
36
|
+
if (input.community) {
|
|
37
|
+
sql += ` AND ed.community = ?`;
|
|
38
|
+
params.push(input.community);
|
|
39
|
+
}
|
|
40
|
+
sql += ` GROUP BY ed.id`;
|
|
41
|
+
if (input.has_indian_implementation !== undefined) {
|
|
42
|
+
sql += input.has_indian_implementation ? ` HAVING indian_statute_count > 0` : ` HAVING indian_statute_count = 0`;
|
|
43
|
+
}
|
|
44
|
+
sql += ` ORDER BY ed.year DESC, ed.number DESC LIMIT ?`;
|
|
45
|
+
params.push(limit);
|
|
46
|
+
const rows = db.prepare(sql).all(...params);
|
|
47
|
+
return {
|
|
48
|
+
results: {
|
|
49
|
+
results: rows.map(r => ({
|
|
50
|
+
eu_document: {
|
|
51
|
+
id: r.id, type: r.type, year: r.year, number: r.number,
|
|
52
|
+
title: r.title || undefined, short_name: r.short_name || undefined,
|
|
53
|
+
community: r.community,
|
|
54
|
+
},
|
|
55
|
+
indian_statute_count: r.indian_statute_count,
|
|
56
|
+
primary_implementations: r.primary_implementations?.split(',').filter(Boolean) ?? [],
|
|
57
|
+
})),
|
|
58
|
+
total_results: rows.length,
|
|
59
|
+
},
|
|
60
|
+
_metadata: generateResponseMetadata(db),
|
|
61
|
+
};
|
|
62
|
+
}
|
|
63
|
+
//# sourceMappingURL=search-eu-implementations.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-eu-implementations.js","sourceRoot":"","sources":["../../src/tools/search-eu-implementations.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,EAAE,wBAAwB,EAAqB,MAAM,sBAAsB,CAAC;AAwBnF,MAAM,aAAa,GAAG,EAAE,CAAC;AACzB,MAAM,SAAS,GAAG,GAAG,CAAC;AAEtB,MAAM,CAAC,KAAK,UAAU,uBAAuB,CAC3C,EAAY,EACZ,KA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CAAC,CAAC,CAAC,kCAAkC,CAAC;IACnH,CAAC;IAED,GAAG,IAAI,gDAAgD,CAAC;IACxD,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;IAQnB,MAAM,IAAI,GAAG,EAAE,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,GAAG,MAAM,CAAU,CAAC;IAErD,OAAO;QACL,OAAO,EAAE;YACP,OAAO,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;gBACtB,WAAW,EAAE;oBACX,EAAE,EAAE,CAAC,CAAC,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,MAAM,EAAE,CAAC,CAAC,MAAM;oBACtD,KAAK,EAAE,CAAC,CAAC,KAAK,IAAI,SAAS,EAAE,UAAU,EAAE,CAAC,CAAC,UAAU,IAAI,SAAS;oBAClE,SAAS,EAAE,CAAC,CAAC,SAAS;iBACvB;gBACD,oBAAoB,EAAE,CAAC,CAAC,oBAAoB;gBAC5C,uBAAuB,EAAE,CAAC,CAAC,uBAAuB,EAAE,KAAK,CAAC,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,EAAE;aACrF,CAAC,CAAC;YACH,aAAa,EAAE,IAAI,CAAC,MAAM;SAC3B;QACD,SAAS,EAAE,wBAAwB,CAAC,EAAE,CAAC;KACxC,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* search_legislation — Full-text search across Indian statute provisions.
|
|
3
|
+
*/
|
|
4
|
+
import type { Database } from '@ansvar/mcp-sqlite';
|
|
5
|
+
import { type ToolResponse } from '../utils/metadata.js';
|
|
6
|
+
export interface SearchLegislationInput {
|
|
7
|
+
query: string;
|
|
8
|
+
document_id?: string;
|
|
9
|
+
status?: string;
|
|
10
|
+
as_of_date?: string;
|
|
11
|
+
limit?: number;
|
|
12
|
+
}
|
|
13
|
+
export interface SearchLegislationResult {
|
|
14
|
+
document_id: string;
|
|
15
|
+
document_title: string;
|
|
16
|
+
provision_ref: string;
|
|
17
|
+
chapter: string | null;
|
|
18
|
+
section: string;
|
|
19
|
+
title: string | null;
|
|
20
|
+
snippet: string;
|
|
21
|
+
relevance: number;
|
|
22
|
+
}
|
|
23
|
+
export declare function searchLegislation(db: Database, input: SearchLegislationInput): Promise<ToolResponse<SearchLegislationResult[]>>;
|
|
24
|
+
//# sourceMappingURL=search-legislation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-legislation.d.ts","sourceRoot":"","sources":["../../src/tools/search-legislation.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAGnD,OAAO,EAA4B,KAAK,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAEnF,MAAM,WAAW,sBAAsB;IACrC,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,uBAAuB;IACtC,WAAW,EAAE,MAAM,CAAC;IACpB,cAAc,EAAE,MAAM,CAAC;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;CACnB;AAKD,wBAAsB,iBAAiB,CACrC,EAAE,EAAE,QAAQ,EACZ,KAAK,EAAE,sBAAsB,GAC5B,OAAO,CAAC,YAAY,CAAC,uBAAuB,EAAE,CAAC,CAAC,CA0DlD"}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* search_legislation — Full-text search across Indian statute provisions.
|
|
3
|
+
*/
|
|
4
|
+
import { buildFtsQueryVariants } from '../utils/fts-query.js';
|
|
5
|
+
import { normalizeAsOfDate } from '../utils/as-of-date.js';
|
|
6
|
+
import { generateResponseMetadata } from '../utils/metadata.js';
|
|
7
|
+
const DEFAULT_LIMIT = 10;
|
|
8
|
+
const MAX_LIMIT = 50;
|
|
9
|
+
export async function searchLegislation(db, input) {
|
|
10
|
+
if (!input.query || input.query.trim().length === 0) {
|
|
11
|
+
return {
|
|
12
|
+
results: [],
|
|
13
|
+
_metadata: generateResponseMetadata(db)
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
const limit = Math.min(Math.max(input.limit ?? DEFAULT_LIMIT, 1), MAX_LIMIT);
|
|
17
|
+
const queryVariants = buildFtsQueryVariants(input.query);
|
|
18
|
+
// Validate as_of_date if provided (throws on invalid format)
|
|
19
|
+
if (input.as_of_date)
|
|
20
|
+
normalizeAsOfDate(input.as_of_date);
|
|
21
|
+
let sql = `
|
|
22
|
+
SELECT
|
|
23
|
+
lp.document_id,
|
|
24
|
+
ld.title as document_title,
|
|
25
|
+
lp.provision_ref,
|
|
26
|
+
lp.chapter,
|
|
27
|
+
lp.section,
|
|
28
|
+
lp.title,
|
|
29
|
+
snippet(provisions_fts, 0, '>>>', '<<<', '...', 32) as snippet,
|
|
30
|
+
bm25(provisions_fts) as relevance
|
|
31
|
+
FROM provisions_fts
|
|
32
|
+
JOIN legal_provisions lp ON lp.id = provisions_fts.rowid
|
|
33
|
+
JOIN legal_documents ld ON ld.id = lp.document_id
|
|
34
|
+
WHERE provisions_fts MATCH ?
|
|
35
|
+
`;
|
|
36
|
+
const params = [];
|
|
37
|
+
if (input.document_id) {
|
|
38
|
+
sql += ` AND lp.document_id = ?`;
|
|
39
|
+
params.push(input.document_id);
|
|
40
|
+
}
|
|
41
|
+
if (input.status) {
|
|
42
|
+
sql += ` AND ld.status = ?`;
|
|
43
|
+
params.push(input.status);
|
|
44
|
+
}
|
|
45
|
+
sql += ` ORDER BY relevance LIMIT ?`;
|
|
46
|
+
params.push(limit);
|
|
47
|
+
const runQuery = (ftsQuery) => {
|
|
48
|
+
const bound = [ftsQuery, ...params];
|
|
49
|
+
return db.prepare(sql).all(...bound);
|
|
50
|
+
};
|
|
51
|
+
const primaryResults = runQuery(queryVariants.primary);
|
|
52
|
+
const results = (primaryResults.length > 0 || !queryVariants.fallback)
|
|
53
|
+
? primaryResults
|
|
54
|
+
: runQuery(queryVariants.fallback);
|
|
55
|
+
return {
|
|
56
|
+
results,
|
|
57
|
+
_metadata: generateResponseMetadata(db)
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
//# sourceMappingURL=search-legislation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-legislation.js","sourceRoot":"","sources":["../../src/tools/search-legislation.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAAE,wBAAwB,EAAqB,MAAM,sBAAsB,CAAC;AAqBnF,MAAM,aAAa,GAAG,EAAE,CAAC;AACzB,MAAM,SAAS,GAAG,EAAE,CAAC;AAErB,MAAM,CAAC,KAAK,UAAU,iBAAiB,CACrC,EAAY,EACZ,KAA6B;IAE7B,IAAI,CAAC,KAAK,CAAC,KAAK,IAAI,KAAK,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACpD,OAAO;YACL,OAAO,EAAE,EAAE;YACX,SAAS,EAAE,wBAAwB,CAAC,EAAE,CAAC;SACxC,CAAC;IACJ,CAAC;IAED,MAAM,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,KAAK,IAA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ACxC,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* validate_citation — Validate an Indian legal citation against the database.
|
|
3
|
+
*/
|
|
4
|
+
import type { Database } from '@ansvar/mcp-sqlite';
|
|
5
|
+
import { type ToolResponse } from '../utils/metadata.js';
|
|
6
|
+
export interface ValidateCitationInput {
|
|
7
|
+
citation: string;
|
|
8
|
+
}
|
|
9
|
+
export interface ValidateCitationResult {
|
|
10
|
+
citation: string;
|
|
11
|
+
formatted_citation: string;
|
|
12
|
+
valid: boolean;
|
|
13
|
+
document_exists: boolean;
|
|
14
|
+
provision_exists: boolean;
|
|
15
|
+
document_title?: string;
|
|
16
|
+
status?: string;
|
|
17
|
+
warnings: string[];
|
|
18
|
+
}
|
|
19
|
+
export declare function validateCitationTool(db: Database, input: ValidateCitationInput): Promise<ToolResponse<ValidateCitationResult>>;
|
|
20
|
+
//# sourceMappingURL=validate-citation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validate-citation.d.ts","sourceRoot":"","sources":["../../src/tools/validate-citation.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAInD,OAAO,EAA4B,KAAK,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAEnF,MAAM,WAAW,qBAAqB;IACpC,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,sBAAsB;IACrC,QAAQ,EAAE,MAAM,CAAC;IACjB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,KAAK,EAAE,OAAO,CAAC;IACf,eAAe,EAAE,OAAO,CAAC;IACzB,gBAAgB,EAAE,OAAO,CAAC;IAC1B,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,EAAE,CAAC;CACpB;AAED,wBAAsB,oBAAoB,CACxC,EAAE,EAAE,QAAQ,EACZ,KAAK,EAAE,qBAAqB,GAC3B,OAAO,CAAC,YAAY,CAAC,sBAAsB,CAAC,CAAC,CA+B/C"}
|