Files
2025-08-30 12:48:35 +00:00

29 lines
965 B
Go

package processor
import (
"github.com/bitmagnet-io/bitmagnet/internal/classifier"
"github.com/bitmagnet-io/bitmagnet/internal/protocol"
)
type ClassifyMode int
const (
// ClassifyModeDefault will use any pre-existing content match as a hint
// This is the most common use case and will only attempt to match previously unmatched torrents
ClassifyModeDefault ClassifyMode = iota
// ClassifyModeRematch will ignore any pre-existing classification and always classify from scratch
// This is useful if there are errors in matches from an earlier version that need to be corrected
ClassifyModeRematch
)
type ClassifierParams struct {
ClassifyMode ClassifyMode `json:"ClassifyMode,omitempty"`
ClassifierWorkflow classifier.Workflow `json:"ClassifierWorkflow,omitempty"`
ClassifierFlags classifier.Flags `json:"ClassifierFlags,omitempty"`
}
type MessageParams struct {
ClassifierParams
InfoHashes []protocol.ID `json:"InfoHashes"`
}