feat: add streaming unified review assistant
This commit is contained in:
+3
-1
@@ -13,6 +13,7 @@ MEMBER_GET_PATHS = frozenset(
|
||||
"/api/mentors/setup",
|
||||
"/api/mentors/messages",
|
||||
"/api/heaven/setup",
|
||||
"/api/assistant/messages",
|
||||
}
|
||||
)
|
||||
|
||||
@@ -27,6 +28,7 @@ MEMBER_POST_PATHS = frozenset(
|
||||
"/api/heaven/hexagram",
|
||||
"/api/heaven/personal",
|
||||
"/api/heaven/interpret",
|
||||
"/api/assistant/chat",
|
||||
}
|
||||
)
|
||||
|
||||
@@ -54,7 +56,7 @@ def required_role(method: str, path: str) -> AccessRole:
|
||||
if method == "DELETE":
|
||||
if re.fullmatch(r"/api/heaven/sector-phases/.+", path):
|
||||
return "admin"
|
||||
if path == "/api/mentors/messages" or re.fullmatch(
|
||||
if path in {"/api/mentors/messages", "/api/assistant/messages"} or re.fullmatch(
|
||||
r"/api/screener/strategies/\d+", path
|
||||
):
|
||||
return "member"
|
||||
|
||||
Reference in New Issue
Block a user