Skip to content

Who knows what

By default the human and the Assistant know the same kind of things: the human's preferences, the scenario and everything that happens in the negotiation. To study how a person and an AI collaborate, you can give them different information, so that each holds something the other needs. The information setting does this, per project, per study or for the whole server.

It can split these kinds of information:

What Example
Past negotiations Records of earlier negotiations in the same scenario. The human gets some of them and the Assistant gets the rest.
Preferences The human knows how important each issue is (the weights), and the Assistant knows what each option is worth (the values).
Market research Only the Assistant knows how preferences in this scenario are usually distributed, as if it had done a market study.
Private briefings Only the human is told "your manager will not approve a rent above 3200", a limit that is not in their preferences. The Assistant has to ask.
Decisions only the human makes The Assistant may suggest a price or suggest accepting, but only the human can set the price or accept.

Each part can be used alone or together with the others. When nothing is set, nothing is split and HANI2 behaves exactly as before.

Setting it

Put an information block in a study's study.yaml, a project's project.yaml, or env.json → negotiation. Only the keys you give change. A study's block replaces its project's block as a whole, as with every other study setting.

projects/HI2027/studies/split-01/study.yaml
information:
  past_negotiations:
    count: 6            # six past negotiations per scenario
    human_share: 0.5    # three for the human, three for the Assistant
  preferences:
    human: weights      # the human sees the issue weights
    assistant: values   # the Assistant knows what each option is worth
  market_research:
    audience: assistant

In the admin console, the project and study forms under Projects have an Information split section with the most-used keys. Edit the file for the others.

All the keys and their defaults:

information:
  past_negotiations:
    count: 0                 # how many past negotiations each scenario has (0: none)
    preferences: similar     # similar | same | different: how the past parties' preferences relate to this one's
    opponent_preferences:    # the same, for the opponent's side only (empty: as preferences)
    noise: 0.25              # how far "similar" preferences move (0 to 1)
    human_share: 0.5         # the fraction for the human; the Assistant gets the rest (0: all to the Assistant, 1: all to the human)
    shared: false            # true: both get every record
    assignment: random       # random (per participant and round) | first (the human gets P1, P2, ...)
    utilities: own           # what a record shows: own (the utilities of the party in the human's role) | both | none
    n_steps: 20              # rounds of a simulated negotiation
    negotiators: [BoulwareTBNegotiator, LinearTBNegotiator, ConcederTBNegotiator, NaiveTitForTatNegotiator]
    use_scenario_file: true  # use the scenario folder's _past_negotiations.yaml when it has one
    seed: 0
  preferences:
    human: full              # full | weights | values | none: what the human knows of their own preferences
    assistant: full          # the same, for the Assistant
    reserved_value: both     # both | human | assistant | none: who knows the value on disagreement
    show_totals_to_partial: false  # show deal values to a side that knows only part of the preferences
  market_research:
    audience: none           # none | assistant | human | both
    sides: opponent          # opponent | own | both: whose preferences it describes
    samples: 40              # how many comparable profiles the statistics come from
    noise: 0.3               # how spread out those profiles are
  briefing: []               # private instructions, added to the scenario's own (see below)
  use_scenario_briefing: true   # use the briefing in the scenario's _info.yaml
  briefing_audience:         # human | assistant | both: give the scenario's briefings to this side instead
  control:
    human_only_issues: []    # issues only the human may set
    human_only_actions: []   # any of send, accept, end: actions only the human may take

Past negotiations

A past negotiation is a record of an earlier negotiation in the same scenario (the same issues and options). Records give the Assistant (or the human) knowledge that the other side of the team lacks, so they have to work together. A record has every offer and, by default, every message with its text. It also says who made each offer and how the negotiation ended. Each offer carries what it was worth to both past parties, by their own preferences.

Switching them on

enabled is the on/off switch. Set it in general (the Settings page, env.json → negotiation.information), for a project (project.yaml) or for a study (study.yaml). Each has a Simulated past negotiations row at the top of its Information settings:

study.yaml
information:
  past_negotiations:
    enabled: true        # 10 past negotiations per scenario, all of them for the Assistant

Switched on this way, every record goes to the Assistant: it knows something the human does not. Set human_share to give the human some of them too. enabled: false switches them off whatever count says. When enabled is not set, count decides, and its default of 0 means none.

The past_negotiations keys merge across the layers, key by key: env.json, then the project, then the study. So a study that only says enabled: true keeps the project's conditions, share and tool access. The rest of a study's information block replaces the project's as a whole.

Six conditions

Six independent choices decide how the past negotiations relate to the negotiation being played. "Your side" is the party in the human's role.

Setting Values What it decides
self_preferences same, similar, any your side's utility function
opponent_preferences same, similar, any the opponent's utility function
self_reserved same, similar, any your side's value on disagreement
opponent_reserved same, similar, any the opponent's value on disagreement
self_agent same, variable, runtime who negotiated for your side
opponent_agent same, variable, runtime who negotiated for the opponent
  • same is exactly this negotiation's function or value. similar moves it by about noise (weights, option values, value on disagreement). any is an unrelated random one over the same issues, or for a value on disagreement, anywhere in the lower 60% of the range. different is the old name of any.
  • preferences is the default of both self_preferences and opponent_preferences. An unset *_reserved is same when the preferences are same, else similar.
  • An agent choice is a mode or a mapping:

    self_agent: {mode: same, agent: BoulwareTBNegotiator}                 # one agent for every record
    opponent_agent: {mode: variable, agents: [LinearTBNegotiator, HybridWithTextNegotiator]}
    

    same plays every record with agent, or with one agent picked at random from agents (empty: the standard negotiators). variable picks one from agents (empty: negotiators) for each record. runtime decides when the negotiation starts:

    • opponent_agent: runtime uses the opponent the human is facing. A person or a self-hosted opponent cannot play the records; their opponents then vary.
    • self_agent: runtime uses the human's Assistant on autopilot. With a negotiator as autopilot driver, that negotiator plays your side. With the Assistant as driver, it plays your side in a headless session of its own that writes no results or recordings. An Advisor does not negotiate, so with one the agents vary.

    Run-time records are played in the background once the negotiation starts. Until they are ready, the tools say so and the Assistant is told they are on their way. Records with a language-model agent are played the same way, never while a scenario loads. When a run-time agent cannot play, the conditions say what happened instead (mode: variable, requested: runtime). A scenario file played without run-time agents is not used by a study that asks for them.

  • keep: full (the default) keeps every message with its text. keep: offers keeps only the offers exchanged.

  • count (how many), n_steps (rounds), noise and seed complete the conditions.

The conditions are saved with the records and shown to everyone who sees them: admins in the scenario explorer, the human in the Related Negotiations tool and the Assistant in get_private_information.

Where the records come from

When the scenario folder has a _past_negotiations.yaml, its records are used (the first count of them, and only those generated for the human's role). Otherwise HANI2 simulates them when the scenario is loaded, or once the negotiation starts for run-time agents. A simulation is deterministic: the same scenario, settings and run-time agents always give the same records. So in a strict study every participant who meets a scenario sees the same records.

To fix the records, or to edit them, write them into the scenario folders. There are three ways:

  • When making scenarios: hani2 generate --past 10 writes 10 past negotiations next to every scenario it generates. --past-options sets the conditions, as inline JSON or a JSON/YAML file.

    hani2 generate --type Lease -n 20 --past 10 \
      --past-options '{"self_preferences": "same", "opponent_preferences": "any", "keep": "offers"}'
    
  • For existing scenarios:

    hani2 scenario past ~/negmas/hani2/settings/scenarios/Lease              # 10 per scenario
    hani2 scenario past ./Lease/0003 --count 4 --self-preferences same --opponent-preferences any \
      --opponent-agent variable --opponent-agents BoulwareTBNegotiator,HybridWithTextNegotiator --keep full
    hani2 scenario past ./Lease --all-roles   # records for every role, whichever the human plays
    
  • In the scenario explorer (Library → Scenarios → a type → Past negotiations): pick the conditions and press Generate. A pool scenario's records replace its file. A generated sample's stay on the page.

Run-time agents are known only in a session, so the generators make them vary, and each record says how its agents were chosen. --force replaces an existing file. The file is plain YAML. You can add a notes text to a record, or write records of real negotiations by hand:

Lease/0003/_past_negotiations.yaml
conditions:
  self_preferences: similar
  opponent_preferences: any
  self_reserved: similar
  opponent_reserved: similar
  self_agent: {mode: variable, agent: null, agents: [BoulwareTBNegotiator, ConcederTBNegotiator]}
  opponent_agent: {mode: same, agent: HybridWithTextNegotiator, agents: []}
  count: 10
  keep: full
  n_steps: 20
  noise: 0.25
  seed: 0
  roles: [Tenant]
negotiations:
- id: P1
  roles: [Landlord, Tenant]
  self_role: Tenant
  agents: {Landlord: HybridWithTextNegotiator, Tenant: ConcederTBNegotiator}
  steps: 12
  agreement: {Rent: 3200, Deposit: 2000, Move-in date: 1 June, Lease length: 1 year}
  utilities: {Landlord: 0.71, Tenant: 0.55}
  reserved_values: {Landlord: 0.12, Tenant: 0.05}
  similarity: {Landlord: 0.12, Tenant: 0.93}
  offers:
  - {step: 0, by: Landlord, offer: {Rent: 3600, Deposit: 4000, Move-in date: 1 May, Lease length: 2 years},
     utilities: {Landlord: 1.0, Tenant: 0.0}, text: "Here is where I would like to start."}
  # ...
  notes: The tenant gave in on rent to get the move-in date.

similarity is how alike each past party's preferences are to this scenario's. It is the correlation of their utilities over the outcomes: 1 is the same ranking and spacing of deals, 0 is unrelated, -1 is opposed. Rescaling either function does not change it. ufuns (not shown above) keeps the past parties' utility functions, for the plots and for the Assistant's past_negotiation_preferences.

Who gets which

human_share decides how many records the human gets. With assignment: random each participant gets a random share that is fixed for that participant and round. shared: true gives every record to both.

The human sees their records in the Past Negotiations tool: a table of the records, and for the one picked, its offers in a chart and a table. The tool tells them how many records their Assistant has. It knows the ids the human holds but not what is in them, and it cannot read the human's tool, unless every record in it is one the Assistant holds as well.

The Assistant, an Advisor or a Copilot, reads its own records through functions. None of them is put in its prompt:

  • get_private_information gives a summary of each record and the conditions they were generated under.
  • show_past_negotiation gives every offer and message of one record. For each offer it shows what it was worth to your side then, and what it is worth to the human now.
  • past_negotiation_preferences gives your side's preferences in one record, as much as the Assistant knows of the human's own (see preferences.assistant), and how alike they are.

The Assistant never sees the opponent's preferences, its value on disagreement or its utilities, even with utilities: both. With opponent_preferences: same those would be the real opponent's.

Related Negotiations explores the past negotiations:

  • How they were generated: the conditions.
  • A summary table: who negotiated for each side, the result, the rounds, what your side got, and how alike your side's preferences were to the human's.
  • One record, as a chat (every offer and message) or as a plot.

tool decides who gets it: admins (the default) or everyone. Set it in general, in a project or in a study, like enabled.

  • An admin sees every record with both sides: the opponent's utilities, both values on disagreement, the opponent's similarity, and the negotiation in a 2D utility plot.
  • A participant sees only the records they hold. The opponent's side is left out, so instead of the 2D plot they see what each offer was worth to their side and a histogram of the options each side offered. tool_opponent: true shows them the opponent's side too.
  • The Assistant reading the tool sees only its own records, never the opponent's side.

The scenario explorer has the same view for admins (Past negotiations): the conditions, the summary table and every record as a chat or a 2D plot.

Preferences

preferences.human and preferences.assistant say how much each side knows of the human's utility function:

Value Means
full Everything (the default).
weights How important each issue is.
values What each option of each issue is worth.
none Nothing.

For example, human: weights, assistant: values gives each side one half. The human's Preferences tool then shows only the issue weights, with a note that the Assistant knows the option values. get_private_information gives the Assistant the option values.

A side that does not know the full function cannot see what a deal is worth to the human, and HANI2 hides these numbers from it:

  • The human loses the utility gauges on the offer on the table and on their draft, and the utilities in the history. The tools that show deal values are not offered: Utility Plot, Negotiation Plot, Trace, Utility Selector and Response Generator. The counter-offer fields are not filled with the human's best deal, and the scenario hints are hidden, because they are worked out from the preferences.
  • The Assistant gets no utilities in the negotiation state, and the scenario hints are hidden from it as well.
  • Past negotiations show no utilities to a side that cannot see deal values, whatever utilities says, since with preferences: same they would be the real values.

Set show_totals_to_partial: true to show deal values to a side that knows only part of the preferences.

reserved_value says who knows the value on disagreement. The human's Preferences tool shows it at the top (right under In short, or first of all when they know only part of their preferences) and says so when they do not know it, and the Assistant's state leaves it out when it does not.

Weights and values exist only for preferences that are a weighted sum of issue values, which is true of every built-in scenario type. For other preferences HANI2 cannot split them: both sides know them fully, and admins get a warning when the scenario is loaded.

Market research

Market research tells what parties in this scenario usually want. For each role it covers (sides), it gives:

  • the typical weight of each issue, with its spread;
  • the option of each issue that is most often the best, and how often;
  • the most likely best deal;
  • the usual value on disagreement.

It is computed from samples other scenarios of the same type: new ones from the type's generator, or the saved scenarios of the category when the type has no generator. So it describes the population the preferences are drawn from, not this opponent. A one-off scenario, with neither a generator nor at least two saved scenarios, falls back to profiles near the real preferences (noise says how near). These are close to the opponent's own preferences, and admins get a warning when the scenario is loaded. A scenario can add its own text under market_research in _info.yaml, either one text or one per role:

_info.yaml
market_research:
  Landlord: Landlords in this district rarely lower the rent but often waive the deposit.

With audience: assistant it reaches the human only through what the Assistant tells them. With audience: human the human gets a Market Research tool.

What the Assistant is told

When the two sides know different things, the negotiation state the Assistant reads with every message has an information section. It says what each side knows and which past negotiations the human holds, but not their contents. The Assistant's instructions tell it to call get_private_information and to ask the participant about what only they know.

The new ability private_info (Its own information) unlocks get_private_information and show_past_negotiation. Both are offered only in rounds where something is split. Like every ability, participants can switch it off when the interface allows it. See the Assistant guide.

Python Assistants can read self.session.human_ufun directly, and HANI2 cannot stop that. To keep to the study's design, use the helpers instead:

class MyAssistant(Assistant):
    def on_event(self, event_name, nmi=None):
        if event_name == "negotiation_started":
            mine = self.private_information()  # what only the Assistant knows
            for rec in mine.get("past_negotiations_you_hold", []):
                full = self.past_negotiation(rec["id"])["negotiation"]
                ...

self.session.information is the round's InformationState. It says which part of the preferences each side knows (human_prefs, assistant_prefs), which past negotiations each holds (human_past, assistant_past) and whether deal values may be shown (human_sees_totals, assistant_sees_totals).

Tools can depend on the split too. A tool with needs_totals = True is not offered while the human cannot see deal values. A tool with private_information = True cannot be read or used by the Assistant while the two sides know different things; override private_now() to refuse it only when it shows something the Assistant does not know. Preferences does this: with only past negotiations split, the Assistant still reads it. Override available() to offer a tool only in some rounds. See Tools.

Negotiator autopilot

An autopilot driven by a negotiator plays with the human's full preferences. In studies that split the preferences, use the Assistant as the autopilot driver, or turn the autopilot off.

Private briefings and hidden constraints

A briefing is a private instruction for one side, such as a limit set by someone the human negotiates for, or a preference that is not in the utility function. A scenario writes its briefings in _info.yaml, per role. A study can add its own under information.briefing.

_info.yaml
briefing:
  Tenant:
    text: Your family insists on a one-year lease; anything else needs their approval.
    constraints:
      - {issue: Lease length, allowed: [1 year]}
  Landlord:
    to: human              # human (default) | assistant | both
    text: The bank needs the rent to be at least 3000.
    constraints:
      - {issue: Rent, min: 3000}

Only the briefing for the role the participant plays is used. An entry is a text, a mapping with text, to, constraints and pin, or a list of those. Without a text, the constraints are written out in words. A constraint names an issue and any of min, max, allowed (a list of options) and forbidden.

  • A briefing for the human is shown in the Briefing tool and pinned above the negotiation when it starts (pin: false turns that off). The Assistant cannot read it. It is told only that the participant has a private briefing and that it should ask them about it.
  • A briefing for the Assistant reaches it through get_private_information.
  • briefing_audience redirects a scenario's briefings, so one scenario serves several conditions: assistant gives the human's limit to the Assistant instead, and use_scenario_briefing: false leaves it out for a control group.

The constraints are checked against the agreement, on the raw option values. Each results row has constraints_met: 1 when the agreement keeps every constraint, 0 when it breaks one (constraint_violations counts the broken ones), and empty without an agreement. The dual_control evaluation metric gives the same from a recording.

Briefing texts stay out of the scenario once a round is set up: the opponent, the tools and the saved copy of the scenario never see them, and the results row names briefings only by id (B1:human). The recording keeps the texts. Nothing stops a participant from breaking a limit, so the column shows whether the information reached the decision.

Decisions only the human makes

control keeps some decisions for the human. The Assistant may only suggest them:

information:
  control:
    human_only_issues: [Price]     # the Assistant cannot fill these in
    human_only_actions: [accept]   # nor take these actions: send, accept, end
  • When the Assistant fills in the offer, the human-only issues keep the participant's values, and the Assistant is told so.
  • A human-only send, accept or end by the Assistant becomes a suggestion: it fills in the offer and highlights the button, whatever its autonomy level. Because sending or accepting decides every issue, a human-only issue makes sending and accepting the participant's decision too. The session also refuses these actions from Python Assistants.
  • The negotiation state marks each human-only issue with only_the_participant_may_set. The participant sees the rules in the Briefing tool and in a pinned note.
  • The autopilot is not restricted, because the participant handed it the controls.

In the results

When something is split, each results row has these columns:

Column Content
information_split True
info_human_preferences, info_assistant_preferences What each side knew of the preferences.
info_human_reserved_value, info_assistant_reserved_value Whether each side knew the value on disagreement.
info_past_negotiations, info_past_source How many records there were, and where they came from (scenario or simulated).
info_human_past, info_assistant_past The ids each side held.
info_market_research Who got the market research.
info_briefings The briefings by id and audience (B1:human,B2:assistant).
constraints_met, constraint_violations Whether the agreement kept the briefings' constraints, and how many it broke (see above).
info_human_only_issues, info_human_only_actions What only the human could set or do.

The recording of the negotiation keeps the same data and the records themselves, under information in its scenario entry. The scenario-loaded event has it too.