| build_cat_stats |
Ran ran; our contract draft was wrong, not the code |
ai-forever/RUMBA/evaluation/metric_analytics.py code served (permissive licence) · get_code("4926ea8b47ad1a6c") 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 DataFrame. 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 pandas as pd
import numpy as np
# Create sample data for the function
# The function expects:
# - df: pd.DataFrame with columns for doc and metric
# - doc_col: column name containing documents (dicts with category info)
# - metric_col: column name containing metrics (dicts with scores)
# - judge_key: key to extract from metric dict
# Create sample documents with category information
docs = [
{'specific': {'category': 'A'}, 'other': 'data1'},
{'specific': {'category': 'A'}, 'other': 'data2'},
{'specific': {'category': 'B'}, 'other': 'data3'},
{'category': 'C', 'other': 'data4'},
{'category': 'C', 'other': 'data5'},
{'specific': {'category': 'B'}, 'other': 'data6'},
]
# Create sample metrics with scores
metrics = [
{'llm-judge-accuracy': 0.85},
{'llm-judge-accuracy': 0.90},
{'llm-judge-accuracy': 0.75},
{'llm-judge-accuracy': 0.88},
{'llm-judge-accuracy': 0.92},
{'llm-judge-accuracy': 0.80},
]
# Create DataFrame
df = pd.DataFrame({
'doc': docs,
'metric': metrics
})
ARGS = {
'df': df,
'doc_col': 'doc',
'metric_col': 'metric',
'judge_key': 'llm-judge-accuracy'
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- numpy, pandas — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type DataFrame — a DataFrame output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a DataFrame output the recorded ndim 2 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_to_pairs |
Ran ran; our contract draft was wrong, not the code |
ai-forever/RUMBA/evaluation/run_experiments_add.py code served (permissive licence) · get_code("06fe12dbaea2bee7") 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 torch
import numpy as np
torch.manual_seed(0)
# Build a minimal item structure that matches what conversation_to_pairs expects
item = {
'conversation': {
'speaker_a': 'User Assistant',
'speaker_b': 'Assistant Bot',
'messages': [
{
'speaker': 'User Assistant',
'text': 'Hello, how are you?'
},
{
'speaker': 'Assistant Bot',
'text': 'I am doing well, thank you for asking.'
},
{
'speaker': 'User Assistant',
'text': 'What is the weather?'
},
{
'speaker': 'Assistant Bot',
'text': 'It is sunny today.'
}
],
'messages_date_time': '2024-01-15 10:30:00'
},
'sample_id': 'sample_001'
}
idx = 0
ARGS = {
'item': item,
'idx': idx
}
- 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 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
|
| conversation_to_payload |
Ran ran; our contract draft was wrong, not the code |
ai-forever/RUMBA/evaluation/run_experiments_add.py code served (permissive licence) · get_code("2cc374dddd30bcf3") 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 torch
import numpy as np
torch.manual_seed(0)
# Construct a minimal item dict that matches the function's expectations
item = {
'conversation': {
'speaker_a': 'User Alice',
'speaker_b': 'Bot Assistant',
'messages_1': [
{
'speaker': 'User Alice',
'text': 'Hello, how are you?'
},
{
'speaker': 'Bot Assistant',
'text': 'I am doing well.'
},
{
'speaker': 'User Alice',
'text': 'Great!'
}
],
'messages_1_date_time': '2024-01-15 10:30:00',
'messages_2': [
{
'speaker': 'User Alice',
'text': 'What is the weather?'
},
{
'speaker': 'Bot Assistant',
'text': 'It is sunny today.'
}
],
'messages_2_date_time': '2024-01-15 10:35:00'
},
'sample_id': 'sample_001'
}
idx = 42
ARGS = {
'item': item,
'idx': idx
}
- 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 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
|
| extract_judge_feedback |
Ran ran; our contract draft was wrong, not the code |
ai-forever/RUMBA/evaluation/lighteval_ext/custom_tasks/rumba_en.py code served (permissive licence) · get_code("ea3bf2870cd5128d") 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 re
import json
def extract_judge_feedback(jsonresp):
print(jsonresp)
if isinstance(jsonresp, list):
jsonresp = jsonresp[0]
raw_response = '' if jsonresp is None else str(jsonresp)
text = raw_response.strip()
candidates = []
match = re.search('```(?:json)?\\s*(.*?)\\s*```', text, re.DOTALL)
if match:
candidates.append(match.group(1))
if text:
candidates.append(text)
start = text.find('{')
end = text.rfind('}')
if start != -1 and end != -1 and (start < end):
candidates.append(text[start:end + 1])
seen = set()
unique_candidates = []
for candidate in candidates:
candidate = candidate.strip()
if candidate and candidate not in seen:
unique_candidates.append(candidate)
seen.add(candidate)
for candidate in unique_candidates:
try:
verdict = json.loads(candidate)
label = verdict['verdict']
reasoning = verdict['reasoning']
if isinstance(label, str) and label.strip().isdigit():
label = int(label.strip())
if label in [0, 1, 2, 3]:
return (reasoning, label, raw_response, True)
except Exception:
pass
verdict_match = re.search('"verdict"\\s*:\\s*([0-3])', candidate)
if not verdict_match:
verdict_match = re.search('\\bverdict\\b\\s*[:=]\\s*([0-3])', candidate, re.IGNORECASE)
if verdict_match:
label = int(verdict_match.group(1))
reasoning_match = re.search('"reasoning"\\s*:\\s*"((?:[^"\\\\]|\\\\.)*)"', candidate, re.DOTALL)
if reasoning_match:
reasoning = reasoning_match.group(1)
try:
reasoning = json.loads(f'"{reasoning}"')
except Exception:
pass
else:
reasoning = ''
return (reasoning, label, raw_response, True)
return ('Failed to parse judge response', 0, raw_response, False)
ARGS = {
'jsonresp': '{"verdict": 1, "reasoning": "This is a test verdict"}'
}
- 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
|
| extract_timestamp |
Ran ran, honoured the contract we drafted |
ai-forever/RUMBA/evaluation/users_stats_query_qdrant.py code served (permissive licence) · get_code("fd081534bb7e149e") 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 torch
# Test case 1: payload with direct timestamp
payload_with_timestamp = {
'timestamp': 1234567890,
'data': 'some_data'
}
# Test case 2: payload with timestamp in metadata
payload_with_metadata = {
'metadata': {
'timestamp': 9876543210,
'source': 'api'
},
'data': 'other_data'
}
# Test case 3: payload with timestamp in meta
payload_with_meta = {
'meta': {
'timestamp': 5555555555,
'user_id': 123
},
'data': 'more_data'
}
# Test case 4: payload without timestamp
payload_without_timestamp = {
'data': 'no_timestamp_here',
'id': 456
}
# Test case 5: non-dict payload (should return None)
non_dict_payload = "not a dict"
# Use the first payload as the main test
ARGS = {
'payload': payload_with_timestamp
}
- 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 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
|
| extract_user_index |
Ran ran, honoured the contract we drafted |
ai-forever/RUMBA/evaluation/users_stats_query_chroma.py code served (permissive licence) · get_code("689115f86c329ff8") 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 os
import re
PREFIX = os.getenv('CHROMA_PREFIX', 'memories_user_')
def extract_user_index(name: str) -> int:
m = re.match(f'^{re.escape(PREFIX)}(\\d+)$', name)
return int(m.group(1)) if m else 10 ** 9
# Test case 1: Valid name matching the prefix pattern
test_name_valid = f'{PREFIX}42'
# Test case 2: Name that doesn't match the pattern
test_name_invalid = 'some_other_name'
# Test case 3: Valid name with different user index
test_name_valid_2 = f'{PREFIX}999'
ARGS = {
'name': test_name_valid
}
- 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
|
| get_count |
Ran ran, honoured the contract we drafted |
ai-forever/RUMBA/evaluation/users_stats_query_chroma.py code served (permissive licence) · get_code("b8589dcf97d6f447") 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 torch
import numpy as np
class MockCollection:
"""Mock collection object with count() method."""
def count(self):
return 42
def get(self, ids=None, include=None):
"""Mock get method in case count() is not available."""
return {"ids": ids or [], "documents": []}
# Create a mock collection instance
mock_coll = MockCollection()
ARGS = {
"coll": mock_coll
}
- 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 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
|
| get_latest_dir |
Ran ran; our contract draft was wrong, not the code |
ai-forever/RUMBA/evaluation/metric_analytics.py code served (permissive licence) · get_code("d4e229fbe4dfa7ee") 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 PosixPath. 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 tempfile
from pathlib import Path
# Create a temporary directory structure that the function expects
temp_dir = tempfile.mkdtemp()
output_folder = temp_dir
# Create the expected directory structure: output_folder/details/technique_type/subdirs
details_dir = Path(output_folder) / 'details'
details_dir.mkdir(exist_ok=True)
technique_type = 'my_technique'
technique_dir = details_dir / technique_type
technique_dir.mkdir(exist_ok=True)
# Create some subdirectories with sortable names
(technique_dir / '001_run').mkdir(exist_ok=True)
(technique_dir / '002_run').mkdir(exist_ok=True)
(technique_dir / '003_run').mkdir(exist_ok=True)
ARGS = {
'output_folder': output_folder,
'technique_type': technique_type,
}
- 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 PosixPath — a PosixPath output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a PosixPath 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
|
| is_valid_iso |
Ran ran; our contract draft was wrong, not the code |
ai-forever/RUMBA/evaluation/users_stats_query_qdrant.py code served (permissive licence) · get_code("1bc343e067430b22") 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 re
from datetime import datetime
ISO_PREFIX_RE = re.compile('^\\d{4}-\\d{2}-\\d{2}T')
def is_valid_iso(ts) -> tuple[bool, str | None]:
"""
(ok, reason_if_invalid)
Поддерживает 'Z' на конце.
"""
if ts is None:
return (False, 'missing')
if not isinstance(ts, str):
return (False, f'not_a_string:{type(ts).__name__}')
s = ts.strip()
if not s:
return (False, 'empty')
if not ISO_PREFIX_RE.match(s):
return (False, 'bad_prefix')
if s.endswith('Z'):
s = s[:-1] + '+00:00'
try:
datetime.fromisoformat(s)
return (True, None)
except Exception as e:
return (False, f'fromisoformat:{e.__class__.__name__}')
# Test case 1: Valid ISO string with Z
ARGS = {
'ts': '2024-01-15T10:30:45Z'
}
- 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
|
| list_collection_names |
Ran ran; our contract draft was wrong, not the code |
ai-forever/RUMBA/evaluation/users_stats_query_chroma.py code served (permissive licence) · get_code("e59cdd555ce8d27e") 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 torch
import numpy as np
class MockCollection:
def __init__(self, name):
self.name = name
class MockCollectionDict:
def __init__(self, name):
self._data = {'name': name}
def get(self, key):
return self._data.get(key)
class MockClient:
def list_collections(self):
return [
MockCollection('collection_1'),
MockCollectionDict('collection_2'),
MockCollection('collection_3'),
]
client = MockClient()
ARGS = {
'client': client,
}
- 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 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
|
| load_data |
Ran ran; our contract draft was wrong, not the code |
ai-forever/RUMBA/evaluation/run_experiments_add.py code served (permissive licence) · get_code("c38f105fc182acf1") 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 json
import tempfile
import os
# Create a temporary JSON file with sample data
temp_dir = tempfile.mkdtemp()
temp_file = os.path.join(temp_dir, "test_data.json")
sample_data = {
"key1": "value1",
"key2": [1, 2, 3],
"key3": {"nested": "object"}
}
with open(temp_file, 'w', encoding='utf-8') as f:
json.dump(sample_data, f)
# Define ARGS with the path parameter
ARGS = {
"path": temp_file
}
- 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 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
|
| load_details_df |
Ran ran; our contract draft was wrong, not the code |
ai-forever/RUMBA/evaluation/metric_analytics.py code served (permissive licence) · get_code("a6d9ba4fc8a34593") 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 DataFrame. 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 tempfile
from pathlib import Path
import pandas as pd
import os
# Create a temporary directory structure for testing
temp_dir = tempfile.mkdtemp()
output_folder = temp_dir
# Create the required directory structure
details_dir = Path(output_folder) / 'details' / 'test_technique'
details_dir.mkdir(parents=True, exist_ok=True)
# Create a subdirectory with a sortable name
subdir = details_dir / '001_run'
subdir.mkdir(parents=True, exist_ok=True)
# Create a sample parquet file
sample_df = pd.DataFrame({
'col1': [1, 2, 3],
'col2': ['a', 'b', 'c'],
'col3': [1.1, 2.2, 3.3]
})
parquet_file = subdir / 'data.parquet'
sample_df.to_parquet(parquet_file)
ARGS = {
'output_folder': output_folder,
'technique_type': 'test_technique'
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- pandas — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type DataFrame — a DataFrame output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a DataFrame output the recorded ndim 2 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
|
| process_judge_response |
Ran ran, honoured the contract we drafted |
ai-forever/RUMBA/evaluation/lighteval_ext/custom_tasks/rumba_ru.py code served (permissive licence) · get_code("99ca46ea75be9332") 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
def process_judge_response(response) -> int:
if isinstance(response, list):
response = response[0]
match = re.search('\\[RESULT\\]\\s*(-?\\d+)\\s*\\[END\\]', response)
label = int(match.group(1)) if match else None
if label in [0, 1]:
return 0
elif label in [2, 3]:
return 1
return 0
# Test case 1: string with valid result in range [0, 1]
response_1 = "The judge says [RESULT] 0 [END] done"
# Test case 2: list with string containing valid result in range [2, 3]
response_2 = ["The judge says [RESULT] 2 [END] done"]
# Test case 3: string with negative number
response_3 = "The judge says [RESULT] -5 [END] done"
# Test case 4: string without matching pattern
response_4 = "No result here"
ARGS = {
"response": response_1
}
- 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
|
| print_section |
Not yet run unverified (harvested, no recorded run) |
ai-forever/RUMBA/evaluation/users_stats_query_neo4j.py code served (permissive licence) · get_code("cef73a9b4b26450b") How it ran |