chore: 初始化 eightbf-analysis-go(对齐 Java 会商作业服务)
Go 实现 /api/v1/analysis 契约、Demo/Live Worker、DeerFlow SSE;含设计文档与冒烟脚本。 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
commit
0c45b86d67
29 files changed
+3789
No files matched your search
@@ -0,0 +1,21 @@
|
||||
package domain
|
||||
|
||||
// 会商作业状态(与 Java JobStatus / 前端约定一致,勿自创别名)。
|
||||
const (
|
||||
StatusQueued = "queued"
|
||||
StatusRunning = "running"
|
||||
StatusAwaitingInput = "awaiting_input"
|
||||
StatusDone = "done"
|
||||
StatusError = "error"
|
||||
StatusCancelled = "cancelled"
|
||||
)
|
||||
|
||||
// IsActive 是否仍可能被 worker 推进(含等人中)。
|
||||
func IsActive(status string) bool {
|
||||
return status == StatusQueued || status == StatusRunning || status == StatusAwaitingInput
|
||||
}
|
||||
|
||||
// IsTerminal 是否已结束,不应再 resume / inject / 改计划。
|
||||
func IsTerminal(status string) bool {
|
||||
return status == StatusDone || status == StatusError || status == StatusCancelled
|
||||
}
|
||||
Reference in new issue
Block a user