From 482bec824f3027e9049ac2a981ce36c954e67882 Mon Sep 17 00:00:00 2001 From: nicole pardal <109545900+npardal@users.noreply.github.com> Date: Thu, 13 Nov 2025 13:24:13 -0800 Subject: [PATCH] embeddings: added cli command to embedding docs (#12993) --- docs/capabilities/embeddings.mdx | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/docs/capabilities/embeddings.mdx b/docs/capabilities/embeddings.mdx index 99a577489a..7d364200fc 100644 --- a/docs/capabilities/embeddings.mdx +++ b/docs/capabilities/embeddings.mdx @@ -13,9 +13,23 @@ Embeddings turn text into numeric vectors you can store in a vector database, se ## Generate embeddings -Use `/api/embed` with a single string. - + + Generate embeddings directly from the command line: + + ```shell + ollama run embeddinggemma "Hello world" + ``` + + You can also pipe text to generate embeddings: + + ```shell + echo "Hello world" | ollama run embeddinggemma + ``` + + Output is a JSON array. + + ```shell curl -X POST http://localhost:11434/api/embed \