Skip to content

[Bug] URL in message triggers duplicate LLM calls - processed as both text and attachment (webapp) #6486

@thewoweffect

Description

@thewoweffect

Description

When a user sends a message containing a URL, ElizaOS processes it twice:

  1. As text content → generates response
  2. As attachment (metadata/preview) → generates second response

Both responses are sent through the same SSE stream before the done event, resulting in duplicated text in the final response.

Steps to Reproduce

  1. Start ElizaOS with webapp
  2. Send a message containing a URL (e.g., "Check this: https://example.com")
  3. Observe the response

Expected Behavior

URL should be processed once, generating a single response.

Actual Behavior

Two identical (or near-identical) responses are generated and streamed as one message, doubling token usage and producing duplicated output.

Impact

  • 2x LLM API calls per message with URL
  • Doubled token costs
  • Poor UX with duplicated responses
  • Forces workarounds on client side

Environment

  • ElizaOS version: [your version]
  • Client: webapp

Suggested Fix

Ensure URL is processed either as text OR as attachment, not both. The decision should happen in the message processing flow before LLM calls.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions