fix: add missing _context method to RemoteSharedAIPlatformClient

This commit is contained in:
2026-05-31 15:48:24 +08:00
parent 323e7cf572
commit 3ff384cbeb
@@ -97,6 +97,13 @@ class RemoteSharedAIPlatformClient:
api_prefix=settings.shared_ai_platform_api_prefix,
)
def _context(self, current_user: Dict[str, Any]) -> SharedAIRequestContext:
return SharedAIRequestContext(
tenant_id=current_user.get("tenant_id", ""),
user_id=current_user.get("id", ""),
user_role=current_user.get("role", "admin"),
)
def stream_answer(
self,
current_user: Dict[str, Any],