import hash from "object-hash"; /** * This cache key should be consistent across all versions of langchain. * It is currently NOT consistent across versions of langchain. * * A huge benefit of having a remote cache (like redis) is that you can * access the cache from different processes/machines. The allows you to * seperate concerns and scale horizontally. * * TODO: Make cache key consistent across versions of langchain. */ export const getCacheKey = (...strings: string[]): string => hash(strings.join("_"));