header-langage
简体中文
繁體中文
English
Tiếng Việt
한국어
日本語
ภาษาไทย
Türkçe
Scan to Download the APP
Partnered With:

Perplexity Introduces Search as Code: AI Agent Natively Searches Through Python Code

According to Dynamic Insight monitoring, Perplexity has announced the full deployment of the new Search as Code (SaC) architecture in the Perplexity Agent API and its in-house Computer product. The new architecture abandons the traditional intelligent agent's serial loop pattern that relies on multi-round inference for function calling or MCP tool invocation. Instead, the intelligent agent now directly generates Python code to invoke modular retrieval primitives provided by the Agentic Search SDK, orchestrating thousands of searches and processing operations in parallel within a single inference cycle.

Traditional tool invocations face challenges such as high latency, restricted control flow, and context contamination. SaC allows large models to run Python code in a secure computing sandbox, dynamically orchestrating parallel queries, deduplication, filtering, merging, and reshuffling. To address the challenge of passing intermediate states across inference cycles, the team has adopted an explicit serialization (serde) approach using a persistent file system, which is more reliable than the REPL mode for long-trace tasks. Additionally, the development team has introduced an exclusive Agent Skills prompt package with up to 2000 tokens to guide large models in efficiently orchestrating complex retrieval tasks.

In multiple search benchmark evaluations, the SaC architecture has performed outstandingly. In the in-house WANDR benchmark test, which measures professional wide-range retrieval, SaC scored 0.386, a 2.5x improvement over the runner-up Anthropic system (0.152) and a 45% improvement over the non-SaC baseline. In a real-world test case for 200 high-risk CVE vulnerability queries, SaC achieved 100% accuracy and reduced token consumption by 85.1% compared to the traditional baseline. In DSQA evaluation, while achieving a high score of 0.871, SaC has reduced the cost per task at a moderate inference level to below $1.

举报 Correction/Report
Correction/Report
Submit
Add Library
Visible to myself only
Public
Save
Choose Library
Add Library
Cancel
Finish