{"id":26657037,"url":"https://github.com/xavidop/genkitx-voiceflow","last_synced_at":"2025-08-20T23:05:49.321Z","repository":{"id":283715742,"uuid":"952723341","full_name":"xavidop/genkitx-voiceflow","owner":"xavidop","description":"Community Plugin for Genkit to use Voiceflow","archived":false,"fork":false,"pushed_at":"2025-08-19T21:40:30.000Z","size":989,"stargazers_count":4,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-19T23:29:24.121Z","etag":null,"topics":["firebase","firebase-genkit","gen-ai","generative-ai","genkit-plugin","genkit-retriever","genkitx","plugin"],"latest_commit_sha":null,"homepage":"https://xavidop.github.io/genkitx-voiceflow/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/xavidop.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":"xavidop","patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"lfx_crowdfunding":null,"polar":null,"buy_me_a_coffee":null,"thanks_dev":null,"custom":null}},"created_at":"2025-03-21T19:07:12.000Z","updated_at":"2025-08-19T21:40:27.000Z","dependencies_parsed_at":"2025-03-21T19:21:28.991Z","dependency_job_id":"d5276dc1-7ef6-47a4-8fb8-114512cc64dd","html_url":"https://github.com/xavidop/genkitx-voiceflow","commit_stats":null,"previous_names":["xavidop/genkitx-voiceflow"],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/xavidop/genkitx-voiceflow","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xavidop%2Fgenkitx-voiceflow","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xavidop%2Fgenkitx-voiceflow/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xavidop%2Fgenkitx-voiceflow/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xavidop%2Fgenkitx-voiceflow/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xavidop","download_url":"https://codeload.github.com/xavidop/genkitx-voiceflow/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xavidop%2Fgenkitx-voiceflow/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271241695,"owners_count":24724969,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-19T02:00:09.176Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["firebase","firebase-genkit","gen-ai","generative-ai","genkit-plugin","genkit-retriever","genkitx","plugin"],"created_at":"2025-03-25T08:16:40.334Z","updated_at":"2025-08-20T23:05:49.299Z","avatar_url":"https://github.com/xavidop.png","language":"TypeScript","funding_links":["https://github.com/sponsors/xavidop"],"categories":["Plugins"],"sub_categories":["JavaScript - Community"],"readme":"![Firebase Genkit + Voiceflow](https://github.com/xavidop/genkitx-voiceflow/blob/main/assets/genkit-voiceflow.png?raw=true)\n\n\u003ch1 align=\"center\"\u003e\n   Firebase Genkit \u003c\u003e Voiceflow Plugin\n\u003c/h1\u003e\n\n\u003ch4 align=\"center\"\u003eVoiceflow Community Plugin for Google Firebase Genkit\u003c/h4\u003e\n\n\u003cdiv align=\"center\"\u003e\n   \u003cimg alt=\"GitHub version\" src=\"https://img.shields.io/github/v/release/xavidop/genkitx-voiceflow\"\u003e\n   \u003cimg alt=\"NPM Downloads\" src=\"https://img.shields.io/npm/dw/genkitx-voiceflow\"\u003e\n   \u003cimg alt=\"GitHub License\" src=\"https://img.shields.io/github/license/xavidop/genkitx-voiceflow\"\u003e\n   \u003cimg alt=\"Static Badge\" src=\"https://img.shields.io/badge/yes-a?label=maintained\"\u003e\n\u003c/div\u003e\n\n\u003cdiv align=\"center\"\u003e\n   \u003cimg alt=\"GitHub Issues or Pull Requests\" src=\"https://img.shields.io/github/issues/xavidop/genkitx-voiceflow?color=blue\"\u003e\n   \u003cimg alt=\"GitHub Issues or Pull Requests\" src=\"https://img.shields.io/github/issues-pr/xavidop/genkitx-voiceflow?color=blue\"\u003e\n   \u003cimg alt=\"GitHub commit activity\" src=\"https://img.shields.io/github/commit-activity/m/xavidop/genkitx-voiceflow\"\u003e\n\u003c/div\u003e\n\n\u003c/br\u003e\n\n**`genkitx-voiceflow`** is a community plugin for using Voiceflow Knowledge base in\n[Firebase Genkit](https://github.com/firebase/genkit). Built by [**Xavier Portilla Edo**](https://github.com/xavidop).\n\n\u003c!-- TOC --\u003e\n\n- [Installation](#installation)\n- [Configuration](#configuration)\n- [Usage](#usage)\n  - [Indexer](#indexer)\n    - [Basic examples](#basic-examples)\n    - [Within a flow](#within-a-flow)\n  - [Retriever](#retriever)\n    - [Basic examples](#basic-examples-1)\n    - [Within a flow](#within-a-flow-1)\n- [Examples](#examples)\n- [Feature supported from Voiceflow Knowledge Base](#feature-supported-from-voiceflow-knowledge-base)\n- [API Reference](#api-reference)\n- [Contributing](#contributing)\n- [Need support?](#need-support)\n- [Credits](#credits)\n- [License](#license)\n\n\u003c!-- /TOC --\u003e\n\n## Installation\n\nInstall the plugin in your project with your favorite package manager:\n\n- `npm install genkitx-voiceflow`\n- `pnpm add genkitx-voiceflow`\n\n## Configuration\n\nTo use the plugin, you need to configure it with your Voiceflow API key. You can do this by calling the `genkit` function:\n\n```typescript\nimport { genkit, z } from 'genkit';\nimport {github, openAIGpt4o} from \"genkitx-voiceflow\";\n\nconst ai = genkit({\n  plugins: [\n    openAI({ apiKey: process.env.OPENAI_API_KEY }),\n    voiceflow([\n      {\n        name: 'kb',\n        clientParams: {\n          apiKey: process.env.VOICEFLOW_API_KEY!,\n        }\n      },\n    ])\n  ],\n});\n```\n\n## Usage\n\nThe plugin provides two main functionalities: `index` and `retrieve`. You can use them directly or within a Genkit flow.\n\n### Indexer\n\nIndexer is used to index documents in the Voiceflow Knowledge Base. Voiceflow Knowledge Base only works with documents that contain a `media` field with a `url` property. The URL could be a link to a website or to a local file with `file://`.\n\n#### Basic examples\n\nThe simplest way to call the indexer is by using the helper function `index`:\n\n```typescript\nconst voiceflowIndexer = voiceflowIndexerRef({\n  name: 'kb'\n});\n\nconst documents = [{ content: [{ media: { url: 'https://www.voiceflow.com' } }] }];\nawait ai.index({ indexer: voiceflowIndexer, documents });\n```\n\n\n#### Within a flow\n\n```typescript\n// ...configure Genkit (as shown above)...\n\nexport const indexerFlow = ai.defineFlow(\n  {\n    name: 'indexerFlow',\n    inputSchema: z.string(),\n    outputSchema: z.string(),\n  },\n  async () =\u003e {\n\n   const voiceflowIndexer = voiceflowIndexerRef({\n     name: 'kb'\n   });\n\n   const documents = [{ content: [{ media: { url: 'https://www.voiceflow.com' } }] }];\n   await ai.index({ indexer: voiceflowIndexer, documents });\n\n   return 'done';\n   \n  }\n);\n```\n\n\n### Retriever\n\nA retriever is used to retrieve documents from the Voiceflow Knowledge Base. You can pass a query and options to the retriever. The options object can contain the following properties:\n1. `querySettings`: An object with the following properties:\n   - `model`: The model to use for the query. The default is `gpt-4o`.\n   - `temperature`: The temperature to use for the query. The default is `0.7`.\n   - `system`: The system prompt to use for the query. The default is `''`.\n2. `k`: The number of documents to retrieve. The default is `5`.\n3. `filters`: filters to apply to the query. The default is `[]`.\n\n#### Basic examples\n\nThe simplest way to call the retriever is by using the helper function `retrieve`:\n\n```typescript\nconst voiceflowRetriever = voiceflowRetrieverRef({\n  name: 'retriever'\n});\n\nconst docs = await ai.retrieve({ retriever: voiceflowRetriever, query: subject, \noptions:{\n  querySettings: { model: 'gpt-4o', temperature: 0.7 },\n  k: 5\n}});\n```\n\n#### Within a flow\n\n```typescript\n// ...configure Genkit (as shown above)...\n\nexport const retrieverFlow = ai.defineFlow(\n  {\n    name: 'retrieverFlow',\n    inputSchema: z.string(),\n    outputSchema: z.string(),\n  },\n  async (subject) =\u003e {\n\n   const voiceflowRetriever = voiceflowRetrieverRef({\n     name: 'retriever'\n   });\n\n   const docs = await ai.retrieve({ retriever: voiceflowRetriever, query: subject, \n    options:{\n     querySettings: { model: 'gpt-4o', temperature: 0.7 },\n     k: 5\n   }});\n   \n   const llmResponse = await ai.generate({\n      prompt: `What is Voiceflow?`,\n      docs: docs,\n    });\n    return llmResponse.text;\n  }\n);\n```\n\nFor more detailed examples and the explanation of other functionalities, refer to the [official Genkit documentation](https://firebase.google.com/docs/genkit/get-started).\n\n## Examples\n\nYou can find more examples in the [examples](https://github.com/xavidop/genkitx-voiceflow/blob/main/examples/) folder.\n\n## Feature supported from Voiceflow Knowledge Base\n\nThis plugins supports all the features supported by the Vocieflow Knowledge Base API. You can find the full list of features in the [Voiceflow Knowledge Base API Reference](https://docs.voiceflow.com/reference/post_knowledge-base-query-1).\n\n## API Reference\n\nYou can find the full API reference in the [API Reference Documentation](https://xavidop.github.io/genkitx-voiceflow/)\n\n## Contributing\n\nWant to contribute to the project? That's awesome! Head over to our [Contribution Guidelines](https://github.com/xavidop/genkitx-voiceflow/blob/main/CONTRIBUTING.md).\n\n## Need support?\n\n\u003e [!NOTE]  \n\u003e This repository depends on Google's Firebase Genkit. For issues and questions related to Genkit, please refer to instructions available in [Genkit's repository](https://github.com/firebase/genkit).\n\nReach out by opening a discussion on [GitHub Discussions](https://github.com/xavidop/genkitx-voiceflow/discussions).\n\n## Credits\n\nThis plugin is proudly maintained by Xavier Portilla Edo [**Xavier Portilla Edo**](https://github.com/xavidop).\n\n## License\n\nThis project is licensed under the [Apache 2.0 License](https://github.com/xavidop/genkitx-voiceflow/blob/main/LICENSE).\n\n[![License: Apache 2.0](https://img.shields.io/badge/License-Apache%202%2E0-lightgrey.svg)](https://github.com/xavidop/genkitx-voiceflow/blob/main/LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxavidop%2Fgenkitx-voiceflow","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxavidop%2Fgenkitx-voiceflow","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxavidop%2Fgenkitx-voiceflow/lists"}