__init__.py 908 B

12345678910111213141516171819202122232425262728293031
  1. """
  2. 数据库封装模块
  3. - connection: 共享数据库连接
  4. - schedule: 定时任务相关(demand_content、demand_find_task)
  5. - store_results: 推荐结果写入(demand_find_author、demand_find_content_result)
  6. """
  7. from .connection import get_connection
  8. from .open_aigc_pattern_connection import get_open_aigc_pattern_connection
  9. from .schedule import (
  10. get_next_unprocessed_demand,
  11. get_daily_unprocessed_pool,
  12. create_task_record,
  13. update_task_status,
  14. update_task_on_complete,
  15. )
  16. from .store_results import upsert_good_authors, insert_contents, update_content_plan_ids
  17. __all__ = [
  18. "get_connection",
  19. "get_open_aigc_pattern_connection",
  20. "get_next_unprocessed_demand",
  21. "get_daily_unprocessed_pool",
  22. "create_task_record",
  23. "update_task_status",
  24. "update_task_on_complete",
  25. "upsert_good_authors",
  26. "insert_contents",
  27. "update_content_plan_ids",
  28. ]