vidspotai-shared 1.0.69-dev.0 → 1.0.69
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/globals/aiModels/enums.d.ts +6 -63
- package/lib/globals/aiModels/enums.d.ts.map +1 -1
- package/lib/globals/aiModels/enums.js +9 -78
- package/lib/globals/aiModels/index.d.ts +30 -2
- package/lib/globals/aiModels/index.d.ts.map +1 -1
- package/lib/globals/aiModels/index.js +35 -7
- package/lib/globals/aiModels/providers/bytedance.d.ts.map +1 -1
- package/lib/globals/aiModels/providers/bytedance.js +0 -19
- package/lib/globals/aiModels/providers/google.d.ts.map +1 -1
- package/lib/globals/aiModels/providers/google.js +2 -150
- package/lib/globals/aiModels/providers/kling.d.ts.map +1 -1
- package/lib/globals/aiModels/providers/kling.js +37 -280
- package/lib/globals/aiModels/providers/minimax.d.ts.map +1 -1
- package/lib/globals/aiModels/providers/minimax.js +11 -76
- package/lib/globals/aiModels/providers/openai.d.ts.map +1 -1
- package/lib/globals/aiModels/providers/openai.js +6 -90
- package/lib/globals/aiModels/providers/pixverse.d.ts.map +1 -1
- package/lib/globals/aiModels/providers/pixverse.js +29 -111
- package/lib/globals/aiModels/providers/runway.d.ts.map +1 -1
- package/lib/globals/aiModels/providers/runway.js +2 -64
- package/lib/globals/aiModels/types.d.ts +1 -20
- package/lib/globals/aiModels/types.d.ts.map +1 -1
- package/lib/globals/ttsModels/index.d.ts +0 -2
- package/lib/globals/ttsModels/index.d.ts.map +1 -1
- package/lib/globals/ttsModels/index.js +1 -9
- package/lib/globals/ttsModels/types.d.ts +1 -1
- package/lib/globals/ttsModels/types.d.ts.map +1 -1
- package/lib/globals/ttsModels/voices.d.ts +4 -39
- package/lib/globals/ttsModels/voices.d.ts.map +1 -1
- package/lib/globals/ttsModels/voices.js +26 -273
- package/lib/globals/types.d.ts +1 -59
- package/lib/globals/types.d.ts.map +1 -1
- package/lib/globals/types.js +2 -81
- package/lib/index.d.ts +0 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +0 -1
- package/lib/models/index.d.ts +0 -6
- package/lib/models/index.d.ts.map +1 -1
- package/lib/models/index.js +0 -6
- package/lib/models/user.model.d.ts +1 -12
- package/lib/models/user.model.d.ts.map +1 -1
- package/lib/models/video.model.d.ts +8 -120
- package/lib/models/video.model.d.ts.map +1 -1
- package/lib/models/video.model.js +0 -10
- package/lib/services/aiGen/aiGenFactory.service.d.ts +1 -21
- package/lib/services/aiGen/aiGenFactory.service.d.ts.map +1 -1
- package/lib/services/aiGen/aiGenFactory.service.js +21 -84
- package/lib/services/aiGen/helpers.d.ts.map +1 -1
- package/lib/services/aiGen/helpers.js +0 -10
- package/lib/services/aiGen/providers/alibaba/alibaba.d.ts +3 -14
- package/lib/services/aiGen/providers/alibaba/alibaba.d.ts.map +1 -1
- package/lib/services/aiGen/providers/alibaba/alibaba.js +22 -155
- package/lib/services/aiGen/providers/azure/azure.service.d.ts +14 -0
- package/lib/services/aiGen/providers/azure/azure.service.d.ts.map +1 -0
- package/lib/services/aiGen/providers/azure/azure.service.js +108 -0
- package/lib/services/aiGen/providers/azure/index.d.ts +2 -0
- package/lib/services/aiGen/providers/azure/index.d.ts.map +1 -0
- package/lib/services/aiGen/providers/{pexels → azure}/index.js +1 -1
- package/lib/services/aiGen/providers/baseAiGenProvider.service.d.ts +4 -22
- package/lib/services/aiGen/providers/baseAiGenProvider.service.d.ts.map +1 -1
- package/lib/services/aiGen/providers/baseAiGenProvider.service.js +0 -32
- package/lib/services/aiGen/providers/bytedance/bytedance.service.d.ts.map +1 -1
- package/lib/services/aiGen/providers/bytedance/bytedance.service.js +25 -13
- package/lib/services/aiGen/providers/google/google.service.d.ts +2 -11
- package/lib/services/aiGen/providers/google/google.service.d.ts.map +1 -1
- package/lib/services/aiGen/providers/google/google.service.js +28 -245
- package/lib/services/aiGen/providers/index.d.ts +0 -3
- package/lib/services/aiGen/providers/index.d.ts.map +1 -1
- package/lib/services/aiGen/providers/index.js +0 -3
- package/lib/services/aiGen/providers/kling/index.d.ts +0 -1
- package/lib/services/aiGen/providers/kling/index.d.ts.map +1 -1
- package/lib/services/aiGen/providers/kling/index.js +0 -1
- package/lib/services/aiGen/providers/kling/kling.service.d.ts +1 -12
- package/lib/services/aiGen/providers/kling/kling.service.d.ts.map +1 -1
- package/lib/services/aiGen/providers/kling/kling.service.js +26 -357
- package/lib/services/aiGen/providers/kling/types.d.ts +0 -105
- package/lib/services/aiGen/providers/kling/types.d.ts.map +1 -1
- package/lib/services/aiGen/providers/minimax/minimax.service.d.ts +2 -15
- package/lib/services/aiGen/providers/minimax/minimax.service.d.ts.map +1 -1
- package/lib/services/aiGen/providers/minimax/minimax.service.js +5 -128
- package/lib/services/aiGen/providers/minimax/types.d.ts +1 -10
- package/lib/services/aiGen/providers/minimax/types.d.ts.map +1 -1
- package/lib/services/aiGen/providers/openai/openai.service.d.ts +2 -8
- package/lib/services/aiGen/providers/openai/openai.service.d.ts.map +1 -1
- package/lib/services/aiGen/providers/openai/openai.service.js +7 -184
- package/lib/services/aiGen/providers/pixverse/pixverse.service.d.ts.map +1 -1
- package/lib/services/aiGen/providers/pixverse/pixverse.service.js +2 -125
- package/lib/services/aiGen/providers/runway/runway.service.d.ts +2 -12
- package/lib/services/aiGen/providers/runway/runway.service.d.ts.map +1 -1
- package/lib/services/aiGen/providers/runway/runway.service.js +21 -224
- package/lib/services/aiGen/providers/types.d.ts +6 -263
- package/lib/services/aiGen/providers/types.d.ts.map +1 -1
- package/lib/services/analytics.service.js +4 -2
- package/lib/services/bullmq.service.d.ts +1 -6
- package/lib/services/bullmq.service.d.ts.map +1 -1
- package/lib/services/bullmq.service.js +14 -62
- package/lib/services/credit.service.d.ts.map +1 -1
- package/lib/services/credit.service.js +7 -45
- package/lib/services/firestore.service.d.ts +0 -17
- package/lib/services/firestore.service.d.ts.map +1 -1
- package/lib/services/firestore.service.js +0 -30
- package/lib/services/gcp/index.d.ts +0 -1
- package/lib/services/gcp/index.d.ts.map +1 -1
- package/lib/services/gcp/index.js +0 -1
- package/lib/services/index.d.ts +0 -13
- package/lib/services/index.d.ts.map +1 -1
- package/lib/services/index.js +0 -13
- package/lib/services/redis.service.d.ts +0 -9
- package/lib/services/redis.service.d.ts.map +1 -1
- package/lib/services/redis.service.js +11 -20
- package/lib/services/tts/index.d.ts +0 -2
- package/lib/services/tts/index.d.ts.map +1 -1
- package/lib/services/tts/index.js +0 -2
- package/lib/services/tts/providers/elevenlabs.service.d.ts.map +1 -1
- package/lib/services/tts/providers/elevenlabs.service.js +24 -91
- package/lib/services/tts/ttsFactory.service.d.ts.map +1 -1
- package/lib/services/tts/ttsFactory.service.js +0 -6
- package/lib/services/tts/types.d.ts +0 -33
- package/lib/services/tts/types.d.ts.map +1 -1
- package/lib/utils/errors.d.ts +0 -8
- package/lib/utils/errors.d.ts.map +1 -1
- package/lib/utils/errors.js +0 -8
- package/lib/utils/helpers.d.ts +0 -13
- package/lib/utils/helpers.d.ts.map +1 -1
- package/lib/utils/helpers.js +11 -48
- package/lib/utils/logger.d.ts.map +1 -1
- package/lib/utils/logger.js +1 -37
- package/package.json +1 -5
- package/lib/globals/aiModels/providers/alibaba.d.ts +0 -4
- package/lib/globals/aiModels/providers/alibaba.d.ts.map +0 -1
- package/lib/globals/aiModels/providers/alibaba.js +0 -194
- package/lib/globals/aiModels/providers/elevenlabs.d.ts +0 -14
- package/lib/globals/aiModels/providers/elevenlabs.d.ts.map +0 -1
- package/lib/globals/aiModels/providers/elevenlabs.js +0 -29
- package/lib/globals/aiModels/providers/pixverseTemplates.d.ts +0 -36
- package/lib/globals/aiModels/providers/pixverseTemplates.d.ts.map +0 -1
- package/lib/globals/aiModels/providers/pixverseTemplates.js +0 -42
- package/lib/globals/aiModels/tierHelpers.d.ts +0 -33
- package/lib/globals/aiModels/tierHelpers.d.ts.map +0 -1
- package/lib/globals/aiModels/tierHelpers.js +0 -109
- package/lib/globals/ttsModels/providers/minimax.d.ts +0 -8
- package/lib/globals/ttsModels/providers/minimax.d.ts.map +0 -1
- package/lib/globals/ttsModels/providers/minimax.js +0 -18
- package/lib/globals/ttsModels/providers/openai.d.ts +0 -12
- package/lib/globals/ttsModels/providers/openai.d.ts.map +0 -1
- package/lib/globals/ttsModels/providers/openai.js +0 -22
- package/lib/models/agent.model.d.ts +0 -357
- package/lib/models/agent.model.d.ts.map +0 -1
- package/lib/models/agent.model.js +0 -21
- package/lib/models/cachedAsset.model.d.ts +0 -18
- package/lib/models/cachedAsset.model.d.ts.map +0 -1
- package/lib/models/cachedAsset.model.js +0 -2
- package/lib/models/cachedRawAsset.model.d.ts +0 -20
- package/lib/models/cachedRawAsset.model.d.ts.map +0 -1
- package/lib/models/cachedRawAsset.model.js +0 -2
- package/lib/models/image.model.d.ts +0 -47
- package/lib/models/image.model.d.ts.map +0 -1
- package/lib/models/image.model.js +0 -2
- package/lib/models/notification.model.d.ts +0 -25
- package/lib/models/notification.model.d.ts.map +0 -1
- package/lib/models/notification.model.js +0 -2
- package/lib/models/ref.model.d.ts +0 -80
- package/lib/models/ref.model.d.ts.map +0 -1
- package/lib/models/ref.model.js +0 -13
- package/lib/models/share.model.d.ts +0 -29
- package/lib/models/share.model.d.ts.map +0 -1
- package/lib/models/share.model.js +0 -2
- package/lib/schemas/agentPersona.schema.d.ts +0 -10
- package/lib/schemas/agentPersona.schema.d.ts.map +0 -1
- package/lib/schemas/agentPersona.schema.js +0 -11
- package/lib/schemas/agentRunJob.schema.d.ts +0 -105
- package/lib/schemas/agentRunJob.schema.d.ts.map +0 -1
- package/lib/schemas/agentRunJob.schema.js +0 -88
- package/lib/schemas/brandKit.schema.d.ts +0 -113
- package/lib/schemas/brandKit.schema.d.ts.map +0 -1
- package/lib/schemas/brandKit.schema.js +0 -46
- package/lib/schemas/brief.schema.d.ts +0 -263
- package/lib/schemas/brief.schema.d.ts.map +0 -1
- package/lib/schemas/brief.schema.js +0 -157
- package/lib/schemas/index.d.ts +0 -7
- package/lib/schemas/index.d.ts.map +0 -1
- package/lib/schemas/index.js +0 -22
- package/lib/schemas/project.schema.d.ts +0 -1025
- package/lib/schemas/project.schema.d.ts.map +0 -1
- package/lib/schemas/project.schema.js +0 -256
- package/lib/schemas/videoPlan.schema.d.ts +0 -590
- package/lib/schemas/videoPlan.schema.d.ts.map +0 -1
- package/lib/schemas/videoPlan.schema.js +0 -412
- package/lib/services/agent/beatSnap.d.ts +0 -10
- package/lib/services/agent/beatSnap.d.ts.map +0 -1
- package/lib/services/agent/beatSnap.js +0 -128
- package/lib/services/agent/bibleBuilder.d.ts +0 -43
- package/lib/services/agent/bibleBuilder.d.ts.map +0 -1
- package/lib/services/agent/bibleBuilder.js +0 -102
- package/lib/services/agent/bibleImageVision.d.ts +0 -45
- package/lib/services/agent/bibleImageVision.d.ts.map +0 -1
- package/lib/services/agent/bibleImageVision.js +0 -169
- package/lib/services/agent/chatAgent.d.ts +0 -79
- package/lib/services/agent/chatAgent.d.ts.map +0 -1
- package/lib/services/agent/chatAgent.js +0 -136
- package/lib/services/agent/costPreflight.d.ts +0 -61
- package/lib/services/agent/costPreflight.d.ts.map +0 -1
- package/lib/services/agent/costPreflight.js +0 -143
- package/lib/services/agent/critic.d.ts +0 -103
- package/lib/services/agent/critic.d.ts.map +0 -1
- package/lib/services/agent/critic.js +0 -139
- package/lib/services/agent/editClassifier.d.ts +0 -262
- package/lib/services/agent/editClassifier.d.ts.map +0 -1
- package/lib/services/agent/editClassifier.js +0 -186
- package/lib/services/agent/eval/index.d.ts +0 -5
- package/lib/services/agent/eval/index.d.ts.map +0 -1
- package/lib/services/agent/eval/index.js +0 -20
- package/lib/services/agent/eval/judge.d.ts +0 -14
- package/lib/services/agent/eval/judge.d.ts.map +0 -1
- package/lib/services/agent/eval/judge.js +0 -96
- package/lib/services/agent/eval/recorder.d.ts +0 -28
- package/lib/services/agent/eval/recorder.d.ts.map +0 -1
- package/lib/services/agent/eval/recorder.js +0 -100
- package/lib/services/agent/eval/seedBriefs.d.ts +0 -16
- package/lib/services/agent/eval/seedBriefs.d.ts.map +0 -1
- package/lib/services/agent/eval/seedBriefs.js +0 -1188
- package/lib/services/agent/eval/types.d.ts +0 -230
- package/lib/services/agent/eval/types.d.ts.map +0 -1
- package/lib/services/agent/eval/types.js +0 -73
- package/lib/services/agent/executor.d.ts +0 -141
- package/lib/services/agent/executor.d.ts.map +0 -1
- package/lib/services/agent/executor.js +0 -561
- package/lib/services/agent/globalActions.d.ts +0 -49
- package/lib/services/agent/globalActions.d.ts.map +0 -1
- package/lib/services/agent/globalActions.js +0 -328
- package/lib/services/agent/index.d.ts +0 -38
- package/lib/services/agent/index.d.ts.map +0 -1
- package/lib/services/agent/index.js +0 -53
- package/lib/services/agent/llmCaller.d.ts +0 -144
- package/lib/services/agent/llmCaller.d.ts.map +0 -1
- package/lib/services/agent/llmCaller.js +0 -16
- package/lib/services/agent/llmCallerAnthropic.d.ts +0 -90
- package/lib/services/agent/llmCallerAnthropic.d.ts.map +0 -1
- package/lib/services/agent/llmCallerAnthropic.js +0 -255
- package/lib/services/agent/llmCallerGateway.d.ts +0 -61
- package/lib/services/agent/llmCallerGateway.d.ts.map +0 -1
- package/lib/services/agent/llmCallerGateway.js +0 -360
- package/lib/services/agent/llmCallerRegistry.d.ts +0 -6
- package/lib/services/agent/llmCallerRegistry.d.ts.map +0 -1
- package/lib/services/agent/llmCallerRegistry.js +0 -39
- package/lib/services/agent/modelQualityNotes.d.ts +0 -100
- package/lib/services/agent/modelQualityNotes.d.ts.map +0 -1
- package/lib/services/agent/modelQualityNotes.js +0 -248
- package/lib/services/agent/modelRouter.d.ts +0 -41
- package/lib/services/agent/modelRouter.d.ts.map +0 -1
- package/lib/services/agent/modelRouter.js +0 -65
- package/lib/services/agent/musicSelect.d.ts +0 -23
- package/lib/services/agent/musicSelect.d.ts.map +0 -1
- package/lib/services/agent/musicSelect.js +0 -109
- package/lib/services/agent/overlayRenderer.d.ts +0 -67
- package/lib/services/agent/overlayRenderer.d.ts.map +0 -1
- package/lib/services/agent/overlayRenderer.js +0 -253
- package/lib/services/agent/perSceneCritic.d.ts +0 -90
- package/lib/services/agent/perSceneCritic.d.ts.map +0 -1
- package/lib/services/agent/perSceneCritic.js +0 -125
- package/lib/services/agent/personas.d.ts +0 -78
- package/lib/services/agent/personas.d.ts.map +0 -1
- package/lib/services/agent/personas.js +0 -177
- package/lib/services/agent/planDiff.d.ts +0 -76
- package/lib/services/agent/planDiff.d.ts.map +0 -1
- package/lib/services/agent/planDiff.js +0 -182
- package/lib/services/agent/planMutations.d.ts +0 -46
- package/lib/services/agent/planMutations.d.ts.map +0 -1
- package/lib/services/agent/planMutations.js +0 -120
- package/lib/services/agent/planner/Planner.d.ts +0 -107
- package/lib/services/agent/planner/Planner.d.ts.map +0 -1
- package/lib/services/agent/planner/Planner.js +0 -591
- package/lib/services/agent/planner/overlaySanity.d.ts +0 -7
- package/lib/services/agent/planner/overlaySanity.d.ts.map +0 -1
- package/lib/services/agent/planner/overlaySanity.js +0 -86
- package/lib/services/agent/planner/promptSections.d.ts +0 -25
- package/lib/services/agent/planner/promptSections.d.ts.map +0 -1
- package/lib/services/agent/planner/promptSections.js +0 -174
- package/lib/services/agent/planner/repair.d.ts +0 -16
- package/lib/services/agent/planner/repair.d.ts.map +0 -1
- package/lib/services/agent/planner/repair.js +0 -51
- package/lib/services/agent/planner/structuralRules.d.ts +0 -10
- package/lib/services/agent/planner/structuralRules.d.ts.map +0 -1
- package/lib/services/agent/planner/structuralRules.js +0 -111
- package/lib/services/agent/planner/validators.d.ts +0 -65
- package/lib/services/agent/planner/validators.d.ts.map +0 -1
- package/lib/services/agent/planner/validators.js +0 -284
- package/lib/services/agent/planner.d.ts +0 -3
- package/lib/services/agent/planner.d.ts.map +0 -1
- package/lib/services/agent/planner.js +0 -14
- package/lib/services/agent/providerFallback/chains.d.ts +0 -100
- package/lib/services/agent/providerFallback/chains.d.ts.map +0 -1
- package/lib/services/agent/providerFallback/chains.js +0 -198
- package/lib/services/agent/providerFallback/classifier.d.ts +0 -36
- package/lib/services/agent/providerFallback/classifier.d.ts.map +0 -1
- package/lib/services/agent/providerFallback/classifier.js +0 -103
- package/lib/services/agent/providerFallback/index.d.ts +0 -4
- package/lib/services/agent/providerFallback/index.d.ts.map +0 -1
- package/lib/services/agent/providerFallback/index.js +0 -19
- package/lib/services/agent/providerFallback/withFallback.d.ts +0 -60
- package/lib/services/agent/providerFallback/withFallback.d.ts.map +0 -1
- package/lib/services/agent/providerFallback/withFallback.js +0 -93
- package/lib/services/agent/providerTaskCache.d.ts +0 -50
- package/lib/services/agent/providerTaskCache.d.ts.map +0 -1
- package/lib/services/agent/providerTaskCache.js +0 -98
- package/lib/services/agent/qualityGate.d.ts +0 -82
- package/lib/services/agent/qualityGate.d.ts.map +0 -1
- package/lib/services/agent/qualityGate.js +0 -232
- package/lib/services/agent/referenceImageRenderer.d.ts +0 -37
- package/lib/services/agent/referenceImageRenderer.d.ts.map +0 -1
- package/lib/services/agent/referenceImageRenderer.js +0 -92
- package/lib/services/agent/regenCore.d.ts +0 -60
- package/lib/services/agent/regenCore.d.ts.map +0 -1
- package/lib/services/agent/regenCore.js +0 -487
- package/lib/services/agent/runHelpers.d.ts +0 -44
- package/lib/services/agent/runHelpers.d.ts.map +0 -1
- package/lib/services/agent/runHelpers.js +0 -196
- package/lib/services/agent/sceneLayoutVision.d.ts +0 -90
- package/lib/services/agent/sceneLayoutVision.d.ts.map +0 -1
- package/lib/services/agent/sceneLayoutVision.js +0 -212
- package/lib/services/agent/stitchedVideoCritic.d.ts +0 -136
- package/lib/services/agent/stitchedVideoCritic.d.ts.map +0 -1
- package/lib/services/agent/stitchedVideoCritic.gemini.d.ts +0 -26
- package/lib/services/agent/stitchedVideoCritic.gemini.d.ts.map +0 -1
- package/lib/services/agent/stitchedVideoCritic.gemini.js +0 -198
- package/lib/services/agent/stitchedVideoCritic.js +0 -162
- package/lib/services/agent/taskPoller.d.ts +0 -65
- package/lib/services/agent/taskPoller.d.ts.map +0 -1
- package/lib/services/agent/taskPoller.js +0 -176
- package/lib/services/agent/textOverlayStyles.d.ts +0 -60
- package/lib/services/agent/textOverlayStyles.d.ts.map +0 -1
- package/lib/services/agent/textOverlayStyles.js +0 -174
- package/lib/services/agent/toolRegistry.d.ts +0 -73
- package/lib/services/agent/toolRegistry.d.ts.map +0 -1
- package/lib/services/agent/toolRegistry.js +0 -95
- package/lib/services/agent/tools/analyzeReference.tool.d.ts +0 -36
- package/lib/services/agent/tools/analyzeReference.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/analyzeReference.tool.js +0 -44
- package/lib/services/agent/tools/animateImage.tool.d.ts +0 -24
- package/lib/services/agent/tools/animateImage.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/animateImage.tool.js +0 -115
- package/lib/services/agent/tools/animateImageWithMotionBrush.tool.d.ts +0 -32
- package/lib/services/agent/tools/animateImageWithMotionBrush.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/animateImageWithMotionBrush.tool.js +0 -135
- package/lib/services/agent/tools/composeScene.tool.d.ts +0 -978
- package/lib/services/agent/tools/composeScene.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/composeScene.tool.js +0 -90
- package/lib/services/agent/tools/estimateCost.tool.d.ts +0 -352
- package/lib/services/agent/tools/estimateCost.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/estimateCost.tool.js +0 -62
- package/lib/services/agent/tools/generateAvatarVideo.tool.d.ts +0 -32
- package/lib/services/agent/tools/generateAvatarVideo.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/generateAvatarVideo.tool.js +0 -143
- package/lib/services/agent/tools/generateCaptions.tool.d.ts +0 -42
- package/lib/services/agent/tools/generateCaptions.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/generateCaptions.tool.js +0 -196
- package/lib/services/agent/tools/generateImage.tool.d.ts +0 -74
- package/lib/services/agent/tools/generateImage.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/generateImage.tool.js +0 -206
- package/lib/services/agent/tools/generateVideo.tool.d.ts +0 -31
- package/lib/services/agent/tools/generateVideo.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/generateVideo.tool.js +0 -153
- package/lib/services/agent/tools/generateVoiceover.tool.d.ts +0 -44
- package/lib/services/agent/tools/generateVoiceover.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/generateVoiceover.tool.js +0 -206
- package/lib/services/agent/tools/index.d.ts +0 -20
- package/lib/services/agent/tools/index.d.ts.map +0 -1
- package/lib/services/agent/tools/index.js +0 -35
- package/lib/services/agent/tools/planVideo.tool.d.ts +0 -343
- package/lib/services/agent/tools/planVideo.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/planVideo.tool.js +0 -46
- package/lib/services/agent/tools/render.tool.d.ts +0 -367
- package/lib/services/agent/tools/render.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/render.tool.js +0 -48
- package/lib/services/agent/tools/searchMusic.tool.d.ts +0 -49
- package/lib/services/agent/tools/searchMusic.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/searchMusic.tool.js +0 -74
- package/lib/services/agent/tools/searchStock.tool.d.ts +0 -41
- package/lib/services/agent/tools/searchStock.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/searchStock.tool.js +0 -314
- package/lib/services/agent/tools/searchUserLibrary.tool.d.ts +0 -59
- package/lib/services/agent/tools/searchUserLibrary.tool.d.ts.map +0 -1
- package/lib/services/agent/tools/searchUserLibrary.tool.js +0 -58
- package/lib/services/agent/ttsDuration.d.ts +0 -29
- package/lib/services/agent/ttsDuration.d.ts.map +0 -1
- package/lib/services/agent/ttsDuration.js +0 -60
- package/lib/services/aiGen/canonicalAdapters/cameraControl.types.d.ts +0 -31
- package/lib/services/aiGen/canonicalAdapters/cameraControl.types.d.ts.map +0 -1
- package/lib/services/aiGen/canonicalAdapters/cameraControl.types.js +0 -2
- package/lib/services/aiGen/canonicalAdapters/index.d.ts +0 -3
- package/lib/services/aiGen/canonicalAdapters/index.d.ts.map +0 -1
- package/lib/services/aiGen/canonicalAdapters/index.js +0 -18
- package/lib/services/aiGen/canonicalAdapters/multiShot.types.d.ts +0 -23
- package/lib/services/aiGen/canonicalAdapters/multiShot.types.d.ts.map +0 -1
- package/lib/services/aiGen/canonicalAdapters/multiShot.types.js +0 -12
- package/lib/services/aiGen/providers/elevenlabs/elevenlabs.service.d.ts +0 -18
- package/lib/services/aiGen/providers/elevenlabs/elevenlabs.service.d.ts.map +0 -1
- package/lib/services/aiGen/providers/elevenlabs/elevenlabs.service.js +0 -102
- package/lib/services/aiGen/providers/fal/falImage.service.d.ts +0 -15
- package/lib/services/aiGen/providers/fal/falImage.service.d.ts.map +0 -1
- package/lib/services/aiGen/providers/fal/falImage.service.js +0 -141
- package/lib/services/aiGen/providers/fal/index.d.ts +0 -2
- package/lib/services/aiGen/providers/fal/index.d.ts.map +0 -1
- package/lib/services/aiGen/providers/fal/index.js +0 -17
- package/lib/services/aiGen/providers/kling/cameraAdapter.d.ts +0 -4
- package/lib/services/aiGen/providers/kling/cameraAdapter.d.ts.map +0 -1
- package/lib/services/aiGen/providers/kling/cameraAdapter.js +0 -53
- package/lib/services/aiGen/providers/kling/klingImage.service.d.ts +0 -21
- package/lib/services/aiGen/providers/kling/klingImage.service.d.ts.map +0 -1
- package/lib/services/aiGen/providers/kling/klingImage.service.js +0 -208
- package/lib/services/aiGen/providers/pexels/index.d.ts +0 -2
- package/lib/services/aiGen/providers/pexels/index.d.ts.map +0 -1
- package/lib/services/aiGen/providers/pexels/pexels.service.d.ts +0 -11
- package/lib/services/aiGen/providers/pexels/pexels.service.d.ts.map +0 -1
- package/lib/services/aiGen/providers/pexels/pexels.service.js +0 -150
- package/lib/services/aiGen/providers/pixabay/index.d.ts +0 -2
- package/lib/services/aiGen/providers/pixabay/index.d.ts.map +0 -1
- package/lib/services/aiGen/providers/pixabay/index.js +0 -17
- package/lib/services/aiGen/providers/pixabay/pixabay.service.d.ts +0 -12
- package/lib/services/aiGen/providers/pixabay/pixabay.service.d.ts.map +0 -1
- package/lib/services/aiGen/providers/pixabay/pixabay.service.js +0 -156
- package/lib/services/aiGen/providers/runway/cameraAdapter.d.ts +0 -3
- package/lib/services/aiGen/providers/runway/cameraAdapter.d.ts.map +0 -1
- package/lib/services/aiGen/providers/runway/cameraAdapter.js +0 -46
- package/lib/services/aiGen/providers/unsplash/index.d.ts +0 -2
- package/lib/services/aiGen/providers/unsplash/index.d.ts.map +0 -1
- package/lib/services/aiGen/providers/unsplash/index.js +0 -17
- package/lib/services/aiGen/providers/unsplash/unsplash.service.d.ts +0 -16
- package/lib/services/aiGen/providers/unsplash/unsplash.service.d.ts.map +0 -1
- package/lib/services/aiGen/providers/unsplash/unsplash.service.js +0 -131
- package/lib/services/apiUsageCounter.service.d.ts +0 -20
- package/lib/services/apiUsageCounter.service.d.ts.map +0 -1
- package/lib/services/apiUsageCounter.service.js +0 -84
- package/lib/services/asr/assemblyai.service.d.ts +0 -72
- package/lib/services/asr/assemblyai.service.d.ts.map +0 -1
- package/lib/services/asr/assemblyai.service.js +0 -89
- package/lib/services/asr/index.d.ts +0 -3
- package/lib/services/asr/index.d.ts.map +0 -1
- package/lib/services/asr/index.js +0 -18
- package/lib/services/asr/whisper.service.d.ts +0 -18
- package/lib/services/asr/whisper.service.d.ts.map +0 -1
- package/lib/services/asr/whisper.service.js +0 -151
- package/lib/services/assetCache.service.d.ts +0 -54
- package/lib/services/assetCache.service.d.ts.map +0 -1
- package/lib/services/assetCache.service.js +0 -109
- package/lib/services/audioAnalysis/index.d.ts +0 -2
- package/lib/services/audioAnalysis/index.d.ts.map +0 -1
- package/lib/services/audioAnalysis/index.js +0 -17
- package/lib/services/audioAnalysis/onsetDetection.service.d.ts +0 -50
- package/lib/services/audioAnalysis/onsetDetection.service.d.ts.map +0 -1
- package/lib/services/audioAnalysis/onsetDetection.service.js +0 -140
- package/lib/services/credits/pricing.d.ts +0 -58
- package/lib/services/credits/pricing.d.ts.map +0 -1
- package/lib/services/credits/pricing.js +0 -111
- package/lib/services/editor/designToProject.d.ts +0 -75
- package/lib/services/editor/designToProject.d.ts.map +0 -1
- package/lib/services/editor/designToProject.js +0 -295
- package/lib/services/editor/planToProject.d.ts +0 -84
- package/lib/services/editor/planToProject.d.ts.map +0 -1
- package/lib/services/editor/planToProject.js +0 -395
- package/lib/services/editor/projectToDesign.d.ts +0 -4
- package/lib/services/editor/projectToDesign.d.ts.map +0 -1
- package/lib/services/editor/projectToDesign.js +0 -186
- package/lib/services/gcp/uploadAudioBuffer.d.ts +0 -13
- package/lib/services/gcp/uploadAudioBuffer.d.ts.map +0 -1
- package/lib/services/gcp/uploadAudioBuffer.js +0 -28
- package/lib/services/musicGen/index.d.ts +0 -6
- package/lib/services/musicGen/index.d.ts.map +0 -1
- package/lib/services/musicGen/index.js +0 -26
- package/lib/services/musicGen/musicSearchFactory.service.d.ts +0 -14
- package/lib/services/musicGen/musicSearchFactory.service.d.ts.map +0 -1
- package/lib/services/musicGen/musicSearchFactory.service.js +0 -59
- package/lib/services/musicGen/providers/curated.service.d.ts +0 -24
- package/lib/services/musicGen/providers/curated.service.d.ts.map +0 -1
- package/lib/services/musicGen/providers/curated.service.js +0 -173
- package/lib/services/musicGen/providers/jamendo.service.d.ts +0 -8
- package/lib/services/musicGen/providers/jamendo.service.d.ts.map +0 -1
- package/lib/services/musicGen/providers/jamendo.service.js +0 -113
- package/lib/services/musicGen/providers/mubert.service.d.ts +0 -10
- package/lib/services/musicGen/providers/mubert.service.d.ts.map +0 -1
- package/lib/services/musicGen/providers/mubert.service.js +0 -128
- package/lib/services/musicGen/types.d.ts +0 -46
- package/lib/services/musicGen/types.d.ts.map +0 -1
- package/lib/services/musicGen/types.js +0 -10
- package/lib/services/notification.service.d.ts +0 -22
- package/lib/services/notification.service.d.ts.map +0 -1
- package/lib/services/notification.service.js +0 -76
- package/lib/services/rateLimiter/distributedRateLimiter.service.d.ts +0 -78
- package/lib/services/rateLimiter/distributedRateLimiter.service.d.ts.map +0 -1
- package/lib/services/rateLimiter/distributedRateLimiter.service.js +0 -269
- package/lib/services/rateLimiter/index.d.ts +0 -2
- package/lib/services/rateLimiter/index.d.ts.map +0 -1
- package/lib/services/rateLimiter/index.js +0 -17
- package/lib/services/redisOptions.d.ts +0 -22
- package/lib/services/redisOptions.d.ts.map +0 -1
- package/lib/services/redisOptions.js +0 -51
- package/lib/services/tts/providers/minimax.service.d.ts +0 -14
- package/lib/services/tts/providers/minimax.service.d.ts.map +0 -1
- package/lib/services/tts/providers/minimax.service.js +0 -78
- package/lib/services/tts/providers/openai.service.d.ts +0 -14
- package/lib/services/tts/providers/openai.service.d.ts.map +0 -1
- package/lib/services/tts/providers/openai.service.js +0 -73
|
@@ -1,253 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* AG-40 — overlay renderer. Turns a `TextOverlay[]` into a list of ffmpeg
|
|
4
|
-
* `drawtext` filter expressions ready to chain in a `-filter_complex` graph.
|
|
5
|
-
*
|
|
6
|
-
* Word-wrap policy:
|
|
7
|
-
* - Each role has a `maxWidthFraction` (e.g. 0.88 of frame width).
|
|
8
|
-
* - We estimate text width as `chars * fontSize * 0.55` (Arial-ish ratio).
|
|
9
|
-
* - If a line exceeds the max width, greedy word-wrap into multiple lines.
|
|
10
|
-
* - If a single word exceeds max width even alone, we shrink fontSize stepwise.
|
|
11
|
-
*
|
|
12
|
-
* Anti-emoji guard:
|
|
13
|
-
* drawtext can't render colour glyphs without libass — strip surrogate-pair
|
|
14
|
-
* emoji upfront. Was the cause of "the H is cut off" mishap in Test 1: the
|
|
15
|
-
* "🌊" wasn't rendered but its width was counted toward layout.
|
|
16
|
-
*/
|
|
17
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
-
exports.renderOverlay = renderOverlay;
|
|
19
|
-
exports.renderOverlayChain = renderOverlayChain;
|
|
20
|
-
exports.expandPersistentOverlays = expandPersistentOverlays;
|
|
21
|
-
const textOverlayStyles_1 = require("./textOverlayStyles");
|
|
22
|
-
/**
|
|
23
|
-
* Strip emojis + chars drawtext can't render. Emojis are stripped because
|
|
24
|
-
* the colour-glyph rendering needs libass, not drawtext. Other control chars
|
|
25
|
-
* get cleaned out for the same reason.
|
|
26
|
-
*/
|
|
27
|
-
function stripEmoji(s) {
|
|
28
|
-
return s
|
|
29
|
-
.replace(/[\u{1F300}-\u{1FAFF}\u{2600}-\u{27BF}\u{FE0F}\u{200D}]/gu, "")
|
|
30
|
-
.replace(/\s+/g, " ")
|
|
31
|
-
.trim();
|
|
32
|
-
}
|
|
33
|
-
/**
|
|
34
|
-
* Greedy word-wrap. Given a max char count per line, returns the text split
|
|
35
|
-
* into lines. If a single word exceeds the budget, the line gets that word
|
|
36
|
-
* alone — caller handles font shrink in that case.
|
|
37
|
-
*/
|
|
38
|
-
function wrapWords(text, maxCharsPerLine) {
|
|
39
|
-
if (maxCharsPerLine <= 0)
|
|
40
|
-
return [text];
|
|
41
|
-
const words = text.split(/\s+/).filter(Boolean);
|
|
42
|
-
const lines = [];
|
|
43
|
-
let current = "";
|
|
44
|
-
for (const w of words) {
|
|
45
|
-
if (!current) {
|
|
46
|
-
current = w;
|
|
47
|
-
continue;
|
|
48
|
-
}
|
|
49
|
-
if ((current + " " + w).length <= maxCharsPerLine) {
|
|
50
|
-
current += " " + w;
|
|
51
|
-
}
|
|
52
|
-
else {
|
|
53
|
-
lines.push(current);
|
|
54
|
-
current = w;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
if (current)
|
|
58
|
-
lines.push(current);
|
|
59
|
-
return lines;
|
|
60
|
-
}
|
|
61
|
-
/**
|
|
62
|
-
* Approximate char width relative to font size. 0.55 is a decent fit for
|
|
63
|
-
* Arial-family sans-serif at mixed case. Bolder weights are slightly wider —
|
|
64
|
-
* we bump to 0.6 for bold/black to be safe.
|
|
65
|
-
*/
|
|
66
|
-
function avgCharWidth(fontSizePx, weight) {
|
|
67
|
-
const ratio = weight === "bold" || weight === "black" ? 0.6 : 0.55;
|
|
68
|
-
return fontSizePx * ratio;
|
|
69
|
-
}
|
|
70
|
-
/**
|
|
71
|
-
* Escape a literal text string for ffmpeg drawtext filter syntax. Special chars
|
|
72
|
-
* that need escaping inside single-quoted drawtext text=: backslash, single
|
|
73
|
-
* quote, colon. Newlines stay literal "\n" in the text expression — drawtext
|
|
74
|
-
* with `text_align=center` and `\n` produces multi-line output (modern ffmpeg)
|
|
75
|
-
* or we pre-render each line as a separate drawtext with y offsets (compat).
|
|
76
|
-
*/
|
|
77
|
-
function escapeDrawtext(s) {
|
|
78
|
-
return s
|
|
79
|
-
.replace(/\\/g, "\\\\")
|
|
80
|
-
.replace(/:/g, "\\:")
|
|
81
|
-
.replace(/'/g, "\\'")
|
|
82
|
-
.replace(/%/g, "\\%");
|
|
83
|
-
}
|
|
84
|
-
/**
|
|
85
|
-
* Compute x/y ffmpeg expressions for a given position. ffmpeg drawtext
|
|
86
|
-
* accepts `x` / `y` as expressions referencing `w` (frame W), `h`, `text_w`,
|
|
87
|
-
* `text_h`.
|
|
88
|
-
*/
|
|
89
|
-
function positionExprs(position, edgePadPx) {
|
|
90
|
-
switch (position) {
|
|
91
|
-
case "top":
|
|
92
|
-
return { x: "(w-text_w)/2", y: `${edgePadPx}` };
|
|
93
|
-
case "top-left":
|
|
94
|
-
return { x: `${edgePadPx}`, y: `${edgePadPx}` };
|
|
95
|
-
case "top-right":
|
|
96
|
-
return { x: `w-text_w-${edgePadPx}`, y: `${edgePadPx}` };
|
|
97
|
-
case "center":
|
|
98
|
-
return { x: "(w-text_w)/2", y: "(h-text_h)/2" };
|
|
99
|
-
case "lower-third":
|
|
100
|
-
return { x: "(w-text_w)/2", y: "h*0.66" };
|
|
101
|
-
case "bottom":
|
|
102
|
-
return { x: "(w-text_w)/2", y: `h-text_h-${edgePadPx}` };
|
|
103
|
-
case "bottom-left":
|
|
104
|
-
return { x: `${edgePadPx}`, y: `h-text_h-${edgePadPx}` };
|
|
105
|
-
case "bottom-right":
|
|
106
|
-
return { x: `w-text_w-${edgePadPx}`, y: `h-text_h-${edgePadPx}` };
|
|
107
|
-
default:
|
|
108
|
-
return { x: "(w-text_w)/2", y: `h-text_h-${edgePadPx}` };
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
/**
|
|
112
|
-
* Convert animation kind + scene timing into ffmpeg drawtext `enable` and
|
|
113
|
-
* `alpha` expressions. Best-effort: fade and pop are supported; type/slide-up
|
|
114
|
-
* fall back to plain (drawtext can't do per-glyph typewriter without -filter_complex
|
|
115
|
-
* gymnastics).
|
|
116
|
-
*/
|
|
117
|
-
function animationExprs(_animation, startSec, endSec) {
|
|
118
|
-
// ffmpeg filter graph parser treats commas as filter separators even inside
|
|
119
|
-
// single-quoted option values when used with -vf. Multi-term expressions like
|
|
120
|
-
// `min(1,max(0,...))` were being split into "filters" by ffmpeg, producing
|
|
121
|
-
// `No such filter: '0.000'`. Quoted commas inside drawtext's `between(...)`
|
|
122
|
-
// also fail unless explicitly escaped. Escape commas with `\,` per ffmpeg
|
|
123
|
-
// filter-graph quoting rules. We keep things simple: only emit the `enable`
|
|
124
|
-
// gate (no alpha) — short overlays don't need a fade-out to look acceptable.
|
|
125
|
-
const enable = `between(t\\,${startSec.toFixed(3)}\\,${endSec.toFixed(3)})`;
|
|
126
|
-
return { enable };
|
|
127
|
-
}
|
|
128
|
-
/**
|
|
129
|
-
* Build one drawtext expression for a single overlay. Returns the expression
|
|
130
|
-
* plus debug metadata. Caller chains many of these with `,` (or splits per
|
|
131
|
-
* scene depending on its mux structure).
|
|
132
|
-
*/
|
|
133
|
-
function renderOverlay(overlay, ctx) {
|
|
134
|
-
const resolved = (0, textOverlayStyles_1.resolveOverlayStyle)(overlay);
|
|
135
|
-
// 1. Compute initial font size from frame height + max width budget in px.
|
|
136
|
-
let fontSizePx = typeof overlay.fontSize === "number"
|
|
137
|
-
? overlay.fontSize
|
|
138
|
-
: Math.round(ctx.frameHeight * resolved.fontSizeFraction);
|
|
139
|
-
const maxWidthPx = ctx.frameWidth * resolved.maxWidthFraction;
|
|
140
|
-
const edgePadPx = Math.round(Math.min(ctx.frameWidth, ctx.frameHeight) * resolved.edgePaddingFraction);
|
|
141
|
-
// 2. Clean text (strip emoji) — same content the user sees.
|
|
142
|
-
const cleanText = stripEmoji(overlay.text);
|
|
143
|
-
// 3. Wrap by char budget, auto-shrinking until widest line fits the width
|
|
144
|
-
// budget. Cap at 6 shrink passes (each -10%) so we don't infinite-loop
|
|
145
|
-
// on an absurd single word.
|
|
146
|
-
let lines = [cleanText];
|
|
147
|
-
for (let pass = 0; pass < 6; pass++) {
|
|
148
|
-
const charW = avgCharWidth(fontSizePx, resolved.weight);
|
|
149
|
-
const maxCharsPerLine = Math.max(1, Math.floor(maxWidthPx / charW));
|
|
150
|
-
lines = wrapWords(cleanText, maxCharsPerLine);
|
|
151
|
-
// Check that no single line is over-wide (an unwrappable long word).
|
|
152
|
-
const widestPx = Math.max(...lines.map((l) => l.length * charW));
|
|
153
|
-
if (widestPx <= maxWidthPx)
|
|
154
|
-
break;
|
|
155
|
-
// Shrink ~10% and retry.
|
|
156
|
-
fontSizePx = Math.max(12, Math.round(fontSizePx * 0.9));
|
|
157
|
-
}
|
|
158
|
-
// Multi-line text in drawtext requires either a real newline (which breaks
|
|
159
|
-
// -vf parsing) or a doubly-escaped backslash that survives filter-graph
|
|
160
|
-
// unescape and reaches drawtext as `\n`. The single-escape form ("\\n",
|
|
161
|
-
// 2 chars: backslash+n) gets stripped by the filter parser and drawtext
|
|
162
|
-
// renders a literal "n" glyph — that's what produced "yournwatertasten"
|
|
163
|
-
// in the Test 1 repair. Use a 4-char source escape so drawtext sees `\n`.
|
|
164
|
-
const wrapped = lines.map(escapeDrawtext).join("\\\\n");
|
|
165
|
-
const startSec = (overlay.startMs ?? 0) / 1000;
|
|
166
|
-
const endSec = (overlay.endMs ?? overlay.startMs ?? ctx.sceneDurationSec * 1000) / 1000;
|
|
167
|
-
// Default end = scene end when no endMs given.
|
|
168
|
-
const effectiveEnd = overlay.endMs !== undefined ? endSec : ctx.sceneDurationSec;
|
|
169
|
-
const effectiveStart = startSec;
|
|
170
|
-
const { x, y } = positionExprs(resolved.position, edgePadPx);
|
|
171
|
-
const anim = animationExprs(resolved.animation, effectiveStart, effectiveEnd);
|
|
172
|
-
// Compose drawtext expression. Order: fontfile, text, fontsize, fontcolor,
|
|
173
|
-
// box (if bgColor), borderw + bordercolor (stroke), x, y, enable, alpha.
|
|
174
|
-
const parts = [];
|
|
175
|
-
parts.push(`fontfile='${ctx.fontFile.replace(/'/g, "\\'")}'`);
|
|
176
|
-
// Wrap the multi-line text in single quotes for the filter; we already
|
|
177
|
-
// escaped colons + quotes + backslashes inside.
|
|
178
|
-
parts.push(`text='${wrapped}'`);
|
|
179
|
-
parts.push(`fontsize=${fontSizePx}`);
|
|
180
|
-
parts.push(`fontcolor=${resolved.color}`);
|
|
181
|
-
if (resolved.bgColor) {
|
|
182
|
-
parts.push("box=1");
|
|
183
|
-
parts.push(`boxcolor=${resolved.bgColor}@${(resolved.bgAlpha ?? 0.85).toFixed(2)}`);
|
|
184
|
-
parts.push("boxborderw=18");
|
|
185
|
-
}
|
|
186
|
-
if (resolved.strokeWidth > 0) {
|
|
187
|
-
parts.push(`borderw=${resolved.strokeWidth}`);
|
|
188
|
-
parts.push(`bordercolor=${resolved.strokeColor}`);
|
|
189
|
-
}
|
|
190
|
-
parts.push("line_spacing=12");
|
|
191
|
-
parts.push("text_align=C");
|
|
192
|
-
parts.push(`x=${x}`);
|
|
193
|
-
parts.push(`y=${y}`);
|
|
194
|
-
parts.push(`enable='${anim.enable}'`);
|
|
195
|
-
if (anim.alpha)
|
|
196
|
-
parts.push(`alpha='${anim.alpha}'`);
|
|
197
|
-
return {
|
|
198
|
-
drawtextExpr: `drawtext=${parts.join(":")}`,
|
|
199
|
-
source: overlay,
|
|
200
|
-
resolved,
|
|
201
|
-
finalFontSizePx: fontSizePx,
|
|
202
|
-
finalText: wrapped,
|
|
203
|
-
lineCount: lines.length,
|
|
204
|
-
};
|
|
205
|
-
}
|
|
206
|
-
/**
|
|
207
|
-
* Render many overlays into a single chained filter expression, joined by
|
|
208
|
-
* commas. Caller pipes it through `-vf` (single video stream) or wraps in
|
|
209
|
-
* `-filter_complex` if mixing with other filters.
|
|
210
|
-
*/
|
|
211
|
-
function renderOverlayChain(overlays, ctx) {
|
|
212
|
-
const rendered = overlays.map((o) => renderOverlay(o, ctx));
|
|
213
|
-
return {
|
|
214
|
-
vfilter: rendered.map((r) => r.drawtextExpr).join(","),
|
|
215
|
-
rendered,
|
|
216
|
-
};
|
|
217
|
-
}
|
|
218
|
-
/**
|
|
219
|
-
* AG-40: persist-across-scenes resolver. Given the per-scene overlay arrays
|
|
220
|
-
* in playback order, append any overlay flagged `persistAcrossScenes` (or with
|
|
221
|
-
* a role whose default-persist is true, like watermark) onto every subsequent
|
|
222
|
-
* scene that doesn't already have an overlay of the same role.
|
|
223
|
-
*
|
|
224
|
-
* This is what lets the planner emit a watermark exactly once (on scene 0) and
|
|
225
|
-
* have it appear on every scene — no need to repeat it scene-by-scene.
|
|
226
|
-
*/
|
|
227
|
-
function expandPersistentOverlays(perScene) {
|
|
228
|
-
const sticky = [];
|
|
229
|
-
const out = [];
|
|
230
|
-
for (const sceneOverlays of perScene) {
|
|
231
|
-
const own = sceneOverlays ?? [];
|
|
232
|
-
// Inject sticky overlays at the front, but skip any whose role this scene
|
|
233
|
-
// already has explicitly (per-scene override wins).
|
|
234
|
-
const ownRoles = new Set(own.map((o) => o.role));
|
|
235
|
-
const carried = sticky.filter((o) => !ownRoles.has(o.role));
|
|
236
|
-
const final = [...carried, ...own];
|
|
237
|
-
out.push(final);
|
|
238
|
-
// Update sticky stack with this scene's persistent overlays.
|
|
239
|
-
for (const o of own) {
|
|
240
|
-
const persist = o.persistAcrossScenes ??
|
|
241
|
-
((0, textOverlayStyles_1.resolveOverlayStyle)(o).persistAcrossScenesDefault ?? false);
|
|
242
|
-
if (persist) {
|
|
243
|
-
// Replace existing sticky of same role with the newer instance.
|
|
244
|
-
const idx = sticky.findIndex((s) => s.role === o.role);
|
|
245
|
-
if (idx >= 0)
|
|
246
|
-
sticky[idx] = o;
|
|
247
|
-
else
|
|
248
|
-
sticky.push(o);
|
|
249
|
-
}
|
|
250
|
-
}
|
|
251
|
-
}
|
|
252
|
-
return out;
|
|
253
|
-
}
|
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* AG-43: per-scene critic. Runs a lightweight Gemini Flash pass on each scene's
|
|
3
|
-
* raw MP4 *before* stitch, focused on the failure modes that show up in a
|
|
4
|
-
* single clip (action plausibility, character drift across the clip's own
|
|
5
|
-
* frames, brand label legibility, prompt adherence). The full stitched critic
|
|
6
|
-
* (stitchedVideoCritic.ts) still grades the assembled result — this is an
|
|
7
|
-
* earlier safety net so we can flag broken scenes and queue targeted re-gens
|
|
8
|
-
* via AG-41 instead of paying for a stitch + critic over already-broken assets.
|
|
9
|
-
*
|
|
10
|
-
* Cost: ~$0.0001 per scene (Gemini Flash, ~3s clip ≈ 800 input tokens). For a
|
|
11
|
-
* 5-scene plan that's ~$0.0005 total — negligible vs the $0.20-0.50 we save
|
|
12
|
-
* by re-generating one scene instead of the whole thing.
|
|
13
|
-
*/
|
|
14
|
-
import { z } from "zod";
|
|
15
|
-
export declare const PerSceneFindingSchema: z.ZodObject<{
|
|
16
|
-
severity: z.ZodEnum<{
|
|
17
|
-
fail: "fail";
|
|
18
|
-
warn: "warn";
|
|
19
|
-
pass: "pass";
|
|
20
|
-
}>;
|
|
21
|
-
dimension: z.ZodEnum<{
|
|
22
|
-
brandTextLegibility: "brandTextLegibility";
|
|
23
|
-
actionPlausibility: "actionPlausibility";
|
|
24
|
-
promptAdherence: "promptAdherence";
|
|
25
|
-
characterDrift: "characterDrift";
|
|
26
|
-
compositionQuality: "compositionQuality";
|
|
27
|
-
motionQuality: "motionQuality";
|
|
28
|
-
}>;
|
|
29
|
-
message: z.ZodString;
|
|
30
|
-
}, z.core.$strip>;
|
|
31
|
-
export type PerSceneFinding = z.infer<typeof PerSceneFindingSchema>;
|
|
32
|
-
export declare const PerSceneReviewSchema: z.ZodObject<{
|
|
33
|
-
sceneIndex: z.ZodNumber;
|
|
34
|
-
score: z.ZodNumber;
|
|
35
|
-
shippable: z.ZodBoolean;
|
|
36
|
-
summary: z.ZodString;
|
|
37
|
-
findings: z.ZodArray<z.ZodObject<{
|
|
38
|
-
severity: z.ZodEnum<{
|
|
39
|
-
fail: "fail";
|
|
40
|
-
warn: "warn";
|
|
41
|
-
pass: "pass";
|
|
42
|
-
}>;
|
|
43
|
-
dimension: z.ZodEnum<{
|
|
44
|
-
brandTextLegibility: "brandTextLegibility";
|
|
45
|
-
actionPlausibility: "actionPlausibility";
|
|
46
|
-
promptAdherence: "promptAdherence";
|
|
47
|
-
characterDrift: "characterDrift";
|
|
48
|
-
compositionQuality: "compositionQuality";
|
|
49
|
-
motionQuality: "motionQuality";
|
|
50
|
-
}>;
|
|
51
|
-
message: z.ZodString;
|
|
52
|
-
}, z.core.$strip>>;
|
|
53
|
-
recommendRegenerate: z.ZodBoolean;
|
|
54
|
-
}, z.core.$strip>;
|
|
55
|
-
export type PerSceneReview = z.infer<typeof PerSceneReviewSchema>;
|
|
56
|
-
export interface PerSceneCriticInput {
|
|
57
|
-
sceneIndex: number;
|
|
58
|
-
videoUrl: string;
|
|
59
|
-
/** Original visual prompt the model was given. */
|
|
60
|
-
prompt: string;
|
|
61
|
-
/** Optional spoken line for context (don't grade audio — there is none yet). */
|
|
62
|
-
voiceoverLine?: string;
|
|
63
|
-
/** Optional on-screen text that overlays will burn later. */
|
|
64
|
-
onScreenText?: string;
|
|
65
|
-
/** Bible entities so we know what objects/characters should be present. */
|
|
66
|
-
expectedEntities?: Array<{
|
|
67
|
-
name: string;
|
|
68
|
-
kind: "character" | "object" | "environment";
|
|
69
|
-
}>;
|
|
70
|
-
}
|
|
71
|
-
export declare function buildPerSceneCriticPrompt(input: PerSceneCriticInput): string;
|
|
72
|
-
/**
|
|
73
|
-
* Run the per-scene critic. Caller passes the same Gemini invoker the stitched
|
|
74
|
-
* critic uses; only difference is the prompt + smaller response schema.
|
|
75
|
-
*/
|
|
76
|
-
export declare function runPerSceneCritic(input: PerSceneCriticInput, invokeGemini: (args: {
|
|
77
|
-
prompt: string;
|
|
78
|
-
videoUrl: string;
|
|
79
|
-
responseSchema: z.ZodType<PerSceneReview>;
|
|
80
|
-
}) => Promise<PerSceneReview>): Promise<PerSceneReview>;
|
|
81
|
-
/**
|
|
82
|
-
* Convenience: run the per-scene critic over many scenes in parallel (capped
|
|
83
|
-
* concurrency to keep Gemini quota safe).
|
|
84
|
-
*/
|
|
85
|
-
export declare function runPerSceneCriticBatch(scenes: PerSceneCriticInput[], invokeGemini: (args: {
|
|
86
|
-
prompt: string;
|
|
87
|
-
videoUrl: string;
|
|
88
|
-
responseSchema: z.ZodType<PerSceneReview>;
|
|
89
|
-
}) => Promise<PerSceneReview>, concurrency?: number): Promise<PerSceneReview[]>;
|
|
90
|
-
//# sourceMappingURL=perSceneCritic.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"perSceneCritic.d.ts","sourceRoot":"","sources":["../../../src/services/agent/perSceneCritic.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;iBAWhC,CAAC;AACH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;iBAY/B,CAAC;AACH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAElE,MAAM,WAAW,mBAAmB;IAClC,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,kDAAkD;IAClD,MAAM,EAAE,MAAM,CAAC;IACf,gFAAgF;IAChF,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,6DAA6D;IAC7D,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,2EAA2E;IAC3E,gBAAgB,CAAC,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,WAAW,GAAG,QAAQ,GAAG,aAAa,CAAA;KAAE,CAAC,CAAC;CAC1F;AAED,wBAAgB,yBAAyB,CAAC,KAAK,EAAE,mBAAmB,GAAG,MAAM,CAgC5E;AAED;;;GAGG;AACH,wBAAsB,iBAAiB,CACrC,KAAK,EAAE,mBAAmB,EAC1B,YAAY,EAAE,CAAC,IAAI,EAAE;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,CAAC,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC;CAC3C,KAAK,OAAO,CAAC,cAAc,CAAC,GAC5B,OAAO,CAAC,cAAc,CAAC,CAuBzB;AAED;;;GAGG;AACH,wBAAsB,sBAAsB,CAC1C,MAAM,EAAE,mBAAmB,EAAE,EAC7B,YAAY,EAAE,CAAC,IAAI,EAAE;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,CAAC,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC;CAC3C,KAAK,OAAO,CAAC,cAAc,CAAC,EAC7B,WAAW,SAAI,GACd,OAAO,CAAC,cAAc,EAAE,CAAC,CAY3B"}
|
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* AG-43: per-scene critic. Runs a lightweight Gemini Flash pass on each scene's
|
|
4
|
-
* raw MP4 *before* stitch, focused on the failure modes that show up in a
|
|
5
|
-
* single clip (action plausibility, character drift across the clip's own
|
|
6
|
-
* frames, brand label legibility, prompt adherence). The full stitched critic
|
|
7
|
-
* (stitchedVideoCritic.ts) still grades the assembled result — this is an
|
|
8
|
-
* earlier safety net so we can flag broken scenes and queue targeted re-gens
|
|
9
|
-
* via AG-41 instead of paying for a stitch + critic over already-broken assets.
|
|
10
|
-
*
|
|
11
|
-
* Cost: ~$0.0001 per scene (Gemini Flash, ~3s clip ≈ 800 input tokens). For a
|
|
12
|
-
* 5-scene plan that's ~$0.0005 total — negligible vs the $0.20-0.50 we save
|
|
13
|
-
* by re-generating one scene instead of the whole thing.
|
|
14
|
-
*/
|
|
15
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.PerSceneReviewSchema = exports.PerSceneFindingSchema = void 0;
|
|
17
|
-
exports.buildPerSceneCriticPrompt = buildPerSceneCriticPrompt;
|
|
18
|
-
exports.runPerSceneCritic = runPerSceneCritic;
|
|
19
|
-
exports.runPerSceneCriticBatch = runPerSceneCriticBatch;
|
|
20
|
-
const zod_1 = require("zod");
|
|
21
|
-
const logger_1 = require("../../utils/logger");
|
|
22
|
-
exports.PerSceneFindingSchema = zod_1.z.object({
|
|
23
|
-
severity: zod_1.z.enum(["pass", "warn", "fail"]),
|
|
24
|
-
dimension: zod_1.z.enum([
|
|
25
|
-
"actionPlausibility",
|
|
26
|
-
"promptAdherence",
|
|
27
|
-
"brandTextLegibility",
|
|
28
|
-
"characterDrift",
|
|
29
|
-
"compositionQuality",
|
|
30
|
-
"motionQuality",
|
|
31
|
-
]),
|
|
32
|
-
message: zod_1.z.string().min(4),
|
|
33
|
-
});
|
|
34
|
-
exports.PerSceneReviewSchema = zod_1.z.object({
|
|
35
|
-
sceneIndex: zod_1.z.number().int().nonnegative(),
|
|
36
|
-
score: zod_1.z.number().min(0).max(10),
|
|
37
|
-
shippable: zod_1.z.boolean(),
|
|
38
|
-
summary: zod_1.z.string().min(8).max(400),
|
|
39
|
-
findings: zod_1.z.array(exports.PerSceneFindingSchema),
|
|
40
|
-
/**
|
|
41
|
-
* Critic recommends regenerating this scene if true — usually because at
|
|
42
|
-
* least one FAIL finding fired. AG-41 edit-classifier reads this to decide
|
|
43
|
-
* whether to surface a `modify-scene-visual` edit suggestion.
|
|
44
|
-
*/
|
|
45
|
-
recommendRegenerate: zod_1.z.boolean(),
|
|
46
|
-
});
|
|
47
|
-
function buildPerSceneCriticPrompt(input) {
|
|
48
|
-
const entities = input.expectedEntities?.length
|
|
49
|
-
? input.expectedEntities.map((e) => ` - ${e.kind}: ${e.name}`).join("\n")
|
|
50
|
-
: " (none specified)";
|
|
51
|
-
return [
|
|
52
|
-
"You are a per-scene QC reviewer for AI-generated short ad clips.",
|
|
53
|
-
"WATCH the attached video (silent, no audio yet — judge VISUALS only).",
|
|
54
|
-
"Grade against the spec and rubric below. Be strict — this is the pre-stitch",
|
|
55
|
-
"safety net that catches breakage worth a re-generation.",
|
|
56
|
-
"",
|
|
57
|
-
`Scene index: ${input.sceneIndex}`,
|
|
58
|
-
`Visual prompt the model was given:`,
|
|
59
|
-
` """${input.prompt}"""`,
|
|
60
|
-
input.voiceoverLine ? `Spoken line (for context — will be added later):\n """${input.voiceoverLine}"""` : "",
|
|
61
|
-
input.onScreenText ? `Planned on-screen text (will be overlaid later):\n """${input.onScreenText}"""` : "",
|
|
62
|
-
"Expected entities in the frame (from the visual bible):",
|
|
63
|
-
entities,
|
|
64
|
-
"",
|
|
65
|
-
"Rubric — score each dimension pass / warn / fail:",
|
|
66
|
-
" - actionPlausibility : every visible action must be physically possible given the state of the objects on screen. MUST flag FAIL: drinking from a sealed/capped bottle, pouring from a closed container, using a phone with a dark screen, walking through a closed door, etc. Pay attention to caps, lids, seals, buttons, doors, switches.",
|
|
67
|
-
" - promptAdherence : does the scene actually depict what the prompt asked for, or did the model drift?",
|
|
68
|
-
" - brandTextLegibility : if a product label is visible, is the brand name spelled correctly and readable?",
|
|
69
|
-
" - characterDrift : within this single scene, does the person stay the same throughout (no morphing mid-clip)?",
|
|
70
|
-
" - compositionQuality : framing, lighting, focus all professional — not amateur / blurry / mis-composed?",
|
|
71
|
-
" - motionQuality : motion feels natural — no warping limbs, melting faces, teleporting objects?",
|
|
72
|
-
"",
|
|
73
|
-
"Set recommendRegenerate=true if ANY dimension is FAIL. The orchestrator will queue a targeted re-generation",
|
|
74
|
-
"(keeping all other scenes + voice + music intact) when this is true, so be honest — a generous PASS",
|
|
75
|
-
"when you should have said FAIL costs more than a strict FAIL when you should have said WARN.",
|
|
76
|
-
"",
|
|
77
|
-
"Output JSON exactly matching the response schema.",
|
|
78
|
-
].filter(Boolean).join("\n");
|
|
79
|
-
}
|
|
80
|
-
/**
|
|
81
|
-
* Run the per-scene critic. Caller passes the same Gemini invoker the stitched
|
|
82
|
-
* critic uses; only difference is the prompt + smaller response schema.
|
|
83
|
-
*/
|
|
84
|
-
async function runPerSceneCritic(input, invokeGemini) {
|
|
85
|
-
try {
|
|
86
|
-
const prompt = buildPerSceneCriticPrompt(input);
|
|
87
|
-
const review = await invokeGemini({
|
|
88
|
-
prompt,
|
|
89
|
-
videoUrl: input.videoUrl,
|
|
90
|
-
responseSchema: exports.PerSceneReviewSchema,
|
|
91
|
-
});
|
|
92
|
-
return { ...review, sceneIndex: input.sceneIndex };
|
|
93
|
-
}
|
|
94
|
-
catch (e) {
|
|
95
|
-
const msg = e instanceof Error ? e.message : String(e);
|
|
96
|
-
logger_1.logger.warn("perSceneCritic failed; soft-fail review", { sceneIndex: input.sceneIndex, err: msg });
|
|
97
|
-
return {
|
|
98
|
-
sceneIndex: input.sceneIndex,
|
|
99
|
-
score: 0,
|
|
100
|
-
shippable: false,
|
|
101
|
-
summary: `Per-scene critic failed: ${msg}. Manual review required.`,
|
|
102
|
-
findings: [
|
|
103
|
-
{ severity: "warn", dimension: "compositionQuality", message: `Critic call failed: ${msg}` },
|
|
104
|
-
],
|
|
105
|
-
recommendRegenerate: false,
|
|
106
|
-
};
|
|
107
|
-
}
|
|
108
|
-
}
|
|
109
|
-
/**
|
|
110
|
-
* Convenience: run the per-scene critic over many scenes in parallel (capped
|
|
111
|
-
* concurrency to keep Gemini quota safe).
|
|
112
|
-
*/
|
|
113
|
-
async function runPerSceneCriticBatch(scenes, invokeGemini, concurrency = 3) {
|
|
114
|
-
const out = [];
|
|
115
|
-
let i = 0;
|
|
116
|
-
async function worker() {
|
|
117
|
-
while (i < scenes.length) {
|
|
118
|
-
const idx = i++;
|
|
119
|
-
const scene = scenes[idx];
|
|
120
|
-
out[idx] = await runPerSceneCritic(scene, invokeGemini);
|
|
121
|
-
}
|
|
122
|
-
}
|
|
123
|
-
await Promise.all(Array.from({ length: Math.min(concurrency, scenes.length) }, worker));
|
|
124
|
-
return out;
|
|
125
|
-
}
|
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
import { AgentPersona, AgentPersonaSchema } from "../../schemas/agentPersona.schema";
|
|
2
|
-
import { LlmCaller } from "./llmCaller";
|
|
3
|
-
import { ModelRouter } from "./modelRouter";
|
|
4
|
-
export type { AgentPersona };
|
|
5
|
-
export { AgentPersonaSchema };
|
|
6
|
-
/**
|
|
7
|
-
* Vertical agent personas. Each persona = curated planner system prompt
|
|
8
|
-
* + recommended tier mix + critic rubric. Router LLM picks the persona
|
|
9
|
-
* from the user's first message (single classification call, Haiku-tier).
|
|
10
|
-
*
|
|
11
|
-
* Why personas: vertical specialisation is what makes a small model and
|
|
12
|
-
* a small team feel like a domain expert. invideo / Captions both win
|
|
13
|
-
* on this. v1 ships 5; v2 adds general + niche personas.
|
|
14
|
-
*/
|
|
15
|
-
export interface PersonaPack {
|
|
16
|
-
id: AgentPersona;
|
|
17
|
-
/** Short user-facing label. */
|
|
18
|
-
label: string;
|
|
19
|
-
/** Single-sentence pitch shown in persona picker. */
|
|
20
|
-
blurb: string;
|
|
21
|
-
/** Default brief axes the persona pre-fills (used when LLM confidence is low). */
|
|
22
|
-
defaults: {
|
|
23
|
-
aspect: "16:9" | "9:16" | "1:1";
|
|
24
|
-
durationSec: number;
|
|
25
|
-
tone: string;
|
|
26
|
-
pacing: "slow" | "medium" | "fast" | "very-fast";
|
|
27
|
-
hookStyle: string;
|
|
28
|
-
tierBudget: "T0" | "T1" | "T2" | "T3";
|
|
29
|
-
};
|
|
30
|
-
/** Planner system-prompt addendum: niche-specific structural priors. */
|
|
31
|
-
plannerPrompt: string;
|
|
32
|
-
/**
|
|
33
|
-
* Default BPM for the beat-snap pass when neither the user nor the planner
|
|
34
|
-
* specifies one. Personas where steady BPM cuts feel right (recap, UGC) set
|
|
35
|
-
* a value; cinematic / educational personas leave it undefined so cuts stay
|
|
36
|
-
* free-form.
|
|
37
|
-
*/
|
|
38
|
-
defaultBpm?: number;
|
|
39
|
-
/** Critic rubric weights (override the global judge). */
|
|
40
|
-
criticEmphasis: Partial<{
|
|
41
|
-
hookStrength: number;
|
|
42
|
-
voVisualSync: number;
|
|
43
|
-
pacingFit: number;
|
|
44
|
-
brandSafety: number;
|
|
45
|
-
costVsTier: number;
|
|
46
|
-
intentMatch: number;
|
|
47
|
-
}>;
|
|
48
|
-
/**
|
|
49
|
-
* AG-30: recommended consistency tier for this persona. Used as the default
|
|
50
|
-
* when the brief leaves `consistencyTier` undefined. Character-driven
|
|
51
|
-
* personas (UGC, talking-head, product-demo with presenter) need C2 — text
|
|
52
|
-
* descriptions alone do not anchor faces tightly enough across scenes, so
|
|
53
|
-
* we end up with a different actor in every cut. Stock-driven personas
|
|
54
|
-
* (recipe B-roll, travel) stay on C1 since there's no recurring face.
|
|
55
|
-
*/
|
|
56
|
-
recommendedConsistencyTier?: "C0" | "C1" | "C2";
|
|
57
|
-
}
|
|
58
|
-
export declare const PERSONA_PACKS: Record<AgentPersona, PersonaPack>;
|
|
59
|
-
/**
|
|
60
|
-
* AG-30: resolve the consistency tier for an agent run. Brief wins when set
|
|
61
|
-
* explicitly; otherwise fall back to the persona's recommendation; otherwise
|
|
62
|
-
* the safe global default of C1. UGC / talking-head / product-demo
|
|
63
|
-
* recommend C2 because the same presenter/product needs to look identical
|
|
64
|
-
* across cuts — text descriptions alone produce a different actor every
|
|
65
|
-
* scene (Test 1 had 5 different women in 5 scenes on C1).
|
|
66
|
-
*/
|
|
67
|
-
export declare function resolveConsistencyTier(persona: AgentPersona | undefined, briefTier: "C0" | "C1" | "C2" | undefined): "C0" | "C1" | "C2";
|
|
68
|
-
export declare class PersonaRouter {
|
|
69
|
-
private readonly llm;
|
|
70
|
-
private readonly router;
|
|
71
|
-
constructor(llm: LlmCaller, router?: ModelRouter);
|
|
72
|
-
route(rawPrompt: string): Promise<{
|
|
73
|
-
persona: AgentPersona;
|
|
74
|
-
confidence: number;
|
|
75
|
-
reason: string;
|
|
76
|
-
}>;
|
|
77
|
-
}
|
|
78
|
-
//# sourceMappingURL=personas.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"personas.d.ts","sourceRoot":"","sources":["../../../src/services/agent/personas.ts"],"names":[],"mappings":"AACA,OAAO,EACL,YAAY,EACZ,kBAAkB,EACnB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAE5C,YAAY,EAAE,YAAY,EAAE,CAAC;AAC7B,OAAO,EAAE,kBAAkB,EAAE,CAAC;AAE9B;;;;;;;;GAQG;AAEH,MAAM,WAAW,WAAW;IAC1B,EAAE,EAAE,YAAY,CAAC;IACjB,+BAA+B;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,qDAAqD;IACrD,KAAK,EAAE,MAAM,CAAC;IACd,kFAAkF;IAClF,QAAQ,EAAE;QACR,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC;QAChC,WAAW,EAAE,MAAM,CAAC;QACpB,IAAI,EAAE,MAAM,CAAC;QACb,MAAM,EAAE,MAAM,GAAG,QAAQ,GAAG,MAAM,GAAG,WAAW,CAAC;QACjD,SAAS,EAAE,MAAM,CAAC;QAClB,UAAU,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;KACvC,CAAC;IACF,wEAAwE;IACxE,aAAa,EAAE,MAAM,CAAC;IACtB;;;;;OAKG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,yDAAyD;IACzD,cAAc,EAAE,OAAO,CAAC;QACtB,YAAY,EAAE,MAAM,CAAC;QACrB,YAAY,EAAE,MAAM,CAAC;QACrB,SAAS,EAAE,MAAM,CAAC;QAClB,WAAW,EAAE,MAAM,CAAC;QACpB,UAAU,EAAE,MAAM,CAAC;QACnB,WAAW,EAAE,MAAM,CAAC;KACrB,CAAC,CAAC;IACH;;;;;;;OAOG;IACH,0BAA0B,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;CACjD;AAED,eAAO,MAAM,aAAa,EAAE,MAAM,CAAC,YAAY,EAAE,WAAW,CAmH3D,CAAC;AAEF;;;;;;;GAOG;AACH,wBAAgB,sBAAsB,CACpC,OAAO,EAAE,YAAY,GAAG,SAAS,EACjC,SAAS,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,SAAS,GACxC,IAAI,GAAG,IAAI,GAAG,IAAI,CAIpB;AAQD,qBAAa,aAAa;IAEtB,OAAO,CAAC,QAAQ,CAAC,GAAG;IACpB,OAAO,CAAC,QAAQ,CAAC,MAAM;gBADN,GAAG,EAAE,SAAS,EACd,MAAM,GAAE,WAA+B;IAGpD,KAAK,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC;QACtC,OAAO,EAAE,YAAY,CAAC;QACtB,UAAU,EAAE,MAAM,CAAC;QACnB,MAAM,EAAE,MAAM,CAAC;KAChB,CAAC;CA4BH"}
|