Enhance agent workflows and tools: unify subscription and download processes, add site querying functionality, and improve error handling in download operations.

This commit is contained in:
jxxghp
2025-11-17 11:39:08 +08:00
parent a5e7483870
commit 043be409d0
9 changed files with 220 additions and 44 deletions
+2 -2
View File
@@ -17,14 +17,14 @@ class QueryMediaLibraryInput(BaseModel):
media_type: Optional[str] = Field("all",
description="Type of media content: '电影' for films, '电视剧' for television series or anime series, 'all' for all types")
title: Optional[str] = Field(None,
description="Specific media title to search for (optional, if provided returns detailed info for that specific media)")
description="Specific media title to check if it exists in the media library (optional, if provided checks for that specific media)")
year: Optional[str] = Field(None,
description="Release year of the media (optional, helps narrow down search results)")
class QueryMediaLibraryTool(MoviePilotTool):
name: str = "query_media_library"
description: str = "Query media library status and list all media files that have been successfully processed and added to the media server (Plex, Emby, Jellyfin). Shows library statistics and file details."
description: str = "Check if a specific media resource already exists in the media library (Plex, Emby, Jellyfin). Use this tool to verify whether a movie or TV series has been successfully processed and added to the media server before performing operations like downloading or subscribing."
args_schema: Type[BaseModel] = QueryMediaLibraryInput
async def run(self, media_type: Optional[str] = "all",