Datasets · Question answering Legacy
Laravel 11 QA Long Form
1,453 Laravel 11 questions with long answers, generated from the official documentation. 86% of answers have step headings, and 95% include a code block.
How do you test job dispatching in Laravel without executing the jobs?
Testing Job Dispatching in Laravel Without Execution
When developing applications in Laravel, you might want to test job dispatching without actually executing the jobs. This is particularly useful when you want to ensure that your application logic correctly queues jobs without running them. Laravel provides a convenient way to fake job dispatching using the Queue facade.
Step 1: Fake the Queue
To prevent jobs from being executed, you can use the Queue::fake() method. This method will intercept any jobs that are dispatched, allowing you to make assertions on them without executing the job logic.
use Illuminate\Support\Facades\Queue; Queue::fake();
Overview
The answers come from the same Laravel 11 documentation as Laravel 11 QA. The median answer is 348 words, and 90% of answers open with a Markdown heading. I fine-tuned the same two Llama models on this set.
- Pairs
- 1,453
- Median answer
- 348 words
- Answers with code
- 95%
- Models trained
- 2
- Task
- Question answering
- License
- MIT (opens in a new tab)
- Splits
- train 1,453
- Format
- Parquet · 1.7 MB
- Published
- Downloads
- 747 all time
Example row
How do you test job dispatching in Laravel without executing the jobs?
Testing Job Dispatching in Laravel Without Execution
When developing applications in Laravel, you might want to test job dispatching without actually executing the jobs. This is particularly useful when you want to ensure that your application logic correctly queues jobs without running them. Laravel provides a convenient way to fake job dispatching using the Queue facade.
Step 1: Fake the Queue
To prevent jobs from being executed, you can use the Queue::fake() method. This method will intercept any jobs that are dispatched, allowing you to make assertions on them without executing the job logic.
use Illuminate\Support\Facades\Queue;
Queue::fake();Answer length
68% of answers in this set run 200 to 399 words. The chart counts words per answer in both Laravel sets, from the published Parquet files.
- 0-24
- 25-49
- 50-99
- 100-199
- 200-399
- 400+
- Laravel 11 QA Long Form median 348
- Laravel 11 QA median 50
How it was made
Topics
Topics were taken from the Laravel 11 documentation as of October 1, 2024.
Questions
Models from OpenAI and Anthropic wrote questions about each topic.
Answers
The same models wrote long answers with explanations and code examples.
Review
The answers were reviewed and edited for accuracy.
Limitations
- Coverage stops at the Laravel 11 documentation as of October 1, 2024.
Load the dataset
The splits are Parquet files on Hugging Face, released under MIT.
from datasets import load_dataset
long_form = load_dataset("yannelli/laravel-11-qa-long-form", split="train")
print(long_form[0]["human"])
print(long_form[0]["assistant"])Fields
humanstring- A question about Laravel 11.
assistantstring- A long answer in Markdown.
Ryan Yannelli, Laravel 11 Documentation Q&A (Long Form), Hugging Face, 2024, https://huggingface.co/datasets/yannelli/laravel-11-qa-long-formModels
- Safetensors1BLaravel 11 Llama 3.2 1B InstructLlama 3.2 1B Instruct fine-tuned on both Laravel sets and a private code-samples set, on one RTX 3070 Ti. (opens Hugging Face in a new tab)
- GGUF1BLaravel 11 Llama 3.2 1B Instruct GGUFThe 1B fine-tune as GGUF, for LM Studio, Jan, vLLM, and llama.cpp. (opens Hugging Face in a new tab)
- Safetensors8BLaravel 11 Llama 3.1 8B InstructLlama 3.1 8B Instruct fine-tuned on both Laravel sets. (opens Hugging Face in a new tab)
- GGUF8BLaravel 11 Llama 3.1 8B Instruct GGUFThe 8B fine-tune as GGUF for local runtimes. (opens Hugging Face in a new tab)
More datasets
All datasetsCLI Command Risk
124,923 shell commands in five shells, labeled from safe to critical with risk categories, for classifiers that check a command before a terminal or coding agent runs it.
124,923 rowsCC BY 4.048 downloads
View datasetJS/TS Code Review Decisions
12,000 synthetic JavaScript and TypeScript snippets labeled for 10 code review flaws. The dataset has 27,450 line-level findings and a 13-question benchmark for small decision models.
12,000 rowsCC BY 4.0200 downloads
View datasetLaravel 11 QA Legacy
12,649 question and answer pairs generated from the official Laravel 11 documentation, for fine-tuning and evaluating small models on Laravel.
12,649 rowsMIT1,248 downloads
View dataset