Loads and integrates a Huggingface generative decoder-based 'causal' model with limited options to control model preprocessing prompt behavior
(self, model,tokenizer,prompt_wrapper=None,
instruction_following=False)
| 1337 | return model |
| 1338 | |
| 1339 | def load_hf_generative_model(self, model,tokenizer,prompt_wrapper=None, |
| 1340 | instruction_following=False): |
| 1341 | |
| 1342 | """ Loads and integrates a Huggingface generative decoder-based 'causal' model with limited options |
| 1343 | to control model preprocessing prompt behavior """ |
| 1344 | |
| 1345 | model = HFGenerativeModel(model, tokenizer, prompt_wrapper=prompt_wrapper, |
| 1346 | instruction_following=instruction_following) |
| 1347 | |
| 1348 | return model |
| 1349 | |
| 1350 | def load_embedding_model (self, model_name=None, |
| 1351 | model=None, tokenizer=None,from_hf=False, |
no test coverage detected