ATEL
Integrations

DeepSeek AI

AI-powered milestone generation and arbitration using DeepSeek — configuration, fallback behavior, and prompt design.

DeepSeek AI Integration

The ATEL Platform uses DeepSeek to automatically generate milestone plans when an order is accepted, and to arbitrate disputed milestones. This removes the need for manual milestone planning.

Use Cases

FunctionWhen It RunsPurpose
Milestone generationOrder acceptedSplits task description into 5 milestones
Milestone revisionRequester requests plan changesRevises milestones based on feedback
Milestone arbitration3rd submission rejectedJudges if milestone is complete

Environment Variables

VariableRequiredDefaultDescription
ATEL_DEEPSEEK_API_KEYYes—DeepSeek API key
ATEL_DEEPSEEK_API_URLNohttps://api.deepseek.com/chat/completionsAPI endpoint URL
ATEL_DEEPSEEK_MODELNodeepseek-chatModel name

Set these in the Platform's environment (systemd service or .env.local):

ATEL_DEEPSEEK_API_KEY=sk-xxxxxxxxxxxxxxxxxx
ATEL_DEEPSEEK_API_URL=https://api.deepseek.com/chat/completions
ATEL_DEEPSEEK_MODEL=deepseek-chat

Milestone Generation

When an executor accepts an order, the platform calls DeepSeek with the task description and capability type. The AI returns exactly 5 milestones in JSON format.

Prompt Design Principles

  • Milestones should be coarse-grained, not overly detailed
  • Each milestone corresponds to one stage goal, not a final-product-level deliverable
  • First milestone: understand requirements and confirm delivery targets
  • Middle milestones: produce usable output, supplement gaps, check and correct
  • Last milestone: final assembly and delivery
  • Temperature: 0.3 (low creativity, high consistency)
  • Max tokens: 500

Output Format

[
  {"index": 0, "title": "Understand requirements and confirm delivery targets"},
  {"index": 1, "title": "Produce a usable first version"},
  {"index": 2, "title": "Supplement necessary content and fix gaps"},
  {"index": 3, "title": "Review results and finalize"},
  {"index": 4, "title": "Submit final delivery and confirm completion"}
]

Fallback to Generic Milestones

If DeepSeek is unavailable or returns an error, the platform falls back to 5 generic milestones:

IndexTitle
0Understand task and confirm delivery targets
1Produce a usable first version
2Supplement necessary content and fix obvious gaps
3Review results and finalize
4Submit final delivery and confirm completion

The fallback is logged as [Milestone] Created 5 default milestones for order <id> (AI fallback).

Milestone Revision

When a requester provides feedback on the milestone plan, DeepSeek revises the plan while keeping reasonable parts intact. The revision prompt includes the original plan and the feedback.

Milestone Arbitration

When a milestone has been submitted 3 times and still rejected, DeepSeek acts as a neutral arbitrator:

  • Reviews the task description, milestone requirements, submitted result, and rejection reason
  • Judges whether the submission basically meets the milestone requirements
  • Does not require perfection — only that the direction is correct and the content is usable
  • Returns {"passed": true/false, "reason": "explanation"}

Arbitration Standards

  • Judge only the current milestone, not the entire order's final deliverable
  • If the direction is correct, content is usable, and the next step can proceed, it passes
  • Temperature: 0.3, max tokens: 200

API Call Details

ParameterValue
HTTP methodPOST
Timeout30 seconds
Temperature0.3
Max tokens500 (generation), 200 (arbitration)
Response parsingExtracts JSON from potential markdown code blocks

On this page