affaan-m/ECC · error · ValueError
interview produced an invalid profile
Error message
interview produced an invalid profile: {problems} What it means
conduct() runs the taste interview and validates the assembled profile dict against TASTE_PROFILE_SCHEMA before returning it. If any required key, type, or structure is missing or wrong, the interviewer refuses to emit the profile and lists the schema problems. It is an internal invariant: the interview flow itself produced a malformed profile.
Solutions
- Inspect the `problems` list in the message — it names each missing/mistyped field
- Ensure every interview question that feeds a required schema field is asked and non-empty before building the profile
- Run schema.validate(profile, schema.TASTE_PROFILE_SCHEMA) on your assembled answers locally to reproduce
- Update the profile-building code to match the current TASTE_PROFILE_SCHEMA if the schema recently changed
Example fix
// before: brief collected but 'look' question skipped
profile['answers'] = {'content': {'brief': brief}}
// after: all required answers gathered first
assert look and brief, 'interview must collect look and brief'
profile['answers'] = {'look': look, 'content': {'brief': brief}} Defensive patterns
Strategy: validation
Validate before calling
from tasteforge.scripts.tasteforge import schema
problems = schema.validate(profile, schema.TASTE_PROFILE_SCHEMA)
if problems:
raise ValueError(f'profile invalid before conduct(): {problems}') Type guard
def is_valid_profile(profile):
return isinstance(profile, dict) and not schema.validate(profile, schema.TASTE_PROFILE_SCHEMA) Try / catch
try:
profile = interview.conduct(answers)
except ValueError as e:
logger.error('interview profile rejected: %s', e)
raise Prevention
- Validate intermediate answer dicts with TASTE_PROFILE_SCHEMA before passing them in
- Keep the interview question list in sync with schema-required fields
- Cover conduct() with a unit test asserting a valid profile for canonical answers
- Re-run validation whenever the schema evolves
When it happens
Trigger: The interview answers collected do not populate every schema-required field (e.g. missing 'look', empty 'content'/'brief', wrong nesting of 'answers'/'content'), so schema.validate returns non-empty problems.
Common situations: Customizing interview question flows and dropping a question whose answer feeds a required profile field; programmatic invocation of conduct() with mocked/empty answer inputs; schema updated to require new fields while the interview code still builds the old shape.
Understand the failure class
Background: Schema validation failed / invalid input schema: payload rejected because its shape doesn't match the expected schema — this error's family across 28 libraries.
Related errors
- input_artifacts must be a list
- has invalid
- lacks probe evidence
- reference style evidence times must be finite and within…
- -32602
AI-assisted analysis of affaan-m/ECC@8321021c54 (2026-09-16).
Data as JSON: /api/errors/b55bd9692b1b9fb7.
Report an issue: GitHub.
Appendix: source
Thrown at skills/taste-application/scripts/tasteforge/interview.py:96
brief = (answers.get("brief") or "").strip()
if not brief:
unanswered.append("brief")
profile = {
"schema_version": 1,
"genre": genre,
"created": _utc_now(),
"answers": {k: str(v).strip() for k, v in answers.items() if str(v).strip()},
"unanswered": unanswered,
"constraints": {
"look": look,
"content": {"brief": brief},
},
}
problems = schema.validate(profile, schema.TASTE_PROFILE_SCHEMA)
if problems:
raise ValueError(f"interview produced an invalid profile: {problems}")
return profile
View on GitHub (pinned to 8321021c54)