HuggingFace MCP - Image Generation samples#25
Open
elbruno wants to merge 5 commits intomicrosoft:mainfrom
Open
HuggingFace MCP - Image Generation samples#25elbruno wants to merge 5 commits intomicrosoft:mainfrom
elbruno wants to merge 5 commits intomicrosoft:mainfrom
Conversation
…gging Face and Ollama APIs - Created Visual Studio solution file for the project. - Added MCP-01-HuggingFace project with necessary dependencies and implemented image generation logic. - Added MCP-02-HuggingFace-Ollama project with dependencies for OllamaSharp and implemented image generation logic. - Configured environment variables and user secrets for API keys and deployment names. - Implemented client setup for both Hugging Face and Ollama APIs to generate images based on user queries.
…CP-ConsoleApps - Created HFMCP.GenImage.sln with multiple projects including AppHost, ServiceDefaults, ApiService, and Web. - Established project configurations for Debug and Release modes. - Created HuggingFace-MCP-ConsoleApps.sln with solution properties and a unique SolutionGuid.
…gging Face MCP Server samples
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.
This pull request introduces a new feature for generating AI images using the Hugging Face MCP Server in C#. It includes updates to the repository's structure, documentation, and the addition of sample solutions, including console applications and a .NET Aspire Blazor WebApp. Additionally, it incorporates service defaults for resilience, health checks, and OpenTelemetry instrumentation. Below is a breakdown of the most important changes:
Documentation Updates:
Sample Solutions:
MCP-01-HuggingFaceandMCP-02-HuggingFace-Ollama) demonstrate connecting to the Hugging Face MCP Server, listing tools, and generating images from text prompts using cloud-hosted or local models.HFMCP.GenImage.Web) for AI-powered image generation with a user-friendly interface and extensible architecture. Includes setup instructions and supported models.Infrastructure Enhancements:
HFMCP.GenImage.ServiceDefaults) to provide common services such as resilience, health checks, and OpenTelemetry instrumentation for all service projects in the solution. [1] [2]HFMCP.GenImage.ApiService) with OpenAPI support, health checks, and default endpoints for interacting with AI models. [1] [2] [3]Application Host:
HFMCP.GenImage.AppHost) to manage the solution's components, including the API service and web frontend. Configured health checks and service references for seamless integration. [1] [2]Web Frontend Enhancements:
App.razorandMainLayout.razor, to structure the user interface and provide navigation. [1] [2]