---
title: "Companion"
sidebar_label: "Companion"
description: "Kotlin binding reference: Companion."
---

<!-- Generated by tools/api_reference/generate_api_docs.py. Do not edit. -->

//[clika-runtime](../../../../index.md)/[io.clika.runtime](../../index.md)/[Processor](../index.md)/[Companion](index.md)

# Companion

[common]\
object [Companion](index.md)

## Functions

| Name | Summary |
|---|---|
| [fromDirectory](fromDirectory.md) | [common]<br>fun [fromDirectory](fromDirectory.md)(path: [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html), where: [Placement](../../Placement/index.md)? = null): [Processor](../index.md)<br>Load from a model directory, detecting the format present. |
| [fromHuggingface](fromHuggingface.md) | [common]<br>fun [fromHuggingface](fromHuggingface.md)(path: [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html), where: [Placement](../../Placement/index.md)? = null, consumedKeys: [List](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html)&lt;[String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html)&gt; = emptyList()): [Processor](../index.md)<br>Load a Hugging Face model directory: the tokenizer (any artifact) and the media processor its `preprocessor_config.json` describes. [where](fromHuggingface.md) binds the media processor's default placement; [consumedKeys](fromHuggingface.md) extends the image configuration's recognized keys as on [ImageProcessor.fromHuggingface](../../ImageProcessor/Companion/fromHuggingface.md). |