-
Notifications
You must be signed in to change notification settings - Fork 4k
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
feat: Enhance backend with context management, error handling, and refactored code #4286
base: main
Are you sure you want to change the base?
Commits on Oct 25, 2024
-
Configuration menu - View commit details
-
Copy full SHA for b4064ab - Browse repository at this point
Copy the full SHA b4064abView commit details -
Configuration menu - View commit details
-
Copy full SHA for 2f3bb69 - Browse repository at this point
Copy the full SHA 2f3bb69View commit details -
Configuration menu - View commit details
-
Copy full SHA for 6e913cd - Browse repository at this point
Copy the full SHA 6e913cdView commit details -
Add agent components for action routing, decision-making, execution, …
…and context management - Introduced `AgentActionRouter` to route agent flow based on action type. - Added `DecideActionComponent` for determining actions from context and prompts. - Implemented `ExecuteActionComponent` to execute actions using available tools. - Created `GenerateThoughtComponent` for generating thoughts based on context. - Developed `ProvideFinalAnswerComponent` to generate final answers from context. - Built `AgentContextBuilder` for constructing `AgentContext` instances. - Added `ObserveResultComponent` to process and observe action results. - Implemented `CheckTerminationComponent` to determine if the agent should continue or terminate.
Configuration menu - View commit details
-
Copy full SHA for 8459565 - Browse repository at this point
Copy the full SHA 8459565View commit details -
Add AgentContext class for managing agent state and context serializa…
…tion - Introduced `AgentContext` class in `context.py` to handle agent state, including tools, language model, and context history. - Implemented serialization methods for converting agent context to JSON-compatible format. - Added validation for language model instances to ensure compatibility. - Provided methods for updating and retrieving full context, including context history management.
Configuration menu - View commit details
-
Copy full SHA for a5e3d44 - Browse repository at this point
Copy the full SHA a5e3d44View commit details -
Configuration menu - View commit details
-
Copy full SHA for 927b359 - Browse repository at this point
Copy the full SHA 927b359View commit details -
Configuration menu - View commit details
-
Copy full SHA for 3ee2686 - Browse repository at this point
Copy the full SHA 3ee2686View commit details -
Configuration menu - View commit details
-
Copy full SHA for d43751b - Browse repository at this point
Copy the full SHA d43751bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 86fc405 - Browse repository at this point
Copy the full SHA 86fc405View commit details -
Configuration menu - View commit details
-
Copy full SHA for 25ccac1 - Browse repository at this point
Copy the full SHA 25ccac1View commit details -
Configuration menu - View commit details
-
Copy full SHA for 3e9332d - Browse repository at this point
Copy the full SHA 3e9332dView commit details -
Configuration menu - View commit details
-
Copy full SHA for e312f13 - Browse repository at this point
Copy the full SHA e312f13View commit details -
Configuration menu - View commit details
-
Copy full SHA for 818443c - Browse repository at this point
Copy the full SHA 818443cView commit details -
Configuration menu - View commit details
-
Copy full SHA for 7405501 - Browse repository at this point
Copy the full SHA 7405501View commit details -
Configuration menu - View commit details
-
Copy full SHA for 45bb9f3 - Browse repository at this point
Copy the full SHA 45bb9f3View commit details -
Configuration menu - View commit details
-
Copy full SHA for 8efafc7 - Browse repository at this point
Copy the full SHA 8efafc7View commit details -
Add context management methods to custom component class
- Introduced a `_ctx` attribute to store context data. - Added `ctx` property to access the graph's context, raising an error if the graph is not built. - Implemented `add_to_ctx` method to add key-value pairs to the context with an optional overwrite flag. - Implemented `update_ctx` method to update the context with a dictionary of values, ensuring the graph is built and the input is a dictionary.
Configuration menu - View commit details
-
Copy full SHA for 431bbe6 - Browse repository at this point
Copy the full SHA 431bbe6View commit details -
Configuration menu - View commit details
-
Copy full SHA for 5d8a529 - Browse repository at this point
Copy the full SHA 5d8a529View commit details -
Configuration menu - View commit details
-
Copy full SHA for 3c3355b - Browse repository at this point
Copy the full SHA 3c3355bView commit details -
Convert
get_response
method to asynchronous and update graph proces……sing to use async iteration.
Configuration menu - View commit details
-
Copy full SHA for 0bf83c2 - Browse repository at this point
Copy the full SHA 0bf83c2View commit details -
Configuration menu - View commit details
-
Copy full SHA for b92300b - Browse repository at this point
Copy the full SHA b92300bView commit details -
Refactor Agent Flow JSON: Simplify input types and update agent compo…
…nent structure - Removed "BaseTool" from input types for "ToolCallingAgent" to streamline tool handling. - Updated agent component to a more modular structure with new prompts and input configurations. - Replaced deprecated methods and fields with updated implementations for improved functionality. - Adjusted metadata and configuration settings for better clarity and usability.
Configuration menu - View commit details
-
Copy full SHA for 4861084 - Browse repository at this point
Copy the full SHA 4861084View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7143208 - Browse repository at this point
Copy the full SHA 7143208View commit details -
Add Agent import to init, improve error handling, and clean up imports
- Added `Agent` import to `__init__.py` for better module accessibility. - Improved error handling in `aiml_embeddings.py` by raising a `ValueError` when the expected embedding count is not met. - Cleaned up redundant imports in `test_cycles.py` to enhance code readability.
Configuration menu - View commit details
-
Copy full SHA for c556074 - Browse repository at this point
Copy the full SHA c556074View commit details -
Configuration menu - View commit details
-
Copy full SHA for 438ac6b - Browse repository at this point
Copy the full SHA 438ac6bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 5024e6b - Browse repository at this point
Copy the full SHA 5024e6bView commit details -
Configuration menu - View commit details
-
Copy full SHA for d5f03a2 - Browse repository at this point
Copy the full SHA d5f03a2View commit details -
Configuration menu - View commit details
-
Copy full SHA for c48aea4 - Browse repository at this point
Copy the full SHA c48aea4View commit details -
Refactor graph tests to include new components and update iteration l…
…ogic - Replaced complex agent flow with a simplified guessing game using OpenAI components and conditional routing. - Introduced `TextInputComponent` and updated `ChatInput` initialization. - Added new test `test_conditional_router_max_iterations` to validate conditional routing with max iterations. - Updated graph cyclicity assertions and snapshot checks for improved test coverage. - Removed deprecated agent components and related logic.
Configuration menu - View commit details
-
Copy full SHA for cda8540 - Browse repository at this point
Copy the full SHA cda8540View commit details -
Refactor conditional router to return message consistently and use it…
…erate_and_stop_once method
Configuration menu - View commit details
-
Copy full SHA for 70fa7f5 - Browse repository at this point
Copy the full SHA 70fa7f5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4ad2e26 - Browse repository at this point
Copy the full SHA 4ad2e26View commit details -
Configuration menu - View commit details
-
Copy full SHA for 8f40330 - Browse repository at this point
Copy the full SHA 8f40330View commit details -
Remove unnecessary
@override
decorator and add# noqa: ARG002
com……ments for unused arguments
Configuration menu - View commit details
-
Copy full SHA for ee72767 - Browse repository at this point
Copy the full SHA ee72767View commit details