MridulNegi2005 commited on
Commit
ec1221d
·
1 Parent(s): 6e491ce

Optimize baseline prompt: multi-round negotiation strategy, all 3 tasks now pass

Browse files
Files changed (1) hide show
  1. inference.py +20 -8
inference.py CHANGED
@@ -71,23 +71,35 @@ def run_task(client, model_name: str, task_config):
71
 
72
  target_goal = "buy for as low as possible (below your maximum value)" if obs.role == "buyer" else "sell for as high as possible (above your minimum value)"
73
 
74
- prompt = f"""You are negotiating as a {obs.role}. Your goal is to {target_goal} to maximize profit.
75
 
76
- State:
77
- * Your PRIVATE Valuation: {obs.agent_value} (DO NOT accept or offer a deal worse than this!)
78
  * Current offer on the table: {obs.current_offer}
79
  * Round: {step_n} of {obs.max_rounds}
80
  * Opponent's last action: {obs.last_opponent_action}
81
  * Opponent's last offer: {obs.last_opponent_offer}
82
 
83
- {history_text}CRITICAL RULE: NEVER make an OFFER that is worse than your private valuation. For example, if you are a buyer with a valuation of 500, never offer >500.
 
 
 
 
 
 
 
 
 
 
 
 
84
 
85
  Choose exactly ONE action:
86
- * OFFER <price> — make a counter-offer (negotiate toward your private valuation)
87
- * ACCEPT — accept the opponent's offer (ONLY if it is profitable compared to your valuation)
88
- * REJECT — walk away (only if no deal is possible)
89
 
90
- Respond with ONLY your chosen action, nothing else."""
91
 
92
  action_str = "REJECT"
93
  action_price = 0
 
71
 
72
  target_goal = "buy for as low as possible (below your maximum value)" if obs.role == "buyer" else "sell for as high as possible (above your minimum value)"
73
 
74
+ prompt = f"""You are an expert negotiator acting as a {obs.role}. Your objective is to {target_goal} and maximize your profit through strategic multi-round bargaining.
75
 
76
+ CURRENT STATE:
77
+ * Your PRIVATE Valuation: {obs.agent_value} (your absolute limit NEVER go past this)
78
  * Current offer on the table: {obs.current_offer}
79
  * Round: {step_n} of {obs.max_rounds}
80
  * Opponent's last action: {obs.last_opponent_action}
81
  * Opponent's last offer: {obs.last_opponent_offer}
82
 
83
+ {history_text}YOUR NEGOTIATION PLAYBOOK:
84
+
85
+ ROUND-BY-ROUND STRATEGY (you are a {obs.role}):
86
+ {"- Round 1: Start AGGRESSIVE. Offer around 30-35% of the opponent's opening price. (e.g., if they open at 1000, offer 300-350). This anchors the negotiation in your favor." if obs.role == "buyer" else "- Round 1: Start AGGRESSIVE. Offer around 2-3x your minimum value. This anchors the negotiation in your favor."}
87
+ - Round 2-3: Concede SLOWLY. Increase your offer by only 50-80 per round. Watch how the opponent responds.
88
+ - Round 3-4: If the opponent's counter-offer is profitable for you ({"below" if obs.role == "buyer" else "above"} your valuation), ACCEPT it. Otherwise make one final offer near the midpoint.
89
+ - Round 5+: You are running out of time. ACCEPT any profitable deal immediately.
90
+
91
+ SCORING RULES:
92
+ 1. PROFIT MATTERS MOST: Your score = (your profit) × (time bonus). A great deal on round 3 beats a mediocre deal on round 1.
93
+ 2. TIME BONUS: Decreases each round. Don't drag past round 5.
94
+ 3. AGGRESSION PENALTY: Offers extremely far from reasonable (e.g., offering 100 when market is 500+) are penalized. Stay within a plausible range.
95
+ 4. NEVER REJECT unless it's the absolute last round and you cannot profit.
96
 
97
  Choose exactly ONE action:
98
+ * OFFER <price> — counter-offer (follow the round strategy above)
99
+ * ACCEPT — accept if the opponent's offer gives you good profit
100
+ * REJECT — walk away (almost never do this)
101
 
102
+ Respond with ONLY your action. Example: OFFER 350"""
103
 
104
  action_str = "REJECT"
105
  action_price = 0