Mastra.getVector()
.getVector() メソッドは、名前で Vector Store を取得します。Vector Store 名を表す単一の string パラメーターを受け取ります。
使用例使用例への直接リンク
mastra.getVector('testVectorStore')
パラメーターパラメーターへの直接リンク
name:
TVectorName extends keyof TVectors
取得する Vector Store の名前。Mastra の設定に存在する有効な Vector Store 名である必要があります。
戻り値戻り値への直接リンク
vector:
TVectors[TVectorName]
指定した名前の Vector Store インスタンス。Vector Store が見つからない場合はエラーをスローします。