Skip to content

fix(ui): attached documents don't reach a Hub-installed flagship agent #4166

Description

@kovtcharov

Attach a document to a chat session and ask about it, and a Hub-installed flagship agent answers as if the file were not there. The agent never sees it.

The Agent UI relays a sidecar turn over the agent's /query contract, and that request body carries the transcript and the session id but not the session's attached file paths. An in-process agent gets them through its constructor, so the same session behaves differently depending only on whether the agent was installed as a wheel or as a Hub binary.

Pre-existing for any binary install, but #4165 is what makes the path reachable for the flagship, so it will start being hit. Noted in a comment at the relay call site in _dispatch_sidecar_query.

Fixing it needs a decision first: whether the host sends paths the sidecar then indexes itself, or whether indexing stays host-side and the sidecar receives retrieved context. The second keeps the sidecar free of filesystem access it otherwise does not need.

Test plan

  • Attach a PDF to a session and ask a question only answerable from it, against a binary-installed flagship
  • Same session, same question, against a wheel install — the answers should not differ

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent-uiAgent UI changesbugSomething isn't workingp2low priority

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions