Skip to content

Commit 9cb9acf

Browse files
Remove "words" key from DQA output (#1040)
cc @Wauplin - this matches `transformers` because `transformers` never outputs a `words` key. I'll make another PR to `transformers` to remove the key from the docstrings as well.
1 parent f51b2e3 commit 9cb9acf

File tree

2 files changed

+1
-12
lines changed

2 files changed

+1
-12
lines changed

packages/tasks/src/tasks/document-question-answering/inference.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -102,9 +102,5 @@ export interface DocumentQuestionAnsweringOutputElement {
102102
* boxes).
103103
*/
104104
start: number;
105-
/**
106-
* The index of each word/box pair that is in the answer
107-
*/
108-
words: number[];
109105
[property: string]: unknown;
110106
}

packages/tasks/src/tasks/document-question-answering/spec/output.json

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,15 +22,8 @@
2222
"end": {
2323
"type": "integer",
2424
"description": "The end word index of the answer (in the OCR\u2019d version of the input or provided word boxes)."
25-
},
26-
"words": {
27-
"type": "array",
28-
"items": {
29-
"type": "integer"
30-
},
31-
"description": "The index of each word/box pair that is in the answer"
3225
}
3326
},
34-
"required": ["answer", "score", "start", "end", "words"]
27+
"required": ["answer", "score", "start", "end"]
3528
}
3629
}

0 commit comments

Comments
 (0)