Instructions to use dizyann/crivo-web with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers.js
How to use dizyann/crivo-web with Transformers.js:
// ⚠️ Unknown pipeline tag
Download src/decisions/model-runtime.ts from dizyann/crivo-web: direct link, hf CLI and curl.
- Browser
- Download file 511 Bytes
-
https://huggingface.co/dizyann/crivo-web/resolve/main/src/decisions/model-runtime.ts
- Command line
-
hf download hf://dizyann/crivo-web/src/decisions/model-runtime.ts
-
curl -L -o model-runtime.ts https://huggingface.co/dizyann/crivo-web/resolve/main/src/decisions/model-runtime.ts
511 Bytes
| import type { DecideInput, Decision, DecisionResults } from './types.js' | |
| /** A runtime owns the resources it allocates and releases them before settling. */ | |
| export interface DecisionRuntime { | |
| decide(input: DecideInput): Promise<DecisionResults<readonly Decision[]>> | |
| } | |
| export class InputTooLongError extends Error { | |
| constructor( | |
| readonly tokens: number, | |
| readonly limit: number, | |
| readonly decisionId = '' | |
| ) { | |
| super(`Decision needs ${tokens} tokens, exceeding the limit of ${limit}.`) | |
| } | |
| } | |