Copyright | (c) 2025 Tushar Adhatrao |
---|---|
License | MIT |
Maintainer | Tushar Adhatrao <[email protected]> |
Safe Haskell | None |
Language | Haskell2010 |
Llama.Context
Description
Synopsis
- supportsRpc :: IO Bool
- supportsGpuOffload :: IO Bool
- supportsMLock :: IO Bool
- supportsMMap :: IO Bool
- getMaxDevices :: IO Int
- getTimeUs :: IO Int
- getContextSize :: Context -> IO Int
- getBatchSize :: Context -> IO Int
- getUnbatchedSize :: Context -> IO Int
- getMaxSeqCount :: Context -> IO Int
- getPoolingType :: Context -> IO (Maybe LlamaPoolingType)
- detachThreadPool :: Context -> IO ()
- defaultContextParams :: IO LlamaContextParams
Documentation
supportsRpc :: IO Bool Source #
Check if the backend supports remote procedure calls (RPC).
supportsGpuOffload :: IO Bool Source #
Check if the backend supports GPU offloading.
supportsMLock :: IO Bool Source #
Check if the backend supports locking model memory into RAM (no swapping).
supportsMMap :: IO Bool Source #
Check if the backend supports memory mapping models.
getMaxDevices :: IO Int Source #
Get maximum number of devices supported by the backend (e.g., GPUs).
getContextSize :: Context -> IO Int Source #
Get the maximum context size (n_ctx) of the model in the given context.
getPoolingType :: Context -> IO (Maybe LlamaPoolingType) Source #
Get the pooling type used by the context.
detachThreadPool :: Context -> IO () Source #
Detach the internal threadpool from the context.
defaultContextParams :: IO LlamaContextParams Source #
Allocate and initialize a new LlamaContextParams
with defaults.