-
Notifications
You must be signed in to change notification settings - Fork 1
v0.3.0 #45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
v0.3.0 #45
Conversation
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
feat!: migrate embeddings to Cloud API infrastructure Migrate DartmouthEmbeddings from HuggingFace-based endpoints to the new Cloud API infrastructure using OpenAI-compatible interface. This aligns the embeddings implementation with ChatDartmouthCloud for consistency. Key changes: - Replace HuggingFaceEndpointEmbeddings base class with OpenAIEmbeddings - Switch from JWT authentication to API key-based auth - Update model listing to use CloudModelListing with tag/capability filtering - Add filter_dartmouth_chat_models() utility for advanced model filtering - Improve test coverage with parametrized embedding model tests - Fix redirect handling by disabling follow_redirects in HTTP clients BREAKING CHANGE: Authentication now requires DARTMOUTH_CHAT_API_KEY environment variable instead of DARTMOUTH_API_KEY. Constructor parameter renamed from dartmouth_api_key to dartmouth_chat_api_key.
) - Merge ChatDartmouthCloud into ChatDartmouth as unified interface - ChatDartmouth now serves both free on-prem and paid cloud models - Update default model to openai.gpt-oss-120b - Update test suite - Consolidate chat model tests to use unified ChatDartmouth interface - Remove duplicate cloud-specific test cases - Update test assertions and model references This consolidation simplifies the API surface and makes it clearer that ChatDartmouth is the single entry point for all chat model access, regardless of whether models are hosted on-prem or in the cloud. BREAKING CHANGE: The model IDs for users of the old ChatDartmouth have changed. Use ChatDartmouth.list() to find the new one.
* refactor!: consolidate chat model interfaces and improve type hints - Merge ChatDartmouthCloud into ChatDartmouth as unified interface - ChatDartmouth now serves both free on-prem and paid cloud models - Update default model to openai.gpt-oss-120b - Update test suite - Consolidate chat model tests to use unified ChatDartmouth interface - Remove duplicate cloud-specific test cases - Update test assertions and model references This consolidation simplifies the API surface and makes it clearer that ChatDartmouth is the single entry point for all chat model access, regardless of whether models are hosted on-prem or in the cloud. BREAKING CHANGE: The model IDs for users of the old ChatDartmouth have changed. Use ChatDartmouth.list() to find the new one. * remove mentions of ChatDartmouthCloud
refactor!: introduce ModelInfo class for type-safe model representation Replace dictionary-based model listings with a structured ModelInfo Pydantic class to improve type safety, validation, and developer experience. BREAKING CHANGE: Model listing methods now return list[ModelInfo] instead of list[dict]. Code using dictionary access (model["id"]) must be updated to use attribute access (model.id). Changes: - Add ModelInfo Pydantic model with properties: id, name, description, is_embedding, capabilities, is_local, and cost - Implement smart validators to flatten nested metadata and extract tags - Update ChatDartmouth.list() return type to list[ModelInfo] - Update DartmouthEmbeddings.list() return type to list[ModelInfo] - Update CloudModelListing.list() return type to list[ModelInfo] - Remove filter_dartmouth_chat_models() utility function (58 lines) - Simplify filtering logic using is_embedding property - Update tests to use attribute access Benefits: - Pydantic validation ensures data conformity - Better IDE autocomplete and type hints - Reduced code complexity (-58 lines of filtering logic) - Centralized model representation - Clearer API with documented properties Files changed: 5 files (+112, -81)
This was referenced Oct 16, 2025
Closed
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.
🎯 Overview
This PR introduces version 0.3.0, a major update that unifies the API interface, improves model management, and enhances the overall developer experience. The release consolidates chat model interfaces and modernizes the embeddings system while maintaining backward compatibility through deprecation warnings.
🚀 Major Changes
1. Unified Chat Model Interface
Consolidated
ChatDartmouthandChatDartmouthCloudChatDartmouthnow handles both on-premises and cloud-based modelsChatDartmouthClouddeprecated with graceful fallback toChatDartmouth"llama-3-1-8b-instruct"to"openai.gpt-oss-120b"Before:
After:
2. Enhanced Model Listing
New
ModelInfoPydantic ClassKey Attributes:
id: Model identifier for API callsname: Human-readable display namedescription: Detailed model descriptioncapabilities: List of features (vision, tool calling, reasoning, etc.)is_local: Boolean indicating on-premises vs cloud hostingcost: Relative cost indicator ("free","$"to"$$$$")is_embedding: Flag for embedding modelsReturn Type Changes:
ChatDartmouth.list():list[dict]→list[ModelInfo]DartmouthEmbeddings.list():list[dict]→list[ModelInfo]3. Embeddings Modernization
Infrastructure Changes:
HuggingFaceEndpointEmbeddingstoOpenAIEmbeddingsDARTMOUTH_API_KEYtoDARTMOUTH_CHAT_API_KEY"baai.bge-large-en-v1-5")New Features:
dimensionsparameter for controlling output embedding size4. Documentation Enhancements
New Migration Guide (
docs/migration.rst)