pycityagent 2.0.0a33__py3-none-any.whl → 2.0.0a34__py3-none-any.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.
pycityagent/workflow/block.py
CHANGED
@@ -168,16 +168,44 @@ class Block:
|
|
168
168
|
def llm(
|
169
169
|
self,
|
170
170
|
) -> LLM:
|
171
|
-
|
171
|
+
if self._llm is None:
|
172
|
+
raise RuntimeError(f"LLM access before assignment, please `set_llm` first!")
|
173
|
+
return self._llm
|
172
174
|
|
173
175
|
@property
|
174
176
|
def memory(
|
175
177
|
self,
|
176
178
|
) -> Memory:
|
177
|
-
|
179
|
+
if self._memory is None:
|
180
|
+
raise RuntimeError(
|
181
|
+
f"Memory access before assignment, please `set_memory` first!"
|
182
|
+
)
|
183
|
+
return self._memory
|
178
184
|
|
179
185
|
@property
|
180
186
|
def simulator(
|
181
187
|
self,
|
182
188
|
) -> Simulator:
|
183
|
-
|
189
|
+
if self._simulator is None:
|
190
|
+
raise RuntimeError(
|
191
|
+
f"Simulator access before assignment, please `set_simulator` first!"
|
192
|
+
)
|
193
|
+
return self._simulator
|
194
|
+
|
195
|
+
def set_llm_client(self, llm: LLM):
|
196
|
+
"""
|
197
|
+
Set the llm_client of the block.
|
198
|
+
"""
|
199
|
+
self._llm = llm
|
200
|
+
|
201
|
+
def set_simulator(self, simulator: Simulator):
|
202
|
+
"""
|
203
|
+
Set the simulator of the block.
|
204
|
+
"""
|
205
|
+
self._simulator = simulator
|
206
|
+
|
207
|
+
def set_memory(self, memory: Memory):
|
208
|
+
"""
|
209
|
+
Set the memory of the block.
|
210
|
+
"""
|
211
|
+
self._memory = memory
|
@@ -66,10 +66,10 @@ pycityagent/utils/parsers/parser_base.py,sha256=KBKO4zLZPNdGjPAGqIus8LseZ8W3Tlt2
|
|
66
66
|
pycityagent/utils/pg_query.py,sha256=h5158xcrxjUTR0nKwAaG1neFfTHPbN5guLmaXpC8yvs,1918
|
67
67
|
pycityagent/utils/survey_util.py,sha256=Be9nptmu2JtesFNemPgORh_2GsN7rcDYGQS9Zfvc5OI,2169
|
68
68
|
pycityagent/workflow/__init__.py,sha256=QNkUV-9mACMrR8c0cSKna2gC1mMZdxXbxWzjE-Uods0,621
|
69
|
-
pycityagent/workflow/block.py,sha256=
|
69
|
+
pycityagent/workflow/block.py,sha256=C2aWdVRffb3LknP955GvPcBMsm3VPXN9ZuAtCgITFTo,7181
|
70
70
|
pycityagent/workflow/prompt.py,sha256=6jI0Rq54JLv3-IXqZLYug62vse10wTI83xvf4ZX42nk,2929
|
71
71
|
pycityagent/workflow/tool.py,sha256=xADxhNgVsjNiMxlhdwn3xGUstFOkLEG8P67ez8VmwSI,8555
|
72
72
|
pycityagent/workflow/trigger.py,sha256=Df-MOBEDWBbM-v0dFLQLXteLsipymT4n8vqexmK2GiQ,5643
|
73
|
-
pycityagent-2.0.
|
74
|
-
pycityagent-2.0.
|
75
|
-
pycityagent-2.0.
|
73
|
+
pycityagent-2.0.0a34.dist-info/METADATA,sha256=za2dplTaxTwxYovvgF_HioNdjMXvmpTdg6v4Nx8Q2vI,8033
|
74
|
+
pycityagent-2.0.0a34.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
|
75
|
+
pycityagent-2.0.0a34.dist-info/RECORD,,
|
File without changes
|