# Gemini Flash Lite Latest (`ilborso/gemini-flash-lite-latest`) Actor

AI text generation directly inside your web scraping and data pipeline workflows. Gemini Flash Lite is engineered for lightning-speed responses, making it the perfect choice for high-volume content generation, text summarization, data extraction, and AI processing tasks.

- **URL**: https://apify.com/ilborso/gemini-flash-lite-latest.md
- **Developed by:** [Fabio Borsotti](https://apify.com/ilborso) (community)
- **Categories:**
- **Stats:** 3 total users, 2 monthly users, 60.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.90 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Gemini Flash Lite — Fast, Cheap & Powerful AI Actor

Unlock ultra-fast, **with upload file support**, high-efficiency AI text generation directly inside your web scraping and data pipeline workflows. **Gemini Flash Lite** is engineered for lightning-speed responses and maximum cost-efficiency, making it the perfect choice for high-volume content generation, text summarization, data extraction, and AI processing tasks.

***

### Why Use Gemini Flash Lite Actor?

- **Blazing Fast Speed**: Powered by Google's lightest and fastest Gemini model, delivering responses in milliseconds. By default, the Actor uses the latest Gemini Flash-Lite model (`gemini-2.5-flash`).
- **Ultra Cost-Effective**: Drastically lower API overhead compared to standard LLMs while maintaining impressive reasoning capabilities.
- **Multimodal Support**: Attach images, documents, PDFs, or audio files directly alongside your prompt text.
- **Instant Integration**: Effortlessly connect with webhooks, Apify API, Make, Zapier, Python, Node.js, and custom data scraping pipelines.
- **Production Ready & Reliable**: Built-in error handling and fallback mechanisms to ensure 99.9% pipeline stability.
- **Zero Overhead**: Pass your query and optional file attachments, receive clean AI output directly in your dataset.

***

### Popular Use Cases

- **SEO & Content Generation**: Create meta descriptions, titles, outline summaries, and optimized content snippets at scale.
- **Web Scraping Enrichment**: Summarize scraped articles, clean raw web text, or reformat unstructured data on the fly.
- **Multimodal Document & Image Analysis**: Extract text, analyze charts, inspect screenshots, and process attached PDFs directly.
- **Sentiment & Entity Extraction**: Analyze user feedback, product reviews, and social posts rapidly.
- **Data Translation & Formatting**: Convert raw text into structured formats, bullet points, or multiple target languages.
- **Automation Workflows**: Integrate seamless AI decision-making into no-code or low-code automation tools.

***

### Actor Input

The Actor accepts a lightweight JSON input with your search query or prompt text and optional file attachments:

| Field | Type | Required | Default | Description |
| :--- | :--- | :---: | :--- | :--- |
| `q` | `string` | **Yes** | — | The search query, text prompt, or instruction to process with Google Gemini. |
| `attachments` | `array` | No | `[]` | List of file URLs (images, PDFs, audio, documents), Data URIs, or Base64 strings to analyze. |

#### Example Input

```json
{
  "attachments": [
    "https://raw.githubusercontent.com/ilborso/resources/1f4ce917216ab8b2717aca24b06265e4a8d53f82/Pensione.pdf",
    "https://raw.githubusercontent.com/ilborso/resources/f9b9367ed5032427c1f86ca6351dc21ee5e5476e/Storia.pdf"
  ],
  "q": "summarize the attached documents"
}
```

#### Example output

```json
[
  {
    "q": "summarize the attached documents",
    "response": "Here is a summary of the two attached documents, which cover completely different topics: an article on current economic/social security affairs and a short story.\n\n---\n\n### Document 1: Early retirement proposal (newspaper article)\nThe article, titled *\"Claudio Durigon: 'Severance pay (Tfr) as an annuity to retire at 64...'\"*, analyzes the proposal put forward by the League ahead of the Budget Law:\n\n* **Scope of the measure:** The goal is to extend the possibility of early retirement at **64 years of age** to workers in the mixed system (those who started working before January 1, 1996), who were previously excluded and limited only to \"pure contributory\" workers.\n* **The conditions:** The exit would be voluntary (with at least 25 years of contributions), but would require:\n  1. A fully contributory recalculation of the entire pension (including the portion accrued before 1996), with an estimated resulting reduction of around 10.6% (a permanent loss of between 183 and 366 gross euros per month).\n  2. The use of a portion of the **severance pay (Tfr)** to reach the minimum required amount threshold (equal to at least three times the social allowance).\n* **The increase in thresholds:** The increases in the minimum threshold required to access retirement at 64 over the years are highlighted: from 1,310.68 euros per month in 2022 to 1,638.72 euros in 2026, up to an estimated 1,818.94 euros for 2030, with a consequent increase in the necessary contributory capital and gross salaries.\n\n---\n\n### Document 2: \"The Last Lighthouse of North Cape\" (short story)\nThe story narrates the last night of work for Samuel, the elderly keeper of a lighthouse that is about to be fully automated:\n\n* **The context:** It is New Year's Eve, and the next day Samuel will have to leave the island because a computer will take control of the lighthouse after 40 years of honorable service.\n* **The blackout and emergency:** During a violent storm, the main generator fails due to a short circuit, leaving the lighthouse in darkness just as a struggling fishing boat risks crashing into the rocks.\n* **The heroic act:** Despite the automatic system not being active, Samuel does not lose heart: he climbs the stairs, lights an old kerosene lamp, and manually cranks the Fresnel lens for hours, saving the boat.\n* **The conclusion:** At dawn, technicians arrive to install the computers. The boss recognizes the value and the \"soul\" that Samuel put into his work that night. Samuel smiles, bids farewell to the lighthouse, and leaves, leaving behind forty years of light and saved lives."
  }
]
```

#### Multimodal Attachments Details (`attachments`)

The `attachments` array empowers Gemini with multimodal intelligence by accepting files directly in your pipeline.

**Supported Input Formats**:

1. **Direct File URLs**: Any publicly accessible HTTP/HTTPS link to an image, document, or media file (e.g. `https://example.com/report.pdf`).
2. **Data URIs**: Base64 data with MIME type header (e.g. `data:image/png;base64,iVBORw0...`).
3. **Raw Base64 Strings**: Pure Base64 encoded string payload of the file.

**Supported File Formats**:

- **Images**: PNG, JPEG, WEBP, HEIC, HEIF
- **Documents**: PDF, TXT, HTML, CSV, RTF
- **Audio & Video**: MP3, WAV, AAC, FLAC, MP4, MOV, AVI

***

### Actor Output

The Actor saves the generated response into your Apify Dataset under the `response` field:

| Field | Type | Description |
| :--- | :--- | :--- |
| `response` | `string` | The complete text response generated by Google Gemini Flash Lite. |

**Run the Actor**: Pass your search prompt `q` and optional `attachments` array to get instant AI-generated results!

# Actor input Schema

## `q` (type: `string`):

The search query, text prompt, or content to process with Google Gemini.

## `attachments` (type: `array`):

List of file URLs (images, PDFs, audio, documents), Data URIs, or Base64 strings to send to Gemini alongside your prompt.

## Actor input object example

```json
{
  "q": "Hi Gemini, say hello!"
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "q": "Hi Gemini, say hello!"
};

// Run the Actor and wait for it to finish
const run = await client.actor("ilborso/gemini-flash-lite-latest").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "q": "Hi Gemini, say hello!" }

# Run the Actor and wait for it to finish
run = client.actor("ilborso/gemini-flash-lite-latest").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "q": "Hi Gemini, say hello!"
}' |
apify call ilborso/gemini-flash-lite-latest --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,ilborso/gemini-flash-lite-latest"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/cDLGZTEQ3xyL99WTY/builds/avrx1zGYPaXWS06BK/openapi.json
