Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion graphrag/index/utils/hashing.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from typing import Any


def gen_sha512_hash(item: dict[str, Any], hashcode: Iterable[str]):
def gen_sha512_hash(item: dict[str, Any], hashcode: Iterable[str]) -> str:
"""Generate a SHA512 hash."""
hashed = "".join([str(item[column]) for column in hashcode])
return f"{sha512(hashed.encode('utf-8'), usedforsecurity=False).hexdigest()}"