Skip to contents

Run a single round of the society: the chosen agents each speak once, given the shared history so far, and their utterances are appended with a new step index. Speaking uses the Agent's stateless reply() over the shared transcript (the same role-flipped construction conversation() uses), so no agent writes to its own memory and the transcript remains the single record.

Usage

step_interaction(society, who = NULL, prompt = NULL, ...)

Arguments

society

A society().

who

Optional character vector of agent names to speak this round; the default lets every connected agent speak.

prompt

Optional instruction appended as the "your turn" cue for each speaker. Default: "Contribute to the discussion."

...

Passed to each agent's underlying LLMR call.

Value

The updated society() (its step incremented and history extended by one utterance per speaker).

Details

Who speaks: all of who (by agent name) when supplied, otherwise every agent that has at least one edge in the network (an isolate with no edges is skipped). Each speaker currently sees the full shared history; the edge list is recorded as the exposure structure (see exposure_matrix()) rather than used to mask the transcript, which keeps the round simple while leaving the connectivity available for analysis.

Examples

if (FALSE) { # \dontrun{
soc <- step_interaction(soc, prompt = "React in one sentence.")
soc$history
} # }