From fde4e5d11ebf26bc285a6cb75779c3efbdf0ced1 Mon Sep 17 00:00:00 2001 From: ModelHub XC Date: Wed, 17 Jun 2026 16:17:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=9D=E5=A7=8B=E5=8C=96=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=EF=BC=8C=E7=94=B1ModelHub=20XC=E7=A4=BE=E5=8C=BA=E6=8F=90?= =?UTF-8?q?=E4=BE=9B=E6=A8=A1=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Model: duyntnet/Phi-3.5-mini-instruct-imatrix-GGUF Source: Original Platform --- .gitattributes | 62 +++++++++++++++++++ Phi-3.5-mini-instruct-IQ1_M.gguf | 3 + Phi-3.5-mini-instruct-IQ1_S.gguf | 3 + Phi-3.5-mini-instruct-IQ2_M.gguf | 3 + Phi-3.5-mini-instruct-IQ2_S.gguf | 3 + Phi-3.5-mini-instruct-IQ2_XS.gguf | 3 + Phi-3.5-mini-instruct-IQ2_XXS.gguf | 3 + Phi-3.5-mini-instruct-IQ3_M.gguf | 3 + Phi-3.5-mini-instruct-IQ3_S.gguf | 3 + Phi-3.5-mini-instruct-IQ3_XS.gguf | 3 + Phi-3.5-mini-instruct-IQ3_XXS.gguf | 3 + Phi-3.5-mini-instruct-IQ4_NL.gguf | 3 + Phi-3.5-mini-instruct-IQ4_XS.gguf | 3 + Phi-3.5-mini-instruct-Q2_K.gguf | 3 + Phi-3.5-mini-instruct-Q2_K_S.gguf | 3 + Phi-3.5-mini-instruct-Q3_K_L.gguf | 3 + Phi-3.5-mini-instruct-Q3_K_M.gguf | 3 + Phi-3.5-mini-instruct-Q3_K_S.gguf | 3 + Phi-3.5-mini-instruct-Q4_0.gguf | 3 + Phi-3.5-mini-instruct-Q4_1.gguf | 3 + Phi-3.5-mini-instruct-Q4_K_M.gguf | 3 + Phi-3.5-mini-instruct-Q4_K_S.gguf | 3 + Phi-3.5-mini-instruct-Q5_0.gguf | 3 + Phi-3.5-mini-instruct-Q5_1.gguf | 3 + Phi-3.5-mini-instruct-Q5_K_M.gguf | 3 + Phi-3.5-mini-instruct-Q5_K_S.gguf | 3 + Phi-3.5-mini-instruct-Q6_K.gguf | 3 + Phi-3.5-mini-instruct-Q8_0.gguf | 3 + README.md | 99 ++++++++++++++++++++++++++++++ 29 files changed, 242 insertions(+) create mode 100644 .gitattributes create mode 100644 Phi-3.5-mini-instruct-IQ1_M.gguf create mode 100644 Phi-3.5-mini-instruct-IQ1_S.gguf create mode 100644 Phi-3.5-mini-instruct-IQ2_M.gguf create mode 100644 Phi-3.5-mini-instruct-IQ2_S.gguf create mode 100644 Phi-3.5-mini-instruct-IQ2_XS.gguf create mode 100644 Phi-3.5-mini-instruct-IQ2_XXS.gguf create mode 100644 Phi-3.5-mini-instruct-IQ3_M.gguf create mode 100644 Phi-3.5-mini-instruct-IQ3_S.gguf create mode 100644 Phi-3.5-mini-instruct-IQ3_XS.gguf create mode 100644 Phi-3.5-mini-instruct-IQ3_XXS.gguf create mode 100644 Phi-3.5-mini-instruct-IQ4_NL.gguf create mode 100644 Phi-3.5-mini-instruct-IQ4_XS.gguf create mode 100644 Phi-3.5-mini-instruct-Q2_K.gguf create mode 100644 Phi-3.5-mini-instruct-Q2_K_S.gguf create mode 100644 Phi-3.5-mini-instruct-Q3_K_L.gguf create mode 100644 Phi-3.5-mini-instruct-Q3_K_M.gguf create mode 100644 Phi-3.5-mini-instruct-Q3_K_S.gguf create mode 100644 Phi-3.5-mini-instruct-Q4_0.gguf create mode 100644 Phi-3.5-mini-instruct-Q4_1.gguf create mode 100644 Phi-3.5-mini-instruct-Q4_K_M.gguf create mode 100644 Phi-3.5-mini-instruct-Q4_K_S.gguf create mode 100644 Phi-3.5-mini-instruct-Q5_0.gguf create mode 100644 Phi-3.5-mini-instruct-Q5_1.gguf create mode 100644 Phi-3.5-mini-instruct-Q5_K_M.gguf create mode 100644 Phi-3.5-mini-instruct-Q5_K_S.gguf create mode 100644 Phi-3.5-mini-instruct-Q6_K.gguf create mode 100644 Phi-3.5-mini-instruct-Q8_0.gguf create mode 100644 README.md diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..c8c3259 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,62 @@ +*.7z filter=lfs diff=lfs merge=lfs -text +*.arrow filter=lfs diff=lfs merge=lfs -text +*.bin filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.ckpt filter=lfs diff=lfs merge=lfs -text +*.ftz filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.h5 filter=lfs diff=lfs merge=lfs -text +*.joblib filter=lfs diff=lfs merge=lfs -text +*.lfs.* filter=lfs diff=lfs merge=lfs -text +*.mlmodel filter=lfs diff=lfs merge=lfs -text +*.model filter=lfs diff=lfs merge=lfs -text +*.msgpack filter=lfs diff=lfs merge=lfs -text +*.npy filter=lfs diff=lfs merge=lfs -text +*.npz filter=lfs diff=lfs merge=lfs -text +*.onnx filter=lfs diff=lfs merge=lfs -text +*.ot filter=lfs diff=lfs merge=lfs -text +*.parquet filter=lfs diff=lfs merge=lfs -text +*.pb filter=lfs diff=lfs merge=lfs -text +*.pickle filter=lfs diff=lfs merge=lfs -text +*.pkl filter=lfs diff=lfs merge=lfs -text +*.pt filter=lfs diff=lfs merge=lfs -text +*.pth filter=lfs diff=lfs merge=lfs -text +*.rar filter=lfs diff=lfs merge=lfs -text +*.safetensors filter=lfs diff=lfs merge=lfs -text +saved_model/**/* filter=lfs diff=lfs merge=lfs -text +*.tar.* filter=lfs diff=lfs merge=lfs -text +*.tar filter=lfs diff=lfs merge=lfs -text +*.tflite filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.wasm filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text +*tfevents* filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ1_S.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ1_M.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q2_K.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q2_K_S.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ2_S.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ2_M.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ2_XS.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ2_XXS.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q3_K_S.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q3_K_M.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q3_K_L.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ3_S.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ3_M.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ3_XS.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ3_XXS.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q4_0.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q4_1.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q4_K_M.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q4_K_S.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ4_NL.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-IQ4_XS.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q5_0.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q5_1.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q5_K_M.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q5_K_S.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q6_K.gguf filter=lfs diff=lfs merge=lfs -text +Phi-3.5-mini-instruct-Q8_0.gguf filter=lfs diff=lfs merge=lfs -text diff --git a/Phi-3.5-mini-instruct-IQ1_M.gguf b/Phi-3.5-mini-instruct-IQ1_M.gguf new file mode 100644 index 0000000..cf3431e --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ1_M.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:36c8e68cee3f2c094f4817cf9da33649c957c7ef3d3de8f0f6a1fb708c107925 +size 917107872 diff --git a/Phi-3.5-mini-instruct-IQ1_S.gguf b/Phi-3.5-mini-instruct-IQ1_S.gguf new file mode 100644 index 0000000..8ad1c7c --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ1_S.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:83307e988e48437294d5f2c278f1550cebf5f1e73895239e330875f8c7fc5646 +size 841610400 diff --git a/Phi-3.5-mini-instruct-IQ2_M.gguf b/Phi-3.5-mini-instruct-IQ2_M.gguf new file mode 100644 index 0000000..fb68e50 --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ2_M.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d18c5dae68eff4be2af9ebf01f648af528df9e750871b178c0cfbc548feccba +size 1316395680 diff --git a/Phi-3.5-mini-instruct-IQ2_S.gguf b/Phi-3.5-mini-instruct-IQ2_S.gguf new file mode 100644 index 0000000..4b62500 --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ2_S.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8665c3d3c89053c4e018a8d03a9c57cb95eb87070183bb1a8c58464de57a8878 +size 1215732384 diff --git a/Phi-3.5-mini-instruct-IQ2_XS.gguf b/Phi-3.5-mini-instruct-IQ2_XS.gguf new file mode 100644 index 0000000..ef16c8b --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ2_XS.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1ddca84a79106d2f65c18e901f35c7e837e5ca08dcc176949d4a5fe5d2029456 +size 1153037472 diff --git a/Phi-3.5-mini-instruct-IQ2_XXS.gguf b/Phi-3.5-mini-instruct-IQ2_XXS.gguf new file mode 100644 index 0000000..68de751 --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ2_XXS.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e6baa24866f1eb3b0ab36502db24d73fa14c6ecaecc2a859160e12fe4c14d854 +size 1042936992 diff --git a/Phi-3.5-mini-instruct-IQ3_M.gguf b/Phi-3.5-mini-instruct-IQ3_M.gguf new file mode 100644 index 0000000..5136f24 --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ3_M.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b460de1fba5b009e9fb2fb5458c6d50185db79d393696f2b8987221c5e4fbcf7 +size 1855600800 diff --git a/Phi-3.5-mini-instruct-IQ3_S.gguf b/Phi-3.5-mini-instruct-IQ3_S.gguf new file mode 100644 index 0000000..8d74fce --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ3_S.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f2f5c42bbd1e9337a881664ee213ea83b4d5cd9e24b7a5ae944224b07fcf2a57 +size 1681799328 diff --git a/Phi-3.5-mini-instruct-IQ3_XS.gguf b/Phi-3.5-mini-instruct-IQ3_XS.gguf new file mode 100644 index 0000000..336c1c0 --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ3_XS.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d274c2abc3754b8b4f726debd0d1052c02621754b5eb0b75124e14c855f954ac +size 1625176224 diff --git a/Phi-3.5-mini-instruct-IQ3_XXS.gguf b/Phi-3.5-mini-instruct-IQ3_XXS.gguf new file mode 100644 index 0000000..b5870ce --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ3_XXS.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:17973b87ed4f184993d0b8ab9bcf964ba2287f15a2f1216d1d4171173684f28b +size 1513003680 diff --git a/Phi-3.5-mini-instruct-IQ4_NL.gguf b/Phi-3.5-mini-instruct-IQ4_NL.gguf new file mode 100644 index 0000000..3742ddb --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ4_NL.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f4b8e06a17b2d0d7c2c0a99520c2f8498f6ddd5ee8d2d5df848f1236ebf5deb2 +size 2176177824 diff --git a/Phi-3.5-mini-instruct-IQ4_XS.gguf b/Phi-3.5-mini-instruct-IQ4_XS.gguf new file mode 100644 index 0000000..a65fc2e --- /dev/null +++ b/Phi-3.5-mini-instruct-IQ4_XS.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:846f62dd6d203f6139aa0bba41f8ecc6e3a011b7574c0e60bf9cf06be82266ef +size 2059853472 diff --git a/Phi-3.5-mini-instruct-Q2_K.gguf b/Phi-3.5-mini-instruct-Q2_K.gguf new file mode 100644 index 0000000..fa17659 --- /dev/null +++ b/Phi-3.5-mini-instruct-Q2_K.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:77dc3f12c9ce32fc648ba7d8e64d4903fb3696f3ecb0f6649be306d333b00f96 +size 1416204960 diff --git a/Phi-3.5-mini-instruct-Q2_K_S.gguf b/Phi-3.5-mini-instruct-Q2_K_S.gguf new file mode 100644 index 0000000..4d2a170 --- /dev/null +++ b/Phi-3.5-mini-instruct-Q2_K_S.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f19579dbf551a90ba018650395f10c36c817e159e0a96b62e221fcc584d5560 +size 1327338144 diff --git a/Phi-3.5-mini-instruct-Q3_K_L.gguf b/Phi-3.5-mini-instruct-Q3_K_L.gguf new file mode 100644 index 0000000..3c328f2 --- /dev/null +++ b/Phi-3.5-mini-instruct-Q3_K_L.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:191155baa511ac50eb7bf763758c8930117e1fc0d949b0d0bba679965a1ec9a1 +size 2087598240 diff --git a/Phi-3.5-mini-instruct-Q3_K_M.gguf b/Phi-3.5-mini-instruct-Q3_K_M.gguf new file mode 100644 index 0000000..6053ba9 --- /dev/null +++ b/Phi-3.5-mini-instruct-Q3_K_M.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:98d9a606dbb12d1093f8510d612c9756c7849003c8ac5afcd8dcc8e61b6f7a31 +size 1955477664 diff --git a/Phi-3.5-mini-instruct-Q3_K_S.gguf b/Phi-3.5-mini-instruct-Q3_K_S.gguf new file mode 100644 index 0000000..2c3c921 --- /dev/null +++ b/Phi-3.5-mini-instruct-Q3_K_S.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ec6364c08f9cf8fb9f8cff255b6c7f2271a90dbcbf92b19b4d8b9969ed7f5da8 +size 1681799328 diff --git a/Phi-3.5-mini-instruct-Q4_0.gguf b/Phi-3.5-mini-instruct-Q4_0.gguf new file mode 100644 index 0000000..407c11d --- /dev/null +++ b/Phi-3.5-mini-instruct-Q4_0.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1046a58d065e273aa8543078b744d4e675626b6e2682b9f0ecaaa052b8c3cc6d +size 2182469280 diff --git a/Phi-3.5-mini-instruct-Q4_1.gguf b/Phi-3.5-mini-instruct-Q4_1.gguf new file mode 100644 index 0000000..4282ff3 --- /dev/null +++ b/Phi-3.5-mini-instruct-Q4_1.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f4b0450473116c6cfa36b2a1382c005e0fb2fc741f45d46a239639a3d4a860ab +size 2408826528 diff --git a/Phi-3.5-mini-instruct-Q4_K_M.gguf b/Phi-3.5-mini-instruct-Q4_K_M.gguf new file mode 100644 index 0000000..0909e2b --- /dev/null +++ b/Phi-3.5-mini-instruct-Q4_K_M.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6882b07ded3a57182faf2e3e6a255d6c6113a6db2d8aebf54275a1c51e6336df +size 2393233056 diff --git a/Phi-3.5-mini-instruct-Q4_K_S.gguf b/Phi-3.5-mini-instruct-Q4_K_S.gguf new file mode 100644 index 0000000..da1ed8a --- /dev/null +++ b/Phi-3.5-mini-instruct-Q4_K_S.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:06ed82f415606d80b82c244f3fe384ce707751ad9fa5005460b26777cdf6313f +size 2188760736 diff --git a/Phi-3.5-mini-instruct-Q5_0.gguf b/Phi-3.5-mini-instruct-Q5_0.gguf new file mode 100644 index 0000000..2914ea1 --- /dev/null +++ b/Phi-3.5-mini-instruct-Q5_0.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:966726cbcd943c077598b7973727857dfb40872acafdeaa939db929e427458f0 +size 2647766688 diff --git a/Phi-3.5-mini-instruct-Q5_1.gguf b/Phi-3.5-mini-instruct-Q5_1.gguf new file mode 100644 index 0000000..4fd6ddd --- /dev/null +++ b/Phi-3.5-mini-instruct-Q5_1.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:23a157996596774f4905ea8a180cc8613989e024f690d7f8e334f3e6d6983cc7 +size 2874123936 diff --git a/Phi-3.5-mini-instruct-Q5_K_M.gguf b/Phi-3.5-mini-instruct-Q5_K_M.gguf new file mode 100644 index 0000000..daf17ae --- /dev/null +++ b/Phi-3.5-mini-instruct-Q5_K_M.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:294feeb1733140c9e578410d4c9ec35425f5823c42677d87eedd9778e2f2d6e1 +size 2815276704 diff --git a/Phi-3.5-mini-instruct-Q5_K_S.gguf b/Phi-3.5-mini-instruct-Q5_K_S.gguf new file mode 100644 index 0000000..d243c9e --- /dev/null +++ b/Phi-3.5-mini-instruct-Q5_K_S.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:efb03d696110775f97ada22d069af9fcd2369ca469f46d604803abf6f2f08ce2 +size 2641475232 diff --git a/Phi-3.5-mini-instruct-Q6_K.gguf b/Phi-3.5-mini-instruct-Q6_K.gguf new file mode 100644 index 0000000..6c699a6 --- /dev/null +++ b/Phi-3.5-mini-instruct-Q6_K.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0829fd1fe0d4fa6dbae0723621326973a5df7d2e064a3950c4bacdfdfe6e236a +size 3135853728 diff --git a/Phi-3.5-mini-instruct-Q8_0.gguf b/Phi-3.5-mini-instruct-Q8_0.gguf new file mode 100644 index 0000000..47f8d8c --- /dev/null +++ b/Phi-3.5-mini-instruct-Q8_0.gguf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b2a885daeddbaca4398e26b0bdad041fb35b023e487937567f5912cb001d4ab +size 4061223072 diff --git a/README.md b/README.md new file mode 100644 index 0000000..f0483ab --- /dev/null +++ b/README.md @@ -0,0 +1,99 @@ +--- +license: other +language: +- en +pipeline_tag: text-generation +inference: false +tags: +- transformers +- gguf +- imatrix +- Phi-3.5-mini-instruct +--- +Quantizations of https://huggingface.co/microsoft/Phi-3.5-mini-instruct + + +### Inference Clients/UIs +* [llama.cpp](https://github.com/ggerganov/llama.cpp) +* [JanAI](https://github.com/janhq/jan) +* [KoboldCPP](https://github.com/LostRuins/koboldcpp) +* [text-generation-webui](https://github.com/oobabooga/text-generation-webui) +* [ollama](https://github.com/ollama/ollama) +* [GPT4All](https://github.com/nomic-ai/gpt4all) + +--- + +# From original readme + +Phi-3.5-mini is a lightweight, state-of-the-art open model built upon datasets used for Phi-3 - synthetic data and filtered publicly available websites - with a focus on very high-quality, reasoning dense data. The model belongs to the Phi-3 model family and supports 128K token context length. The model underwent a rigorous enhancement process, incorporating both supervised fine-tuning, proximal policy optimization, and direct preference optimization to ensure precise instruction adherence and robust safety measures. + +## Usage + +### Requirements +Phi-3 family has been integrated in the `4.43.0` version of `transformers`. The current `transformers` version can be verified with: `pip list | grep transformers`. + +Examples of required packages: +``` +flash_attn==2.5.8 +torch==2.3.1 +accelerate==0.31.0 +transformers==4.43.0 +``` + +Phi-3.5-mini-instruct is also available in [Azure AI Studio](https://aka.ms/try-phi3.5mini) + +### Tokenizer + +Phi-3.5-mini-Instruct supports a vocabulary size of up to `32064` tokens. The [tokenizer files](https://huggingface.co/microsoft/Phi-3.5-mini-instruct/blob/main/added_tokens.json) already provide placeholder tokens that can be used for downstream fine-tuning, but they can also be extended up to the model's vocabulary size. + +### Input Formats +Given the nature of the training data, the Phi-3.5-mini-instruct model is best suited for prompts using the chat format as follows: + +``` +<|system|> +You are a helpful assistant.<|end|> +<|user|> +How to explain Internet for a medieval knight?<|end|> +<|assistant|> +``` + +### Loading the model locally +After obtaining the Phi-3.5-mini-instruct model checkpoint, users can use this sample code for inference. + +```python +import torch +from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline + +torch.random.manual_seed(0) + +model = AutoModelForCausalLM.from_pretrained( + "microsoft/Phi-3.5-mini-instruct", + device_map="cuda", + torch_dtype="auto", + trust_remote_code=True, +) +tokenizer = AutoTokenizer.from_pretrained("microsoft/Phi-3.5-mini-instruct") + +messages = [ + {"role": "system", "content": "You are a helpful AI assistant."}, + {"role": "user", "content": "Can you provide ways to eat combinations of bananas and dragonfruits?"}, + {"role": "assistant", "content": "Sure! Here are some ways to eat bananas and dragonfruits together: 1. Banana and dragonfruit smoothie: Blend bananas and dragonfruits together with some milk and honey. 2. Banana and dragonfruit salad: Mix sliced bananas and dragonfruits together with some lemon juice and honey."}, + {"role": "user", "content": "What about solving an 2x + 3 = 7 equation?"}, +] + +pipe = pipeline( + "text-generation", + model=model, + tokenizer=tokenizer, +) + +generation_args = { + "max_new_tokens": 500, + "return_full_text": False, + "temperature": 0.0, + "do_sample": False, +} + +output = pipe(messages, **generation_args) +print(output[0]['generated_text']) +``` \ No newline at end of file