跳到正文
cccskills
免费在 GitHub 公开

context7-auto-research

Research libraries and APIs automatically by pulling live documentation into the agent's context before answering. Use when writing code against unfamiliar or fast-moving libraries so examples match current versions.

中文简介正在准备中。当前显示原文说明。

查看安装方法

包含的文件(1)

  • SKILL.md3.7 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

Auto-Research with Live Documentation

Libraries change faster than training data. The auto-research pattern is simple: before writing code against a library, fetch its current documentation into context, then generate code from that — never from memory of an old API.

Overview

Stale API knowledge is the top cause of hallucinated code: invented parameters, renamed functions, deprecated patterns. The fix is a research step that retrieves the live docs for exactly the library and version in use and puts them in front of the model. This turns code generation into grounded generation — the model quotes real signatures instead of reconstructing them from memory.

When to use

  • Writing code with a library you haven't used recently, or one with frequent breaking changes.
  • The user mentions a specific version — resolve the docs for that version, not "the latest you remember."
  • An API call fails or returns unexpected results — re-check the docs before debugging your logic.
  • Reviewing generated code that uses an unfamiliar library: verify signatures against live docs.

Core concepts

  • Doc-first generation: research step precedes code step. Fetch first, generate second — never the reverse.
  • Version pinning: docs for the installed version, matched by package lockfile or explicit user statement. "Latest" docs and a pinned old dependency is a classic mismatch.
  • Targeted retrieval: pull the specific reference pages (API signatures, config options, migration guides), not the whole documentation site. Noise dilutes the context.
  • Freshness check: note the doc page's date/version. If the docs look older than the installed version, flag the mismatch.
  • Cache with expiry: doc lookups are network calls; cache them per project but invalidate when the version changes.

Practical workflow

  1. Identify the library and version from the project's lockfile or package manifest — don't guess.
  2. Fetch the current reference docs: API signatures, quickstart, and migration notes for that version.
  3. Extract the exact signatures and options needed for the task; quote them in your working notes.
  4. Generate code against the fetched docs, citing which doc page each pattern comes from.
  5. If generated code fails, re-read the docs before assuming a bug in your logic — check parameter names, defaults, and async behavior.
  6. Cache the fetched docs in the project workspace; note the version so the next session revalidates instead of re-fetching blindly.
Research note format (keep in workspace):
Library: <name> @ <version>
Source:  <doc URL + access date>
Needs:   <signatures/options relevant to the task>
Watch:   <deprecations, version-specific gotchas>

Common pitfalls

  • Generating from memory first: the default habit. Make doc-fetching the mandatory first step for unfamiliar libraries.
  • Version mismatch: reading latest docs while the project pins an old version. Always cross-check against the lockfile.
  • Over-fetching: dumping entire doc sites into context. Retrieve the pages that match the task; summarize the rest.
  • No freshness note: docs fetched months ago treated as current. Record the access date and revalidate on version bumps.
  • Trusting examples blindly: doc examples sometimes lag the reference. Prefer the signature reference over tutorial prose.
  • Skipping the step under time pressure: that's exactly when stale-API hallucinations happen. The research step is cheapest insurance.

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

Master 1Password: vaults, Watchtower, passkeys, SSH agent, CLI, and family/team administration. Use when getting full value from 1Password personally or administering it for others.

中文简介正在准备中。当前显示原文说明。

aicodedecode/awesome-muse-skills252026年10月10日 更新

Create 3D visuals with modeling, texturing, lighting, rendering, and optimization for web and product.

中文简介正在准备中。当前显示原文说明。

aicodedecode/awesome-muse-skills252026年10月10日 更新

Create 3D web experiences: scene setup, models, materials, lighting, animation, scroll-driven scenes, and performance budgets. Use when adding 3D to websites beyond basic demos.

中文简介正在准备中。当前显示原文说明。

aicodedecode/awesome-muse-skills252026年10月10日 更新

Writing abstracts that get papers read — structured content, the 5-sentence core, and journal-specific constraints.

中文简介正在准备中。当前显示原文说明。

aicodedecode/awesome-muse-skills252026年10月10日 更新

Learn effectively from courses and academies: choosing programs, studying actively, and converting courses into skills. Use when investing time/money in structured learning.

中文简介正在准备中。当前显示原文说明。

aicodedecode/awesome-muse-skills252026年10月10日 更新

Audit designs for accessibility with WCAG checklists covering color, type, focus, motion, and content.

中文简介正在准备中。当前显示原文说明。

aicodedecode/awesome-muse-skills252026年10月10日 更新

查看 aicodedecode 的全部技能

报告此技能的问题