Building an LLM Client in Python
Don't let vendor SDKs leak into your business logic. Build one clean client. Swap providers later without touching your app. The Interface from abc import ABC, abstractmethod from dataclasses import dataclass @dataclass class LLMResponse: text: str tokens_used: int model: str...
Python OOP for GenAI Projects
The previous post covered classes as a practical tool for managing state in AI applications — conversations, sessions, agents. This one zooms out to the bigger picture: object-oriented programming (OOP) as a design philosophy, and specifically the four core principles —...