hyperpocket-langgraph 0.3.5__tar.gz → 0.3.7__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.
@@ -1,10 +1,10 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: hyperpocket-langgraph
3
- Version: 0.3.5
3
+ Version: 0.3.7
4
4
  Author-email: Hyperpocket Team <hyperpocket@vessl.ai>
5
5
  Requires-Python: >=3.10
6
6
  Requires-Dist: hyperpocket>=0.0.3
7
- Requires-Dist: langgraph>=0.2.59
7
+ Requires-Dist: langgraph>=0.2.0
8
8
  Description-Content-Type: text/markdown
9
9
 
10
10
  # Langgraph extensions
@@ -1,10 +1,11 @@
1
1
  import copy
2
+ import json
2
3
  from typing import Optional
3
4
 
4
- from hyperpocket.config import pocket_logger
5
5
  from langchain_core.runnables import RunnableConfig
6
6
  from langgraph.errors import NodeInterrupt
7
- from pydantic import BaseModel
7
+
8
+ from hyperpocket.config import pocket_logger
8
9
 
9
10
  try:
10
11
  from langchain_core.messages import ToolMessage
@@ -66,9 +67,6 @@ class PocketLanggraph(Pocket):
66
67
  body = tool_args
67
68
  profile = "default"
68
69
 
69
- if isinstance(body, BaseModel):
70
- body = body.model_dump()
71
-
72
70
  prepare = await self.prepare_in_subprocess(
73
71
  tool_name, body=body, thread_id=thread_id, profile=profile
74
72
  )
@@ -122,8 +120,8 @@ class PocketLanggraph(Pocket):
122
120
  body = tool_args
123
121
  profile = "default"
124
122
 
125
- if isinstance(body, BaseModel):
126
- body = body.model_dump()
123
+ if isinstance(body, str):
124
+ body = json.loads(body)
127
125
 
128
126
  try:
129
127
  auth = await self.authenticate_in_subprocess(
@@ -185,8 +183,8 @@ class PocketLanggraph(Pocket):
185
183
  thread_id = "default"
186
184
  profile = "default"
187
185
 
188
- if isinstance(body, BaseModel):
189
- body = body.model_dump()
186
+ if isinstance(body, str):
187
+ body = json.loads(body)
190
188
 
191
189
  result, interrupted = self.invoke_with_state(
192
190
  pocket_tool.name, body, thread_id, profile, **kwargs
@@ -206,8 +204,8 @@ class PocketLanggraph(Pocket):
206
204
  thread_id = "default"
207
205
  profile = "default"
208
206
 
209
- if isinstance(body, BaseModel):
210
- body = body.model_dump()
207
+ if isinstance(body, str):
208
+ body = json.loads(body)
211
209
 
212
210
  result, interrupted = await self.ainvoke_with_state(
213
211
  pocket_tool.name, body, thread_id, profile, **kwargs
@@ -1,12 +1,15 @@
1
1
 
2
2
  [project]
3
3
  name = "hyperpocket-langgraph"
4
- version = "0.3.5"
4
+ version = "0.3.7"
5
5
  description = ""
6
6
  authors = [{ name = "Hyperpocket Team", email = "hyperpocket@vessl.ai" }]
7
7
  requires-python = ">=3.10"
8
8
  readme = "README.md"
9
- dependencies = ["langgraph>=0.2.59", "hyperpocket>=0.0.3"]
9
+ dependencies = [
10
+ "hyperpocket>=0.0.3",
11
+ "langgraph>=0.2.0",
12
+ ]
10
13
 
11
14
  [tool.uv.sources]
12
15
  hyperpocket = { path = "../../hyperpocket", editable = true }
@@ -400,7 +400,7 @@ wheels = [
400
400
 
401
401
  [[package]]
402
402
  name = "hyperpocket"
403
- version = "0.1.8"
403
+ version = "0.3.6"
404
404
  source = { editable = "../../hyperpocket" }
405
405
  dependencies = [
406
406
  { name = "click" },
@@ -442,12 +442,13 @@ requires-dist = [
442
442
  [package.metadata.requires-dev]
443
443
  dev = [
444
444
  { name = "pytest", specifier = ">=8.3.4" },
445
+ { name = "pytest-cov", specifier = ">=6.0.0" },
445
446
  { name = "ruff", specifier = ">=0.8.6" },
446
447
  ]
447
448
 
448
449
  [[package]]
449
450
  name = "hyperpocket-langgraph"
450
- version = "0.1.8"
451
+ version = "0.3.6"
451
452
  source = { editable = "." }
452
453
  dependencies = [
453
454
  { name = "hyperpocket" },
@@ -466,7 +467,7 @@ test = [
466
467
  [package.metadata]
467
468
  requires-dist = [
468
469
  { name = "hyperpocket", editable = "../../hyperpocket" },
469
- { name = "langgraph", specifier = ">=0.2.59" },
470
+ { name = "langgraph", specifier = ">=0.2.0" },
470
471
  ]
471
472
 
472
473
  [package.metadata.requires-dev]
@@ -620,29 +621,29 @@ wheels = [
620
621
 
621
622
  [[package]]
622
623
  name = "langgraph"
623
- version = "0.2.63"
624
+ version = "0.2.73"
624
625
  source = { registry = "https://pypi.org/simple" }
625
626
  dependencies = [
626
627
  { name = "langchain-core" },
627
628
  { name = "langgraph-checkpoint" },
628
629
  { name = "langgraph-sdk" },
629
630
  ]
630
- sdist = { url = "https://files.pythonhosted.org/packages/84/ac/70c4e4f8197af0a348042b38bdebd219b8cc3522e44848e18027d2e1520d/langgraph-0.2.63.tar.gz", hash = "sha256:4bcdd6023b02d16c840b5ee612bfbafd1b9e0beef91622aa1827593374ee6e8e", size = 120296 }
631
+ sdist = { url = "https://files.pythonhosted.org/packages/05/80/545dd6253fe164b56cbfb85834ecd2fac2eed6be477f831429ab1d78bd4e/langgraph-0.2.73.tar.gz", hash = "sha256:61ae2b2140940d32543a384ebc96f5cca13c14932a377fba58e73257f9997de6", size = 131357 }
631
632
  wheels = [
632
- { url = "https://files.pythonhosted.org/packages/3e/7e/0a40b69abe014f1caa5000ccf0856ed3e62aa5c3e4cd1f3cc1bafab16d3a/langgraph-0.2.63-py3-none-any.whl", hash = "sha256:7867108e045c0ee52cb705749edd478b08588dce74fbd4466b4197a04c4e718b", size = 139696 },
633
+ { url = "https://files.pythonhosted.org/packages/a4/61/e4a148e0459e049a712f0bc92754c6e220b10c17f4b2aed6e712d7dd2ae8/langgraph-0.2.73-py3-none-any.whl", hash = "sha256:a6c1e491674a11b8d4f946cb7120ae0d18313f0daf6bb16cccd9d49ea547a780", size = 151472 },
633
634
  ]
634
635
 
635
636
  [[package]]
636
637
  name = "langgraph-checkpoint"
637
- version = "2.0.10"
638
+ version = "2.0.15"
638
639
  source = { registry = "https://pypi.org/simple" }
639
640
  dependencies = [
640
641
  { name = "langchain-core" },
641
642
  { name = "msgpack" },
642
643
  ]
643
- sdist = { url = "https://files.pythonhosted.org/packages/26/96/378e06c60d8c8cf44e1d6a2b669e9d5d87236bdee6bf7cfc9125ef5b5d0e/langgraph_checkpoint-2.0.10.tar.gz", hash = "sha256:2dcc04e09091d588bb6209e49d83ff5406d7231c2590d6ff18fb29ab8b140129", size = 33431 }
644
+ sdist = { url = "https://files.pythonhosted.org/packages/b9/e3/19e1beb24aa628a5e113a80feaaa93f818a9303ad5577c5747ba50309c17/langgraph_checkpoint-2.0.15.tar.gz", hash = "sha256:e3fffb7ce35b709caab2422fd6db2ec9fc446aab18a3845d30ffb6ace391d738", size = 34269 }
644
645
  wheels = [
645
- { url = "https://files.pythonhosted.org/packages/4d/ef/c320b52035e29081f2693377602289a00545016b4adcc963d5e202ac0c92/langgraph_checkpoint-2.0.10-py3-none-any.whl", hash = "sha256:0d592cfda2df93844c6ea44d142170a8f7e5ba5320274e0e5e60e27f2749392c", size = 37476 },
646
+ { url = "https://files.pythonhosted.org/packages/e6/cc/9f7c294e89babd2e4ed2a884de14ff9aa824251c29824e86e795807f5ead/langgraph_checkpoint-2.0.15-py3-none-any.whl", hash = "sha256:769d73544a3f4e89e65ba8034ad15e233c9a81bbd62b0a678d233849a0026c32", size = 38366 },
646
647
  ]
647
648
 
648
649
  [[package]]