Search for Wikipedia context with natural language
Changed onSearch for wikipedia documents
Request
- Base URLhttps://api.asknews.app
- AuthAPI key in header Authorization
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Query parameters
Query string that can be any phrase, keyword, question, or paragraph.
Number of neighbor chunks to attach and return. If 0, then no neighbor chunks will be returned.
Number of documents to return.
If true, then full articles will be returned. If false, then only chunks and their neighbors will be returned. Beware that asking for full articles returns more data, and therefore is more token intense downstream.
If true, then hybrid search will be used. If false, then only Sparse vector search will be used.
List of strings that must be present in the results. If empty, then no string guarantee will be applied.
Diversity factor for MMR re-ranking. 0.0 means no diversity (pure relevance), 1.0 means full diversity.
If true, then the main section of the article will be included at the start of each chunk's content. If false, then only the chunk content will be returned. Useful because the main section often contains important context.
Filter results by whether the article has Wikidata. If true, only articles with Wikidata are returned. If false, articles without Wikidata are returned (including points where the field is absent). If not set, no filtering is applied.
Response
Wikipedia search results
Changes
- breaking
the response property
////became optional for the status - breaking
the response property
////became optional for the status - breaking
the response property
////became optional for the status - breaking
the response property
////became optional for the status - breaking
the response property
////became optional for the status - breaking
response property
documents/items/cirrus_metadata/anyOf[subschema #1: CirrusMetadata]/create_timestamplist-of-types was widened by adding typesnullto media typeapplication/jsonof response200 - breaking
response property
documents/items/cirrus_metadata/anyOf[subschema #1: CirrusMetadata]/popularity_scorelist-of-types was widened by adding typesnullto media typeapplication/jsonof response200 - breaking
response property
documents/items/cirrus_metadata/anyOf[subschema #1: CirrusMetadata]/text_byteslist-of-types was widened by adding typesnullto media typeapplication/jsonof response200 - breaking
response property
documents/items/cirrus_metadata/anyOf[subschema #1: CirrusMetadata]/versionlist-of-types was widened by adding typesnullto media typeapplication/jsonof response200 - breaking
response property
documents/items/cirrus_metadata/anyOf[subschema #1: CirrusMetadata]/wikibase_itemlist-of-types was widened by adding typesnullto media typeapplication/jsonof response200 - info
added the new optional
queryrequest parameterhas_wikidata - info
added the optional property
////to the response with the status - info
added the optional property
////to the response with the status - info
added the optional property
////to the response with the status - info
added the optional property
//to the response with the status - info
added the optional property
//to the response with the status - info
added the optional property
//to the response with the status
- breaking