The community members are trying to use the AutoModelForCausalLM from the ctransformers library with the llamaindex library, but are encountering issues with the model file not being found. The community members suggest skipping the llamaindex loading and passing the model directly, but this leads to other issues with the config and metadata of the ctransformers model. They explore options like monkey-patching and extending the HuggingFaceLLM class, but there are still problems. The community members also consider using llama.cpp instead of ctransformers, but encounter issues with the GUF model format. Eventually, they find that using the specific LLM class for llama.cpp seems to work.
how can I use AutoModelForCausalLM.from_pretrained('TheBloke/leo-hessianai-7B-chat-GGUF', model_file="leo-hessianai-7b-chat.Q4_K_M.gguf", model_type="llama") based on ctransformers with llamaindex? this is currently failing with TheBloke/leo-hessianai-7B-chat-GGUF does not appear to have a file named pytorch_model.bin, tf_model.h5, model.ckpt or flax_model.msgpack. for the AutoModelForCausalLM which is coming from the normal transformers library which is used by llamaindex?
@Logan M but even when using AttributeError: 'Llama' object has no attribute 'metadata' --> 123 config_dict = self._model.config.to_dict() 124 model_context_window = int( 125 config_dict.get("max_position_embeddings", context_window) 126 ) 127 if model_context_window and model_context_window < context_window:
AttributeError: 'Llama' object has no attribute 'config' llm_model = Llama(model_path, model_type="llama", . it looks like llama_cpp python is also not fully supported?