# IOllamaResource

- Module: [CommunityToolkit.Aspire.Hosting.Ollama](/reference/api/typescript/communitytoolkit.aspire.hosting.ollama.md)
- Version: `13.4.0`
- Kind: `interface`
- Source: [GitHub](https://github.com/CommunityToolkit/Aspire)

Represents an Ollama resource.

## Definition

```typescript
interface IOllamaResource {
  addHuggingFaceModel(
      name: string,
      modelName: string): OllamaModelResource;
  addModel(modelName: string): OllamaModelResource;
  addNamedModel(
      name: string,
      modelName: string): OllamaModelResource;
  withOpenWebUI(configureContainer?: (obj: OpenWebUIResource) => Promise<void>, containerName?: string): IOllamaResource;
}
```

## Methods

- [addHuggingFaceModel](/reference/api/typescript/communitytoolkit.aspire.hosting.ollama/iollamaresource/addhuggingfacemodel.md) -- `method` -- Adds a model from Hugging Face to the Ollama resource. Only models in GGUF format are supported.
    ```typescript
  addHuggingFaceModel(name: string, modelName: string): OllamaModelResource
  ```
- [addModel](/reference/api/typescript/communitytoolkit.aspire.hosting.ollama/iollamaresource/addmodel.md) -- `method` -- Adds a model to the Ollama resource.
    ```typescript
  addModel(modelName: string): OllamaModelResource
  ```
- [addNamedModel](/reference/api/typescript/communitytoolkit.aspire.hosting.ollama/iollamaresource/addnamedmodel.md) -- `method` -- Adds a model to the Ollama resource.
    ```typescript
  addNamedModel(name: string, modelName: string): OllamaModelResource
  ```
- [withOpenWebUI](/reference/api/typescript/communitytoolkit.aspire.hosting.ollama/iollamaresource/withopenwebui.md) -- `method` -- Adds an Open WebUI container to the application model for administering Ollama. This version of the package defaults to the main tag of the Open WebUI container image.
    ```typescript
  withOpenWebUI(configureContainer?: (obj: OpenWebUIResource) => Promise<void>, containerName?: string): IOllamaResource
  ```
