Skip to content

Commit 4f60692

Browse files
timgreinpquentinl-trotta
committed
Add rerank task type specification (#4488)
Co-authored-by: Quentin Pradet <[email protected]> Co-authored-by: Laura Trotta <[email protected]> (cherry picked from commit 7c4997b)
1 parent 1af6007 commit 4f60692

File tree

2 files changed

+52
-39
lines changed

2 files changed

+52
-39
lines changed

output/schema/schema.json

Lines changed: 38 additions & 38 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

specification/inference/_types/CommonTypes.ts

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -771,13 +771,26 @@ export class EisServiceSettings {
771771
}
772772

773773
export enum EisTaskType {
774-
chat_completion
774+
chat_completion,
775+
rerank
775776
}
776777

777778
export enum EisServiceType {
778779
elastic
779780
}
780781

782+
export class EisTaskSettings {
783+
/**
784+
* For a `rerank` task, return doc text within the results.
785+
*/
786+
return_documents?: boolean
787+
788+
/**
789+
* For a `rerank` task, the number of the top N documents that should be returned.
790+
*/
791+
top_n?: integer
792+
}
793+
781794
export class ElasticsearchServiceSettings {
782795
/**
783796
* Adaptive allocations configuration details.

0 commit comments

Comments
 (0)