[Feat] Allow the agent to send input to a running background terminal (send_to_terminal)

オープン
#512 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 2 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
48/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
活発
技術スタック
java

調査の方向性

Start by locating IRunInTerminalTool and RunInTerminalTool.executeCommand(); the issue identifies these entry points and notes that sendCommand() already uses ITerminalViewControl.pasteString(). Trace how background terminals are opened and how get_terminal_output selects a terminal, then determine how input should target the running process. Done means the agent can send abc to a background interactive terminal and receive got: abc.

索引モデルが issue の本文から書いたものです。

説明

enhancement

Problem
The copilot agent can start a long-running interactive process with
run_in_terminal (isBackground=true) and read it with get_terminal_output,
but it cannot send further input to that process. Interactive CLIs (debugger
consoles, serial monitors) therefore cannot be driven step by step:
the model has to pre-script all input (stdin pipe + sleeps) and cannot react
to intermediate replies.

Evidence (0.21.0)

  • IRunInTerminalTool only exposes executeCommand, getBackgroundCommandOutput,
    cancelCurrentCommand.
  • RunInTerminalTool.executeCommand() opens a new Copilot-<id> terminal per
    background call; a new foreground call first runs
    closeRunningForegroundTerminal(...).
  • Internally sendCommand() already uses ITerminalViewControl.pasteString().

Repro

  1. Ask the agent to run in background:
    powershell -NoProfile -Command 'while ($true) { $l = Read-Host ''input''; Write-Output (''got: '' + $l) }'
  2. Ask it to send abc to that terminal and show got: abc.

Observed
Eclipse Copilot: the agent can't type into the running terminal. It ends up writing one script that pipes all input with sleeps and only sees the output at the end.
VS Code Copilot: send_to_terminal works, I get got: abc back.

主要言語
Java
スター
129
フォーク
70
平均マージ
3日 2時間
マージ済み PR(30日)
15

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

microsoft/copilot-for-eclipse のほかの issue

microsoft/copilot-for-eclipse の issue をすべて見る

似ている issue

Java の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。