-
-
Notifications
You must be signed in to change notification settings - Fork 9
Universal HttpLlm
#218
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
Universal HttpLlm
#218
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This pull request refactors the HTTP LLM application codebase by removing generic type parameters and consolidating configuration handling. The changes simplify function signatures throughout the codebase and unify configuration interfaces from IOptions<Model> to IConfig.
Key Changes:
- Removed generic type parameters (
<Model extends ILlmSchema.Model>) from all interfaces and functions, includingHttpLlm,HttpLlmComposer,HttpLlmFunctionFetcher, andLlmDataMerger - Consolidated configuration by replacing
IHttpLlmApplication.IOptionswithIHttpLlmApplication.IConfigand changed properties from optional to required with explicit defaults - Updated documentation comments throughout the codebase to reflect the new configuration structure and remove references to deprecated keyword arguments and model generics
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
src/HttpLlm.ts |
Removed generic type parameters from all function signatures, updated configuration handling to use unified IConfig, and revised documentation to reflect the new structure |
src/structures/IHttpLlmApplication.ts |
Renamed IOptions interface to IConfig, changed properties from optional to required with default values documented, and updated property name from options to config |
src/composers/HttpLlmApplicationComposer.ts |
Removed generic type parameters from composer functions, implemented explicit config initialization with default values, and simplified function signatures throughout |
src/http/HttpLlmFunctionFetcher.ts |
Removed generic type parameters from execute and propagate functions, simplifying the fetcher interface |
src/utils/LlmDataMerger.ts |
Removed generic type parameters from IProps interface and parameters function, updated error message to reference correct namespace |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
* 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 <[email protected]> * Update src/structures/ILlmSchema.ts Co-authored-by: Copilot <[email protected]> * Update src/structures/ILlmSchema.ts Co-authored-by: Copilot <[email protected]> * prettier --------- Co-authored-by: Copilot <[email protected]> * 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 <[email protected]> * Update src/HttpLlm.ts Co-authored-by: Copilot <[email protected]> * fix configuration comments * fix more thing --------- Co-authored-by: Copilot <[email protected]> * 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 <[email protected]> * fixed most of test functions * fixed most of test functions * completed everything --------- Co-authored-by: Copilot <[email protected]> * Publish v6 * Re-write README for universal LLM schemas (#221) --------- Co-authored-by: Copilot <[email protected]>
This pull request refactors the type system and configuration handling for the HTTP LLM application codebase. The changes remove generic type parameters related to LLM models, unify configuration interfaces, and simplify function signatures and internal logic. The result is a more streamlined and maintainable codebase, with less reliance on generics and improved clarity around configuration options.
Refactoring and Type Simplification:
<Model extends ILlmSchema.Model>) from interfaces and functions throughout the codebase, includingHttpLlm,HttpLlmComposer, and related fetchers, resulting in simpler and more consistent function signatures. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] [14]Configuration and Options Unification:
IOptions<Model>with a unifiedIConfiginterface, and updated all references and documentation comments to useIConfig. This includes changing parameter names and default values for configuration options. [1] [2] [3] [4] [5]Internal Logic and Documentation Updates:
configstructure, and removed unnecessary references to model-specific configuration. [1] [2] [3] [4]These changes modernize the codebase, reduce complexity, and make the configuration system more robust and easier to use.