baml-py 0.90.1__cp38-abi3-macosx_10_12_x86_64.whl → 0.200.0__cp38-abi3-macosx_10_12_x86_64.whl
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.
- baml_py/baml_py.abi3.so +0 -0
- baml_py/baml_py.pyi +2 -0
- baml_py/ctx_manager.py +10 -0
- baml_py/stream.py +1 -1
- {baml_py-0.90.1.dist-info → baml_py-0.200.0.dist-info}/METADATA +1 -1
- baml_py-0.200.0.dist-info/RECORD +16 -0
- {baml_py-0.90.1.dist-info → baml_py-0.200.0.dist-info}/WHEEL +1 -1
- baml_py-0.90.1.dist-info/RECORD +0 -16
- {baml_py-0.90.1.dist-info → baml_py-0.200.0.dist-info}/entry_points.txt +0 -0
- {baml_py-0.90.1.dist-info → baml_py-0.200.0.dist-info}/licenses/LICENSE +0 -0
baml_py/baml_py.abi3.so
CHANGED
Binary file
|
baml_py/baml_py.pyi
CHANGED
@@ -103,6 +103,8 @@ class RuntimeContextManager:
|
|
103
103
|
def context_depth(self) -> int: ...
|
104
104
|
|
105
105
|
class BamlRuntime:
|
106
|
+
def __getstate__(self) -> Tuple[str, Dict[str, str]]: ...
|
107
|
+
def __setstate__(self, state: Tuple[str, Dict[str, str]]) -> None: ...
|
106
108
|
@staticmethod
|
107
109
|
def from_directory(directory: str, env_vars: Dict[str, str]) -> BamlRuntime: ...
|
108
110
|
async def call_function(
|
baml_py/ctx_manager.py
CHANGED
@@ -31,6 +31,16 @@ prev_ctx_manager: typing.Optional["CtxManager"] = None
|
|
31
31
|
|
32
32
|
|
33
33
|
class CtxManager:
|
34
|
+
def __setstate__(self, state: typing.Dict[str, typing.Any]) -> None:
|
35
|
+
self.rt = state["rt"]
|
36
|
+
self.ctx = contextvars.ContextVar[typing.Dict[int, RuntimeContextManager]](
|
37
|
+
"baml_ctx", default={current_thread_id(): self.rt.create_context_manager()}
|
38
|
+
)
|
39
|
+
atexit.register(self.rt.flush)
|
40
|
+
|
41
|
+
def __getstate__(self) -> typing.Dict[str, typing.Any]:
|
42
|
+
return {"rt": self.rt}
|
43
|
+
|
34
44
|
def __new__(cls, *args, **kwargs):
|
35
45
|
if prev_ctx_manager is not None:
|
36
46
|
return prev_ctx_manager
|
baml_py/stream.py
CHANGED
@@ -0,0 +1,16 @@
|
|
1
|
+
baml_py-0.200.0.dist-info/METADATA,sha256=EbvmXr3GAXbMB2z23KV0HZx_OOd1_As-TL_tFOVpC9g,335
|
2
|
+
baml_py-0.200.0.dist-info/WHEEL,sha256=EGuPi0n_1hkOWYoFFR6b_9qqSL6dMSNZbfmSoiDcLVo,104
|
3
|
+
baml_py-0.200.0.dist-info/entry_points.txt,sha256=9Uu_VcUjoI2qQMjVb0PRjEgI6pQ55WqBbzNparAPJyA,54
|
4
|
+
baml_py-0.200.0.dist-info/licenses/LICENSE,sha256=QwcOLU5TJoTeUhuIXzhdCEEDDvorGiC6-3YTOl4TecE,11356
|
5
|
+
baml_py/__init__.py,sha256=QWyuR-eLmqkiRW5v9RKF83knRj_HG8fyTlp6Sse9D3o,827
|
6
|
+
baml_py/baml_py.abi3.so,sha256=HTW028Lh3_9QreEn1isirzRTgwKDthXEPF6iSGCMuwc,43121240
|
7
|
+
baml_py/baml_py.pyi,sha256=Ev8oqkdiQhp0tb9-62xEy3ZtMN43uyJIxP68ZNlGD98,13995
|
8
|
+
baml_py/ctx_manager.py,sha256=JwWLvxFT05BnYiguzB-k-g47r7mft74L3mYt8e3qtus,6081
|
9
|
+
baml_py/errors.py,sha256=wqv7xT_-pVXQNxD5JbOrrr_CABCFuNrLrEhmEX8RVJ8,389
|
10
|
+
baml_py/internal_monkeypatch.py,sha256=JDwBPw4S8veD3nvJ13lFw8P5p29UOmDvvkgOy8eKA58,2106
|
11
|
+
baml_py/logging.py,sha256=zM-yKPJ3LF4qpIptYQVr5zw_Gjimy3deWlTt4dOzVp0,190
|
12
|
+
baml_py/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
13
|
+
baml_py/safe_import.py,sha256=turgUpn9B4G273ZuDVjfZ_CkA2qmFQyiP-ZCPhtJO4M,2888
|
14
|
+
baml_py/stream.py,sha256=pNfXDOa-6u4cjANaq071I6AevUx9N7DhDORc18Vh03k,6881
|
15
|
+
baml_py/type_builder.py,sha256=HIAlses70C5DWNWgx3ZwsLeGt5-tviWXCXZiyyWedSg,6374
|
16
|
+
baml_py-0.200.0.dist-info/RECORD,,
|
baml_py-0.90.1.dist-info/RECORD
DELETED
@@ -1,16 +0,0 @@
|
|
1
|
-
baml_py-0.90.1.dist-info/METADATA,sha256=dfqOnYNMNtHAl8j8oo_CqkZI1KaPu5fS0WkoERvr3YI,334
|
2
|
-
baml_py-0.90.1.dist-info/WHEEL,sha256=-VeZVZVER2HyvPbjF_EpJfcVOYx0xLg34sdR3QVUxMw,104
|
3
|
-
baml_py-0.90.1.dist-info/entry_points.txt,sha256=9Uu_VcUjoI2qQMjVb0PRjEgI6pQ55WqBbzNparAPJyA,54
|
4
|
-
baml_py-0.90.1.dist-info/licenses/LICENSE,sha256=QwcOLU5TJoTeUhuIXzhdCEEDDvorGiC6-3YTOl4TecE,11356
|
5
|
-
baml_py/__init__.py,sha256=QWyuR-eLmqkiRW5v9RKF83knRj_HG8fyTlp6Sse9D3o,827
|
6
|
-
baml_py/baml_py.abi3.so,sha256=ivftwi4VS71K2_zTLF0egOoDWY8e5B6J5jkVFWdi6Vg,40902064
|
7
|
-
baml_py/baml_py.pyi,sha256=YYyXU1tLGLhz2OMRm9lroIAaKmQ0RZfATQ5Dea8q73s,13858
|
8
|
-
baml_py/ctx_manager.py,sha256=p6Y4X1qfUExLeBeJKcVuf4WS9NrSabjRcRFrPIasTxY,5660
|
9
|
-
baml_py/errors.py,sha256=wqv7xT_-pVXQNxD5JbOrrr_CABCFuNrLrEhmEX8RVJ8,389
|
10
|
-
baml_py/internal_monkeypatch.py,sha256=JDwBPw4S8veD3nvJ13lFw8P5p29UOmDvvkgOy8eKA58,2106
|
11
|
-
baml_py/logging.py,sha256=zM-yKPJ3LF4qpIptYQVr5zw_Gjimy3deWlTt4dOzVp0,190
|
12
|
-
baml_py/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
13
|
-
baml_py/safe_import.py,sha256=turgUpn9B4G273ZuDVjfZ_CkA2qmFQyiP-ZCPhtJO4M,2888
|
14
|
-
baml_py/stream.py,sha256=RoHvdlYi1lap7DN0sCUA-H5HtAfxxePnm1nIe6BRTTs,6892
|
15
|
-
baml_py/type_builder.py,sha256=HIAlses70C5DWNWgx3ZwsLeGt5-tviWXCXZiyyWedSg,6374
|
16
|
-
baml_py-0.90.1.dist-info/RECORD,,
|
File without changes
|
File without changes
|