An introduction to
programmatic access
Rafael C Jimenez
ELIXIR CTO
EMBL-EBI workshop networks and pathways 2014, Friday 23 June
European Life Sciences Infrastructure for Biological Information
www.elixir-europe.org
Query interfaces
remote resource
Data
Graphical
User
Interface
(GUI)
Biologist
2
FTP
access
Web
Services
Bioinformaticians
Application
Programmatic
Interface
(API)
Database
access
Developers
Query interfaces
remote resource
Data
Graphical
User
Interface
(GUI)
FTP
access
Web
Services
Application
Programmatic
Interface
(API)
Database
access
Interface: A program that allows users to interact with a system
API: An interface that can be accessed using a specific programing
language
Web service: A web API available for multiple programming languages
3
This introduction is intended for a non technical
audience with purposely simplified technical concepts.
Web Services
Service on the server side providing functionality
It is accessible over a network (Internet)
It is meant for machine to machine communication
Independent from programming languages
It can be operated following specific rules (protocols: REST or
SOAP)
This introduction is intended for a non technical
audience with purposely simplified technical concepts.
Web Services
User/Developer
1 How should I invoke you?
Web server
Documentation 2
3 Make a request
Application
2
Results 4
describes the methods and variables to query the service
REST Web Services
Informal
Description
Formal
Description
or
Developer
WADL
Web server
1 How should I invoke you?
Documentation 2
3 Make a request ( GET or POST)
Application
2
Results (data
+ status)
4
Sometimes a WADL file is available in the server to describe
the service
SOAP Web Services
Informal
Description
Formal
Description
and WSDL
Developer
Web server
1 How should I invoke you?
Documentation (WSDL) 2
3
Application
3
Make a SOAP
Results (SOAP
SOAP request
Method / Parameters
request
response) 4
4 SOAP response
Data
SOAP vs. REST
SOAP
• Based on Standards.
• Only accessed by specialized software.
• Allow description of complex data structure in request and response.
SOAP
REST
WSDL: http://www.ebi.ac.uk/…/psicquic?wsdl
REST
• Geared to simplicity.
• A browser can be a client.
• Request as complex as a URL can be.
REST query: http://www.ebi.ac.uk/…/query/P99999?format=xml25
8
WADL: http://www.ebi.ac.uk/…/current?_wadl
1
2
3
PSICQUIC
REST
queries
intact
query p53
http://www.ebi.ac.uk/Tools/webservices/psicquic/
http://mint.bio.uniroma2.it/
/
mint/psicquic/webservices/current/search/query/p53
http://www.ebi.ac.uk/Tools/webservices/psicquic/
Bruno Aranda (baranda@ebi.ac.uk)
/webservices/current/search/
chembl/webservices/current/search/query/p53
MIQL
Bruno Aranda (baranda@ebi.ac.uk)
• Terms
• Fields
• Operands
…/query/
specie:rat
…/query/brca
AND rpa1
MIQL
PSICQUIC SOAP service
species:trypanosoma AND detmethod:’two hybrid’
Workflows
European Life Sciences Infrastructure for Biological Information
www.elixir-europe.org
Workflow
• Workflow
– Sequence of tasks that produces a
result of observable value
• Workflow management
system
– Computer system to compose and
execute workflows.
• Workflow components
– Input
– Service
– Output
– toShims
Introduction
Web Services at EBI
Service A
Service B
Shims: Connecting services
• Convert data formats and act as connectors
Service A
Service A
Service B
Service B
Mismatch
Match
MyGrid
European Life Sciences Infrastructure for Biological Information
www.elixir-europe.org
myGrid solutions
Discover and reuse services
Create and run workflows
Share, discover and reuse workflows
Biocatalogue
http://www.biocatalogue.org
• A public centralised and curated registry of
Life Science Web Services
• ‘Web 2.0’-style website and API
• Allow anyone to register, discover and curate
Web Services
• Community oriented with expert guidance
• Open content, open source, open platform
Paul Fisher, myGrid, University of Manchester
BioCatalogue’s Mission
4/8/2015
19
Service Search
Taverna
• Workflow management system
• Java desktop application
• Open source and extensible
• Includes access to Biocatalogue and myExperiment
• http://www.taverna.org.uk/
Available
Workflow
services
diagram
Tree view of
workflow structure
Sharing Experiments
• You can share results/experiments/experiences with your
– Research group
– Collaborators
– Scientific community
A registry of workflows
Paul Fisher, myGrid, University of Manchester
myExperiment
http://www.myexperiment.org/
Recycling, Reuse, Repurposing
•
•
•
•
•
Paul writes workflows for identifying biological pathways
implicated in resistance to Trypanosomiasis
Paul meets Jo. Jo is investigating mouse Whipworm infection.
Jo reuses one of Paul’s workflows.
Jo identifies the biological pathways involved in sex dependence
in the mouse model, believed to be involved in the ability of
mice to expel the parasite.
Previously a manual two year study by Jo had failed to do this.
Workflows are protocols
Paul Fisher, myGrid, University of Manchester
Examples from myExperiment
OLS
Biomart and
Microarray
analysis
ChEBI
PICR
Taverna
European Life Sciences Infrastructure for Biological Information
www.elixir-europe.org
Run workflow
Services Panel
Workflow
Diagram
Workflow
Explorer
Input
list
Input description
Input example
Input value
Output
tab
List of
results
Results
Installing the Workbench
• Download the Taverna 2.5 workbench from
http://www.taverna.org.uk/
• Install Taverna
• Open Taverna
• Start / All programs / Taverna / Taverna Workbench 2.5
• You do not have to complete the registration now. Click on “Do no ask
me again”.
Tutorial
myExperiment & Taverna
European Life Sciences Infrastructure for Biological Information
www.elixir-europe.org
Simple PSICQUIC workflow with Taverna
to query IntAct
1. Open one PSICQUIC workflow
1. Open Taverna and click the “myExperiment” button.
myExperiment is a repository of workflows
2.
3.
4.
5.
2. In the “Query” field, type “psicquic”
3. Find the “Molecular Interactions from IntAct PSICQUIC service (REST)” workflow and
click on the “Open” button.
Run a PSICQUIC workflow
1. In the menu click on “File” and “Run workflow”
Define your query
1. Find and click the “Set value” button
2. Specify your MIQL query. i.e
• species:trypanosoma AND detmethod:"two hybrid"
3. Click on the button “Run workflow”
Check your results
1. In the bottom left corner, in the “MITAB” tab, click on “Value1”
Save results
1. Click on the “Save value” button on the bottom right corner.
Workflow results
Make your own workflow,
reuse workflows
Look at the following workflows:
•
•
Get a list of Protein Identification experiments from PRIDE by a Gene Ontology query
http://www.myexperiment.org/workflows/2746.html
Get a list of proteins annotated with an Ontology term and use these proteins to query
BioModels
http://www.myexperiment.org/workflows/3113.html
Create a similar workflow to retrieve molecular interactions from IntAct
using a GO term as input. Reuse one of the previous workflows and
connect it with one of the following workflows:
•
Retrieve Molecular Interactions from PSICQUIC Services:
http://www.myexperiment.org/workflows/2153.html
http://www.myexperiment.org/workflows/1799.html
http://www.myexperiment.org/workflows/2458.html
Thank you
European Life Sciences Infrastructure for Biological Information
www.elixir-europe.org