stablyai / stablyai/orca

[Feature]: Add highlighted selections to Chat UI as chips (editor, markdown, terminal)

Open
#16,640 1 comment 2 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
69.7k
Forks
4.5k
Avg merge
15h 28m
Merged PRs (30d)
471

Description

### Problem or use case

Coming from Cursor, the daily loop is: highlight a few lines, add them to chat, keep typing. The composer stays small. The agent still sees the exact range.

In Orca I can `@` files, drag paths, paste images, and Copy Context. Those still dump or hide the thing I pointed at:

1. A terminal highlight becomes a blob of text (or a clipboard dump), not “this pane, these lines.”
2. The raw agent terminal does not show stacked screenshot thumbnails, so two or three images are easy to lose.
3. File and markdown highlights have no “add this range” — only the whole file, a review note, or a paste.

That makes Chat UI feel like a TTY with extra chrome instead of a place I can point from.

### Proposed solution

A bindable **Add to chat** action (editor, rich/raw markdown, terminal selection) that appends a **removable chip** on the active Chat UI composer:

| Source | Chip label | Agent payload |
| --- | --- | --- |
| File / Monaco | `path:start–end` | Those lines + path |
| Markdown | same, from the source range | Same |
| Terminal | pane title + line range | Highlighted scrollback only |

Images (paste, drop, attach) stay **thumbnail chips**, multiple, removable, visible in the composer and in the sent bubble. Do not inline the selection into the textarea.

Reuse today’s native-chat attach/ride-along path so the PTY still gets the content on send. Terminal-only sessions can keep pasting paths; this is for Chat UI.

### Alternatives or additional context

Workarounds today: Copy Context, paste, `@file`, markdown review notes → Send to agent, Design Mode for the browser.

Related, not the same:

- #14881 — agent reading a whole terminal tab
- #12572 — remote-server drag/paste into the composer

Contributor guide

Open the contributing guide

Research direction

Start at the Chat UI composer and the existing native-chat attach/ride-along path described in the issue, then trace how editor, markdown, terminal selections, and images reach the composer and sent bubble. Done means removable range chips and visible thumbnail chips work for the listed sources without inlining selections into the textarea, while terminal content still reaches the PTY on send.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
cli, frontend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.