Find answers from the community

Updated 2 months ago

Prompts

might be nice to make the docs a bit clearer about this
Attachment
image.png
L
p
3 comments
Yea you found it. Good point though, it could be clearer.

Overall I'd like to make this more obvious without using docs though.

There are callbacks and debug logs that will expose this slightly, but I think the overall UX could be better. Something I want to improve at some point πŸ™
@Logan M that would be awesome! So is there a way to enable debug logs that expose this?
Pretty sure this will enable debug logs

Plain Text
import logging
import sys

logging.basicConfig(stream=sys.stdout, level=logging.DEBUG)
logging.getLogger().addHandler(logging.StreamHandler(stream=sys.stdout))


Another option is using a callback, like the token counting handler (the bottom section shows how to inspect each llm call programmatically)
https://gpt-index.readthedocs.io/en/stable/examples/callbacks/TokenCountingHandler.html
Add a reply
Sign up and join the conversation on Discord