a6a78cca8b
Phase correlation 運鏡分析 (camera_motion.rs): - ffmpeg pipe 抽幀 → 灰階 256x256 → rustfft 相位相關估 pan/tilt - 徑向功率譜估 zoom、極座標相位相關估 rotation - 中位數去噪 + none/low/high 分級 - samples_for_level: none=1, low=2, high=4 pHash 去重 (frame_dedup.rs): - 64-bit pHash (DCT 低頻) + hamming<=8 + 時間間隔去重 - scene extract 後對 jpg 去重: 387 → 317 (移除 70) 三層取樣 (scene_vlm.rs process_interval): - L0 moment=10s 保底 (SCENE_VLM_MOMENT_SEC) - L1 每個 cut 保底 1 張 (不設上限) - L2 運鏡依 level 增採, 運動路徑均勻取樣 + blurdetect 資料結構: - SceneFrame.camera_motion + selection_reason CameraMotion*/CutBaseline - VLM truncated (finish_reason=length) salvage 部分 JSON summary 其他: - face dedup 改用 per-library output dir - max_tokens 2048→4096 - config 5 項 (moment_sec/camera_motion_enabled/phash_hamming/time_gap/k) - Cargo.toml +image/ndarray/rustfft 驗證: 17e230cc force re-run → Selected 387 frames, CAM-MOTION 分析執行, pHash dedup 387→317, RESUME force=true carried over 0
193 lines
3.6 KiB
TOML
193 lines
3.6 KiB
TOML
[package]
|
|
name = "momentry_core"
|
|
version = "1.3.5"
|
|
edition = "2021"
|
|
authors = ["Momentry Team"]
|
|
description = "Digital asset management system with video analysis and RAG"
|
|
|
|
[dependencies]
|
|
sysinfo = "0.30"
|
|
# Core
|
|
anyhow = "1.0"
|
|
thiserror = "1.0"
|
|
tokio = { version = "1", features = ["full"] }
|
|
tracing = "0.1"
|
|
dirs = "5.0"
|
|
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
|
|
once_cell = "1.19"
|
|
libc = "0.2"
|
|
dotenv = "0.15"
|
|
|
|
# Image processing (camera motion + pHash dedup)
|
|
image = "0.25"
|
|
ndarray = "0.16"
|
|
rustfft = "6"
|
|
|
|
# CLI
|
|
clap = { version = "4", features = ["derive"] }
|
|
|
|
# Async
|
|
async-trait = "0.1"
|
|
futures-util = "0.3"
|
|
|
|
# Serialization
|
|
serde = { version = "1.0", features = ["derive"] }
|
|
serde_json = "1.0"
|
|
regex = "1"
|
|
chrono = { version = "0.4", features = ["serde"] }
|
|
urlencoding = "2.1"
|
|
|
|
# UUID
|
|
sha2 = "0.10"
|
|
hex = "0.4"
|
|
uuid = { version = "1.0", features = ["v4"] }
|
|
mac_address = "1.1"
|
|
|
|
# Security
|
|
subtle = "2.5"
|
|
aes-gcm = "0.10"
|
|
base64 = "0.22"
|
|
argon2 = "0.5"
|
|
jsonwebtoken = "9.3"
|
|
|
|
# Text processing
|
|
jieba-rs = "0.8.1"
|
|
ferrous-opencc = { version = "0.3.1", features = ["s2t-conversion", "t2s-conversion"] }
|
|
|
|
# Cache
|
|
moka = { version = "0.12", features = ["future"] }
|
|
|
|
# Database
|
|
redis = { version = "1.0", features = ["tokio-comp", "connection-manager"] }
|
|
sqlx = { version = "0.8", features = ["runtime-tokio", "postgres", "sqlite", "json", "chrono", "uuid"] }
|
|
mongodb = { version = "2", features = ["tokio-runtime"] }
|
|
bson = { version = "2", features = ["chrono-0_4"] }
|
|
qdrant-client = "1.7"
|
|
reqwest = { version = "0.12", features = ["json", "gzip", "zstd"] }
|
|
pgvector = { version = "0.3", features = ["sqlx"] }
|
|
|
|
# HTTP Server
|
|
axum = { version = "0.7", features = ["multipart"] }
|
|
tower = "0.4"
|
|
tower-http = { version = "0.5", features = ["cors", "fs"] }
|
|
|
|
# API Documentation
|
|
utoipa = { version = "4", features = ["axum_extras", "chrono", "uuid"] }
|
|
utoipa-swagger-ui = { version = "7", features = ["axum"] }
|
|
|
|
# File watching
|
|
notify = "6"
|
|
|
|
# Logging
|
|
env_logger = "0.11"
|
|
|
|
# Hash
|
|
md5 = "0.7"
|
|
|
|
# TUI
|
|
ratatui = "0.28"
|
|
crossterm = "0.28"
|
|
|
|
# Terminal
|
|
atty = "0.2"
|
|
tokio-util = { version = "0.7.18", features = ["io"] }
|
|
walkdir = "2.5.0"
|
|
flate2 = "1.0"
|
|
tar = "0.4"
|
|
|
|
# System
|
|
|
|
[lib]
|
|
name = "momentry_core"
|
|
path = "src/lib.rs"
|
|
|
|
[features]
|
|
default = []
|
|
player = ["sdl2"]
|
|
|
|
[dependencies.sdl2]
|
|
version = "0.35"
|
|
optional = true
|
|
|
|
[[bin]]
|
|
name = "momentry"
|
|
path = "src/main.rs"
|
|
|
|
[[bin]]
|
|
name = "momentry-cli"
|
|
path = "src/bin/cli.rs"
|
|
|
|
[[bin]]
|
|
name = "momentry_player"
|
|
path = "src/player/main.rs"
|
|
|
|
[[bin]]
|
|
name = "momentry_playground"
|
|
path = "src/playground.rs"
|
|
|
|
[[bin]]
|
|
name = "fix_chunks"
|
|
path = "src/bin/fix_chunks.rs"
|
|
|
|
[[bin]]
|
|
name = "migrate_chinese_text"
|
|
path = "src/bin/migrate_chinese_text.rs"
|
|
|
|
[[bin]]
|
|
name = "test_bm25_simple"
|
|
path = "src/bin/test_bm25_simple.rs"
|
|
|
|
[[bin]]
|
|
name = "integrated_player"
|
|
path = "src/bin/integrated_player.rs"
|
|
|
|
[[bin]]
|
|
name = "docserver"
|
|
path = "src/bin/docserver/main.rs"
|
|
|
|
[[bin]]
|
|
name = "pipeline_worker"
|
|
path = "src/bin/pipeline_worker.rs"
|
|
|
|
[[bin]]
|
|
name = "release"
|
|
path = "src/bin/release.rs"
|
|
|
|
[[bin]]
|
|
name = "vectorize_missing"
|
|
path = "src/bin/vectorize_missing.rs"
|
|
|
|
[[bin]]
|
|
name = "sync_qdrant_from_pg"
|
|
path = "src/bin/sync_qdrant_from_pg.rs"
|
|
|
|
[[bin]]
|
|
name = "service"
|
|
path = "src/bin/service.rs"
|
|
|
|
[build-dependencies]
|
|
chrono = "0.4"
|
|
|
|
[dev-dependencies]
|
|
tempfile = "3"
|
|
|
|
[[bin]]
|
|
name = "backfill_trace_profiles"
|
|
path = "src/bin/backfill_trace_profiles.rs"
|
|
|
|
[[bin]]
|
|
name = "rebuild_trace_thumbs"
|
|
path = "src/bin/rebuild_trace_thumbs.rs"
|
|
|
|
[[bin]]
|
|
name = "backfill_trace_vlm"
|
|
path = "src/bin/backfill_trace_vlm.rs"
|
|
|
|
[[bin]]
|
|
name = "rust_unregister"
|
|
path = "src/bin/rust_unregister.rs"
|
|
|
|
[[bin]]
|
|
name = "rust_register"
|
|
path = "src/bin/rust_register.rs"
|