annotation: annotate nested objects using jsonpath
reference
#395
Labels
enhancement
New feature or request
jsonpath
reference
#395
The recently released annotation feature allows to annotate top-level objects stored on
State
.For example, if
State
had this schema (this is the result of allreads
andwrites
defined via@action
), we could only annotate the full list ofparagraphs
and `summaries.The challenge is how to link annotations to specific state values.
Proposed solution
Since state is immutable and we have the full object stored, we could store access paths for arbitrary
Mapping
andSequence
types (i.e., JSON-like). For example, you could annotate the 3rd paragraph by specifyingState -> paragraphs -> index 2
Related: if
paragraphs
was a list of objects that have richer UI support (e.g.,list[pydantic.BaseModel]
), we could display them in rich format.Adapting the annotation UI for easy navigation may be challenging
The text was updated successfully, but these errors were encountered: