From 10b0836ff4145922895c01416d23f3f0dd307103 Mon Sep 17 00:00:00 2001
From: Logan <logan.markewich@live.com>
Date: Wed, 3 Apr 2024 14:20:35 -0600
Subject: [PATCH] Make chat message to dict safer (#12526)

---
 llama-index-core/llama_index/core/base/llms/types.py | 2 +-
 llama-index-core/pyproject.toml                      | 2 +-
 pants.toml                                           | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/llama-index-core/llama_index/core/base/llms/types.py b/llama-index-core/llama_index/core/base/llms/types.py
index 567bd8a36e..204378d012 100644
--- a/llama-index-core/llama_index/core/base/llms/types.py
+++ b/llama-index-core/llama_index/core/base/llms/types.py
@@ -63,7 +63,7 @@ class ChatMessage(BaseModel):
         # ensure all additional_kwargs are serializable
         msg = super().dict(**kwargs)
 
-        for key, value in msg["additional_kwargs"].items():
+        for key, value in msg.get("additional_kwargs", {}).items():
             value = self._recursive_serialization(value)
             if not isinstance(value, (str, int, float, bool, dict, list, type(None))):
                 raise ValueError(
diff --git a/llama-index-core/pyproject.toml b/llama-index-core/pyproject.toml
index b01d921ea9..35301de376 100644
--- a/llama-index-core/pyproject.toml
+++ b/llama-index-core/pyproject.toml
@@ -83,7 +83,7 @@ dirtyjson = "^1.0.8"
 tqdm = "^4.66.1"
 pillow = ">=9.0.0"
 PyYAML = ">=6.0.1"
-llamaindex-py-client = "^0.1.15"
+llamaindex-py-client = "^0.1.16"
 wrapt = "*"
 
 [tool.poetry.extras]
diff --git a/pants.toml b/pants.toml
index ffed2a5bec..79bfbb34c0 100644
--- a/pants.toml
+++ b/pants.toml
@@ -9,7 +9,7 @@ pants_version = "2.19.0"
 remote_cache_read = true
 remote_cache_write = true
 remote_instance_name = "main"
-remote_store_address = "grpc://44.204.50.6:9092"
+remote_store_address = "grpc://framework-ci-balancer-1983728860.us-east-1.elb.amazonaws.com:9092"
 unmatched_build_file_globs = "error"
 
 [black]
-- 
GitLab