ocr

package
v0.101.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 20, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

Package ocr provides a background runner for processing attachments with OCR and text extraction.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Runner

type Runner struct {
	// contains filtered or unexported fields
}

Runner processes attachments for OCR and text extraction.

func NewRunner

func NewRunner(store *store.Store, profile *profile.Profile) *Runner

NewRunner creates a new OCR runner.

func (*Runner) ProcessAttachmentAsync

func (r *Runner) ProcessAttachmentAsync(ctx context.Context, attachmentID int32)

ProcessAttachmentAsync processes a single attachment asynchronously. This can be called when a new attachment is uploaded.

func (*Runner) Run

func (r *Runner) Run(ctx context.Context)

Run starts the background task.

func (*Runner) RunOnce

func (r *Runner) RunOnce(ctx context.Context)

RunOnce processes attachments once (for manual trigger).

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL