### Class

# Foundry LlmResource

#### Description [src]

    abstract class Foundry.LlmResource : GObject.Object
    {
      /* No available fields */
    }

Abstract base class for LLM resources.

A resource represents external content that can be provided to an LLM, such as files, URLs, or other data sources. Resources have metadata including a URI, name, description, and content type.

#### Ancestors

- GObject

#### Descendants

- FoundryJsonListLlmResource
- FoundryJsonLlmResource

#### Instance methods

###### foundry_llm_resource_dup_content_type

Gets the content type for the resource.

since: 1.1

###### foundry_llm_resource_dup_description

Gets the description for the resource.

since: 1.1

###### foundry_llm_resource_dup_name

Gets the name for the resource.

since: 1.1

###### foundry_llm_resource_dup_uri

Gets the URI for the resource.

since: 1.1

###### foundry_llm_resource_emit_changed

Emits the “changed” signal.

since: 1.1

###### foundry_llm_resource_load_bytes

Loads the bytes for the resource.

since: 1.1

###### foundry_llm_resource_load_json

If the content_type is “application/json” then the resource may implement this function to provide a JsonNode instead of a serialized byte buffer. This is helpful in situations where the protocol can pass structured information for JSON such as Model Context Protocol.

since: 1.1

##### Methods inherited from GObject (43)

Please see GObject for a full list of methods.

#### Properties

###### Foundry.LlmResource:content-type

The content type of the resource.

###### Foundry.LlmResource:description

The description of the resource.

###### Foundry.LlmResource:name

The name of the resource.

###### Foundry.LlmResource:uri

The URI of the resource.

#### Signals

###### Foundry.LlmResource::changed

Emitted when the resource has changed.

since: 1.1

##### Signals inherited from GObject (1)

###### GObject::notify

The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

#### Class structure

    struct FoundryLlmResourceClass {
      GObjectClass parent_class;
      char* (* dup_uri) (
        FoundryLlmResource* self
      );
      char* (* dup_name) (
        FoundryLlmResource* self
      );
      char* (* dup_description) (
        FoundryLlmResource* self
      );
      char* (* dup_content_type) (
        FoundryLlmResource* self
      );
      DexFuture* (* load_bytes) (
        FoundryLlmResource* self
      );
      DexFuture* (* load_json) (
        FoundryLlmResource* self
      );

    }

No description available.

###### Class members

`parent_class: GObjectClass`

  No description available.

`dup_uri: char* (* dup_uri) ( FoundryLlmResource* self )`

  No description available.

`dup_name: char* (* dup_name) ( FoundryLlmResource* self )`

  No description available.

`dup_description: char* (* dup_description) ( FoundryLlmResource* self )`

  No description available.

`dup_content_type: char* (* dup_content_type) ( FoundryLlmResource* self )`

  No description available.

`load_bytes: DexFuture* (* load_bytes) ( FoundryLlmResource* self )`

  No description available.

`load_json: DexFuture* (* load_json) ( FoundryLlmResource* self )`

  No description available.

#### Virtual methods

###### Foundry.LlmResourceClass.dup_content_type

Gets the content type for the resource.

since: 1.1

###### Foundry.LlmResourceClass.dup_description

Gets the description for the resource.

since: 1.1

###### Foundry.LlmResourceClass.dup_name

Gets the name for the resource.

since: 1.1

###### Foundry.LlmResourceClass.dup_uri

Gets the URI for the resource.

since: 1.1

###### Foundry.LlmResourceClass.load_bytes

Loads the bytes for the resource.

since: 1.1

###### Foundry.LlmResourceClass.load_json

If the content_type is “application/json” then the resource may implement this function to provide a JsonNode instead of a serialized byte buffer. This is helpful in situations where the protocol can pass structured information for JSON such as Model Context Protocol.

since: 1.1