Introducing Agents.js: Give tools to your LLMs using JavaScript

Practical AI: Tools, Models & Frameworks

What changed

Getting started is very easy, you can grab the library from npm with the following: npm install @huggingface/agents The library exposes the HfAgent object which is the entry point to the library. You can instantiate it like this: import { HfAgent } from "@huggingface/agents"; const HF_ACCESS_TOKEN = "hf_..."; // get your token at https://huggingface.co/settings/tokens const agent = new HfAgent(HF_ACCESS_TOKEN); Afterward, using the agent is easy. You give it a plain-text command and it will return some messages.

Why it matters

A concrete addition to Practical AI: Tools, Models & Frameworks: it changes what's available to builders today rather than being general commentary.

How it compares

Related prior coverage to compare against:

  • Transformers.js v4: Now Available on NPM!
  • Python & JavaScript Libraries
  • Introducing the Open Leaderboard for Japanese LLMs!

Sources