Module agentforge4j.llm.api
Package com.agentforge4j.llm.api
package com.agentforge4j.llm.api
Public LLM invocation contract shared by runtime callers and provider adapters.
Key types:
LlmClient— executes requests for one provider idLlmExecutionRequest— immutable invocation parametersLlmExecutionResponse— model output and optional token usageLlmInvocationException— failures from clients or transportLlmRetryPolicy— optional retry settings exposed by clientsTokenUsageReport— provider token usage for an invocationPromptLayerBoundaries— stable-prefix layer byte boundaries
-
ClassDescriptionExecutes LLM requests for a single registered provider (for example OpenAI, Ollama, or Claude).Immutable parameters for a single LLM invocation.Result of a single
LlmClientinvocation.Thrown when an LLM request fails due to network issues, HTTP errors, invalid responses, or provider-specific validation failures.Optional run/workflow/step/agent identity for a single LLM invocation.Immutable retry settings for a retrying LLM client: attempt cap, decorrelated jitter bounds, and optional total elapsed budget.Capability tier an agent or step declares instead of a concrete, versioned model string.Thrown when a declaredModelTiercannot be resolved to a concrete model string for the selected provider — that is, no mapping exists after shipped defaults and any operator overrides have been applied.Resolves a declaredModelTierto a concrete, versioned model string for a given provider.Byte offsets marking the end of each prompt layer in an assembled provider request body.Token usage reported by an LLM provider for a single invocation.