feat: generalize persona workflow task schema#13
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a7662edeb2
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| raw_inputs = raw_task_input["inputs"] | ||
| normalized = { | ||
| "task_name": str(raw_task_input.get("task_name") or "Untitled Persona Workflow"), | ||
| "task_type": str(raw_task_input.get("task_type") or "market_research"), |
There was a problem hiding this comment.
Normalize
task_type before storing normalized input
validate_task_input trims whitespace when checking membership, so a value like "market_research " passes validation, but normalize_task_input stores the untrimmed value here and downstream code uses it directly (profile_for(task_type) in build_design_output), which raises KeyError at runtime. This means a task can be marked valid and still crash the workflow; trimming task_type during normalization (in both branches) avoids this mismatch.
Useful? React with 👍 / 👎.
* feat: integrate dynamic task input into persona workflow * feat: generalize persona workflow task schema (#13)
Summary:
Validation:
Notes: