Dataset Viewer
Auto-converted to Parquet Duplicate
chunk_id
stringlengths
7
12
question_id
stringlengths
4
8
language
stringclasses
1 value
chunk_index
int64
0
42
dense_vector
listlengths
4.1k
4.1k
sparse_indices
listlengths
2
277
sparse_values
listlengths
2
277
3186420_c0
3186420
perl
0
[ -0.00244140625, -0.022216796875, 0.002349853515625, -0.01446533203125, 0.0274658203125, -0.02392578125, -0.00238037109375, 0.00775146484375, -0.00860595703125, -0.0004367828369140625, -0.0400390625, 0.0172119140625, 0.02490234375, -0.00830078125, 0.049072265625, -0.00335693359375, 0....
[ 48962, 17368, 1736, 23, 117, 141, 12298, 15649, 12 ]
[ 0.07672119140625, 0.1497802734375, 0.251708984375, 0.109130859375, 0.1729736328125, 0.188720703125, 0.1109619140625, 0.1815185546875, 0.0176849365234375 ]
55500294_c0
55500294
perl
0
[ 0.025146484375, -0.01458740234375, -0.0108642578125, -0.0185546875, 0.038818359375, -0.01409912109375, -0.01220703125, 0.0059814453125, -0.001068115234375, -0.0032806396484375, -0.0361328125, 0.0234375, 0.0194091796875, -0.018310546875, 0.04248046875, 0.011474609375, 0.0186767578125,...
[ 48962, 908, 141, 853, 23935, 55331, 28574, 53, 12298, 117, 6835, 3355, 15649, 12 ]
[ 0.08367919921875, 0.203125, 0.178955078125, 0.10296630859375, 0.1846923828125, 0.1593017578125, 0.214111328125, 0.137939453125, 0.09136962890625, 0.1656494140625, 0.1260986328125, 0.1895751953125, 0.1976318359375, 0.058990478515625 ]
9227603_c0
9227603
perl
0
[-0.01806640625,-0.0012664794921875,-0.01373291015625,-0.00811767578125,0.00360107421875,-0.04052734(...TRUNCATED)
[ 48962, 908, 141, 105233, 1061, 27853, 12298, 117, 221, 7, 15649, 12, 20, 10 ]
[0.044281005859375,0.1634521484375,0.1646728515625,0.1781005859375,0.15771484375,0.275634765625,0.07(...TRUNCATED)
51416789_c0
51416789
perl
0
[-0.0087890625,-0.0037078857421875,-0.00970458984375,-0.0322265625,0.017333984375,-0.0133056640625,0(...TRUNCATED)
[ 48962, 12, 4171, 3768, 18, 64040, 67, 92537, 64, 8859, 33209, 5, 26822, 12298, 117, 141, 15649 ]
[0.10400390625,0.025238037109375,0.1236572265625,0.06475830078125,0.1356201171875,0.218017578125,0.1(...TRUNCATED)
33612086_c0
33612086
perl
0
[-0.003143310546875,-0.039306640625,-0.00457763671875,-0.0185546875,0.00213623046875,-0.009643554687(...TRUNCATED)
[ 48962, 12, 4263, 63805, 140992, 1916, 18499, 12298, 117, 141, 15649 ]
[0.07342529296875,0.0276641845703125,0.243896484375,0.256591796875,0.190673828125,0.08740234375,0.22(...TRUNCATED)
3607957_c0
3607957
perl
0
[-0.0240478515625,-0.030517578125,-0.0029754638671875,-0.026123046875,0.01495361328125,0.00085830688(...TRUNCATED)
[ 48962, 60552, 117, 141, 9803, 936, 12298, 83279, 13, 11508, 6077, 15649 ]
[0.049896240234375,0.1864013671875,0.1500244140625,0.16552734375,0.1607666015625,0.1947021484375,0.0(...TRUNCATED)
4505474_c0
4505474
perl
0
[0.0126953125,-0.0233154296875,-0.0279541015625,0.0086669921875,0.0283203125,-0.017333984375,-0.0142(...TRUNCATED)
[ 48962, 853, 432, 6496, 56409, 38931, 7, 1295, 18151, 12298, 87109, 117, 141, 15649, 12 ]
[0.052459716796875,0.046356201171875,0.1583251953125,0.095947265625,0.202880859375,0.33349609375,0.1(...TRUNCATED)
13211397_c0
13211397
perl
0
[-0.008544921875,-0.003875732421875,-0.005157470703125,-0.00994873046875,0.005279541015625,-0.017578(...TRUNCATED)
[ 48962, 11062, 5037, 2053, 47, 10298, 53, 678, 908, 141, 12298, 117, 15649, 12 ]
[0.07440185546875,0.109130859375,0.194091796875,0.190185546875,0.0989990234375,0.2406005859375,0.198(...TRUNCATED)
24312734_c0
24312734
perl
0
[0.02685546875,-0.010498046875,-0.034423828125,0.01092529296875,0.015380859375,-0.0128173828125,-0.0(...TRUNCATED)
[ 48962, 181139, 171763, 1636, 1295, 3365, 316, 19, 12298, 10, 434, 92, 1736, 117, 141, 15649, 12 ]
[0.0628662109375,0.2154541015625,0.302001953125,0.1932373046875,0.1680908203125,0.1990966796875,0.22(...TRUNCATED)
29687781_c0
29687781
perl
0
[0.00138092041015625,-0.0142822265625,-0.0166015625,-0.0189208984375,-0.00372314453125,-0.0098266601(...TRUNCATED)
[ 48962, 60972, 11435, 1295, 7986, 23, 908, 141, 12298, 117, 15649 ]
[0.07659912109375,0.267822265625,0.22119140625,0.1480712890625,0.1929931640625,0.0504150390625,0.185(...TRUNCATED)
End of preview. Expand in Data Studio

Perl StackOverflow Vector Dataset

Summary

This repository contains the Perl shard of the Stack2Graph vector retrieval dataset. Each Hugging Face dataset repository contains one programming-language shard and is intended to restore or rebuild the Qdrant collection stackoverflow_perl_vector.

The dataset is the vector counterpart to the Stack2Graph RDF knowledge graph. It is designed for hybrid retrieval, graph entry-point finding, and retrieval-augmented generation experiments over Stack Overflow content.

Stack2Graph source: https://github.com/tha-atlas/Stack2Graph

Repository Layout

README.md
dataset_manifest.json
qdrant_snapshots/
  collections_manifest.json
  stackoverflow_perl_vector.tar.zst
  stackoverflow_perl_vector.snapshot.zst.part_000
  ...
question_metadata/
  r0_00000.parquet
chunk_records/
  r0_00000.parquet
question_records/
  r0_00000.parquet
  • dataset_manifest.json: language-scoped manifest listing the files in this shard.
  • qdrant_snapshots/collections_manifest.json: language-scoped Qdrant snapshot manifest.
  • qdrant_snapshots/stackoverflow_perl_vector.*: optional Qdrant restore artifact files for stackoverflow_perl_vector.
  • question_metadata/*.parquet: question-level metadata used by parent-child chunk retrieval.
  • chunk_records/*.parquet: chunk-level vector rows when parent-child indexing is enabled.
  • question_records/*.parquet: question-level vector rows when non-chunked export is used.

The Hugging Face upload is one repository per language. During upload, the local leading language directory is removed, so local files such as perl/chunk_records/r0_00000.parquet appear in this repository as chunk_records/r0_00000.parquet.

Data Model

Rows are derived from Stack Overflow questions tagged for Perl.

The current Stack2Graph vector pipeline uses:

  • dense vectors from Qwen/Qwen3-Embedding-8B
  • 4096-dimensional dense embeddings with last-token pooling
  • instruction-aware query embedding for retrieval
  • sparse lexical vectors from BAAI/bge-m3
  • unified question text containing title, tags, cleaned problem text, and code
  • optional parent-child indexing where chunk hits collapse back to parent question IDs

When Qdrant snapshots are included, they are the fastest restore path. The Parquet files remain the portable fallback for rebuilding the collection.

Coverage

This repository contains only the Perl shard. A Stack Overflow question can appear in more than one language shard when it has multiple programming-language tags.

The dataset is not a complete Stack Overflow mirror. Full question and answer graph context lives in the corresponding Stack2Graph knowledge graph artifacts; the vector dataset stores retrieval rows, vectors, sparse weights, and routing metadata.

Recommended Use

Use this dataset for:

  • semantic and hybrid retrieval
  • Qdrant restore or ingestion tests
  • Stack2Graph RAG experiments
  • graph entry-point retrieval before QLever graph expansion
  • vector database benchmarking and diagnostics

This dataset is not intended as a standalone supervised training dataset.

Restore With Stack2Graph

You do not need to regenerate embeddings to use this dataset.

Typical workflow:

  1. Clone Stack2Graph and configure .env with service paths and HF token.
  2. Start local services:
docker compose up -d
  1. Download and restore vector artifacts:
python -m experiment.sources.hf --skip-kg

The loader restores Qdrant snapshots when present and falls back to Parquet ingestion when snapshots are unavailable.

Manual Use

For manual use, inspect dataset_manifest.json, then either:

  • restore the Qdrant snapshot artifacts under qdrant_snapshots/, or
  • ingest the listed Parquet shards into a compatible vector database.

The target Qdrant collection name is:

stackoverflow_perl_vector

Quality Notes

  • Embedding quality depends on the configured Stack2Graph export pipeline and model versions.
  • Sparse text can be generated from the same unified text as dense embeddings or from a lexical variant, depending on export configuration.
  • Community-generated Stack Overflow content may contain errors, outdated information, bias, or incomplete answers.
  • Rebuilding from Parquet may produce operational differences if Qdrant collection settings differ from the original export.

License And Attribution

This dataset is derived from Stack Overflow content and is distributed under CC-BY-SA-4.0. Preserve required attribution and license notices when redistributing derived artifacts.

Citation

If you use this dataset, cite the Stack2Graph project and preserve Stack Overflow attribution requirements:

  • Stack2Graph: A Structured Knowledge Representation of Stack Overflow Data for Retrieval-based Question Answering
Downloads last month
69