OpenAICloudflare Developer PlatformApr 16, 2026, 12:00 PM

AI Search - AI Search instances now include built-in storage and namespace Workers Bindings

A condensed section focused on the key takeaways first.

Original Post

Quick Digest

Summary

A condensed section focused on the key takeaways first.

openaienmodel: gpt-5-mini-2025-08-07

AI Search - AI Search instances now include built-in storage and namespace Workers Bindings

Key Points

  • Built-in storage and vector index for immediate indexing
  • Namespace binding (ai_search_namespaces) for runtime instance management
  • Cross-instance search returns a single ranked result list

Summary

New AI Search instances created after 2026-04-16 include built-in storage and a built-in vector index. You can upload files directly to an instance (via the Items API or dashboard), have them indexed immediately, and search them right away without configuring R2 or external data sources. A new Workers binding, ai_search_namespaces, replaces the previous env.AI.autorag() API and enables runtime creation, update, and deletion of instances. Namespace-level APIs also support cross-instance search that returns a single ranked list of results.

Key Points

  • Built-in storage + vector index: upload and wait for indexing with instance.items.uploadAndPoll(...), then query immediately with instance.search(...).
  • Namespace Workers binding: add ai_search_namespaces to wrangler.jsonc and manage instances at runtime via env.AI_SEARCH.create({ id: "my-instance" }) without redeploying.
  • Cross-instance search: call env.AI_SEARCH.search({ ..., ai_search_options: { instance_ids: ["id1","id2"] } }) to query multiple instances in one call and receive a single ranked result list.
  • No external buckets required: eliminates the need to set up R2 or connect external data sources before indexing.
  • Migration note: update your Workers binding to ai_search_namespaces and follow the Workers binding migration documentation for detailed steps.

Full Translation

Translations

A translation section that keeps the flow of the original article.

openaijamodel: gpt-5-mini-2025-08-07

AI Search - AI Search インスタンスに組み込みストレージと namespace Workers Bindings が追加されました

AI Search インスタンスに組み込みストレージと namespace Workers Bindings が追加されました

公開日: 2026-04-16

新しい AI Search インスタンスの動作が変更されます。今回の更新では、新規インスタンスに組み込みストレージとベクトルインデックスが付属するようになり、ファイルをアップロードすると即座にインデックス化され、そのまま検索可能になります。さらに、AI Search 向けの Workers Bindings が利用可能になりました。新しい namespace バインディングにより、ランタイムでインスタンスを作成・管理でき、クロスインスタンス検索 API により複数インスタンスを 1 回の呼び出しで横断検索できます。

主な変更点

  • 組み込みストレージとベクトルインデックス
  • namespace バインディングによるランタイムでのインスタンス作成・管理
  • クロスインスタンス検索(複数インスタンスの検索結果をランク付けして返す)

組み込みストレージとベクトルインデックス

新しいインスタンスには組み込みストレージが含まれており、Items API またはダッシュボードを使ってファイルを直接アップロードできます。R2 バケットの設定や外部データソースの事前接続は不要です。

例(TypeScript):

const instance = env . AI_SEARCH . get ( "my-instance" ) ;
// upload and wait for indexing to complete
const item = await instance . items . uploadAndPoll ( "faq.md" , content ) ;
// search immediately after indexing
const results = await instance . search ( {
  messages : [ { role : "user" , content : "onboarding guide" } ] ,
} ) ;

Namespace バインディング

新しい ai_search_namespaces バインディングは、従来の env.AI.autorag() API(AI バインディングを通じて提供されていたもの)に代わるものです。これにより、Worker から名前空間内のすべてのインスタンスへアクセスでき、再デプロイせずにランタイムでインスタンスの作成・更新・削除が可能になります。

例(wrangler.jsonc):

// wrangler.jsonc
{
  " ai_search_namespaces " : [
    {
      " binding " : "AI_SEARCH" ,
      " namespace " : "default" ,
    },
  ],
}

例(TypeScript):

// create an instance at runtime
const instance = await env . AI_SEARCH . create ( { id : "my-instance" , } ) ;

移行の詳細は Workers binding migration を参照してください。名前空間の詳細は Namespaces を参照してください。

クロスインスタンス検索

新しい AI Search バインディングでは、namespace レベルで Search および Chat API にアクセスできるようになりました。インスタンス ID の配列を渡すと、複数インスタンスを横断して 1 つのランク付けされた結果リストが返ります。

例(TypeScript):

const results = await env . AI_SEARCH . search ( {
  messages : [ { role : "user" , content : "What is Cloudflare?" } ] ,
  ai_search_options : { instance_ids : [ "product-docs" , "customer-abc123" ] , },
} ) ;

詳細は Namespace-level search を参照してください。

リソース

  • 新規ユーザー向け: Directory
  • Sponsorships
  • Open Source Support
  • Help Center
  • System Status
  • Compliance / GDPR
  • 会社情報: cloudflare.com

© 2026 Cloudflare, Inc. Privacy Policy Terms of Use Report Security Issues Trademark Cookie Settings

Was this helpful? Yes No