CopilotKit / CopilotKit/outpost

generateStreamingResponse retrieves docs only, so the streaming path will regress code search

Open
#245 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

area: ai roadmap roadmap: next
Dominant language
TypeScript
Stars
7
Forks
3
Avg merge
7d 16h
Merged PRs (30d)
15

Description

Found by the review of PR #242 (Phase 2, code search).

AIPipeline.generateSupportResponse now retrieves over docs and source. generateStreamingResponse still calls searchDocs only.

So the same question answered on the streaming path gets docs-only retrieval, while the prompt it runs under (GROUNDING_RULES, updated in #242) tells the model that source code may be present and that documentation silence is not evidence a feature is missing. The model is invited to reason about evidence the streaming path never fetched.

Latent rather than live: nothing in production reaches it. handlers/ai-response.ts and apps/web/src/app/api/qa/route.ts both call generateSupportResponse. But it will silently regress the #242 fix the moment anyone streams, and "no production caller" is exactly why the streaming path has drifted before — see #237 (no empty-response guard, raw provider error yielded as content) and #146 (streaming still reads the pre-#143 groundedness signal).

Three issues now describe the same underlying thing: generateStreamingResponse is a second copy of the pipeline that nobody exercises. Worth deciding whether to bring it to parity or delete it until there is a caller, rather than fixing each divergence as it is spotted.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with AIPipeline.generateStreamingResponse and compare it with generateSupportResponse, especially the searchDocs call; review handlers/ai-response.ts, apps/web/src/app/api/qa/route.ts, and PR #242 with issues #237 and #146. Decide whether streaming should be brought to parity or removed while uncalled, then verify the chosen path no longer leaves retrieval and grounding behavior divergent.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
ai, backend-api-design, search
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.