xproof 0.2.2__tar.gz → 0.2.3__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.
Files changed (25) hide show
  1. {xproof-0.2.2 → xproof-0.2.3}/PKG-INFO +1 -1
  2. {xproof-0.2.2 → xproof-0.2.3}/pyproject.toml +1 -1
  3. {xproof-0.2.2 → xproof-0.2.3}/xproof/__init__.py +1 -1
  4. {xproof-0.2.2 → xproof-0.2.3}/xproof/client.py +30 -1
  5. {xproof-0.2.2 → xproof-0.2.3}/xproof.egg-info/PKG-INFO +1 -1
  6. {xproof-0.2.2 → xproof-0.2.3}/LICENSE +0 -0
  7. {xproof-0.2.2 → xproof-0.2.3}/README.md +0 -0
  8. {xproof-0.2.2 → xproof-0.2.3}/setup.cfg +0 -0
  9. {xproof-0.2.2 → xproof-0.2.3}/tests/test_client.py +0 -0
  10. {xproof-0.2.2 → xproof-0.2.3}/tests/test_integration.py +0 -0
  11. {xproof-0.2.2 → xproof-0.2.3}/xproof/exceptions.py +0 -0
  12. {xproof-0.2.2 → xproof-0.2.3}/xproof/integrations/__init__.py +0 -0
  13. {xproof-0.2.2 → xproof-0.2.3}/xproof/integrations/autogen.py +0 -0
  14. {xproof-0.2.2 → xproof-0.2.3}/xproof/integrations/crewai.py +0 -0
  15. {xproof-0.2.2 → xproof-0.2.3}/xproof/integrations/deerflow.py +0 -0
  16. {xproof-0.2.2 → xproof-0.2.3}/xproof/integrations/langchain.py +0 -0
  17. {xproof-0.2.2 → xproof-0.2.3}/xproof/integrations/llamaindex.py +0 -0
  18. {xproof-0.2.2 → xproof-0.2.3}/xproof/integrations/openai_agents.py +0 -0
  19. {xproof-0.2.2 → xproof-0.2.3}/xproof/models.py +0 -0
  20. {xproof-0.2.2 → xproof-0.2.3}/xproof/py.typed +0 -0
  21. {xproof-0.2.2 → xproof-0.2.3}/xproof/utils.py +0 -0
  22. {xproof-0.2.2 → xproof-0.2.3}/xproof.egg-info/SOURCES.txt +0 -0
  23. {xproof-0.2.2 → xproof-0.2.3}/xproof.egg-info/dependency_links.txt +0 -0
  24. {xproof-0.2.2 → xproof-0.2.3}/xproof.egg-info/requires.txt +0 -0
  25. {xproof-0.2.2 → xproof-0.2.3}/xproof.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: xproof
3
- Version: 0.2.2
3
+ Version: 0.2.3
4
4
  Summary: Python SDK for xProof — blockchain-anchored proof-of-existence for AI agents on MultiversX
5
5
  Author-email: xProof <contact@xproof.app>
6
6
  License-Expression: MIT
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "xproof"
7
- version = "0.2.2"
7
+ version = "0.2.3"
8
8
  description = "Python SDK for xProof — blockchain-anchored proof-of-existence for AI agents on MultiversX"
9
9
  readme = "README.md"
10
10
  license = "MIT"
@@ -21,7 +21,7 @@ from .models import (
21
21
  )
22
22
  from .utils import hash_bytes, hash_file
23
23
 
24
- __version__ = "0.2.2"
24
+ __version__ = "0.2.3"
25
25
 
26
26
  __all__ = [
27
27
  "XProofClient",
@@ -17,7 +17,7 @@ from .exceptions import (
17
17
  from .models import BatchResult, Certification, PricingInfo, RegistrationResult
18
18
  from .utils import hash_file
19
19
 
20
- __version__ = "0.1.0"
20
+ __version__ = "0.2.3"
21
21
 
22
22
  DEFAULT_BASE_URL = "https://xproof.app"
23
23
  DEFAULT_TIMEOUT = 30
@@ -378,6 +378,35 @@ class XProofClient:
378
378
  )
379
379
  return data
380
380
 
381
+ def get_context_drift(self, decision_id: str) -> Dict[str, Any]:
382
+ """Detect execution context drift across a decision chain.
383
+
384
+ Compares ``model_hash``, ``tools_version``, ``strategy_snapshot``, and
385
+ ``operator_scope`` between consecutive proofs in the chain. Returns a
386
+ coherence score and per-stage breakdown of which fields changed.
387
+
388
+ Args:
389
+ decision_id: The shared identifier linking proofs in the chain.
390
+
391
+ Returns:
392
+ A dictionary with:
393
+
394
+ - ``context_coherent`` (bool): True if no drift was detected.
395
+ - ``drift_score`` (float): 0.0 = fully coherent, 1.0 = total drift.
396
+ - ``fields_drifted`` (list[str]): Fields that changed at least once.
397
+ - ``fields_stable`` (list[str]): Fields present in all stages and unchanged.
398
+ - ``fields_absent`` (list[str]): Fields never populated in any stage.
399
+ - ``stages`` (list[dict]): Per-stage context with ``context_break``
400
+ and ``drifted_fields`` flags.
401
+ """
402
+ from urllib.parse import quote
403
+ data = self._request(
404
+ "GET",
405
+ f"/api/context-drift/{quote(decision_id, safe='')}",
406
+ auth_required=False,
407
+ )
408
+ return data
409
+
381
410
  def batch_certify(
382
411
  self,
383
412
  files: List[Dict[str, Any]],
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: xproof
3
- Version: 0.2.2
3
+ Version: 0.2.3
4
4
  Summary: Python SDK for xProof — blockchain-anchored proof-of-existence for AI agents on MultiversX
5
5
  Author-email: xProof <contact@xproof.app>
6
6
  License-Expression: MIT
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