Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/LMCache/LMCache
/ functions
Functions
13,371 in github.com/LMCache/LMCache
⨍
Functions
13,371
◇
Types & classes
2,044
↳
Endpoints
181
↓ 42 callers
Method
fileno
(self)
lmcache/v1/distributed/l2_adapters/dax_l2_adapter.py:80
↓ 42 callers
Method
get_object_state
Get the internal state of the object with the given key. Args: key: The object key. Returns: The L1ObjectSta
lmcache/v1/distributed/l1_manager.py:857
↓ 42 callers
Method
replace
Swap the registry content in place with ``new_nodes``.
lmcache/lmcache_frontend/app.py:60
↓ 41 callers
Function
_make_key
(i: int)
tests/v1/storage_backend/test_pd_backend_async.py:52
↓ 41 callers
Method
contains
Check if key exists in storage.
tests/v1/storage_backend/test_storage_plugin.py:71
↓ 41 callers
Method
ref_count_up
Increase ref count for the given MemoryObj by one.
lmcache/v1/memory_management.py:301
↓ 41 callers
Function
wait_for_event_fd
Wait for an event fd to be signaled. Returns True if signaled within timeout, False otherwise.
tests/v1/distributed/test_nixl_store_l2_adapter.py:116
↓ 40 callers
Method
IntHash2Bytes
(chunk_hash: int)
lmcache/v1/distributed/api.py:111
↓ 40 callers
Method
get_shapes
Get the shapes of the KV cache in LMCache
lmcache/v1/metadata.py:84
↓ 40 callers
Function
ptr
--- helpers ---
operator/api/v1alpha1/lmcacheengine_test.go:25
↓ 40 callers
Method
put
(self, key: str, data: bytes)
tests/v1/distributed/test_s3_l2_adapter.py:67
↓ 40 callers
Method
reserve_write
(self, **kw: Any)
tests/cli/commands/trace/test_dispatch.py:38
↓ 39 callers
Function
recover_engine_states
(engine)
tests/v1/utils.py:158
↓ 39 callers
Function
wait_for_event_fd
Wait for an event fd to be signaled.
tests/v1/distributed/test_nixl_store_dynamic_l2_adapter.py:109
↓ 38 callers
Function
create_object_key
Create a test ObjectKey with the given chunk ID.
tests/v1/distributed/test_mock_l2_adapter.py:57
↓ 38 callers
Method
set
(self, index: int)
tests/v1/storage_backend/raw_block_test_utils.py:205
↓ 38 callers
Method
skip
skip stamps the given skip reason on the pod (without injecting), marshals it, and returns an Allowed patch response. The pod is still admitted (fail-
operator/internal/webhook/pod_injector.go:264
↓ 38 callers
Method
wait
Wait for the future to be done. Args: timeout (Optional[float]): Maximum time to wait in seconds. If Non
lmcache/v1/multiprocess/futures.py:26
↓ 37 callers
Function
assertArg
=========================== Test helpers ===========================
operator/internal/resources/resources_test.go:1068
↓ 37 callers
Method
close
(self)
lmcache/v1/storage_backend/remote_backend.py:614
↓ 37 callers
Function
create_object_key
Create a test ObjectKey with the given chunk ID.
tests/v1/distributed/test_nixl_store_l2_adapter.py:74
↓ 37 callers
Method
report_status
Return a status dict describing L1 cache state.
lmcache/v1/distributed/l1_manager.py:829
↓ 37 callers
Method
synchronize
Block the host until this event completes. No-op in the stub implementation.
lmcache/v1/platform/cpu/stub_cpu_device.py:71
↓ 36 callers
Method
GetOrCreate
Get or create the singleton instance. Args: config: Required for first-time initialization. Optional for subseque
lmcache/v1/pin_monitor.py:63
↓ 36 callers
Function
_make_cache_key
Create a CacheEngineKey for testing.
tests/v1/storage_backend/test_maru_backend.py:110
↓ 36 callers
Function
create_memory_obj
Create a test TensorMemoryObj with the given size.
tests/v1/distributed/test_mock_l2_adapter.py:66
↓ 36 callers
Function
create_memory_obj
Create a TensorMemoryObj that references page(s) in the registered buffer. Args: buffer: The flat uint8 buffer registered with NIXL.
tests/v1/distributed/test_nixl_store_l2_adapter.py:83
↓ 36 callers
Function
wait_for_event_fd
Wait for an event fd to be signaled. Returns True if signaled within timeout, False otherwise.
tests/v1/distributed/test_mock_l2_adapter.py:81
↓ 35 callers
Method
clear
( self, tokens: Optional[Union[torch.Tensor, List[int]]] = None, locations: Optional[L
lmcache/v1/cache_engine.py:1553
↓ 35 callers
Method
get_blocking
Blocking get for a single key.
tests/v1/storage_backend/test_storage_plugin.py:93
↓ 35 callers
Method
get_dtypes
Return per-group dtypes, or the legacy single dtype if the manager has not been registered yet (e.g. some unit tests).
lmcache/v1/metadata.py:76
↓ 35 callers
Method
submit_put_task
Submit a put task to store KV cache to GDS asynchronously. :param on_complete_callback: Optional callback invoked after the GDS
lmcache/v1/storage_backend/gds_backend.py:558
↓ 34 callers
Function
CreateConnector
Create a remote connector from the given URL. Supported URL formats: - redis://[[username]:[password]@]host[:port][/database][?option=va
lmcache/v1/storage_backend/connector/__init__.py:358
↓ 34 callers
Function
_make_event
(event_type: EventType, keys: list)
tests/v1/mp_observability/subscribers/metrics/test_l1_lifecycle.py:40
↓ 34 callers
Function
close_asyncio_loop
(async_loop, async_thread)
tests/v1/utils.py:211
↓ 34 callers
Method
exists
Check if key exists.
tests/v1/storage_backend/test_remote_storage_plugin.py:43
↓ 34 callers
Function
fetch
()
lmcache/v1/distributed/l2_adapters/s3_l2_adapter.py:253
↓ 34 callers
Function
init_asyncio_loop
()
tests/v1/utils.py:204
↓ 34 callers
Method
on_keys_created
Notify the eviction policy that new keys have been created. New keys are added as most recently used. Args: keys
lmcache/v1/distributed/eviction_policy/lru.py:72
↓ 34 callers
Method
start
Start the background prefetch loop thread.
lmcache/v1/distributed/storage_controllers/prefetch_controller.py:526
↓ 34 callers
Method
stop
Signal the loop to stop and wait for the thread to join. Cleans up any in-flight requests (releases L1 write locks, L2 locks
lmcache/v1/distributed/storage_controllers/prefetch_controller.py:531
↓ 34 callers
Function
wait_for_event_fd
(event_fd: int, timeout: float = 5.0)
tests/v1/distributed/test_native_connector_l2_adapter.py:185
↓ 34 callers
Method
write
Write from a GPU buffer into the file. Args: src: Device pointer (``ctypes.c_void_p``) to write from. size: Number of
lmcache/v1/storage_backend/hipfile_shim.py:140
↓ 33 callers
Method
batched_allocate
Allocate blocks of memory from the virtual address space of a given size and batch size. The actual allocated size could be larger th
lmcache/v1/memory_management.py:1406
↓ 33 callers
Method
get_hashes
(self, start: int, end: int)
lmcache/v1/multiprocess/session.py:50
↓ 33 callers
Function
get_response_class
Get the expected response class for a request type. Args: req_type: The request type to look up Returns: Expected respo
lmcache/v1/multiprocess/protocol.py:51
↓ 33 callers
Method
read
Read from the file into a GPU buffer. Args: dest: Device pointer (``ctypes.c_void_p``) to read into. size: Number of
lmcache/v1/storage_backend/hipfile_shim.py:114
↓ 33 callers
Method
stream
Return a context manager that sets the active stream. Args: stream: The stream to activate. If None, uses the cur
lmcache/v1/platform/cpu/stub_cpu_device.py:262
↓ 33 callers
Method
submit
Submit *fn* for execution on the worker determined by *affinity_key*. Returns a :class:`concurrent.futures.Future`.
lmcache/v1/multiprocess/affinity_pool.py:82
↓ 32 callers
Method
allocate
( self, shapes: Union[torch.Size, list[torch.Size]], dtypes: Union[torch.dtype, list[t
lmcache/v1/memory_management.py:2316
↓ 32 callers
Method
close
(self)
lmcache/v1/memory_management.py:2359
↓ 32 callers
Method
finish_write
(self, **kw: Any)
tests/cli/commands/trace/test_dispatch.py:42
↓ 32 callers
Method
get_ref_count
Get ref count for the given MemoryObj.
lmcache/v1/memory_management.py:322
↓ 32 callers
Method
log_message
Add a log line to the display. Thread-safe.
lmcache/cli/commands/bench/engine_bench/progress.py:83
↓ 32 callers
Method
notify
(self)
lmcache/v1/distributed/l2_adapters/dax_l2_adapter.py:82
↓ 32 callers
Method
store
(self, *args, **kwargs)
tests/v1/test_v1_adapter_state_desync.py:59
↓ 32 callers
Method
submit_prefetch_request
Submit a prefetch request for the given keys. Thread-safe. Can be called from any thread. The retained subset of found keys
lmcache/v1/distributed/storage_controllers/prefetch_controller.py:326
↓ 32 callers
Function
validate_and_set_config_value
Validate and set configuration value. Args: config: Configuration object to update. config_key: The configuration key to set.
lmcache/v1/config_base.py:645
↓ 31 callers
Function
create_object_key
(chunk_id: int, model_name: str = "test_model")
tests/v1/distributed/test_native_connector_l2_adapter.py:163
↓ 31 callers
Method
is_available
(self)
tests/v1/distributed/test_devdax_l1_allocator.py:84
↓ 31 callers
Method
step
(self, time_offset: float)
tests/cli/commands/bench/engine_bench/workloads/test_base_workload.py:33
↓ 30 callers
Function
_make_workload
( config: PrefixSuffixTunerConfig | None = None, seed: int = 42, )
tests/cli/commands/bench/engine_bench/workloads/test_prefix_suffix_tuner.py:236
↓ 30 callers
Function
_totals_by_salt
Return ``{cache_salt: (sum, count)}`` for histogram *name*.
tests/v1/mp_observability/subscribers/metrics/test_sm_lifecycle.py:73
↓ 30 callers
Method
add
(self, key: int)
lmcache/v1/storage_backend/nixl_storage_backend.py:370
↓ 30 callers
Method
discard
(self, key: int)
lmcache/v1/storage_backend/nixl_storage_backend.py:373
↓ 30 callers
Function
make_adapter
Create a MockL2Adapter with fast bandwidth.
tests/v1/distributed/test_prefetch_controller.py:144
↓ 30 callers
Method
register_listener
Register a listener for L1Manager events. Args: listener: The listener to register.
lmcache/v1/distributed/l1_manager.py:228
↓ 30 callers
Method
unsafe_read
Unsafe read the read-locked objects without adding new read locks. This method does not acquire read locks. Therefore, the caller need
lmcache/v1/distributed/l1_manager.py:296
↓ 29 callers
Method
finish_read_prefetched
Finish reading prefetched objects. Args: keys: Object keys that have been read. extra_count: Extra read locks to rele
lmcache/v1/distributed/storage_manager.py:369
↓ 29 callers
Function
get_zmq_socket
Create a ZeroMQ socket with the specified protocol and role.
lmcache/v1/rpc_utils.py:30
↓ 29 callers
Method
raise_for_status
(self)
tests/lmcache_frontend/test_heartbeat.py:25
↓ 29 callers
Method
reserve_write
Reserve the object for writing into the storage manager. Args: keys (list[ObjectKey]): List of object keys to reserve fo
lmcache/v1/distributed/storage_manager.py:167
↓ 29 callers
Method
start
Start the background store loop thread.
lmcache/v1/distributed/storage_controllers/store_controller.py:303
↓ 29 callers
Method
write
(self, *_, **__)
tests/v1/storage_backend/test_gds_backend.py:422
↓ 28 callers
Method
Bytes2IntHash
(chunk_hash: bytes)
lmcache/v1/distributed/api.py:116
↓ 28 callers
Method
Stream
(self)
tests/v1/test_musa_connector.py:112
↓ 28 callers
Function
_create_config
( *, chunk_size: int = 16, local_cpu: bool = True, max_local_cpu_size: float = 0.1, extra_
tests/v1/storage_backend/test_dax_backend.py:72
↓ 28 callers
Function
_create_metadata
( chunk_size: int = 16, world_size: int = 1, role: str = "worker", )
tests/v1/storage_backend/test_dax_backend.py:36
↓ 28 callers
Function
_make_allocation_event
( records: list[FakeBlockAllocationRecord], instance_id: int = 0, model_name: str = "test-model",
tests/v1/mp_observability/subscribers/metrics/test_l0_lifecycle.py:45
↓ 28 callers
Method
close
(self)
tests/v1/storage_backend/test_local_cpu_backend.py:678
↓ 28 callers
Function
create_memory_obj
Create a TensorMemoryObj that references page(s) in the registered buffer.
tests/v1/distributed/test_nixl_store_dynamic_l2_adapter.py:83
↓ 28 callers
Function
discover_subclasses
Yield concrete subclasses of *base_class* found by walking the submodules of *package*. Each subclass is yielded **at most once**, even when
lmcache/v1/utils/subclass_discovery.py:72
↓ 28 callers
Method
free
(self, obj)
tests/v1/test_memory_management.py:510
↓ 28 callers
Method
get_logs
(self)
tests/v1/storage_backend/test_audit_connector.py:137
↓ 28 callers
Function
make_object_key
Create a test ObjectKey with the given chunk ID.
tests/v1/distributed/test_prefetch_controller.py:57
↓ 28 callers
Method
open
Open the file and register the hipfile handle.
lmcache/v1/storage_backend/hipfile_shim.py:86
↓ 28 callers
Method
submit_request
Submit a request to the server. Args: request_type (RequestType): The type of the request. request_payloads (list[Any
lmcache/v1/multiprocess/mq.py:355
↓ 28 callers
Method
update_on_put
( self, key: KeyType, )
lmcache/v1/storage_backend/cache_policy/lfu.py:56
↓ 27 callers
Method
_async_allocate_and_put
Allocate remote memory slots and register KV objects. Uses reservation-based admission: on the first batch for a request, reserves to
lmcache/v1/storage_backend/pd_backend_async.py:1282
↓ 27 callers
Function
_make_alloc_req
( keys, last_chunk_toks=16, req_id="", is_last_batch=False, shape=None, total_chunks=0
tests/v1/storage_backend/test_pd_backend_async.py:107
↓ 27 callers
Method
allocate
(self, *args, **kwargs)
lmcache/v1/storage_backend/connector/__init__.py:87
↓ 27 callers
Function
create_l2_adapter_from_registry
Create an L2 adapter using the factory registry. Looks up the type name for *config* via the config registry, then calls the matching factory
lmcache/v1/distributed/l2_adapters/factory.py:165
↓ 27 callers
Function
dumb_metadata
(kv_shape=(32, 2, 256, 8, 128))
tests/v1/utils.py:166
↓ 27 callers
Method
from_file
Load the config from a JSON file.
lmcache/v1/storage_backend/connector/mooncakestore_connector.py:285
↓ 27 callers
Method
is_available
Check whether the device backend is available. Returns: False always, since this is a CPU-only stub.
lmcache/v1/platform/cpu/stub_cpu_device.py:214
↓ 27 callers
Function
make_descriptor
Create an AdapterDescriptor for testing.
tests/v1/distributed/test_prefetch_controller.py:150
↓ 27 callers
Function
make_layout
Create a small MemoryLayoutDesc for testing.
tests/v1/distributed/test_prefetch_controller.py:66
↓ 27 callers
Method
resolve
Return the registry-owned ``(host, port)`` matching the input. The returned tuple is taken from the registry itself, not from the cal
lmcache/lmcache_frontend/app.py:72
↓ 27 callers
Method
start
(self)
tests/v1/test_vllm_mp_adapter.py:71
↓ 27 callers
Function
store_keys_in_l2
Store test data directly in L2 adapter and wait for completion.
tests/v1/distributed/test_prefetch_controller.py:156
← previous
next →
101–200 of 13,371, ranked by callers