{"record":{"id":"30f2abed6185a69c","repo":"upstash/context7","slug":"your-results-only-include-libraries-matching-your-30f2ab","errorCode":null,"errorMessage":"Your results only include libraries matching your teamspace's library filters. To adjust quality thresholds or blocked libraries, update your filters at https://context7.com/dashboard?tab=policies","messagePattern":"Your results only include libraries matching your teamspace's library filters\\. To adjust quality thresholds or blocked libraries, update your filters at https://context7\\.com/dashboard\\?tab=policies","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"packages/cli/src/commands/generate.ts","lineNumber":168,"sourceCode":"      \"These sources are used to:\\n• extract best practices and constraints\\n• compare patterns across official docs and examples\\n• avoid outdated or incorrect guidance\\n\"\n    )\n  );\n  console.log(pc.dim(\"You can adjust which sources the skill is based on.\\n\"));\n\n  const searchSpinner = ora(\"Finding relevant sources...\").start();\n  const searchResult = await searchLibraries(motivation, accessToken);\n\n  if (searchResult.error || !searchResult.results?.length) {\n    searchSpinner.fail(pc.red(\"No sources found\"));\n    log.warn(searchResult.message || \"Try a different description\");\n    return;\n  }\n\n  searchSpinner.succeed(pc.green(`Found ${searchResult.results.length} relevant sources`));\n  log.blank();\n\n  if (searchResult.searchFilterApplied) {\n    log.warn(\n      \"Your results only include libraries matching your teamspace's library filters. To adjust quality thresholds or blocked libraries, update your filters at https://context7.com/dashboard?tab=policies\"\n    );\n    log.blank();\n  }\n\n  let selectedLibraries: LibrarySearchResult[];\n  try {\n    const formatProjectId = (id: string) => {\n      return id.startsWith(\"/\") ? id.slice(1) : id;\n    };\n\n    const isGitHubRepo = (id: string): boolean => {\n      const cleanId = id.startsWith(\"/\") ? id.slice(1) : id;\n      const parts = cleanId.split(\"/\");\n      if (parts.length !== 2) return false;\n      const nonGitHubPrefixes = [\"websites\", \"packages\", \"npm\", \"docs\", \"libraries\", \"llmstxt\"];\n      return !nonGitHubPrefixes.includes(parts[0].toLowerCase());\n    };","sourceCodeStart":150,"sourceCodeEnd":186,"githubUrl":"https://github.com/upstash/context7/blob/4416fb855b8f752be735e34f943b5d0762701aad/packages/cli/src/commands/generate.ts#L150-L186","documentation":"When the search response has searchFilterApplied=true, generateCommand warns that results were restricted by teamspace library filters (quality thresholds / blocked libraries) and points to the dashboard policies tab. Search succeeded, but the result set was narrowed server-side by the team's policy configuration.","triggerScenarios":"`searchLibraries` returns results with searchFilterApplied === true, i.e. the teamspace's policy filters excluded some libraries from the candidate set.","commonSituations":"Working in an org teamspace with strict quality thresholds or a blocked-library list; a needed library is filtered out, causing worse or missing source matches.","solutions":["Visit https://context7.com/dashboard?tab=policies and adjust quality thresholds or unblock the needed libraries","Ask a teamspace admin to update the library filter policies","Generate outside the filtered teamspace context if your plan allows"],"exampleFix":"// before (dashboard policies)\nqualityThreshold: 90, blocked: [\"popular-lib\"]\n// after\nqualityThreshold: 50, blocked: []","handlingStrategy":"fallback","validationCode":"if (searchResult.searchFilterApplied) { console.warn('Results filtered by teamspace policies; adjust at dashboard?tab=policies'); }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Review teamspace library-filter policies before generating expertise","Unblock or lower thresholds for libraries you need at https://context7.com/dashboard?tab=policies","Confirm with the teamspace admin which libraries are filtered"],"tags":["cli","search","teamspace","policy-filters"],"backgroundTag":"insufficient-permissions","analyzedSha":"4416fb855b8f752be735e34f943b5d0762701aad","analyzedAt":"2026-09-16T20:28:07.148Z","contentChangedAt":"2026-09-16T20:28:07.148Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}