Search as Code: Perplexity Is Right About the Future — Just Not First to It

📊 Full opportunity report: Search as Code: Perplexity Is Right About the Future — Just Not First to It on ThorstenMeyerAI.com — validation score, market gap, and execution plan.

TL;DR

Perplexity has announced a new method called Search as Code (SaC), allowing AI models to dynamically assemble search pipelines. While initial results are promising, independent validation and comparison specifics are still pending.

Perplexity has introduced a new search architecture called Search as Code (SaC), claiming it significantly improves the accuracy and efficiency of AI retrieval processes. This development aims to address limitations in traditional search pipelines for AI agents, and its initial results suggest substantial gains in both performance and cost efficiency.

On June 1, 2026, Perplexity’s research team published a detailed proposal for SaC, a method that shifts from fixed search endpoints to a modular, code-driven approach. Instead of treating search as a static process, SaC exposes retrieval, filtering, ranking, and rendering as atomic building blocks accessible via a Python SDK. This allows AI models to generate code that orchestrates these primitives dynamically, tailoring search pipelines to specific tasks.

The core idea is to empower models to control the search process actively, rather than passively consuming search results from a monolithic API. The architecture comprises three layers: the model as the control plane, a sandbox for deterministic execution, and the primitive set of search components. This design aims to improve flexibility, precision, and efficiency, especially for complex multi-step tasks.

Perplexity reports that their CVE case study, which involved identifying and characterizing over 200 high-severity vulnerabilities, achieved 100% accuracy while reducing token usage by 85%, compared to traditional systems. They also benchmarked SaC against several tests, claiming it outperformed competitors on four of five, including a new benchmark called WANDR, where SaC was 2.5 times more effective than the next-best system.

However, some skepticism exists regarding the novelty and validation of these results. The benchmarks where SaC shows the greatest advantage are either proprietary or newly created by Perplexity, raising questions about independent verification. Additionally, the comparison models run on different versions of GPT, complicating direct evaluation. The approach itself—using code to orchestrate search—has precedents in recent academic and industry work, including papers from ICML 2024 and recent publications by Anthropic, which argue that turning tools into executable code improves agent scalability and accuracy.

At a glance
reportWhen: announced June 1, 2026; ongoing develop…
The developmentPerplexity has launched a new search architecture called Search as Code, aiming to improve AI retrieval by enabling models to generate and execute custom search pipelines.
Search as Code — Perplexity SaC, in context
AI Dispatch · Infrastructure

Search as Code

Perplexity says agents shouldn’t call a search engine — they should program one, composing atomic primitives into a bespoke pipeline in a sandbox. The thesis is right. It’s also the search-shaped version of an idea the field has been converging on since 2024.

■ The old contract
One fixed pipeline. The model tweaks query params and consumes whatever comes back — through the context window, every time.
model → query(params)
engine → fixed pipeline
return → full result set
repeat ×N serial round-trips
⚠ every intermediate result routed through model context
▲ Search as Code
Amazon

Python SDK for search pipeline development

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Programmable primitives

The model writes code that orchestrates atomic search ops — fan-out, dedupe, verify — keeping bulk data out of the token stream.
sdk.search.web_many(queries)
filter()
dedupe()
sdk.llm.extract_many(schema)
verified records
✓ only the useful tokens reach the model
100%
CVE case-study accuracy (SaC run)
−85%
Token use vs baseline 288.7K → 42.9K
<25%
Score for the rival systems tested
2.5×
SaC lead on Perplexity’s own WANDR bench
A convergent idea, not a cold start
“Let the model write code instead of emitting tool calls” has been building for two years. SaC is the search-specific instantiation.
2024
CodeAct
Wang et al. · ICML
2024–25
smolagents
Hugging Face
2025
Code Mode
Cloudflare
Nov 2025
Code exec + MCP
Anthropic
Jun 2026
Search as Code
Perplexity
The take

Directionally right, genuinely engineered — the rebuilt-from-atoms search stack is the part rivals can’t cheaply copy. But it’s a strong execution of an industry-wide idea, validated mostly on benchmarks Perplexity ran itself. The moat is the infrastructure and the tuning loops, not the architecture.

Sources: Perplexity Research, “Rethinking Search as Code Generation” (Jun 1 2026); CodeAct (Wang et al., ICML 2024); HF smolagents; Cloudflare Code Mode; Anthropic “Code execution with MCP” (Nov 2025). Figures as reported by Perplexity.
thorstenmeyerai.com
Bendable Flexible Magnetic Pickup Tool, 24'' Four Claw Grabber Tool, Accurate Pick Up In Narrow Space for Engine Bay/Home Sink/Drain/Earring/Keys/Metal Objects (Magnetic orientation)

Bendable Flexible Magnetic Pickup Tool, 24'' Four Claw Grabber Tool, Accurate Pick Up In Narrow Space for Engine Bay/Home Sink/Drain/Earring/Keys/Metal Objects (Magnetic orientation)

【Narrow Space Pickups Saviour】: SARDVISA grabber tool has an orientable tube body and four steel claws can be…

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Implications for AI Search and Agent Development

This development signals a shift toward more flexible, programmable search architectures that could significantly enhance the capabilities of AI agents. By enabling models to generate and execute custom search pipelines, SaC could improve accuracy, reduce costs, and enable more complex multi-step reasoning. However, the approach’s reliance on proprietary benchmarks and the lack of independent validation mean its real-world impact remains to be seen. If validated, SaC could influence future AI system design, emphasizing modular, code-driven retrieval processes over static APIs.

API FRESHWATER MASTER TEST KIT 800-Test Freshwater Aquarium Water Master Test Kit, White, Single, Multi-colored

API FRESHWATER MASTER TEST KIT 800-Test Freshwater Aquarium Water Master Test Kit, White, Single, Multi-colored

Contains one (1) API FRESHWATER MASTER TEST KIT 800-Test Freshwater Aquarium Water Master Test Kit, including 7 bottles…

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Evolution of Search Architectures in AI

Traditional search systems treat query processing as a fixed pipeline, which becomes a bottleneck for AI agents executing complex, multi-step tasks. Recent academic work, including the ICML 2024 CodeAct paper and Anthropic’s MCP framework, has argued for turning tools into executable code to improve scalability and precision. Perplexity’s SaC builds on these concepts but applies them specifically to search stacks, re-architecting retrieval primitives into composable, programmable components. Prior to this, most AI search approaches relied on static APIs or tool calls, which limited control and flexibility.

While Perplexity claims to have pioneered this specific architecture, the underlying idea of using code to orchestrate search is well-established in recent research. The novelty lies in their implementation and engineering, which involves re-engineering their entire search stack into atomic primitives that can be dynamically assembled by the model.

“SaC represents a meaningful step toward more flexible, controllable AI search pipelines, but independent validation is essential before widespread adoption.”

— Thorsten Meyer, AI researcher

Pro Tools Perpetual License NEW 1-year software download with updates + support for a year

Pro Tools Perpetual License NEW 1-year software download with updates + support for a year

Full version, permanent License of Avid Pro Tools. Includes 1-Year of software updates and upgrades.

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Validation and Benchmarking Challenges

It remains unclear whether the impressive benchmark results, especially on the proprietary WANDR test, can be independently replicated or validated. The benchmarks are either newly created by Perplexity or proprietary, raising questions about their generalizability. Additionally, the comparison models run on different GPT versions, which complicates direct evaluation. The broader applicability and robustness of SaC across diverse tasks and environments are still unproven.

Independent Testing and Broader Adoption

Next steps include independent researchers attempting to replicate Perplexity’s benchmark results, especially on WANDR. Further development will likely involve testing SaC across various models and tasks, as well as integrating it into real-world applications. Industry and academia will watch for validation of the approach’s scalability and robustness before considering widespread adoption. Perplexity may also release more detailed technical documentation and open benchmarks to facilitate external evaluation.

Key Questions

What is Search as Code (SaC)?

SaC is a new architecture proposed by Perplexity that allows AI models to generate and execute custom search pipelines by assembling modular primitives in code, rather than relying on static search APIs.

How does SaC improve upon traditional search methods?

SaC offers greater flexibility, control, and efficiency by enabling models to tailor retrieval and filtering processes dynamically, potentially reducing token usage and increasing accuracy for complex tasks.

Are the benchmark results reliable?

The results are promising but come from proprietary or newly created benchmarks. Independent validation is needed to confirm the performance claims.

Is this approach entirely new?

The idea of turning tools into executable code for AI agents is not new; recent academic work and industry efforts have explored similar concepts. SaC’s innovation lies in its engineering and specific application to search stacks.

What are the potential risks or limitations?

Risks include overreliance on proprietary benchmarks, potential challenges in scaling the approach, and uncertain generalizability across diverse tasks and models.

Source: ThorstenMeyerAI.com

Nothing in this article is financial or investment advice. Cryptocurrency and precious-metal investments carry significant risk — do your own research and consider a licensed advisor.
You May Also Like

10 Best Gaming Laptops for High-Refresh Play in 2026

Discover the best gaming laptops in 2026, balancing GPU, display, and portability for high-frame-rate gaming. Updated list for gamers seeking peak performance.

Maui’s Viral AI Art: Stunning Visual Effects That Are Captivating the Internet

How is Maui’s viral AI art redefining creativity and challenging traditional artistry? Discover the captivating visuals that have everyone talking.

Peter Schiff Critiques Proof of Work: Why It “Doesn’t Make Sense

You might be surprised by Peter Schiff’s harsh critique of proof of work—what implications does this have for the future of cryptocurrency?

Nvidia Takes a Tumble—Is This Your Chance to Buy Low and Profit Later?

Profit potential looms as Nvidia’s market cap plummets—will this downturn be your golden opportunity or a risky gamble?