Giter Site home page Giter Site logo

gustavz / datachad Goto Github PK

View Code? Open in Web Editor NEW
302.0 3.0 79.0 1.34 MB

Ask questions about any data source by leveraging langchains

Home Page: https://datachad.streamlit.app/

License: Apache License 2.0

Python 99.00% Dockerfile 1.00%
activeloop embeddings langchain openai python streamlit chatbot chatgpt chatwithpdf knowledge-base

datachad's People

Contributors

derluke avatar gustavz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

datachad's Issues

Import error

Hi Gustav,

I built your project with Docker Desktop and ran it. However, it gives the following error:

ImportError: cannot import name 'get_openai_token_cost_for_model' from 'langchain.callbacks.openai_info' (/usr/local/lib/python3.10/site-packages/langchain/callbacks/openai_info.py)

Traceback:

File "/usr/local/lib/python3.10/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 534, in _run_script
    exec(code, module.__dict__)
File "/app/app.py", line 1, in <module>
    from datachad.streamlit.helper import init_session_state
File "/app/datachad/streamlit/helper.py", line 8, in <module>
    from langchain.callbacks.openai_info import get_openai_token_cost_for_model

I tried the solution here, but it still gives the same error.

I was wondering if you have any thought on this error. Many thanks in advance!

knowledge base

Hello Gustav.

I would like to understand if it's possible to put several source of different nature inside the same knowledge base.

For what i read in the doc, this is doable only for multiple pdf loading but it would be great to combine different source types as well.

Thanks

ERROR: "Dataset does not exist at the specified path..."

I am getting the following error anytime I start the app locally, or once it is running locally and I try to upload my own documents.

Failed to build chain for data source 'https://github.com/gustavz/DataChad.git' with error: A dataset does not exist at the specified path, or you do not have sufficient permissions to load or create one. Please check the dataset path and make sure that you have sufficient permissions to the path.

I am guessing this has to do with my activeloop account, but I am unable to figure out where to enable permissions for datasets to be created in activeloop. Am I missing something obvious?

Issue with Local Deployment (Ignore - I am the issue. It is me.)

Running with .env set locally, with python 3.10.9. Requirements installed. Not sure what the issue is. I'm probably just doing something stupid.

streamlit run app.py [ARGUMENTS]
2023-05-26 15:38:22.241 Session state does not function when running a script without streamlit run
Error in sys.excepthook:
Traceback (most recent call last):
File "/Users/home/.pyenv/versions/DataChad/lib/python3.10/site-packages/humbug/report.py", line 540, in _hook
self.error_report(error=exception_instance, tags=tags, publish=publish)
File "/Users/home/.pyenv/versions/DataChad/lib/python3.10/site-packages/humbug/report.py", line 274, in error_report
traceback.format_exception(
TypeError: format_exception() got an unexpected keyword argument 'etype'

Original exception was:
Traceback (most recent call last):
File "/Users/home/.pyenv/versions/DataChad/lib/python3.10/site-packages/streamlit/runtime/state/session_state.py", line 376, in getitem
return self._getitem(widget_id, key)
File "/Users/home/.pyenv/versions/DataChad/lib/python3.10/site-packages/streamlit/runtime/state/session_state.py", line 421, in _getitem
raise KeyError
KeyError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Users/home/pytorch-test/DataChad/app.py", line 205, in
authentication_form()
File "/Users/home/pytorch-test/DataChad/app.py", line 92, in authentication_form
f"{st.session_state['mode']} API Key",
File "/Users/home/.pyenv/versions/DataChad/lib/python3.10/site-packages/streamlit/runtime/state/session_state_proxy.py", line 90, in getitem
return get_session_state()[key]
File "/Users/home/.pyenv/versions/DataChad/lib/python3.10/site-packages/streamlit/runtime/state/safe_session_state.py", line 113, in getitem
return self._state[key]
File "/Users/home/.pyenv/versions/DataChad/lib/python3.10/site-packages/streamlit/runtime/state/session_state.py", line 378, in getitem
raise KeyError(_missing_key_error_message(key))
KeyError: 'st.session_state has no key "mode". Did you forget to initialize it? More info: https://docs.streamlit.io/library/advanced-features/session-state#initialization'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.