Dataset Viewer
The dataset viewer is not available for this dataset.
The JWT signature verification failed. Check the signing key and the algorithm.
Error code:   JWTInvalidSignature
Exception:    InvalidSignatureError
Message:      Signature verification failed
Traceback:    Traceback (most recent call last):
                File "/src/libs/libapi/src/libapi/jwt_token.py", line 286, in validate_jwt
                  decoded = jwt.decode(
                      jwt=token,
                  ...<2 lines>...
                      options=options,
                  )
                File "/usr/local/lib/python3.14/site-packages/jwt/api_jwt.py", line 368, in decode
                  decoded = self.decode_complete(
                      jwt,
                  ...<8 lines>...
                      leeway=leeway,
                  )
                File "/usr/local/lib/python3.14/site-packages/jwt/api_jwt.py", line 265, in decode_complete
                  decoded = self._jws.decode_complete(
                      jwt,
                  ...<3 lines>...
                      detached_payload=detached_payload,
                  )
                File "/usr/local/lib/python3.14/site-packages/jwt/api_jws.py", line 270, in decode_complete
                  self._verify_signature(
                  ~~~~~~~~~~~~~~~~~~~~~~^
                      signing_input,
                      ^^^^^^^^^^^^^^
                  ...<4 lines>...
                      options=merged_options,
                      ^^^^^^^^^^^^^^^^^^^^^^^
                  )
                  ^
                File "/usr/local/lib/python3.14/site-packages/jwt/api_jws.py", line 417, in _verify_signature
                  raise InvalidSignatureError("Signature verification failed")
              jwt.exceptions.InvalidSignatureError: Signature verification failed

Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.

YAML Metadata Warning:empty or missing yaml metadata in repo card

Check out the documentation for more information.

# InfoSeek Numeric/Time Fact Store

InfoSeek numeric/time 계열 질문에서 Wikidata claim을 이용해 복원한 fact retrieval 학습용 데이터다. 목적은 FactHead를 contrastive하게 학습하기 위한 positive fact와 hard negative fact를 제공하는 것이다.

이 데이터는 official InfoSeek evidence가 아니다. Gold QID, answer value/range, Wikidata claims, property/unit/qualifier rule을 이용해 만든 pseudo-supervision이다.

1. Layout

fact_store/
  data/facts/
    infoseek_numeric_facts_enriched.jsonl
    numeric_qid_to_fact_ids.json
    numeric_pid_to_fact_ids.json
    numeric_label_cache.json
  data/maps/
    infoseek_train_numeric_question_fact_map_enriched_v2.jsonl
    infoseek_val_numeric_question_fact_map_enriched_v2.jsonl
  data/annotations/
    infoseek_train.jsonl
    infoseek_train_withkb.jsonl
    infoseek_val.jsonl
    infoseek_val_withkb.jsonl
    infoseek_val_qtype.jsonl
  data/docs/
    match_vector_sampling_policy.md
    *_match_vector_eval.json
    *_numeric_enrichment_summary_v2.json
    statistics.md
    fact_coverage.md
    numeric_fact_enrichment.md
  samples/
    *.sample.jsonl

2. Download from Hugging Face

Replace <repo_id> with the actual dataset repo.

pip install -U huggingface_hub
huggingface-cli login
huggingface-cli download <repo_id> \
  --repo-type dataset \
  --local-dir fact_store \
  --local-dir-use-symlinks False

Python version:

from huggingface_hub import snapshot_download

snapshot_download(
    repo_id="hwoos/infoseek-numeric-fact-store",
    repo_type="dataset",
    local_dir="fact_store",
    local_dir_use_symlinks=False,
)

Git LFS version:

git lfs install
git clone https://huggingface.co/datasets/hwoos/infoseek-numeric-fact-store fact_store

infoseek_train_numeric_question_fact_map_enriched_v2.jsonl is large, so CLI or snapshot_download is recommended.

3. Core files

Fact database

data/facts/infoseek_numeric_facts_enriched.jsonl

Each line is one fact item. Important fields are:

fact_id
subject_qid / subject_label
property_id / property_label / property_description
amount or time
unit_qid / unit_label
qualifiers
text_for_encoder

Training code should load this file as:

fact_id -> fact item

text_for_encoder is the easiest input for a first fact encoder.

Query-to-fact maps

data/maps/infoseek_train_numeric_question_fact_map_enriched_v2.jsonl
data/maps/infoseek_val_numeric_question_fact_map_enriched_v2.jsonl

Each line is one InfoSeek QA row with recovered positive/negative facts.

Important fields:

data_id
image_id
question
answer / answer_eval
entity_id
selected_positive_fact_ids
positive_status_v2
hard_negative_fact_ids_by_type
hard_negative_meta_v2

Use rows only if:

positive_status_v2 == "selected_positive"
selected_positive_fact_ids is not empty

4. How to use for training

The intended module is a dual-encoder style FactHead.

query side:
  z_q_fact(e_i) = FactQueryHead(image, question, candidate_entity)

fact side:
  z_fact = FactItemHead(fact_text_or_fields)

training:
  pull z_q_fact close to positive fact
  push z_q_fact away from hard negative facts

For the first experiment, use oracle/gold entity from InfoSeek with-KB:

image + question + gold entity -> z_q_fact
selected_positive_fact_ids -> positives
hard_negative_meta_v2 -> negatives

For full pipeline inference:

1. EntityHead retrieves top-K entities.
2. For each candidate entity e_i:
     z_q_fact(e_i) = FactQueryHead(image, question, e_i)
     retrieve facts from facts[e_i]
3. Use retrieved facts for QA generation or entity reranking.

5. Negative sampling policy

Do not rely only on old negative type labels. Use hard_negative_meta_v2[fact_id].

Important metadata:

match_vector
match_vector_key
match_vector_label
negative_tier
use_as_negative
legacy_type

Match vector order:

entity / property / qualifier / value

Examples:

11n0 = same entity, same property, qualifier not applicable, wrong value
10n1 = same entity, different property, qualifier not applicable, same value
01n0 = different entity, same property, qualifier not applicable, wrong value

Recommended tiers:

Tier A: same entity + same property + wrong value/qualifier
Tier B: same entity + different property
Tier C: different entity + same property
Tier D: easier or mixed negatives

Do not use these as negatives:

1111
11n1

They are positive-like because entity/property/value all match.

6. Minimal dataloader sketch

import json
from pathlib import Path

root = Path("fact_store")

fact_by_id = {}
with open(root / "data/facts/infoseek_numeric_facts_enriched.jsonl", encoding="utf-8") as f:
    for line in f:
        item = json.loads(line)
        fact_by_id[item["fact_id"]] = item

def iter_training_rows(split="train"):
    path = root / "data/maps" / f"infoseek_{split}_numeric_question_fact_map_enriched_v2.jsonl"
    with open(path, encoding="utf-8") as f:
        for line in f:
            row = json.loads(line)
            pos = row.get("selected_positive_fact_ids", [])
            if row.get("positive_status_v2") != "selected_positive" or not pos:
                continue

            neg_meta = row.get("hard_negative_meta_v2", {})
            neg_ids = [
                fid for fid, meta in neg_meta.items()
                if meta.get("use_as_negative", True)
                and meta.get("match_vector_key") not in {"1111", "11n1"}
            ]
            if not neg_ids:
                continue

            yield {
                "data_id": row["data_id"],
                "image_id": row.get("image_id"),
                "entity_id": row["entity_id"],
                "question": row["question"],
                "positive_facts": [fact_by_id[fid] for fid in pos if fid in fact_by_id],
                "negative_facts": [fact_by_id[fid] for fid in neg_ids if fid in fact_by_id],
                "negative_meta": {fid: neg_meta[fid] for fid in neg_ids},
            }

A practical sampler should cap negatives per row, for example:

Tier A: up to 4
Tier B: up to 4
Tier C: up to 4
Tier D: up to 2
in-batch facts: included by contrastive batch

Treat the exact ratio as a hyperparameter.

7. Suggested batch format

query_input:
  image_id
  question
  entity_id / entity_text

positive_fact_text:
  fact_by_id[pos_id]["text_for_encoder"]

negative_fact_texts:
  fact_by_id[neg_id]["text_for_encoder"]

Example fact text:

Subject: Rhine Falls. Property: height. Property description: vertical extent of the item. Value: 23 metre.

A simple MVP fact encoder:

z_fact = normalize(MLP(TextEncoder(text_for_encoder)))

The query encoder should be entity-conditioned:

z_q_fact = FactQueryHead(image, question, candidate_entity)

8. What is not included

Image pixels are not included. The rows reference InfoSeek/OVEN image ids only. Training code must resolve image files separately.

The current fact store focuses on numeric/time-like Wikidata claims. String-valued fact recovery and text evidence retrieval are separate workstreams.

9. Sanity summary

Current generated maps have:

val:
  rows = 19,301
  usable_rows = 18,128
  hard negative meta items = 283,465
  missing_vector = 0
  positive_like_negative = 0

train:
  rows = 190,983
  usable_rows = 140,772
  hard negative meta items = 2,163,357
  missing_vector = 0
  positive_like_negative = 0

See data/docs/*match_vector_eval.json and data/docs/match_vector_sampling_policy.md for details.

10. Recommended first experiment

Experiment: oracle-entity FactHead retrieval

Input:
  image + question + gold entity

Target:
  selected_positive_fact_ids

Negatives:
  match_vector tiered hard negatives + in-batch negatives

Metric:
  Fact Recall@1 / Recall@5 / Recall@10
  optional final QA accuracy with retrieved fact text

Compare against:

random fact retrieval
BM25 over fact text
dense text-only fact retrieval
FactHead without match-vector hard negatives
FactHead with match-vector hard negatives
Downloads last month
66