Skip to main content

A Python module to process bulk data using Google's generative AI (Gemini).

Project description

GeminiDataProcessor

Overview

GeminiDataProcessor is a Python library that streamlines data processing through the use of Google's generative AI models (Gemini). It allows users to generate structured responses for tabular datasets using customizable prompts and schemas.

Features

  • Integration with Gemini AI: Process data through Google's generative AI models.
  • Asynchronous Processing: Supports efficient handling of large datasets using asyncio.
  • Flexible Schema: Define custom output schemas for structured JSON responses.
  • Error Handling: Robust error management for API and data parsing issues.
  • Progress Tracking: Real-time processing feedback with tqdm.

Installation

You can install the module using pip:

pip install gemini_data_processor
from gemini_batch_processor import GeminiBot

bot = GeminiBot(
    input_file="input_data.csv",
    prompt_template="Generate a summary for: {row[column name]}",
    key_names="summary,details",
    api_key="your_google_api_key",
    model="gemini-1.5-flash-002"
)
from gemini_batch_processor import GeminiBot
GeminiBot.model_list(api_key="your_api_key")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gemini_batch_processor-1.0.1.tar.gz (5.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gemini_batch_processor-1.0.1-py3-none-any.whl (5.7 kB view details)

Uploaded Python 3

File details

Details for the file gemini_batch_processor-1.0.1.tar.gz.

File metadata

  • Download URL: gemini_batch_processor-1.0.1.tar.gz
  • Upload date:
  • Size: 5.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for gemini_batch_processor-1.0.1.tar.gz
Algorithm Hash digest
SHA256 9685a650e69d5c1799da4b8d970654d465f49efcb7a51138ef71a791a66393db
MD5 5f24346832cace132ff21f002e6b46b4
BLAKE2b-256 231d437e4cc16cb9e3f348b7b6bae9c18b3966cf57fd121afa5e4958909288f6

See more details on using hashes here.

File details

Details for the file gemini_batch_processor-1.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for gemini_batch_processor-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 7fce6d257dcb05491e0c45cd9c6eeed164183fc6bbdae5ee1b60180d478a9b56
MD5 459821423c0d752249926e12fd11f085
BLAKE2b-256 877338cab0f6712b49921c103afb680ae1f2254ba3903cfe5e364e9566678420

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page