WaveGuardClient 3.0.0__tar.gz → 3.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.
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/PKG-INFO +2 -2
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/README.md +1 -1
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/WaveGuardClient.egg-info/PKG-INFO +2 -2
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/mcp_server/server.py +19 -5
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/pyproject.toml +1 -1
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/waveguard/client.py +26 -9
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/LICENSE +0 -0
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/WaveGuardClient.egg-info/SOURCES.txt +0 -0
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/WaveGuardClient.egg-info/dependency_links.txt +0 -0
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/WaveGuardClient.egg-info/entry_points.txt +0 -0
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/WaveGuardClient.egg-info/requires.txt +0 -0
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/WaveGuardClient.egg-info/top_level.txt +0 -0
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/mcp_server/__init__.py +0 -0
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/setup.cfg +0 -0
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/tests/test_client.py +0 -0
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/tests/test_mcp_server.py +0 -0
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/waveguard/__init__.py +0 -0
- {waveguardclient-3.0.0 → waveguardclient-3.2.0}/waveguard/exceptions.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: WaveGuardClient
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.2.0
|
|
4
4
|
Summary: Python SDK for WaveGuard — physics-based anomaly detection, fingerprinting & crypto risk API
|
|
5
5
|
Author: Greg Partin
|
|
6
6
|
License-Expression: MIT
|
|
@@ -36,7 +36,7 @@ Dynamic: license-file
|
|
|
36
36
|
|
|
37
37
|
<p align="center">
|
|
38
38
|
<img src="https://img.shields.io/pypi/v/WaveGuardClient?style=for-the-badge&color=blueviolet" alt="PyPI">
|
|
39
|
-
<img src="https://img.shields.io/badge/API-
|
|
39
|
+
<img src="https://img.shields.io/badge/API-v3.1.0_stateless-brightgreen?style=for-the-badge" alt="v3.1.0">
|
|
40
40
|
<img src="https://img.shields.io/badge/GPU-CUDA_accelerated-76B900?style=for-the-badge&logo=nvidia" alt="CUDA">
|
|
41
41
|
<img src="https://img.shields.io/badge/MCP-Claude_Desktop-orange?style=for-the-badge" alt="MCP">
|
|
42
42
|
<a href="https://smithery.ai/servers/emergentphysicslab/waveguard"><img src="https://smithery.ai/badge/emergentphysicslab/waveguard" alt="Smithery"></a>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<p align="center">
|
|
2
2
|
<img src="https://img.shields.io/pypi/v/WaveGuardClient?style=for-the-badge&color=blueviolet" alt="PyPI">
|
|
3
|
-
<img src="https://img.shields.io/badge/API-
|
|
3
|
+
<img src="https://img.shields.io/badge/API-v3.1.0_stateless-brightgreen?style=for-the-badge" alt="v3.1.0">
|
|
4
4
|
<img src="https://img.shields.io/badge/GPU-CUDA_accelerated-76B900?style=for-the-badge&logo=nvidia" alt="CUDA">
|
|
5
5
|
<img src="https://img.shields.io/badge/MCP-Claude_Desktop-orange?style=for-the-badge" alt="MCP">
|
|
6
6
|
<a href="https://smithery.ai/servers/emergentphysicslab/waveguard"><img src="https://smithery.ai/badge/emergentphysicslab/waveguard" alt="Smithery"></a>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: WaveGuardClient
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.2.0
|
|
4
4
|
Summary: Python SDK for WaveGuard — physics-based anomaly detection, fingerprinting & crypto risk API
|
|
5
5
|
Author: Greg Partin
|
|
6
6
|
License-Expression: MIT
|
|
@@ -36,7 +36,7 @@ Dynamic: license-file
|
|
|
36
36
|
|
|
37
37
|
<p align="center">
|
|
38
38
|
<img src="https://img.shields.io/pypi/v/WaveGuardClient?style=for-the-badge&color=blueviolet" alt="PyPI">
|
|
39
|
-
<img src="https://img.shields.io/badge/API-
|
|
39
|
+
<img src="https://img.shields.io/badge/API-v3.1.0_stateless-brightgreen?style=for-the-badge" alt="v3.1.0">
|
|
40
40
|
<img src="https://img.shields.io/badge/GPU-CUDA_accelerated-76B900?style=for-the-badge&logo=nvidia" alt="CUDA">
|
|
41
41
|
<img src="https://img.shields.io/badge/MCP-Claude_Desktop-orange?style=for-the-badge" alt="MCP">
|
|
42
42
|
<a href="https://smithery.ai/servers/emergentphysicslab/waveguard"><img src="https://smithery.ai/badge/emergentphysicslab/waveguard" alt="Smithery"></a>
|
|
@@ -371,7 +371,7 @@ class MCPStdioServer:
|
|
|
371
371
|
def __init__(self) -> None:
|
|
372
372
|
self.server_info = {
|
|
373
373
|
"name": "waveguard",
|
|
374
|
-
"version": "
|
|
374
|
+
"version": "3.1.0",
|
|
375
375
|
}
|
|
376
376
|
|
|
377
377
|
def handle_message(self, msg: dict) -> Optional[dict]:
|
|
@@ -403,6 +403,20 @@ class MCPStdioServer:
|
|
|
403
403
|
"result": {"tools": TOOLS},
|
|
404
404
|
}
|
|
405
405
|
|
|
406
|
+
elif method == "resources/list":
|
|
407
|
+
return {
|
|
408
|
+
"jsonrpc": "2.0",
|
|
409
|
+
"id": msg_id,
|
|
410
|
+
"result": {"resources": []},
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
elif method == "prompts/list":
|
|
414
|
+
return {
|
|
415
|
+
"jsonrpc": "2.0",
|
|
416
|
+
"id": msg_id,
|
|
417
|
+
"result": {"prompts": []},
|
|
418
|
+
}
|
|
419
|
+
|
|
406
420
|
elif method == "tools/call":
|
|
407
421
|
tool_name = params.get("name", "")
|
|
408
422
|
arguments = params.get("arguments", {})
|
|
@@ -435,7 +449,7 @@ class MCPStdioServer:
|
|
|
435
449
|
def run_stdio(self) -> None:
|
|
436
450
|
"""Run the MCP server on stdin/stdout."""
|
|
437
451
|
sys.stderr.write(
|
|
438
|
-
f"WaveGuard MCP server
|
|
452
|
+
f"WaveGuard MCP server v3.1.0 started (API: {API_URL})\n"
|
|
439
453
|
)
|
|
440
454
|
sys.stderr.flush()
|
|
441
455
|
|
|
@@ -470,7 +484,7 @@ def run_http_server(port: int = 3001) -> None:
|
|
|
470
484
|
print("HTTP transport requires: pip install fastapi uvicorn")
|
|
471
485
|
sys.exit(1)
|
|
472
486
|
|
|
473
|
-
mcp_app = FA(title="WaveGuard MCP Server", version="
|
|
487
|
+
mcp_app = FA(title="WaveGuard MCP Server", version="3.1.0")
|
|
474
488
|
server = MCPStdioServer()
|
|
475
489
|
|
|
476
490
|
@mcp_app.post("/mcp")
|
|
@@ -481,7 +495,7 @@ def run_http_server(port: int = 3001) -> None:
|
|
|
481
495
|
async def mcp_tools() -> dict: # type: ignore[type-arg]
|
|
482
496
|
return {"tools": TOOLS}
|
|
483
497
|
|
|
484
|
-
print(f"WaveGuard MCP HTTP server
|
|
498
|
+
print(f"WaveGuard MCP HTTP server v3.1.0 on port {port}")
|
|
485
499
|
uvicorn.run(mcp_app, host="0.0.0.0", port=port)
|
|
486
500
|
|
|
487
501
|
|
|
@@ -492,7 +506,7 @@ def run_http_server(port: int = 3001) -> None:
|
|
|
492
506
|
def main():
|
|
493
507
|
"""Entry point for `waveguard-mcp` console script."""
|
|
494
508
|
parser = argparse.ArgumentParser(
|
|
495
|
-
description="WaveGuard MCP Server
|
|
509
|
+
description="WaveGuard MCP Server v3.0.0"
|
|
496
510
|
)
|
|
497
511
|
parser.add_argument(
|
|
498
512
|
"--http",
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "WaveGuardClient"
|
|
7
|
-
version = "3.
|
|
7
|
+
version = "3.2.0"
|
|
8
8
|
description = "Python SDK for WaveGuard — physics-based anomaly detection, fingerprinting & crypto risk API"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
license = "MIT"
|
|
@@ -42,7 +42,7 @@ from .exceptions import (
|
|
|
42
42
|
ServerError,
|
|
43
43
|
)
|
|
44
44
|
|
|
45
|
-
__version__ = "3.
|
|
45
|
+
__version__ = "3.2.0"
|
|
46
46
|
|
|
47
47
|
logger = logging.getLogger("waveguard")
|
|
48
48
|
|
|
@@ -145,15 +145,17 @@ class FingerprintResult:
|
|
|
145
145
|
Attributes
|
|
146
146
|
----------
|
|
147
147
|
fingerprint : list[float]
|
|
148
|
-
52-
|
|
148
|
+
Physics embedding vector (52-dim at L0, 62-dim at L1).
|
|
149
149
|
dimensions : int
|
|
150
|
-
Number of dimensions (
|
|
150
|
+
Number of dimensions (52 at Level 0, 62 at Level 1).
|
|
151
151
|
labels : list[str]
|
|
152
152
|
Human-readable label for each dimension.
|
|
153
153
|
encoder_type : str
|
|
154
154
|
Encoder used to map input data onto the lattice.
|
|
155
155
|
latency_ms : float
|
|
156
156
|
Server-side processing time.
|
|
157
|
+
field_level : int
|
|
158
|
+
Field level used (0=real scalar, 1=complex).
|
|
157
159
|
raw : dict
|
|
158
160
|
Full JSON response.
|
|
159
161
|
"""
|
|
@@ -163,6 +165,7 @@ class FingerprintResult:
|
|
|
163
165
|
labels: List[str]
|
|
164
166
|
encoder_type: str
|
|
165
167
|
latency_ms: float
|
|
168
|
+
field_level: int = 0
|
|
166
169
|
raw: Dict[str, Any] = field(default_factory=dict)
|
|
167
170
|
|
|
168
171
|
|
|
@@ -177,9 +180,9 @@ class CompareResult:
|
|
|
177
180
|
distance : float
|
|
178
181
|
Euclidean distance between fingerprints.
|
|
179
182
|
fingerprint_a : list[float]
|
|
180
|
-
|
|
181
|
-
fingerprint_b
|
|
182
|
-
|
|
183
|
+
Physics embedding of data_a.
|
|
184
|
+
fingerprint_b: List[float]
|
|
185
|
+
Physics embedding of data_b.
|
|
183
186
|
dimensions : int
|
|
184
187
|
Number of dimensions.
|
|
185
188
|
encoder_type : str
|
|
@@ -266,6 +269,7 @@ class WaveGuard:
|
|
|
266
269
|
test: List[Any],
|
|
267
270
|
encoder_type: Optional[str] = None,
|
|
268
271
|
sensitivity: Optional[float] = None,
|
|
272
|
+
field_level: int = 0,
|
|
269
273
|
) -> ScanResult:
|
|
270
274
|
"""Scan test data for anomalies against a training baseline.
|
|
271
275
|
|
|
@@ -282,11 +286,15 @@ class WaveGuard:
|
|
|
282
286
|
1+ samples to check for anomalies.
|
|
283
287
|
encoder_type : str, optional
|
|
284
288
|
Force a specific encoder: ``"json"``, ``"numeric"``,
|
|
285
|
-
``"text"``, ``"timeseries"``, ``"tabular"
|
|
289
|
+
``"text"``, ``"timeseries"``, ``"tabular"``,
|
|
290
|
+
``"complex_numeric"``.
|
|
286
291
|
Leave *None* for auto-detection (recommended).
|
|
287
292
|
sensitivity : float, optional
|
|
288
293
|
Detection sensitivity in the range 0.5–3.0.
|
|
289
294
|
Lower values are more sensitive (flag more anomalies).
|
|
295
|
+
field_level : int
|
|
296
|
+
Physics field complexity. 0 = real scalar (default).
|
|
297
|
+
1 = complex field (phase-aware, 62-dim fingerprints).
|
|
290
298
|
|
|
291
299
|
Returns
|
|
292
300
|
-------
|
|
@@ -302,6 +310,8 @@ class WaveGuard:
|
|
|
302
310
|
body["encoder_type"] = encoder_type
|
|
303
311
|
if sensitivity is not None:
|
|
304
312
|
body["sensitivity"] = sensitivity
|
|
313
|
+
if field_level:
|
|
314
|
+
body["field_level"] = field_level
|
|
305
315
|
|
|
306
316
|
resp = self._post("/v1/scan", body)
|
|
307
317
|
return self._parse_scan(resp, len(training), len(test))
|
|
@@ -310,8 +320,9 @@ class WaveGuard:
|
|
|
310
320
|
self,
|
|
311
321
|
data: Any,
|
|
312
322
|
encoder_type: Optional[str] = None,
|
|
323
|
+
field_level: int = 0,
|
|
313
324
|
) -> FingerprintResult:
|
|
314
|
-
"""Get a
|
|
325
|
+
"""Get a physics embedding of any data item.
|
|
315
326
|
|
|
316
327
|
Parameters
|
|
317
328
|
----------
|
|
@@ -319,16 +330,21 @@ class WaveGuard:
|
|
|
319
330
|
A single data item to fingerprint (JSON object, list, string, etc.).
|
|
320
331
|
encoder_type : str, optional
|
|
321
332
|
Force a specific encoder. Leave *None* for auto-detection.
|
|
333
|
+
field_level : int
|
|
334
|
+
0 = real scalar (52-dim, default).
|
|
335
|
+
1 = complex field (62-dim, includes phase statistics).
|
|
322
336
|
|
|
323
337
|
Returns
|
|
324
338
|
-------
|
|
325
339
|
FingerprintResult
|
|
326
|
-
``.fingerprint`` is the 52
|
|
340
|
+
``.fingerprint`` is the embedding vector (52 or 62 dims).
|
|
327
341
|
``.labels`` names each dimension.
|
|
328
342
|
"""
|
|
329
343
|
body: Dict[str, Any] = {"data": data}
|
|
330
344
|
if encoder_type is not None:
|
|
331
345
|
body["encoder_type"] = encoder_type
|
|
346
|
+
if field_level:
|
|
347
|
+
body["field_level"] = field_level
|
|
332
348
|
|
|
333
349
|
resp = self._post("/v1/fingerprint", body)
|
|
334
350
|
return FingerprintResult(
|
|
@@ -337,6 +353,7 @@ class WaveGuard:
|
|
|
337
353
|
labels=resp.get("labels", []),
|
|
338
354
|
encoder_type=resp.get("encoder_type", "auto"),
|
|
339
355
|
latency_ms=resp.get("latency_ms", 0.0),
|
|
356
|
+
field_level=resp.get("field_level", 0),
|
|
340
357
|
raw=resp,
|
|
341
358
|
)
|
|
342
359
|
|
|
File without changes
|
|
File without changes
|
{waveguardclient-3.0.0 → waveguardclient-3.2.0}/WaveGuardClient.egg-info/dependency_links.txt
RENAMED
|
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
|