Database / Weaviate Vector database Interview questions
What is a cross-reference in Weaviate?
A cross-reference is a link from one object to another, potentially in a different collection, letting Weaviate represent relationships between data, similar in spirit to a foreign key in a relational database, but resolved at query time as part of a GraphQL-style traversal.
Property( name="hasAuthor", data_type=DataType.OBJECT, reference=ReferenceProperty(name="hasAuthor", target_collection="Author") )
Cross-references capture relationships but don't change the vectors of the objects they connect; an object's embedding still reflects only its own properties, not anything about objects it references. Weaviate's own documentation actively encourages minimizing cross-reference use where possible, suggesting that embedding related information directly into an object (or using filters against denormalized properties) is often a better fit for its query patterns than modeling data the way a normalized relational schema would.
More Related questions...