-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Edit agent feature 1 #998
Edit agent feature 1 #998
Conversation
Rounak Bhatia seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
superagi/models/agent_config.py
Outdated
# Fetch agent configurations | ||
agent_configs = session.query(AgentConfiguration).filter(AgentConfiguration.agent_id == agent_id).all() | ||
for agent_config in agent_configs: | ||
key = agent_config.key |
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.
remove key var u can directly us eit.
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.
removed key variable
@@ -100,3 +106,46 @@ def eval_agent_config(cls, key, value): | |||
|
|||
if key == "goal" or key == "instruction": | |||
return eval(value) | |||
|
|||
@classmethod | |||
def fetch_details_api(cls, session, agent, results_agent, results_agent_execution, total_calls, total_tokens): |
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.
build_agent_execution_config
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## dev #998 +/- ##
==========================================
+ Coverage 59.41% 59.46% +0.04%
==========================================
Files 197 198 +1
Lines 8723 8844 +121
Branches 908 927 +19
==========================================
+ Hits 5183 5259 +76
- Misses 3316 3343 +27
- Partials 224 242 +18
☔ View full report in Codecov by Sentry. |
6c9afdd
into
TransformerOptimus:dev
Description
Changes in 7 files:
controllers/agent.py -> removed the fetch details api and i have moved it to the controllers/agent_execution_config.py file
and in the create_agent_with_config function i have added new agent_execution_configs
models/agent_config.py -> added a update_agent_configurations_table function which updates the "agent_configurations" table
whenever we run edit agent
controllers/agent_execution_config.py -> added a new api call(get_agent_execution_configuration) , which is used by frontend to fetch the details of the execution/ run
controllers/ agent_execution.py -> added a new api call(create_agent_run), which is used to create a new execution/ run
controllers/ type/ agent_execution_config.py -> created this new file which contains the AgentRunIn class, this class is used to update the "agent_configurations" table and to create a new execution
models/agent.py -> using this code for extracting value:
list(ast.literal_eval(value))
because the array containing the tools_id is received in the form of a string
Related Issues
Solution and Design
Test Plan
Type of change
Checklist