feat: 岗位会商命令幂等与圆桌后台作业租约调度
岗位会商写操作引入 command_id 幂等与版本锁,前端支持同键重试;圆桌后台作业改为 DB 租约 dispatcher、去重与草稿 outbox 补偿,并持久化 intent turns。 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
4f536d9b39
commit
75963c9ad9
51 files changed
+4449
-670
No files matched your search
@@ -162,6 +162,25 @@ The separately deployed TaskCOP Vue app uses `POST /api/v1/auth/login/username`
|
||||
|
||||
Position-roundtable history supports two modes. A non-empty `external_task_id` from the frontend route's `taskId` creates a row with `task_scoped = true`, so all sessions, nodes and persisted conversation snapshots for that task are shared across users; `user_id` is then creator audit metadata only. When the field is absent or empty, the original per-user personal-session behavior remains unchanged. Alembic revision `20260808_01` adds `task_scoped` with the safe default `false` for historical rows plus the task/update-time index.
|
||||
|
||||
### Roundtable concurrency guarantees
|
||||
|
||||
Position-roundtable node completion, rejection, thread binding and activation
|
||||
are database transactions with row locking and retry-stable command ids. This
|
||||
keeps simultaneous seat completion from leaving a downstream stage locked.
|
||||
Task and intent snapshots are frozen when the chain becomes active, so a late
|
||||
request from another user cannot alter the confirmed input. Background
|
||||
roundtable jobs use a database unique active-job key and renewable worker
|
||||
leases; cancelled jobs are finalized by the lease holder or recovered after an
|
||||
expired lease, allowing users to start a new job after a worker failure.
|
||||
|
||||
The ordinary unit tests use SQLite. To verify deployed database semantics with
|
||||
real PostgreSQL row locks and independent connections, set
|
||||
`DEERFLOW_POSTGRES_CONCURRENCY_TEST_URL` and run:
|
||||
|
||||
```bash
|
||||
PYTHONPATH=. uv run --no-sync pytest tests/test_roundtable_postgres_concurrency.py -q
|
||||
```
|
||||
|
||||
AI writing supports a sample-imitation mode: the frontend can upload or paste a sample article, the Gateway extracts text for document files, and the `ai_writing` graph runs a `sample_analyzer` node before normal intent/research/outline/draft stages. The resulting style profile is injected into outline and draft prompts with explicit guardrails against copying source sentences, facts, names, or data.
|
||||
|
||||
### Custom Agents
|
||||
|
||||
Reference in new issue
Block a user