You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+3Lines changed: 3 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -6,6 +6,9 @@
6
6
7
7
- Added the `run_with_context` method to `Component`. This method includes a `context_` parameter, which provides information about the pipeline from which the component is executed (e.g., the `run_id`). It also enables the component to send events to the pipeline's callback function.
8
8
9
+
### Fixed
10
+
11
+
- Added `enforce_schema` parameter to `SimpleKGPipeline` for optional schema enforcement.
Copy file name to clipboardExpand all lines: src/neo4j_graphrag/experimental/pipeline/kg_builder.py
+7-1Lines changed: 7 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -25,7 +25,10 @@
25
25
from neo4j_graphrag.experimental.components.kg_writer import KGWriter
26
26
from neo4j_graphrag.experimental.components.pdf_loader import DataLoader
27
27
from neo4j_graphrag.experimental.components.text_splitters.base import TextSplitter
28
-
from neo4j_graphrag.experimental.components.types import LexicalGraphConfig
28
+
from neo4j_graphrag.experimental.components.types import (
29
+
LexicalGraphConfig,
30
+
SchemaEnforcementMode,
31
+
)
29
32
from neo4j_graphrag.experimental.pipeline.config.object_config import ComponentType
30
33
from neo4j_graphrag.experimental.pipeline.config.runner import PipelineRunner
31
34
from neo4j_graphrag.experimental.pipeline.config.template_pipeline import (
@@ -61,6 +64,7 @@ class SimpleKGPipeline:
61
64
- dict: following the SchemaRelation schema, ie with label, description and properties keys
62
65
63
66
potential_schema (Optional[List[tuple]]): A list of potential schema relationships.
67
+
enforce_schema (str): Validation of the extracted entities/rels against the provided schema. Defaults to "NONE", where schema enforcement will be ignored even if the schema is provided. Possible values "None" or "STRICT".
64
68
from_pdf (bool): Determines whether to include the PdfLoader in the pipeline.
65
69
If True, expects `file_path` input in `run` methods.
0 commit comments