feat(ai): modernize providers and add LiteLLM/Ollama adapters#962
Merged
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: bc19b6be2b
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Contributor
📦 Version Bump PreviewWhen this PR is merged, packages will receive a minor What happens on merge?
No manual intervention needed! 🎉 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
This PR modernizes
@happyvertical/aias a broader provider cleanup release rather than a single-provider patch.It adds first-class
litellmandollamaadapters, updates provider and auto-detection wiring, improves model discovery and capability reporting, and fills in several previously thin or misleading provider paths.It also expands integration coverage so we can validate real gateways and local model hosts instead of relying only on mocked behavior.
Highlights
llm.happyvertical.comWhy
We want to make heavy use of LiteLLM and local Ollama infrastructure, and the package had started to accumulate a mix of OpenAI-shaped assumptions, partial provider implementations, and uneven integration coverage.
This release closes those gaps so the package is a better fit for heterogeneous model routing, local model hosts, and current SDK behavior.
Impact
Consumers can now configure
type: 'litellm'ortype: 'ollama'directly instead of routing everything through the OpenAI adapter.Provider selection, capability reporting, model discovery, and observability are more honest across the supported backends, and the package now has stronger live validation for the environments we actually run.
Validation
pnpm --filter @happyvertical/ai buildset -a && source .env.local && set +a && pnpm --filter @happyvertical/ai testOLLAMA_HOST=snail-ollama:11434 OLLAMA_INTEGRATION=1 pnpm --filter @happyvertical/ai test -- src/ollama.integration.test.tsOLLAMA_HOST=warthog-ollama:11434 OLLAMA_INTEGRATION=1 pnpm --filter @happyvertical/ai test -- src/ollama.integration.test.tsturbo run typecheck