Replies: 2 comments 1 reply
-
Hey @arrowkato! I'm here to assist you with any bugs, questions, or contributions you have. Let's tackle this together! 😊 LangSmith uses the Python import logging
# Create a logger
logger = logging.getLogger('langsmith')
logger.setLevel(logging.DEBUG) # Set the logging level
# Create a file handler
file_handler = logging.FileHandler('langsmith.log')
file_handler.setLevel(logging.DEBUG)
# Create a logging format
formatter = logging.Formatter('%(asctime)s - %(name)s - %(levelname)s - %(message)s')
file_handler.setFormatter(formatter)
# Add the file handler to the logger
logger.addHandler(file_handler)
# Example log message
logger.info('This is a log message.') This script sets up a logger that writes log messages to a file named |
Beta Was this translation helpful? Give feedback.
-
I didn't get the results I was expecting. Please tell me the source code where the logger definition used by default in langchain is defined. |
Beta Was this translation helpful? Give feedback.
-
I'm using langsmith, but it's a hassle to check the web page every time.
Please tell me how to output the log to a local file (e.g. langsmith.log).
Thank you
Beta Was this translation helpful? Give feedback.
All reactions