| build_answerer_user_prompt |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/prompts.py code served (permissive licence) · get_code("340bde46c69a75fb") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import json
from typing import Any
CATEGORY_2_DATE_INSTRUCTION = 'For time or date questions, resolve relative expressions such as yesterday, last year, this month, and next month against dates or timestamps available in the native context. Prefer an absolute date, month, or year over a relative phrase.'
ANSWERER_USER_PROMPT_TEMPLATE = '\nUse the provided native conversational memory context to answer the LoCoMo question.\nGive a concise answer. Answer with exact words from the native context whenever possible.\n{category_instruction}\n\nNative context:\n{native_context}\n\nQuestion: {question}\nShort answer:\n'.strip()
def _serialize_native_context(native_context: Any) -> str:
if isinstance(native_context, str):
return native_context
return json.dumps(native_context, ensure_ascii=False, indent=2)
def build_answerer_user_prompt(native_context: Any, question: str, *, category: int=0) -> str:
category_instruction = CATEGORY_2_DATE_INSTRUCTION if category == 2 else ''
return ANSWERER_USER_PROMPT_TEMPLATE.format(category_instruction=category_instruction, native_context=_serialize_native_context(native_context), question=question)
ARGS = {
'native_context': {
'conversation': [
{'speaker': 'Alice', 'text': 'I was born in 1990'},
{'speaker': 'Bob', 'text': 'That is interesting'}
],
'timestamp': '2024-01-15'
},
'question': 'When was Alice born?',
'category': 0
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| category_name |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/questions.py code served (permissive licence) · get_code("428bea11a75a56e8") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
def category_name(category: int) -> str:
return {1: 'multi-hop', 2: 'temporal', 3: 'open-domain', 4: 'single-hop', 5: 'adversarial'}.get(category, f'category-{category}')
ARGS = {
'category': 1
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| conversation_unit_id |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/adapter.py code served (permissive licence) · get_code("b876e5700698ca84") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
import numpy as np
# conversation_unit_id takes an int conversation_idx and returns a formatted string
# The function simply formats the index + 1 as a 4-digit zero-padded number in a string
ARGS = {
'conversation_idx': 0
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| exact_match |
Ran ran, honoured the contract we drafted |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/rigorous.py code served (permissive licence) · get_code("6aea303b6aec6c67") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned float, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import re
import string
def normalize_text(text: str) -> str:
text = text.lower()
text = text.translate(str.maketrans('', '', string.punctuation))
text = re.sub('\\b(a|an|the)\\b', ' ', text)
return re.sub('\\s+', ' ', text).strip()
def exact_match(prediction: str, ground_truth: str) -> float:
return 1.0 if normalize_text(prediction) == normalize_text(ground_truth) else 0.0
ARGS = {
"prediction": "The quick brown fox jumps over the lazy dog",
"ground_truth": "the quick brown fox jumps over a lazy dog"
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type float, ndim 0, dtype family float, shape () — shape () as a later run recorded it
- dtype family
- int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| load_dataset |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/longmemeval/dataset.py code served (permissive licence) · get_code("73cba72603aa228a") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import json
import tempfile
import os
# Create a temporary JSON file with sample dataset
temp_dir = tempfile.mkdtemp()
dataset_path = os.path.join(temp_dir, "dataset.json")
sample_data = [
{"id": 1, "text": "sample text 1", "label": "A"},
{"id": 2, "text": "sample text 2", "label": "B"},
{"id": 3, "text": "sample text 3", "label": "C"}
]
with open(dataset_path, 'w', encoding='utf-8') as f:
json.dump(sample_data, f)
ARGS = {
"path": dataset_path
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
- dtype family
- int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| normalize_category_5_prediction |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/prompts.py code served (permissive licence) · get_code("64c55dcb60229eb9") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
# The function only uses string operations, so we need simple string arguments
prediction = " (B) "
answer = "The answer to the question"
ARGS = {
"prediction": prediction,
"answer": answer
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| normalize_locomo_turn |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/dataset.py code served (permissive licence) · get_code("11bfecc717880f84") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned dict. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
import numpy as np
from typing import Any
torch.manual_seed(0)
ARGS = {
"turn": {
"speaker": "Alice",
"text": "Hello, what do you see in this image?",
"query": "object detection",
"blip_caption": "A cat sitting on a chair"
}
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| normalize_text |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/rigorous.py code served (permissive licence) · get_code("ae71bb9ba2af46bf") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import re
import string
def normalize_text(text: str) -> str:
text = text.lower()
text = text.translate(str.maketrans('', '', string.punctuation))
text = re.sub('\\b(a|an|the)\\b', ' ', text)
return re.sub('\\s+', ' ', text).strip()
ARGS = {
"text": "The Quick Brown Fox! A lazy dog, an example."
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| normalized_tokens |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/rigorous.py code served (permissive licence) · get_code("20b3d8cf23b0d87c") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import re
import string
def normalize_text(text: str) -> str:
text = text.lower()
text = text.translate(str.maketrans('', '', string.punctuation))
text = re.sub('\\b(a|an|the)\\b', ' ', text)
return re.sub('\\s+', ' ', text).strip()
def normalized_tokens(text: str) -> list[str]:
normalized = normalize_text(text)
return normalized.split() if normalized else []
ARGS = {
"text": "The quick brown fox jumps over a lazy dog!"
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
- dtype family
- int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| official_ground_truth_answer |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/prompts.py code served (permissive licence) · get_code("0174084e67c613d1") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
ARGS = {
'category': 5,
'answer': 'This is a sample answer'
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| parse_judge_response |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/judge.py code served (permissive licence) · get_code("c268d1b34b72988e") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import json
import re
def parse_judge_response(text: str) -> tuple[str, float, str]:
"""Parse JSON or text judge output into verdict, score, and reason."""
try:
payload = json.loads(text)
except json.JSONDecodeError:
payload = None
if isinstance(payload, dict):
raw_label = str(payload.get('label', '')).strip().upper()
verdict = raw_label if raw_label in {'CORRECT', 'WRONG'} else 'WRONG'
reasoning = str(payload.get('reasoning', '')).strip()
reason = reasoning if reasoning else text.strip()
score = 1.0 if verdict == 'CORRECT' else 0.0
return (verdict, score, reason)
verdict_match = re.search('VERDICT:\\s*(CORRECT|WRONG)', text, flags=re.IGNORECASE)
reason_match = re.search('REASON:\\s*(.*)', text, flags=re.IGNORECASE | re.DOTALL)
verdict = verdict_match.group(1).upper() if verdict_match else 'WRONG'
reason = reason_match.group(1).strip() if reason_match else text.strip()
score = 1.0 if verdict == 'CORRECT' else 0.0
return (verdict, score, reason)
# Test case 1: JSON input with CORRECT label
json_correct = json.dumps({"label": "CORRECT", "reasoning": "The answer is accurate."})
# Test case 2: JSON input with WRONG label
json_wrong = json.dumps({"label": "WRONG", "reasoning": "The answer is inaccurate."})
# Test case 3: Plain text with VERDICT and REASON tags
text_verdict = "VERDICT: CORRECT\nREASON: The solution is correct because it follows the algorithm."
# Test case 4: Plain text without structured format
plain_text = "This is just plain text without any structured format."
ARGS = {
"text": json_correct
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type tuple, ndim 1, dtype family float — a tuple output has no array shape of its own; none is stated
- dtype family
- int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| parse_locomo_date |
Ran ran, honoured the contract we drafted |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/dataset.py code served (permissive licence) · get_code("f902c4ca0121dbe1") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned float, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
from datetime import datetime, timezone
ARGS = {
"date_str": "03:45 PM on 15 December, 2023"
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type float, ndim 0, dtype family float, shape () — shape () as a later run recorded it
- dtype family
- int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| parse_longmemeval_date |
Ran ran, honoured the contract we drafted |
matstech/dmf-benchmarks/dmf_bench/benchmarks/longmemeval/dataset.py code served (permissive licence) · get_code("565e4cb5d95611bb") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned int, ndim 0, dtype family int, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import re
from datetime import datetime, timezone
def parse_longmemeval_date(date_str: str) -> int | None:
"""'2023/05/01 (Mon) 21:05' -> Unix epoch int (UTC)."""
try:
cleaned = re.sub('\\s*\\([A-Za-z]+\\)\\s*', ' ', date_str).strip()
dt = datetime.strptime(cleaned, '%Y/%m/%d %H:%M').replace(tzinfo=timezone.utc)
return int(dt.timestamp())
except (ValueError, TypeError):
return None
ARGS = {
'date_str': '2023/05/01 (Mon) 21:05'
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type int, ndim 0, dtype family int, shape () — shape () as a later run recorded it
- dtype family
- int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| parse_longmemeval_date_human |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/longmemeval/dataset.py code served (permissive licence) · get_code("2fb4d363847e5b3f") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import re
from datetime import datetime, timezone
ARGS = {
"date_str": "2023/05/01 (Mon) 21:05"
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| precision_at_k |
Ran ran, honoured the contract we drafted |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/ablation.py code served (permissive licence) · get_code("1c147c09654b3caa") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned float, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
import numpy as np
torch.manual_seed(0)
# Construct arguments for precision_at_k function
# The function takes:
# - retrieved_ids: list[str] - a list of retrieved item IDs
# - gold_ids: set[str] - a set of ground truth item IDs
retrieved_ids = ["item_1", "item_2", "item_3", "item_4", "item_5"]
gold_ids = {"item_2", "item_4", "item_6", "item_7"}
ARGS = {
"retrieved_ids": retrieved_ids,
"gold_ids": gold_ids
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type float, ndim 0, dtype family float, shape () — shape () as a later run recorded it
- dtype family
- int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| question_id |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/adapter.py code served (permissive licence) · get_code("002ac560607595f7") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
torch.manual_seed(0)
ARGS = {
'conversation_idx': 0,
'question_idx': 1,
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| recall_at_k |
Ran ran, honoured the contract we drafted |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/ablation.py code served (permissive licence) · get_code("20a53bb137695e55") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned float, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
# Set random seed for reproducibility
torch.manual_seed(0)
# Define ARGS dict with values for recall_at_k parameters
ARGS = {
"retrieved_ids": ["doc_1", "doc_2", "doc_3", "doc_5"],
"gold_ids": {"doc_1", "doc_2", "doc_4"}
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type float, ndim 0, dtype family float, shape () — shape () as a later run recorded it
- dtype family
- int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| reciprocal_rank |
Ran ran, honoured the contract we drafted |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/ablation.py code served (permissive licence) · get_code("939c1d4e6225165a") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned float, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
# Construct valid arguments for reciprocal_rank function
retrieved_ids = ["item_1", "item_2", "item_3", "item_4"]
gold_ids = {"item_2", "item_5"}
ARGS = {
"retrieved_ids": retrieved_ids,
"gold_ids": gold_ids,
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type float, ndim 0, dtype family float, shape () — shape () as a later run recorded it
- dtype family
- int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| serialize_locomo_turn_for_dmf |
Ran ran; our contract draft was wrong, not the code |
matstech/dmf-benchmarks/dmf_bench/benchmarks/locomo/dataset.py code served (permissive licence) · get_code("1e282bca38ed5dc9") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
from typing import Any
# Construct a minimal turn dict that will be passed to serialize_locomo_turn_for_dmf
turn = {
'text': 'This is an utterance from the speaker.',
'speaker': 'Alice',
'query': 'What is in the image?',
'blip_caption': 'A dog playing in the park.'
}
ARGS = {
'turn': turn
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|