Refactor to Remove Config Manager and Optimize Settings#83
Merged
Umpire2018 merged 8 commits intoNov 21, 2024
Conversation
- Introduce lazy loading to optimize performance by delaying resource initialization until needed. - Remove `config_manager` and config file saving functionality - Update default model names and remove context window handling - Introduce `llama_index.llms.openai` for LLM communication to enhance integration and compatibility with updated LLM protocols. - Add `ChatPromptTemplate` to manage prompts more efficiently and improve prompt consistency. - Streamline implementation within `ChatEngine` for improved readability and maintainability.
- Fix issue where logger failed to capture full error stack trace in certain cases - Remove `tiktoken` dependency, directly retrieve token usage from API response - Add import sorting for improved readability and consistency - Remove deprecated test cases
- Removed deprecated `config.toml.template` file - Removed `sync_func` to prevent TypeError and ensure file saving
…ality - Integrated `llama_index.vector_stores.chroma` and `llama_index.embeddings.openai` for improved vector storage and embeddings. - Added semantic chunking for better document segmentation. - Introduced `ChatPromptTemplate` and `PromptTemplate` for customizable chat prompts.
- Changed `print_hierarchy` from a subcommand to an option in the `run` command. - Defined `chat-with-repo` as an optional dependency in `pyproject.toml`.
LOGIC-10
approved these changes
Nov 20, 2024
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.
Summary
This PR focuses on removing the deprecated
config_managerand associated configuration file saving functionality while introducing key improvements across the codebase.Key Changes
1. Remove
config_managerconfig_managermodule and configuration file handling.2. Enhance Settings Management
initialize_with_paramsmethod for dynamic configuration.3. Integrate
LlamaIndexchat_with_repoto usellama_indexfor enhanced functionality:llama_index.vector_stores.chromaandllama_index.embeddings.openai.ChatPromptTemplatefor consistent prompt management.4. Refactor CLI
print_hierarchyfrom a subcommand to an option (--print-hierarchy) in theruncommand for streamlined usage.5. Logging Improvements
tiktokendependency; token usage is now retrieved directly from API responses.6. Additional Updates
READMEto include GitHub Actions support.chat-with-repoas an optional dependency inpyproject.toml.config.toml.templateandsync_func).Checklist
config_managerand its dependencies.Details