-
Notifications
You must be signed in to change notification settings - Fork 12.4k
Closed
Labels
enhancementNew feature or requestNew feature or request
Description
Motivation
Support for control vector is added in #5970 , but to generate the vector, users must run python code (which uses huggingface API instead of llama.cpp)
Possible Implementation
By looking at https://github.com/vgel/repeng/blob/main/repeng/extract.py , we can see some key steps that need to be adapted to cpp:
batched_get_hiddens
returns a list of embedding vectors from hidden layers. This can be done in llama.cpp using eval callback- For the moment, we can't find any lightweight implementation of Principal component analysis (PCA) in cpp. An idea would be to replace it with this UMAP C++ implementation
lin72h, martindevans, jukofyork, vrbt, kaizau and 4 moreafrideva, Yorizuka and lin72h
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request