Merge pull request 'fix(arguments): route "חשב טיעונים" through the legal-analyst agent' (#326) from worktree-fix-aggregate-btn into main
This commit was merged in pull request #326.
This commit is contained in:
@@ -71,12 +71,30 @@ export function useLegalArguments(caseNumber: string | undefined) {
|
||||
});
|
||||
}
|
||||
|
||||
export type AggregateArgumentsResult = {
|
||||
status: "started" | string;
|
||||
case_number: string;
|
||||
force: boolean;
|
||||
message: string;
|
||||
};
|
||||
/**
|
||||
* The aggregation runs on the legal-analyst agent (host-side, where the
|
||||
* `claude` CLI lives) — NOT inline in the FastAPI container. The endpoint
|
||||
* either delegates via a Paperclip wakeup (`queued`) or short-circuits on a
|
||||
* cheap in-container DB pre-check (`no_claims` / `exists`). `skipped` means
|
||||
* no analyst route was available; the chair can run the MCP tool manually.
|
||||
*/
|
||||
export type AggregateArgumentsResult =
|
||||
| {
|
||||
status: "queued";
|
||||
sub_issue_id: string;
|
||||
analyst_id: string;
|
||||
main_issue_id: string;
|
||||
}
|
||||
| {
|
||||
status: "no_claims" | "exists";
|
||||
total: number;
|
||||
message: string;
|
||||
}
|
||||
| {
|
||||
status: "skipped";
|
||||
reason: "no_api_key" | "no_analyst" | "no_issue" | string;
|
||||
company_id?: string;
|
||||
};
|
||||
|
||||
export function useAggregateArguments(caseNumber: string | undefined) {
|
||||
const qc = useQueryClient();
|
||||
|
||||
Reference in New Issue
Block a user