"""Runs the model if strategy is False, otherwise uses a classical method."""
ifself.strategy:
returnself.apply_random(m,n)
instruction=f"""
You have $100 to allocate between yourself and an anonymous person.
- Allocating 1 point for yourself is worth {m} dollars.
- Allocating 1 point for the other person is worth {n} dollars.
Your goal is to decide how to allocate these $100.
Example:
- If `m = 1` and `n = 2`, then for every point you allocate to yourself, you receive $1, and for every point you allocate to the other person, they receive $2.
- If you choose to allocate 30 points to yourself, then you would receive 30 * 1 = $30, and the other person would receive $100 - $30 = $70 .
- Thus, your total allocation would be 30 points for yourself and 70/2 = 35 points for the other person, totaling $100.
Please provide:
- How many points you want to allocate to yourself (out of $100),
- How many points you want to allocate to the other person.
Your response should be in JSON format with `my_share`, `other_share`, and `reasoning`.
"""
forattemptinrange(self.max_retries):
agent=AssistantAgent(
name="Dictator",
model_client=self.model_client,
system_message="You are a helpful assistant. You will be given 25 rounds of decision-making tasks and will be responsible for making decisions. You should use your best judgment to come up with solutions that you like most."