Skip to content

[feat] Add Semantic Scholar tools#8751

Open
danialza wants to merge 1 commit into
agno-agi:mainfrom
danialza:codex/add-semantic-scholar-tools
Open

[feat] Add Semantic Scholar tools#8751
danialza wants to merge 1 commit into
agno-agi:mainfrom
danialza:codex/add-semantic-scholar-tools

Conversation

@danialza

@danialza danialza commented Jul 4, 2026

Copy link
Copy Markdown

Summary

Closes #8750.

Adds SemanticScholarTools, a research toolkit backed by the Semantic Scholar Academic Graph API. It gives Agno agents paper search, paper metadata lookup, and optional author-paper lookup without adding a new package dependency.

Changes

  • Add SemanticScholarTools under libs/agno/agno/tools/
  • Support search_papers, get_paper, and get_author_papers
  • Use existing httpx dependency and optional SEMANTIC_SCHOLAR_API_KEY header support
  • Add mock-based unit tests for initialization, request handling, formatting, validation, and error paths
  • Add a cookbook example under cookbook/91_tools/

Type of change

  • Bug fix
  • New feature
  • Breaking change
  • Improvement
  • Model update
  • Other:

Checklist

  • Code complies with style guidelines
  • Ran format/validation scripts or focused equivalents
  • Self-review completed
  • Documentation updated through a cookbook example
  • Examples and guides: Relevant cookbook examples have been included or updated
  • Tested in clean environment
  • Tests added/updated

Duplicate and AI-Generated PR Check

  • I have searched existing open pull requests and confirmed that no other PR already addresses this issue
  • If a similar PR exists, I have explained below why this PR is a better approach
  • Check if this PR was entirely AI-generated (by Copilot, Claude Code, Cursor, etc.)

How Has This Been Tested?

  • /tmp/agno-semantic-scholar-venv/bin/python -m pytest libs/agno/tests/unit/tools/test_semantic_scholar.py -q
  • /tmp/agno-semantic-scholar-venv/bin/python -m ruff check libs/agno/agno/tools/semantic_scholar.py libs/agno/tests/unit/tools/test_semantic_scholar.py cookbook/91_tools/semantic_scholar_tools.py
  • /tmp/agno-semantic-scholar-venv/bin/python -m ruff format --check libs/agno/agno/tools/semantic_scholar.py libs/agno/tests/unit/tools/test_semantic_scholar.py cookbook/91_tools/semantic_scholar_tools.py
  • /tmp/agno-semantic-scholar-venv/bin/python -m mypy libs/agno/agno/tools/semantic_scholar.py --config-file libs/agno/pyproject.toml --follow-imports=skip

Additional Notes

Unauthenticated live smoke testing hit Semantic Scholar shared public rate limiting with HTTP 429, so the PR relies on mock-based unit coverage and supports SEMANTIC_SCHOLAR_API_KEY for stable usage.

AI assistance disclosure: This PR was generated with Codex. I reviewed the implementation scope and ran the checks listed above.

@danialza danialza marked this pull request as ready for review July 4, 2026 23:12
@danialza danialza requested a review from a team as a code owner July 4, 2026 23:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] Add Semantic Scholar academic paper search toolkit

1 participant