chore: initial commit — existing single-user document scanner codebase
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
from abc import ABC, abstractmethod
|
||||
from dataclasses import dataclass, field
|
||||
|
||||
|
||||
@dataclass
|
||||
class ClassificationResult:
|
||||
topics: list[str] = field(default_factory=list)
|
||||
suggested_new_topics: list[str] = field(default_factory=list)
|
||||
reasoning: str = ""
|
||||
|
||||
|
||||
class AIProvider(ABC):
|
||||
@abstractmethod
|
||||
async def classify(
|
||||
self,
|
||||
document_text: str,
|
||||
existing_topics: list[str],
|
||||
system_prompt: str,
|
||||
) -> ClassificationResult:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def suggest_topics(
|
||||
self,
|
||||
document_text: str,
|
||||
system_prompt: str,
|
||||
) -> list[str]:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def health_check(self) -> bool:
|
||||
...
|
||||
Reference in New Issue
Block a user