feat(aihr): close phase two practice pilot gates
This commit is contained in:
@@ -36,6 +36,16 @@ export type SopSearchResponse = {
|
||||
snippets: SopSnippet[];
|
||||
training: string[];
|
||||
records: SopRecord[];
|
||||
keyPoints?: string[];
|
||||
cautions?: string[];
|
||||
reviewId?: number;
|
||||
};
|
||||
|
||||
export type SopReviewResponse = {
|
||||
id: number;
|
||||
usable: boolean | null;
|
||||
status: string;
|
||||
reviewedAt: string;
|
||||
};
|
||||
|
||||
export type SopUploadResponse = {
|
||||
@@ -49,7 +59,7 @@ export type SopUploadResponse = {
|
||||
snippets: SopSnippet[];
|
||||
};
|
||||
|
||||
export function searchKnowledgeSop(data: { queryText: string; category: string; limit: number }): Promise<ApiResult<SopSearchResponse>> {
|
||||
export function searchKnowledgeSop(data: { queryText: string; category: string; position?: string; source?: string; limit: number }): Promise<ApiResult<SopSearchResponse>> {
|
||||
return request({
|
||||
url: '/api/knowledge/search',
|
||||
method: 'post',
|
||||
@@ -68,6 +78,15 @@ export function uploadKnowledgeDoc(data: FormData): Promise<ApiResult<SopUploadR
|
||||
});
|
||||
}
|
||||
|
||||
export function reviewKnowledgeSop(id: number, data: { usable: boolean; reviewer?: string; note?: string }): Promise<ApiResult<SopReviewResponse>> {
|
||||
return request({
|
||||
url: `/api/knowledge/reviews/${id}`,
|
||||
method: 'post',
|
||||
data,
|
||||
headers: { repeatSubmit: false }
|
||||
});
|
||||
}
|
||||
|
||||
export type UploadEnqueueResponse = {
|
||||
itemId: number;
|
||||
batchId: string;
|
||||
|
||||
Reference in New Issue
Block a user