mechaharness.inference.base
Inference Strategy: pluggable backends for raw model calls.
Client code depends on InferenceStrategy, not on a specific provider.
Concrete strategies adapt OpenAI, Anthropic, LM Studio, vLLM, etc.
- class mechaharness.inference.base.InferenceStrategy[source]
Bases:
CompleterStrategy interface for talking to an inference engine.
- capability_profile() CapabilityProfile[source]
Declared skills used for cost pricing of this backend.
- abstractmethod async complete(request: CompletionRequest) CompletionResponse[source]
Run a single non-streaming completion.
- async stream(request: CompletionRequest) AsyncIterator[str][source]
Optional token stream. Default falls back to a single complete().