from pathlib import Path
import json, subprocess
root=Path('/tmp/lead-28527-r1/capture/project-v3')
root.mkdir(exist_ok=True)
items=[]
for i in range(200):
    marker='qzsingle' if i==0 else 'qzfour' if i<5 else 'qznine' if i<14 else 'qzten' if i<24 else 'qzthirty' if i<54 else 'qzcommon'
    name=f'qzaudit-{i:03d}'
    if marker=='qzfour': display=name+'-long-skill-name-with-international-text-café-東京-and-deliberately-extended-label'
    desc=f'{marker} Demonstration skill {i:03d}: inspect the synthetic workspace and report a concise result.'
    if marker=='qzfour': desc+=' Résumé café 東京 — preserve non-ASCII text while checking truncation and make this description substantially longer than one hundred and sixty characters in the command menu.'
    path=root/'.agents'/'skills'/name/'SKILL.md'
    path.parent.mkdir(parents=True, exist_ok=True)
    path.write_text('---\nname: '+json.dumps(name)+'\ndescription: '+json.dumps(desc,ensure_ascii=False)+'\n---\n\nInspect the synthetic evidence fixture. Do not run a provider turn.\n')
    if marker=='qzfour':
        agents=path.parent/'agents'; agents.mkdir(exist_ok=True); (agents/'openai.yaml').write_text('interface:\n  display_name: '+json.dumps(display,ensure_ascii=False)+'\n')
    items.append(dict(name=name,description=desc,path=str(path),marker=marker))
for i in range(120):
    folder=root/'src'/('qzv28527-folder' if i%3==0 else 'nested-long-directory-name-for-path-truncation')
    folder.mkdir(parents=True,exist_ok=True)
    suffix=['.ts','.md',''][i%3]
    (folder/f'qzv28527-{i:03d}-synthetic-evidence-file{suffix}').write_text('Synthetic evidence fixture only.\n')
for i in range(12):
    (root/'src'/'nested-long-directory-name-for-path-truncation'/f'qzv28527-{i:03d}-synthetic-evidence-file.ts').write_text('Synthetic TypeScript evidence fixture.\n')
(root/'README.md').write_text('# Composer evidence fixture\n\nSynthetic skills and files for command menu captures.\n')
subprocess.run(['git','init',str(root)],check=True,capture_output=True)
subprocess.run(['git','-C',str(root),'config','user.name','Evidence Fixture'],check=True)
subprocess.run(['git','-C',str(root),'config','user.email','fixture@example.invalid'],check=True)
subprocess.run(['git','-C',str(root),'remote','add','origin','https://git.cafe/pingdotgg/t3code.git'],capture_output=True)
subprocess.run(['git','-C',str(root),'add','.'],check=True)
subprocess.run(['git','-C',str(root),'commit','-m','Synthetic evidence fixture'],capture_output=True)
Path('/tmp/lead-28527-r1/capture/seed-manifest.json').write_text(json.dumps(items,indent=2,ensure_ascii=False))
print('Seeded',len(items),'skills and 132 files:',root)
