forked from Archives/langchain
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
458 B
Python
18 lines
458 B
Python
import platform
|
|
from functools import lru_cache
|
|
|
|
|
|
@lru_cache(maxsize=1)
|
|
def get_runtime_environment() -> dict:
|
|
"""Get information about the environment."""
|
|
# Lazy import to avoid circular imports
|
|
from langchain import __version__
|
|
|
|
return {
|
|
"library_version": __version__,
|
|
"library": "langchain",
|
|
"platform": platform.platform(),
|
|
"runtime": "python",
|
|
"runtime_version": platform.python_version(),
|
|
}
|