Spaces:
Sleeping
Sleeping
File size: 323 Bytes
1c223a0 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | from __future__ import annotations
from dataclasses import asdict, dataclass
@dataclass(frozen=True, slots=True)
class RawDocument:
doc_id: str
filename: str
extension: str
source_path: str
char_count: int
word_count: int
text: str
def to_dict(self) -> dict:
return asdict(self)
|