Open Agent Loops
API Reference

Role

@open-agent-loops/core


Defined in: types/roles.ts:17

Conversation roles.

Remarks

A string enum whose values are the OpenAI wire strings, so JSON.stringify of a message still emits "role":"user" etc. — the wire shape is unchanged; only in-code references become named constants.

Enumeration Members

Enumeration MemberValueDescriptionDefined in
Assistant"assistant"A model turn.types/roles.ts:23
System"system"The system prompt role.types/roles.ts:19
Tool"tool"A tool-result turn.types/roles.ts:25
User"user"A user turn.types/roles.ts:21

On this page