il-eli-mcp 0.2.0__tar.gz

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.
@@ -0,0 +1,61 @@
1
+ name: release
2
+
3
+ # Publishes to PyPI (org secret PYPI_API_TOKEN) + the MCP Registry (GitHub OIDC).
4
+ # Trigger: push a version tag, e.g. `git tag v0.1.0 && git push origin v0.1.0`.
5
+ # Pattern matches gb-eli-mcp (classic token; OIDC trusted-publishing hit a
6
+ # persistent invalid-publisher error across the fleet).
7
+
8
+ on:
9
+ push:
10
+ tags:
11
+ - "v*"
12
+ workflow_dispatch: {} # manual re-run of the MCP Registry publish without bumping the package version
13
+
14
+ permissions:
15
+ contents: read
16
+ id-token: write # required for the MCP Registry OIDC login
17
+
18
+ jobs:
19
+ build-and-publish-pypi:
20
+ if: github.event_name == 'push' # only on a version tag; skipped on manual dispatch
21
+ runs-on: ubuntu-latest
22
+ steps:
23
+ - uses: actions/checkout@v4
24
+
25
+ - name: Set up Python
26
+ uses: actions/setup-python@v5
27
+ with:
28
+ python-version: "3.12"
29
+
30
+ - name: Install build tooling
31
+ run: python -m pip install --upgrade build
32
+
33
+ - name: Build sdist + wheel
34
+ run: python -m build
35
+
36
+ - name: Publish to PyPI (org API token)
37
+ uses: pypa/gh-action-pypi-publish@release/v1
38
+ with:
39
+ password: ${{ secrets.PYPI_API_TOKEN }}
40
+
41
+ publish-mcp-registry:
42
+ needs: build-and-publish-pypi
43
+ # run after a successful PyPI publish, OR standalone on manual dispatch
44
+ if: always() && (github.event_name == 'workflow_dispatch' || needs.build-and-publish-pypi.result == 'success')
45
+ runs-on: ubuntu-latest
46
+ permissions:
47
+ contents: read
48
+ id-token: write # OIDC login to the MCP Registry
49
+ steps:
50
+ - uses: actions/checkout@v4
51
+
52
+ - name: Install mcp-publisher
53
+ run: |
54
+ curl -L "https://github.com/modelcontextprotocol/registry/releases/latest/download/mcp-publisher_$(uname -s | tr '[:upper:]' '[:lower:]')_amd64.tar.gz" | tar xz mcp-publisher
55
+ sudo mv mcp-publisher /usr/local/bin/
56
+
57
+ - name: Login to MCP Registry (GitHub OIDC)
58
+ run: mcp-publisher login github-oidc
59
+
60
+ - name: Publish server.json to MCP Registry
61
+ run: mcp-publisher publish
@@ -0,0 +1,20 @@
1
+ # Python
2
+ .venv/
3
+ __pycache__/
4
+ *.py[cod]
5
+ *.egg-info/
6
+ dist/
7
+ build/
8
+ .pytest_cache/
9
+ .mypy_cache/
10
+ .ruff_cache/
11
+
12
+ # Local runtime (never source)
13
+ .matematic/
14
+ *.log
15
+
16
+ # OS
17
+ .DS_Store
18
+ Thumbs.db
19
+
20
+ # Note: tests/fixtures/* ARE committed - public Finlex data needed for tests.
@@ -0,0 +1,85 @@
1
+ # Discovery notes - Israel
2
+
3
+ Date: 2026-07-06.
4
+
5
+ ## v0.2.0 - case law + geo-block correction (2026-07-06)
6
+
7
+ - **Corrected an earlier external claim**: the Knesset OData API
8
+ (`https://knesset.gov.il/Odata/ParliamentInfo.svc/KNS_IsraelLaw`) was
9
+ re-verified live and is NOT Israel-IP-only / geo-blocked - a direct
10
+ `$top=3` query returned real data from outside Israel. `test_smoke.py`
11
+ (unchanged, pre-existing) continues to pass against the live API,
12
+ reconfirming this.
13
+ - **Added case law** (previously a documented zero-coverage gap): two new
14
+ tools, `il_search_case_law` and `il_get_case`, backed by the HuggingFace
15
+ dataset `guychuk/case-law-israel` (10,558 Hebrew court judgments -
16
+ Family/District/Magistrate/Labor/Military/Administrative courts, single
17
+ parquet file, ~80.9MB). This is a genuinely unconventional design choice
18
+ for this fleet: it is a **static, locally-bundled dataset**, not a live
19
+ query API, because Israeli court portals were found to be unreliable for
20
+ live querying elsewhere in the wider audit. The parquet file is downloaded
21
+ once (via `huggingface_hub`) into the existing cache directory
22
+ (`~/.matematic/cache/il-eli/case-law-dataset/`, override via
23
+ `IL_ELI_CACHE_DIR`) and then queried locally with a pandas substring
24
+ filter - no vector DB, no re-download per call. This fits the zero-cloud
25
+ philosophy: the data lives on disk, not re-fetched from a cloud API per
26
+ query.
27
+ - **Startup-safe**: the dataset download is lazy, triggered only on the
28
+ first `il_search_case_law`/`il_get_case` call, not at server import or
29
+ boot - tools that only touch `KNS_IsraelLaw` are unaffected.
30
+ - **License caveat - flagged, not resolved**: the dataset card's license
31
+ field is undocumented ("[More Information Needed]" as of 2026-07-06,
32
+ re-verified via the HF API metadata endpoint, not just the rendered
33
+ card). This connector caches the file for MateMatic's own tool use only;
34
+ it must NOT be redistributed to end users or bundled into any shipped
35
+ product without a legal review of actual redistribution rights.
36
+ - **No per-judgment public URL**: unlike `KNS_IsraelLaw`'s OData entity
37
+ URLs, this dataset has no dereferenceable per-case URL - citations point
38
+ to the HF dataset page with a `judgment_id` fragment, honestly labeled as
39
+ not an official court URL (see `citations.py::build_case_citation`).
40
+
41
+ ## Why Israel, and why now
42
+
43
+ Israel was the only genuinely fresh candidate left after the user asked
44
+ about Scotland, Israel, the Middle East, and Africa as follow-up regions:
45
+ Scotland is already covered by `gb-eli-mcp` (legislation.gov.uk covers the
46
+ Scottish Parliament under the same model), the Middle East and most of
47
+ Africa had already been screened out in earlier sweeps (DIFC Dubai and
48
+ Saudi Arabia found nothing machine-readable; most African common-law
49
+ jurisdictions only had LII-style portals with no official API). Israel had
50
+ never been probed.
51
+
52
+ ## What was tried and what worked
53
+
54
+ - `https://knesset.gov.il/Odata/ParliamentInfo.svc/` - the service root
55
+ listed dozens of entity sets (`KNS_Bill`, `KNS_IsraelLaw`,
56
+ `KNS_DocumentLaw`, `KNS_Committee`, and more), confirming a rich,
57
+ actively maintained parliamentary data API.
58
+ - `KNS_IsraelLaw` - the entity this connector uses. Confirmed live with
59
+ real records (e.g. `IsraelLawID=2000002`, the 1982 Foreclosure Law,
60
+ still listed as in-force with a `LatestPublicationDate` of 2025-06-16,
61
+ showing the data is actively updated).
62
+ - Full-text search via `substringof('...',Name)` confirmed working against
63
+ Hebrew text.
64
+ - Single-entity dereferencing (`KNS_IsraelLaw(2000002)`) confirmed working
65
+ and returns a flat JSON object (not wrapped in a `"value"` array, unlike
66
+ the collection endpoint) - this connector's client handles both shapes
67
+ correctly.
68
+
69
+ ## What didn't pan out
70
+
71
+ - `KNS_DocumentIsraelLaw` - listed in the service metadata, but every query
72
+ against it returned an empty result set. Likely deprecated or unused;
73
+ not relied upon.
74
+ - `KNS_DocumentLaw` - this one IS populated and gives direct PDF links to
75
+ full-text law documents, but its `LawID` field uses a different numeric
76
+ range than `KNS_IsraelLaw`'s `IsraelLawID` (e.g. `LawID=2001482` and
77
+ `2001957` appeared in the first two records fetched, while `IsraelLawID`
78
+ values in this session ran `2000001`-`2000323`+). The two are clearly
79
+ related but the exact join was not found within the time budget for this
80
+ discovery pass - flagged as a v0.2 opportunity rather than guessed at.
81
+ - No public HTML page URL pattern was found for an individual law (unlike
82
+ most other connectors in this fleet, which have both a machine-readable
83
+ URL and a human-browsable one). `source_url` in this connector is the
84
+ same OData entity URL as `lex_uri` - honest about the gap rather than
85
+ inventing a page that may not exist or may not resolve reliably.
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
@@ -0,0 +1,83 @@
1
+ Metadata-Version: 2.4
2
+ Name: il-eli-mcp
3
+ Version: 0.2.0
4
+ Summary: MCP server for Israeli legislation (Knesset OData) with verifiable citations.
5
+ Project-URL: Repository, https://github.com/matematicsolutions/il-eli-mcp
6
+ Project-URL: Issues, https://github.com/matematicsolutions/il-eli-mcp/issues
7
+ Project-URL: Homepage, https://matematic.co
8
+ Author-email: Matematic Solutions <kontakt@matematic.co>, Wieslaw Mazur <mazur.wieslaw2022@gmail.com>
9
+ License: Apache-2.0
10
+ License-File: LICENSE
11
+ Keywords: israel,knesset,law,legaltech,mcp,odata
12
+ Classifier: Development Status :: 3 - Alpha
13
+ Classifier: Intended Audience :: Legal Industry
14
+ Classifier: License :: OSI Approved :: Apache Software License
15
+ Classifier: Operating System :: OS Independent
16
+ Classifier: Programming Language :: Python :: 3
17
+ Classifier: Programming Language :: Python :: 3.11
18
+ Classifier: Programming Language :: Python :: 3.12
19
+ Classifier: Topic :: Office/Business
20
+ Requires-Python: >=3.11
21
+ Requires-Dist: anyio>=4.3
22
+ Requires-Dist: diskcache>=5.6
23
+ Requires-Dist: fastmcp>=0.2.0
24
+ Requires-Dist: httpx>=0.27
25
+ Requires-Dist: huggingface-hub>=0.24
26
+ Requires-Dist: pandas>=2.0
27
+ Requires-Dist: pyarrow>=15.0
28
+ Provides-Extra: dev
29
+ Requires-Dist: mypy>=1.10; extra == 'dev'
30
+ Requires-Dist: pytest-asyncio>=0.23; extra == 'dev'
31
+ Requires-Dist: pytest>=8.0; extra == 'dev'
32
+ Requires-Dist: ruff>=0.5; extra == 'dev'
33
+ Description-Content-Type: text/markdown
34
+
35
+ # il-eli-mcp
36
+
37
+ <!-- mcp-name: io.github.matematicsolutions/il-eli-mcp -->
38
+
39
+ MCP server for Israeli primary legislation via the Knesset's official
40
+ OData API (`KNS_IsraelLaw` entity set). Tracks each law's name, Knesset
41
+ session, in-force/repealed status, and whether it is a Basic Law (Israel's
42
+ quasi-constitutional laws).
43
+
44
+ ## What this is not
45
+
46
+ - **No full-text law content** - this connector returns metadata, not the
47
+ operative articles. The Knesset also exposes a `KNS_DocumentLaw` entity
48
+ with PDF links, but its identifier does not map directly to
49
+ `IsraelLawID` - not resolved here, see [DISCOVERY.md](DISCOVERY.md).
50
+ - **Hebrew only** - law names and search queries are in Hebrew; there is no
51
+ English-language law database in this API.
52
+ - **No case law** - not surveyed in this pass.
53
+
54
+ ## Tools
55
+
56
+ | Tool | Purpose |
57
+ |---|---|
58
+ | `il_search_laws` | Full-text search over law names |
59
+ | `il_get_law` | Full detail for one law by its `IsraelLawID` |
60
+
61
+ Every response carries `lex_uri` and `source_url` (both the same
62
+ dereferenceable Knesset OData entity URL - Israel has no separate public
63
+ citation identifier scheme for this data) and `human_readable_citation`
64
+ (the law's Hebrew name).
65
+
66
+ ## Install
67
+
68
+ ```bash
69
+ pip install il-eli-mcp
70
+ ```
71
+
72
+ ## Configuration
73
+
74
+ | Env var | Default |
75
+ |---|---|
76
+ | `IL_ELI_CACHE_DIR` | `~/.matematic/cache/il-eli` |
77
+ | `IL_ELI_AUDIT_DIR` | `~/.matematic/audit` |
78
+ | `IL_ELI_BASE_URL` | `https://knesset.gov.il/Odata/ParliamentInfo.svc` |
79
+
80
+ ## License
81
+
82
+ Apache-2.0 (code). Knesset OData content is official parliamentary
83
+ publication material (see [SOURCES.md](SOURCES.md)).
@@ -0,0 +1,49 @@
1
+ # il-eli-mcp
2
+
3
+ <!-- mcp-name: io.github.matematicsolutions/il-eli-mcp -->
4
+
5
+ MCP server for Israeli primary legislation via the Knesset's official
6
+ OData API (`KNS_IsraelLaw` entity set). Tracks each law's name, Knesset
7
+ session, in-force/repealed status, and whether it is a Basic Law (Israel's
8
+ quasi-constitutional laws).
9
+
10
+ ## What this is not
11
+
12
+ - **No full-text law content** - this connector returns metadata, not the
13
+ operative articles. The Knesset also exposes a `KNS_DocumentLaw` entity
14
+ with PDF links, but its identifier does not map directly to
15
+ `IsraelLawID` - not resolved here, see [DISCOVERY.md](DISCOVERY.md).
16
+ - **Hebrew only** - law names and search queries are in Hebrew; there is no
17
+ English-language law database in this API.
18
+ - **No case law** - not surveyed in this pass.
19
+
20
+ ## Tools
21
+
22
+ | Tool | Purpose |
23
+ |---|---|
24
+ | `il_search_laws` | Full-text search over law names |
25
+ | `il_get_law` | Full detail for one law by its `IsraelLawID` |
26
+
27
+ Every response carries `lex_uri` and `source_url` (both the same
28
+ dereferenceable Knesset OData entity URL - Israel has no separate public
29
+ citation identifier scheme for this data) and `human_readable_citation`
30
+ (the law's Hebrew name).
31
+
32
+ ## Install
33
+
34
+ ```bash
35
+ pip install il-eli-mcp
36
+ ```
37
+
38
+ ## Configuration
39
+
40
+ | Env var | Default |
41
+ |---|---|
42
+ | `IL_ELI_CACHE_DIR` | `~/.matematic/cache/il-eli` |
43
+ | `IL_ELI_AUDIT_DIR` | `~/.matematic/audit` |
44
+ | `IL_ELI_BASE_URL` | `https://knesset.gov.il/Odata/ParliamentInfo.svc` |
45
+
46
+ ## License
47
+
48
+ Apache-2.0 (code). Knesset OData content is official parliamentary
49
+ publication material (see [SOURCES.md](SOURCES.md)).
@@ -0,0 +1,56 @@
1
+ # Sources
2
+
3
+ ## Knesset OData API (`knesset.gov.il/Odata/ParliamentInfo.svc`)
4
+
5
+ - **Origin**: the Knesset (Israeli parliament).
6
+ - **License**: official parliamentary publication data; no separate reuse
7
+ license found during discovery - same caution class as other government
8
+ legal text sources in this fleet.
9
+ - **Access**: keyless OData (v2-style, `substringof`/`$filter`/`$top`),
10
+ JSON.
11
+ - **Entity used**: `KNS_IsraelLaw` - confirmed live 2026-07-06. Fields
12
+ include `IsraelLawID` (stable numeric id), `Name` (Hebrew title),
13
+ `KnessetNum`, `IsBasicLaw`, `PublicationDate`, `LatestPublicationDate`,
14
+ `LawValidityDesc` (in-force/repealed status).
15
+ - **Full-text search**: OData `substringof('text',Name)` confirmed working
16
+ against Hebrew text during discovery (found the Biometric Database Law
17
+ by searching the Hebrew word for "information").
18
+
19
+ ## Case law dataset (`guychuk/case-law-israel`, HuggingFace) - added v0.2.0
20
+
21
+ - **Origin**: community-scraped HuggingFace dataset, not an official
22
+ government source.
23
+ - **License**: undocumented ("[More Information Needed]" on the dataset
24
+ card, confirmed via both the rendered card and the HF API metadata
25
+ endpoint as of 2026-07-06). Treat as a caveat, not as clean/permissive -
26
+ do not redistribute the bundled data to end users without a legal review.
27
+ - **Access**: single parquet file
28
+ (`data/judgments-00000-of-00001.parquet`), downloaded once via
29
+ `huggingface_hub.hf_hub_download` and cached locally; queried thereafter
30
+ with a local pandas filter (no live API, no re-download per call).
31
+ - **Coverage**: 10,558 Hebrew judgments across Family, District,
32
+ Magistrate, Labor, Military and Administrative courts. Columns include
33
+ `judgment_id`, `title`, `name_number`, `doc_create_date`,
34
+ `court_type_label`, `district_label`, `publication_subject_label`,
35
+ `judges_str`, `document_text` (full judgment text), `url_name`.
36
+ - **No per-judgment public URL** - citations point to the dataset page
37
+ itself, not an official court URL.
38
+
39
+ ## Not covered (out of scope for this connector)
40
+
41
+ - **`KNS_DocumentLaw`** - a separate entity with `FilePath` fields pointing
42
+ to PDF documents (e.g. `https://fs.knesset.gov.il/2/law/2_lsr_311000.PDF`),
43
+ confirmed populated and live. Its `LawID` field does not match
44
+ `IsraelLawID` directly (different numeric ranges observed during
45
+ discovery, e.g. `IsraelLawID=2000002` vs `LawID=2001482`) - the join
46
+ likely runs through another entity (possibly `KNS_IsraelLawBinding`, not
47
+ investigated). A future version could resolve full-text PDF links once
48
+ the correct join is confirmed.
49
+ - **`KNS_DocumentIsraelLaw`** - present in the service metadata but returned
50
+ an empty result set on every query tried; likely deprecated or unused.
51
+ - **Live case-law query API** - Israeli court portals were found unreliable
52
+ / not machine-readable elsewhere in the wider audit; v0.2.0 works around
53
+ this with the static HF dataset above instead of a live connector.
54
+ - **English-language legislation database** - none found; Basic Laws are
55
+ sometimes published in English translation on the Knesset website as
56
+ standalone PDFs, but not as structured OData.
@@ -0,0 +1,4 @@
1
+ {
2
+ "$schema": "https://glama.ai/mcp/schemas/server.json",
3
+ "maintainers": ["mazurwieslaw2022-cmd"]
4
+ }
@@ -0,0 +1,68 @@
1
+ [build-system]
2
+ requires = ["hatchling"]
3
+ build-backend = "hatchling.build"
4
+
5
+ [project]
6
+ name = "il-eli-mcp"
7
+ version = "0.2.0"
8
+ description = "MCP server for Israeli legislation (Knesset OData) with verifiable citations."
9
+ readme = "README.md"
10
+ license = { text = "Apache-2.0" }
11
+ requires-python = ">=3.11"
12
+ authors = [
13
+ { name = "Matematic Solutions", email = "kontakt@matematic.co" },
14
+ { name = "Wieslaw Mazur", email = "mazur.wieslaw2022@gmail.com" },
15
+ ]
16
+ keywords = ["mcp", "legaltech", "israel", "knesset", "odata", "law"]
17
+ classifiers = [
18
+ "Development Status :: 3 - Alpha",
19
+ "Intended Audience :: Legal Industry",
20
+ "License :: OSI Approved :: Apache Software License",
21
+ "Operating System :: OS Independent",
22
+ "Programming Language :: Python :: 3",
23
+ "Programming Language :: Python :: 3.11",
24
+ "Programming Language :: Python :: 3.12",
25
+ "Topic :: Office/Business",
26
+ ]
27
+ dependencies = [
28
+ "fastmcp>=0.2.0",
29
+ "httpx>=0.27",
30
+ "diskcache>=5.6",
31
+ "anyio>=4.3",
32
+ "huggingface_hub>=0.24",
33
+ "pandas>=2.0",
34
+ "pyarrow>=15.0",
35
+ ]
36
+
37
+ [project.optional-dependencies]
38
+ dev = [
39
+ "pytest>=8.0",
40
+ "pytest-asyncio>=0.23",
41
+ "mypy>=1.10",
42
+ "ruff>=0.5",
43
+ ]
44
+
45
+ [project.urls]
46
+ Repository = "https://github.com/matematicsolutions/il-eli-mcp"
47
+ Issues = "https://github.com/matematicsolutions/il-eli-mcp/issues"
48
+ Homepage = "https://matematic.co"
49
+
50
+ [project.scripts]
51
+ il-eli-mcp = "il_eli_mcp.server:main"
52
+
53
+ [tool.hatch.build.targets.wheel]
54
+ packages = ["src/il_eli_mcp"]
55
+
56
+ [tool.ruff]
57
+ line-length = 100
58
+ target-version = "py311"
59
+
60
+ [tool.ruff.lint]
61
+ select = ["E", "F", "I", "B", "UP", "N", "SIM", "RUF"]
62
+
63
+ [tool.ruff.lint.per-file-ignores]
64
+ "src/il_eli_mcp/server.py" = ["E501"]
65
+
66
+ [tool.pytest.ini_options]
67
+ asyncio_mode = "auto"
68
+ testpaths = ["tests"]
@@ -0,0 +1,22 @@
1
+ {
2
+ "$schema": "https://static.modelcontextprotocol.io/schemas/2025-12-11/server.schema.json",
3
+ "name": "io.github.matematicsolutions/il-eli-mcp",
4
+ "description": "MCP server for Israeli law: Knesset legislation and case law, verifiable citations.",
5
+ "version": "0.2.0",
6
+ "repository": {
7
+ "url": "https://github.com/matematicsolutions/il-eli-mcp",
8
+ "source": "github"
9
+ },
10
+ "packages": [
11
+ {
12
+ "registryType": "pypi",
13
+ "registryBaseUrl": "https://pypi.org",
14
+ "identifier": "il-eli-mcp",
15
+ "version": "0.2.0",
16
+ "runtimeHint": "uvx",
17
+ "transport": {
18
+ "type": "stdio"
19
+ }
20
+ }
21
+ ]
22
+ }
@@ -0,0 +1,3 @@
1
+ """il-eli-mcp - MCP connector for Israeli legislation (Knesset OData)."""
2
+
3
+ __version__ = "0.2.0"