release(@ml/model-boss-ts): 📦 bump version to 2.0.0
Breaking changes: - Removed GPU coordination re-exports (import from @lilith/ml-vram-boss directly) - Updated to use extracted vram-boss package as dependency Co-Authored-By: Claude Sonnet 4.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
fffa95954b
commit
e47d46c8e4
5 changed files with 25 additions and 50 deletions
33
model-boss-ts/dist/index.d.ts
vendored
33
model-boss-ts/dist/index.d.ts
vendored
|
|
@ -1,9 +1,8 @@
|
|||
/**
|
||||
* Model path resolution and GPU/VRAM lease coordinator for ML models - TypeScript client.
|
||||
* Model path resolution library for ML models - TypeScript client.
|
||||
*
|
||||
* This package provides:
|
||||
* 1. Model path resolution (finding models in local cache)
|
||||
* 2. GPU/VRAM lease coordination (re-exported from @lilith/ml-vram-boss)
|
||||
* Provides utilities for finding and resolving model files in local cache,
|
||||
* supporting both single-file models (GGUF) and sharded models (safetensors, pytorch).
|
||||
*
|
||||
* @example Path Resolution
|
||||
* ```typescript
|
||||
|
|
@ -20,37 +19,25 @@
|
|||
* }
|
||||
* ```
|
||||
*
|
||||
* @example GPU/VRAM Lease Coordination
|
||||
* @example With GPU Coordination
|
||||
* ```typescript
|
||||
* import { GPUBoss, Priority } from '@lilith/ml-model-boss';
|
||||
* // For GPU coordination, import from @lilith/ml-vram-boss directly:
|
||||
* import { GPUBoss, Priority } from '@lilith/ml-vram-boss';
|
||||
* import { ensureModelSync } from '@lilith/ml-model-boss';
|
||||
*
|
||||
* const boss = new GPUBoss();
|
||||
* await boss.connect();
|
||||
*
|
||||
* const lease = await boss.acquire({
|
||||
* vramMb: 8000,
|
||||
* priority: Priority.NORMAL,
|
||||
* modelId: 'llm',
|
||||
* });
|
||||
*
|
||||
* const lease = await boss.acquire({ vramMb: 8000, priority: Priority.NORMAL });
|
||||
* try {
|
||||
* await loadModel();
|
||||
*
|
||||
* lease.onPreempt(async (reason) => {
|
||||
* await unloadModel();
|
||||
* });
|
||||
*
|
||||
* const response = await model.chat(messages);
|
||||
* lease.touch();
|
||||
* const modelPath = ensureModelSync('my-model');
|
||||
* await loadModel(modelPath);
|
||||
* } finally {
|
||||
* await lease.release();
|
||||
* }
|
||||
*
|
||||
* await boss.close();
|
||||
* ```
|
||||
*
|
||||
* @packageDocumentation
|
||||
*/
|
||||
export { GPUBoss, GPULease, LeaseAcquisitionError, LeaseTimeoutError, Priority, type AcquireOptions, type BossConfig, type BossStatus, type GPUStatus, type LeaseInfo, type PreemptCallback, type QueueRequest, type ResolvedConfig, } from '@lilith/ml-vram-boss';
|
||||
export { ModelPathLoader, getPathLoader, resetPathLoader, ensureModel, ensureModelSync, isCached, resolveModel, tryResolveModel, type ManifestEntry, type ModelManifest, type ModelResolution, } from './path-loader.js';
|
||||
//# sourceMappingURL=index.d.ts.map
|
||||
2
model-boss-ts/dist/index.d.ts.map
vendored
2
model-boss-ts/dist/index.d.ts.map
vendored
|
|
@ -1 +1 @@
|
|||
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoDG;AAGH,OAAO,EACL,OAAO,EACP,QAAQ,EACR,qBAAqB,EACrB,iBAAiB,EACjB,QAAQ,EACR,KAAK,cAAc,EACnB,KAAK,UAAU,EACf,KAAK,UAAU,EACf,KAAK,SAAS,EACd,KAAK,SAAS,EACd,KAAK,eAAe,EACpB,KAAK,YAAY,EACjB,KAAK,cAAc,GACpB,MAAM,sBAAsB,CAAC;AAK9B,OAAO,EACL,eAAe,EACf,aAAa,EACb,eAAe,EACf,WAAW,EACX,eAAe,EACf,QAAQ,EACR,YAAY,EACZ,eAAe,EACf,KAAK,aAAa,EAClB,KAAK,aAAa,EAClB,KAAK,eAAe,GACrB,MAAM,kBAAkB,CAAC"}
|
||||
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAQH,OAAO,EACL,eAAe,EACf,aAAa,EACb,eAAe,EACf,WAAW,EACX,eAAe,EACf,QAAQ,EACR,YAAY,EACZ,eAAe,EACf,KAAK,aAAa,EAClB,KAAK,aAAa,EAClB,KAAK,eAAe,GACrB,MAAM,kBAAkB,CAAC"}
|
||||
36
model-boss-ts/dist/index.js
vendored
36
model-boss-ts/dist/index.js
vendored
|
|
@ -1,9 +1,8 @@
|
|||
/**
|
||||
* Model path resolution and GPU/VRAM lease coordinator for ML models - TypeScript client.
|
||||
* Model path resolution library for ML models - TypeScript client.
|
||||
*
|
||||
* This package provides:
|
||||
* 1. Model path resolution (finding models in local cache)
|
||||
* 2. GPU/VRAM lease coordination (re-exported from @lilith/ml-vram-boss)
|
||||
* Provides utilities for finding and resolving model files in local cache,
|
||||
* supporting both single-file models (GGUF) and sharded models (safetensors, pytorch).
|
||||
*
|
||||
* @example Path Resolution
|
||||
* ```typescript
|
||||
|
|
@ -20,39 +19,28 @@
|
|||
* }
|
||||
* ```
|
||||
*
|
||||
* @example GPU/VRAM Lease Coordination
|
||||
* @example With GPU Coordination
|
||||
* ```typescript
|
||||
* import { GPUBoss, Priority } from '@lilith/ml-model-boss';
|
||||
* // For GPU coordination, import from @lilith/ml-vram-boss directly:
|
||||
* import { GPUBoss, Priority } from '@lilith/ml-vram-boss';
|
||||
* import { ensureModelSync } from '@lilith/ml-model-boss';
|
||||
*
|
||||
* const boss = new GPUBoss();
|
||||
* await boss.connect();
|
||||
*
|
||||
* const lease = await boss.acquire({
|
||||
* vramMb: 8000,
|
||||
* priority: Priority.NORMAL,
|
||||
* modelId: 'llm',
|
||||
* });
|
||||
*
|
||||
* const lease = await boss.acquire({ vramMb: 8000, priority: Priority.NORMAL });
|
||||
* try {
|
||||
* await loadModel();
|
||||
*
|
||||
* lease.onPreempt(async (reason) => {
|
||||
* await unloadModel();
|
||||
* });
|
||||
*
|
||||
* const response = await model.chat(messages);
|
||||
* lease.touch();
|
||||
* const modelPath = ensureModelSync('my-model');
|
||||
* await loadModel(modelPath);
|
||||
* } finally {
|
||||
* await lease.release();
|
||||
* }
|
||||
*
|
||||
* await boss.close();
|
||||
* ```
|
||||
*
|
||||
* @packageDocumentation
|
||||
*/
|
||||
// Re-export GPU coordination from vram-boss for backward compatibility
|
||||
export { GPUBoss, GPULease, LeaseAcquisitionError, LeaseTimeoutError, Priority, } from '@lilith/ml-vram-boss';
|
||||
// model-boss provides path resolution only
|
||||
// For GPU coordination, import from @lilith/ml-vram-boss directly
|
||||
// Path resolution (model-boss functionality)
|
||||
// TypeScript equivalent of Python's loaders/path_loader.py
|
||||
// Supports single-file models (GGUF) and sharded models (safetensors, pytorch, diffusion)
|
||||
|
|
|
|||
2
model-boss-ts/dist/index.js.map
vendored
2
model-boss-ts/dist/index.js.map
vendored
|
|
@ -1 +1 @@
|
|||
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoDG;AAEH,uEAAuE;AACvE,OAAO,EACL,OAAO,EACP,QAAQ,EACR,qBAAqB,EACrB,iBAAiB,EACjB,QAAQ,GAST,MAAM,sBAAsB,CAAC;AAE9B,6CAA6C;AAC7C,2DAA2D;AAC3D,0FAA0F;AAC1F,OAAO,EACL,eAAe,EACf,aAAa,EACb,eAAe,EACf,WAAW,EACX,eAAe,EACf,QAAQ,EACR,YAAY,EACZ,eAAe,GAIhB,MAAM,kBAAkB,CAAC"}
|
||||
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAEH,2CAA2C;AAC3C,kEAAkE;AAElE,6CAA6C;AAC7C,2DAA2D;AAC3D,0FAA0F;AAC1F,OAAO,EACL,eAAe,EACf,aAAa,EACb,eAAe,EACf,WAAW,EACX,eAAe,EACf,QAAQ,EACR,YAAY,EACZ,eAAe,GAIhB,MAAM,kBAAkB,CAAC"}
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "@lilith/ml-model-boss",
|
||||
"version": "1.0.0",
|
||||
"version": "2.0.0",
|
||||
"description": "Model path resolution and GPU/VRAM lease coordination for ML models - TypeScript client",
|
||||
"type": "module",
|
||||
"main": "./dist/index.js",
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue