- Updated `AskEndpoints.cs` to include `MinimalHelpers.FluentValidation` and standardize endpoint descriptions.
- Integrated FluentValidation in `Program.cs` and registered validators.
- Modified `SqlDatabaseVectorSearch.csproj` to add necessary package references for FluentValidation.
- Created `QuestionValidator` class to enforce validation rules on the `Question` model.
Updated `ChatService.cs` to improve user guidance for unavailable information responses. Added multiple phrases to ensure clarity and context relevance.
Modified `SqlDatabaseVectorSearch.csproj` to upgrade `Microsoft.SemanticKernel` from `1.45.0` to `1.47.0`, and incremented versions for `Swashbuckle.AspNetCore.SwaggerUI` and `TinyHelpers.AspNetCore` to `8.1.1` and `4.0.25`, respectively, for bug fixes and improvements.
Updated versions of several package references in the
`SqlDatabaseVectorSearch.csproj` file, including:
- `Microsoft.AspNetCore.OpenApi`, `Microsoft.EntityFrameworkCore.SqlServer`,
and `Microsoft.EntityFrameworkCore.Tools` from `9.0.3` to `9.0.4`.
- `Microsoft.Extensions.Caching.Hybrid` and
`Microsoft.Extensions.Http.Resilience` from `9.3.0` to `9.4.0`.
- `TinyHelpers.AspNetCore` from `4.0.22` to `4.0.23`.
These updates aim to incorporate bug fixes, new features,
and improvements from the latest versions.
Clarified the `Dimensions` property requirements for embedding models that support shortening. Added information about the maximum supported size for the `VECTOR` type (1998) and the need to update database migrations accordingly.
Updated `Swashbuckle.AspNetCore.SwaggerUI` from `8.0.0` to `8.1.0` and `TinyHelpers.AspNetCore` from `4.0.21` to `4.0.22`. Removed previous versions in favor of the latest updates.
Updated token count keys from `inputTokenCount`, `outputTokenCount`, and `totalTokenCount` to `promptTokens`, `completionTokens`, and `totalTokens` for improved clarity. Modified `question` and `answer` fields to align with the new structure, with some values set to `null` to indicate streaming state.
- Updated `TokenUsage` class properties to `PromptTokens` and `CompletionTokens`.
- Modified `Ask.razor` to display new token counts.
- Added logger to `ChatService` constructor for improved logging.
- Implemented logging for token usage in `ChatService` methods.
- Changed logging level to `Debug` for paragraph storage in `VectorSearchService`.
- Updated logging configuration in `appsettings.Development.json` for better visibility.
- Updated `Documents.razor` to change form submission handler to `UploadFile` and added `id` to `InputFile`.
- Implemented `UploadFile` method to handle file uploads and reset input after successful upload.
- Upgraded package references in `SqlDatabaseVectorSearch.csproj` for `Microsoft.SemanticKernel` and `Swashbuckle.AspNetCore.SwaggerUI`.
- Introduced `resetFileInput` function in `functions.js` to clear file input selections.
Incremented versions for several packages in `SqlDatabaseVectorSearch.csproj`, including:
- `Microsoft.AspNetCore.OpenApi` to `9.0.3`
- `Microsoft.EntityFrameworkCore.SqlServer` to `9.0.3`
- `Microsoft.EntityFrameworkCore.Tools` to `9.0.3`
- `Microsoft.Extensions.Caching.Hybrid` to `9.3.0` (removed preview version)
- `Microsoft.Extensions.Http.Resilience` to `9.3.0`
- `Microsoft.SemanticKernel` to `1.41.0`
- `TinyHelpers.AspNetCore` to `4.0.21`
Added functionality to update userMessage.Text with the
reformulated question when the streaming response starts.
This improvement provides immediate feedback to users,
enhancing the overall user experience.
Replaced `UploadDocumentRequest` with `UploadDocument` class to streamline data management. Updated `EditForm` to bind directly to the new model, removing the `EditContext` and `HandleFileSelected` method. Adjusted validation and submission logic to work with the new structure, enhancing clarity and maintainability.
- Modify `AddHybridCache` to include local cache expiration.
- Change resilience handler addition to use configure method.
- Set total request timeout to 2 minutes.
Modified the `AddStandardResilienceHandler` method in
`Program.cs` to accept an `options` parameter. This allows
for setting a `TotalRequestTimeout` of 2 minutes, enhancing
the resilience handling of HTTP requests.
- Separated endpoint definitions into `AskEndpoints` and `DocumentEndpoints` classes for better organization and maintainability.
- Removed inline endpoint definitions in `Program.cs` and replaced with `app.MapEndpoints();`.
- Updated `Microsoft.SemanticKernel` package from version `1.40.0` to `1.40.1`.
- Replaced `MinimalHelpers.OpenApi` with `MinimalHelpers.Routing.Analyzers` in project dependencies.
- Defined new POST endpoints for asking questions and document management with detailed API documentation.
- Enhanced code structure for easier management and future extensibility.
- Renamed `CopyToClipboard` to `CopyToClipboardAsync` in `Ask.razor` for clarity on asynchronous operation.
- Added `ElementReference` for `chat` and introduced `EnsureMessageIsVisibleAsync` to improve message visibility.
- Modified streaming state handling for better readability.
- Made `FormatTokenUsage` and `FormatTokenUsageDetails` methods static and adjusted their implementations.
- Enhanced styling in `Home.razor` with a new paragraph class.
- Updated `SqlDatabaseVectorSearch.csproj` to upgrade `Microsoft.SemanticKernel` and other package versions.
- Added a new `scrollTo` function in `functions.js` to improve user experience by ensuring elements are visible.
Refactor Home.razor to replace markdown loading with static HTML content for the SQL Database Vector Search application, including a main heading and feature list. Remove the IWebHostEnvironment dependency.
Upgrade package references in SqlDatabaseVectorSearch.csproj for Microsoft.ML.Tokenizers and Microsoft.SemanticKernel.
Revise docs.md to focus on supported features instead of setup instructions.
Add new SVG files (openai.svg and sqldatabase.svg) for application icons.
- Removed the `FooterSection` from `MainLayout.razor` and its associated styles in `MainLayout.razor.css`.
- Added top margin to the card in `Ask.razor` for improved spacing.
- Increased height of `.card-body` in both default and media queries for better content display.
- Added CSS rules in `app.css` to reset margin and padding for `body` and `html`.
- Modified binary file `SqlDatabaseVectorSearch_WebApp.png`.
Updated README.md to clarify functionality and added a link to OpenAPI documentation in MainLayout.razor. Removed unnecessary methods from RequestExtensions.cs for simplification. Streamlined docs.md by removing detailed JSON response examples while retaining key information about response streaming.
- Enhanced README.md with new sections and images for the web app and API.
- Clarified setup instructions and reorganized content.
- Removed SqlDatabaseVectorSearch.png; modified favicon.png and SqlDatabaseVectorSearch_API.png.
- Added new image file: SqlDatabaseVectorSearch_WebApp.png.
Clarified the need to update the Database Migration when changing the size of the `VECTOR` column to match the embedding model. This replaces the previous mention that lacked a specific link to the Database Migration.
- Updated `Documents.razor` to show a loading spinner when documents are being fetched, introducing an `isLoading` state variable.
- Added `ConfigureDatabaseAsync` method in `Program.cs` for handling database migrations at startup.
- Modified `SqlDatabaseVectorSearch.csproj` to include `Microsoft.EntityFrameworkCore.Tools` for migration management.
- Enhanced documentation in `docs.md` regarding the `Dimensions` property and `VECTOR` column size requirements.
- Created initial migration files to define the database schema for `Documents` and `DocumentChunks` tables.
- Defined `Document` and `DocumentChunk` entities in migration files for data storage and retrieval.
- Rearranged navigation items in `MainLayout.razor`.
- Removed `ToastService` injection and modified key handling in `Ask.razor`.
- Downgraded `Microsoft.SemanticKernel` version in project file.
- Updated CSS styles for sidebar brand icon and navigation item states.
- Fixed error message content in `.blazor-error-boundary` class.
- Removed clipboard icon reference and added ElementReference for input field in Ask.razor.
- Introduced OnAfterRenderAsync method to manage input focus.
- Updated app.css with new CSS variables for enhanced sidebar styling.
- Added setFocus function in functions.js to manage element focus.
- Specified `Type` attributes for buttons in `Ask.razor` to clarify their intended behavior.
- Added `h1:focus` style in `app.css` to remove default outline for focused headings.
- Updated `MainLayout.razor` to include a footer displaying the framework description, styled with new CSS.
- Modified `MainLayout.razor.css` to add styles for the footer.
- Enhanced `Ask.razor` with a new `ToastService` for user notifications and improved message handling.
- Updated `Documents.razor` to restrict file uploads to specific formats and improved error handling with notifications for uploads and deletions.
Added a line to the `embeddingQuestion` string to emphasize that the reformulated question must explicitly contain the subject. This change clarifies the requirements for the chat service's functionality.
Updated `ChatService` to enforce a message limit based on the new `MessageLimit` property in `AppSettings`. Excess messages are removed before updating the cache to optimize performance. Adjusted `appsettings.json` to reflect the new configuration, changing `MaxInputTokens` from 16385 to 16384 and adding `MessageLimit` with a default value of 20.
Updated the `embeddingQuestion` string to require that the reformulated question explicitly contains the subject of the original question. The reformulation must also be in the same language as the user's question and should not include phrases like "in this chat" or "search for."
- Updated `MainLayout.razor` to include a `Toasts` component and removed the `FooterSection`.
- Replaced `Toasts` in `Documents.razor` with a new `ToastService` for notifications, enhancing document upload and deletion processes.
- Modified `Home.razor` to read markdown content from a local file using `IWebHostEnvironment`.
- Removed HTTP client service registration in `Program.cs` and adjusted resilience handling configuration.
- Updated `ChatService.cs` with guidelines for question reformulation.
- Added `docs.md` with setup instructions and details on supported features for the SQL Database Vector Search application.