search_models
Find GO-CAM biological models by filtering criteria including title, state, contributor, research group, publication, or gene product to retrieve relevant model metadata.
Instructions
Search for GO-CAM models based on various criteria.
Allows searching models by title, state, contributor, group, publication, or gene product. Returns a list of matching models with their metadata.
Args: title: Search for models containing this text in their title state: Filter by model state (production, development, internal_test) contributor: Filter by contributor ORCID (e.g., 'https://orcid.org/0000-0002-6601-2165') group: Filter by group/provider (e.g., 'http://www.wormbase.org') pmid: Filter by PubMed ID (e.g., 'PMID:12345678') gene_product: Filter by gene product (e.g., 'UniProtKB:Q9BRQ8', 'MGI:MGI:97490') limit: Maximum number of results to return (default: 50) offset: Offset for pagination (default: 0)
Returns: Dictionary containing search results with model metadata
Examples: # Search for all production models results = search_models(state="production")
Notes: - Results include model ID, title, state, contributors, and dates - Use pagination (offset/limit) for large result sets - Filters can be combined for more specific searches - Gene products can be from various databases (UniProt, MGI, RGD, etc.)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | No | ||
| state | No | ||
| contributor | No | ||
| group | No | ||
| pmid | No | ||
| gene_product | No | ||
| limit | No | ||
| offset | No |
Input Schema (JSON Schema)
Implementation Reference
- src/noctua_mcp/mcp_server.py:1348-1440 (handler)The primary handler function for the 'search_models' MCP tool. It uses FastMCP's @mcp.tool() decorator for registration and calls BaristaClient.list_models() to perform the search with provided filters.async def search_models( title: Optional[str] = None, state: Optional[str] = None, contributor: Optional[str] = None, group: Optional[str] = None, pmid: Optional[str] = None, gene_product: Optional[str] = None, limit: int = 50, offset: int = 0 ) -> Dict[str, Any]: """ Search for GO-CAM models based on various criteria. Allows searching models by title, state, contributor, group, publication, or gene product. Returns a list of matching models with their metadata. Args: title: Search for models containing this text in their title state: Filter by model state (production, development, internal_test) contributor: Filter by contributor ORCID (e.g., 'https://orcid.org/0000-0002-6601-2165') group: Filter by group/provider (e.g., 'http://www.wormbase.org') pmid: Filter by PubMed ID (e.g., 'PMID:12345678') gene_product: Filter by gene product (e.g., 'UniProtKB:Q9BRQ8', 'MGI:MGI:97490') limit: Maximum number of results to return (default: 50) offset: Offset for pagination (default: 0) Returns: Dictionary containing search results with model metadata Examples: # Search for all production models results = search_models(state="production") # Find models containing "Wnt signaling" in title results = search_models(title="Wnt signaling") # Find models for a specific gene product results = search_models(gene_product="UniProtKB:P38398") # Find models from a specific paper results = search_models(pmid="PMID:30194302") # Find models by a specific contributor results = search_models( contributor="https://orcid.org/0000-0002-6601-2165" ) # Combine filters results = search_models( state="production", title="kinase", limit=10 ) # Pagination example page1 = search_models(limit=50, offset=0) page2 = search_models(limit=50, offset=50) # Find models from specific research group results = search_models(group="http://www.wormbase.org") # Search for development models with specific gene results = search_models( state="development", gene_product="MGI:MGI:97490" ) Notes: - Results include model ID, title, state, contributors, and dates - Use pagination (offset/limit) for large result sets - Filters can be combined for more specific searches - Gene products can be from various databases (UniProt, MGI, RGD, etc.) """ client = get_client() try: results = client.list_models( title=title, state=state, contributor=contributor, group=group, pmid=pmid, gp=gene_product, limit=limit, offset=offset ) return results except Exception as e: return { "error": "Failed to search models", "message": str(e) }