diff --git a/modelscope_agent/rag/knowledge.py b/modelscope_agent/rag/knowledge.py index 1450a6f1f..bc2fbf89b 100644 --- a/modelscope_agent/rag/knowledge.py +++ b/modelscope_agent/rag/knowledge.py @@ -243,11 +243,13 @@ def get_extra_readers( ) return extra_readers - return { + extra_readers.update({ '.pb': PandasCSVReader(), '.html': HTMLTagReader(), '.txt': FlatReader() - }.update(extra_readers) + }) + + return extra_readers def read(self, knowledge_source: Union[str, List[str]],