0019-allow-arrays-of-strings.patch 740 B

123456789101112131415161718192021
  1. From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
  2. From: jmorganca <jmorganca@gmail.com>
  3. Date: Wed, 5 Mar 2025 17:41:07 -0800
  4. Subject: [PATCH] allow arrays of strings
  5. ---
  6. ggml/src/gguf.cpp | 1 -
  7. 1 file changed, 1 deletion(-)
  8. diff --git a/ggml/src/gguf.cpp b/ggml/src/gguf.cpp
  9. index ab13669c..9dfefd43 100644
  10. --- a/ggml/src/gguf.cpp
  11. +++ b/ggml/src/gguf.cpp
  12. @@ -777,7 +777,6 @@ enum gguf_type gguf_get_arr_type(const struct gguf_context * ctx, int64_t key_id
  13. const void * gguf_get_arr_data(const struct gguf_context * ctx, int64_t key_id) {
  14. GGML_ASSERT(key_id >= 0 && key_id < gguf_get_n_kv(ctx));
  15. - GGML_ASSERT(ctx->kv[key_id].get_type() != GGUF_TYPE_STRING);
  16. return ctx->kv[key_id].data.data();
  17. }