Go: implement Embed (embeddings) in Replicate driver (#15073)

### What problem does this PR solve?

`ReplicateModel.Embed` in `internal/entity/models/replicate.go` was a
`"replicate, no such method"` stub. Tracking issue #14736 lists
Replicate's embedding surface as not implemented. This PR wires it up
against Replicate's documented embedding schema.

Until this PR, a tenant who selected a Replicate embedding model got the
sentinel error on every embed call.

Co-authored-by: sxxtony <sxxtony@users.noreply.github.com>
Co-authored-by: Jin Hai <haijin.chn@gmail.com>
This commit is contained in:
sxxtony
2026-05-21 10:11:56 +03:00
committed by Jin Hai
parent 3e5b11a523
commit 7740ec6c95
2 changed files with 154 additions and 1 deletions

View File

@@ -22,6 +22,13 @@
"model_types": [
"chat"
]
},
{
"name": "replicate/all-mpnet-base-v2:b6b7585c9640cd7a9572c6e129c9549d79c9c31f0d3fdce7baac7c67ca38f305",
"max_tokens": 384,
"model_types": [
"embedding"
]
}
]
}