Git Product home page Git Product logo

sap-samples / btp-genai-starter-kit Goto Github PK

View Code? Open in Web Editor NEW
50.0 11.0 15.0 2.58 MB

This repo aims to help developers to get into the genAI topic quicker by automating AI Core and HANA Vector Engine provisioning and configuration with Terraform Provider for SAP BTP.

License: Apache License 2.0

Shell 2.08% Dockerfile 1.00% HCL 19.67% Python 77.25%
ai-core genai hana-cloud langchain rag terraform vector-engine

btp-genai-starter-kit's Introduction

SAP BTP genAI starter kit

REUSE status

Description

This repo wants to give users of the SAP Business Technology Platform (BTP) a quick way to learn how to use generative AI with BTP services.

Architectural overview

Requirements

  • You have access to an SAP BTP global account or an existing SAP BTP sub account.

  • Visual Studio Code is installed on your machine with the Dev Container extension. You understand purpose and basic concepts of Dev Containers in VS Code.

  • As prerequisite for using dev containers, Docker is installed on your machine and you understand its basics concepts.

  • Git is available on your machine (test with git --version) and you know how to clone a project from github.

  • The SAP BTP global account needs to be sufficiently entitled to use the following services and applications:

    Name Service/ Application Plan
    AI Core aicore (service) extended
    AI Launchpad (optional) ai-launchpad (app subscription) standard
    HANA Cloud hana-cloud (service) hana
    HANA Cloud Tools hana-cloud-tools (app subscription) tools

Download and Installation

Step 1: Setup SAP BTP infrastructure

  • Clone this GitHub repository to your local machine and open it in VS Code.
  • Open the Dev Container on your machine from within VS Code (Reopen in Dev Container).
  • Wait for the dev container to be built and the project to be loaded within it.

    Be aware that opening the dev container can take a while!

  • In the folder config/secrets rename the file btp_ai_setup.tfvars to my_btp_ai_setup.tfvars.
    • adapt the value for globalaccount for the subaccount to be created within. You find in the global account landing page ("Subdomain: .....").
    • if you would like to use custom IDP, provide the value for idp e.g. <your-ias-tenant>.accounts.ondemand.com.
    • add your email address to the variable admins. This should be looking similar to this: admins = ["[email protected]"].
    • save the file.
  • In the folder config/secrets rename the file btp_credentials.tfvars to my_btp_credentials.tfvars.
    • adapt the value for the variable BTP_USERNAME to your email address.
    • save the file.
  • Within VS Code open a terminal session.
  • In the terminal simply type ./run.sh and enter your BTP_PASSWORD as well as the password for the HANA DB (you will be prompted accordingly).

    Make sure that the password for the HANA DB matches the minimum requirements (length >= 8, 1+ upper case chars, 2+ lower case chars, 1+ digit)!

In case you want to authenticate via Single-Sign-On (SSO) you should set the enironment variable BTP_ENABLE_SSO to true. You do this by running the following command within your dev container: export BTP_ENABLE_SSO=true

The startet script will now setup the following things for you in your SAP BTP global account:

  • It creates a subaccount with the name configured in the my_btp_ai_setup.tfvars file (folder config/secrets).
  • It creates service instances/subscriptions for the following services
    • SAP AI Core (service)
    • SAP HANA Cloud (service) with integrated vector engine
    • SAP HANA Cloud tools (app subscription)
  • It creates a file called .env that will be copied into the config/secrets folder.

Step 2: Deploy AI Models for your genAI experiments in AI Core

The second step will automatically be taken care of by the running ./run.sh command from step 1.
After the successful setup of the BTP subaccount, it calls the python script poetry run python main.py in the folder scripts.

That python script does the following:

  • It loads the content of the newly created .env file from step 1 into the environment variables of the session.
  • It calls the AI Core APIs to give you access to the models you have defined in the file config/secrets/my_btp_ai_setup.tfvars (through the variable target_ai_core_model).

Step 3: Run GenAI examples

After the steps above, you are all set for your first genAI experiments on SAP BTP.

You can proceed by switching to the folder scripts/step03_explore_examples.

Here you will find some examples with respective instructions and sample code.

Known Issues

❗There is an existing issue that makes AI Core API token invalid for about 1-2 hours after it was created. We implemented a retry mechanism, nevertheless, until the issue is resolved, running the ./run.sh might result in the following error. As a temporary workaround, just re-run the ./run.sh in 1-2 hours. issue

How to obtain support

Create an issue in this repository if you find a bug or have questions about the content.

For additional support, ask a question in SAP Community.

Contributing

If you wish to contribute code, offer fixes or improvements, please send a pull request. Due to legal reasons, contributors will be asked to accept a DCO when they create the first pull request to this project. This happens in an automated fashion during the submission process. SAP uses the standard DCO text of the Linux Foundation.

License

Copyright (c) 2024 SAP SE or an SAP affiliate company. All rights reserved. This project is licensed under the Apache Software License, version 2.0 except as noted otherwise in the LICENSE file.

btp-genai-starter-kit's People

Contributors

dependabot[bot] avatar evgeniiskrebtcov avatar github-actions[bot] avatar michael-sap avatar ospo-bot[bot] avatar pecodev avatar romaniam avatar rui1610 avatar sap-ospo-bot avatar serioussem 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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

btp-genai-starter-kit's Issues

04_rag_on_mixed_data -> multiple responses to some questions

I see that 04_rag_on_mixed_data gets into some kind of loop (?) after getting the question it cannot answer.

Starting with the example of a mistakenly submitted empty question (pressed Enter):

04_rag_on_mixed_data $ poetry run python main.py 
Welcome to the interactive Q&A session!

0: Clean up database
1: Ingest data
2: Retrieve data
3: Exit

Which task would you like to run? 2
/home/user/projects/btp-genai-starter-kit/scripts/step03_explore_examples/04_rag_on_mixed_data/.venv/lib/python3.11/site-packages/sqlalchemy_hana/dialect.py:902: SAWarning: Did not recognize type 'REAL_VECTOR' of column 'vec_vector'
  util.warn(
Ask a question or type 'exit' to leave: 
[2024-08-06 16:06:03] INFO   : Asking a question: 


> Entering new SQL Agent Executor chain...
I need to understand the question before deciding on the next steps. 

Please provide the question you need answered.Invalid Format: Missing 'Action:' after 'Thought:I need to understand the question before deciding on the next steps. 

Please provide the question you need answered.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It appears there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:It seems there was a misunderstanding in the process. Please provide the specific question you need answered, and I will proceed accordingly.Invalid Format: Missing 'Action:' after 'Thought:

> Finished chain.
/home/user/projects/btp-genai-starter-kit/scripts/step03_explore_examples/04_rag_on_mixed_data/.venv/lib/python3.11/site-packages/sqlalchemy_hana/dialect.py:902: SAWarning: Did not recognize type 'REAL_VECTOR' of column 'vec_vector'
  util.warn(
Ask a question or type 'exit' to leave: 
image

02_advanced_rag - Self Query <- clarifications

Hello. I ran 02_advanced_rag option 3.

  1. It does not display what user query was submitted at first.
  2. Execution exits after displaying:

Now try to ask 'What is the summary of the episode 67?' and notice how self-querying can help to avoid hallucination.

Here is the output:

(.venv) user: 02_advanced_rag $ poetry run python main.py
Welcome to the interactive Q&A session

0: Prerequisite - Clean up database
1: Prerequisite - Ingest sample data
2: Advanced RAG - Compare Splitter Methods
3: Advanced RAG - Self Query
4: Advanced RAG - Rewrite Retrieve Read
5: Advanced RAG - RAG Fusion
6: Exit

Which task would you like to run?3
Without database filtering based on user query


> Entering new RetrievalQA chain...

> Finished chain.
Source Documents:
Title: Microsoft Word - Word - Transcript - Episode 65.docx  Page Number: 0
Title: Microsoft Word - Word - Transcript - Episode 64.docx  Page Number: 0
Title: Microsoft Word - Word - Transcript - Episode 65.docx  Page Number: 7
Title: Microsoft Word - Word - Transcript - Episode 64.docx  Page Number: 8
Title: Microsoft Word - Word - Transcript - Episode 65.docx  Page Number: 6
Result: The summary of episode 65 is that supply chains are moving towards being run on information and data, rather than intuition. The episode discusses the importance of grounding supply chains in data, insights, and factuality, and using technology to power supply chains. The guest, Paula Natoli from Google Cloud, talks about how technology can be utilized to solve business problems and generate opportunities in the supply chain and logistics industry. The conversation also touches on the challenges that supply chain executives are facing today, emphasizing the increasing complexity of supply chains.
With database filtering based on user query
Podcast Title: episode 65


> Entering new RetrievalQA chain...

> Finished chain.
Source Documents:
Title: Microsoft Word - Word - Transcript - Episode 65.docx  Page Number: 0
Title: Microsoft Word - Word - Transcript - Episode 65.docx  Page Number: 7
Title: Microsoft Word - Word - Transcript - Episode 65.docx  Page Number: 6
Title: Microsoft Word - Word - Transcript - Episode 65.docx  Page Number: 6
Title: Microsoft Word - Word - Transcript - Episode 65.docx  Page Number: 5
Result: The summary of episode 65 is that supply chains are moving towards being data-driven, grounded in insights and factuality, and powered by technology. The conversation with Google Cloud's Paula Natoli focused on the challenges supply chain executives are facing today, the role of technology in solving supply chain problems, and the future of supply chain being driven by information rather than intuition. The episode also discussed the potential of Generative AI and the role of Google Cloud in helping organizations integrate and innovate in their supply chain operations.
[2024-08-06 15:23:36] SUCCESS: Self querying completed successfully!
                Now try to ask 'What is the summary of the episode 67?' and notice how self-querying can help to avoid hallucination.
                
(.venv) user: 02_advanced_rag $ 
image

Global Account not found by Terraform script

Observation

The run.sh script throws an error stating that the Global Account is not found.

Reproduction

  1. Take all the steps listed in Step 1: Setup SAP BTP infrastructure.
  2. Observe the following as part of the output (I abbreviated account IDs):
Setting up SAP BTP infrastructure
…
Terraform has been successfully initialized!
…
Applying terraform script
--------------------------------------------------------------------------------
/workspaces/btp-genai-starter-kit/scripts/step01_setup_infra
var.BTP_PASSWORD
  Your BTP password.

  Enter a value: <secret>
…
Terraform planned the following actions, but then encountered a problem:

  # random_id.subaccount_domain_suffix will be created
  + resource "random_id" "subaccount_domain_suffix" {
      + b64_std     = (known after apply)
      + b64_url     = (known after apply)
      + byte_length = 12
      + dec         = (known after apply)
      + hex         = (known after apply)
      + id          = (known after apply)
    }

Plan: 1 to add, 0 to change, 0 to destroy.

Changes to Outputs:
  + globalaccount_id        = "cd…55"
  + subaccount_name         = "b9…8c"
  + subaccount_region       = "eu10"
  + timestamp_test_finished = (known after apply)
╷
│ Error: unableToCreateClient
│ 
│   with provider["registry.terraform.io/sap/btp"],
│   on provider.tf line 11, in provider "btp":
│   11: provider "btp" {
│ 
│ Global account 'cd…55' not found. Try again and make sure to provide the global account's subdomain. [Status:
│ 404; Correlation ID: 74b6d037-dd4a-d9a9-7a4e-d43f1cdd56e4]
╵
The 'terraform apply' command was not successful. Exiting.

Remarks

  • The Global Account subdomain used is listed in the Global-Account landing page in Cloud Cockpit.
  • On my machine (i.e. outside the Docker container), btp target --global-account cd…55 does succeed, confirming that the Global Account subdomain is valid.
  • The same problem also occurs if the name (rather than ID, which was just a try) of the subaccount is used.
  • Networking in the container does function.

No error handling in qa_chain.invoke in 01_naive_rag

See the following trace returned when the model does not respond before the timeout when called via result = qa_chain.invoke({"question": question}), in case you want to add any error handling.

$ poetry run python main.py 
Welcome to the interactive Q&A session

0: Clean up database
1: Ingest data
2: Retrieve data
3: Exit

Which task would you like to run?2
Ask a question or type 'exit' to leave: Who can contribute?
[2024-08-01 15:01:23] INFO   : Asking a question: Who can contribute?
[2024-08-01 15:01:53] INFO   : Retrying request to %s in %f seconds
[2024-08-01 15:01:54] INFO   : Retrying request to %s in %f seconds
[2024-08-01 15:01:56] ERROR  : Traceback (most recent call last):

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/scripts/step03_explore_examples/01_naive_rag/main.py", line 81, in <module>
    main()

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/scripts/step03_explore_examples/01_naive_rag/main.py", line 71, in main
    chat()

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/scripts/step03_explore_examples/01_naive_rag/main.py", line 29, in chat
    result = qa_chain.invoke({"question": question})
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/base.py", line 166, in invoke
    raise e

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/base.py", line 156, in invoke
    self._call(inputs, run_manager=run_manager)

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/conversational_retrieval/base.py", line 168, in _call
    answer = self.combine_docs_chain.run(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain_core/_api/deprecation.py", line 168, in warning_emitting_wrapper
    return wrapped(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/base.py", line 605, in run
    return self(kwargs, callbacks=callbacks, tags=tags, metadata=metadata)[
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain_core/_api/deprecation.py", line 168, in warning_emitting_wrapper
    return wrapped(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/base.py", line 383, in __call__
    return self.invoke(
           ^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/base.py", line 166, in invoke
    raise e

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/base.py", line 156, in invoke
    self._call(inputs, run_manager=run_manager)

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/combine_documents/base.py", line 138, in _call
    output, extra_return_dict = self.combine_docs(
                                ^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/combine_documents/stuff.py", line 245, in combine_docs
    return self.llm_chain.predict(callbacks=callbacks, **inputs), {}
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/llm.py", line 318, in predict
    return self(kwargs, callbacks=callbacks)[self.output_key]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain_core/_api/deprecation.py", line 168, in warning_emitting_wrapper
    return wrapped(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/base.py", line 383, in __call__
    return self.invoke(
           ^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/base.py", line 166, in invoke
    raise e

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/base.py", line 156, in invoke
    self._call(inputs, run_manager=run_manager)

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/llm.py", line 128, in _call
    response = self.generate([inputs], run_manager=run_manager)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain/chains/llm.py", line 140, in generate
    return self.llm.generate_prompt(
           ^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain_core/language_models/chat_models.py", line 698, in generate_prompt
    return self.generate(prompt_messages, stop=stop, callbacks=callbacks, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain_core/language_models/chat_models.py", line 555, in generate
    raise e

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain_core/language_models/chat_models.py", line 545, in generate
    self._generate_with_cache(

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain_core/language_models/chat_models.py", line 770, in _generate_with_cache
    result = self._generate(
             ^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/langchain_openai/chat_models/base.py", line 549, in _generate
    response = self.client.create(**payload)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/gen_ai_hub/proxy/native/openai/clients.py", line 288, in create
    return super().create(messages=messages, model=model_name, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/openai/_utils/_utils.py", line 277, in wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/openai/resources/chat/completions.py", line 643, in create
    return self._post(
           ^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/openai/_base_client.py", line 1266, in post
    return cast(ResponseT, self.request(cast_to, opts, stream=stream, stream_cls=stream_cls))
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/gen_ai_hub/proxy/native/openai/clients.py", line 505, in request
    return super().request(cast_to, options, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/openai/_base_client.py", line 942, in request
    return self._request(
           ^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/openai/_base_client.py", line 1031, in _request
    return self._retry_request(
           ^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/openai/_base_client.py", line 1079, in _retry_request
    return self._request(
           ^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/openai/_base_client.py", line 1031, in _request
    return self._retry_request(
           ^^^^^^^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/openai/_base_client.py", line 1079, in _retry_request
    return self._request(
           ^^^^^^^^^^^^^^

NoneType: None
[2024-08-01 15:01:56] ERROR  :   File "/home/user/projects/btp-genai-starter-kit/.venv/lib/python3.11/site-packages/openai/_base_client.py", line 1046, in _request
    raise self._make_status_error_from_response(err.response) from None

NoneType: None
[2024-08-01 15:01:56] ERROR  : openai.RateLimitError: Error code: 429 - {'error': 'TooManyRequest', 'message': 'Your request has been rate limited. Please try again later.'}

NoneType: None
[2024-08-01 15:01:56] ERROR  : Error code: 429 - {'error': 'TooManyRequest', 'message': 'Your request has been rate limited. Please try again later.'}
NoneType: None

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.