feat(tools): add search_people tool#157
Merged
stickerdaniel merged 3 commits intostickerdaniel:mainfrom Feb 20, 2026
Merged
Conversation
… Hub documentation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Really enjoyed digging into this codebase and hope to keep contributing — great project.
This adds a
search_peopletool for searching LinkedIn people by keywords and optional location filter.Hat tip to #152 by @danmunz which identified this as a missing tool and inspired this implementation. I borrowed the
only_first_degreeURL parameter idea from that PR but ultimately took a different approach — implementing directly onLinkedInExtractorusing the existinginnerTextextraction pattern rather than introducing thelinkedin_scraperdependency. This keeps the tool consistent with the rest of the codebase and maintains the separation between the scraping layer (extractor.py) and the tool registration layer (tools/person.py).Note:
only_first_degreefiltering was intentionally left out of this PR — wanted to ship the core feature first and tackle that in a follow-up once the member ID scoping requirement is solved properly.Changes
scraping/extractor.py— addedsearch_people()method alongsidesearch_jobs()tools/person.py— registeredsearch_peopletool insideregister_person_tools()tests/test_tools.py— addedtest_search_peopleandsearch_peoplemock to_make_mock_extractorAGENTS.md— addedsearch_peopleto the Available MCP Tools tableGreptile Summary
Adds a
search_peopletool for searching LinkedIn people by keywords with optional location filtering. The implementation follows the exact same pattern as the existingsearch_jobstool - adding asearch_people()method toLinkedInExtractorthat constructs the search URL with properly encoded parameters and extracts the results page using the establishedinnerTextextraction pattern. Tool registration inperson.pyincludes proper annotations, authentication, error handling, and progress reporting. All documentation files (README.md, AGENTS.md, docs/docker-hub.md) have been updated per the development workflow requirements.quote_plus()test_scraping.pyand README.md tool table entry - these appear to be addressed or acknowledgedConfidence Score: 5/5
search_jobsimplementation almost identically, uses proper URL encoding, includes comprehensive test coverage at the tool level, and updates all required documentation. No security concerns, no breaking changes, and no logic issues detected.Important Files Changed
search_people()method following exact pattern ofsearch_jobs()- clean implementation with proper URL encoding and consistent return structuresearch_peopletool with proper annotations, error handling, and progress reporting - mirrorssearch_jobspattern perfectlysearch_peopleand mock support - though unit test for extractor method intest_scraping.pyis still needed per existing commentFlowchart
%%{init: {'theme': 'neutral'}}%% flowchart TD A[AI calls search_people with keywords and location] --> B[Ensure user is authenticated] B --> C[Get or create browser instance] C --> D[Create LinkedInExtractor] D --> E[Build search URL with encoded parameters] E --> F[Navigate to LinkedIn people search page] F --> G[Extract page innerText] G --> H{Text extracted?} H -->|Yes| I[Add to search_results section] H -->|No| J[Return empty sections] I --> K[Return result with url, sections, pages_visited] J --> KLast reviewed commit: 1e75f36
Context used:
dashboard- CLAUDE.md (source)