Repository navigation
feat(gov): return law results with legal labels from firecrawl_gov_search - #599
Draft
erikengervall wants to merge 8 commits into
Draft
erikengervall wants to merge 8 commits into
erikengervall wants to merge 8 commits into
Conversation
…esults # Conflicts: # CHANGELOG.md
…esults # Conflicts: # CHANGELOG.md
…esults # Conflicts: # CHANGELOG.md
…esults # Conflicts: # CHANGELOG.md
This branch has not been deployed
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.
firecrawl_gov_searchnow requestssources=lawfrom/v2/search/govand returns thelawresults. Each row instructuredContent.resultskeepsurl,title,descriptionandposition, and also carries the Government Index's legal labels when the index has them:jurisdiction,court,court_type,cites,cited_asandupdated_at.The
lawgroup lists the same results in the same order asweb, so the text block (## <position>. <title>, URL, snippet) reads exactly as before. The tool description, input schema and server instructions are unchanged. The output schema already allows extra fields on each row, so the contract snapshots don't change.Draft until the API ships
sources: firecrawl/firecrawl#5354 addssourcesanddata.lawto/v2/search/gov. Until that is deployed, the API rejects thesourcesparameter with a 400, so this PR must not merge before it.Tests
tests/mcp-search-profile.test.mjs: the fake backend now answers withdata.law. The test asserts that the request sendssources=lawexactly once, that the text block is unchanged, and thatstructuredContent.resultscarries the labels.tsc --noEmit,pnpm lintand the fullpnpm test(225 pass) all pass.Docs: firecrawl/firecrawl-docs#1708.
Summary by cubic
firecrawl_gov_searchnow requestssources=lawfrom/v2/search/govand returns thelawresults instead of thewebresults.structuredContent.resultskeepsurl,title,descriptionandposition, and carries the index's legal labels (jurisdiction,court,court_type,cites,cited_as,updated_at) when available.webresults when the API ignoressourcesand only answersweb.Migration: Do not merge until the API supports
sources(firecrawl/firecrawl#5354); if the API rejects the parameter with a 400, the fallback does not apply.Written for commit d27129b. Summary will update on new commits.