UNPKG

@huggingface/transformers

Version:

State-of-the-art Machine Learning for the web. Run 🤗 Transformers directly in your browser, with no need for a server!

72 lines (58 loc) • 2.48 kB
/** * @file Entry point for the Transformers.js library. Only the exports from this file * are available to the end user, and are grouped as follows: * * 1. [Environment variables](./env) * 2. [Pipelines](./pipelines) * 3. [Models](./models) * 4. [Tokenizers](./tokenizers) * 5. [Processors](./processors) * 6. [Configs](./configs) * * @module transformers */ // Environment variables export { env, LogLevel } from './env.js'; // Pipelines export * from './pipelines.js'; // Models export * from './models/models.js'; export * from './models/auto/modeling_auto.js'; // Tokenizers export * from './models/tokenizers.js'; export * from './models/auto/tokenization_auto.js'; // Feature Extractors export * from './models/feature_extractors.js'; export * from './models/auto/feature_extraction_auto.js'; // Image Processors export * from './models/image_processors.js'; export * from './models/auto/image_processing_auto.js'; // Processors export * from './models/processors.js'; export * from './models/auto/processing_auto.js'; // Configs export { PretrainedConfig, AutoConfig } from './configs.js'; // Additional exports export * from './generation/streamers.js'; export * from './generation/stopping_criteria.js'; export * from './generation/logits_process.js'; export { load_audio, read_audio, RawAudio } from './utils/audio.js'; export { load_image, RawImage } from './utils/image.js'; export { load_video, RawVideo, RawVideoFrame } from './utils/video.js'; export * from './utils/tensor.js'; export { softmax, log_softmax, dot, cos_sim } from './utils/maths.js'; export { random } from './utils/random.js'; export { DynamicCache } from './cache_utils.js'; // Cache and file management export { ModelRegistry } from './utils/model_registry/ModelRegistry.js'; // Expose common types used across the library for developers to access /** * @typedef {import('./utils/hub.js').PretrainedModelOptions} PretrainedModelOptions * @typedef {import('./processing_utils.js').PretrainedProcessorOptions} PretrainedProcessorOptions * @typedef {import('./tokenization_utils.js').Message} Message * @typedef {import('./tokenization_utils.js').PretrainedTokenizerOptions} PretrainedTokenizerOptions * @typedef {import('./utils/dtypes.js').DataType} DataType * @typedef {import('./utils/devices.js').DeviceType} DeviceType * @typedef {import('./utils/core.js').ProgressCallback} ProgressCallback * @typedef {import('./utils/core.js').ProgressInfo} ProgressInfo */