Conversation
There was a problem hiding this comment.
Pull request overview
This pull request unifies test functions about LLM schemas by removing model-specific generic type parameters and consolidating multiple test files into single, simpler tests. The refactoring simplifies the API by removing the Model generic parameter from ILlmSchema, ILlmFunction, and related types, making the codebase easier to maintain.
Key changes:
- Removed generic
Modeltype parameters fromILlmFunction,ILlmSchema, and related interfaces - Consolidated multiple model-specific test functions into single unified tests
- Updated
LlmSchemaComposerto exportgetConfigas a public utility function - Replaced model-specific type checkers (e.g.,
ChatGptTypeChecker,LlamaTypeChecker) with unifiedLlmTypeChecker
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
test/src/utils/LlmFunctionCaller.ts |
Removed generic type parameters from IProps and simplified function signatures |
test/src/utils/LlmApplicationFactory.ts |
Removed model-specific generics and updated to use LlmSchemaComposer.getConfig() |
test/src/features/mcp/validate_mcp_application.ts |
Deleted file - functionality consolidated into new unified test |
test/src/features/mcp/test_mcp_schema_ref.ts |
Updated to use non-generic types and unified LlmTypeChecker |
test/src/features/mcp/test_mcp_application.ts |
New consolidated test file replacing model-specific tests |
test/src/features/llm/schema/validate_llm_type_checker_cover_array.ts |
Deleted file - replaced by unified test |
test/src/features/llm/schema/validate_llm_type_checker_cover_any.ts |
Deleted file - replaced by unified test |
test/src/features/llm/schema/test_llm_type_checker_cover_array.ts |
New unified test replacing 5 model-specific tests |
test/src/features/llm/schema/test_llm_type_checker_cover_any.ts |
New unified test replacing 5 model-specific tests |
test/src/features/llm/schema/test_llm_schema_tuple.ts |
Simplified by removing model-specific logic and generics |
test/src/features/llm/schema/test_llm_schema_discriminator.ts |
Updated to use unified LlmTypeChecker.isAnyOf and x-discriminator |
src/composers/LlmSchemaComposer.ts |
Made getConfig a public export and updated schema to accept optional config |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 99 out of 99 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
* Unified to `ILlmSchema`, no more separation. (#213) * Unified to `ILlmSchema` * Complete the new `ILlmSchema` type * detailed description comments * Update src/structures/ILlmSchema.ts Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Update src/structures/ILlmSchema.ts Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Update src/structures/ILlmSchema.ts Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * prettier --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Unify `ILlmApplication` and `ILlmFunction` too. (#214) * Universal `LlmSchemaComposer` (#215) * Universal LlmSchemaComposer * complete `LlmSchemaComposer.schema()` function * fix logics * Universal `LlmTypeChecker` (#216) * Universal `LlmTypeChecker` * Fix `LlmSchemaComposer` to utilize `LlmTypeCheckeer` * JSDoc comments on universal LLM types. (#217) * Universal `HttpLlm` (#218) * Universal `HttpLlm` * Update src/HttpLlm.ts Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Update src/HttpLlm.ts Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * fix configuration comments * fix more thing --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Remove individual LLM schemas (#219) * Remove individual LLM schemas * fix * Unify test functions about LLM schemas (#220) * Unify test functions about LLM schemas * Update test/src/utils/LlmApplicationFactory.ts Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * fixed most of test functions * fixed most of test functions * completed everything --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Publish v6 * Re-write README for universal LLM schemas (#221) --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
No description provided.