This commit is contained in:
seehi 2024-03-08 21:50:38 +08:00
parent 451cbd7e46
commit 6a388b53f1
16 changed files with 19 additions and 9 deletions

View file

@ -1,4 +1,5 @@
"""RAG pipeline"""
import asyncio
from pydantic import BaseModel

View file

@ -1,4 +1,5 @@
"""Agent with RAG search"""
"""Agent with RAG search."""
import asyncio
from examples.rag_pipeline import DOC_PATH, QUESTION
@ -8,7 +9,8 @@ from metagpt.roles import Sales
async def search():
"""Agent with RAG search"""
"""Agent with RAG search."""
store = SimpleEngine.from_docs(input_files=[DOC_PATH])
role = Sales(profile="Sales", store=store)
result = await role.run(QUESTION)