MCPcopy Index your code
hub / github.com/codingis4noobs2/QuickDigest / upload_files

Function upload_files

app.py:135–142  ·  view source on GitHub ↗
(types=["pdf", "txt", "mp3", "mp4", 'mpeg', 'doc', 'docx'], **kwargs)

Source from the content-addressed store, hash-verified

133
134 # Upload files and cache them
135 def upload_files(types=["pdf", "txt", "mp3", "mp4", 'mpeg', 'doc', 'docx'], **kwargs):
136 files = st.file_uploader(
137 label=f"Upload files", type=types, **kwargs
138 )
139 if not files:
140 st.info(f"Please add documents, Note: Scanned documents are not supported yet!")
141 st.stop()
142 return cache_files(files, types=types)
143
144 # Cache uploaded files
145 def cache_files(files, types=["pdf", "txt", "mp3", "mp4", 'mpeg', 'doc', 'docx']) -> list[str]:

Callers 1

chat_with_filesFunction · 0.85

Calls 1

cache_filesFunction · 0.85

Tested by

no test coverage detected