Skip to content

Use device configuration from models.yaml instead of hardcoding to cpu #100

@rogermt

Description

@rogermt

Problem

Device preference is hardcoded to "cpu" throughout the request pipeline, ignoring the device: "cuda" setting in models.yaml.

Current Flow

  1. Server defaults to "cpu" (api.py L124)
  2. Server does NOT include device in tool_args (tasks.py L388-391)
  3. Plugin falls back to "cpu" when device not in args (plugin.py run_tool)
  4. models.yaml device: "cuda" is read by load_model_config() but never used in request path

Expected Behavior

  • Load device config from models.yaml
  • Pass device to plugin via tool_args
  • Plugin uses configured device instead of defaulting to cpu

Related Issue

  • #164 (Phase 12: plugin argument contract)

Files Affected

  • server/app/api.py - Device parameter handling
  • server/app/tasks.py - tool_args construction
  • plugins/forgesyte-yolo-tracker/configs/models.yaml - Device config
  • plugins/forgesyte-yolo-tracker/src/forgesyte_yolo_tracker/plugin.py - Device usage

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions