OpenVINO
bloom
katuni4ka commited on
Commit
c0610c2
1 Parent(s): 5fcdd5c

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +31 -1
README.md CHANGED
@@ -26,7 +26,7 @@ The provided OpenVINO™ IR model is compatible with:
26
  * OpenVINO version 2024.4.0 and higher
27
  * Optimum Intel 1.20.0 and higher
28
 
29
- ## Running Model Inference
30
 
31
  1. Install packages required for using [Optimum Intel](https://huggingface.co/docs/optimum/intel/index) integration with the OpenVINO backend:
32
 
@@ -53,6 +53,36 @@ print(text)
53
 
54
  For more examples and possible optimizations, refer to the [OpenVINO Large Language Model Inference Guide](https://docs.openvino.ai/2024/learn-openvino/llm_inference_guide.html).
55
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
56
  ## Limitations
57
 
58
  Check the original model card for [original model card](https://huggingface.co/bigscience/bloomz-3b) for limitations.
 
26
  * OpenVINO version 2024.4.0 and higher
27
  * Optimum Intel 1.20.0 and higher
28
 
29
+ ## Running Model Inference with [Optimum Intel](https://huggingface.co/docs/optimum/intel/index)
30
 
31
  1. Install packages required for using [Optimum Intel](https://huggingface.co/docs/optimum/intel/index) integration with the OpenVINO backend:
32
 
 
53
 
54
  For more examples and possible optimizations, refer to the [OpenVINO Large Language Model Inference Guide](https://docs.openvino.ai/2024/learn-openvino/llm_inference_guide.html).
55
 
56
+ ## Running Model Inference with [OpenVINO GenAI](https://github.com/openvinotoolkit/openvino.genai)
57
+
58
+ 1. Install packages required for using OpenVINO GenAI.
59
+ ```
60
+ pip install openvino-genai huggingface_hub
61
+ ```
62
+
63
+ 2. Download model from HuggingFace Hub
64
+
65
+ ```
66
+ import huggingface_hub as hf_hub
67
+
68
+ model_id = "OpenVINO/bloomz-3b-int8-ov"
69
+ model_path = "bloomz-3b-int8-ov"
70
+
71
+ hf_hub.snapshot_download(model_id, local_dir=model_path)
72
+
73
+ ```
74
+
75
+ 3. Run model inference:
76
+
77
+ ```
78
+ import openvino_genai as ov_genai
79
+
80
+ device = "CPU"
81
+ pipe = ov_genai.LLMPipeline(model_path, device)
82
+ print(pipe.generate("What is OpenVINO?", max_length=200))
83
+ ```
84
+
85
+ More GenAI usage examples can be found in OpenVINO GenAI library [docs](https://github.com/openvinotoolkit/openvino.genai/blob/master/src/README.md) and [samples](https://github.com/openvinotoolkit/openvino.genai?tab=readme-ov-file#openvino-genai-samples)
86
  ## Limitations
87
 
88
  Check the original model card for [original model card](https://huggingface.co/bigscience/bloomz-3b) for limitations.