@fmlima4/artificial-intelligence
v1.1.0
Published
Global CLI to import shared AI skills, prompts, agents and MCP guides into any project.
Maintainers
Readme
@fmlima4/artificial-intelligence
A global CLI that lets any developer interactively copy shared skills, prompts, agents, and MCP guides into a project so GitHub Copilot picks them up automatically.
The value is the content. The code only exists to make assets easy to discover and copy.
Global install
npm install -g @fmlima4/artificial-intelligenceRequires Node.js 22+. Install once per machine; use in any project.
Import assets into a project
Navigate to any project and run:
ai-library importThe CLI will:
- Ask which kind of asset you want — skill, agent, prompt, or MCP guide.
- Show a checkbox list of all available assets for that kind.
- Copy the selected files into the correct
.github/subfolder of the current directory, with Copilot-ready frontmatter. - Skip any file that already exists (never overwrites).
Example session:
$ ai-library import
? What kind of asset do you want to import? Skill
? Select skills to copy into this project:
◉ review-node-service
◯ update-readme
◉ create-pr-description
copied .github/instructions/review-node-service.instructions.md
copied .github/instructions/create-pr-description.instructions.md
Done. 2 copied, 0 skipped.Where files land
| Asset type | Destination |
|---|---|
| skill | .github/prompts/<name>.prompt.md |
| mcp | .github/instructions/<name>.instructions.md |
| prompt | .github/prompts/<name>.prompt.md |
| agent | .github/prompts/<name>.prompt.md |
Files are copied with the correct Copilot frontmatter already set:
skill/prompt→mode: ask(appears as a slash-command in chat)mcp→applyTo: "**"(VS Code applies the instruction automatically)prompt→mode: ask(appears as a slash-command in chat)agent→mode: agent(runs as an agentic prompt)
Commit the generated files. Copilot in VS Code picks them up from .github/ without any other setup.
Other CLI commands
# List available assets
ai-library list skills
ai-library list agents
ai-library list prompts
ai-library list mcps
# Print a single asset to stdout
ai-library show skill review-node-service
ai-library show agent backend-reviewer
ai-library show prompt code-review
ai-library show mcp postgresThe list and show commands are read-only and work without being inside a project.
Asset format
Every asset is a markdown file with optional YAML frontmatter:
---
name: update-readme
description: Update project README based on source code
tags:
- documentation
---
Body of the asset, written as normal markdown.name— optional. Defaults to the filename (without.md).description— optional single line. Used in the Copilot frontmatter when copying.tags— optional, informational only.
Directory structure
@fmlima4/artificial-intelligence
├── skills/
│ ├── update-readme.md
│ ├── create-pr-description.md
│ └── review-node-service.md
├── agents/
│ ├── backend-reviewer.md
│ ├── security-reviewer.md
│ └── solution-architect.md
├── prompts/
│ ├── feature-design.md
│ ├── bug-investigation.md
│ └── code-review.md
├── mcps/
│ ├── aws.md
│ ├── github.md
│ └── postgres.md
├── src/
│ ├── cli.ts
│ ├── import.ts
│ ├── loader.ts
│ ├── paths.ts
│ └── types.ts
└── test/
└── index.test.tsAdding a new asset
Pick the right folder:
skills/,agents/,prompts/, ormcps/.Create a new file named
<your-asset-name>.md(lowercase, kebab-case).Add YAML frontmatter with at least
nameanddescription.Write the body in plain markdown.
Run the tests:
npm testOpen a PR. No code changes needed — the CLI picks up new files automatically.
Notes
- Install globally on a developer machine; run
ai-library importinside any project. - The CLI reads assets from the npm package directory at runtime, so do not bundle it with webpack/esbuild.
- There is intentionally no remote download, plugin system, or marketplace. Assets are versioned and shipped with the package.
Version and publish pipeline
This repository is configured for tag-driven publishing. The recommended flow uses Changesets; a manual flow with npm version is preserved as a fallback.
Before the first release
- Create an npm publish token in npm.
- Save it in GitHub as the repository secret
NPM_TOKEN. - Confirm that
.github/workflows/publish.ymlis present and configured to publish on pushedv*tags.
Recommended flow with Changesets
Make your code changes on a feature branch.
Run
npm run changesetand describe the change. This creates a file under.changeset/.Commit the changeset file with your code and open a pull request.
After merging to
main, run locally (or via a release workflow):npm run changeset:versionThis updates
package.json,CHANGELOG.mdand removes consumed changesets.Commit those changes and create the matching tag:
git add . git commit -m "Release v$(npm pkg get version | tr -d '\"')" git tag "v$(npm pkg get version | tr -d '\"')" git push git push --tagsThe publish workflow validates that the tag matches
package.json#version, runs the full check suite, runsnpm audit signatures, and publishes to npm with provenance.
Legacy manual flow
Make the code changes for the release.
Update
CHANGELOG.mdwith the user-visible changes included in the release.Review what changed:
git status git diffRun the local validation commands:
npm run check npm pack --dry-runCommit the release changes:
git add . git commit -m "Describe the change"Bump the version with npm. Choose one of:
npm run release:patch npm run release:minor npm run release:majorThese commands update
package.json, create a Git commit, and create a Git tag likev0.1.1.Push the branch and the new tag:
git push git push origin v0.1.3If you prefer, you can also push all tags with:
git push --tagsGitHub Actions runs
.github/workflows/publish.ymlwhen av*tag is pushed.The workflow installs dependencies with
npm ci, validates the tag againstpackage.json#version, runs the full check suite (typecheck, tests, build,publint,@arethetypeswrong/cli,npm audit signatures), and publishes to npm with provenance.
What changes in each version type
patch: bug fixes and small compatible improvements, for example0.1.2->0.1.3minor: new backward-compatible features, for example0.1.2->0.2.0major: breaking changes, for example0.1.2->1.0.0
If npm version fails because of Git signing
If your Git configuration requires GPG or SSH signing and the machine cannot unlock the key, npm version may fail after updating package.json and package-lock.json.
In that case, complete the version step manually:
git add package.json package-lock.json
git -c commit.gpgsign=false commit -m "0.1.3"
git -c tag.gpgSign=false tag v0.1.3After that, continue with the normal push step:
git push
git push origin v0.1.3How to confirm the release worked
- Open the Actions tab in GitHub.
- Check that the
Publish packageworkflow started from the pushed tag. - Confirm the workflow passed the
Install dependencies,Build package, andPublish to npmsteps. - Confirm the new version appears in npm.
If the publish fails
- Read the GitHub Actions log to identify whether the failure happened in install, build, or publish.
- Fix the problem in a new commit.
- Release a new version number instead of trying to reuse the failed one if npm already published it.
Quick checklist for every release
git status
nano CHANGELOG.md
npm run build
npm pack --dry-run
git add .
git commit -m "Describe the change"
npm run release:patch
git push
git push origin v0.1.3GitHub Actions setup
Before the first publish, add this repository secret in GitHub:
NPM_TOKEN: an npm automation token with permission to publish this package
Because this is a scoped package, the workflow publishes with public access enabled.
The publish workflow currently uses Node.js 22 and publishes only when a tag matching v* is pushed.
License
MIT — see LICENSE.
