第一次合并clean代码
This commit is contained in:
0
examples/__init__.py
Normal file
0
examples/__init__.py
Normal file
22
examples/dify-sty-agent-reparagraph.py
Normal file
22
examples/dify-sty-agent-reparagraph.py
Normal file
@@ -0,0 +1,22 @@
|
||||
from clean.reparagraph import *
|
||||
from config import ConfigFactory
|
||||
|
||||
OPENAI_BASE_URL = "XXX"
|
||||
OPENAI_API_KEY = "XXX"
|
||||
MODEL_NAME = "deepseek-chat"
|
||||
|
||||
class ReparagraphConfig(ConfigFactory):
|
||||
"""配置类"""
|
||||
def __init__(self):
|
||||
self.remove_content = True
|
||||
self.max_file_size = 50 * 1024 * 1024 # 50MB
|
||||
self.backup = True
|
||||
self.dry_run = False
|
||||
self.parallel = True
|
||||
self.task_name = "result_reparagraph"
|
||||
self.openai_base_url = OPENAI_BASE_URL
|
||||
self.openai_api_key = OPENAI_API_KEY
|
||||
self.model_name = MODEL_NAME
|
||||
|
||||
config = ReparagraphConfig()
|
||||
reparagraph_file("/home/ubuntu/50T/LYT/datapipe/result/dify-sty-agent", config)
|
||||
Reference in New Issue
Block a user