[GH-ISSUE #100] issue with chromadb not working #66

Closed
opened 2026-10-15 18:03:59 +00:00 by bsakaguchi · 5 comments
Owner

Originally created by @0xYc0d0ne on GitHub (Aug 1, 2023).
Original GitHub issue: https://github.com/SillyTavern/SillyTavern-Extras/issues/100

here is how i got the error

PS C:\Users\User\SillyTavern-extras> python server.py --enable-modules=chromadb --share --secure

Using torch device: cpu
Initializing ChromaDB
Traceback (most recent call last):
File "C:\Users\alpha\SillyTavern-extras\server.py", line 268, in
chromadb_client = chromadb.PersistentClient(path=args.chroma_folder, settings=Settings(anonymized_telemetry=False))
AttributeError: module 'chromadb' has no attribute 'PersistentClient'

also error when trying to purge chromadb in silly tavern terminal window returns this error and silly tavern doesn't show any sign that the chromadb chat was purged from chromadb

127.0.0.1 - - [01/Aug/2023 12:52:35] "POST /api/chromadb/purge HTTP/1.1" 500 -
127.0.0.1 - - [01/Aug/2023 12:52:58] "OPTIONS /api/chromadb/purge HTTP/1.1" 200 -
[2023-08-01 12:52:59,192] ERROR in app: Exception on /api/chromadb/purge [POST]
Traceback (most recent call last):
File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 2190, in wsgi_app
response = self.full_dispatch_request()
File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1486, in full_dispatch_request
rv = self.handle_user_exception(e)
File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask_cors\extension.py", line 165, in wrapped_function
return cors_after_request(app.make_response(f(*args, **kwargs)))
File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1484, in full_dispatch_request
rv = self.dispatch_request()
File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1469, in dispatch_request
return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
File "C:\Users\alpha\SillyTavern-extras\server.py", line 303, in decorated_view
return fn(*args, **kwargs)
File "C:\Users\alpha\SillyTavern-extras\server.py", line 775, in chromadb_purge
chromadb_client.persist()
AttributeError: 'SegmentAPI' object has no attribute 'persist'
127.0.0.1 - - [01/Aug/2023 12:52:59] "POST /api/chromadb/purge HTTP/1.1" 500 -

so i suspect that chromadb may just be completely broken all together

please fix this issue in another update....

anyone know any solutions if you have ran into this problem yourselves???

Originally created by @0xYc0d0ne on GitHub (Aug 1, 2023). Original GitHub issue: https://github.com/SillyTavern/SillyTavern-Extras/issues/100 here is how i got the error PS C:\Users\User\SillyTavern-extras> python server.py --enable-modules=chromadb --share --secure Using torch device: cpu Initializing ChromaDB Traceback (most recent call last): File "C:\Users\alpha\SillyTavern-extras\server.py", line 268, in <module> chromadb_client = chromadb.PersistentClient(path=args.chroma_folder, settings=Settings(anonymized_telemetry=False)) AttributeError: module 'chromadb' has no attribute 'PersistentClient' also error when trying to purge chromadb in silly tavern terminal window returns this error and silly tavern doesn't show any sign that the chromadb chat was purged from chromadb 127.0.0.1 - - [01/Aug/2023 12:52:35] "POST /api/chromadb/purge HTTP/1.1" 500 - 127.0.0.1 - - [01/Aug/2023 12:52:58] "OPTIONS /api/chromadb/purge HTTP/1.1" 200 - [2023-08-01 12:52:59,192] ERROR in app: Exception on /api/chromadb/purge [POST] Traceback (most recent call last): File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 2190, in wsgi_app response = self.full_dispatch_request() File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1486, in full_dispatch_request rv = self.handle_user_exception(e) File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask_cors\extension.py", line 165, in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1484, in full_dispatch_request rv = self.dispatch_request() File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1469, in dispatch_request return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args) File "C:\Users\alpha\SillyTavern-extras\server.py", line 303, in decorated_view return fn(*args, **kwargs) File "C:\Users\alpha\SillyTavern-extras\server.py", line 775, in chromadb_purge chromadb_client.persist() AttributeError: 'SegmentAPI' object has no attribute 'persist' 127.0.0.1 - - [01/Aug/2023 12:52:59] "POST /api/chromadb/purge HTTP/1.1" 500 - so i suspect that chromadb may just be completely broken all together please fix this issue in another update.... anyone know any solutions if you have ran into this problem yourselves???
bsakaguchi 2026-10-15 18:03:59 +00:00
  • closed this issue
  • added the
    duplicate
    label
Author
Owner

@UrBoiTom commented on GitHub (Aug 1, 2023):

Run pip install --upgrade chromadb

<!-- gh-comment-id:1660999390 --> @UrBoiTom commented on GitHub (Aug 1, 2023): Run `pip install --upgrade chromadb`
Author
Owner

@wereretot commented on GitHub (Aug 2, 2023):

Got this error fixed with @Sorro123 solution.

<!-- gh-comment-id:1662086855 --> @wereretot commented on GitHub (Aug 2, 2023): Got this error fixed with @Sorro123 solution.
Author
Owner

@0xYc0d0ne commented on GitHub (Aug 2, 2023):

@Sorro123 i already ran " pip install --upgrade chromadb" which got chromadb to run but when actually trying to use chromadb i get errors like this

"127.0.0.1 - - [01/Aug/2023 12:52:35] "POST /api/chromadb/purge HTTP/1.1" 500 -
127.0.0.1 - - [01/Aug/2023 12:52:58] "OPTIONS /api/chromadb/purge HTTP/1.1" 200 -
[2023-08-01 12:52:59,192] ERROR in app: Exception on /api/chromadb/purge [POST]
Traceback (most recent call last):
File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 2190, in wsgi_app
response = self.full_dispatch_request()
File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1486, in full_dispatch_request
rv = self.handle_user_exception(e)
File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask_cors\extension.py", line 165, in wrapped_function
return cors_after_request(app.make_response(f(*args, **kwargs)))
File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1484, in full_dispatch_request
rv = self.dispatch_request()
File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1469, in dispatch_request
return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
File "C:\Users\alpha\SillyTavern-extras\server.py", line 303, in decorated_view
return fn(*args, **kwargs)
File "C:\Users\alpha\SillyTavern-extras\server.py", line 775, in chromadb_purge
chromadb_client.persist()
AttributeError: 'SegmentAPI' object has no attribute 'persist'
127.0.0.1 - - [01/Aug/2023 12:52:59] "POST /api/chromadb/purge HTTP/1.1" 500 -"

<!-- gh-comment-id:1662155378 --> @0xYc0d0ne commented on GitHub (Aug 2, 2023): @Sorro123 i already ran " pip install --upgrade chromadb" which got chromadb to run but when actually trying to use chromadb i get errors like this "127.0.0.1 - - [01/Aug/2023 12:52:35] "POST /api/chromadb/purge HTTP/1.1" 500 - 127.0.0.1 - - [01/Aug/2023 12:52:58] "OPTIONS /api/chromadb/purge HTTP/1.1" 200 - [2023-08-01 12:52:59,192] ERROR in app: Exception on /api/chromadb/purge [POST] Traceback (most recent call last): File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 2190, in wsgi_app response = self.full_dispatch_request() File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1486, in full_dispatch_request rv = self.handle_user_exception(e) File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask_cors\extension.py", line 165, in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1484, in full_dispatch_request rv = self.dispatch_request() File "C:\Users\alpha\AppData\Roaming\Python\Python310\site-packages\flask\app.py", line 1469, in dispatch_request return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args) File "C:\Users\alpha\SillyTavern-extras\server.py", line 303, in decorated_view return fn(*args, **kwargs) File "C:\Users\alpha\SillyTavern-extras\server.py", line 775, in chromadb_purge chromadb_client.persist() AttributeError: 'SegmentAPI' object has no attribute 'persist' 127.0.0.1 - - [01/Aug/2023 12:52:59] "POST /api/chromadb/purge HTTP/1.1" 500 -"
Author
Owner

@Cohee1207 commented on GitHub (Aug 8, 2023):

I did an update specifically for your case with purge @0xYc0d0ne github.com/SillyTavern/SillyTavern-extras@5ed3013e45

<!-- gh-comment-id:1669761126 --> @Cohee1207 commented on GitHub (Aug 8, 2023): I did an update specifically for your case with purge @0xYc0d0ne https://github.com/SillyTavern/SillyTavern-extras/commit/5ed3013e458317db7977d47d3d985b084547e7fc
Author
Owner

@Cohee1207 commented on GitHub (Sep 3, 2023):

Cleaning up ChromaDB issues into one: https://github.com/SillyTavern/SillyTavern-Extras/issues/110

<!-- gh-comment-id:1704318773 --> @Cohee1207 commented on GitHub (Sep 3, 2023): Cleaning up ChromaDB issues into one: https://github.com/SillyTavern/SillyTavern-Extras/issues/110
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
SillyTavern/SillyTavern-Extras#66
No description provided.