From 34b1cb5f58e29c14f8012503c0aabbe78377a952 Mon Sep 17 00:00:00 2001 From: Pavlo Paliychuk Date: Wed, 7 May 2025 18:29:43 -0400 Subject: [PATCH] chore: upgrade Neo4j to 5.26.2 and switch to local build for graph service (#455) --- docker-compose.yml | 13 ++++++----- server/poetry.lock | 54 +++++++++++++++++++++++++------------------ server/pyproject.toml | 9 ++++---- 3 files changed, 42 insertions(+), 34 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index e2ee91c..5717e16 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,8 +1,9 @@ -version: '3.8' +version: "3.8" services: graph: - image: zepai/graphiti:latest + build: + context: . ports: - "8000:8000" healthcheck: @@ -26,7 +27,7 @@ services: - NEO4J_PASSWORD=${NEO4J_PASSWORD} - PORT=8000 neo4j: - image: neo4j:5.22.0 + image: neo4j:5.26.2 healthcheck: test: wget "http://localhost:${NEO4J_PORT}" || exit 1 interval: 1s @@ -34,12 +35,12 @@ services: retries: 20 start_period: 3s ports: - - "7474:7474" # HTTP - - "${NEO4J_PORT}:${NEO4J_PORT}" # Bolt + - "7474:7474" # HTTP + - "${NEO4J_PORT}:${NEO4J_PORT}" # Bolt volumes: - neo4j_data:/data environment: - NEO4J_AUTH=${NEO4J_USER}/${NEO4J_PASSWORD} volumes: - neo4j_data: \ No newline at end of file + neo4j_data: diff --git a/server/poetry.lock b/server/poetry.lock index 6fed2b3..2a09024 100644 --- a/server/poetry.lock +++ b/server/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 2.1.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 2.1.3 and should not be changed by hand. [[package]] name = "annotated-types" @@ -106,7 +106,7 @@ description = "Backport of PEP 654 (exception groups)" optional = false python-versions = ">=3.7" groups = ["main", "dev"] -markers = "python_version < \"3.11\"" +markers = "python_version == \"3.10\"" files = [ {file = "exceptiongroup-1.2.2-py3-none-any.whl", hash = "sha256:3111b9d131c238bec2f8f516e123e14ba243563fb135d3fe885990585aa7795b"}, {file = "exceptiongroup-1.2.2.tar.gz", hash = "sha256:47c2edf7c6738fafb49fd34290706d1a1a2f4d1c6df275526b62cbb4aa5393cc"}, @@ -172,22 +172,27 @@ standard = ["uvicorn[standard] (>=0.15.0)"] [[package]] name = "graphiti-core" -version = "0.8.1" +version = "0.11.5" description = "A temporal graph building library" optional = false -python-versions = "^3.10" +python-versions = ">=3.10,<4" groups = ["main"] files = [] develop = false [package.dependencies] -diskcache = "^5.6.3" -neo4j = "^5.23.0" +diskcache = ">=5.6.3" +neo4j = ">=5.23.0" numpy = ">=1.0.0" -openai = "^1.53.0" -pydantic = "^2.8.2" -python-dotenv = "^1.0.1" -tenacity = "9.0.0" +openai = ">=1.53.0" +pydantic = ">=2.8.2" +python-dotenv = ">=1.0.1" +tenacity = ">=9.0.0" + +[package.extras] +anthropic = ["anthropic (>=0.49.0)"] +google-genai = ["google-genai (>=1.8.0)"] +groq = ["groq (>=0.2.0)"] [package.source] type = "directory" @@ -207,22 +212,25 @@ files = [ [[package]] name = "httpcore" -version = "0.13.2" +version = "1.0.9" description = "A minimal low-level HTTP client." optional = false -python-versions = ">=3.6" +python-versions = ">=3.8" groups = ["main"] files = [ - {file = "httpcore-0.13.2-py3-none-any.whl", hash = "sha256:52b7d9413f6f5592a667de9209d70d4d41aba3fb0540dd7c93475c78b85941e9"}, - {file = "httpcore-0.13.2.tar.gz", hash = "sha256:c16efbdf643e1b57bde0adc12c53b08645d7d92d6d345a3f71adfc2a083e7fd2"}, + {file = "httpcore-1.0.9-py3-none-any.whl", hash = "sha256:2d400746a40668fc9dec9810239072b40b4484b640a8c38fd654a024c7a1bf55"}, + {file = "httpcore-1.0.9.tar.gz", hash = "sha256:6e34463af53fd2ab5d807f399a9b45ea31c3dfa2276f15a2c3f00afff6e176e8"}, ] [package.dependencies] -h11 = "==0.*" -sniffio = "==1.*" +certifi = "*" +h11 = ">=0.16" [package.extras] +asyncio = ["anyio (>=4.0,<5.0)"] http2 = ["h2 (>=3,<5)"] +socks = ["socksio (==1.*)"] +trio = ["trio (>=0.22.0,<1.0)"] [[package]] name = "httptools" @@ -282,28 +290,28 @@ test = ["Cython (>=0.29.24)"] [[package]] name = "httpx" -version = "0.25.1" +version = "0.28.1" description = "The next generation HTTP client." optional = false python-versions = ">=3.8" groups = ["main"] files = [ - {file = "httpx-0.25.1-py3-none-any.whl", hash = "sha256:fec7d6cc5c27c578a391f7e87b9aa7d3d8fbcd034f6399f9f79b45bcc12a866a"}, - {file = "httpx-0.25.1.tar.gz", hash = "sha256:ffd96d5cf901e63863d9f1b4b6807861dbea4d301613415d9e6e57ead15fc5d0"}, + {file = "httpx-0.28.1-py3-none-any.whl", hash = "sha256:d909fcccc110f8c7faf814ca82a9a4d816bc5a6dbfea25d6591d6985b8ba59ad"}, + {file = "httpx-0.28.1.tar.gz", hash = "sha256:75e98c5f16b0f35b567856f597f06ff2270a374470a5c2392242528e3e3e42fc"}, ] [package.dependencies] anyio = "*" certifi = "*" -httpcore = "*" +httpcore = "==1.*" idna = "*" -sniffio = "*" [package.extras] brotli = ["brotli ; platform_python_implementation == \"CPython\"", "brotlicffi ; platform_python_implementation != \"CPython\""] cli = ["click (==8.*)", "pygments (==2.*)", "rich (>=10,<14)"] http2 = ["h2 (>=3,<5)"] socks = ["socksio (==1.*)"] +zstd = ["zstandard (>=0.18.0)"] [[package]] name = "idna" @@ -1097,7 +1105,7 @@ description = "A lil' TOML parser" optional = false python-versions = ">=3.8" groups = ["dev"] -markers = "python_version < \"3.11\"" +markers = "python_version == \"3.10\"" files = [ {file = "tomli-2.2.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:678e4fa69e4575eb77d103de3df8a895e1591b48e740211bd1067378c69e8249"}, {file = "tomli-2.2.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:023aa114dd824ade0100497eb2318602af309e5a55595f76b626d6d9f3b7b0a6"}, @@ -1431,4 +1439,4 @@ files = [ [metadata] lock-version = "2.1" python-versions = "^3.10" -content-hash = "30f046e703002a59db3ded2bbb507ab3b06eabe63a357cef885791e690538fb2" +content-hash = "c89b798bc1d33e6bb0bb39342362785d694487ad4f056942337eeb6528c96929" diff --git a/server/pyproject.toml b/server/pyproject.toml index ada3198..6666df2 100644 --- a/server/pyproject.toml +++ b/server/pyproject.toml @@ -13,8 +13,11 @@ fastapi = "^0.115.0" graphiti-core = { path = "../" } pydantic-settings = "^2.4.0" uvicorn = "^0.30.6" +httpx = "^0.28.1" -[tool.poetry.dev-dependencies] +[tool.poetry.group.dev.dependencies] +pydantic = "^2.8.2" +mypy = "^1.11.1" pytest = "^8.3.2" python-dotenv = "^1.0.1" pytest-asyncio = "^0.24.0" @@ -22,10 +25,6 @@ pytest-xdist = "^3.6.1" ruff = "^0.6.2" fastapi-cli = "^0.0.5" -[tool.poetry.group.dev.dependencies] -pydantic = "^2.8.2" -mypy = "^1.11.1" - [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api"