104 lines
3.8 KiB
Go
104 lines
3.8 KiB
Go
package config
|
|
|
|
import "gitea.maximumdirect.net/eric/narratio/internal/artifactmodel"
|
|
|
|
// Default filesystem locations for config lookup when config path flags are
|
|
// omitted. Order is highest to lowest precedence.
|
|
const (
|
|
DefaultPipelineConfigPathUsrLocal = "/usr/local/etc/narratio/pipeline.yml"
|
|
DefaultPipelineConfigPathEtc = "/etc/narratio/pipeline.yml"
|
|
DefaultSessionConfigPathUsrLocal = "/usr/local/etc/narratio/session.yml"
|
|
DefaultSessionConfigPathEtc = "/etc/narratio/session.yml"
|
|
DefaultS3AccessKeyIDEnv = "OBJECT_STORAGE_KEY_ID"
|
|
DefaultS3SecretAccessKeyEnv = "OBJECT_STORAGE_KEY"
|
|
DefaultStorageS3RootPrefix = "dnd"
|
|
DefaultWorkspaceRoot = "/var/lib/narratio"
|
|
DefaultCampaignsRoot = "/usr/local/share/narratio/campaigns"
|
|
DefaultSpoolRoot = "/var/spool/narratio"
|
|
DefaultCacheRoot = "/var/cache/narratio"
|
|
DefaultCacheS3Audio = true
|
|
|
|
DefaultWhisperXLanguage = "en"
|
|
DefaultWhisperXTimeout = "30m"
|
|
DefaultWhisperXRetryDelay = "2s"
|
|
DefaultWhisperXConcurrency = 2
|
|
DefaultWhisperXRetries = 3
|
|
|
|
DefaultSeriatimBinary = "seriatim"
|
|
DefaultSeriatimTimeout = "10m"
|
|
DefaultSeriatimOutputSchema = "seriatim-intermediate"
|
|
DefaultSeriatimCoalesceGap = 3.0
|
|
DefaultSeriatimReport = true
|
|
|
|
DefaultAuditaBinary = "audita"
|
|
DefaultAuditaTimeout = "3h"
|
|
DefaultAuditaReport = true
|
|
|
|
DefaultScriptoriumBinary = "scriptorium"
|
|
DefaultScriptoriumTimeout = "10m"
|
|
DefaultScriptoriumArtifactOutputRoot = "artifacts"
|
|
|
|
DefaultTrimBoundsTimeout = "10m"
|
|
DefaultTrimSeriatimReport = false
|
|
|
|
DefaultNormalizeOutputPath = artifactmodel.TranscriptPathFinal
|
|
DefaultNormalizeOutputSchema = "seriatim-intermediate"
|
|
DefaultNormalizeReport = true
|
|
|
|
DefaultArchiveEnabled = true
|
|
DefaultArchiveUploadRun = true
|
|
|
|
PathWorkDirSegment = "work"
|
|
PathInputsDirSegment = "inputs"
|
|
PathAudioDirSegment = "audio"
|
|
PathTranscriptsSegment = "transcripts"
|
|
PathTranscriptsRaw = "transcripts/raw"
|
|
PathTranscriptsTrimmed = "transcripts/trimmed"
|
|
PathArtifactsDirSegment = "artifacts"
|
|
PathReportsDirSegment = "reports"
|
|
PathConfigDirSegment = "config"
|
|
PathLogsDirSegment = "logs"
|
|
PathCurrentDirSegment = "current"
|
|
PathRunsDirSegment = "runs"
|
|
PathPreviousDirSegment = "previous"
|
|
PathManifestFile = "manifest.json"
|
|
PathLockFile = ".lock"
|
|
PathTranscriptBase = artifactmodel.TranscriptPathBase
|
|
PathTranscriptPolished = artifactmodel.TranscriptPathPolished
|
|
PathTranscriptFinal = artifactmodel.TranscriptPathFinal
|
|
PathTranscriptFinalTrimmed = artifactmodel.TranscriptPathFinalTrimmed
|
|
|
|
S3CampaignsSegment = "campaigns"
|
|
S3SessionsSegment = "sessions"
|
|
S3RunsSegment = "runs"
|
|
S3CurrentSegment = "current"
|
|
S3ManifestFile = "manifest.json"
|
|
S3RunIDFile = "run_id.txt"
|
|
)
|
|
|
|
// DefaultPublishOutputs defines the default publish output rules.
|
|
// Callers should copy this slice before mutating.
|
|
var DefaultPublishOutputs = []PublishOutputRule{
|
|
{Source: artifactmodel.SourceTranscriptFinalTrimmed, Dest: PathTranscriptFinalTrimmed},
|
|
}
|
|
|
|
// DefaultPipelineConfigSearchPaths defines the default search order for
|
|
// pipeline.yml when callers do not provide an explicit path.
|
|
//
|
|
// Keep this in a variable so future defaults can be extended without changing
|
|
// call sites.
|
|
var DefaultPipelineConfigSearchPaths = []string{
|
|
DefaultPipelineConfigPathUsrLocal,
|
|
DefaultPipelineConfigPathEtc,
|
|
}
|
|
|
|
// DefaultSessionConfigSearchPaths defines the default search order for
|
|
// session.yml when callers do not provide an explicit path.
|
|
//
|
|
// Keep this in a variable so future defaults can be extended without changing
|
|
// call sites.
|
|
var DefaultSessionConfigSearchPaths = []string{
|
|
DefaultSessionConfigPathUsrLocal,
|
|
DefaultSessionConfigPathEtc,
|
|
}
|