Skip to main content

Module classify

Module classify 

Source
Expand description

Classifier APIs: TypeSafe’s System One protocol, the same protocol on Cloudflare Workers AI, and classification with a llama.cpp chat model.

Ports of system-one-shared.ts, typesafe-system-one.ts, cloudflare-workers-ai-system-one.ts and llama-cpp-classify.ts in packages/ai/src/api in pi v1.0.0.

Structs§

ClassifyOptions
Options of one classification.

Functions§

classify
Classifies context with model. Reports failures in the result, as pi’s classify() does.
error_result
pi’s classifierErrorResult: model’s result for a classification that failed with message, aborted when cancel fired.
llama_server_root
pi’s llamaServerRoot: the base URL without /v1.