Answering Queries using Humans, Algorithms and Databases

Aditya G. Parameswaran, Neoklis PolyzotisCIDR 2011

Introduction

The rise of crowdsourcing platforms like Amazon Mechanical Turk has transformed human intelligence into a "programmable" resource. However, integrating this resource into software remains a manual and error-prone process. Developers are often forced to write complex, procedural scripts to manage task posting, pricing, quality control, and data integration. This paper proposes hQuery, a declarative framework designed to treat crowdsourcing services as a seamless extension of a traditional database system.

The hQuery Framework

At the heart of the proposal is a Datalog-like language that allows developers to specify what information they need without dictating how to retrieve it. The framework classifies data sources into three distinct predicate types:

  1. Relational Predicates (r-predicates): Standard data stored in traditional relational databases (e.g., a table of restaurant metadata).
  2. Algorithmic Predicates (a-predicates): Deterministic functions executed by code (e.g., a computer vision script that detects image brightness).
  3. Human Predicates (h-predicates): Tasks outsourced to a Crowd-Sourcing Service (CrSS) (e.g., asking a human to judge if a restaurant photo is "appealing").

By unifying these types, hQuery enables hybrid queries that combine the speed of algorithms with the nuanced judgment of humans. The authors also introduce ha-predicates, which can be resolved by either an algorithm or a human, allowing the system to choose the most cost-effective or accurate path.

Adaptive Query Processing

Unlike traditional SQL optimizers that focus primarily on execution speed, the hQuery engine must navigate a "skyline" of three competing objectives: Latency, Monetary Cost, and Uncertainty.

Because human computation is unpredictable, the engine does not follow a static execution plan. Instead, it is adaptive, selecting the next task based on "information gain." For instance, if a query seeks high-quality images of clean restaurants, the engine might first ask a human to filter for "cleanliness" if that predicate is expected to eliminate the most candidates, thereby saving money on subsequent tasks. This approach treats the crowd as a "virtual" table where facts are computed on demand.

Managing Noise and Uncertainty

Human workers are fallible, and crowdsourcing platforms are often plagued by "spammers" or low-effort contributors. To address this, hQuery moves beyond simple majority voting for answer consolidation. The authors suggest employing Item-Response Theory (IRT)—a psychometric model—to simultaneously estimate the difficulty of a task and the reliability of individual workers. This allows the system to weight answers from proven experts more heavily than those from unverified sources.

Challenges and Research Roadmap

As a vision paper presented at CIDR, the work outlines several open research challenges for the database community:

  • Latency Constraints: Because human responses take minutes or hours, hQuery is currently best suited for offline analytics rather than interactive, real-time applications.
  • Dynamic Pricing: The system could potentially adjust task rewards in real-time to meet deadlines, paying a premium for "bottleneck" tasks that are holding up the rest of the query.
  • Complex Outputs: While the current model excels at unit tasks (labeling, filtering), extending declarative logic to creative or generative human tasks (like writing summaries) remains an open problem.
  • Cardinality Estimation: Traditional databases rely on statistics to estimate result sizes; hQuery must solve the "hairy" problem of estimating the size of data that hasn't even been created by a human yet.

Conclusion

By treating the crowd as just another data source, hQuery provides a roadmap for a new generation of data-intensive applications. It shifts the burden of task management from the developer to the database engine, paving the way for more robust and scalable human-in-the-loop systems.

Summary updated

BibTeX
@inproceedings{parameswaran2011answering,
  author = {Aditya G. Parameswaran and Neoklis Polyzotis},
  title = {{Answering Queries using Humans, Algorithms and Databases}},
  booktitle = {CIDR},
  year = {2011},
}
Figure