extract_with_llm
Extract structured data from URLs or text using natural-language prompts, with optional LLM provider selection.
Instructions
Extract data from a URL or text using a natural-language prompt. Defaults to a local Ollama model (http://localhost:11434, no API key required) and picks an installed model itself; pass model to choose one, or provider: "openai" or "anthropic" with the matching API key to use a cloud model instead. Not for known selectors (scrape_structured) or a schema-shaped result (extract_structured). Call list_ollama_models only when a model name is rejected. Cost: 3 credits plus your LLM provider's own charge.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | URL to fetch and extract from (one of url/content required) | |
| model | No | Override the model. For ollama, pass a name returned by list_ollama_models (e.g. 'llama3.2', 'qwen2.5:7b'). Defaults: openai='gpt-4o-mini', anthropic='claude-haiku-4-5-20251001', ollama='llama3.2' or $OLLAMA_DEFAULT_MODEL. | |
| prompt | Yes | Natural-language extraction instruction | |
| schema | No | Optional JSON-schema for output shape (used as Ollama structured-outputs format when provider is 'ollama') | |
| content | No | Pre-fetched text to extract from (one of url/content required) | |
| provider | No | LLM provider. Defaults to 'ollama' (local, no key, http://localhost:11434). Use 'openai' or 'anthropic' for cloud models (requires the matching API key). | auto |
| maxTokens | No | Maximum output tokens | |
| user_agent | No | Override the outbound User-Agent. CrawlForge identifies itself honestly by default; use this only for targets you have your own agreement with. | |
| respect_robots | No | Respect the target site's robots.txt (default: true). Setting this to false is honoured, returns a warning in the response, and is recorded against your API key — it is your decision, not a silent default. | |
| verify_numbers | No | Numeric provenance guard (default: true): every price or numeric value the LLM returns must appear literally in the page source, else it is returned as null with a reason in `provenance.unverified`. Set false to get the model's raw numbers back, including ones it derived (a count, a sum, a total) rather than read off the page. |