答:默认本地存储可用 index.storage_context.persist(persist_dir=...) 保存。重启后通过 StorageContext.from_defaults(persist_dir=...) 取得上下文,再用 load_index_from_storage 恢复索引。
题干与完整题解免费阅读第 1 / 1 页
本页 1 道,共 1 道浏览其他领域
答:默认本地存储可用 index.storage_context.persist(persist_dir=...) 保存。重启后通过 StorageContext.from_defaults(persist_dir=...) 取得上下文,再用 load_index_from_storage 恢复索引。