wzgy

Results 4 comments of wzgy

> > 解法加强了,800秒可跑出今日的话题关卡,普通关卡 60秒左右 但是生成的数据文件 被压塑需要还原然后魔改 才能用在第三方web自动解 网页,yin'we 输出的倒数第第二行是post提交数据 > > 建议和3d地图版 完美结合直接 如果跑出来结果直接写入 js 刷新 > > 我以为是优化了算法,结果今天算不出来。2022.11.1 周末一般都简单,这周周一也简单, 运算量在那儿,出题者减小横截面、增加种类、减少每种牌的数量,运算量直接就爆炸了

是tiktoken的锅,[tiktoken_ext/openai_public.py#L17](https://github.com/openai/tiktoken/blob/4560a8896f5fb1d35c6f8fd6eee0399f9a1a27ca/tiktoken_ext/openai_public.py#L17)会去下载gpt2的分词器 而dify在[python/dify_plugin/interfaces/model/ai_model.py#L281](https://github.com/langgenius/dify-plugin-sdks/blob/b936b1be9f91d1ae6725604ad8938b80cf42c635/python/dify_plugin/interfaces/model/ai_model.py#L281)引用了gpt2的分词器

> > 是tiktoken的锅,[tiktoken_ext/openai_public.py#L17](https://github.com/openai/tiktoken/blob/4560a8896f5fb1d35c6f8fd6eee0399f9a1a27ca/tiktoken_ext/openai_public.py#L17)会去下载gpt2的分词器 而dify在[python/dify_plugin/interfaces/model/ai_model.py#L281](https://github.com/langgenius/dify-plugin-sdks/blob/b936b1be9f91d1ae6725604ad8938b80cf42c635/python/dify_plugin/interfaces/model/ai_model.py#L281)引用了gpt2的分词器 > > 请问怎么解决呢 @momomobinx 已经给出了[解决方案](https://github.com/langgenius/dify/issues/14565#issuecomment-2716290533) 但挂载只是临时方案,建议项目组写进Dockerfile,打进镜像