Actions13
- Collection Actions
- Vector Actions
- System Actions
- Graph Actions
Vector → Insert Vector
AI-generatedSummary
Insert a new raw vector embedding into a specified collection in HyperspaceDB, identified by a unique numeric ID and optionally accompanied by metadata.
Inputs
- Collection Name (required) — The name of the collection where the vector will be inserted.
- ID (Numeric) (required) — A unique numeric identifier for the vector entry.
- Vector Data (JS Array) (required) — The raw vector embedding represented as a JSON array string.
- Metadata — Optional JSON object containing additional metadata associated with the vector.
Output shape
a single JSON object per inserted vector confirming success and echoing the ID and collection name
Returns { json: { success: true, id, collection } } for each inserted vector. If multiple input items are processed, returns an array of such objects. Errors are thrown unless 'Continue On Fail' is enabled, in which case error messages appear in the output.
Examples
Example 1: Insert a single vector embedding into the 'photos' collection with ID 123 and optional descriptive metadata.
Set 'Collection Name' to 'photos', 'ID (Numeric)' to 123, and 'Vector Data (JS Array)' to the JSON string of the embedding, e.g. "[0.1,0.2,0.3]". Provide optional 'Metadata' as a JSON object if needed.