Class RagRequest.Builder
- All Implemented Interfaces:
RagRequest._FinalStage,RagRequest.QueryStage
- Enclosing class:
RagRequest
-
Method Summary
Modifier and TypeMethodDescriptionadditionalProperties(Map<String, Object> additionalProperties) additionalProperty(String key, Object value) allowGlobalRegion(Boolean allowGlobalRegion) Opt this request into global (non-US) region serving for lower cost.allowGlobalRegion(Optional<Boolean> allowGlobalRegion) Opt this request into global (non-US) region serving for lower cost.build()from(RagRequest other) instructions(String instructions) Optional system prompt that overrides the default.instructions(Optional<String> instructions) Optional system prompt that overrides the default.Maximum number of tokens to generate.Maximum number of tokens to generate.Model alias to use, from the list returned byGET /v1/models.Model alias to use, from the list returned byGET /v1/models.The natural-language question to answer over your indexed content.temperature(Float temperature) Sampling temperature.temperature(Optional<Float> temperature) Sampling temperature.
-
Method Details
-
from
- Specified by:
fromin interfaceRagRequest.QueryStage
-
query
The natural-language question to answer over your indexed content.
The natural-language question to answer over your indexed content.
- Specified by:
queryin interfaceRagRequest.QueryStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
allowGlobalRegion
Opt this request into global (non-US) region serving for lower cost. Requires a signed global-processing waiver on your account that permits per-request override; otherwise the request is rejected with 403. When omitted, the request follows your account's default residency setting.
- Specified by:
allowGlobalRegionin interfaceRagRequest._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
allowGlobalRegion
Opt this request into global (non-US) region serving for lower cost. Requires a signed global-processing waiver on your account that permits per-request override; otherwise the request is rejected with 403. When omitted, the request follows your account's default residency setting.
- Specified by:
allowGlobalRegionin interfaceRagRequest._FinalStage
-
temperature
Sampling temperature. Defaults to 0.3, favoring more deterministic, retrieval-grounded answers.
- Specified by:
temperaturein interfaceRagRequest._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
temperature
Sampling temperature. Defaults to 0.3, favoring more deterministic, retrieval-grounded answers.
- Specified by:
temperaturein interfaceRagRequest._FinalStage
-
maxTokens
Maximum number of tokens to generate. Defaults to 1024; the maximum is 4096.
- Specified by:
maxTokensin interfaceRagRequest._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
maxTokens
Maximum number of tokens to generate. Defaults to 1024; the maximum is 4096.
- Specified by:
maxTokensin interfaceRagRequest._FinalStage
-
search
- Specified by:
searchin interfaceRagRequest._FinalStage
-
search
- Specified by:
searchin interfaceRagRequest._FinalStage
-
model
Model alias to use, from the list returned by
GET /v1/models. Defaults toclaude-haiku-4-5.- Specified by:
modelin interfaceRagRequest._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
model
Model alias to use, from the list returned by
GET /v1/models. Defaults toclaude-haiku-4-5.- Specified by:
modelin interfaceRagRequest._FinalStage
-
instructions
Optional system prompt that overrides the default. Defaults to a generic instruction to answer using only the provided context.
- Specified by:
instructionsin interfaceRagRequest._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
instructions
Optional system prompt that overrides the default. Defaults to a generic instruction to answer using only the provided context.
- Specified by:
instructionsin interfaceRagRequest._FinalStage
-
build
- Specified by:
buildin interfaceRagRequest._FinalStage
-
additionalProperty
- Specified by:
additionalPropertyin interfaceRagRequest._FinalStage
-
additionalProperties
- Specified by:
additionalPropertiesin interfaceRagRequest._FinalStage
-