Skip to content

Commit 2c87880

Browse files
committed
Bump version to v0.0.3
1 parent afecb1d commit 2c87880

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ trustdynamics = ["py.typed"]
1313

1414
[project]
1515
name = "trustdynamics"
16-
version = "0.0.2"
16+
version = "0.0.3"
1717
description = "A Python framework for modeling trust dynamics in human–AI and organizational networks"
1818
readme = "README.md"
1919
license = {text = "MIT"}

trustdynamics/organization/organization.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -306,21 +306,21 @@ def set_agent_homophily_normative_tradeoff(self, agent: int | str, value: float)
306306
raise ValueError("Agent must exist in the organization to set homophily_normative_tradeoff.")
307307
self.G_agents.nodes[agent_id]["homophily_normative_tradeoff"] = float(value)
308308

309-
def get_agent_opinion_technology_use_cutoff(self, agent: int | str) -> float:
309+
def get_agent_technology_use_cutoff_opinion(self, agent: int | str) -> float:
310310
agent_id = self.search(agent)
311311
if agent_id is None:
312312
raise ValueError(
313-
"Agent must exist in the organization to get opinion_technology_use_cutoff."
313+
"Agent must exist in the organization to get technology_use_cutoff_opinion."
314314
)
315-
return self.G_agents.nodes[agent_id].get("opinion_technology_use_cutoff", 0.0)
315+
return self.G_agents.nodes[agent_id].get("technology_use_cutoff_opinion", 0.0)
316316

317-
def set_agent_opinion_technology_use_cutoff(self, agent: int | str, value: float) -> None:
317+
def set_agent_technology_use_cutoff_opinion(self, agent: int | str, value: float) -> None:
318318
agent_id = self.search(agent)
319319
if agent_id is None:
320320
raise ValueError(
321-
"Agent must exist in the organization to set opinion_technology_use_cutoff."
321+
"Agent must exist in the organization to set technology_use_cutoff_opinion."
322322
)
323-
self.G_agents.nodes[agent_id]["opinion_technology_use_cutoff"] = float(value)
323+
self.G_agents.nodes[agent_id]["technology_use_cutoff_opinion"] = float(value)
324324

325325
# =========================
326326
# Team-level parameters

trustdynamics/organization/serialization.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ def _ensure_node_opinions_list(G):
111111
"self_trust_learning_rate": 0.0,
112112
"trust_learning_rate": 0.0,
113113
"homophily_normative_tradeoff": 0.5,
114-
"opinion_technology_use_cutoff": 0.0,
114+
"technology_use_cutoff_opinion": 0.0,
115115
}
116116

117117
def _apply_defaults(G, defaults: dict):
@@ -136,7 +136,7 @@ def _coerce_types_agent(attrs: dict):
136136
"self_trust_learning_rate",
137137
"trust_learning_rate",
138138
"homophily_normative_tradeoff",
139-
"opinion_technology_use_cutoff",
139+
"technology_use_cutoff_opinion",
140140
):
141141
attrs[k] = float(attrs.get(k, 0.0))
142142

0 commit comments

Comments
 (0)