Module: Rogalik::Plugins::Core::EmbeddingsMethods
- Defined in:
- lib/rogalik/plugins/core/embeddings_methods.rb
Overview
Mixin that wires the configured embeddings provider into any class that includes it.
When included, included reads the active provider from
Rogalik.configuration and delegates to Embeddings.load,
which requires the provider file and mixes in its ProviderMethods.
The including class therefore gains the full embedding interface
(+embed_text+, embed_documents, etc.) without knowing which
provider is in use.
Instance Method Summary collapse
Instance Method Details
#embed_documents(_documents) ⇒ Object
24 25 26 |
# File 'lib/rogalik/plugins/core/embeddings_methods.rb', line 24 def (_documents) raise NotImplementedError, "Embeddings plugins must be included" end |
#embed_text(_text) ⇒ Object
28 29 30 |
# File 'lib/rogalik/plugins/core/embeddings_methods.rb', line 28 def (_text) raise NotImplementedError, "Embeddings plugins must be included" end |