Add e2e tests for embedding raw flag #16923
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
🧩 Summary
This PR adds a CI workflow for end-to-end embedding tests.
It marks the first phase of an effort to move an abstraction of the existing
examples/llama-embeddinglogic behindllama-server, so the server can use llama.cpp’s own embedding implementation instead of external (OpenAI) APIs.🎯 Motivation & Future
llama-servercurrently supports OpenAI-compatible/embeddingrequests, but those are not backed by native llama.cpp logic.This workflow establishes a reproducible test foundation before refactoring the embedding code so that:
--parallel Ncan support multiple concurrent embedding requests.⚙️ CI Implementation
🧱 Embedding CPP Logic Flow Update
A small cleanup in
print_raw_embeddings()improves readability, logic flow, and isolation.Although minor, this change is modular alongside the CI workflow changes, touching a vertical slice of the embedding flow without altering evaluation, model logic, or any interface. Note that expecting purely small horizontal modularity ossifies software (makes it brittle).
🚀 Next Steps
a. Extend CI coverage for concurrent (--parallel) embedding tests.
(could actually become more than three steps)