```python
import bpy, math
from mathutils import Vector
from math import sin, cos, pi

# ------------------------------------------------------------
# Reset
# ------------------------------------------------------------
bpy.ops.object.select_all(action='SELECT')
bpy.ops.object.delete(use_global=False)
for datablocks in (bpy.data.meshes, bpy.data.curves, bpy.data.materials, bpy.data.cameras, bpy.data.lights):
    pass

# ------------------------------------------------------------
# Materials
# ------------------------------------------------------------
def mat_principled(name, base, rough=0.5, metallic=0.0, noise=False, bump=0.0):
    m = bpy.data.materials.new(name)
    m.diffuse_color = (*base, 1)
    m.use_nodes = True
    nt = m.node_tree
    bs = nt.nodes.get("Principled BSDF")
    bs.inputs["Base Color"].default_value = (*base, 1)
    bs.inputs["Roughness"].default_value = rough
    bs.inputs["Metallic"].default_value = metallic
    if noise:
        tex = nt.nodes.new("ShaderNodeTexNoise")
        tex.inputs["Scale"].default_value = 35
        tex.inputs["Detail"].default_value = 5
        tex.inputs["Roughness"].default_value = .75
        ramp = nt.nodes.new("ShaderNodeValToRGB")
        ramp.color_ramp.elements[0].color = (base[0]*.35, base[1]*.35, base[2]*.35, 1)
        ramp.color_ramp.elements[1].color = (min(base[0]*1.25,1), min(base[1]*1.25,1), min(base[2]*1.25,1), 1)
        nt.links.new(tex.outputs["Fac"], ramp.inputs["Fac"])
        nt.links.new(ramp.outputs["Color"], bs.inputs["Base Color"])
        if bump:
            b = nt.nodes.new("ShaderNodeBump")
            b.inputs["Strength"].default_value = bump
            b.inputs["Distance"].default_value = .045
            nt.links.new(tex.outputs["Fac"], b.inputs["Height"])
            nt.links.new(b.outputs["Normal"], bs.inputs["Normal"])
    return m

leather = mat_principled("aged full grain leather", (.16,.045,.022), .68, noise=True, bump=.24)
leather_dark = mat_principled("burnished dark leather", (.075,.018,.009), .74, noise=True, bump=.18)
leather_edge = mat_principled("abraded lighter leather", (.34,.12,.045), .76, noise=True, bump=.16)
solemat = mat_principled("blackened rubber sole", (.035,.028,.022), .84, noise=True, bump=.12)
weltmat = mat_principled("muddy welt stitching", (.20,.105,.045), .82, noise=True, bump=.07)
lace_mat = mat_principled("aged round cotton lace", (.42,.30,.18), .9, noise=True, bump=.08)
metal = mat_principled("worn brass eyelets", (.28,.20,.09), .3, metallic=.78, noise=True, bump=.05)
metalbright = mat_principled("polished eyelet rims", (.62,.42,.16), .22, metallic=.9)
mud = mat_principled("dried mud", (.095,.045,.018), .95, noise=True, bump=.2)
salt = mat_principled("faint salt tide", (.38,.25,.14), .88, noise=True, bump=.04)
fraymat = mat_principled("frayed fibers", (.25,.16,.09), .95)

# ------------------------------------------------------------
# Helpers
# ------------------------------------------------------------
def apply_mat(o, m):
    o.data.materials.append(m)

def bevel(o, amount=.08, seg=3):
    mod=o.modifiers.new("soft worn edges","BEVEL")
    mod.width=amount; mod.segments=seg
    mod.limit_method='ANGLE'
    bpy.context.view_layer.objects.active=o
    bpy.ops.object.modifier_apply(modifier=mod.name)

def cube(name, loc, scale, mat, bevel_amt=.05, rot=(0,0,0)):
    bpy.ops.mesh.primitive_cube_add(location=loc, rotation=rot)
    o=bpy.context.object; o.name=name
    o.scale=scale
    bpy.ops.object.transform_apply(location=False, rotation=False, scale=True)
    if bevel_amt: bevel(o, bevel_amt, 4)
    apply_mat(o,mat)
    return o

def uv(name, loc, scale, mat, seg=40, rings=24):
    bpy.ops.mesh.primitive_uv_sphere_add(segments=seg, ring_count=rings, location=loc)
    o=bpy.context.object; o.name=name; o.scale=scale
    bpy.ops.object.transform_apply(location=False, rotation=False, scale=True)
    apply_mat(o,mat)
    return o

def cyl_between(name, a, b, radius, mat, vertices=12):
    a,b=Vector(a),Vector(b); d=b-a
    mid=(a+b)/2
    bpy.ops.mesh.primitive_cylinder_add(vertices=vertices, radius=radius, depth=d.length, location=mid)
    o=bpy.context.object; o.name=name
    o.rotation_mode='QUATERNION'; o.rotation_quaternion=d.to_track_quat('Z','Y')
    apply_mat(o,mat)
    return o

def curve_poly(name, pts, bevel_depth, mat, cyclic=False, resolution=2):
    cu=bpy.data.curves.new(name,'CURVE'); cu.dimensions='3D'; cu.resolution_u=resolution
    cu.bevel_depth=bevel_depth; cu.bevel_resolution=3
    sp=cu.splines.new('BEZIER'); sp.bezier_points.add(len(pts)-1)
    for p,co in zip(sp.bezier_points,pts):
        p.co=co; p.handle_left_type='AUTO'; p.handle_right_type='AUTO'
    sp.use_cyclic_u=cyclic
    ob=bpy.data.objects.new(name,cu); bpy.context.collection.objects.link(ob); apply_mat(ob,mat)
    return ob

# ------------------------------------------------------------
# Boot body: uneven, collapsed, handmade silhouette
# ------------------------------------------------------------
# heel block and layered sole
cube("raised heel block",(-.92,0,.31),(.48,.69,.30),solemat,.12)
cube("thick rubber outsole",(-.02,0,.22),(1.48,.76,.22),solemat,.14)
cube("midsole welt",(-.02,0,.50),(1.43,.73,.13),weltmat,.09)

# toe and vamp, asymmetrically slumped
uv("rounded reinforced toe",(.62,-.015,1.02),(1.18,.77,.69),leather,48,28)
uv("darkened toe cap",(.86,-.01,1.12),(.78,.765,.57),leather_dark,40,24)
cube("collapsed vamp",(-.12,-.005,1.18),(.86,.70,.62),leather,.20,rot=(0,.02,-.025))

# rear quarter and ankle shaft
cube("rear quarter",(-.67,.01,1.22),(.57,.67,.72),leather,.16,rot=(0,-.035,.035))
cube("ankle shaft",(-.76,.015,1.82),(.47,.61,.77),leather,.13,rot=(0,-.10,.035))
# slightly open padded collar
cube("padded outer collar",(-.76,-.01,2.53),(.51,.68,.15),leather_dark,.12,rot=(0,-.08,.035))
# dark opening
cube("ankle opening",-0 if False else (-.76,0,2.55),(.31,.45,.045),leather_dark,.08,rot=(0,-.08,.035))

# tongue rises behind laces
cube("tongue",(-.18,-.005,1.85),(.42,.37,.88),leather_dark,.10,rot=(0,-.16,0))
# tongue top highlight
cube("tongue worn face",(-.12,-.01,2.22),(.30,.375,.38),leather,.08,rot=(0,-.16,0))

# leather side overlays / seam panels
curve_poly("quarter seam",[(-.96,-.715,.72),(-.70,-.72,1.10),(-.46,-.72,1.78),(-.42,-.63,2.34)],.018,leather_edge)
curve_poly("vamp seam",[(-.44,-.73,.70),(-.16,-.74,1.27),(.35,-.75,1.50),(.94,-.60,1.33)],.018,leather_dark)

# flex creases across vamp/toe, visibly irregular
for i,x in enumerate([-.05,.10,.23,.36,.49]):
    y=-.745 - .015*sin(i)
    z=1.54 + .04*sin(i*1.7)
    pts=[(x-.13,y,z+.10),(x-.04,y-.018,z-.03),(x+.11,y,z+.06),(x+.20,y-.01,z-.07)]
    curve_poly("deep flex crease %02d"%i,pts,.026 if i<3 else .018,leather_dark)
    # matching subtle highlight next to each crease
    curve_poly("crease abrasion %02d"%i,[(p[0]+.025,p[1]-.012,p[2]+.025) for p in pts],.012,leather_edge)

# scuffed toe abrasion patches
for i in range(7):
    ang=-.95+i*.28
    x=.75+.28*cos(ang); y=-.73+.12*sin(ang); z=1.15+.13*sin(ang*2)
    uv("toe scuff", (x,y,z),(.11,.018,.045), leather_edge, 20,12)

# water/salt tide line above welt on side
curve_poly("faint salt tide line",[(-1.30,-.725,.72),(-.85,-.735,.74),(-.35,-.75,.69),(.18,-.76,.73),(.70,-.67,.75),(1.25,-.48,.78)],.018,salt)

# ------------------------------------------------------------
# Welt perimeter and stitch relief
# ------------------------------------------------------------
# side welt cords (visible side and far side)
for y in (-.78,.78):
    curve_poly("continuous welt cord",[(-1.38,y,.57),(-1.05,y,.64),(-.25,y,.65),(.55,y,.67),(1.25,y,.64),(1.47,y,.55)],.038,weltmat)
# curved toe/front welt
curve_poly("toe welt",[(-1.38,-.78,.57),(-1.08,-.79,.48),(-.30,-.79,.45),(.48,-.78,.46),(1.15,-.68,.48),(1.47,-.45,.55)],.038,weltmat)
curve_poly("toe welt far",[(x,-y,z) for x,y,z in [(-1.38,-.78,.57),(-1.08,-.79,.48),(-.30,-.79,.45),(.48,-.78,.46),(1.15,-.68,.48),(1.47,-.45,.55)]],.038,weltmat)

# small stitch bars around visible welt
for i in range(22):
    x=-1.20+i*.115
    y=-.805
    z=.62 + .025*sin(i*.55)
    cyl_between("welt stitch",(x-.035,y-.018,z),(x+.035,y-.018,z+.018),.014,lace_mat,8)
for i in range(9):
    x=1.18-.08*i; y=-.70-.018*i; z=.57+.02*i
    cyl_between("toe stitch",(x,y-.025,z),(x+.045,y-.025,z+.015),.014,lace_mat,8)

# ------------------------------------------------------------
# Tread: lugs along bottom, obvious from orbit
# ------------------------------------------------------------
for x in [-1.17,-.82,-.47,-.12,.23,.58,.93,1.25]:
    for y in [-.58,.58]:
        cube("deep tread lug",(x,y,.06),(.12,.16,.12),solemat,.035,rot=(0,0,.10 if y>0 else -.10))
for x in [-.9,-.35,.2,.72]:
    cube("center tread lug",(x,0,.045),(.17,.25,.10),solemat,.035,rot=(0,0,.15))
# mud lodged at tread and welt
for x,y in [(-1.12,-.76),(-.55,-.77),(.12,-.78),(.72,-.73),(1.12,-.62)]:
    uv("dried mud in welt",(x,y,.58),(.10,.035,.045),mud,18,10)

# ------------------------------------------------------------
# Eyelets: two rows, six each side, metal rings and dark holes
# ------------------------------------------------------------
rowx=[-.48,-.27,-.06,.15,.36,.57]
for side in (-1,1):
    y=side*.70
    for j,x in enumerate(rowx):
        z=1.56 + j*.105
        # torus axis along Y
        bpy.ops.mesh.primitive_torus_add(major_segments=20,minor_segments=8, location=(x,y,z),
                                         major_radius=.085,minor_radius=.026, rotation=(pi/2,0,0))
        ring=bpy.context.object; ring.name="worn metal eyelet"
        apply_mat(ring,metal)
        # bright rim on facing side
        bpy.ops.mesh.primitive_torus_add(major_segments=20,minor_segments=6, location=(x,y+side*.012,z),
                                         major_radius=.061,minor_radius=.012, rotation=(pi/2,0,0))
        apply_mat(bpy.context.object,metalbright)

# lace criss-cross, round and slightly sagging
for j,x in enumerate(rowx[:-1]):
    z1=1.57+j*.105; z2=1.675+j*.105
    # crossing from each side to opposite
    curve_poly("crossed round lace",[(x,-.735,z1),(x+.105,0,z1+.025),(x+.21,.735,z2)],.032,lace_mat)
    curve_poly("crossed round lace",[(x,.735,z1),(x+.105,0,z1+.035),(x+.21,-.735,z2)],.032,lace_mat)

# loose top two rows drooping toward visible side, one missing aglet
curve_poly("loose lace left",[(.36,-.735,1.99),(.48,-.48,1.92),(.63,-.30,1.72),(.67,-.42,1.52)],.034,lace_mat)
curve_poly("loose lace right",[(.57,.735,2.10),(.72,.40,2.02),(.86,.18,1.86),(.92,-.08,1.73)],.034,lace_mat)
# frayed fibers at one tip
for k in range(5):
    curve_poly("frayed lace fiber",[(.67,-.42,1.52),(.69+sin(k)*.05,-.42+cos(k)*.055,1.43-.04*k)],.008,fraymat)

# ------------------------------------------------------------
# Heel pull loop, stitched ends
# ------------------------------------------------------------
curve_poly("stitched heel pull loop",[(-1.00,-.02,2.38),(-1.08,-.02,2.82),(-.76,-.02,2.98),(-.53,-.02,2.57)],.055,leather_dark)
for x in [-1.01,-.94,-.87,-.80,-.73,-.66,-.59]:
    cyl_between("pull loop stitch",(x,-.075,2.48),(x+.025,-.075,2.52),.012,lace_mat,8)

# ------------------------------------------------------------
# Ground studio sweep
# ------------------------------------------------------------
ground=mat_principled("warm neutral studio",(.18,.17,.15),.72)
cube("studio floor",(0,0,-.20),(8,8,.18),ground,.05)
# curved-looking rear wall via large vertical plane
cube("studio background",(0,3.8,3.6),(7,.15,4.0),ground,.12)

# ------------------------------------------------------------
# Camera and lighting
# ------------------------------------------------------------
bpy.ops.object.camera_add(location=(4.7,-6.4,3.15))
cam=bpy.context.object; cam.name="Hero camera"
bpy.context.scene.camera=cam
def track(obj, target):
    obj.rotation_euler=(Vector(target)-obj.location).to_track_quat('-Z','Y').to_euler()
track(cam,(0.05,0,1.35))
cam.data.lens=57

# large soft key from front-left/top, fill, rim
def area(name, loc, energy, size, color):
    bpy.ops.object.light_add(type='AREA', location=loc)
    o=bpy.context.object; o.name=name; o.data.energy=energy; o.data.shape='DISK'; o.data.size=size; o.data.color=color
    track(o,(0,0,1.25)); return o
area("large raking softbox",(3.2,-4.5,5.8),1050,4.0,(1.0,.78,.58))
area("shadow side fill",(-3.8,-3.0,2.8),650,4.5,(.55,.68,1.0))
area("warm rim light",(-1.8,2.8,4.5),1200,3.0,(1.0,.42,.20))

# world and render
world=bpy.context.scene.world
world.use_nodes=True
world.node_tree.nodes["Background"].inputs["Color"].default_value=(.025,.022,.02,1)
world.node_tree.nodes["Background"].inputs["Strength"].default_value=.28

scene=bpy.context.scene
scene.render.engine='BLENDER_EEVEE_NEXT'
scene.render.resolution_x=1536; scene.render.resolution_y=1536; scene.render.resolution_percentage=100
scene.render.image_settings.file_format='PNG'
scene.render.film_transparent=False
scene.view_settings.look='AgX - Medium High Contrast'
scene.render.filepath="/tmp/worn_work_boot.png"

# modest contact shadow and metadata
scene["description"]="Single asymmetrical, well-worn leather work boot with welt stitches, six-pair metal eyelets, crossed loose lace, pull loop, scuffed toe, salt tide, mud and deep tread."
bpy.ops.wm.save_as_mainfile(filepath="/tmp/worn_work_boot.blend")
```