Home

Chat Message

This is an executable type used in Stencila Schema for an individual message within a Chat.

It exists so messages can carry structured parts, execution state, attachments, and model-generated metadata rather than being reduced to plain text. This supports richer conversational documents and tooling for reviewing, replaying, or transforming model interactions.

Key properties include the message role, message parts or content, and inherited execution metadata from Executable.

This type is marked as unstable and is subject to change.

Analogues

The following external types, elements, or nodes are similar to a ChatMessage:

  • OpenAI chat message: Close analogue for role-based conversational turns, though Stencila messages can include block document content and attached files.

  • Anthropic message: Close provider-level analogue for structured chat turns.

Properties

The ChatMessage type has these properties:

NameDescriptionTypeInherited from
authorThe author of the messageAuthor-
roleThe role of the message in the conversation.MessageRole-
contentThe content of the message.Block*-
filesThe content of the message.File*-
isSelectedWhether this message is the selected message in the parent ChatMessageGroupBoolean-
executionModeUnder which circumstances the node should be executed.ExecutionModeExecutable
compilationDigestA digest of the content, semantics and dependencies of the node.CompilationDigestExecutable
compilationMessagesMessages generated while compiling the code.CompilationMessage*Executable
executionDigestThe compilationDigest of the node when it was last executed.CompilationDigestExecutable
executionDependenciesThe upstream dependencies of this node.ExecutionDependency*Executable
executionDependantsThe downstream dependants of this node.ExecutionDependant*Executable
executionTagsTags in the code which affect its execution.ExecutionTag*Executable
executionCountA count of the number of times that the node has been executed.IntegerExecutable
executionRequiredWhether, and why, the code requires execution or re-execution.ExecutionRequiredExecutable
executionStatusStatus of the most recent, including any current, execution.ExecutionStatusExecutable
executionInstanceThe id of the kernel instance that performed the last execution.StringExecutable
executionEndedThe timestamp when the last execution ended.TimestampExecutable
executionDurationDuration of the last execution.DurationExecutable
executionMessagesMessages emitted while executing the node.ExecutionMessage*Executable
idThe identifier for this item.StringEntity

Related

The ChatMessage type is related to these types:

Bindings

The ChatMessage type is represented in:


This documentation was generated from ChatMessage.yaml by docs_types.rs.

© 2026 Stencila