本文へスキップ
Skillpedia
一般的なプログラミング64k · #3164

context7-mcp

できること

このスキルは、エージェントが回答する前に、ソフトウェアのライブラリやフレームワークの最新のドキュメントを確認するようにします。古いコード例ではなく、正確なコードがほしい開発者向けです。

使う場面

  • ✓React、Next.js、Prisma などのライブラリを使うコードを書いてほしいとき。
  • ✓フレームワークの設定やセットアップについて質問するとき。
  • ✓使っているツールの正確な API メソッドが必要なとき。

スキルのリンク

https://github.com/upstash/context7/blob/master/packages/opencode/skills/context7-mcp/SKILL.md

コピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。

使い方

いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。

貼り付け用メッセージ

このスキルを使って手伝ってください:https://github.com/upstash/context7/blob/master/packages/opencode/skills/context7-mcp/SKILL.md このリンクのSKILL.mdファイルを読んで、私の作業でその指示に従ってください。
こういうスキルを、AIが自分で見つけてくれたら?無料のSkillpedia MCPをインストール。1行で、作業の前に15,000+のスキルから探してくれます。1分でインストール →

AIへの頼み方の例

“最新のドキュメントを使って、Next.js のプロキシの設定方法を見せてください。”

毎週5つの新しいスキル。1分で読めます。

仕組み

このスキルは、まず Context7 の索引から適切なライブラリを見つけ、あなたの質問に関するドキュメントを取得します。エージェントは記憶だけでなく、そのドキュメントを使って答えます。

技術的な内容(元のSKILL.md)

作者による元のテキスト(英語)をGitHubからそのまま表示しています。

When the user asks about libraries, frameworks, or needs code examples, use Context7 to fetch current documentation instead of relying on training data.

When to Use This Skill

Activate this skill when the user:

  • Asks setup or configuration questions ("How do I configure a Next.js proxy?")
  • Requests code involving libraries ("Write a Prisma query for...")
  • Needs API references ("What are the Supabase auth methods?")
  • Mentions specific frameworks (React, Vue, Svelte, Express, Tailwind, etc.)

How to Fetch Documentation

Step 1: Resolve the Library ID

Call resolve-library-id with:

  • libraryName: The library name extracted from the user's question
  • query: What to look up in the library's documentation (improves relevance ranking)

Step 2: Select the Best Match

From the resolution results, choose based on:

  • Exact or closest name match to what the user asked for
  • Higher benchmark scores indicate better documentation quality
  • If the user mentioned a version (e.g., "React 19"), prefer version-specific IDs

Step 3: Fetch the Documentation

Call query-docs with:

  • libraryId: The selected Context7 library ID (e.g., /vercel/next.js)
  • query: What to look up in the library's documentation, scoped to a single concept

If the user's question spans multiple distinct concepts (e.g. routing and auth and caching), make a separate query-docs call per concept with the same library ID, unless the question is about how the concepts interact — combined queries dilute ranking and return shallow results for each topic.

Step 4: Use the Documentation

Incorporate the fetched documentation into your response:

  • Answer the user's question using current, accurate information
  • Include relevant code examples from the docs
  • Cite the library version when relevant

Guidelines

  • Be specific: Describe what to look up in the library's documentation, but keep each query to a single concept
  • One topic per query: Split multi-topic questions into separate query-docs calls — resolve the library ID once, then query per concept, unless the question is about how the concepts interact
  • Version awareness: When users mention versions ("Next.js 16", "React 19"), use version-specific library IDs if available from the resolution step
  • Prefer official sources: When multiple matches exist, prefer official/primary packages over community forks
よくある質問

記憶に頼らないのはなぜですか?

ライブラリは頻繁に変わるため、記憶は古くなることがあります。最新のドキュメントは、古いコード例を避ける助けになります。

特定のバージョンのドキュメントを探せますか?

はい。React 19 などのバージョンを指定すると、そのバージョン専用のドキュメントを優先します。

多くのツールに対応していますか?

React、Vue、Next.js、Prisma、Supabase など、多くのライブラリやフレームワークに対応しています。

詳細

作者による元の説明

This skill should be used when the user asks about libraries, frameworks, API references, or needs code examples. Activates for setup questions, code generation involving libraries, or mentions of specific frameworks like React, Vue, Next.js, Prisma, Supabase, etc.

repo: upstash/context7

人気

GitHubのスター
64k
ランキング
#3164
ライセンス
MIT
更新日
2026/11/2

このスキルは役に立ちますか?

0

ログイン して投票しましょう。

コメント

  • …

このリポジトリの他のスキル

似ているスキル