kai_engine_firebase_ai 0.1.0 copy "kai_engine_firebase_ai: ^0.1.0" to clipboard
kai_engine_firebase_ai: ^0.1.0 copied to clipboard

A Firebase AI adapter for the Kai Engine.

Kai Engine Firebase AI Adapter #

GitHub

A Firebase AI adapter for the Kai Engine.

Overview #

This package provides a Firebase AI integration for the Kai Engine, allowing you to easily use Firebase's AI services with the Kai Engine's pipeline architecture.

Features #

  • Seamless integration with Firebase AI services
  • Implements the GenerationServiceBase interface from Kai Engine
  • Supports streaming responses from Firebase AI
  • Handles authentication and error management
  • Type-safe API interactions

Getting Started #

Add the dependency to your pubspec.yaml:

dependencies:
  kai_engine_firebase_ai:
    git:
      url: https://github.com/pckimlong/kai_engine.git
      ref: main
      path: packages/kai_engine_firebase_ai

Usage #

import 'package:kai_engine/kai_engine.dart';
import 'package:kai_engine_firebase_ai/kai_engine_firebase_ai.dart';

// Create the Firebase AI generation service
final generationService = FirebaseAIGenerationService(
  // Configure your Firebase AI settings
  model: 'gemini-pro',
  apiKey: 'your-api-key',
);

// Create your chat controller with the Firebase AI service
final chatController = MyChatController(
  conversationManager: conversationManager,
  generationService: generationService,
  queryEngine: queryEngine,
  postResponseEngine: postResponseEngine,
  messageAdapter: messageAdapter,
);

Documentation #

For complete documentation, see the Kai Engine documentation.

Contributing #

Contributions are welcome! Please read our Contributing Guide for details on how to submit pull requests, report issues, or request features.

License #

This project is licensed under the MIT License - see the LICENSE file for details.