Commit graph

41 commits

Author SHA1 Message Date
Ikko Eltociear Ashimine
87fbf31a78
docs: update agent.ipynb (#273)
persistance -> persistence
2025-04-06 21:31:46 -04:00
Daniel Chalef
d3c83adb04
Enhance README and add quickstart example for Graphiti (#326)
- Updated the main README to direct users to the new quickstart example.
- Added a comprehensive quickstart example demonstrating Graphiti's core functionalities, including connecting to Neo4j, adding episodes, and performing searches.
- Created a requirements.txt file for the quickstart example to manage dependencies.
- Documented setup instructions and next steps for users to explore Graphiti's capabilities.
2025-04-06 09:24:02 -07:00
Preston Rasmussen
fb37565112
Retrieve episodes override (#319)
* add episode override

* add test

* make format
2025-04-02 17:19:24 -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
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
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
Preston Rasmussen
34496ffa6a
Abstract Neo4j filters in search queries (#243)
* move null check for search queries to python

* update search filtering

* update

* update
2024-12-16 21:45:45 -05:00
Preston Rasmussen
9f3dd5552a
add generic client (#237)
* add generic client

* format
2024-12-10 22:02:46 -05: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
0fbe5c0704
Pagination for get by group_id (#218)
* add pagination to subgraphs

* update pagination

* update LiteralString import

* cleanup

* cleanup

* update embedding dims
2024-12-02 11:17:37 -05:00
Preston Rasmussen
281fe072cb
add fulltext search limit (#215)
* add fulltext search limit

* format

* update

* update

* update tests

* remove unused imports

* format

* mypy
2024-11-14 12:18:18 -05: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
c266f55b88
Update MSC dataset (#208)
jsonl
2024-11-06 11:00:06 -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
c8ff5be8ce
Msc benchmark update (#173)
* eval update

* I sped it up

* make format

* search updates

* updates

* cleanup

* make format

* remove unused imports

* poetry lock
2024-10-03 15:39:35 -04:00
Preston Rasmussen
fd341a6f16
Add MSC benchmark and improve search performance (#157)
* test cases

* test

* benchmark

* eval updates

* improve search performance

* remove data

* formatting

* add None type to config

* update sanitization

* push version

* maketrans update

* mypy
2024-09-26 16:12:38 -04:00
Preston Rasmussen
794b705664
Group id fix (#152)
* node distance and group_ids fixed

* get all with no group_id passed

* push

* push

* remove comments

* mypy

* mypy ids

* please mypy

* trust

* last one
2024-09-24 15:55:30 -04:00
Preston Rasmussen
5506a01e24
In memory label propagation community detection (#136)
* WIP

* in memory graph detection

* format

* add comments

* update readme

* fixed an issue where solo nodes would throw an error when building communities
2024-09-23 11:05:44 -04:00
Preston Rasmussen
e398f95612
Mentions reranker (#124)
* documentation update

* update communities

* mentions reranker

* fix episode edge mentions

* get episode mentions

* add communities to mentions endpoint

* rebase

* defaults episodes to empty list

* update
2024-09-18 15:44:28 -04:00
Preston Rasmussen
a18b3179ee
Add community update (#121)
* documentation update

* update communities

* update runner

* make format

* mypy

* oops

* add update_communities
2024-09-18 11:37:34 -04:00
Preston Rasmussen
d7c20c1f59
Search refactor + Community search (#111)
* WIP

* WIP

* WIP

* community search

* WIP

* WIP

* integration tested

* tests

* tests

* mypy

* mypy

* format
2024-09-16 14:03:05 -04:00
Preston Rasmussen
85cf8e5840
Improve node distance reranker speed (#107)
* much faster

* clean up code

* variable rename
2024-09-12 11:23:45 -04:00
Preston Rasmussen
c0a740ff60
Community nodes (#103)
* add gds

* community work

* save progress

* community updates

* e2e communities

* troubleshooting

* updates

* communities

* remove unused import
2024-09-11 12:06:35 -04:00
Preston Rasmussen
42fb590606
Add group ids (#89)
* set and retrieve group ids

* update add episode with group id support

* add episode and search functional

* update bulk

* mypy updates

* remove unused imports

* update unit tests

* unit tests

* add optional uuid field

* format

* mypy

* ellipsis
2024-09-06 12:33:42 -04:00
Preston Rasmussen
299021173b
Add episode refactor (#85)
* temp commit while moving

* fix name embedding bug

* invalidation

* format

* tests on runner examples

* format

* ellipsis

* ruff

* fix

* format

* minor prompt change
2024-09-05 12:05:44 -04:00
Preston Rasmussen
e56a599a72
search update (#81)
* search update

* update string literals
2024-09-04 10:05:45 -04:00
Preston Rasmussen
e9e6039b1e
Speed up add episode (#77)
* WIP

* updates

* use uuid for node dedupe

* pret-testing

* parallelized node resolution

* working add_episode

* revert to 4o

* format

* mypy update

* update types
2024-09-03 13:25:52 -04:00
Daniel Chalef
77685b063c
Feat/langgraph-example (#73)
* wip

* wip

* image + clean run

* chore: Update LANGCHAIN_TRACING_V2 to 'false' in agent.ipynb

* chore: Remove unused import in runner.ipynb

* lock file
2024-09-01 12:31:08 -07:00
Daniel Chalef
2d0705fc1b
Add get_nodes_by_query method to Graphiti class (#49)
* Add get_nodes_by_query method to Graphiti class

Add a method to the Graphiti class that wraps `get_relevant_nodes` and returns a list of nodes given a query.

* Add `get_nodes_by_query` method to the `Graphiti` class in `graphiti_core/graphiti.py`.
* Import `generate_embedding` from `graphiti_core/llm_client/utils.py`.
* Use `generate_embedding` to generate an embedding for the query.
* Call `get_relevant_nodes` with the generated embedding and return the relevant nodes.

Add an embedding function to `llm_client/utils.py`.

* Add `generate_embedding` function to `graphiti_core/llm_client/utils.py`.
* Accept an embedder and model_id as parameters.
* Generate an embedding for the given text and return it.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/getzep/graphiti?shareId=XXXX-XXXX-XXXX-XXXX).

* address comments left by @danielchalef on #49 (Add get_nodes_by_query method to Graphiti class);

* fix ellipsis name in cla config

* feat: Add get_nodes_by_query method to Graphiti class

* chore: Cleanup unused files, add hybrid node search, add tests

---------

Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
Co-authored-by: paulpaliychuk <pavlo.paliychuk.ca@gmail.com>
2024-08-26 20:00:28 -07:00
Daniel Chalef
895afc7be1
implement diskcache (#39)
* chore: Add romeo runner

* fix: Linter

* wip

* wip dump

* chore: Update romeo parser

* chore: Anthropic model fix

* wip

* allbirds

* allbirds runner

* format

* wip

* wip

* mypy updates

* update

* remove r

* update tests

* format

* wip

* chore: Strategically update the message

* rebase and fix import issues

* Update package imports for graphiti_core in examples and utils

* nits

* chore: Update OpenAI GPT-4o model to gpt-4o-2024-08-06

* implement groq

* improvments & linting

* cleanup and nits

* Refactor package imports for graphiti_core in examples and utils

* Refactor package imports for graphiti_core in examples and utils

* implement diskcache

* remove debug stuff

* log cache hit when debugging only

* Improve LLM config. Fix bugs (#41)

Refactor LLMConfig class to allow None values for model and base_url

* chore: Resolve mc

---------

Co-authored-by: paulpaliychuk <pavlo.paliychuk.ca@gmail.com>
Co-authored-by: prestonrasmussen <prasmuss15@gmail.com>
2024-08-26 13:13:05 -04:00
Pavlo Paliychuk
0ed7739bc0
Controlled example (#37)
* chore: Add romeo runner

* fix: Linter

* dedupe fixes

* wip

* wip dump

* allbirds

* chore: Update romeo parser

* chore: Anthropic model fix

* allbirds runner

* format

* wip

* mypy updates

* update

* remove r

* update tests

* format

* wip

* wip

* wip

* chore: Strategically update the message

* chore: Add romeo runner

* fix: Linter

* wip

* wip dump

* chore: Update romeo parser

* chore: Anthropic model fix

* wip

* allbirds

* allbirds runner

* format

* wip

* wip

* mypy updates

* update

* remove r

* update tests

* format

* wip

* chore: Strategically update the message

* rebase and fix import issues

* Update package imports for graphiti_core in examples and utils

* nits

* chore: Update OpenAI GPT-4o model to gpt-4o-2024-08-06

* implement groq

* improvments & linting

* cleanup and nits

* Refactor package imports for graphiti_core in examples and utils

* Refactor package imports for graphiti_core in examples and utils

* chore: Nuke unused examples

* chore: Nuke unused examples

* chore: Only run type check on graphiti_core

* fix unit tests

* reformat

* unit test

* fix: Unit tests

* test: Add coverage for extract_date_strings_from_edge

* lint

* remove commented code

---------

Co-authored-by: prestonrasmussen <prasmuss15@gmail.com>
Co-authored-by: Daniel Chalef <131175+danielchalef@users.noreply.github.com>
2024-08-26 10:30:22 -04:00
Daniel Chalef
c5e52153c4
chore: Fix packaging (#38)
* feat: Update project name and description

The project name and description in the `pyproject.toml` file have been updated to reflect the changes made to the project.

* chore: Update pyproject.toml to include core package

The `pyproject.toml` file has been updated to include the `core` package in the list of packages. This change ensures that the `core` package is included when building the project.

* fix imports

* fix importats
2024-08-25 10:07:50 -07:00
Daniel Chalef
6d52be49f4
Add Apache License 2.0 boilerplate to all Python files (#30)
* Add Apache License 2.0 boilerplate to all Python files

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/getzep/graphiti?shareId=XXXX-XXXX-XXXX-XXXX).

* format

* format

* chore: Add Ellipsis configuration file
2024-08-23 16:01:33 -04:00
Pavlo Paliychuk
605219f8c7
feat: Add real world dates extraction (#26)
* feat: Add real world dates extraction

* fix: Linter

* fix: 💄 mypy errors

* chore: handle invalid dates returned by the llm

* chore: Polish prompt

* reformat

* style: 💄 reformat
2024-08-23 14:18:45 -04:00
Preston Rasmussen
a1e54881a2
improve deduping issue (#28)
* improve deduping issue

* fix comment

* commit format

* default embeddings

* update
2024-08-23 12:17:15 -04:00
Preston Rasmussen
7152a211ae
fix constraints (#25) 2024-08-22 19:10:18 -04:00
Daniel Chalef
73ec0146ff
ruff action (#17)
* ruff action

* chore: Update Python version to 3.10 in lint.yml workflow

* fix lint and formatting

* cleanup
2024-08-22 13:06:42 -07:00
Daniel Chalef
50da9d0f31
format and linting (#18)
* Makefile and format

* fix podcast stuff

* refactor: update import statement for transcript_parser in podcast_runner.py

* format and linting

* chore: Update import statements and remove unused code in maintenance module
2024-08-22 12:26:13 -07:00
Daniel Chalef
8141a783b1
move podcast to examples (#15) 2024-08-22 11:13:41 -07:00