Access the STRING database to map identifiers, retrieve protein–protein interaction networks, and run functional/PPI enrichment when you need interaction context for a gene/protein set.
62
73%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
View guide
Passed
No findings from the security scan
Fix and improve this skill with Tessl
tessl review fix ./scientific-skills/Evidence Insight/string-database/SKILL.mdTP53) and need to resolve them to STRING protein identifiers for downstream analysis.>=3.8requests (tested with >=2.28)pandas (tested with >=1.5)Install:
pip install requests pandasfrom scripts.string_api import StringClient
def main():
# STRING does not require a secret API key, but providing a caller identity is recommended.
client = StringClient(caller_identity="my_analysis_tool")
# 1) Map an identifier (e.g., TP53 in Homo sapiens; NCBI taxonomy ID 9606)
protein_id = client.map_id(identifier="TP53", species=9606)
print("Mapped ID:", protein_id)
# 2) Download a network image and expand by adding interaction partners
client.get_network_image(
identifiers=[protein_id],
output_file="tp53_network.png",
add_color_nodes=10, # add 10 partners
)
print("Saved network image to tp53_network.png")
# 3) Run PPI enrichment for the set
ppi_stats = client.get_ppi_enrichment(identifiers=[protein_id])
print("PPI enrichment:", ppi_stats)
if __name__ == "__main__":
main()scripts/string_api.py provides the main wrapper (e.g., StringClient) around the STRING REST API.caller_identity string is strongly recommended (project name/email/URL) to support rate/load management.StringClient(caller_identity="my_email@example.com")) or inject via environment variables in your own wrapper.9606 for human).references/string_reference.md for original API notes and endpoint details included with this skill.63c61d3
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.