Create a new domain alignment workflow.
This endpoint initiates a domain alignment workflow that fine-tunes a base model using provided documents.
Request Body:
name: Name of the domain alignment projectbase_model: Base model to use for alignment (e.g., nugen-flash-instruct)document_ids: List of document IDs to use for training dataworkflow_id (optional): Custom workflow identifierbenchmark_id (optional): Benchmark ID for post-alignment evaluationdescription (optional): Description of the alignment projectReturns:
id: Unique alignment identifier for tracking workflow progressstatus: Initial workflow status (always pending)Raises:
400: If base model doesn’t support alignment or training provider is invalid404: If document IDs are not found or don’t belong to userExample Request:
POST /api/v3/alignment/create
Headers: {"Authorization": "Bearer <api_key>"}
{
"name": "Customer Support Domain Alignment",
"base_model": "nugen-flash-instruct",
"document_ids": ["doc-123", "doc-456", "doc-789"],
"benchmark_id": "task-abc123",
"description": "Alignment for customer support documentation and FAQs"
}
Example Response:
{
"id": "alignment-xyz789",
"status": "pending"
}
Notes:
/alignment/status/{id} to track workflow progressbenchmark_id is provided, the model will be evaluated automatically after alignmentBearer authentication header of the form Bearer <token>, where <token> is your auth token.
Name of the domain alignment project
"My Alignment Project"
Base model that alignment will be based on
"nugen-flash-instruct"
List of document IDs to generate synthetic training data from
["doc-abc123", "doc-def456"]This id is to orchestrate the entire flow
"workflow-abc123"
Benchmark ID for evaluation (created via /benchmark/create or /benchmark/upload)
"benchmark-xyz789"
Optional project description
"This project aims to align the model for better customer support performance."
Returns a unique identifier for the initiated domain alignment workflow along with the initial workflow status. This endpoint starts an asynchronous process to fine-tune a base model using provided documents and optional benchmark evaluation, allowing users to track progress and retrieve results once completed.