Inspiration
As Network Attached Storage transitions from passive archival into intelligent, compute-capable hubs, shared multi-user environments face a critical challenge: untracked file changes, mid-process write collisions, and metadata fragmentation. In creative studios and collaborative households, multiple users or automated tasks frequently access the same asset volumes simultaneously. Existing network tools either rely on invasive cloud uploads—compromising data privacy—or lack cross-agent coordination.
We were inspired by the raw local compute capability of the flagship UGREEN AI NAS (such as the iDX6011 Pro with an Intel Core Ultra 7 SoC delivering up to $96\text{ TOPS}$ of heterogeneous AI compute). We asked: Can we build an autonomous, zero-cloud data sentinel that guards folder concurrency, validates file integrity, enriches multi-modal media with local AI models, and compiles tamper-aware lineage dossiers right at the edge?
What it does
edge-lineage-sentinel is an offline-first Uliya Skill designed for UGOS Pro that transforms shared NAS directories into audited, collision-free storage vaults through a 5-phase pipeline:
- Concurrency Lease Protection: Implements an active directory lease guard (
.sentinel-lease/) with ownership timestamps and a 3,600-second staleness override to prevent competing sessions from corrupting active jobs. - Change-Detection Baseline: Recursively traverses directories via
file-agent, cataloging assets into Images, Documents, and Unsupported types while constructing deterministic metadata fingerprints: $$\text{Fingerprint} = \text{size_bytes} \parallel \text{mtime_utc} \parallel \text{extension}$$ - Multi-Modal AI Inspection:
- Images (
photo-agent): Extracts complete EXIF camera, lens, exposure, and GPS telemetry; applies a standardized $1\text{–}10$ local Vision-Language Model (vision-vlm) scoring rubric across Sharpness, Exposure, Composition, and Subject Clarity; and extracts optical text via on-deviceOCR. - Documents (
document-agent): Parses contracts and records for entities, dates, and currency amounts, running localized translation where needed.
- Images (
- Structured Lineage Reporting (
knowledge-agent): Persists a human-readable, fully traceable audit document (.sentinel-dossier.md) linking every insight directly back to the original relative NAS file path. - Zero-Trust Safety & Cleanup: Strictly gates all filesystem writes behind interactive UGOS Gateway authorization prompts and guarantees lease deletion upon job conclusion.
How we built it
We designed and built the entire project under the official Uliya Skill Development Standard:
- Pure Markdown Orchestration: Orchestrated system agents entirely through declarative Markdown workflows in
SKILL.mdwithout invoking prohibited bash scripts or unverified binaries. - Agent Delegation Matrix: Mapped low-level primitives across
ug-filesystem(stat,ls,cat,mkdir,echo,del),ug-photo(meta,vision-vlm,OCR),ug-document(extract,translate), andug-knowledge(save-text). - Memoryless State Context: Solved the platform challenge of isolated agent runtimes by serializing intermediate tables and state tokens directly through structured Markdown context blocks.
- Automated Test Harness: Built a 22-test automated validation harness simulating concurrency collisions, corrupted media streams, permission denials, and ZIP archive packaging constraints.
Challenges we ran into
- Cryptographic Checksum Exposure: While
ug-filemgr scan-dedupeinternally utilizes file hashing,ug-filesystemdoes not currently expose a direct per-file CLI hashing primitive (likesha256sum). Rather than pretending to perform cryptographic verification, we engineered an honest "degraded mode" using composite metadata fingerprints and explicitly documented genuine SHA-256 validation as a Round 2 hardware target. - Directory Lock Atomicity: UGOS documentation does not contractually confirm create-only POSIX atomicity on
mkdir. We addressed this by designing a dual-tier lease protocol that checksstat, creates.sentinel-lease/, stampssession.mdwith a unique session ID, and validates ownership before scanning. - Partial Batch Fault Tolerance: In media folders containing corrupted or truncated images, single inference crashes could abort an entire job. We implemented fault-tolerant recovery where individual asset failures are logged to an Anomaly Register while allowing remaining assets to process uninterrupted.
Accomplishments that we're proud of
- 100% Platform Compliance: Passed all 22 static and functional simulation tests with zero warnings or errors.
- True Edge Privacy: Completely eliminated cloud telemetry - all document parsing, OCR, and vision ratings execute locally on UGOS Pro.
- Traceable Data Lineage: Every extracted entity and quality rating in the final dossier preserves an unbroken link to its source file path.
- Rigorous Budget Adherence: Structured the official proposal to exactly 447 substantive English words (below the 500-word ceiling) and a compact 27 KB submission package.
What we learned
Developing for Uliya demonstrated the power of declarative, agentic LLM orchestration over traditional imperative scripting. We gained deep insights into designing zero-trust safety gates where the user retains absolute veto power over local mutations, and how local NPU/GPU hardware acceleration can replace third-party SaaS vision APIs on consumer premises.
What's next for edge-lineage-sentinel
During Round 2 remote testing on the physical UGREEN AI NAS iDX6011 Pro:
- Benchmark real-world inference latencies of the Intel Arc 140T GPU and onboard NPU when scoring batches of 48MP RAW photos ($\text{target } < 450\text{ ms/image}$).
- Probe hardware-level
mkdiratomicity under microsecond race conditions. - Test native SHA-256 hardware acceleration hooks within UGOS storage drivers.
- Implement automated album tagging for low-quality or corrupted files via
photo-agentcreate-album.