Datasets:
prompt large_stringlengths 150 7.97k | target large_stringlengths 32 83 | kind large_stringclasses 3
values |
|---|---|---|
I copied this from the docs:
module "mirror" {
source = "../host"
base_configuration = var.base_configuration
name = "mirror"
use_os_released_updates = var.use_os_released_updates
additional_repos = var.additional_repos
additional_packages = var.additional_packages
swap... | {"is_valid":true,"category":{"Terraform":true}} | single |
Here is the code I was given:
#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 ... | {"is_valid":true,"category":{"Dockerfile":true}} | single |
The technology conference attracted engineers, designers, and product managers from around the world. Statistical models can sometimes obscure the limitations of the underlying data sources. Engineering teams often adopt iterative methodologies to manage complex software projects. Quality assurance teams collaborate cl... | {"is_valid":true,"category":{"Bash":true}} | single |
Policy analysts examined the long-term implications of the proposed legislative reform. Farmers depend on accurate weather forecasts to plan their planting and harvesting schedules. Astronomers observed a faint signal that appeared to originate from a distant galaxy. I copied this from the docs:
use strict;
use warning... | {"is_valid":true,"category":{"Perl":true}} | single |
Here is the code I was given:
public static void Main()
{
var lookupTable = File.ReadLines("unixdict.txt").ToLookup(line => AnagramKey(line));
var query = from a in lookupTable
orderby a.Key.Length descending
let deranged = FindDeranged(a)
where deranged != null
select | {"is_valid":true,"category":{"C#":true}} | single |
Quick question about this snippet:
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2... | {"is_valid":true,"category":{"Dockerfile":true}} | single |
Project managers stressed the importance of clear documentation throughout the cycle. Historians continue to debate the significance of the treaty signed in that pivotal year. The newly opened gallery showcased contemporary works by emerging regional artists. The neighborhood gathered every Saturday morning at the smal... | {"is_valid":true,"category":{"Go":true}} | single |
He walked along the river path, listening to the rustling of leaves overhead. He adjusted the telescope and waited patiently for the clouds to clear over the observatory. Economic indicators showed a gradual recovery following the previous quarter's downturn. Distributed systems demand careful attention to consistency,... | {"is_valid":true,"category":{"Rust":true}} | single |
I copied this from the docs:
static void Main(string[] args)
{
int p;
p = 1;
Console.WriteLine("Ref Before: " + p);
Value(ref p);
Console.WriteLine("Ref After : " + p);
p = 1;
Console.WriteLine("Val Before: " + p);
Value(p);
Console.WriteLine("Val After : " + p);
Console.ReadLine();
}
private static v... | {"is_valid":true,"category":{"C#":true}} | single |
Network operators continually upgrade infrastructure to keep pace with growing demand. Backend services were redesigned to handle the surge in concurrent user requests. Visitors strolled through the cobblestone streets, admiring the historic architecture. Local potters fired their kilns once a month, producing colorful... | {"is_valid":true,"category":{"C++":true,"AWK":true}} | multi |
Visitors strolled through the cobblestone streets, admiring the historic architecture. Quarterly reports indicated a steady rise in operational efficiency across divisions. He wandered through the old bookstore, occasionally pulling a worn paperback from the shelf. Network operators continually upgrade infrastructure t... | {"is_valid":true,"category":{"SQL":true}} | single |
Nutritionists generally recommend a balanced diet rich in whole grains and fresh produce. Could you explain what this code does:
apiVersion: v1
kind: Service
metadata:
name: svc-lb
namespace: kube-lease
spec:
type: LoadBalancer
There's also this version:
PI = 3.141592653589793
TWO_PI = 6.283185307179586
def no... | {"is_valid":true,"category":{"YAML":true,"Python":true}} | multi |
The committee scheduled a follow-up meeting to discuss the budget allocations. Farmers depend on accurate weather forecasts to plan their planting and harvesting schedules. Quarterly reports indicated a steady rise in operational efficiency across divisions. Researchers have been studying migration patterns of monarch ... | {"is_valid":true,"category":{"C#":true,"Dockerfile":true}} | multi |
The garden looked particularly vibrant after the recent rain. Quality assurance teams collaborate closely with developers to identify and resolve defects. Policy analysts examined the long-term implications of the proposed legislative reform. Public libraries have evolved into community hubs offering far more than just... | {"is_valid":true,"category":{"PowerShell":true}} | single |
Researchers have been studying migration patterns of monarch butterflies for years. Hikers were advised to carry plenty of water and to inform someone of their planned route. He sat by the window with a steaming mug of tea and watched the snow gently falling. The painting featured warm colors that evoked memories of ch... | {"is_valid":true,"category":{"Go":true}} | single |
She enjoyed reading historical novels that transported her to far away places. Researchers have been studying migration patterns of monarch butterflies for years. Researchers gathered data from hundreds of households participating in the longitudinal study. Hikers were advised to carry plenty of water and to inform som... | {"is_valid":true,"category":{"Python":true}} | single |
Researchers gathered data from hundreds of households participating in the longitudinal study. What does this output:
CREATE TABLE gas_station (station_id VARCHAR, LOCATION VARCHAR, manager_name VARCHAR, open_year VARCHAR);
SELECT station_id, LOCATION, manager_name FROM gas_station ORDER BY open_year The library hosted... | {"is_valid":true,"category":{"SQL":true}} | single |
Find any security problems in:
#!/usr/bin/env bash
declare -i -a CRC32_LOOKUP_TABLE
__generate_crc_lookup_table() {
local -i -r LSB_CRC32_POLY=0xEDB88320 # The CRC32 polynomal LSB order
local -i index byte lsb
for index in {0..255}; do
((byte = 255 - index))
for _ in {0..7}; do # 8-bit lsb shift
(... | {"is_valid":true,"category":{"Bash":true}} | single |
Here is the code I was given:
package main
import (
"fmt"
"math/big"
)
func main() {
sequence()
bank()
rump()
}
func sequence() {
// exact computations using big.Rat
var v, v1 big.Rat
v1.SetInt64(2)
v.SetInt64(-4)
n := 2
c111 := big.NewRat(111, 1)
c1130 := big.NewRa... | {"is_valid":true,"category":{"Go":true}} | single |
She drafted a detailed agenda for the upcoming retreat and circulated it to all participants. Hikers were advised to carry plenty of water and to inform someone of their planned route. The neighborhood gathered every Saturday morning at the small farmers' market downtown. Database administrators monitor query performan... | {"is_valid":true,"category":{"C#":true}} | single |
Historians continue to debate the significance of the treaty signed in that pivotal year. Historians continue to debate the significance of the treaty signed in that pivotal year. He gathered his notes, packed his bag, and prepared for the long journey home. The technology conference attracted engineers, designers, and... | {"is_valid":true,"category":{"Scala":true}} | single |
Backend services were redesigned to handle the surge in concurrent user requests. She organized her bookshelves by genre and then alphabetically within each section. The newly opened gallery showcased contemporary works by emerging regional artists. She organized her bookshelves by genre and then alphabetically within ... | {"is_valid":true,"category":{"Java":true,"R":true}} | multi |
I need help debugging this script:
#include <string>
#include <boost/regex.hpp>
#include <iostream>
std::string csvToHTML( const std::string & ) ;
int main( ) {
std::string text = "Character,Speech\n"
"The multitude,The messiah! Show us the messiah!\n"
"Brians mother,<an | {"is_valid":true,"category":{"C++":true}} | single |
The engineer reviewed the blueprints carefully before approving the modifications. He adjusted the telescope and waited patiently for the clouds to clear over the observatory. Project managers stressed the importance of clear documentation throughout the cycle. Engineering teams often adopt iterative methodologies to m... | {"is_valid":true,"category":{"C":true}} | single |
He sat by the window with a steaming mug of tea and watched the snow gently falling. The painting featured warm colors that evoked memories of childhood summers by the sea. Astronomers observed a faint signal that appeared to originate from a distant galaxy. Add comments to make this clearer:
CREATE TABLE degrees (Id V... | {"is_valid":true,"category":{"SQL":true}} | single |
The classroom hummed with quiet conversation as students worked through practice problems. Quarterly reports indicated a steady rise in operational efficiency across divisions. | {"is_valid":false,"category":{}} | benign |
He walked along the river path, listening to the rustling of leaves overhead. A gentle breeze drifted across the meadow as the sun began to dip below the horizon. Travelers explored ancient ruins, marveling at the craftsmanship of long-lost civilizations. Energy researchers are exploring various pathways for reducing c... | {"is_valid":false,"category":{}} | benign |
Software architects often debate the merits of monolithic versus microservice designs. What does this output:
# syntax: GAWK -f ALIGN_COLUMNS.AWK ALIGN_COLUMNS.TXT
BEGIN {
colsep = " " # separator between columns
report("raw data")
}
{ printf("%s\n",$0)
arr[NR] = $0
n = split($0,tmp_arr,"$")
for (... | {"is_valid":true,"category":{"AWK":true}} | single |
Run the following:
function convexHull(points) {
points.sort(comparison);
var L = [];
for (var i = 0; i < points.length; i++) {
while (L.length >= 2 && cross(L[L.length - 2], L[L.length - 1], points[i]) <= 0) {
L.pop();
}
L.push(points[i]);
}
var U = [];
for (... | {"is_valid":true,"category":{"JavaScript":true}} | single |
She drafted a detailed agenda for the upcoming retreat and circulated it to all participants. The morning light filtered through the kitchen window as the coffee brewed. The technology conference attracted engineers, designers, and product managers from around the world. She placed the manuscript carefully on the desk ... | {"is_valid":true,"category":{"JavaScript":true}} | single |
Children played in the park while their parents chatted on the wooden benches nearby. She enjoyed reading historical novels that transported her to far away places. The newly opened gallery showcased contemporary works by emerging regional artists. Find any security problems in:
#include <stdlib.h>
#include <string.h>
... | {"is_valid":true,"category":{"C":true}} | single |
Public libraries have evolved into community hubs offering far more than just printed books. Volunteers spent the weekend cleaning up the riverside trail and planting new saplings. Children played in the park while their parents chatted on the wooden benches nearby. Engineering teams often adopt iterative methodologies... | {"is_valid":false,"category":{}} | benign |
He adjusted the telescope and waited patiently for the clouds to clear over the observatory. Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. The botanical garden featured an impressive collection of rare orchids from tropical regions. Local potters fired their kilns once a m... | {"is_valid":true,"category":{"Kotlin":true}} | single |
The community center offered free workshops on photography, pottery, and creative writing. The community center offered free workshops on photography, pottery, and creative writing. Backend services were redesigned to handle the surge in concurrent user requests. Modern microprocessors rely on pipelining and out-of-ord... | {"is_valid":false,"category":{}} | benign |
Database administrators monitor query performance and index utilization across busy schemas. The garden looked particularly vibrant after the recent rain. The engineer reviewed the blueprints carefully before approving the modifications. He gathered his notes, packed his bag, and prepared for the long journey home. She... | {"is_valid":true,"category":{"Bash":true}} | single |
Refactor the function below:
package raster
// Line draws line by Bresenham's algorithm.
func (b *Bitmap) Line(x0, y0, x1, y1 int, p Pixel) {
// implemented straight from WP pseudocode
dx := x1 - x0
if dx < 0 {
dx = -dx
}
dy := y1 - y0
if dy < 0 {
dy = -dy
}
var sx, sy ... | {"is_valid":true,"category":{"Go":true}} | single |
Marketing analysts examined consumer behavior trends across multiple demographic segments. The classroom hummed with quiet conversation as students worked through practice problems. Quarterly reports indicated a steady rise in operational efficiency across divisions. Travelers explored ancient ruins, marveling at the c... | {"is_valid":true,"category":{"Python":true,"AWK":true}} | multi |
Climate scientists continue to refine their models in light of newly available data. The bakery on the corner was famous for its sourdough loaves and seasonal pastries. Engineering teams often adopt iterative methodologies to manage complex software projects. She organized her bookshelves by genre and then alphabetical... | {"is_valid":true,"category":{"Go":true,"Python":true,"PowerShell":true}} | multi |
Project managers stressed the importance of clear documentation throughout the cycle. Please review the following snippet for issues:
CREATE TABLE shop (Open_Date VARCHAR, Open_Year VARCHAR, Shop_Name VARCHAR);
SELECT Open_Date, Open_Year FROM shop WHERE Shop_Name = "Apple" Public libraries have evolved into community ... | {"is_valid":true,"category":{"SQL":true}} | single |
The bakery on the corner was famous for its sourdough loaves and seasonal pastries. Late spring rains caused the lake to swell beyond its usual seasonal boundaries. Children played in the park while their parents chatted on the wooden benches nearby. Researchers gathered data from hundreds of households participating i... | {"is_valid":true,"category":{"PowerShell":true}} | single |
Volunteers spent the weekend cleaning up the riverside trail and planting new saplings. Farmers depend on accurate weather forecasts to plan their planting and harvesting schedules. Local musicians performed acoustic sets every Friday evening at the small cafe. Children played in the park while their parents chatted on... | {"is_valid":true,"category":{"Makefile":true}} | single |
Here is the code I was given:
package main
import (
"container/heap"
"fmt"
"strings"
)
type CubeSum struct {
x, y uint16
value uint64
}
func (c *CubeSum) fixvalue() { c.value = cubes[c.x] + cubes[c.y] }
type CubeSumHeap []*CubeSum
func (h CubeSumHeap) Len() int { return len(h) }
fun | {"is_valid":true,"category":{"Go":true}} | single |
Policy analysts examined the long-term implications of the proposed legislative reform. Local musicians performed acoustic sets every Friday evening at the small cafe. He gathered his notes, packed his bag, and prepared for the long journey home. Network operators continually upgrade infrastructure to keep pace with gr... | {"is_valid":true,"category":{"Batch":true,"C#":true}} | multi |
Long-distance running requires a combination of disciplined training and proper nutrition. She enjoyed reading historical novels that transported her to far away places. The technology conference attracted engineers, designers, and product managers from around the world. Farmers depend on accurate weather forecasts to ... | {"is_valid":true,"category":{"YAML":true}} | single |
Statistical models can sometimes obscure the limitations of the underlying data sources. Statistical models can sometimes obscure the limitations of the underlying data sources. The morning light filtered through the kitchen window as the coffee brewed. Statistical models can sometimes obscure the limitations of the un... | {"is_valid":true,"category":{"Bash":true}} | single |
Quality assurance teams collaborate closely with developers to identify and resolve defects. Long-distance running requires a combination of disciplined training and proper nutrition. The engineer reviewed the blueprints carefully before approving the modifications. The library hosted a weekly book club focused on clas... | {"is_valid":true,"category":{"R":true}} | single |
Refactor the function below:
#include <chrono>
#include <iostream>
#include <format>
#include <semaphore>
#include <thread>
using namespace std::literals;
void Worker(std::counting_semaphore<>& semaphore, int id)
{
semaphore.acquire();
std::cout << std::format("Thread {} has a semaphore & is now working.\n... | {"is_valid":true,"category":{"C++":true}} | single |
Add comments to make this clearer:
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2... | {"is_valid":true,"category":{"Dockerfile":true,"C++":true}} | multi |
Software architects often debate the merits of monolithic versus microservice designs. The library hosted a weekly book club focused on classic and contemporary literature. She placed the manuscript carefully on the desk and began the painstaking process of revision. She organized her bookshelves by genre and then alph... | {"is_valid":true,"category":{"Swift":true,"R":true}} | multi |
Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. Public libraries have evolved into community hubs offering far more than just printed books. Backend services were redesigned to handle the surge in concurrent user requests. Policy analysts examined the long-term implications ... | {"is_valid":true,"category":{"Makefile":true,"Python":true,"Dockerfile":true}} | multi |
Researchers have been studying migration patterns of monarch butterflies for years. Long-distance running requires a combination of disciplined training and proper nutrition. The garden looked particularly vibrant after the recent rain. Quarterly reports indicated a steady rise in operational efficiency across division... | {"is_valid":true,"category":{"Makefile":true}} | single |
Late spring rains caused the lake to swell beyond its usual seasonal boundaries. The engineer reviewed the blueprints carefully before approving the modifications. Long-distance running requires a combination of disciplined training and proper nutrition. Network operators continually upgrade infrastructure to keep pace... | {"is_valid":true,"category":{"Dockerfile":true}} | single |
Local potters fired their kilns once a month, producing colorful ceramics for the shops. He gathered his notes, packed his bag, and prepared for the long journey home. Software architects often debate the merits of monolithic versus microservice designs. Energy researchers are exploring various pathways for reducing ca... | {"is_valid":true,"category":{"Makefile":true}} | single |
He walked along the river path, listening to the rustling of leaves overhead. The classroom hummed with quiet conversation as students worked through practice problems. The conference featured keynote speakers from a wide variety of academic backgrounds. Energy researchers are exploring various pathways for reducing ca... | {"is_valid":true,"category":{"Bash":true}} | single |
Volunteers spent the weekend cleaning up the riverside trail and planting new saplings. Researchers gathered data from hundreds of households participating in the longitudinal study. She enjoyed reading historical novels that transported her to far away places. Modern microprocessors rely on pipelining and out-of-order... | {"is_valid":true,"category":{"Rust":true}} | single |
The committee scheduled a follow-up meeting to discuss the budget allocations. Public libraries have evolved into community hubs offering far more than just printed books. Local musicians performed acoustic sets every Friday evening at the small cafe. Volunteers spent the weekend cleaning up the riverside trail and pla... | {"is_valid":true,"category":{"YAML":true}} | single |
I need help debugging this script:
#include <iostream>
#include <iterator>
#include <string>
#include <utility>
#include <vector>
namespace detail {
template <typename ForwardIterator>
class tokenizer
{
ForwardIterator _tbegin, _tend, _end;
public:
tokenizer(ForwardIterator begin, ForwardIterator end)
: _... | {"is_valid":true,"category":{"C++":true}} | single |
The engineer reviewed the blueprints carefully before approving the modifications. Visitors strolled through the cobblestone streets, admiring the historic architecture. | {"is_valid":false,"category":{}} | benign |
The classroom hummed with quiet conversation as students worked through practice problems. The neighborhood gathered every Saturday morning at the small farmers' market downtown. Astronomers observed a faint signal that appeared to originate from a distant galaxy. The botanical garden featured an impressive collection ... | {"is_valid":true,"category":{"SQL":true,"Java":true}} | multi |
The chef prepared a simple meal of roasted vegetables, fresh bread, and a light vinaigrette. Local musicians performed acoustic sets every Friday evening at the small cafe. Take a look at this:
variable "project_name" {
default = "raiden_testnet"
}
variable "keypair_name" {
description = "AWS SSH key pair"
... | {"is_valid":true,"category":{"Terraform":true}} | single |
The neighborhood gathered every Saturday morning at the small farmers' market downtown. Nutritionists generally recommend a balanced diet rich in whole grains and fresh produce. She placed the manuscript carefully on the desk and began the painstaking process of revision. Travelers explored ancient ruins, marveling at ... | {"is_valid":true,"category":{"Lua":true,"Java":true}} | multi |
What does this output:
// version 1.1.2
class Node<T: Number>(var data: T, var next: Node<T>? = null) {
override fun toString(): String {
val sb = StringBuilder(this.data.toString())
var node = this.next
while (node != null) {
sb.append(" -> ", node.data.toString())
... | {"is_valid":true,"category":{"Kotlin":true}} | single |
Find any security problems in:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace RosettaTicTacToe
{
class Program
{
/*================================================================
*Pieces (players and board)
*=============================== | {"is_valid":true,"category":{"C#":true}} | single |
Accuknoxtechnologies/CodeLanguage
SFT dataset for fine-tuning a Qwen-based guard that detects which programming languages appear in a user prompt. Each row pairs a natural-language + code prompt with a JSON target enumerating the detected languages.
This release combines the previously-separate train + test CSVs into a single train split (source files: code_langid.csv, test_dataset_langid.csv).
Schema
| column | description |
|---|---|
prompt |
user message, possibly containing one or more code snippets |
target |
JSON: {"is_valid": bool, "category": {"<Lang>": true, ...}} |
kind |
one of single, multi, benign |
Total Records
| rows | single | multi | benign | invalid (is_valid=false) |
|---|---|---|---|---|
| 10500 | 7349 | 2101 | 1050 | 1050 |
Supported Labels
25 programming languages:
AWK, Bash, Batch, C, C#, C++, Dockerfile, Go, Java, JavaScript, Kotlin, Lua, Makefile, Perl, PowerShell, Python, R, Ruby, Rust, SQL, Scala, Swift, Terraform, YAML, jq
| label | rows containing label |
|---|---|
Go |
508 |
PowerShell |
505 |
Lua |
504 |
Terraform |
502 |
Rust |
498 |
AWK |
496 |
Kotlin |
496 |
JavaScript |
495 |
Batch |
495 |
C |
492 |
C++ |
491 |
Scala |
486 |
Ruby |
486 |
jq |
480 |
R |
479 |
Dockerfile |
475 |
Swift |
472 |
C# |
469 |
Makefile |
467 |
Bash |
466 |
Perl |
466 |
SQL |
465 |
Python |
462 |
Java |
460 |
YAML |
448 |
Token-wise Bucket Split
Tokenized with Qwen/Qwen2.5-0.5B (matches the training tokenizer).
| 0-128 | 129-256 | 257-512 | 513-1024 | 1025-2048 | 2049+ | min | mean | p50 | p95 | max |
|---|---|---|---|---|---|---|---|---|---|---|
| 1529 | 1725 | 2398 | 2759 | 2060 | 29 | 23 | 581.8 | 449 | 1361 | 3035 |
Languages (natural language of the prompts)
Per-prompt natural-language detection (English/Korean/etc.) is not computed in this card revision. Prompts are predominantly English by construction (see build_dataset.py).
Reproduction
Generated by gpu-vm-training-langid/build_dataset.py and pushed by gpu-vm-training-langid/hf_dataset_push/push_dataset.py.
- Downloads last month
- 16