trustgraph/trustgraph-embeddings-hf
Azizultra32 b9a0bc4bf2 fix: align HF embeddings provider with batch embeddings interface
The batch embeddings refactor (PR #668) changed the EmbeddingsRequest
schema from `text: str` to `texts: list[str]` and updated the base
class to call `on_embeddings(request.texts, model=model)`.

The Ollama and FastEmbed providers were updated to match, but the
HuggingFace provider was missed:

- Parameter was still named `text` (singular) instead of `texts`
- `embed_documents([text])` wrapped the already-list input in another
  list, causing `embed_documents([["text1", "text2"]])` — a list
  containing a list instead of a list of strings

This produces:
  AttributeError: 'list' object has no attribute 'replace'

Fix aligns the HF provider with Ollama/FastEmbed:
- Rename param `text` → `texts`
- Remove redundant `[text]` wrapping
- Add empty-list guard (consistent with other providers)
2026-03-24 16:26:04 -07:00
..
trustgraph fix: align HF embeddings provider with batch embeddings interface 2026-03-24 16:26:04 -07:00
pyproject.toml Update CI for 2.1 release (#653) 2026-02-28 11:10:11 +00:00
README.md Maint/fix build env (#84) 2024-09-30 19:47:09 +01:00