ksvmuralidhar commited on
Commit
bb302fa
·
verified ·
1 Parent(s): 3b8363a

Update api.py

Browse files
Files changed (1) hide show
  1. api.py +2 -11
api.py CHANGED
@@ -123,9 +123,9 @@ class URLList(BaseModel):
123
  class Summary(BaseModel):
124
  urls: List[str] = Field(..., description="List of URLs of news articles inputted by the user")
125
  scraped_texts: List[str] = Field(..., description="List of scraped text from input URLs")
126
- scrape_errors: List[str] = Field("", description="List of errors raised during scraping. One item for corresponding URL")
127
  summaries: List[str] = Field(..., description="List of generated summaries of news articles")
128
- summarizer_error: str = Field("", description="String specifying error raised during summary.")
129
 
130
 
131
  class NewsSummarizerAPIAuthenticationError(Exception):
@@ -146,15 +146,6 @@ def authenticate_key(api_key: str):
146
  "schema": List[Summary]
147
  }
148
  }
149
- },
150
-
151
- 401: {
152
- "description": "Authentication Error: Wrong key",
153
- "content": {
154
- "application/json": {
155
- "schema": List[Summary]
156
- }
157
- }
158
  }
159
  })
160
  async def read_items(q: URLList):
 
123
  class Summary(BaseModel):
124
  urls: List[str] = Field(..., description="List of URLs of news articles inputted by the user")
125
  scraped_texts: List[str] = Field(..., description="List of scraped text from input URLs")
126
+ scrape_errors: List[str] = Field(..., description="List of errors raised during scraping. One item for corresponding URL")
127
  summaries: List[str] = Field(..., description="List of generated summaries of news articles")
128
+ summarizer_error: str = Field(..., description="String specifying error raised during summary.")
129
 
130
 
131
  class NewsSummarizerAPIAuthenticationError(Exception):
 
146
  "schema": List[Summary]
147
  }
148
  }
 
 
 
 
 
 
 
 
 
149
  }
150
  })
151
  async def read_items(q: URLList):