MetaGPT icon indicating copy to clipboard operation
MetaGPT copied to clipboard

Specify Directory of pdf documents as Knowledge Base

Open alphomeg opened this issue 2 years ago • 4 comments
trafficstars

Hi, how can we specify any folder which includes pdf documents as a knowledge base and create a new Role of Document Controller to extract specific information from within the documents in KB?

Any help would be highly appreciated

Thanks much appreciated

alphomeg avatar Aug 09 '23 10:08 alphomeg

@geekan @wangjie5540

voidking avatar Aug 10 '23 09:08 voidking

I think knowledge-base is a good idea, maybe importing knowledge-base as a tool or a skill for roles to choose is a feasible

wangjie5540 avatar Aug 11 '23 06:08 wangjie5540

Hi @wangjie5540 thank you for your response, i'm specifically referring to this part of the code in search_kb.py inside examples folder.

from metagpt.const import DATA_PATH
from metagpt.document_store import FaissStore

not sure if i fully understand DATA_PATH and metagpt.document_store can you please provide any information for these or how to include new document store Thanks in Advance

alphomeg avatar Aug 11 '23 09:08 alphomeg

DATA_PATH = PROJECT_ROOT / 'data' @alphomeg

geekan avatar Sep 09 '23 03:09 geekan

The MetaGPT has provided a knowledge base tool in metagpt/document_store. The usage method can refer to the unit test code in tests/metagpt/document_store and examples/search_kb.py.

iorisa avatar Mar 11 '24 02:03 iorisa