mirror of
https://github.com/tiennm99/litellm.git
synced 2026-08-13 14:23:04 +00:00
fix(greptile-review): address backward compatibility and code quality issues
- Remove duplicate DecodedCharacterId TypedDict from litellm/types/videos/main.py - Remove dead LITELLM_MANAGED_VIDEO_CHARACTER_COMPLETE_STR constant from litellm/types/utils.py - Add FastAPI Form validation for name field in video_create_character endpoint Made-with: Cursor
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
from typing import Any, Dict, Optional
|
||||
|
||||
import orjson
|
||||
from fastapi import APIRouter, Depends, File, Request, Response, UploadFile
|
||||
from fastapi import APIRouter, Depends, File, Form, Request, Response, UploadFile
|
||||
from fastapi.responses import ORJSONResponse
|
||||
|
||||
from litellm.proxy._types import *
|
||||
@@ -530,6 +530,7 @@ async def video_create_character(
|
||||
request: Request,
|
||||
fastapi_response: Response,
|
||||
video: UploadFile = File(...),
|
||||
name: str = Form(...),
|
||||
user_api_key_dict: UserAPIKeyAuth = Depends(user_api_key_auth),
|
||||
):
|
||||
"""
|
||||
|
||||
@@ -3493,9 +3493,6 @@ class SpecialEnums(Enum):
|
||||
LITELLM_MANAGED_VIDEO_COMPLETE_STR = (
|
||||
"litellm:custom_llm_provider:{};model_id:{};video_id:{}"
|
||||
)
|
||||
LITELLM_MANAGED_VIDEO_CHARACTER_COMPLETE_STR = (
|
||||
"litellm:custom_llm_provider:{};model_id:{};character_id:{}"
|
||||
)
|
||||
|
||||
|
||||
class ServiceTier(Enum):
|
||||
|
||||
@@ -106,14 +106,6 @@ class DecodedVideoId(TypedDict, total=False):
|
||||
video_id: str
|
||||
|
||||
|
||||
class DecodedCharacterId(TypedDict, total=False):
|
||||
"""Structure representing a decoded character ID"""
|
||||
|
||||
custom_llm_provider: Optional[str]
|
||||
model_id: Optional[str]
|
||||
character_id: str
|
||||
|
||||
|
||||
class CharacterObject(BaseModel):
|
||||
"""Represents a character created from a video."""
|
||||
|
||||
|
||||
Reference in New Issue
Block a user