PostHog / PostHog/posthog

feat(phai): Improve SQL table readability in AI Chat

Open
#55,834 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement feature/posthog-ai team/posthog-ai
Dominant language
Python
Stars
39.9k
Forks
3.4k
Avg merge
7h 27m
Merged PRs (30d)
222

Description

Feature request

Is your feature request related to a problem?

Yes. SQL tables rendered in AI Chat are constrained by a relatively narrow max-width container, which makes it difficult to inspect wide result sets or tables with many columns. Users cannot effectively use the available screen space within the AI panel.

This creates friction when reviewing query results and can force users into workarounds, such as creating a new Insight solely to view the table in a larger layout, then deleting it afterward.

Describe the solution you'd like

Add an optional expanded viewing mode for SQL tables shown in AI Chat so users can inspect results in a larger, more usable layout without leaving the conversation.

Potential implementations could include:

  • Expand button that opens the table in a larger modal or drawer
  • Full-panel focused table view
  • Resizable table container
  • Better horizontal scrolling experience for wide tables

The goal is to improve readability and usability while keeping the default chat experience unchanged.

Describe alternatives you've considered

  • Making all SQL tables full width by default. May negatively impact chat readability and consistency.

Additional context

Feedback:

“Really missing the ability to expand the sql tables in the AI chat to fill the full width of the AI panel. Right now it’s quite narrow (a hardcoded max width), and I can only use my available screen estate by creating a new insights that I then have to delete.”

Contributor guide

Open the contributing guide

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

No files, tests, or entry points are named. Start by locating the AI Chat component responsible for rendering SQL tables and review its existing layout and test coverage. Done means an optional expanded viewing mode improves readability while leaving the default chat experience unchanged.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, sql, typescript
Domain
frontend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.