[release/9.4] Add GitHub Models integration (#10170)#10313
Merged
danmoseley merged 2 commits intomicrosoft:release/9.4from Jul 10, 2025
Merged
[release/9.4] Add GitHub Models integration (#10170)#10313danmoseley merged 2 commits intomicrosoft:release/9.4from
danmoseley merged 2 commits intomicrosoft:release/9.4from
Conversation
* Add GitHub Models integration * Fix parameters and doc * Add package logo * Support GITHUB_TOKEN env * Fix test * Rename to GithubModel * Remove iisexpress in launch * Update playground/GitHubModelsEndToEnd/GitHubModelsEndToEnd.AppHost/GitHubModelsEndToEnd.AppHost.csproj Co-authored-by: Eric Erhardt <eric.erhardt@microsoft.com> * Define running state on github models * Add organization * Add tests * Add health checks * Add manifest files * Make health checks opt-in * Feedback * Fix test --------- Co-authored-by: Mitch Denny <midenn@microsoft.com> Co-authored-by: Eric Erhardt <eric.erhardt@microsoft.com>
Contributor
There was a problem hiding this comment.
Pull Request Overview
Backports the GitHub Models hosting integration to release/9.4, enabling Aspire applications to configure and use GitHub Models resources via a new extension, resource type, health check, and accompanying tests.
- Introduces
GitHubModelsExtensions,GitHubModelResource, andGitHubModelsHealthCheckin the hosting library - Adds comprehensive unit tests in
Aspire.Hosting.GitHub.Models.Tests - Updates README and playground projects to demonstrate end-to-end usage
Reviewed Changes
Copilot reviewed 28 out of 29 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/Aspire.Hosting.GitHub.Models/GitHubModelsExtensions.cs | Extension methods to add/configure GitHub Models resources and health checks |
| src/Aspire.Hosting.GitHub.Models/GitHubModelsHealthCheck.cs | IHealthCheck implementation querying the GitHub Models API |
| src/Aspire.Hosting.GitHub.Models/GitHubModelResource.cs | Resource class exposing model, organization, key, and connection string |
| tests/Aspire.Hosting.GitHub.Models.Tests/GitHubModelsExtensionTests.cs | Unit tests covering endpoints, API key, organization, and health check annotation |
Comments suppressed due to low confidence (2)
src/Aspire.Hosting.GitHub.Models/GitHubModelsExtensions.cs:40
- For consistency with official branding, consider updating "Github Models" to "GitHub Models".
new(CustomResourceKnownProperties.Source, "Github Models")
src/Aspire.Hosting.GitHub.Models/GitHubModelsHealthCheck.cs:19
- The
_resultfield is accessed without synchronization and could be set concurrently on multiple threads. Consider making access thread-safe (e.g., using a lock orInterlocked.CompareExchange).
private HealthCheckResult? _result;
danmoseley
reviewed
Jul 10, 2025
danmoseley
reviewed
Jul 10, 2025
Co-authored-by: Dan Moseley <danmose@microsoft.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
davidfowl
approved these changes
Jul 10, 2025
joperezr
approved these changes
Jul 10, 2025
danmoseley
pushed a commit
to danmoseley/aspire
that referenced
this pull request
Jul 10, 2025
eerhardt
added a commit
that referenced
this pull request
Jul 10, 2025
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Backport of #10170 to release/9.4
/cc @sebastienros
Customer Impact
Customers can use GitHub models easily in their Aspire applications.
Testing
Manual and new unit tests added.
Risk
Almost none. Just a new integration - no product changes outside of the new integration.
Regression?
No
Description
Adds a new hosting integration for GitHub Models.
Fixes #9569 #7649
Checklist
<remarks />and<code />elements on your triple slash comments?