Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Instrument LangGraph Platform thread-controller execution

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

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

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
28/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
活発
技術スタック
typescript

調査の方向性

runs.wait と runs.stream の既存のインストルメンテーションから始め、次にコントローラーのエントリポイントである client.threads.stream(...), thread.run.start(options), thread.input.respond(...)、および client.threads.joinStream(...) を調査します。要求された real-SDK のエンドツーエンドケースを最初のテスト対象として使用します。完了の条件は、サポート対象の API と span のライフタイムが文書化され、すべての受け入れシナリオに合格し、反復、同時実行、ラップ、自動、無効の各モードでアプリケーションの動作が維持されることです。

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

説明

Follow-up to https://github.com/braintrustdata/braintrust-sdk-javascript/issues/2199.

Thread-controller execution was explicitly deferred from #2199. The current implementation intentionally instruments only runs.wait and runs.stream, where execution and result consumption belong to one call.

Scope

Add instrumentation for the controller returned by client.threads.stream(...), starting with thread.run.start(options). Evaluate continuation and reattachment APIs, including thread.input.respond(...) and client.threads.joinStream(...), and explicitly document which are supported.

Controller construction does not execute an agent. A run.start() acknowledgement can arrive before execution completes, so tracing must distinguish controller setup, submission, and the run's actual lifecycle.

Implementation considerations

  • In the inspected SDK versions (1.9.25 and 1.10.2), a controller's output promise is cached across runs. Do not let a previous run's settled promise prematurely finish a later run's span.
  • Prefer public lifecycle observations and normal typed-channel instrumentation. Avoid opening extra subscriptions or consuming streams solely for tracing when existing events suffice.
  • Define correlation when a controller observes an execution started elsewhere, as well as behavior across reconnection and repeated runs.
  • Keep remote model/tool internals distinct from client-side execution observations; do not invent spans for unobserved work.

Acceptance criteria

  • Provide automatic and explicit instrumentation with shared extraction logic and stable task-span names.
  • Capture each supported run's input, final state, errors, available usage, and streaming timing; use allowlisted metadata.
  • End spans correctly on completion, failure, interruption, and controller closure. Preserve cancellation, promise/controller identity, and private-field receivers.
  • Ensure repeated runs, teardown/re-enabling, and wrapper-plus-hook usage do not duplicate spans, mix contexts, leak listeners, or change application behavior.
  • Add real-SDK e2e tests for multiple runs on one controller, independent concurrent controllers, acknowledgement before completion, failures, interruptions, closure, and supported continuation/reattachment behavior.
  • Cover pinned and separately named latest SDK aliases, ESM/CommonJS, and wrapped/automatic/combined/disabled modes. Assert paired span-tree snapshots, update the CI summary, and verify three consecutive replay runs.
  • Document the supported controller APIs and span lifetimes.
主要言語
TypeScript
スター
27
フォーク
13
平均マージ
2日 20時間
マージ済み PR(30日)
66

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

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

braintrustdata/braintrust-sdk-javascript のほかの issue

braintrustdata/braintrust-sdk-javascript の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

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

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