Skip to content

[Bug]: Report Generation Fails Due to Token Limit Exceeded (Gemini Free Tier) #138

@oushiei120

Description

@oushiei120

Bug Description

When generating the final report in deep-research with a substantial research corpus, all research content is sent as context in a single request to the LLM (e.g., Gemini 2.5 Pro). However, the free tier has a strict token limit (such as 250k TPM for Gemini 2.5 Pro), which frequently leads to failures or empty reports when the content is too lengthy.

Environment:

  • Deployment Method: Docker
  • OS: macOS

Steps to Reproduce

Steps to Reproduce:

  1. Proceed through the workflow to the final report generation step.
  2. Ensure the research content is sufficiently large.
  3. Attempt to generate the report and observe the result—typically an empty report or request failure.

Expected Behavior

Ideally, the system would either warn the user when the context exceeds the token limit, or automatically split the report generation into several API calls to accommodate the restriction.
It would be very helpful if future versions could support a warning when the context is about to exceed the token limit, or automatically divide the report into multiple API requests.

Screenshots

No response

Deployment Method

  • Docker
  • Vercel
  • Server

Desktop OS

macos

Desktop Browser

No response

Desktop Browser Version

No response

Smartphone Device

No response

Smartphone OS

No response

Smartphone Browser

No response

Smartphone Browser Version

No response

Additional Logs

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions