| 3 | import workerpool from "workerpool"; |
| 4 | |
| 5 | export interface AsyncEncoder { |
| 6 | encode(text: string): Promise<number[]>; |
| 7 | decode(tokens: number[]): Promise<string>; |
| 8 | close(): Promise<void>; |
| 9 | } |
| 10 | |
| 11 | export class LlamaAsyncEncoder implements AsyncEncoder { |
| 12 | private workerPool: workerpool.Pool; |
no outgoing calls
no test coverage detected