MCPcopy Create free account
hub / github.com/OpenRaiser/PaperFlow / _doc_payloads

Function _doc_payloads

deployments/desktop/shared/agents.py:2826–2848  ·  view source on GitHub ↗
(docs: Iterable[Dict[str, Any]])

Source from the content-addressed store, hash-verified

2824 return "The GUI language is set to English; this reading report will be written in English."
2825 return "GUI 页面当前选择语言为中文;本次精读报告将按中文生成。"
2826
2827
2828def _reading_task_payload(task: Optional[Dict[str, Any]]) -> Optional[Dict[str, Any]]:
2829 if not task:
2830 return None
2831 return {key: value for key, value in task.items() if key not in {"thread", "internal_docs"}}
2832
2833
2834def _finish_reading_task(task_id: str) -> None:
2835 with _READING_TASK_LOCK:
2836 task = _READING_TASKS.get(task_id)
2837 if not task:
2838 return
2839 task["status"] = "running"
2840 task["progress_phase"] = "running"
2841 task["updated_at"] = _task_timestamp()
2842 user_id = str(task.get("user_id") or "")
2843 push_id = str(task.get("push_id") or "")
2844 response_language = str(task.get("response_language") or "zh")
2845 write_feishu = task.get("write_feishu")
2846 selected_numbers = list(task.get("selected_numbers") or [])
2847 docs = list(task.get("internal_docs") or [])
2848 created_docs_snapshot = list(task.get("created_docs") or [])
2849 completed_docs: List[Dict[str, Any]] = []
2850 errors: List[str] = []
2851

Callers 2

_reports_payloadFunction · 0.85

Calls 3

_report_idFunction · 0.85
_paper_cardFunction · 0.85
getMethod · 0.80

Tested by

no test coverage detected