Skip to content

Commit 5dfc9d5

Browse files
Add changelog
1 parent ee607ae commit 5dfc9d5

File tree

1 file changed

+79
-46
lines changed

1 file changed

+79
-46
lines changed

CHANGELOG.md

Lines changed: 79 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## Next
44

5+
### Added
6+
7+
- Added GoogleGenAI (via `google-genai` SDK): includes `GeminiLLM` (generation/tool calling), `GeminiEmbedder` (embeddings), and integration examples/docs.
8+
59
### Fixed
610

711
- Fixed invalid lexical graph relationships causing "Relationship references unknown start node" errors during parquet import when nodes are pruned.
@@ -23,7 +27,6 @@
2327
- **Breaking**: `RelationshipType` with empty properties and `additional_properties=False` is now auto-corrected to `additional_properties=True` to prevent pruning of LLM-extracted properties.
2428
- Introduced `Pattern` Pydantic model for internal storage of graph patterns, replacing tuple format. Public APIs maintain backward compatibility by accepting both tuples and `Pattern` objects.
2529

26-
2730
## 1.12.0
2831

2932
## Added
@@ -36,7 +39,6 @@
3639
- Switched project/dependency management from Poetry to uv.
3740
- Dropped support for Python 3.9 (EOL)
3841

39-
4042
## 1.11.0
4143

4244
### Added
@@ -65,13 +67,11 @@
6567

6668
- Fixed an edge case where the LLM can output a property with type 'map', which was causing errors during import as it is not a valid property type in Neo4j.
6769

68-
6970
### Added
7071

7172
- Document node is now always created when running SimpleKGPipeline, even if `from_pdf=False`.
7273
- Document metadata is exposed in SimpleKGPipeline run method.
7374

74-
7575
## 1.9.1
7676

7777
### Fixed
@@ -123,7 +123,6 @@
123123
- The `chunk_index` property on `__Entity__` nodes is removed. Use the `FROM_CHUNK` relationship instead.
124124
- The `__entity__id` index is not used anymore and can be dropped from the database (it has been replaced by `__entity__tmp_internal_id`).
125125

126-
127126
## 1.7.0
128127

129128
### Added
@@ -138,14 +137,13 @@
138137

139138
- Improved log output readability in Retrievers and GraphRAG and added embedded vector to retriever result metadata for debugging.
140139
- Switched from pygraphviz to neo4j-viz
141-
- Renders interactive graph now on HTML instead of PNG
142-
- Removed `get_pygraphviz_graph` method
140+
- Renders interactive graph now on HTML instead of PNG
141+
- Removed `get_pygraphviz_graph` method
143142

144143
### Fixed
145144

146145
- Fixed a bug where the `$nin` operator for metadata pre-filtering in retrievers would create an invalid Cypher query.
147146

148-
149147
## 1.6.1
150148

151149
### Added
@@ -156,7 +154,6 @@
156154

157155
- Added `enforce_schema` parameter to `SimpleKGPipeline` for optional schema enforcement.
158156

159-
160157
## 1.6.0
161158

162159
### Added
@@ -174,7 +171,6 @@
174171
- Qdrant retriever now fallbacks on the point ID if the `external_id_property` is not found in the payload.
175172
- Updated a few dependencies, mainly `pypdf`, `anthropic` and `cohere`.
176173

177-
178174
## 1.5.0
179175

180176
### Added
@@ -237,82 +233,98 @@
237233
## 1.4.0
238234

239235
### Added
236+
240237
- Support for conversations with message history, including a new `message_history` parameter for LLM interactions.
241238
- Ability to include system instructions in LLM invoke method.
242239
- Summarization of chat history to enhance query embedding and context handling in GraphRAG.
243240

244241
### Changed
242+
245243
- Updated LLM implementations to handle message history consistently across providers.
246244
- The `id_prefix` parameter in the `LexicalGraphConfig` is deprecated.
247245

248246
### Fixed
247+
249248
- IDs for the Document and Chunk nodes in the lexical graph are now randomly generated and unique across multiple runs, fixing issues in the lexical graph where relationships were created between chunks that were created by different pipeline runs.
250249
- Improve logging for a better debugging experience: long lists and strings are now truncated. The max length can be controlled using the `LOGGING__MAX_LIST_LENGTH` and `LOGGING__MAX_STRING_LENGTH` env variables.
251250

252251
## 1.3.0
253252

254253
### Added
254+
255255
- Integrated `json-repair` package to handle and repair invalid JSON generated by LLMs.
256256
- Introduced `InvalidJSONError` exception for handling cases where JSON repair fails.
257257
- Ability to create a Pipeline or SimpleKGPipeline from a config file. See [the example](examples/build_graph/from_config_files/simple_kg_pipeline_from_config_file.py).
258258
- Added `OllamaLLM` and `OllamaEmbeddings` classes to make Ollama support more explicit. Implementations using the `OpenAILLM` and `OpenAIEmbeddings` classes will still work.
259259

260260
### Changed
261+
261262
- Updated LLM prompt for Entity and Relation extraction to include stricter instructions for generating valid JSON.
262263

263264
### Fixed
265+
264266
- Added schema functions to the documentation.
265267

266268
## 1.2.1
267269

268270
### Added
271+
269272
- Introduced optional lexical graph configuration for `SimpleKGPipeline`, enhancing flexibility in customizing node labels and relationship types in the lexical graph.
270273
- Introduced optional `neo4j_database` parameter for `SimpleKGPipeline`, `Neo4jChunkReader`and `Text2CypherRetriever`.
271274
- Ability to provide description and list of properties for entities and relations in the `SimpleKGPipeline` constructor.
272275

273276
### Fixed
277+
274278
- `neo4j_database` parameter is now used for all queries in the `Neo4jWriter`.
275279

276280
### Changed
281+
277282
- Updated all examples to use `neo4j_database` parameter instead of an undocumented neo4j driver constructor.
278283
- All `READ` queries are now routed to a reader replica (for clusters). This impacts all retrievers, the `Neo4jChunkReader` and `SinglePropertyExactMatchResolver` components.
279284

280-
281285
## 1.2.0
282286

283287
### Added
288+
284289
- Made `relations` and `potential_schema` optional in `SchemaBuilder`.
285290
- Added a check to prevent the use of deprecated Cypher syntax for Neo4j versions 5.23.0 and above.
286291
- Added a `LexicalGraphBuilder` component to enable the import of the lexical graph (document, chunks) without performing entity and relation extraction.
287292
- Added a `Neo4jChunkReader` component to be able to read chunk text from the database.
288293

289294
### Changed
295+
290296
- Vector and Hybrid retrievers used with `return_properties` now also return the node labels (`nodeLabels`) and the node's element ID (`id`).
291297
- `HybridRetriever` now filters out the embedding property index in `self.vector_index_name` from the retriever result by default.
292298
- Removed support for neo4j.AsyncDriver in the KG creation pipeline, affecting Neo4jWriter and related components.
293299
- Updated examples and unit tests to reflect the removal of async driver support.
294300

295301
### Fixed
302+
296303
- Resolved issue with `AzureOpenAIEmbeddings` incorrectly inheriting from `OpenAIEmbeddings`, now inherits from `BaseOpenAIEmbeddings`.
297304

298305
## 1.1.0
299306

300307
### Added
308+
301309
- Introduced a `fail_if_exist` option to index creation functions to control behavior when an index already exists.
302310
- Added Qdrant retriever in neo4j_graphrag.retrievers.
303311

304312
### Changed
313+
305314
- Comprehensive rewrite of the README to improve clarity and provide detailed usage examples.
306315

307316
## 1.0.0
308317

309318
### Fixed
319+
310320
- Fix a bug where `openai` Python client and `numpy` were required to import any embedder or LLM.
311321

312322
### Changed
323+
313324
- The value associated to the enum field `OnError.IGNORE` has been changed from "CONTINUE" to "IGNORE" to stick to the convention and match the field name.
314325

315326
### Added
327+
316328
- Added `SinglePropertyExactMatchResolver` component allowing to merge entities with exact same property (e.g. name)
317329
- Added the `SimpleKGPipeline` class, a simplified abstraction layer to streamline knowledge graph building processes from text documents.
318330

@@ -321,11 +333,13 @@
321333
## 1.0.0a0
322334

323335
### Added
336+
324337
- Added `SinglePropertyExactMatchResolver` component allowing to merge entities with exact same property (e.g. name)
325338

326339
## 0.7.0
327340

328341
### Added
342+
329343
- Added AzureOpenAILLM and AzureOpenAIEmbeddings to support Azure served OpenAI models
330344
- Added `template` validation in `PromptTemplate` class upon construction.
331345
- Examples demonstrating the use of Mistral embeddings and LLM in RAG pipelines.
@@ -340,6 +354,7 @@
340354
- Added support for Qdrant - added optional dependency to `qdrant-client`.
341355

342356
### Fixed
357+
343358
- Resolved import issue with the Vertex AI Embeddings class.
344359
- Fixed bug in `Text2CypherRetriever` using `custom_prompt` arg where the `search` method would not inject the `query_text` content.
345360
- `custom_prompt` arg is now converted to `Text2CypherTemplate` class within the `Text2CypherRetriever.get_search_results` method.
@@ -349,133 +364,151 @@
349364
- Improved query performance in Neo4jWriter: created nodes now have a generic `__KGBuilder__` label and an index is created on the `__KGBuilder__.id` property. Moreover, insertion queries are now batched. Batch size can be controlled using the `batch_size` parameter in the `Neo4jWriter` component.
350365

351366
### Changed
367+
352368
- Moved the Embedder class to the neo4j_graphrag.embeddings directory for better organization alongside other custom embedders.
353369
- Removed query argument from the GraphRAG class' `.search` method; users must now use `query_text`.
354370
- Neo4jWriter component now runs a single query to merge node and set its embeddings if any.
355371
- Nodes created by the `Neo4jWriter` now have an extra `__KGBuilder__` label. Nodes from the entity graph also have an `__Entity__` label.
356372
- Dropped support for Python 3.8 (end of life).
357373

358374
## 0.6.3
375+
359376
### Changed
377+
360378
- Updated documentation links in README.
361379
- Renamed deprecated package references in documentation.
362380

363381
### Added
382+
364383
- Introduction page to the documentation content tree.
365384
- Introduced a new Vertex AI embeddings class for generating text embeddings using Vertex AI.
366385
- Updated documentation to include OpenAI and Vertex AI embeddings classes.
367386
- Added google-cloud-aiplatform as an optional dependency for Vertex AI embeddings.
368387

369388
### Fixed
389+
370390
- Make `pygraphviz` an optional dependency - it is now only required when calling `pipeline.draw`.
371391

372392
## 0.6.2
373393

374394
### Fixed
395+
375396
- Moved pygraphviz to optional dependencies under [tool.poetry.extras] in pyproject.toml to resolve an issue where pip install neo4j-graphrag incorrectly required pygraphviz as a mandatory dependency.
376397

377398
## 0.6.1
378399

379400
### Changed
401+
380402
- Officially renamed neo4j-genai to neo4j-graphrag. For the final release version of neo4j-genai, please visit https://pypi.org/project/neo4j-genai/.
381403

382404
## 0.6.0
383405

384406
### IMPORTANT NOTICE
407+
385408
- The `neo4j-genai` package is now deprecated. Users are advised to switch to the new package `neo4j-graphrag`.
409+
386410
### Added
411+
387412
- Ability to visualise pipeline with `my_pipeline.draw("pipeline.png")`.
388413
- `LexicalGraphBuilder` component to create the lexical graph without entity-relation extraction.
389414

390415
### Fixed
416+
391417
- Pipelines now return correct results when the same pipeline is run in parallel.
392418

393419
### Changed
420+
394421
- Pipeline run method now return a PipelineResult object.
395422
- Improved parameter validation for pipelines (#124). Pipeline now raise an error before a run starts if:
396-
- the same parameter is mapped twice
397-
- or a parameter is defined in the mapping but is not a valid component input
398-
423+
- the same parameter is mapped twice
424+
- or a parameter is defined in the mapping but is not a valid component input
399425

400426
## 0.5.0
401427

402428
### Added
429+
403430
- PDF-to-graph pipeline for knowledge graph construction in experimental mode
404431
- Introduced support for Component/Pipeline flexible architecture.
405432
- Added new components for knowledge graph construction, including text splitters, schema builders, entity-relation extractors, and Neo4j writers.
406433
- Implemented end-to-end tests for the new knowledge graph builder pipeline.
407434

408435
### Changed
436+
409437
- When saving the lexical graph in a KG creation pipeline, the document is also saved as a specific node, together with relationships between each chunk and the document they were created from.
410438

411439
### Fixed
440+
412441
- Corrected the hybrid retriever query to ensure proper normalization of scores in vector search results.
413442

414443
## 0.4.0
415444

416445
### Added
446+
417447
- Add optional custom_prompt arg to the Text2CypherRetriever class.
418448

419449
### Changed
450+
420451
- `GraphRAG.search` method first parameter has been renamed `query_text` (was `query`) for consistency with the retrievers interface.
421452
- Made `GraphRAG.search` method backwards compatible with the query parameter, raising warnings to encourage using query_text instead.
422453

423454
## 0.3.1
424455

425456
### Fixed
426-
- Corrected initialization to allow specifying the embedding model name.
427-
- Removed sentence_transformers from embeddings/__init__.py to avoid ImportError when the package is not installed.
457+
458+
- Corrected initialization to allow specifying the embedding model name.
459+
- Removed sentence_transformers from embeddings/**init**.py to avoid ImportError when the package is not installed.
428460

429461
## 0.3.0
430462

431463
### Added
432-
- Stopped embeddings from being returned when searching with `VectorRetriever`. Added `nodeLabels` and `id` to the metadata of `VectorRetriever` results.
433-
- Added `upsert_vector` utility function for attaching vectors to node properties.
434-
- Introduced `Neo4jInsertionError` for handling insertion failures in Neo4j.
435-
- Included Pinecone and Weaviate retrievers in neo4j_graphrag.retrievers.
436-
- Introduced the GraphRAG object, enabling a full RAG (Retrieval-Augmented Generation) pipeline with context retrieval, prompt formatting, and answer generation.
437-
- Added PromptTemplate and RagTemplate for customizable prompt generation.
438-
- Added LLMInterface with implementation for OpenAI LLM.
439-
- Updated project configuration to support multiple Python versions (3.8 to 3.12) in CI workflows.
440-
- Improved developer experience by copying the docstring from the `Retriever.get_search_results` method to the `Retriever.search` method
441-
- Support for specifying database names in index handling methods and retrievers.
442-
- User Guide in documentation.
443-
- Introduced result_formatter argument to all retrievers, allowing custom formatting of retriever results.
464+
465+
- Stopped embeddings from being returned when searching with `VectorRetriever`. Added `nodeLabels` and `id` to the metadata of `VectorRetriever` results.
466+
- Added `upsert_vector` utility function for attaching vectors to node properties.
467+
- Introduced `Neo4jInsertionError` for handling insertion failures in Neo4j.
468+
- Included Pinecone and Weaviate retrievers in neo4j_graphrag.retrievers.
469+
- Introduced the GraphRAG object, enabling a full RAG (Retrieval-Augmented Generation) pipeline with context retrieval, prompt formatting, and answer generation.
470+
- Added PromptTemplate and RagTemplate for customizable prompt generation.
471+
- Added LLMInterface with implementation for OpenAI LLM.
472+
- Updated project configuration to support multiple Python versions (3.8 to 3.12) in CI workflows.
473+
- Improved developer experience by copying the docstring from the `Retriever.get_search_results` method to the `Retriever.search` method
474+
- Support for specifying database names in index handling methods and retrievers.
475+
- User Guide in documentation.
476+
- Introduced result_formatter argument to all retrievers, allowing custom formatting of retriever results.
444477

445478
### Changed
446-
- Refactored import paths for retrievers to neo4j_graphrag.retrievers.
447-
- Implemented exception chaining for all re-raised exceptions to improve stack trace readability.
448-
- Made error messages in `index.py` more consistent.
449-
- Renamed `Retriever._get_search_results` to `Retriever.get_search_results`
450-
- Updated retrievers and index handling methods to accept optional database names.
479+
480+
- Refactored import paths for retrievers to neo4j_graphrag.retrievers.
481+
- Implemented exception chaining for all re-raised exceptions to improve stack trace readability.
482+
- Made error messages in `index.py` more consistent.
483+
- Renamed `Retriever._get_search_results` to `Retriever.get_search_results`
484+
- Updated retrievers and index handling methods to accept optional database names.
451485

452486
## 0.2.0
453487

454488
### Fixed
455489

456-
- Removed Pinecone and Weaviate retrievers from **init**.py to prevent ImportError when optional dependencies are not installed.
457-
- Moved few-shot examples in `Text2CypherRetriever` to the constructor for better initialization and usage. Updated unit tests and example script accordingly.
458-
- Fixed regex warnings in E2E tests for Weaviate and Pinecone retrievers.
459-
- Corrected HuggingFaceEmbeddings import in E2E tests.
460-
490+
- Removed Pinecone and Weaviate retrievers from **init**.py to prevent ImportError when optional dependencies are not installed.
491+
- Moved few-shot examples in `Text2CypherRetriever` to the constructor for better initialization and usage. Updated unit tests and example script accordingly.
492+
- Fixed regex warnings in E2E tests for Weaviate and Pinecone retrievers.
493+
- Corrected HuggingFaceEmbeddings import in E2E tests.
461494

462495
## 0.2.0a5
463496

464497
## 0.2.0a3
465498

466499
### Added
467500

468-
- Introduced custom exceptions for improved error handling, including `RetrieverInitializationError`, `SearchValidationError`, `FilterValidationError`, `EmbeddingRequiredError`, `RecordCreationError`, `Neo4jIndexError`, and `Neo4jVersionError`.
469-
- Retrievers that integrates with a Weaviate vector database: `WeaviateNeo4jRetriever`.
470-
- New return types that help with getting retriever results: `RetrieverResult` and `RetrieverResultItem`.
471-
- Supported wrapper embedder object for sentence-transformers embeddings: `SentenceTransformerEmbeddings`.
472-
- `Text2CypherRetriever` object which allows for the retrieval of records from a Neo4j database using natural language.
501+
- Introduced custom exceptions for improved error handling, including `RetrieverInitializationError`, `SearchValidationError`, `FilterValidationError`, `EmbeddingRequiredError`, `RecordCreationError`, `Neo4jIndexError`, and `Neo4jVersionError`.
502+
- Retrievers that integrates with a Weaviate vector database: `WeaviateNeo4jRetriever`.
503+
- New return types that help with getting retriever results: `RetrieverResult` and `RetrieverResultItem`.
504+
- Supported wrapper embedder object for sentence-transformers embeddings: `SentenceTransformerEmbeddings`.
505+
- `Text2CypherRetriever` object which allows for the retrieval of records from a Neo4j database using natural language.
473506

474507
### Changed
475508

476-
- Replaced `ValueError` with custom exceptions across various modules for clearer and more specific error messages.
509+
- Replaced `ValueError` with custom exceptions across various modules for clearer and more specific error messages.
477510

478511
### Fixed
479512

480-
- Updated documentation to include new custom exceptions.
481-
- Improved the use of Pydantic for input data validation for retriever objects.
513+
- Updated documentation to include new custom exceptions.
514+
- Improved the use of Pydantic for input data validation for retriever objects.

0 commit comments

Comments
 (0)