added docs and content
Browse files- lightrag/base.py +18 -9
lightrag/base.py
CHANGED
@@ -165,15 +165,24 @@ class DocStatus(str, Enum):
|
|
165 |
@dataclass
|
166 |
class DocProcessingStatus:
|
167 |
"""Document processing status data structure"""
|
168 |
-
|
169 |
-
|
170 |
-
|
171 |
-
|
172 |
-
|
173 |
-
|
174 |
-
|
175 |
-
|
176 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
177 |
|
178 |
|
179 |
class DocStatusStorage(BaseKVStorage):
|
|
|
165 |
@dataclass
|
166 |
class DocProcessingStatus:
|
167 |
"""Document processing status data structure"""
|
168 |
+
content: str
|
169 |
+
"""Original content of the document"""
|
170 |
+
content_summary: str
|
171 |
+
"""First 100 chars of document content, used for preview"""
|
172 |
+
content_length: int
|
173 |
+
"""Total length of document"""
|
174 |
+
status: DocStatus
|
175 |
+
"""Current processing status"""
|
176 |
+
created_at: str
|
177 |
+
"""ISO format timestamp when document was created"""
|
178 |
+
updated_at: str
|
179 |
+
"""ISO format timestamp when document was last updated"""
|
180 |
+
chunks_count: Optional[int] = None
|
181 |
+
"""Number of chunks after splitting, used for processing"""
|
182 |
+
error: Optional[str] = None
|
183 |
+
"""Error message if failed"""
|
184 |
+
metadata: dict[str, Any] = field(default_factory=dict)
|
185 |
+
"""Additional metadata"""
|
186 |
|
187 |
|
188 |
class DocStatusStorage(BaseKVStorage):
|