parsely-dip 0.0.7__tar.gz → 0.0.8__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.
- {parsely_dip-0.0.7/src/parsely_dip.egg-info → parsely_dip-0.0.8}/PKG-INFO +1 -1
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/pyproject.toml +1 -1
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/engine/stanza_service.py +15 -10
- {parsely_dip-0.0.7 → parsely_dip-0.0.8/src/parsely_dip.egg-info}/PKG-INFO +1 -1
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/LICENSE +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/README.md +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/setup.cfg +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/__init__.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/cli/__init__.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/cli/main.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/engine/__init__.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/engine/nlp.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/engine/regex.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/engine/registry.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/engine/splitter.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/intents/__init__.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/intents/day.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/intents/scrum.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/intents/time.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/intents/weather.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip/patterns/__init__.py +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip.egg-info/SOURCES.txt +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip.egg-info/dependency_links.txt +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip.egg-info/entry_points.txt +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip.egg-info/requires.txt +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/src/parsely_dip.egg-info/top_level.txt +0 -0
- {parsely_dip-0.0.7 → parsely_dip-0.0.8}/tests/test_runner.py +0 -0
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "parsely-dip"
|
|
7
|
-
version = "0.0.
|
|
7
|
+
version = "0.0.8"
|
|
8
8
|
description = "PARSELY-DIP: Deterministic Intent Parser — RegEx and NLP pipeline for intent recognition"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
license = {text = "Proprietary"}
|
|
@@ -154,22 +154,27 @@ def restrict_access():
|
|
|
154
154
|
"""
|
|
155
155
|
Security middleware to restrict API access
|
|
156
156
|
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
157
|
+
Restrict API access to localhost only.
|
|
158
|
+
|
|
159
|
+
Source IP must be 127.0.0.1. Token auth (X-Stanza-Token) was REMOVED
|
|
160
|
+
2026-06-17 (C#1070 / George): the service is localhost-bound, so the IP
|
|
161
|
+
check is sufficient, and the token gate caused recurring issues (e.g.
|
|
162
|
+
blocking /health) for no added security on a local-only service.
|
|
163
|
+
Re-add token auth only if this service is ever exposed beyond localhost.
|
|
160
164
|
|
|
161
165
|
Returns:
|
|
162
|
-
None: Allows request to continue
|
|
163
|
-
tuple: (error_json, 403) if
|
|
166
|
+
None: Allows request to continue.
|
|
167
|
+
tuple: (error_json, 403) if the source IP is not localhost.
|
|
164
168
|
"""
|
|
165
|
-
# Check source IP
|
|
169
|
+
# Check source IP (localhost only) -- the sole access control now
|
|
166
170
|
if request.remote_addr != '127.0.0.1':
|
|
167
171
|
return jsonify({"error": "Access denied: Invalid source IP"}), 403
|
|
168
172
|
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
+
|
|
174
|
+
@app.route('/health', methods=['GET'])
|
|
175
|
+
def health():
|
|
176
|
+
"""Liveness check — returns 200 when the service is up. Public (no token)."""
|
|
177
|
+
return jsonify({"status": "ok", "service": "parsely-dip stanza"}), 200
|
|
173
178
|
|
|
174
179
|
|
|
175
180
|
def tree_to_json_with_all_info(tree, sentence, word_index=None):
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|