Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/nozomi-koborinai/firebase-genkit-sample

Firebase and AI Orchestration Samples
https://github.com/nozomi-koborinai/firebase-genkit-sample

Last synced: 1 day ago
JSON representation

Firebase and AI Orchestration Samples

Awesome Lists containing this project

README

        

# firebase-genkit-sample

A sample project demonstrating AI applications using Firebase Cloud Run functions (2nd generation) and Genkit.

## ๐Ÿš€ Features

- Image Analysis (Google AI)
- Web Content Analysis (Google AI)
- Chat Message Generation (Google AI & Firestore)
- Image Generation (Vertex AI)

## ๐Ÿ“ Project Structure

```plain
firebase-genkit-sample/
โ”œโ”€โ”€ .github/
โ”‚ โ””โ”€โ”€ workflows/ # CI/CD Pipelines sample
โ”œโ”€โ”€ prompts/ # AI prompt templates
โ”œโ”€โ”€ src/
โ”‚ โ”œโ”€โ”€ genkit-functions/ # AI function implementations
โ”‚ โ”œโ”€โ”€ genkit.ts # Genkit configuration
โ”‚ โ””โ”€โ”€ index.ts # Deploy Functions
โ””โ”€โ”€ terraform/ # Terraform configuration for infrastructure setup (not directly related to Genkit, but used for setting up the overall Firebase project infrastructure)
```

## ๐Ÿ›  Quick Start

0. Install Genkit CLI

```bash
npm i -g genkit
```

1. Install dependencies

```bash
npm install
```

2. Set environment variables

```bash
export GCLOUD_PROJECT="your-google-cloud-project-id"
export GOOGLE_GENAI_API_KEY="your-api-key"
export GENKIT_ENV="dev"
```

3. Start Genkit emulator for development

```bash
genkit start -- npx tsx --watch src/index.ts
or
genkit start -- firebase emulators:start --inspect-functions
```

4. Deploy to Cloud Run functions (2nd generation)

```bash
firebase deploy --only functions
```

## ๐Ÿ“š Articles

### English

- [Orchestrating Firebase and AI: 8 Genkit Architecture Patterns](https://medium.com/@nozomi-koborinai/orchestrating-firebase-and-ai-8-genkit-architecture-patterns-12e44db40345)
- [How to Develop Firebase Genkit Functions](https://medium.com/@nozomi-koborinai/how-to-develop-firebase-genkit-functions-2677b386a227)
- [Getting Started with AI Image Generation Apps on Flutter, Genkit, and Imagen 3](https://medium.com/@nozomi-koborinai/getting-started-with-ai-image-generation-apps-on-flutter-genkit-and-imagen-3-9a83c63cbdf3)

### Japanese

- [Firebase & AI ใฎใ‚ชใƒผใ‚ฑใ‚นใƒˆใƒฌใƒผใ‚ทใƒงใƒณใ‚’ๅฎŸ็พ๏ผGenkit ใ‚ขใƒผใ‚ญใƒ†ใ‚ฏใƒใƒฃ 8 ้ธ](https://zenn.dev/nozomi_cobo/articles/genkit-architecture)
- [Firebase Genkit Functions ้–‹็™บใฎใ™ใ‚ใ‚](https://zenn.dev/nozomi_cobo/articles/genkit-emulator-suite)
- [Flutter ร— Genkit ร— Imagen 3 ใงๅง‹ใ‚ใ‚‹ AI ็”ปๅƒ็”Ÿๆˆใ‚ขใƒ—ใƒช้–‹็™บๅ…ฅ้–€](https://zenn.dev/nozomi_cobo/articles/flutter-genkit-imagen)