The agent engineering platform.
Python agentsaiai-agentsanthropicchatgptdeepagentsenterpriseframeworkgeminigenerative-ailangchainlanggraphllmmultiagentopen-sourceopenaipydanticpythonragtypescript
chore(langchain): improve PostgreSQL Manager upsert SQLAlchemy API calls. (#32748)
Rémy HUBSCHERfcf71753924f
diff --git a/libs/langchain/langchain/indexes/_sql_record_manager.py b/libs/langchain/langchain/indexes/_sql_record_manager.pyindex 8d24433ae4..9c83318314 100644--- a/libs/langchain/langchain/indexes/_sql_record_manager.py+++ b/libs/langchain/langchain/indexes/_sql_record_manager.py@@ -326,7 +326,7 @@ class SQLRecordManager(RecordManager):records_to_upsert,)stmt = pg_insert_stmt.on_conflict_do_update( # type: ignore[assignment]- "uix_key_namespace", # Name of constraint+ constraint="uix_key_namespace", # Name of constraintset_={"updated_at": pg_insert_stmt.excluded.updated_at,"group_id": pg_insert_stmt.excluded.group_id,@@ -408,7 +408,7 @@ class SQLRecordManager(RecordManager):records_to_upsert,)stmt = pg_insert_stmt.on_conflict_do_update( # type: ignore[assignment]- "uix_key_namespace", # Name of constraint+ constraint="uix_key_namespace", # Name of constraintset_={"updated_at": pg_insert_stmt.excluded.updated_at,"group_id": pg_insert_stmt.excluded.group_id,