Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions src/content/docs/docs/guides/build-with-ai.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
title: Build with AI
description: How to build with Hardhat using coding agents
---

import RunRemote from "@hh/RunRemote.astro";

This guide explains how to use coding agents effectively in Hardhat projects.

## Agent skills

LLMs are good at working with Hardhat, but they tend to prefer Hardhat 2 APIs. A small amount of extra context about Hardhat 3 is usually enough to steer them in the right direction.

The easiest way to provide that context is to install our main Hardhat skill:

<RunRemote command="skills add nomicfoundation/hardhat-skills --skill hardhat" />

### Project-specific skills

Hardhat projects are extensible and can rely on different plugins, so we also publish skills tailored to specific setups.

If your project is based on [`hardhat-toolbox-viem`](/docs/plugins/hardhat-toolbox-viem), install the corresponding skill:

<RunRemote command="skills add nomicfoundation/hardhat-skills --skill hardhat-toolbox-viem" />

If your project is based on [`hardhat-toolbox-mocha-ethers`](/docs/plugins/hardhat-toolbox-mocha-ethers):

<RunRemote command="skills add nomicfoundation/hardhat-skills --skill hardhat-toolbox-mocha-ethers" />

## Documentation

Hardhat docs are agent-friendly: we offer an [`llms.txt`](/llms.txt) index, and any docs page is also available as Markdown. Pointing your agent at our docs should just work.
1 change: 1 addition & 0 deletions src/sidebar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ export const sidebarTopics: StarlightSidebarTopicsUserConfig = [
{ slug: "docs/guides/hardhat-node" },
{ slug: "docs/guides/hardhat-console" },
// { slug: "docs/guides/command-line-completion" },
{ slug: "docs/guides/build-with-ai" },
{ slug: "docs/guides/getting-help" },
],
},
Expand Down
Loading