Recommend Persona
POST /api/chat/personas/recommend
Get recommended persona for a task
Analyzes a task description and recommends the most appropriate AI persona to use. Uses keyword matching to suggest personas based on the task content.
Args: task_description: Description of the task to perform
Returns: Dict containing: - recommended_persona: Persona ID or null if no match - confidence: Match confidence (placeholder for now) - task_analyzed: The analyzed task description
Example Request: POST /chat/personas/recommend { “task_description”: “Help me edit my fantasy novel” }
Example Response: { “recommended_persona”: “creative_editor”, “confidence”: “high”, “task_analyzed”: “Help me edit my fantasy novel” }
Request Body required
Section titled “Request Body required ”Request model for persona recommendation endpoint.
Analyzes task description to recommend the most appropriate AI persona for handling the task based on content keywords and task type.
Fields: task_description: Description of the task requiring persona recommendation
JSON Example: { “taskDescription”: “Help me write a fantasy novel” }
Used By: - POST /api/chat/personas/recommend - Persona selection UI - Intelligent agent routing
object
Task description for persona matching
Responses
Section titled “ Responses ”Successful Response
Response model for persona recommendation endpoint.
Returns recommended persona for a given task based on content analysis and keyword matching for intelligent persona selection.
Fields:
recommended_persona: Recommended persona ID (optional, None if no match found)confidence: Match confidence score (0.0-1.0)task_analyzed: The task description that was analyzed
JSON Example:
{
"recommendedPersona": "creative_editor",
"confidence": 0.85,
"taskAnalyzed": "Help me edit my fantasy novel"
}Validation Error