I have a list of genes and proteins extracted from literature. How can I convert them into standard gene names.
Using an Ensembl ID, Uniprot ID or NCBI ID it is much easier to look up your gene. So I would strongly reccomend using one of those as a key. Personally, I'd use Uniprot, but Ensembl is probably better if your genes are human. One reason for this is also that different resources will use different names, especially for humans.
There are a few considerations, so I will first say how this could be done properly...
Custom Uniprot matcher with weights
Some names are used by different protein, so which one is which would depend on context, co-occurrence with another gene.
Your dataset might be extremely noisy. Therefore, you likely have assigned a confidence score to your matches, yes? It would be nice to give a score to the name based on whether it is the first name of the protein or the fourth synonym in the list.
Therefore to do a conversion properly you really ought to make your own conversion system based upon context and Uniprot data. Uniprot contains the most data on synonyms and notes and binding partners etc. The dataset/API is in XML and Biopython does not have a parser, but I have some notes on the matter and can share some code if needed as I have done something similar (e.g. JSON for human gene/protein names to Uniprot IDs).
The NCBI entrez API is rather flexible and good at presenting to you matches for a strange names. So I would suggest using that.
If you have a list of human gene names from various sources that may include old or alternative names, then I'd suggest using the HUGO database (www.genenames.org). From there you can get a table of approved names and symbols as well as alternative symbols* . With this you can search for your gene names in the table and assign the approved name.
I wouldn't use Ensembl ID as some genes have multiple IDs that indicate the haplotype of the source genome, which is probably not useful for most purposes.
*Names are the full description of the protein, e.g. "B-Raf proto-oncogene, serine/threonine kinase" whereas the symbol is the short version you usually see, e.g "BRAF"