feat(#190): метрики качества первички (AURORA-1759) #229

Merged
aep merged 45 commits from feat/190-ocr-metrics into main 2026-11-07 07:50:00 +03:00
2 changed files with 6 additions and 5 deletions
Showing only changes of commit e14f1ab2aa - Show all commits

View File

@ -72,9 +72,7 @@ async def _outcome_fact_fields(
issues = await statements_repo.issues(session, document.id)
if document.document_type is DocumentType.OSV:
row_count = (
await session.execute(
select(func.count()).select_from(OsvEntry).where(OsvEntry.document_id == document.id)
)
await session.execute(select(func.count()).select_from(OsvEntry).where(OsvEntry.document_id == document.id))
).scalar_one()
osv_warnings = [
issue.code

View File

@ -249,8 +249,11 @@ async def _failure_dimensions_batch(
rows = await session.execute(stmt)
return {
file_id: _FailureDimensions(
legal_entity_id=legal_entity_id, legal_entity_name=legal_entity_name, group_id=group_id,
group_name=group_name, is_scan=is_scan,
legal_entity_id=legal_entity_id,
legal_entity_name=legal_entity_name,
group_id=group_id,
group_name=group_name,
is_scan=is_scan,
)
for file_id, is_scan, legal_entity_id, legal_entity_name, group_id, group_name in rows
}