hired.tools
High-level orchestration functions - the main API.
These are the primary user-facing functions that coordinate the entire pipeline.
- hired.tools.mk_content_for_resume(candidate_info_src: ContentSource | str | dict, job_info_src: ContentSource | str | dict | JobResult, *, agent: Any | None = None, validate: bool = True, strict: bool = False) ResumeSchemaExtended[source]
Generate resume content from candidate and job information.
- Parameters:
candidate_info_src – Candidate information as ContentSource, file path, or dict
job_info_src – Job information as ContentSource, file path, dict, or JobResult
agent – Optional AI agent for content generation
validate – Whether to validate the generated content
strict – Whether to use strict validation
- Returns:
ResumeSchemaExtended object with generated content
Examples
>>> # Using file paths >>> content = mk_content_for_resume("candidate.json", "job.txt") >>> >>> # Using JobResult from job search >>> from hired import JobSources, SearchCriteria >>> sources = JobSources() >>> jobs = sources.jobspy.search(SearchCriteria(query="python developer")) >>> content = mk_content_for_resume(candidate_dict, jobs[0])
- hired.tools.mk_resume(content: ResumeSchemaExtended | dict, rendering: RenderingConfig | dict | None = None, *, output_path: str | None = None, strict: bool = False) bytes[source]
Render resume content to final format.
- hired.tools.render_resume_with_template_and_css(content: ResumeSchemaExtended | dict, template_path: str | Path, css_path: str | Path | None = None, *, format='pdf', strict: bool = False) bytes[source]
Render a resume dict (or pydantic model) to PDF using a specific HTML template file and optional CSS file.
- Parameters:
content – Resume content as a dict or ResumeSchemaExtended instance.
template_path – Path to an HTML/Jinja template file to render from.
css_path – Optional path to a CSS file; its contents will be passed to the renderer as custom_css so PDF rendering picks up the styles.
format – Output format, ‘pdf’ or ‘html’. Default is ‘pdf’.
strict – If True, enable stricter schema validation.
- Returns:
PDF file bytes.