# to_data_points

> **Function** in `langchain_google_vertexai`

📖 [View in docs](https://reference.langchain.com/python/langchain-google-vertexai/vectorstores/_utils/to_data_points)

Converts triplets id, embedding, metadata into `IndexDataPoints` instances.

Only metadata with values of type string, numeric or list of string will be
considered for the filtering.

## Signature

```python
to_data_points(
    ids: list[str],
    embeddings: list[list[float]],
    sparse_embeddings: list[dict[str, list[int] | list[float]]] | None = None,
    metadatas: list[dict[str, Any]] | None = None,
) -> list[meidx_types.IndexDataPoint]
```

## Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `ids` | `list[str]` | Yes | List of unique IDs. |
| `embeddings` | `list[list[float]]` | Yes | List of feature representatitons. |
| `metadatas` | `list[dict[str, Any]] \| None` | No | List of metadatas. (default: `None`) |

---

[View source on GitHub](https://github.com/langchain-ai/langchain-google/blob/a3f016b2a6c4af535df275545f76fa7424aa39e5/libs/vertexai/langchain_google_vertexai/vectorstores/_utils.py#L64)