Add job type inference from payload structure when type field is missing
Some checks failed
Coverage Phase 1 (70% Target) / test-coverage-70 (push) Has been cancelled
Coverage Phase 2 (85% Target) / test-coverage-85 (push) Has been cancelled
Cross-Node Transaction Testing / transaction-test (push) Has been cancelled
Deploy to Testnet / deploy-testnet (push) Has been cancelled
Integration Tests / test-service-integration (push) Has been cancelled
Multi-Node Stress Testing / stress-test (push) Has been cancelled
Python Tests / test-python (push) Has been cancelled
Security Scanning / security-scan (push) Has been cancelled

This commit is contained in:
aitbc
2026-05-27 12:40:25 +02:00
parent 8f3e2dd7ac
commit 0a028a530c

View File

@@ -273,7 +273,12 @@ def execute_job(job, available_models):
logger.info(f"Executing job {job_id}: {payload}")
try:
if payload.get('type') == 'inference':
# Infer job type from payload if not explicitly set
job_type = payload.get('type')
if job_type is None and 'model' in payload and 'prompt' in payload:
job_type = 'inference'
if job_type == 'inference':
# Get the prompt and model
prompt = payload.get('prompt', '')
model = payload.get('model', 'llama3.2:latest')