Skip to content

Assistant types

A study runs one of two types of Assistant:

Advisor Copilot
What it is An AI assistant the participant talks to A full negotiation support system
It can answer messages and speak up on its own, with text, pictures, charts, questions with answer buttons and notifications; fill in the participant's offer and message when they ask (never send them) do everything an Advisor does, and (as far as the admin grants) fill and send offers, accept, highlight and annotate the screen, change the layout, show its own panels, add, read and use tools, and restyle the interface
The participant's screen fixed: the history and the offer area on one side; Preferences, Scenario Info and My Results above the chat on the other every view and every tool the study offers; the participant (and the Assistant) can rearrange it
Its class a subclass of hani2.assistant.Advisor any other Assistant (hani2.assistant.Assistant, also called Copilot)
Tutorial Build an Advisor Build a Copilot

An Advisor study tests the Assistant as an AI assistant: with the screen and the tools the same for everyone, the only difference between two Advisors is what they say and when. A Copilot study tests the Assistant as a whole support system, where a submission may be a new visualization, a new way of acting for the participant or a chat agent.

Copilot is the default.

Choosing the type

Set assistant_type in project.yaml (for every study of the project) or in study.yaml (for one study):

# study.yaml
assistant_type: advisor   # or copilot

In the admin console, open Projects, pick the project or the study, and choose Assistant type among its defaults. An empty field keeps the project's type.

Outside a study (the playground, a quick test), start the server with the type:

hani2 --assistant-type advisor
hani2 --assistant my_advisor.py:MyAdvisor     # an Advisor class sets advisor by itself

--assistant-type sets the environment variable HANI2_ASSISTANT_TYPE, which wins over every study and project. An admin can try a session of the other type with ?assistant_type=advisor (or copilot) in the page's URL.

Only Assistants of the study's type run

An Advisor study runs only Advisors, and a Copilot study only Copilots. This holds wherever the Assistant comes from: assistants in study.yaml or project.yaml, a group, schedule.json, the URL or --assistant. An Assistant of the other type is never replaced by another one: the session runs without an Assistant and shows the error (a banner, a notification, an ERROR event and the assistant_error column), for example:

my_agent:MyAgent is a Copilot, but this study runs Advisors (assistant_type: advisor); use an Advisor subclass or switch the study to copilot

Saving a study whose assistants list a class of the other type is refused with the same reason. The participant's own choice of Assistant, where the study lets them choose, lists only Assistants of the study's type. In the library (Assistants), every Assistant shows its type.

When nothing names an Assistant, a Copilot study runs agent_class from assistant_settings.json and an Advisor study runs advisor_class from the same file; each falls back to the built-in one. The built-in groups follow the type too: :default is that configured Assistant, and :tutorial holds the tutorial Assistants of the study's type.

A self-hosted Assistant (remote:<name>) takes the study's type: in an Advisor study its host is offered only the Advisor's functions, and the screen stays fixed.

The Advisor's screen

  • Wide screens (desktops, tablets held sideways): the history with the offer area under it fills the left; on the right the scenario information sits above the Advisor's chat. The buttons in the chat's header move it: Full height gives it its own column beside the scenario information (which then takes the full height too), Under the scenario information brings it back, Pop out puts it in a window you can drag and resize, and Pin back returns it to where it was. The dividers resize; the browser remembers the choice.
  • Phones and tablets held upright: three tabs, Negotiate, Scenario and the Advisor. A question from the Advisor brings its tab to the front.

The participant cannot switch views, hide, move or enlarge tools, or pick how the Advisor appears: it is always a panel (in one of the places above). They can still switch the Advisor off and back on when the study allows it, and choose whether its unprompted messages arrive as notifications or in the chat. The only tools are Preferences, Scenario Info and My Results, each only when the study offers it (an information split may still hide one, see Who knows what). The status board, the offer generators and the tools menu are not there, and the autopilot cannot be driven by an Advisor.

What an Advisor may do

An Advisor's abilities are at most these, whatever the admin grants:

Ability Key
Chat and ask questions chat
Pictures and charts in its messages chat_media
Notifications toast
Fill in the offer and the message (when the participant asks), never sending them fill_offer, fill_text
Choose the offer and message the action panel starts with on each turn (off by default) starting_offer
Use what only it knows in this negotiation private_info
The admin-only abilities that do not touch the screen opponent_utility, model_choice, own_models

Switching one of these off in the Assistant settings switches it off for Advisors too. An Advisor does not answer the interface's AI features (Write message, Offer from message): the interface uses its own model.

The built-in Advisor says a short word on every offer the participant receives (what it is worth to them, and whether it is worse than no deal or good enough to consider); with starting_offer it also starts their counter-offer at what they can still aim for, conceding slowly as time runs out. advisor_turn_notes: false in assistant_settings.json (the console: The built-in Advisor comments on each offer) keeps it quiet until asked. It fills in the offer or the message otherwise only when the participant asks for it; the participant checks and sends it. With starting_offer, an Advisor's on_turn may also choose the offer and message the action panel starts with on each turn (see The participant's turn).

The built-in Advisor chats with the study's language model, using advisor_system_prompt from assistant_settings.json (empty: its own prompt). Its unprompted turns follow the same proactive settings as a Copilot's (see Proactive messages).

Results

Every row of results.csv records the type in the assistant_type column (copilot or advisor), and the session state and the recorded snapshots carry it too. Pictures and charts in the chat are recorded with the message (components), so a replay shows them.