跳到正文
LlamaIndex:产品、工程与评测·· 2 天前AI 评分52

LlamaIndex Extract V2.6 推出 max effort 模式提升复杂文档抽取质量

Extract V2.6: Max Effort

AI 导读

LlamaIndex 为 Extract 的 agentic_plus 档推出 max effort 设置,按抽取复杂度和所需计算量浮动计费,主打复杂文档的最高质量抽取。

正文 · 原文

Today we’re introducing max effort, a new setting for Extract’s agentic_plus tier. It is designed to deliver our highest-quality extraction and reduce the risk of missing or incorrect data on your most critical and complex documents. Max effort uses variable billing based on the computation required.

As part of our onboarding process for many enterprise customers, we conduct a proof of concept where we evaluate various Extract configurations on samples of the datasets they plan to run in production. An important part of this process is figuring out the optimal tier and schema that will meet the needs of their business while staying within budget. In many cases, the cost that matters more than the price of the extraction service is the cost of a missing or incorrect value. Customers ask, “Can we pay more to unlock even higher quality?”

With max effort on agentic_plus , the answer is now yes. We have developed methods that significantly improve extraction on some of the hardest documents. On ExtractBench Pro, Value F1 rose from 77.7 with standard Agentic Plus to 92.9 with max effort. When max effort is set, billing varies according to the complexity of the extraction and the computation required. That additional quality comes with more computation and can cost more than a standard agentic_plus job.

You can see in the chart below how agentic_plus with max effort extends the top end of our ExtractBench Pro cost and quality curve, offering another option for its hardest challenges.

Explore the documents, schemas, and answer keys.

ExtractBench Pro · 100 documents

Max effort extends the top end of our cost and quality curve

Cost per page against extraction quality. Focus a system to inspect both scores.

  • LlamaExtract
  • Coding agents
  • Extraction APIs
  • 30-minute limit
  • Without the limit

How it works

For example, one area where a strict budget per page can limit extraction quality is reading visual charts. To make visual content in a PDF readable by a model, the page is rendered into an image. To keep standard agentic_plus pricing predictable, we make tradeoffs in image resolution that work for most documents. But on specialized chart-based documents, key data can become too small or blurry to read.

With max effort, Extract can examine relevant regions at higher resolution when needed to pull out the pertinent information. The visualizations below show how that extra detail helps on some of our most visually complex documents.

The benefit of max effort is that it can apply more advanced extraction techniques as a document requires them. Standard tiers also adapt their work, but absorb that variability within a fixed price per page. With max effort, some documents can be pricier when additional work offers a large quality improvement, while in cases where standard methods are sufficient, the cost increase can be marginal.

Standard Agentic Plus → Max effort

Two different cost and quality tradeoffs

Long dense pages: F1 12.7 to 98.4; billed cost per document $0.075 to $3.82.

Custom terminology: F1 98.6 to 99.0; billed cost per document $3.25 to $3.33.

Compare all six categories
Standard Agentic Plus → Max effort. Value F1 uses a 30-minute limit.
CategoryValue F1Mean billed cost per document
Long dense pages12.7 → 98.4$0.075 → $3.82
Relational diagrams49.3 → 99.4$1.32 → $3.36
Document conventions97.5 → 99.5$2.98 → $4.29
Custom terminology98.6 → 99.0$3.25 → $3.33
Charts94.3 → 93.4$1.67 → $2.54
Counting67.6 → 58.3$1.41 → $1.50

If you would like to try agentic_plus with max effort, follow the guide below. We recommend running a representative sample of your documents with your existing schema before migrating to max effort. This will give you an idea of both the quality and cost you can expect with the configuration.

Use max when

  • Standard agentic_plus quality falls short
  • Your document is highly complex and dense
  • There are lots of visual elements such as charts or diagrams to interpret
  • Extraction errors are costly to your business

Extract V2.6 · Beta

Try max effort on your documents

Use Agentic Plus with effort set to max. Start with a small sample so you can compare quality and cost.

Python SDK

python -m pip install -U llama-cloud pydantic

The Python example takes your API key and a local PDF. Replace its sample schema with your own.

import os
import sys
from pathlib import Path
from llama_cloud import LlamaCloud
from pydantic import BaseModel

class Invoice(BaseModel):
    total_amount: float

client = LlamaCloud(
    api_key=os.environ["LLAMA_CLOUD_API_KEY"],
)
file = client.files.create(
    file=Path(sys.argv[1]),
    purpose="extract",
)
job = client.extract.run(
    file_input=file.id,
    configuration={
        "tier": "agentic_plus",
        "effort": "max",
        "version": "latest",
        "extraction_target": "per_doc",
        "data_schema": Invoice.model_json_schema(),
        "confidence_scores": True,
        "cite_sources": True,
    },
)
result = client.extract.get(
    job.id, expand=["extract_metadata"],
)
print(result.extract_result)
print(result.extract_metadata)

Configuration guide Set up your document, schema, and API key. (opens in a new tab)

来源:LlamaIndex:产品、工程与评测 · llamaindex.ai