Skip to content

ModelParams

Namespace: LLama.Common

The parameters for initializing a LLama model.

1
public class ModelParams : LLama.Abstractions.ILLamaParams, LLama.Abstractions.IModelParams, LLama.Abstractions.IContextParams, System.IEquatable`1[[LLama.Common.ModelParams, LLamaSharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]]

Inheritance ObjectModelParams
Implements ILLamaParams, IModelParams, IContextParams, IEquatable<ModelParams>

Properties

ContextSize

1
public Nullable<uint> ContextSize { get; set; }

Property Value

Nullable<UInt32>

MainGpu

1
public int MainGpu { get; set; }

Property Value

Int32

SplitMode

1
public GPUSplitMode SplitMode { get; set; }

Property Value

GPUSplitMode

GpuLayerCount

1
public int GpuLayerCount { get; set; }

Property Value

Int32

Seed

1
public uint Seed { get; set; }

Property Value

UInt32

UseMemorymap

1
public bool UseMemorymap { get; set; }

Property Value

Boolean

UseMemoryLock

1
public bool UseMemoryLock { get; set; }

Property Value

Boolean

ModelPath

1
public string ModelPath { get; set; }

Property Value

String

LoraAdapters

1
public AdapterCollection LoraAdapters { get; set; }

Property Value

AdapterCollection

LoraBase

1
public string LoraBase { get; set; }

Property Value

String

Threads

1
public Nullable<uint> Threads { get; set; }

Property Value

Nullable<UInt32>

BatchThreads

1
public Nullable<uint> BatchThreads { get; set; }

Property Value

Nullable<UInt32>

BatchSize

1
public uint BatchSize { get; set; }

Property Value

UInt32

EmbeddingMode

1
public bool EmbeddingMode { get; set; }

Property Value

Boolean

TensorSplits

1
public TensorSplitsCollection TensorSplits { get; set; }

Property Value

TensorSplitsCollection

MetadataOverrides

1
public List<MetadataOverride> MetadataOverrides { get; set; }

Property Value

List<MetadataOverride>

RopeFrequencyBase

1
public Nullable<float> RopeFrequencyBase { get; set; }

Property Value

Nullable<Single>

RopeFrequencyScale

1
public Nullable<float> RopeFrequencyScale { get; set; }

Property Value

Nullable<Single>

YarnExtrapolationFactor

1
public Nullable<float> YarnExtrapolationFactor { get; set; }

Property Value

Nullable<Single>

YarnAttentionFactor

1
public Nullable<float> YarnAttentionFactor { get; set; }

Property Value

Nullable<Single>

YarnBetaFast

1
public Nullable<float> YarnBetaFast { get; set; }

Property Value

Nullable<Single>

YarnBetaSlow

1
public Nullable<float> YarnBetaSlow { get; set; }

Property Value

Nullable<Single>

YarnOriginalContext

1
public Nullable<uint> YarnOriginalContext { get; set; }

Property Value

Nullable<UInt32>

YarnScalingType

1
public Nullable<RopeScalingType> YarnScalingType { get; set; }

Property Value

Nullable<RopeScalingType>

TypeK

1
public Nullable<GGMLType> TypeK { get; set; }

Property Value

Nullable<GGMLType>

TypeV

1
public Nullable<GGMLType> TypeV { get; set; }

Property Value

Nullable<GGMLType>

NoKqvOffload

1
public bool NoKqvOffload { get; set; }

Property Value

Boolean

DefragThreshold

1
public float DefragThreshold { get; set; }

Property Value

Single

DoPooling

1
public bool DoPooling { get; set; }

Property Value

Boolean

VocabOnly

1
public bool VocabOnly { get; set; }

Property Value

Boolean

Encoding

1
public Encoding Encoding { get; set; }

Property Value

Encoding

Constructors

ModelParams(String)

1
public ModelParams(string modelPath)

Parameters

modelPath String
The model path.

Methods

ToString()

1
public string ToString()

Returns

String

PrintMembers(StringBuilder)

1
protected bool PrintMembers(StringBuilder builder)

Parameters

builder StringBuilder

Returns

Boolean

GetHashCode()

1
public int GetHashCode()

Returns

Int32

Equals(Object)

1
public bool Equals(object obj)

Parameters

obj Object

Returns

Boolean

Equals(ModelParams)

1
public bool Equals(ModelParams other)

Parameters

other ModelParams

Returns

Boolean

<Clone>$()

1
public ModelParams <Clone>$()

Returns

ModelParams