Preston Rasmussen
d6d4bbdeb7
don't save duplicate edges ( #927 )
...
* don't save duplicate edges
* remove build duplicate edges
2025-09-24 17:24:57 -04:00
Daniel Chalef
7cf5ee6288
Skip entity attribute extraction when no fields defined ( #924 )
2025-09-24 13:23:37 -04:00
Preston Rasmussen
1c27a3563b
update prompts and support thinking models ( #846 )
...
* update prompts and support thinking models
* update
* type ignore
2025-08-19 12:31:50 -04:00
Preston Rasmussen
baa6825708
ensure ascii default to false ( #817 )
2025-08-08 11:20:02 -04:00
HUGO SON
ce9ef3ca79
Add support for non-ASCII characters in LLM prompts ( #805 )
...
* Add support for non-ASCII characters in LLM prompts
- Add ensure_ascii parameter to Graphiti class (default: True)
- Create to_prompt_json helper function for consistent JSON serialization
- Update all prompt files to use new helper function
- Preserve Korean/Japanese/Chinese characters when ensure_ascii=False
- Maintain backward compatibility with existing behavior
Fixes issue where non-ASCII characters were escaped as unicode sequences
in prompts, making them unreadable in LLM logs and potentially affecting
model understanding.
* Remove unused json imports after replacing with to_prompt_json helper
- Fix ruff lint errors (F401) for unused json imports
- All prompt files now use to_prompt_json helper instead of json.dumps
- Maintains clean code style and passes lint checks
* Fix ensure_ascii propagation to all LLM calls
- Add ensure_ascii parameter to maintenance operation functions that were missing it
- Update function signatures in node_operations, community_operations, temporal_operations, and edge_operations
- Ensure all llm_client.generate_response calls receive proper ensure_ascii context
- Fix hardcoded ensure_ascii: True values that prevented non-ASCII character preservation
- Maintain backward compatibility with default ensure_ascii=True
- Complete the fix for issue #804 ensuring Korean/Japanese/Chinese characters are properly handled in LLM prompts
2025-08-08 11:07:32 -04:00
Preston Rasmussen
ab8106cb4f
move summary out of attribute extraction ( #792 )
...
* move summary out of attribute extraction
* linter
* linter
* fix db query
2025-07-31 12:15:21 -04:00
Preston Rasmussen
19bddb5528
validate pydantic objects ( #783 )
...
* validate pydantic objects
* unused imports
* linter
2025-07-29 17:54:09 -04:00
Preston Rasmussen
62df6624d4
bulk utils update ( #727 )
...
* bulk utils update
* remove unused imports
* edge model type guard
2025-07-15 11:42:08 -04:00
Preston Rasmussen
0675ac2b7d
Bulk ingestion ( #698 )
...
* partial
* update
* update
* update
* update
* updates
* updates
* update
* update
2025-07-10 12:14:49 -04:00
Daniel Chalef
c29893d972
Excluded entity type filtering ( #624 )
...
* excluded entities filtering
* Fix variable name casing in test_entity_exclusion_int.py for consistency
2025-06-26 20:54:43 -07:00
Preston Rasmussen
2b27353097
Node name bug fix ( #622 )
...
* fixes
* fix bugs
* change version
2025-06-24 17:13:27 -04:00
Preston Rasmussen
e8bf81fc6b
add IS_DUPLICATE_OF edges ( #599 )
...
* add IS_DUPLICATE_OF edges
* cypher query update
* robust handling
2025-06-17 11:56:55 -04:00
Preston Rasmussen
14146dc46f
Add support for falkordb ( #575 )
...
* [wip] add support for falkordb
* updates
* fix-async
* progress
* fix-issues
* rm-date-handler
* red-code
* rm-uns-try
* fix-exm
* rm-un-lines
* fix-comments
* fix-se-utils
* fix-falkor-readme
* fix-falkor-cosine-score
* update-falkor-ver
* fix-vec-sim
* min-updates
* make format
* update graph driver abstraction
* poetry lock
* updates
* linter
* Update graphiti_core/search/search_utils.py
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
---------
Co-authored-by: Dudi Zimberknopf <zimber.dudi@gmail.com>
Co-authored-by: Gal Shubeli <galshubeli93@gmail.com>
Co-authored-by: Gal Shubeli <124919062+galshubeli@users.noreply.github.com>
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-13 12:06:57 -04:00
Preston Rasmussen
ebee09b335
Edge extraction and Node Deduplication updates ( #564 )
...
* update tests
* updated fact extraction
* optimize node deduplication
* linting
* Update graphiti_core/utils/maintenance/edge_operations.py
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
---------
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-06-06 12:28:52 -04:00
Preston Rasmussen
9422b6f5fb
Node dedupe efficiency ( #490 )
...
* update resolve extracted edge
* updated edge resolution
* dedupe nodes update
* single pass node resolution
* updates
* mypy updates
* Update graphiti_core/prompts/dedupe_nodes.py
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
* remove unused imports
* mypy
---------
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-05-15 13:56:33 -04:00
Preston Rasmussen
4198483993
improve memory leak ( #478 )
2025-05-12 16:32:27 -04:00
Preston Rasmussen
fd9969b5a1
Update dedupe prompt ( #457 )
...
* improve dedupe logic
* cut summary length
* update unit tests
2025-05-07 23:23:31 -04:00
prestonrasmussen
8ce9b1e157
fix bugs
2025-05-07 22:46:35 -04:00
Preston Rasmussen
1f2f1eeab5
Size optimizations ( #456 )
...
* memory optimizations for vectors
* debugged
* unused import
* Update graphiti_core/edges.py
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
---------
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-05-07 20:08:30 -04:00
Preston Rasmussen
6b85e92105
Fix empty node name issues ( #433 )
...
* fixes
* fix
* remove unused imports
* format
* bump version
2025-05-02 12:16:26 -04:00
Preston Rasmussen
2ffc58b3da
small model fix ( #432 )
...
* updated dedupe nodes operations
* updates
* Update examples/podcast/podcast_transcript.txt
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
* mypy
---------
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-05-02 10:08:25 -04:00
Preston Rasmussen
e9e511b16d
filter out empty node names ( #427 )
...
* filter out empty node names
* Update graphiti_core/utils/maintenance/node_operations.py
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
---------
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-04-30 21:40:36 -04:00
Preston Rasmussen
c7f1db9974
source description ( #424 )
2025-04-30 15:18:28 -04:00
Preston Rasmussen
1193b25fa3
add_episode() refactor (#421 )
...
* temporal updates
* update resolve nodes
* dedupe edge updates
* edge dedupe
* extract attributes
* update dynamic pydantic model
* first pass of extract node attributes
* no errors
* bug fixes
* bug fixes
* prompt updates
* prompt updates
* updates
* updates
* remove unused imports
* update tests based on changes
* remove unused import
2025-04-30 12:08:52 -04:00
Preston Rasmussen
0b94e0e603
Bulk embed ( #403 )
...
* add batch embeddings
* bulk edge and node embeddings
* update embeddings during add_episode
* Update graphiti_core/embedder/client.py
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
* mypy
---------
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-04-26 22:09:12 -04:00
Preston Rasmussen
a26b25dc06
Add episode refactor ( #399 )
...
* partial refactor
* get relevant nodes refactor
* load edges updates
* refactor triplets
* not there yet
* node search update
* working refactor
* updates
* mypy
* mypy
2025-04-26 00:24:23 -04:00
Preston Rasmussen
064d9207d2
preserve labels when deduplicating a node ( #379 )
...
* preserve labels when deduplicating a node
* entity type updates
* Update graphiti_core/utils/maintenance/node_operations.py
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
---------
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-04-20 15:14:03 -04:00
Preston Rasmussen
5274970be3
reduce entity type attribute hallucinations ( #365 )
...
* reduce entity type attribute hallucinations
* reduce entity type attribute hallucinations
* reduce entity type attribute hallucinations
* mypy fix
* mypy fix
* mypy fix
2025-04-16 19:09:25 -04:00
Daniel Chalef
0f6ac57dab
chore: update version to 0.9.3 and restructure dependencies ( #338 )
...
* Bump version from 0.9.0 to 0.9.1 in pyproject.toml and update google-genai dependency to >=0.1.0
* Bump version from 0.9.1 to 0.9.2 in pyproject.toml
* Update google-genai dependency version to >=0.8.0 in pyproject.toml
* loc file
* Update pyproject.toml to version 0.9.3, restructure dependencies, and modify author format. Remove outdated Google API key note from README.md.
* upgrade poetry and ruff
2025-04-08 20:47:38 -07:00
Daniel Chalef
9e78890f2e
Gemini support ( #324 )
...
* first cut
* Update dependencies and enhance README for optional LLM providers
- Bump aiohttp version from 3.11.14 to 3.11.16
- Update yarl version from 1.18.3 to 1.19.0
- Modify pyproject.toml to include optional extras for Anthropic, Groq, and Google Gemini
- Revise README.md to reflect new optional LLM provider installation instructions and clarify API key requirements
* Remove deprecated packages from poetry.lock and update content hash
- Removed cachetools, google-auth, google-genai, pyasn1, pyasn1-modules, rsa, and websockets from the lock file.
- Added new extras for anthropic, google-genai, and groq.
- Updated content hash to reflect changes.
* Refactor import paths for GeminiClient in README and __init__.py
- Updated import statement in README.md to reflect the new module structure for GeminiClient.
- Removed GeminiClient from the __all__ list in __init__.py as it is no longer directly imported.
* Refactor import paths for GeminiEmbedder in README and __init__.py
- Updated import statement in README.md to reflect the new module structure for GeminiEmbedder.
- Removed GeminiEmbedder and GeminiEmbedderConfig from the __all__ list in __init__.py as they are no longer directly imported.
2025-04-06 09:27:04 -07:00
Preston Rasmussen
f536c4e948
get edges by uuids return empty list instead of errors ( #308 )
...
* get edges by uuids return empty list instead of errors
* lint
* fix null bugs
* guard rails for null summary
* supress
2025-03-27 15:00:05 -04:00
Preston Rasmussen
04203506d9
fix bug with updating node type attributes ( #305 )
...
fix bug with saving new properties
2025-03-26 12:37:48 -04:00
Preston Rasmussen
d91aaa052c
node classification failsafe - remove node labels not part of the custom ontology ( #295 )
...
* node classification failsafe
* Update graphiti_core/utils/maintenance/node_operations.py
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
* test update
* dict.keys update
---------
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-03-18 18:32:56 -04:00
Preston Rasmussen
e83bcbb435
swap type_description to docstring ( #287 )
...
* swap type_description to docstring
* remove unused imports
* bump version
* removed unused imports
2025-03-05 15:27:03 -05:00
Preston Rasmussen
f73867e0fa
Entity classification updates ( #285 )
...
* updates
* tested
* remove unused imports
* llm outputs will be dicts rather than pydantic models
* removed unused imports
2025-03-05 12:08:11 -05:00
Preston Rasmussen
7f20b21572
Entity attributes in prompts ( #284 )
...
* add node attributes to prompts
* tested
* attribute update
2025-03-04 16:34:19 -05:00
Preston Rasmussen
a18dde36be
Catch classification exceptions ( #283 )
...
* Catch classification exceptions
* except
* Update graphiti_core/utils/maintenance/node_operations.py
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
---------
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-02-28 17:06:25 -05:00
Preston Rasmussen
6f874730f3
Entity classification updates ( #281 )
...
* node classification updates
* update
* remove unused code
* update
2025-02-27 15:12:50 -05:00
Preston Rasmussen
1d2417ec26
Search optimizations ( #280 )
...
fix node distance search
2025-02-27 11:51:10 -05:00
Preston Rasmussen
29a071b2b8
Custom ontology ( #262 )
...
* ontology
* extract and save node labels
* extract entity type properties
* neo4j upgrade needed
* add entity types
* update typing
* update types
* updates
* Update graphiti_core/utils/maintenance/node_operations.py
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
* fix warning
* mypy updates
* update properties
* mypy ignore
* mypy types
* bump version
---------
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
2025-02-13 12:17:52 -05:00
Preston Rasmussen
0e45d15462
Add triple update ( #263 )
...
* update add-triplet
* test fixes
2025-02-12 12:04:43 -05:00
Preston Rasmussen
00fe87679e
Bounded semaphore - limiting concurrency ( #244 )
...
* WIP
* add semaphore
* remove unused imports
* remove unused imports
* lower concurrency limit
2024-12-17 13:08:18 -05:00
Daniel Chalef
445dccc021
refactor: use utc_now() for consistent UTC datetime handling ( #234 )
...
* ensure utc timezones
* fix: dep cycle
---------
Co-authored-by: paulpaliychuk <pavlo.paliychuk.ca@gmail.com>
2024-12-09 10:36:04 -08:00
Daniel Chalef
567a8ab74a
Implement OpenAI Structured Output ( #225 )
...
* implement so
* bug fixes and typing
* inject schema for non-openai clients
* correct datetime format
* remove List keyword
* Refactor node_operations.py to use updated prompt_library functions
* update example
2024-12-05 07:03:18 -08:00
Preston Rasmussen
a8a73ec38b
Add episode latency improvements ( #214 )
...
* reformat prompts
* update prompts
* update
* update
* update
* update
* update
* mypy
2024-11-13 20:13:06 -05:00
Preston Rasmussen
eba9f40ca2
add reflexion ( #212 )
...
* add reflexion
* clean up boolean logic
* update conditional
* cap reflexion iterations
* don't do an extra reflection step
2024-11-13 11:58:56 -05:00
Preston Rasmussen
3199e893ed
add_fact endpoint ( #207 )
...
* add_fact endpoint
* bump version
* add edge invalidation
* update
2024-11-06 09:12:21 -05:00
Preston Rasmussen
6c3b32e620
make broader use of debug logs ( #187 )
2024-10-11 16:38:56 -04:00
Daniel Chalef
32b51530ec
feat: Fix bug in dedupe_node_list function ( #137 )
...
The code changes fix a bug in the `dedupe_node_list` function where a node instance was not found in the node map. The bug is now handled by logging a warning message and skipping the iteration. This ensures that the function continues to execute without any errors.
2024-09-20 21:03:20 -07:00
Preston Rasmussen
4122d350a5
add extract nodes from text prompt ( #106 )
2024-09-11 12:06:08 -04:00