<commit_before># stdlib
from typing import Any

# third party
from sqlalchemy import Column
from sqlalchemy import Float
from sqlalchemy import LargeBinary
from sqlalchemy import String
from sqlalchemy import Integer
from sqlalchemy import ForeignKey

# syft absolute
from syft import deserialize
from syft import serialize

# relative
from . import Base


class Ledger(Base):
    __tablename__ = "ledger"

    id = Column(Integer(), primary_key=True, autoincrement=True)
    entity_name = Column(String(256), ForeignKey("entity.name"))
    mechanism_id = Column(Integer(), ForeignKey("mechanism.id"))<commit_msg>ADD foreign keys at ledger table<commit_after># stdlib
from typing import Any

# third party
from sqlalchemy import Column
from sqlalchemy import Float
from sqlalchemy import LargeBinary
from sqlalchemy import String
from sqlalchemy import Integer
from sqlalchemy import ForeignKey

# syft absolute
from syft import deserialize
from syft import serialize

# relative
from . import Base


class Ledger(Base):
    __tablename__ = "ledger"

    id = Column(Integer(), primary_key=True, autoincrement=True)
    entity_name = Column(String(256), ForeignKey("entity.name",  ondelete="CASCADE"))
    mechanism_id = Column(Integer(), ForeignKey("mechanism.id",  ondelete="CASCADE"))
{'fraction_non_alphanumeric': 0.07614607614607614, 'fraction_numerical': 0.004662004662004662, 'mean_word_length': 5.639175257731959, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1085969', 'n_tokens_mistral': 389, 'n_tokens_neox': 370, 'n_words': 126}