The Rust backend of YU AI Manager — an on-device WebUI for managing AI-generated image metadata.
This repository exists so the server can be read and reviewed on its own,
separately from the application it serves. Nothing here is new: every file is
already published inside eauesque/yu_ai_manager. Development happens in a
private repository and is mirrored here.
A single Cargo workspace under crates/:
| Crate | What it does |
|---|---|
yu-server |
The HTTP server binary: routes, auth, MCP, analysis engines |
auth-core |
Shared authentication primitives |
tagdb-core |
Tag database access and migrations |
scan-core |
Filesystem scanning |
meta-extract |
Metadata extraction (A1111, NovelAI, ComfyUI) |
xmp-core |
XMP packet read/merge/write for JPEG, PNG and WebP |
yu-infer-shim |
Emits a yu-infer binary beside yu-server; the sidecar it stands in for lives in yu-hailo-infer |
Two crates that used to live here are now their own repositories and are pinned by git revision:
- yu-lan-cowork — LAN peer discovery, pairing, transport, fleet operations
- yu-hailo-infer — the Hailo inference sidecar
Both pins point at the public repositories on purpose, so a fresh clone or a CI runner resolves them with no credentials and no registry setup.
Nothing outside crates/ is needed to build or test this workspace. That is
worth stating because it was not always true, and because the two ways of
breaking it fail differently:
- At compile time.
include_str!used to reach up toconfig/andextensions/at the repository root. Cargo's dependency graph never seesinclude_str!, so a tree whosecargo metadataresolves cleanly could still fail to compile once those files were missing. Those reads are now done at runtime from the project root instead. - At test time.
meta-extract's conformance test used to climb two directories up to read its goldens and image fixtures. Compiling and evencargo checksucceeded; onlycargo testin an extracted tree failed. The goldens and fixtures now live undercrates/meta-extract/tests/.
The upstream repository gates the first with a check over include_str! /
include_bytes! paths. The second is not something a static check catches — the
only way to settle it is to build and test the tree somewhere else, which is
what the mirror sync does before publishing.
cd crates
cargo build --release -p yu-servercrates/.cargo/config.toml pins jobs = 1: this workspace is also built on a
Raspberry Pi 5, where parallel compilation crashes the machine. Remove it or
override CARGO_BUILD_JOBS on a larger host.
yu-server is a backend, not a self-contained application. At startup it
resolves a project root and reads the UI, templates and extensions from it:
<project root>/ui/default/templates
<project root>/ui/default/static
<project root>/extensions
Point it at a YU AI Manager checkout. Without one the server starts but has nothing to serve.
Measured on the extracted tree, not on the upstream checkout:
cargo clippy --workspace --all-targets -- -D warningspasses with no warnings.cargo test --workspaceruns 1361 passing tests and 5 failing ones. All five invoke the Python implementation to check cross-language agreement — the prompt-engine golden outputs, the encrypted-secret format, the YOLO stream config reader, and the ComfyUI model-registry guard. They shell out to files underextensions/inyu_ai_manager, which is not part of this repository. They are not failures of the Rust code; they are comparisons with no counterpart present. CI therefore runscargo check,cargo fmt --checkand clippy.
MIT. See LICENSE.