Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@marklysze
Copy link
Collaborator

@marklysze marklysze commented Feb 25, 2025

Why are these changes needed?

In the original plan for DocAgent, an in-memory option was to be included, allowing ingestion into the system prompt and then querying directly from that.

This PR creates an in memory query engine that stores ingested text into memory and runs queries from an internal agent's system prompt.

Related issue number

N/A

Checks

@marklysze marklysze self-assigned this Feb 25, 2025
@marklysze marklysze added the agents:docagent Document Agent label Feb 25, 2025
@marklysze
Copy link
Collaborator Author

marklysze commented Feb 26, 2025

@AgentGenie and @Eric-Shang, please review when you get a chance, thanks! Changes to protocol and naming of classes:
DoclingMdQueryEngine to VectorChromaQueryEngine
VectorDbQueryEngine to RAGQueryEngine

Protocol simplified and aligned.

Names were just what I could think of, you may have better/more relevant names.

Copy link
Collaborator

@AgentGenie AgentGenie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it is good to keep all 4 methods from the protocol in autogen/agentchat/contrib/rag/query_engine.py because common vector db query engine will need those 4 methods.

inmemory query engine is a special case.
You can add init_db and connect_db methods in inmemory query engine and explicitly raise NotImplementedError to remind the user.

@marklysze
Copy link
Collaborator Author

I think it is good to keep all 4 methods from the protocol in autogen/agentchat/contrib/rag/query_engine.py because common vector db query engine will need those 4 methods.

inmemory query engine is a special case. You can add init_db and connect_db methods in inmemory query engine and explicitly raise NotImplementedError to remind the user.

I'll put back into protocol implement the NotImplementError exceptions... are you okay with naming changes?

@AgentGenie
Copy link
Collaborator

I'll put back into protocol implement the NotImplementError exceptions... are you okay with naming changes?
@marklysze Naming changes are good.

@AgentGenie AgentGenie marked this pull request as ready for review February 27, 2025 06:59
@davorrunje davorrunje added this pull request to the merge queue Feb 27, 2025
Merged via the queue into main with commit 1452c40 Feb 27, 2025
17 checks passed
@davorrunje davorrunje deleted the docagentinmemory branch February 27, 2025 08:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents:docagent Document Agent

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants