|
1
|
{"slug":"/references/utils/classes/utils.VectorProperty","title":"VectorProperty","frontmatter":{},"toc":[{"title":"Type parameters","id":"type-parameters","level":2},{"title":"constructor","id":"constructor","level":2},{"title":"Type Parameters","id":"constructor-type-parameters","level":3},{"title":"Parameters","id":"constructor-parameters","level":3},{"title":"Properties","id":"properties","level":2},{"title":"Methods","id":"methods","level":2},{"title":"retrievable","id":"retrievable","level":3},{"title":"Parameters","id":"retrievable-parameters","level":4},{"title":"Returns","id":"retrievable-returns","level":4},{"title":"providerOptions","id":"provideroptions","level":3},{"title":"Parameters","id":"provideroptions-parameters","level":4},{"title":"Returns","id":"provideroptions-returns","level":4},{"title":"embed","id":"embed","level":3},{"title":"Returns","id":"embed-returns","level":4},{"title":"parse","id":"parse","level":3},{"title":"Parameters","id":"parse-parameters","level":4},{"title":"Returns","id":"parse-returns","level":4}],"blocks":[{"kind":"markdown","html":"The core of every search index field property. Only the modifiers that make\nsense for any field kind live here; the narrower ones (searchable, facet\ntypes, array) sit on the subclasses whose kinds support them, so an invalid\ncombination is a compile error instead of a boot failure."},{"kind":"heading","level":2,"text":"Type parameters","id":"type-parameters"},{"kind":"typeList","sectionTitle":"VectorProperty","types":[{"name":"T","type":"`object`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"kind":"heading","level":2,"text":"constructor","id":"constructor"},{"kind":"heading","level":3,"text":"Type Parameters","id":"constructor-type-parameters"},{"kind":"typeList","sectionTitle":"constructor","types":[{"name":"T","type":"`object`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"kind":"heading","level":3,"text":"Parameters","id":"constructor-parameters"},{"kind":"typeList","sectionTitle":"constructor","types":[{"name":"dimensions","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"kind":"heading","level":2,"text":"Properties","id":"properties"},{"kind":"typeList","sectionTitle":"VectorProperty","types":[{"name":"$dataType","type":"T","description":"A type-only property to infer the JavaScript data-type\nof the schema property","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"#retrievable","type":"`boolean`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"#providerOptions","type":"`Record<string, Record<string, unknown>>`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"dataType","type":"`object`","description":"The runtime dataType for the schema. It is not the same as\nthe \"$dataType\".","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`\"vector\"`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"options","type":"`Record<string, any>`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"#dimensions","type":"`number`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"#embed","type":"`boolean`","description":"","optional":false,"defaultValue":"false","expandable":false,"children":[]}]},{"kind":"heading","level":2,"text":"Methods","id":"methods"},{"kind":"heading","level":3,"text":"retrievable","id":"retrievable"},{"kind":"heading","level":4,"text":"Parameters","id":"retrievable-parameters"},{"kind":"typeList","sectionTitle":"retrievable","types":[{"name":"value","type":"`boolean`","description":"","optional":false,"defaultValue":"true","expandable":false,"children":[]}]},{"kind":"heading","level":4,"text":"Returns","id":"retrievable-returns"},{"kind":"typeList","sectionTitle":"retrievable","types":[{"name":"VectorProperty","type":"[VectorProperty](/references/utils/classes/utils.VectorProperty)<T>","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]},{"kind":"heading","level":3,"text":"providerOptions","id":"provideroptions"},{"kind":"heading","level":4,"text":"Parameters","id":"provideroptions-parameters"},{"kind":"typeList","sectionTitle":"providerOptions","types":[{"name":"options","type":"`Record<string, Record<string, unknown>>`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"kind":"heading","level":4,"text":"Returns","id":"provideroptions-returns"},{"kind":"typeList","sectionTitle":"providerOptions","types":[{"name":"VectorProperty","type":"[VectorProperty](/references/utils/classes/utils.VectorProperty)<T>","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]},{"kind":"heading","level":3,"text":"embed","id":"embed"},{"kind":"markdown","html":"Ask the engine to embed this field's text at write time, and for\n`search_options.vector.query` at query time. Documents pass a string on\nthis field; the engine applies its configured embedding model."},{"kind":"heading","level":4,"text":"Returns","id":"embed-returns"},{"kind":"typeList","sectionTitle":"embed","types":[{"name":"VectorProperty","type":"[VectorProperty](/references/utils/classes/utils.VectorProperty)<string>","optional":false,"defaultValue":"","description":"Ask the engine to embed this field's text at write time, and for\n`search_options.vector.query` at query time. Documents pass a string on\nthis field; the engine applies its configured embedding model.","expandable":false,"children":[{"name":"string","type":"`string`","optional":false,"defaultValue":"","description":"","expandable":false,"children":[]}]}]},{"kind":"heading","level":3,"text":"parse","id":"parse"},{"kind":"markdown","html":"Returns the serialized metadata"},{"kind":"heading","level":4,"text":"Parameters","id":"parse-parameters"},{"kind":"typeList","sectionTitle":"parse","types":[{"name":"fieldName","type":"`string`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]},{"kind":"heading","level":4,"text":"Returns","id":"parse-returns"},{"kind":"typeList","sectionTitle":"parse","types":[{"name":"SearchPropertyMetadata","type":"[SearchPropertyMetadata](/references/types/SearchTypes/types/types.SearchTypes.SearchPropertyMetadata)<T>","optional":false,"defaultValue":"","description":"Returns the serialized metadata","expandable":false,"children":[]}]}]} |