LangChain、エージェントファーストのデータスタック構築手法を公開
LangChain は従来の BI ツール中心のデータスタックからエージェントファーストな構成へ移行し、3 人のチームで処理していたリクエストを約 40 倍に増やして自己分析を実現した。
AI深層分析を開く2026年7月28日 22:34
AI深層分析
キーポイント
エージェントファーストへのアーキテクチャ転換
従来の BI ツール中心のスタックから、明確なモデル定義、メトリクス、ビジネス文脈を備えたエージェント対応型スタックへ移行した。
自己分析能力の劇的な拡大
データエージェントが約 40 倍のリクエスト処理能力を持ち、30 日間で全社員の 1/3 が利用し、月間平均 23 件の対話を記録した。
データチームの役割変化
個別の質問への回答から、モデル構築、コンテキスト整備、ガードレール設計などシステム全体の改善へと役割がシフトした。
重要な引用
Reliable data agents need more than access to tables. They need clear models, metric definitions, business context, and signals about which sources to trust.
Our self-serve data agent now handles ~40x the volume of requests our 3-person data team could field directly.
The data team now focuses on building the models, context, guardrails, and feedback loops that help make agent answers more useful over time.
編集コメントを表示
編集コメント
この事例は、LLM エージェントを単なるクエリ生成ツールとしてではなく、ビジネス文脈を理解するシステムとして再構築した点で示唆に富む。従来の BI ツールでは不可能だった柔軟な分析を実現するために、データチームがインフラ設計者へと進化している様子が明確である。
Source Article
元記事を日本語で読む
本文に関係しない購読案内、埋め込み通知、サイト内プロモーションは除いています。

重要なポイント
- データエージェントが信頼を得るには、単にテーブルへのアクセス権限があるだけでは不十分です。明確なモデル定義、指標の定義、ビジネスコンテキスト、そしてどのデータソースを信頼すべきかを示すシグナルが必要です。
- エージェントファースト型のスタックを導入することで、セルフサービスの範囲を劇的に拡大できます。現在、当社のデータエージェントが処理しているリクエスト量は、3 人のデータチームが直接対応できる量の約 40 倍に達しています。
- データチームの役割は「あらゆる質問に応えること」から「システム自体を改善すること」へとシフトしました。現在は、モデルやコンテキスト、ガードレール(安全装置)、フィードバックループを整備し、時間とともにエージェントによる回答の有用性を高めることに注力しています。
過去 1 年間、当社のデータチームは、エージェントを支えるためにスタックをどのように進化させるべきかを根本から見直してきました。多くの企業のデータスタックは、ダッシュボードやレポート、SQL ワークフローを中心に構築されています。これらは今でも有用ですが、エージェントの登場によって、データレイヤーが提供するものの質も変わらざるを得ません。
明確な定義、信頼できるソース、ビジネスコンテキスト、そしてデータの背後にあるロジックへのアクセス権があれば、エージェントはより多くの質問に答えることができます。しかし、これらの文脈が欠如していると、SQL を生成することはできても、その回答を信頼するのは難しくなります。企業固有の定義を見落としたり、誤ったテーブルを使用したり、技術的には正しくてもビジネスの実情にはそぐわない回答をしてしまうリスクがあるからです。
私たちは、社内のデータアクセスを容易にすると同時に、エージェントが正確な回答を提供し、その根拠も説明できる十分な文脈を与えられるようにしたいと考えていました。
そこで、従来の BI ツール中心のデータスタックから、セルフサービス分析、共有された文脈、そしてエージェント利用を前提とした新しいアーキテクチャへと大規模な転換を行いました。
主な成果
- 私たちのセルフサービス型データエージェントは、3 人のデータチームが直接対応できるリクエスト量の約 40 倍を処理できるようになりました。
- 直近の 30 日間で、権限付与されたユーザー(社員の約 3 分の 1)のほぼ全員がデータエージェントを利用しました。この期間に約 2,200 件の対話が行われ、ユーザーあたり月平均 23 回の利用となりました。
移行前の状況
今回の移行以前は、データに関する問い合わせのほとんどがデータチームを経由していました。当時、そのチームにはたった一人しかいませんでした。
既存の伝統的な BI ツールは、事前に定義されたレポート作成には機能しましたが、柔軟性に欠けていました。探索的な分析は共同作業が難しく、共有も困難で、データがすでに BI レイヤー上でモデル化・公開されていない限り、データチーム以外の人が自分自身で分析を行うことはできませんでした。
これがボトルネックを生んでいました。社内の人々は的確な質問を持っていましたが、それに応えるには通常、データチームのメンバーが質問を翻訳し、適切なモデルを見つけ、クエリを作成または調整し、結果を検証して回答を返す必要がありました。その結果、データチームは深い分析やモデリング、他部門とのプロジェクトに集中する時間よりも、個別の依頼対応に多くの時間を費やすことになっていました。
私たちは、複数の異なるユーザー層を同時にサポートできる「エージェントファースト」のデータスタックが必要でした。
一部のユーザーは洗練されたダッシュボードを求めていました。また、ノートブックや SQL を利用したいという声もありました。さらに、データの所在を意識せずに質問に答えられる対話型インターフェースを求める人もいました。エンジニアや技術担当者には柔軟性が求められ、多くのビジネスユーザーには、より安全でガイド付きのデータ探索方法が必要でした。
私たちはまた、データ作業のための単一の中央集権的な場所も望んでいました。既存の BI ツールを維持しつつ新しいツールを追加することも検討しましたが、そうすれば利用状況や文脈、信頼性が二つのシステムに分散されてしまいます。
評価基準と選定プロセス
私たちは単なるダッシュボードの置き換えを探していたわけではありませんでした。
ベンダー各社を評価する際、AI 機能を製品に直接組み込み、エージェント体験をコアワークフローの一部として捉えている企業を選びました。また、技術者やエンジニアがデータチームに毎回頼らずとも必要なものを構築できるようなノートブックレイアウトも重要視しました。
非技術系のユーザーにとっては、ビジネス上の質問を行い、妥当な最初の回答を得て、その回答にどのソースが使われたかを理解できる場所が必要でした。
最終的に Hex を選定しました。ダッシュボード、ノートブック、対話型分析のすべてに対応しており、単一の中央データワークスペースを選ぶ上で大きな決め手となりました。
現在、人々は Hex エージェントと複数のインターフェースを通じてやり取りしています:
Hex の UI(Threads やノートブック機能を含む)、Slack、CLI ワークフロー、MCP、そして MCP や CLI 連携を介した LangSmith Fleet など、多様なインターフェースを用意しています。採用を促進するためには、こうした広範なアクセス面を持つことが重要です。エージェントへのアクセスは、人々が普段使っている場所で利用できるときに最も価値を発揮します。
例えば、プロダクトマネージャーは Hex 上でユーザーの行動について質問したいと思うかもしれませんし、GTM(Go-To-Market)チームのメンバーは Slack からパイプラインに関する問い合わせをしたいと考えるでしょう。技術系のユーザーであれば、CLI や MCP を通じて対話を行いたいはずです。
すでに各チーム間で多様なユースケースが確認されています:
- マーケティング部門では、エージェントを活用して毎週のパイプライン分析を行っています
- プロダクト部門は、ユーザーの行動や利用トレンドを把握するために利用しています
- 営業およびデプロイメントエンジニアリングは、顧客の健全性や利用状況に関する質問に対応するために活用しています
- カスタマーエンジニアリングでは、離脱率、拡大傾向、アカウント動向の分析に使用しています
これらは従来であればデータチームへの問い合わせキューが形成されていたような質問です。現在は、最初の確認をツール上で行うことが一般的になり、データチームは検証やより深い分析、あるいは厳密な判断が必要な意思決定のサポートに回ることができます。
移行後に何が変わったか
私たちは古い BI ツールからの完全移行をわずか 6 週間で完了しました。
現在、社内の全ユーザーが何らかの形でエージェントファーストのデータスタックを利用しています。Hex を介してです。
ユーザーの約 70% が読み取り専用アクセス権を持ち、残りの約 30% がエージェントアクセス権を持っています。これらのロールは IT を通じてセルフサービスで管理されており、必要なタイミングであれば誰でもエージェントアクセスを申請できます。
こうした対話の多くは、以前であればデータチームに持ち込まれていた質問です。ただし、データチームがワークフローから完全に姿を消したわけではありません。私たちに届く質問はより複雑で、影響力も大きくなっています。私たちは、深いビジネスコンテキストが必要だったり、強力なデータモデリングや他部門との調整が必要な業務に時間を割いています。
これが私たちの目指すところです。単純な分析の多くをセルフサービスで処理できるようにし、データチームがビジネスへのインパクトを生む業務に集中しやすい環境を作ることでした。
コンテキストに対する考え方
エージェントの体験はコンテキストに依存します。
企業の状況やデータ、指標、内部プロセスをどれだけ明確に記述できるかが、エージェントが企業に関する質問に答える質を決めます。コンテキストを提供することで、エージェントは生データのアクセスから有用な分析を生成できるようになります。
私たちが考えるコンテキストは複数の場所から得られます。各レイヤーがエージェントに異なる種類の情報を提供します。

LangChain のデータスタックアーキテクチャ
データモデルの定義方法
dbt は、データモデルに関するコンテキストを管理する主要な場所の一つです。そのコンテキストは SQL と記述された定義の両方に存在します。
すべてのテーブルと列は、人がデータをどのように理解し、どう使い、どのようなエッジケースがあるかを把握できるようにする必要があります。同じ定義がエージェントにとっても役立ちます。
カラム定義が弱すぎると、以下のような記述になりがちです。
account_status: アカウントのステータス。
これは技術的には正確ですが、読者にとって有用な情報はほとんど含まれていません。
より良い定義は、次のようになります。
account_status: Salesforce 上のアカウントの現在のライフサイクルステータスを示します。「Active」は顧客が有効な有償契約を保有している状態、「Churned」は過去に有償契約を結んでいたが現在失われた状態、「Prospect」はまだ顧客化していない見込みの状態を意味します。顧客レポート作成時は、分析対象に「Churned」や「Prospect」を明示的に含めない限り、フィルタリングは「Active」に限定してください。
この定義により、エージェントにはビジネスコンテキスト、許容値の範囲、解釈のガイドライン、デフォルトのフィルタリングルールが提供されます。これによって、「技術的には正しいが、ビジネス解釈が間違っている」という回答が生成されるリスクを大幅に減らすことができます。
テーブルレベルでも同様のアプローチを採用しています。優れたテーブル定義には、そのテーブルが表す粒度(グライン)、回答を想定している質問の種類、そして注意すべきポイントを含めるべきです。
セマンティックモデルはメトリクスと関係性を定義する
セマンティックモデルは、エージェントに対してメトリクスの意味やモデル間の関係を理解させる役割を果たします。
ここでは、ARR(年間契約額)、パイプライン、アクティブな利用状況、顧客健全度など、頻繁に質問される概念を定義します。セマンティックレイヤーによってこれらの定義を一貫性あるものに保つことで、エージェントは毎回新しい質問に対してメトリクスのロジックをゼロから推測する必要がなくなります。
セマンティックモデルが真に力を発揮するのは、堅固なデータモデリングの上に成り立っている場合です。基盤となるモデルが不明確だったり重複していたり、ドキュメント化が不十分であれば、セマンティックレイヤーでできることには限界があります。私たちは、土台の重要性は変わらないと実感しています。クリーンなモデル、明確な粒度(グライン)、そして適切な定義こそが、下流のすべてのレイヤーにおける品質向上につながります。
ビジネスコンテキストの取り込み
一部の文脈は、テーブルやメトリック定義にきれいに収まらないことがあります。
企業のプロセス、チーム固有のワークフロー、報告の慣習、そしてビジネスルールなど、より広い記述を必要とする要素が存在します。これらはデータエージェントにとっての「スキル」のようなものです。私たちはこれを Hex のワークスペースガイドで管理しています。このガイドは、エージェントに対して、事業の一部や特定のメトリック、一般的なワークフロー、あるいは特定データをどう解釈すべきかといった具体的な指示を書面で与える役割を果たします。
これらのガイドは GitHub リポジトリ上で管理しており、Hex と直接同期させています。これにより、バージョン管理が可能になり、変更点をレビューでき、コンテキストを他のデータドキュメントと密接に連携させることができます。
ガイドには以下のような内容が含まれます:
- 毎週の GTM(Go-To-Market)報告におけるパイプラインの定義方法
- 特定のメトリックにおいてどのダッシュボードが公式(カノニカル)とみなされるか
- 異なるデプロイタイプ間での製品利用状況をどう解釈するか
- カスタマーヘルスを分析する際に適用すべきフィルタリング条件
- どのような質問をデータチームに検証のために転送すべきかの判断基準
このレイヤーが特に有用なのは、ビジネスコンテキストをモデルやカラムの説明に無理やり押し込めることなく、平易な言語で記述できる点にあります。
エージェントに信頼すべき対象を教える「エンダースメント」
エンダースメント(endorsement)は、エージェントがどのデータソースや資産を信頼すべきかを理解する手助けになります。
例えば、ARR 関連のダッシュボードがエンダースメントされている場合、エージェントはそのダッシュボードと背後にあるロジックを活用して回答を作成できます。このシグナルが重要な理由は、企業内では同じ概念を扱うテーブルやダッシュボード、過去のクエリが複数存在するケースが多いためです。信頼性を示すシグナルがないと、一見関連していそうだが実際には最適ではない資産を選んでしまうリスクがあります。
エンダースメントの価値を保つため、私たちは厳格なガードレールを設けています。エンダースメントを設定できるのはデータチームのみです。また、変更が本番環境に反映される前には、データチームによるレビューが必須となっています。このプロセスを通じて、エンダースメントされた資産の信頼性が維持されます。もしすべての資産がエンダースメントされていれば、そのシグナルはもはや有用ではなくなります。
GitHub でデータポイントの背景を深く理解する
エージェントは、dbt リポジトリを確認することで、データポイントがどのように生成されているかという深い文脈も取得できます。
dbt リポジトリには、カラムやメトリックの定義から最終的な出力に至るまでの SQL とロジックが含まれています。これは、表面的な定義だけでは不十分な質問に対して特に役立ちます。エージェントは基盤となるモデルのロジックを検証し、結合(ジョイン)や変換処理を理解し、フィールドがどのように生成されるかを追跡することが可能になります。
より技術的なユーザーにとって、これはセットアップにおいて最も重要な部分の一つです。エージェントはビジネスレベルの文脈と実装レベルの文脈を行き来できるため、デバッグや検証、そして深い分析において非常に有用になります。
システムを改善する方法
文脈にはフィードバックループが必要です。私たちは、人々がどのようにエージェントを利用しているか、またどこでより多くの支援が必要かを把握したいと考えていました。そのために観測性(オバザビリティ)ツールを活用しています。Hex の Context Studio を利用していますが、データエージェントを自社開発しているチームであれば LangSmith を使用することも可能です。
会話のトピックの傾向や、よくある警告・問題点、文脈の欠落などを分析できます。こうしたデータをもとに、スタックのどこを改善すべきかを判断します。
似たような質問が繰り返される場合は、ダッシュボードの改善が必要かもしれません。特定の指標でエージェントが繰り返しつまずく場合、セマンティックモデルの定義をより明確にする必要があるでしょう。社内のビジネスコンテキストが必要な質問が多い場合は、ワークスペースガイドの整備を検討すべきです。もし間違ったソースを利用しているようであれば、エンダンスト(推奨)の設定を見直したり、dbt のドキュメントを改善したりする必要があります。
このループは、データ活用支援に関する考え方を一変させました。私たちは、エージェントとの会話こそが、組織が何を理解しようとしているかを示す強力なシグナルであることを学びました。会話にパターンが見えれば、レポートやドキュメント、モデル化におけるギャップを特定できます。また、繰り返し個別の質問をするよりも、ダッシュボードの方がユーザーにとって有益であるケースも見えてきます。
フィードバックループの仕組み:
- ユーザーは Hex、Slack、CLI、MCP、LangSmith Fleet といったさまざまなチャネルから質問を行います。
- エージェントは dbt の定義やセマンティックモデル、ワークスペースガイド、エンダースメント、ダッシュボード、そして GitHub のコンテキスト情報を活用して回答を生成します。
- オブザーバビリティ機能により、データのギャップや警告、頻出するトピックが可視化されます。
- データチームはこれらのパターンと提案をレビューし、モデルや定義、ガイド、メトリクス、エンダースメント、ダッシュボードの更新を行います。
- これらの改善を通じて、エージェントの回答品質は時間とともに向上していきます。
今後の展望
このワークフローはまだ初期段階にあり、ツールの進化も目覚ましいものです。今後数ヶ月間は、いくつかの重要な改善点に注力していく予定です。
コンテキスト変更の評価
次に取り組むのは、評価(evals)機能の活用です。これにより、コンテキストの変更がエージェントの回答品質向上につながっているかを定量的に把握できるようになります。
現状では、利用パターンの分析や警告の確認、そして質的なフィードバックを通じて改善点を把握しています。しかし、評価機能を導入することで、変更をテストするより構造化されたアプローチが可能になります。例えば、メトリクスの定義を更新したり、ガイドを追加したり、エンダースメントを変更したりした際、エージェントが実際により良い回答を生み出しているかを明確に検証できるようになるのです。
これにより、コンテキスト管理はソフトウェア開発プロセスと同等のものへと進化します。変更を加え、テストを行い、広く展開する前に確信を持って進めることができるようになります。
コンテキストワークフローの改善
また、コンテキストに関する提案プロセス自体を自動化することも目指しています。
観測機能はすでにギャップの特定に役立っています。次のステップは、dbt の定義やワークスペースガイド、セマンティックモデルの更新、承認などにおいて、それらのギャップをレビュー可能な変更として扱いやすくすることです。
文脈の改善を追跡し、レビューし、リリースしやすくする方法を探求しています。
学び続けること
エージェントワークフローは急速に進化しており、何が機能し、どこにガードレールが必要で、製品をどこで改善すべきかについては、まだ学習中の段階です。
文脈の取得、信頼性のシグナル、評価、ユーザー体験における小さな改善が、人々がエージェントを自信を持って使えるかどうかを大きく左右します。
得られた教訓
これまでの道のりでいくつかの重要な教訓が浮き彫りになりました。
堅牢なデータモデリングの基盤がすべてを容易にする
エージェントによるアクセスが可能になっても、優れたデータモデリングの必要性がなくなるわけではありません。むしろ、その価値が高まります。
明確な粒度、適切な名前のモデル、一貫した定義、信頼できる変換処理は、エージェントの有用性を高めます。人間にとってデータモデルが混乱を招くなら、エージェントにとっても同様です。
良質な文脈は最もレバレッジの高い投資の一つ
エージェントはビジネスを理解している場合にパフォーマンスを発揮します。つまり、明確な定義の記述、社内の用語解説、メトリクスのロジックに関するドキュメント化、データの解釈方法に関するガイダンス提供が求められます。
最適な文脈は具体的であるべきです。ビジネスの仕組み、実務上の値の意味、想定されるフィルタ、データの使用・非使用の範囲について説明する必要があります。
強力な基盤の上にこそ、セマンティックモデルは真価を発揮する
定義されたセマンティックモデルは重要ですが、特に共通の指標においては、その下にあるモデルやドキュメントの質に依存します。
この取り組みを始めるなら、まずは基盤を整えるべきです。その後、セマンティックレイヤーを活用して、最も重要な指標の一貫性を高め、エージェントが利用しやすくしましょう。
最も重要な問いから始めよう
初日からすべての文脈を完璧にする必要はありません。
人々が最も頻繁に尋ねる質問から始めてください。それらで参照されるモデルを特定し、まずはその領域に深く取り組むのです。
もし人々の質問の約80%をカバーできれば、大多数のユーザーにとって格段に良い体験を提供できます。残りの長尾部分については、時間をかけて対応していけばよいでしょう。
セルフサービスには依然としてデータ教育が必要
ユーザーがシステムの能力と限界の両方を理解しているとき、セルフサービスは最も効果を発揮します。
エージェントからの回答は、特に重要な意思決定の根拠となる場合、判断力を働かせて扱うべきです。検証が必要な質問については、データチームのメンバーを常に巻き込む必要があります。また、エージェントやツールとの最適な関わり方について学びが深まるにつれ、Slack で定期的なリマインダーやベストプラクティスを共有しています。
私たちが目指しているのは、全員をデータエキスパートにすることではありません。信頼性を保ちながら、人々がデータにより良いアクセスを得られるようにすることです。
まとめ
エージェントファーストのデータスタックを構築する本質は、文脈を明示的にすることにあります。
エージェントには、データの意味、信頼できる情報源、ビジネスの仕組み、そしてどの質問に特別な配慮が必要かを理解する必要があります。スタック全体でこれらの要素をより明確に記述するほど、エージェントの性能は向上します。
私たちが取り組んできたのは、dbt の定義やセマンティックモデル、ワークスペースガイド、エンダンスト(信頼性の証明)、GitHub を活用したコンテキスト、そして行動の観測を通じたフィードバックループへの投資です。データエージェントの信頼性は、データを囲むようなコンテキストによって支えられています。
私たちの取り組みは現在も継続中です。評価手法や CLI ワークフロー、コンテキスト管理ツールが改善されるにつれ、このプロセスはより体系的なものになると予想されます。しかしすでに明らかになっているのは、データチームが手作業で一つひとつの質問に答える時間を減らし、社内の他のメンバーが適切に質問に応えられるよう、コンテキストやモデル、信頼システムを設計する時間へとシフトしていくという点です。
関連コンテンツ
image.png)
Open Source
LangGraph
Agent Architecture
LangGraph を使った 3 年間のグラフエンジニアリング


S. Runkle,
H. Chase
2026 年 7 月 22 日
7 分

Deep Agents
Agent Architecture
Open Source
RLM を Deep Agent で活用する方法

Sydney Runkle
2026 年 7 月 1 日
8 分

Agent Architecture
Deep Agents
Open Source
サンドボックスなしで信頼できないエージェントコードを実行する

Hunter Lovell
2026 年 6 月 30 日
6 分
エージェントの実際の動作を確認する
LangSmith は、エージェントエンジニアリングに特化したプラットフォームです。開発者はこれを使って、すべてのエージェントの判断をデバッグしたり、変更の評価を行ったり、ワンクリックでデプロイしたりできます。
原文を表示

要点
- Reliable data agents need more than access to tables. They need clear models, metric definitions, business context, and signals about which sources to trust.
- An agent-first stack can dramatically expand self-service. Our data agent now handles roughly 40x the request volume our three-person data team could manage directly.
- The data team’s role has shifted from answering every question to improving the system. The data team now focuses on building the models, context, guardrails, and feedback loops that help make agent answers more useful over time.
Over the past year, our data team has been rethinking how our stack needs to evolve to support agents. Most company data stacks are built around dashboards, reports, and SQL workflows. Those are still useful, but agents change what the data layer needs to provide.
An agent can answer more questions when it has clear definitions, trusted sources, business context, and access to the logic behind the data. Without that context, it can still generate SQL, but the answers are harder to trust. The agent might miss company-specific definitions, use the wrong table, or answer a question in a way that is technically valid, but not actually useful for the business.
We wanted to make data easier to access across the company, while giving agents enough context to answer questions accurately and explain how they got there.
We did a big architectural shift, moving from a data stack centered around a traditional BI tool to one designed for self-serve analysis, shared context, and agent use.
Key results
- Our self-serve data agent now handles ~40x the volume of requests our 3-person data team could field directly.
- In the last 30 days, nearly 100% of provisioned users (a third of our company) used the data agent. We saw roughly 2,200 agent conversations in the period, or an average of 23 conversations per month per user.
Where we started
Before this migration, almost every data ask went through the data team. At the time, that team was just one person.
The existing traditional BI tool worked for predefined reporting, but it was rigid. Exploratory analysis was hard to collaborate on, hard to share, and hard for anyone outside the data team to explore on their own unless the data had already been modeled and exposed in the BI layer.
This all created a bottleneck. People across the company had good questions, but answering them usually required a data team member to translate the question, find the right model, write or adjust the query, validate the result, and send back an answer. The data team spent a lot of time handling one-off requests instead of focusing on deeper analysis, modeling, and cross-functional projects.
We needed an agent-first stack that could support several different kinds of users at once.
Some people wanted polished dashboards. Some wanted notebooks and SQL. Some wanted a conversational interface that could help them answer a question without needing to know where the data lived. Engineers and technical operators needed flexibility, while many business users needed a safer and more guided way to explore.
We also wanted one central place for data work. We considered keeping our old BI tool and also adding a new one, but that would have split usage, context, and trust across two systems.
How we evaluated our tooling
We were looking for more than a dashboard replacement.
When we evaluated different vendors, we wanted one that was building AI features directly into the product and treating the agent experience as part of the core workflow. We also wanted a notebook layout that would make it easy for more technical users and engineers to build what they needed without waiting on the data team for every iteration.
For non-technical users, we needed a place where someone could ask a business question, get a reasonable first answer, and understand which sources the agent used.
We ended up choosing Hex. It worked for dashboards, notebooks, and conversational analysis, which made it easier to choose a single central data workspace.
People now interact with the Hex agent through several surfaces:
- The Hex UI, including Threads and notebooks
- Slack
- CLI workflows
- MCP
- LangSmith Fleet, through MCP and CLI integrations
Having a wide surface area is important for adoption. Agent access is most useful when people can use it where they already work. A product manager may want to ask about user behavior in Hex. A GTM teammate may want to ask a pipeline question from Slack. A technical user may want to interact through the CLI or MCP.
We have already seen a wide range of use cases across teams:
- Marketing uses the agent for weekly pipeline analysis
- Product uses it to understand user behavior and usage trends
- Sales and deployment engineering use it for customer health and usage questions
- Customer engineering uses it to analyze churn, expansion, and account trends
These are the kinds of questions that used to create a queue for the data team. Now the first pass can often happen directly in the tool, with the data team available for validation, deeper analysis, or decisions that need more rigor.
What changed after we migrated
We migrated 100% off our old BI tool in six weeks.
Today, 100% of the company uses our agent-first data stack, via Hex, in some form.
Roughly 70% of users have read-only access, and about 30% have agent access. Those roles are self-serve through IT, so anyone can request agent access when they need it.
A lot of those conversations represent questions that previously would have gone through the data team. However, the data team has not disappeared from the workflow entirely. The questions that reach us are more complex and higher leverage. We spend more time on the work that needs deeper business context, stronger data modeling, or cross-functional alignment.
This was our goal. We wanted self-service to handle more of the straightforward analysis, while making it easier for the data team to focus on the work that makes business impact.
How we think about context
The agent experience depends on context.
The more clearly we can describe our business, data, metrics, and internal processes, the better the agent can answer questions about the company. Providing context is what helps agents generate useful analysis from raw table access.
For us, context comes from several places. Each layer gives the agent a different kind of information.

How we define the data models
dbt is one of the main places where we manage context about our data models. That context exists in both SQL and written definitions.
Every table and column should help a person understand what the data represents, how it should be used, and where the edge cases are. Those same definitions also help the agent.
A weak column definition might say:
account_status: The status of the account.
That is technically accurate, but it does not tell the reader much.
A stronger definition would say:
account_status: The current lifecycle status of the account in Salesforce. Active means the customer has an active paid contract. Churned means the customer previously had a paid contract that has ended. Prospect means the account has not yet become a customer. For customer reporting, filter to Active unless the analysis explicitly includes churned or prospective accounts.
This definition gives the agent business context, allowed values, interpretation guidance, and a default filtering rule. It also reduces the chance that someone gets a technically correct answer based on the wrong business interpretation.
We apply the same approach at the table level. A good table definition should explain what grain the table represents, what kinds of questions it is designed to answer, and where people should be careful.
The semantic model defines metrics and relationships
The semantic model gives the agent context about metrics and how models relate to each other.
This is where we define concepts like ARR, pipeline, active usage, customer health, and other metrics that people ask about repeatedly. The semantic layer helps keep those definitions consistent, so the agent does not need to infer metric logic from scratch every time someone asks a question.
A semantic model is most useful when it sits on top of solid data modeling. If the underlying models are unclear, duplicative, or poorly documented, the semantic layer can only do so much. We found that the foundations still matter. Clean models, clear grains, and good definitions lead to higher quality at every downstream layer.
Capturing business context
Some context might not belong neatly in a table or metric definition.
There are company processes, team-specific workflows, reporting conventions, and business rules that need more room. These would be like skills for the data agent. We use Hex workspace guides for this. They give the agent written instructions about parts of the business, specific metrics, common workflows, and how people should interpret certain data. We manage these guides in a GitHub repo that syncs directly into Hex. That lets us version them, review changes, and keep the context close to the rest of our data documentation.
A guide might explain:
- How we define pipeline for weekly GTM reporting
- Which dashboards are considered canonical for a given metric
- How to interpret product usage across different deployment types
- What filters to apply when analyzing customer health
- When a question should be routed to the data team for validation
This layer has been especially useful because it lets us write business context in plain language, without forcing every detail into a model or column description.
Endorsements tell the agent what to trust
Endorsements help the agent understand which data sources and assets are trusted.
For example, if the ARR dashboard is endorsed, the agent can use that dashboard and the logic behind it when answering a question about ARR. Endorsement is an important signal because companies often have multiple tables, dashboards, or historical queries that touch the same concept. Without a trust signal, the agent may choose an asset that looks relevant but is not the best source.
We keep guardrails around endorsements so they stay meaningful. Only the data team can mark something as endorsed. Endorsed dashboards also require data team review before changes go live. Our review process keeps endorsed assets trustworthy. If everything is endorsed, the signal stops being useful.
GitHub provides deeper implementation context
The agent can also look at our dbt repo for deeper context about how a data point is sourced.
The dbt repo gives it access to the SQL and logic that define a column or metric from start to finish. This is useful when a question requires more than a surface-level definition. The agent can inspect the underlying model logic, understand joins and transformations, and trace how a field is produced.
For more technical users, this is one of the most important parts of the setup. The agent can move between business-level context and implementation-level context, which makes it more useful for debugging, validation, and deeper analysis.
How we improve the system
Context needs a feedback loop. We wanted a way to see how people are using the agent and where the agent needs more help. Observability tools help with this. We leverage Context Studio from Hex, but teams can use LangSmith if their data agent is built in-house. We can look at trends in conversation topics, common warnings, issues, and context gaps. This data helps us decide where to improve the stack.
If people keep asking similar questions, we may need a better dashboard. If the agent repeatedly struggles with a metric, we may need a clearer semantic model definition. If users ask questions that require internal business context, we may need a workspace guide. If the agent uses the wrong source, we may need to adjust endorsements or improve dbt documentation.
This loop has changed how we think about data enablement, and we’ve learned that agent conversations are a great signal about what the company is trying to understand. When we see patterns in conversations, we can identify gaps in reporting, documentation, and modeling. We can also see where a dashboard would serve people better than repeated one-off questions.

The feedback loop:
- Users ask questions through Hex, Slack, CLI, MCP, or LangSmith Fleet
- Agent uses dbt definitions, semantic model, workspace guides, endorsements, dashboards, and GitHub context
- Observability surfaces gaps, warnings, and repeated topics
- Data team reviews patterns and suggestions
- Data team updates models, definitions, guides, metrics, endorsements, or dashboards
- Agent responses improve over time
Where we're going next
We are still early in this workflow, and the tooling is changing quickly. Over the next few months, we are focused on a few improvements.
Evaluating context changes
Next, we want to start leveraging evals, which will help us understand whether context changes are improving agent responses.
Today, we can look at usage patterns, warnings, and qualitative feedback. Evals will give us a more structured way to test changes. If we update a metric definition, add a guide, or change an endorsement, we want to know whether the agent produces better answers as a result.
This will make context management feel more like software development. We can make a change, test it, and build more confidence before rolling it out broadly.
Improving our context workflow
We also want to automate more of the process around context suggestions.
Observability already helps us find gaps. The next step is making it easier to turn those gaps into reviewed changes across dbt definitions, workspace guides, semantic model updates, and endorsements.
We are exploring ways to make context improvements easier to track, review, and ship.
Continuing to learn
Agent workflows are evolving quickly, and we are still learning what works, what needs guardrails, and where the product should improve.
Small improvements in context retrieval, trust signals, evaluation, and user experience can make a big difference in whether people use the agent confidently.
What we’ve learned
A few lessons have stood out in our journey thus far.
Solid data modeling foundations make everything easier
Agent access does not remove the need for good data modeling. It raises the value of good data modeling.
Clear grains, well-named models, consistent definitions, and reliable transformations make the agent more useful. If the data model is confusing to humans, it will be confusing to agents too.
Good context is one of the highest leverage investments
The agent performs better when it understands the business. That means writing clear definitions, explaining company vocabulary, documenting metric logic, and giving guidance on how data should be interpreted.
The best context is specific. It explains how the business works, what values mean in practice, which filters are expected, and where the data should or should not be used.
The semantic model works best on top of strong foundations
A well-defined semantic model is important, especially for common metrics. But it depends on the quality of the underlying models and documentation.
If you are starting this work, fix the foundations first. Then use the semantic layer to make the most important metrics consistent and easier for the agent to use.
Start with the questions that matter most
You do not need perfect context everywhere on day one.
Start with the questions people ask most often. Identify the models they hit most often. Go deep on those areas first.
If you can cover roughly 80% of the questions people ask, you’ll create a much better experience for most users. Then you can work through the long tail over time.
Self-service still needs data education
Self-service works best when users understand both the power and the limits of the system.
We are clear that agent responses should be treated with judgment, especially when the answer will inform an important decision. Data team members should always be looped in when questions need validation. We also share periodic reminders and best practices in Slack as we learn more about how to best interact with the agent and our tooling.
Our goal is not to make every person a data expert, but we want to give people better access to data while preserving trust.
Closing
Building an agent-first data stack is mostly about making context explicit.
The agent needs to know what the data means, which sources to trust, how the business works, and when a question requires extra care. The better we describe those things across our stack, the better the agent becomes.
For us, that has meant investing in dbt definitions, semantic models, workspace guides, endorsements, GitHub-based context, and a feedback loop through observability of behavior. The reliability of a data agent comes from the context we put around the data.
Our work is ongoing. As evals, CLI workflows, and context management tools improve, we expect this process to become more systematic. However, it’s already clear that data teams will spend less time answering every question manually and more time designing the context, models, and trust systems that help the rest of the company answer questions well.
Related content
.png)
Open Source
LangGraph
Agent Architecture
3 Years of Graph Engineering with LangGraph


S. Runkle,
H. Chase
July 22, 2026
7
min

Deep Agents
Agent Architecture
Open Source
How to Use RLMs in Deep Agents

Sydney Runkle
July 1, 2026
8
min

Agent Architecture
Deep Agents
Open Source
Running Untrusted Agent Code Without a Sandbox

Hunter Lovell
June 30, 2026
6
min
See what your agent is really doing
LangSmith, our agent engineering platform, helps developers debug every agent decision, eval changes, and deploy in one click.
関連記事
今日のまとめ
AIデイリーブリーフで今日の重要ニュースをまとめ読み