Prompt Block
A preview of how a prompt will be rendered at a location in the document
Used on an Instruction
to render a prompt and display the rendering to the user.
Can also be used standalone to preview how a prompt is rendered at a particular
position in a document.
This type is marked as unstable and is subject to change.
Properties
The PromptBlock
type has these properties:
Name | Description | Type | Inherited from | JSON-LD @id |
Aliases |
---|---|---|---|---|---|
id |
The identifier for this item. | String |
Entity |
schema:id |
- |
executionMode |
Under which circumstances the node should be executed. | ExecutionMode |
Executable |
stencila:executionMode |
execution-mode , execution_mode |
compilationDigest |
A digest of the content, semantics and dependencies of the node. | CompilationDigest |
Executable |
stencila:compilationDigest |
compilation-digest , compilation_digest |
compilationMessages |
Messages generated while compiling the code. | CompilationMessage * |
Executable |
stencila:compilationMessages |
compilation-messages , compilation_messages , compilationMessage , compilation-message , compilation_message |
executionDigest |
The compilationDigest of the node when it was last executed. |
CompilationDigest |
Executable |
stencila:executionDigest |
execution-digest , execution_digest |
executionDependencies |
The upstream dependencies of this node. | ExecutionDependency * |
Executable |
stencila:executionDependencies |
execution-dependencies , execution_dependencies , executionDependency , execution-dependency , execution_dependency |
executionDependants |
The downstream dependants of this node. | ExecutionDependant * |
Executable |
stencila:executionDependants |
execution-dependants , execution_dependants , executionDependant , execution-dependant , execution_dependant |
executionTags |
Tags in the code which affect its execution. | ExecutionTag * |
Executable |
stencila:executionTags |
execution-tags , execution_tags , executionTag , execution-tag , execution_tag |
executionCount |
A count of the number of times that the node has been executed. | Integer |
Executable |
stencila:executionCount |
execution-count , execution_count |
executionRequired |
Whether, and why, the code requires execution or re-execution. | ExecutionRequired |
Executable |
stencila:executionRequired |
execution-required , execution_required |
executionStatus |
Status of the most recent, including any current, execution. | ExecutionStatus |
Executable |
stencila:executionStatus |
execution-status , execution_status |
executionInstance |
The id of the kernel instance that performed the last execution. | String |
Executable |
stencila:executionInstance |
execution-instance , execution_instance |
executionEnded |
The timestamp when the last execution ended. | Timestamp |
Executable |
stencila:executionEnded |
execution-ended , execution_ended |
executionDuration |
Duration of the last execution. | Duration |
Executable |
stencila:executionDuration |
execution-duration , execution_duration |
executionMessages |
Messages emitted while executing the node. | ExecutionMessage * |
Executable |
stencila:executionMessages |
execution-messages , execution_messages , executionMessage , execution-message , execution_message |
instructionType |
The type of instruction the being used for | InstructionType |
- | stencila:instructionType |
instruction-type , instruction_type |
nodeTypes |
The type of nodes the prompt is being used for | String * |
- | stencila:nodeTypes |
node-types , node_types , nodeType , node-type , node_type |
relativePosition |
The relative position of the node being edited, described etc. | RelativePosition |
- | stencila:relativePosition |
relative-position , relative_position |
query |
A user text query used to infer the target prompt |
String |
- | stencila:query |
- |
target |
An identifier for the prompt to be rendered | String |
- | schema:target |
- |
directory |
The home directory of the prompt | String |
- | stencila:directory |
- |
content |
The executed content of the prompt | Block * |
- | stencila:content |
- |
Related
The PromptBlock
type is related to these types:
- Parents:
Executable
- Children: none
Formats
The PromptBlock
type can be encoded (serialized) to, and/or decoded (deserialized) from, these formats:
Format | Encoding | Decoding | Support | Notes |
---|---|---|---|---|
DOM HTML | 🟢 No loss | |||
HTML | 🔷 Low loss | |||
JATS | ||||
Markdown | ⚠️ High loss | Encoded using implemented function | ||
Stencila Markdown | ⚠️ High loss | |||
Quarto Markdown | ⚠️ High loss | |||
MyST Markdown | ⚠️ High loss | |||
LLM Markdown | ⚠️ High loss | |||
LaTeX | 🔷 Low loss | 🔷 Low loss | ||
🔷 Low loss | ||||
Plain text | ⚠️ High loss | |||
IPYNB | 🔷 Low loss | 🔷 Low loss | ||
Microsoft Word DOCX | 🔷 Low loss | 🔷 Low loss | ||
OpenDocument ODT | 🔷 Low loss | 🔷 Low loss | ||
TeX | 🔷 Low loss | 🔷 Low loss | ||
JSON | 🟢 No loss | 🟢 No loss | ||
JSON+Zip | 🟢 No loss | 🟢 No loss | ||
JSON5 | 🟢 No loss | 🟢 No loss | ||
JSON-LD | 🟢 No loss | 🟢 No loss | ||
CBOR | 🟢 No loss | 🟢 No loss | ||
CBOR+Zstandard | 🟢 No loss | 🟢 No loss | ||
YAML | 🟢 No loss | 🟢 No loss | ||
Lexical JSON | 🔷 Low loss | 🔷 Low loss | ||
Koenig JSON | 🔷 Low loss | 🔷 Low loss | ||
Pandoc AST | 🔷 Low loss | 🔷 Low loss | ||
Directory | ||||
Stencila Web Bundle | ||||
Debug | 🔷 Low loss |
Bindings
The PromptBlock
type is represented in:
- JSON-LD
- JSON Schema
- Python class
PromptBlock
- Rust struct
PromptBlock
- TypeScript class
PromptBlock
Source
This documentation was generated from PromptBlock.yaml
by docs_types.rs
.