Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

litellm.set_verbose=True #925

Closed
shen653 opened this issue Nov 27, 2023 · 7 comments
Closed

litellm.set_verbose=True #925

shen653 opened this issue Nov 27, 2023 · 7 comments

Comments

@shen653
Copy link

shen653 commented Nov 27, 2023

No description provided.

@ishaan-jaff
Copy link
Contributor

@shen653 what's the issue you're running into ?

@solyarisoftware
Copy link

solyarisoftware commented Nov 28, 2023

@shen653 You should have inserted the description, in a spirit of collaboration.

Anyway this solves:

from litellm import text_completion, litellm

litellm.set_verbose = True 

I'd close the issue after updating documentation here:
https://docs.litellm.ai/docs/debugging/local_debugging#set-verbose

@ishaan-jaff
Copy link
Contributor

docs already have this @solyarisoftware

closing this issue, feel free to re-open

@solyarisoftware
Copy link

Thanks, it's a minor point but to be honest documentation does not, reading: https://docs.litellm.ai/docs/debugging/local_debugging#set-verbose:


from litellm import completion

litellm.set_verbose=True # 👈 this is the 1-line change you need to make

## set ENV variables
os.environ["OPENAI_API_KEY"] = "openai key"
os.environ["COHERE_API_KEY"] = "cohere key"

messages = [{ "content": "Hello, how are you?","role": "user"}]

# openai call
response = completion(model="gpt-3.5-turbo", messages=messages)

# cohere call
response = completion("command-nightly", messages) 

@ishaan-jaff
Copy link
Contributor

i'm confused - you just linked me to the part that has litellm.set_verbose=True

what's the issue ?

@solyarisoftware
Copy link

solyarisoftware commented Nov 28, 2023

It's a minor point:

the correct Python import statement is:

from litellm import text_completion, litellm

Whereas the import statement in the above documentation omits

, litellm

and the run-time exception is triggered. no problem :-)

@ishaan-jaff
Copy link
Contributor

updated

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants