Integrated AI summary
This commit is contained in:
@@ -65,6 +65,7 @@ type TenderResponse struct {
|
||||
Status TenderStatus `json:"status"`
|
||||
TenderID string `json:"tender_id"`
|
||||
CreatedAt int64 `json:"created_at"`
|
||||
OverallSummary string `json:"overall_summary,omitempty"` // AI-generated summary from the pipeline
|
||||
}
|
||||
|
||||
type OrganizationResponse struct {
|
||||
@@ -103,3 +104,26 @@ func (t *Tender) ToResponse() *TenderResponse {
|
||||
|
||||
return response
|
||||
}
|
||||
|
||||
// AISummaryResponse represents the response for getting an AI-generated summary
|
||||
type AISummaryResponse struct {
|
||||
NoticeID string `json:"notice_id"`
|
||||
OverallSummary string `json:"overall_summary"`
|
||||
Source string `json:"source"` // "storage" or "on_demand"
|
||||
}
|
||||
|
||||
// AISummarizeResponse represents the response for triggering on-demand AI summarization
|
||||
type AISummarizeResponse struct {
|
||||
NoticeID string `json:"notice_id"`
|
||||
Summaries []AIDocumentSummary `json:"summaries"`
|
||||
OverallSummary *string `json:"overall_summary"`
|
||||
}
|
||||
|
||||
// AIDocumentSummary represents a single document summary from the AI service
|
||||
type AIDocumentSummary struct {
|
||||
DocumentName string `json:"document_name"`
|
||||
DocumentType string `json:"document_type"`
|
||||
Summary string `json:"summary"`
|
||||
SummaryModel string `json:"summary_model"`
|
||||
Error string `json:"error,omitempty"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user