Skip to content

Design unified provider interface (base classes, protocols) #3

@Aureliolo

Description

@Aureliolo

Context

Design the abstract interface that all LLM providers must implement. This is the foundation of the provider layer — every provider adapter (Anthropic, OpenRouter, Ollama, etc.) will conform to this interface, ensuring consistent behavior across the framework.

Acceptance Criteria

  • Abstract base class or Protocol defining the unified provider interface
  • completion(messages, tools, config) -> response signature per spec 9.1
  • Streaming support in the interface design
  • Provider configuration model (API keys, base URLs, timeouts, etc.)
  • Model capability description (context window size, tool use support, vision support)
  • Cost information interface (input/output token pricing per model)
  • Unit tests for interface contracts and config validation

Dependencies

None — this is the foundation for all provider work.

Design Spec Reference

Section 9.1 — Provider Interface Design

Metadata

Metadata

Assignees

No one assigned

    Labels

    prio:criticalBlocks other work, must do firstscope:medium1-3 days of workspec:providersDESIGN_SPEC Section 9 - Model Provider Layertype:featureNew feature implementation

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions