How Recurring Tasks and Background Jobs Are Handled in Hiring-Agent

Hiring-agent does not implement an internal scheduler, worker pool, or background-job framework; all processing executes synchronously when the CLI is invoked, with file-based caching available only for development workflows.

The open-source interviewstreet/hiring-agent repository provides a command-line resume evaluation tool that processes documents end-to-end in a single synchronous run. Unlike production-grade hiring platforms that rely on Celery, APScheduler, or async task queues, this architecture deliberately avoids background processing to maintain simplicity. Understanding this design decision clarifies why recurring workloads require external orchestration rather than internal triggering.

Synchronous Pipeline Execution

All business logic in hiring-agent runs synchronously through a single entry point. In score.py, the if __name__ == "__main__" block orchestrates the complete pipeline: PDF text extraction via pymupdf_rag.py, section parsing through LLM calls, optional GitHub profile enrichment via github.py, and final evaluation through evaluator.py.

Each step executes sequentially during the CLI invocation:

python score.py resume_candidate.pdf

The script runs to completion before returning control to the shell, with no daemon processes, threads, or coroutines remaining active after termination.

Absence of Background-Job Frameworks

A comprehensive review of the source tree reveals zero imports of scheduling or concurrency libraries. The codebase contains no references to celery, apscheduler, cron, threading, multiprocessing, or asyncio.

Processing modules such as pdf.py, pymupdf_rag.py, and evaluator.py implement pure synchronous functions that block until LLM API calls and file I/O complete. According to the repository structure, there are no worker configuration files, no task queues, and no scheduler databases—only the main execution thread handling one resume at a time.

Development-Mode Caching as State Management

The only mechanism approximating "recurring" behavior is the optional file-based cache system controlled by DEVELOPMENT_MODE in config.py. When enabled, intermediate results serialize to the cache/ directory during execution:

  • cache/resumecache_*.json stores extracted resume sections
  • cache/githubcache_*.json stores fetched GitHub profile data

These JSON snapshots persist between CLI invocations, allowing subsequent runs to skip expensive LLM parsing or API calls if the source data remains unchanged. However, this is pure read optimization—not background processing. The cache only refreshes when a user manually re-runs python score.py <file>, and stale entries are never updated automatically.

Implementing External Recurring Execution

Because hiring-agent lacks internal scheduling, any recurring task requirement must leverage external automation. The CLI accepts file paths as arguments, making it compatible with standard Unix schedulers and CI pipelines.

To process resumes on a fixed schedule, wrap the CLI in a cron job or systemd timer:


# Cron entry to evaluate new resumes every hour

0 * * * * cd /opt/hiring-agent && python score.py /data/uploads/*.pdf >> /var/log/hiring-agent.log 2>&1

For batch processing across multiple files, invoke the script in a loop:

for resume in /path/to/resumes/*.pdf; do
    python score.py "$resume"
done

Summary

  • No internal scheduler: Hiring-agent contains no task queues, workers, or timing mechanisms.
  • Synchronous-only execution: The score.py entry point processes each resume in a single blocking run through the complete pipeline.
  • Development caching: The cache/ directory provides file-based persistence for LLM results and GitHub data, but requires manual CLI re-runs to refresh.
  • External dependency: True recurring execution requires cron, systemd timers, or CI pipelines to trigger python score.py automatically.

Frequently Asked Questions

Does hiring-agent support Celery or Redis Queue for background jobs?

No. The repository does not import Celery, RQ, or any distributed task queue libraries. All code executes in the main thread, making it unsuitable for asynchronous background processing without significant architectural modification.

How can I automate hiring-agent to run on a schedule?

You must use an external scheduler such as Linux cron, systemd timers, or a CI/CD pipeline (GitHub Actions, GitLab CI) to invoke python score.py <resume> at your desired interval. The tool itself exposes no scheduling API or daemon mode.

What is the purpose of the cache/ directory?

The cache/ directory stores serialized JSON outputs from expensive operations like LLM section parsing and GitHub API calls. When DEVELOPMENT_MODE=True in config.py, the pipeline reads these files on subsequent runs to avoid redundant API calls. This is a development optimization, not a background-job system.

Is there any asynchronous processing in the pipeline?

No. The codebase uses synchronous HTTP requests and blocking file I/O throughout. Modules like github.py and evaluator.py make sequential API calls that block until responses return, with no async/await patterns or thread pools implemented.

Have a question about this repo?

These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:

Share the following with your agent to get started:
curl -s "https://instagit.com/install.md"

Works with
Claude Codex Cursor VS Code OpenClaw Any MCP Client

Maintain an open-source project? Get it listed too →