[bot] Google GenAI Batch API (`ai.batches.create()`) not instrumented
メンテナーはふだん 1 日以内に返信
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 48/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- typescript
調査の方向性
js/src/instrumentation/plugins/google-genai-channels.ts にある4つの既存チャンネルから始め、それらが js/src/wrappers/google-genai.ts と google-genai-plugin.ts でどのようにラップされ、処理されているかを追跡します。次に、vendored types、auto-instrumentation config、既存の e2e シナリオを確認します。これらの領域全体でバッチ操作が表現され、結果として得られる計装に対する e2e カバレッジがあれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Summary
The @google/genai SDK's Batch API (ai.batches.create() / client.batches.*) is a documented, GA generative-execution surface for asynchronous, high-throughput generateContent (and embeddings) processing at a 50% cost discount. It is not instrumented anywhere in this repository — no wrapper support, no channel definitions, no plugin, no auto-instrumentation config entry, and no e2e coverage.
What instrumentation is missing
Channels (js/src/instrumentation/plugins/google-genai-channels.ts)
googleGenAIChannels (lines 20–57) defines only four channels: generateContent, generateContentStream, embedContent, and interactionsCreate. There is no batches-related channel.
Wrapper (js/src/wrappers/google-genai.ts)
wrapModels() (lines 118–133) proxies only generateContent, generateContentStream, and embedContent on instance.models. The instance.batches namespace (ai.batches.create(), .get(), .list(), .cancel()) is not proxied at all and passes through completely untraced.
Plugin (js/src/instrumentation/plugins/google-genai-plugin.ts)
Only subscribes to the four existing channels above — no batch handler exists.
Vendored types (js/src/vendor-sdk-types/google-genai.ts)
No type exists for the batches namespace or its request/response/job-status shapes.
Auto-instrumentation config (js/src/auto-instrumentations/configs/google-genai.ts)
No batch-related entry.
e2e coverage (e2e/scenarios/google-genai-instrumentation/)
No batch-related scenario, cassette, or span-tree snapshot among the existing google-genai-v1/v2 (pinned + latest) scenarios.
Upstream operations not instrumented
ai.batches.create({ model, src, config })— submit a batch job (file-based or inline requests) forgenerateContentai.batches.create_embeddings(...)— submit a batch job for embeddingsai.batches.get(name)— poll job status (JOB_STATE_SUCCEEDED, etc.)ai.batches.list()— list batch jobsai.batches.cancel(name)— cancel a batch job
Braintrust docs status
not_found. The Braintrust Gemini integration guide (https://www.braintrust.dev/docs/integrations/ai-providers/gemini) documents generateContent/generateContentStream, embedContent, grounding metadata, generate_images (Python only), and interactions/Live API (Python only) — but does not mention batch processing anywhere.
Upstream references
- Gemini API Batch Mode guide: https://ai.google.dev/gemini-api/docs/batch-mode
- Gemini API Batch API reference: https://ai.google.dev/gemini-api/docs/batch-api
@google/genainpm package: https://www.npmjs.com/package/@google/genai- SDK source: https://github.com/googleapis/js-genai
Braintrust docs sources checked
Local files inspected
js/src/instrumentation/plugins/google-genai-channels.ts(full file — only 4 channels defined, no batches)js/src/instrumentation/plugins/google-genai-plugin.ts(subscribes only to the 4 existing channels)js/src/wrappers/google-genai.ts(full file —wrapModels()proxies onlygenerateContent/generateContentStream/embedContent;instance.batchesuntouched)js/src/vendor-sdk-types/google-genai.ts(no batches type)js/src/auto-instrumentations/configs/google-genai.ts(no batches entry)e2e/scenarios/google-genai-instrumentation/(full directory listing — no batch scenario/cassette/snapshot)- Repo-wide case-insensitive grep for
batchunderjs/src— zero matches related to Google GenAI
- 主要言語
- TypeScript
- スター
- 29
- フォーク
- 18
- 平均マージ
- 1日 15時間
- マージ済み PR(30日)
- 69
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートなし
- コントリビューションガイドなし
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
braintrustdata/braintrust-sdk-javascript のほかの issue
-
High TypeScript checking cost from generated Zod 3 schemas対応中かも @lforst が 3 日前に担当しました。 オープン
難易度 4/5 3〜5日 初心者へのやさしさ 22/100
braintrustdata/braintrust-sdk-javascript#2624 · コメント 1 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
[bot] Instrument Luma AI (17,324 weekly downloads)対応中かも @karthiksenv が 3 日前に担当しました。 オープンtypescript
難易度 4/5 3〜5日 初心者へのやさしさ 55/100
braintrustdata/braintrust-sdk-javascript#2578 ·
メンテナーはふだん 1 日以内に返信
-
[bot] Instrument Letta Agent SDK (87,205 weekly downloads)対応中かも @karthiksenv が 6 日前に担当しました。 オープンtypescript
難易度 4/5 3〜5日 初心者へのやさしさ 55/100
braintrustdata/braintrust-sdk-javascript#2577 ·
メンテナーはふだん 1 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 55/100
braintrustdata/braintrust-sdk-javascript#2527 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 65/100
braintrustdata/braintrust-sdk-javascript#2526 ·
メンテナーはふだん 1 日以内に返信
braintrustdata/braintrust-sdk-javascript の issue をすべて見る
似ている issue
-
Unsampled pageload span is profiled when profileLifecycle is 'trace' (browser UI profiling)対応中かも @Jxxunnn が今日担当しました。 オープンBrowser Waiting for: Product Owner
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
getsentry/sentry-javascript#25497 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
e2e-failure ready-to-code
難易度 2/5 1〜3時間 初心者へのやさしさ 77/100
redhat-developer/rhdh-plugin-export-overlays#4438 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
resource: destroying a resource calls AbortController.abort() without a reason, creating an AbortError with a stack trace each time対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープンarea: core
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
angular/angular#71422 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
bug status: needs triage
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
facebook/docusaurus#12739 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
factory-active task-identify-harness-labels-done task-identify-issue-type-done
難易度 1/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 1 日以内に返信