Help

wave
About

The web service is based on word embeddings induced using the word2vec method, trained on 17,719,608 PubMed abstracts. The result of the embedding consists of 3,221,627 words in the vocabulary.
The web service uses the Flask framework in Python for the RESTful API.

Nearest Words

This function returns the nearest neighbors that share a similar context in text with a particular word. The nearest words are sorted by the similarity value from highest to lowest.
Examples: MDM2, Breast_neoplasms, Omeprazole
Example query string: /page_nearest?word=mdm2&size=6
Example API query: /page_nearest/api?word=mdm2&size=6
*if the number of nearest neighbors is not given, the first 10 nearest neighbors will be returned.

Word Similarity

This function calculates the cosine similarity of two given words or a word and a list of words with a similarity value between 1 and -1. Cosine similarity is a measure that calculates the cosine of the angle between two word vectors.
Examples: MDM2 -- MDM4, TP53 -- MDM2,CHEK2,TP73,CDKN1A
Example query string: /page_similarity?word=MDM2&simwords=MDM4
Example API query: /page_similarity/api?word=MDM2&simwords=MDM4

Word Analogy

This function checks the semantic analogy between terms. It is used to get a target word "Term 4" that is similar to a particular word "Term 3" according to the semantic similarity between two other words "Term 1" and "Term 2". It performs vector arithmetic: adding the positive vectors (Term 1 and Term 3), subtracting the negative (Term 2), then from that resulting position, listing the known-vectors closest to that angle. ([Term 1 – Term 2] + Term 3 ~ Term 4). Word Analogy can solve analogy questions by calculating the syntactic relationships between word vectors.
Example: "[disease - neoplasms] + drug = ? " The most similar word = "anticancer drug"
Example query string: /page_analogy?word1=disease&word2=neoplasms&word3=drug&size=5
Example API query: /page_analogy/api?word1=disease&word2=neoplasms&word3=drug&size=5
*if the number of nearest neighbors is not given, the first 10 nearest neighbors will be returned.

Word Annotation & Word List Annotation

These functions work as the "Nearest Words" function, but the user is able to specify the output type of the similar words by choosing one of the four biomedical entity types (gene, disease, drug and pathway). These functions were developed based on annotating plenty of concepts using external biomedical resources.
Word Annotation Example: MDM2
Word List Annotation Example: MDM2,TP53
Example query string: /word_annotate__list_page?words=MDM2,TP53&type=gene&size=5
Example API query: /word_annotate_list_page/api?words=MDM2,TP53&type=gene&size=5
*if the number of nearest neighbors is not given, the first 10 nearest neighbors will be returned.

List of Nearest Words

This function takes as input a list of words and returns the combined nearest neighbors to all words that are sorted by the similarity value from highest to lowest according to the following criteria:

  • Number of nearest neighbors = 0 and cosine similarity cutoff = 0
  • The result is the combined similar words of the first 10 nearest neighbors of each word.

  • Cosine similarity cutoff = 0
  • The result is the first combined nearest neighbors to each word according to the chosen number of nearest neighbors.

  • Number of nearest neighbors = 0
  • The result is the first combined nearest neighbors to each word according to the chosen similarity value cutoff.

Example: BRCA1,BRCA2,TP53 .
Example query string: /word_annotate_list_vector?words=BRCA1,BRCA2,TP53&size=5&cutoff=0.6
Example API query: /word_annotate_list_vector/api?words=BRCA1,BRCA2,TP53&size=5&cutoff=0.6
*if the number of nearest neighbors is not given, the first 10 nearest neighbors will be returned.

Similarities between Words

This function returns the similarity between words within a list as kind of network edges. Only the word pairs that have a similarity value >= '0.4' are returned. If a word is not in the vocabulary of the embedding , its similarity to other words can not be calculated, so it won't be in the output list.
Example: TP53,TP73,MDM2,MDM4,TP63.
Example query string: /list_edges_page?words=TP53,TP73,MDM2,MDM4,TP63
Example API query: /list_edges_page/api?words=TP53,TP73,MDM2,MDM4,TP63

Word Vector

This function returns the numerical vector generated by the trained model in 300 dimensions. Word vectors can be represented as numerical descriptors for biomedical concepts.
Example: MDM2.
Example query string: /word_vector_page?word=MDM2
Example API query: /word_vector/api?word=MDM2