diff --git a/README.md b/README.md index 4fb3f57..fa11c17 100644 --- a/README.md +++ b/README.md @@ -76,10 +76,10 @@ Oder manuell: ```bash # .txz von Gitea laden -curl -O http://192.168.1.2:4000/michael/MUA-Mikes-Unraid-Agent/raw/branch/main/dist/mua-2026.08.24.r020-x86_64-1.txz +curl -O http://192.168.1.2:4000/michael/MUA-Mikes-Unraid-Agent/raw/branch/main/dist/mua-2026.08.24.r021-x86_64-1.txz # Installieren -upgradepkg --install-new mua-2026.08.24.r020-x86_64-1.txz +upgradepkg --install-new mua-2026.08.24.r021-x86_64-1.txz ``` ### 2. Service starten @@ -94,7 +94,7 @@ Der Service startet automatisch bei jedem Boot (SysVinit). ```bash curl http://192.168.1.2:3002/health -# → {"status":"ok","version":"2026.08.24.r020","auth":"required"} +# → {"status":"ok","version":"2026.08.24.r021","auth":"required"} ``` --- diff --git a/dist/mua-2026.08.24.r021-x86_64-1.txz b/dist/mua-2026.08.24.r021-x86_64-1.txz new file mode 100644 index 0000000..3666571 Binary files /dev/null and b/dist/mua-2026.08.24.r021-x86_64-1.txz differ diff --git a/package.json b/package.json index dd47e85..72c96fe 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "mua", - "version": "2026.08.24.r020", + "version": "2026.08.24.r021", "description": "Mikes Unraid Agent - MCP over HTTP (Streamable HTTP) for Unraid", "type": "module", "main": "src/index.ts", diff --git a/plugin/mua.plg b/plugin/mua.plg index 163c994..6e6a556 100644 --- a/plugin/mua.plg +++ b/plugin/mua.plg @@ -2,13 +2,13 @@ - + - - + + ]> +### 2026.08.24.r021 +- Die gefilterte Sammlungssuche beendet den Abstieg an einem passenden Verzeichnis. Episodenordner fluten dadurch nicht mehr das begrenzte Erkennungsergebnis. +- Der zweite Aufruf auf den gefundenen Sammlungspfad bleibt unverändert und liefert die vollständige gebündelte Bestandsaufnahme. + ### 2026.08.24.r020 - Neues begrenztes Nur-Lese-Werkzeug `unraid_files_inventory` erfasst Datei- und Ordnernamen eines Shares in einem Aufruf, ohne Dateiinhalte zu lesen. - Ein Namensfilter findet gezielt Sammlungsordner; ein zweiter gebündelter Aufruf inventarisiert den exakten Treffer. Medienprüfungen benötigen keine Kette aus wiederholten `ls`/`find`-Aufrufen mehr. @@ -136,7 +140,7 @@ Das .txz enthält: install/doinst.sh (läuft nach Installation) =========================================== --> - + &txzURL; &txzSHA256; diff --git a/scripts/unraid-mcp-status-helper.php b/scripts/unraid-mcp-status-helper.php index 7fb37ef..1c5dbca 100644 --- a/scripts/unraid-mcp-status-helper.php +++ b/scripts/unraid-mcp-status-helper.php @@ -307,7 +307,13 @@ function files_inventory( break 2; } } - if ($is_dir) $queue[] = [$full, $relative, $depth + 1]; + // A filtered discovery call is meant to locate collection roots. + // Once a directory itself matches, return that root but do not also + // flood the bounded result with matching descendants. A follow-up + // call with this path and an empty filter inventories the collection. + if ($is_dir && !($needle !== '' && $matches)) { + $queue[] = [$full, $relative, $depth + 1]; + } } } diff --git a/src/helpers.ts b/src/helpers.ts index afabf74..7c180dd 100644 --- a/src/helpers.ts +++ b/src/helpers.ts @@ -14,7 +14,7 @@ import { createHash, randomUUID } from "node:crypto"; // ── Konstanten ────────────────────────────────────────────────────────── export const MUA_SERVER_NAME = "mua"; -export const MUA_VERSION = "2026.08.24.r020"; +export const MUA_VERSION = "2026.08.24.r021"; export const MUA_PROTOCOL_VERSION = "2025-03-26"; export const PHP_HELPER = "/usr/local/bin/unraid-docker-mcp-helper.php"; export const STATUS_HELPER = "/usr/local/bin/unraid-mcp-status-helper.php"; diff --git a/src/tools.ts b/src/tools.ts index e645a43..48d0841 100644 --- a/src/tools.ts +++ b/src/tools.ts @@ -542,7 +542,7 @@ export const TOOLS: ToolDef[] = [ properties: { share: str("Exact Unraid share name, for example Audiobooks"), relative_path: str("Optional path below the share; never use /mnt/user or an absolute path"), - name_contains: str("Optional case-insensitive basename fragment, for example 'drei'. It filters returned entries; use a second call on a matched directory to list its descendants"), + name_contains: str("Optional case-insensitive basename fragment, for example 'drei'. A matching directory is returned as a collection root and pruned from further discovery; use a second call on that directory with an empty filter to list its descendants"), max_depth: int("Maximum directory depth below relative_path (1-20, default 10)"), max_entries: int("Maximum returned entries (1-5000, default 2000)"), include_files: { type: "boolean", description: "Include files (default true)" },