pycityagent 2.0.0a30__tar.gz → 2.0.0a31__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.
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/PKG-INFO +1 -1
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/simulation/agentgroup.py +55 -14
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pyproject.toml +1 -1
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/README.md +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/agent.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/economy/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/economy/econ_client.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/interact/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/interact/interact.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/message/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sence/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sence/static.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sidecar/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sidecar/sidecarv2.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/aoi_service.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/client.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/clock_service.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/economy_services.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/lane_service.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/light_service.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/person_service.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/road_service.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/sim_env.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/social_service.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/simulator.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/utils/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/utils/base64.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/utils/const.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/utils/geojson.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/utils/grpc.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/utils/map_utils.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/utils/port.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/utils/protobuf.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/llm/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/llm/embeddings.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/llm/llm.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/llm/llmconfig.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/llm/utils.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/memory/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/memory/const.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/memory/faiss_query.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/memory/memory.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/memory/memory_base.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/memory/profile.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/memory/self_define.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/memory/state.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/memory/utils.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/message/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/message/messager.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/metrics/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/metrics/mlflow_client.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/metrics/utils/const.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/simulation/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/simulation/simulation.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/simulation/storage/pg.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/survey/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/survey/manager.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/survey/models.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/utils/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/utils/avro_schema.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/utils/decorators.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/utils/parsers/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/utils/parsers/code_block_parser.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/utils/parsers/json_parser.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/utils/parsers/parser_base.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/utils/pg_query.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/utils/survey_util.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/workflow/__init__.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/workflow/block.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/workflow/prompt.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/workflow/tool.py +0 -0
- {pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/workflow/trigger.py +0 -0
@@ -409,6 +409,50 @@ class AgentGroup:
|
|
409
409
|
else:
|
410
410
|
for agent in self.agents:
|
411
411
|
_date_time = datetime.now(timezone.utc)
|
412
|
+
try:
|
413
|
+
nominal_gdp = await agent.memory.get("nominal_gdp")
|
414
|
+
except:
|
415
|
+
nominal_gdp = []
|
416
|
+
try:
|
417
|
+
real_gdp = await agent.memory.get("real_gdp")
|
418
|
+
except:
|
419
|
+
real_gdp = []
|
420
|
+
try:
|
421
|
+
unemployment = await agent.memory.get("unemployment")
|
422
|
+
except:
|
423
|
+
unemployment = []
|
424
|
+
try:
|
425
|
+
wages = await agent.memory.get("wages")
|
426
|
+
except:
|
427
|
+
wages = []
|
428
|
+
try:
|
429
|
+
prices = await agent.memory.get("prices")
|
430
|
+
except:
|
431
|
+
prices = []
|
432
|
+
try:
|
433
|
+
inventory = await agent.memory.get("inventory")
|
434
|
+
except:
|
435
|
+
inventory = 0
|
436
|
+
try:
|
437
|
+
price = await agent.memory.get("price")
|
438
|
+
except:
|
439
|
+
price = 0.0
|
440
|
+
try:
|
441
|
+
interest_rate = await agent.memory.get("interest_rate")
|
442
|
+
except:
|
443
|
+
interest_rate = 0.0
|
444
|
+
try:
|
445
|
+
bracket_cutoffs = await agent.memory.get("bracket_cutoffs")
|
446
|
+
except:
|
447
|
+
bracket_cutoffs = []
|
448
|
+
try:
|
449
|
+
bracket_rates = await agent.memory.get("bracket_rates")
|
450
|
+
except:
|
451
|
+
bracket_rates = []
|
452
|
+
try:
|
453
|
+
employees = await agent.memory.get("employees")
|
454
|
+
except:
|
455
|
+
employees = []
|
412
456
|
_status_dict = {
|
413
457
|
"id": agent._uuid,
|
414
458
|
"day": await self.simulator.get_simulator_day(),
|
@@ -418,20 +462,17 @@ class AgentGroup:
|
|
418
462
|
"parent_id": -1,
|
419
463
|
"action": "",
|
420
464
|
"type": await agent.memory.get("type"),
|
421
|
-
"nominal_gdp":
|
422
|
-
"real_gdp":
|
423
|
-
"unemployment":
|
424
|
-
"wages":
|
425
|
-
"prices":
|
426
|
-
"inventory":
|
427
|
-
"price":
|
428
|
-
"interest_rate":
|
429
|
-
"bracket_cutoffs":
|
430
|
-
|
431
|
-
|
432
|
-
"bracket_rates": await agent.memory.get("bracket_rates"),
|
433
|
-
"employees": await agent.memory.get("employees"),
|
434
|
-
"customers": await agent.memory.get("customers"),
|
465
|
+
"nominal_gdp": nominal_gdp,
|
466
|
+
"real_gdp": real_gdp,
|
467
|
+
"unemployment": unemployment,
|
468
|
+
"wages": wages,
|
469
|
+
"prices": prices,
|
470
|
+
"inventory": inventory,
|
471
|
+
"price": price,
|
472
|
+
"interest_rate": interest_rate,
|
473
|
+
"bracket_cutoffs": bracket_cutoffs,
|
474
|
+
"bracket_rates": bracket_rates,
|
475
|
+
"employees": employees,
|
435
476
|
"created_at": _date_time,
|
436
477
|
}
|
437
478
|
_statuses_time_list.append((_status_dict, _date_time))
|
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
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/environment/sim/economy_services.py
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
|
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
|
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
|
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
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{pycityagent-2.0.0a30 → pycityagent-2.0.0a31}/pycityagent/utils/parsers/code_block_parser.py
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
|