Skip to content

armgit / jan

Public Imported from GitHub
0

Jan is an open source alternative to ChatGPT that runs 100% offline on your computer.

842 B
Raw Blame
/**
 * Default Hardware Service - Generic implementation with minimal returns
 */

import type { HardwareData, SystemUsage, DeviceList, HardwareService } from './types'

export class DefaultHardwareService implements HardwareService {
  async getHardwareInfo(): Promise<HardwareData | null> {
    return null
  }

  async getSystemUsage(): Promise<SystemUsage | null> {
    return null
  }

  async getLlamacppDevices(): Promise<DeviceList[]> {
    return []
  }

  async reconcileLlamacppDevices(): Promise<'unchanged' | 'restarted' | 'busy'> {
    return 'unchanged'
  }

  async setActiveGpus(data: { gpus: number[] }): Promise<void> {
    console.log('setActiveGpus called with data:', data)
    // No-op - not implemented in default service
  }

  async refreshHardwareInfo(): Promise<void> {
    // No-op outside Tauri (e.g. web)
  }
}