xAI Grok
Configuration options for xAI Grok models in Weaver
xAI Grok Provider Options
Weaver supports provider-specific configuration options for xAI Grok models. These can be set in the Provider Options (JSON) field in the chat configuration settings.
Available Provider Options
Reasoning Effort
Control reasoning depth for Grok reasoning models.
Possible values:
"low"– Minimal reasoning (faster)"high"– Extensive reasoning (slower but more thorough)
Live Search
Query live data from sources including web, news, X posts, and RSS feeds to provide real-time information in responses. This is different than Weaver's built in web search tool and you SHOULD NOT enable both at the same time.
Note: To enable inline citations, please use the following system prompt:
Use the searchParameters provider option to enable live search
Search Parameters
mode (required):
"off"– Disables search and uses the model without accessing additional information"auto"– Live search is available to the model, but the model automatically decides whether to perform live search"on"– Enables live search
returnCitations (optional, default: true):
true– Returns data source citations in the responsefalse– Does not return citations
maxSearchResults (optional, default: 20):
- Maximum number of data sources to consider in the query
- Integer value
fromDate and toDate (optional):
- Restrict the date range of search data
- Format: ISO8601 (
"YYYY-MM-DD") - Can be used independently
Data Sources
sources (optional, defaults to ["web", "x"]):
Web Search ("type": "web")
Search websites across the internet.
Parameters:
"country"– ISO alpha-2 country code (e.g.,"US","GB","CH")"excludedWebsites"– Array of up to 5 websites to exclude (cannot use withallowedWebsites)"allowedWebsites"– Array of up to 5 websites to search only (cannot use withexcludedWebsites)"safeSearch"– Boolean, defaulttrue
X Posts ("type": "x")
Search X (formerly Twitter) posts.
Parameters:
"xHandles"– Array of X usernames to search posts from
News ("type": "news")
Search news sources.
Parameters:
"country"– ISO alpha-2 country code"excludedWebsites"– Array of up to 5 news websites to exclude"safeSearch"– Boolean, defaulttrue
RSS Feeds ("type": "rss")
Retrieve data from RSS feeds.
Parameters:
"links"– Array containing one RSS feed URL
User Identifier
Provide a unique identifier for the end user.
Format: String identifier that helps xAI monitor usage and detect potential abuse
The user identifier is used for:
- Usage tracking
- Abuse detection
- Rate limiting
- Debugging assistance
This parameter is optional but recommended, especially for applications with multiple users.
Model Compatibility
Check the xAI documentation for the most up-to-date compatibility information. AI SDK