Forge Tools semantic_scholar_search

semantic_scholar_search read

scidex.forge.semantic_scholar_search

Search Semantic Scholar for scholarly papers. Broader than PubMed (covers preprints, CS, multi-disciplinary venues) and carries citation-graph metrics. Returns structured records with title, authors, year, venue, abstract, citation counts, and DOI/PMID/arXiv cross-walks.

HTTP: POST /api/scidex/forge/semantic_scholar_search

Invoke

Calls scidex.tool.invoke on the substrate with this tool name. Edit the JSON below — it must match the input schema. The substrate runs the tool, records the call in substrate_tool_calls, and returns a structured envelope.

Sign in to invoke this tool. Schema and curl snippet are visible to anyone.

Schemas

Input schema
{
  "additionalProperties": false,
  "description": "Input schema for ``scidex.forge.semantic_scholar_search``.",
  "properties": {
    "query": {
      "description": "Free-text query string. S2 ranks by relevance; downstream rerankers can use the returned ``citation_count`` and ``influential_citation_count`` for citation-weighted ordering.",
      "maxLength": 500,
      "minLength": 1,
      "title": "Query",
      "type": "string"
    },
    "limit": {
      "default": 10,
      "description": "Maximum number of papers to return. S2's hard cap is 100 per call; paginate via repeated calls with narrower year or venue filters if you need more.",
      "maximum": 100,
      "minimum": 1,
      "title": "Limit",
      "type": "integer"
    },
    "venue": {
      "anyOf": [
        {
          "maxLength": 500,
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Comma-separated venue names to restrict the search to (e.g. ``Nature,Cell,Science``). Passed through verbatim to S2's ``venue`` query parameter.",
      "title": "Venue"
    },
    "year_range": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Year filter as ``YYYY`` (single year) or ``YYYY-YYYY`` (inclusive range, e.g. ``2018-2024``). Passed to S2 as the ``year`` query parameter.",
      "title": "Year Range"
    }
  },
  "required": [
    "query"
  ],
  "title": "SemanticScholarSearchIn",
  "type": "object"
}
Output schema
{
  "$defs": {
    "S2SearchAuthor": {
      "description": "One author on a search-result paper.",
      "properties": {
        "author_id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Author Id"
        },
        "name": {
          "default": "",
          "title": "Name",
          "type": "string"
        }
      },
      "title": "S2SearchAuthor",
      "type": "object"
    },
    "S2SearchPaper": {
      "description": "One Semantic Scholar paper, flattened for the verb surface.\n\nDistinct from the skill-internal :class:`S2Paper` so the verb's\npublic schema is stable even if we extend the skill later.",
      "properties": {
        "paper_id": {
          "title": "Paper Id",
          "type": "string"
        },
        "title": {
          "default": "",
          "title": "Title",
          "type": "string"
        },
        "authors": {
          "items": {
            "$ref": "#/$defs/S2SearchAuthor"
          },
          "title": "Authors",
          "type": "array"
        },
        "year": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Year"
        },
        "venue": {
          "default": "",
          "title": "Venue",
          "type": "string"
        },
        "abstract": {
          "default": "",
          "title": "Abstract",
          "type": "string"
        },
        "citation_count": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Citation Count"
        },
        "influential_citation_count": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Influential Citation Count"
        },
        "reference_count": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Reference Count"
        },
        "doi": {
          "default": "",
          "title": "Doi",
          "type": "string"
        },
        "pmid": {
          "default": "",
          "title": "Pmid",
          "type": "string"
        },
        "arxiv_id": {
          "default": "",
          "title": "Arxiv Id",
          "type": "string"
        },
        "publication_types": {
          "items": {
            "type": "string"
          },
          "title": "Publication Types",
          "type": "array"
        },
        "open_access_pdf_url": {
          "default": "",
          "title": "Open Access Pdf Url",
          "type": "string"
        }
      },
      "required": [
        "paper_id"
      ],
      "title": "S2SearchPaper",
      "type": "object"
    }
  },
  "description": "Response shape for ``scidex.forge.semantic_scholar_search``.",
  "properties": {
    "query": {
      "title": "Query",
      "type": "string"
    },
    "total": {
      "default": 0,
      "description": "Total matching papers reported by S2. May exceed ``len(results)`` since one call returns at most ``limit`` papers.",
      "title": "Total",
      "type": "integer"
    },
    "returned": {
      "description": "Length of ``results``.",
      "title": "Returned",
      "type": "integer"
    },
    "results": {
      "items": {
        "$ref": "#/$defs/S2SearchPaper"
      },
      "title": "Results",
      "type": "array"
    },
    "took_ms": {
      "description": "Wall-clock time for the upstream call.",
      "title": "Took Ms",
      "type": "integer"
    }
  },
  "required": [
    "query",
    "returned",
    "took_ms"
  ],
  "title": "SemanticScholarSearchOut",
  "type": "object"
}

curl snippet

Replace $SCIDEX_JWT with a valid bearer token. Read verbs are usually accessible without auth in dev; production requires a JWT.

curl -sS -X POST '/api/scidex/forge/semantic_scholar_search' \
  -H 'authorization: Bearer $SCIDEX_JWT' \
  -H 'content-type: application/json' \
  -d '{
  "query": ""
}'

Discussion

Posting anonymously. Sign in for attribution.

No comments yet — be the first.