Skip to content

Clarify language about different types of QREF objects. #118

@mstechly

Description

@mstechly

Currently QREF objects can come in different forms:

  1. Saved to a file
  2. Represented as a dictionary
  3. Instances of pydantic models (SchemaV1)

This introduces some ambiguity, as when we say "QREF object", we could mean any of these.

It would be good to clarify the language here, below is a proposal for this:

  1. "QREF file" would refer to a JSON or YAML file adhering to QREF schema
  2. "QREF dictionary" would refer to a Python dictionary adhering to QREF schema
  3. "QREF object" would refer to an instance of QREF pydantic model

Keep in mind that in future QREF pydantic models might become generic (i.e. they would support not only strings as expressions, but also other types, e.g.: sympy expressions). In such case we could imagine having dictionaries containing non-native expression types. Such dictionary would be a valid input for creating a QREF object. However, we should not call it "QREF dictionary", as it is not JSON/YAML-serializable.

Once we agree on what the good naming is, we should update documentation (including docstrings!) accordingly.

CC: @dexter2206 @sammorley-short

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions