JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 13
  • Score
    100M100P100Q49579F
  • License ISC

Genkit plugin for Hugging Face models

Package Exports

  • genkit-huggingface
  • genkit-huggingface/dist/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (genkit-huggingface) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Firebase Genkit Community Plugin

Community Plugin for Google Firebase Genkit


Built by Acies Crest ❤️

Hugging Face Genkit Plugin

This plugin integrates Hugging Face's Inference API into Genkit, allowing you to leverage Hugging Face models within the Genkit ecosystem.

Installation

To install the library, use npm:

npm install genkit-huggingface

Usage

Here is a simple example of how to use the genkit-huggingface library in your project:

import { genkit } from 'genkit';
import { huggingface } from 'genkit-huggingface';

const ai = genkit({
  plugins: [
    huggingface({
      apiKey: process.env.HUGGING_FACE_API_KEY,
      defaultModel: 'Qwen/Qwen2.5-Coder-32B-Instruct' // Or any other Hugging Face model name
    })
  ]
});

// Use the model
const response = await ai.generate({ model: 'huggingface-model', prompt: "Hello, how are you?" });
console.log(response);

License

This project is licensed under the MIT License.

Contributing

Contributions are welcome! Please open an issue or submit a pull request.

Contact

For any questions or issues, please open an issue on this repository.