2023ǯ2·î¤ËMeta¤¬È¯É½¤·¤¿Â絬ÌϸÀ¸ì¥â¥Ç¥ë¡ÖLLaMA¡×¤Ï¡¢½¾Íè¤ÎGPT-3¤è¤ê¤â¾®µ¬ÌϤǤ¢¤ê¤Ê¤¬¤éGPT-3¤ËɤŨ¤¹¤ëÀ­Ç½¤òñÂÎGPU¤Î´Ä¶­¤Ç¤â¼¨¤¹¤³¤È¤¬²Äǽ¤È¤µ¤ì¤Æ¤ª¤ê¡¢2023ǯ3·î¤Ë¤Ï¥¨¥ó¥¸¥Ë¥¢¤Î¥¸¥ç¡¼¥¸¡¦¥²¥ë¥¬¥Î¥Õ»á¤¬M1¤Ê¤É¤ÎApple ¥·¥ê¥³¥óÅëºÜMac¤ÇLLaMA¤òÆ°ºî¤µ¤»¤ë¡Öllama.cpp¡×¤ò¸ø³«¤·¤Þ¤·¤¿¡£¤½¤ó¤ÊÃæ¡¢¥×¥í¥°¥é¥Þ¡¼¤Î¥¸¥ã¥¹¥Æ¥£¥ó¡¦¥¿¥Ë¡¼»á¤¬llama.cpp¤¬Æ°ºî¤¹¤ëºÝ¤Î¥á¥â¥ê»ÈÍÑÎ̤ò¸º¤é¤¹¥¢¥Ã¥×¥Ç¡¼¥È¤ò¹Ô¤¤¡¢LLaMA¤Î°ìÉô¥â¥Ç¥ë¤Ë»ê¤Ã¤Æ¤Ï6GB̤Ëþ¤ÎRAM¤ÇÆ°ºî¤¹¤ë¤³¤È¤¬Êó¹ð¤µ¤ì¤Æ¤¤¤Þ¤¹¡£

Make loading weights 10-100x faster by jart · Pull Request #613 · ggerganov/llama.cpp · GitHub

https://github.com/ggerganov/llama.cpp/pull/613



30B model now needs only 5.8GB of RAM? How? · ggerganov/llama.cpp · Discussion #638 · GitHub

https://github.com/ggerganov/llama.cpp/discussions/638



LLaMA¤ÏMeta¤ÎAI¸¦µæÁÈ¿¥¤Ç¤¢¤ëMeta AI Research¤¬È¯É½¤·¤¿Â絬ÌϸÀ¸ì¥â¥Ç¥ë¤Ç¤¹¡£Â絬ÌϸÀ¸ì¥â¥Ç¥ë¤Îµ¬ÌϤò¼¨¤¹¥Ñ¥é¥á¡¼¥¿¡¼¿ô¤Ï70²¯¤«¤é650²¯¤Ç¡¢LLaMA¤Î13B(¥Ñ¥é¥á¡¼¥¿¡¼¿ô¤¬130²¯)¥â¥Ç¥ë¤Î¥Ù¥ó¥Á¥Þ¡¼¥¯¥Æ¥¹¥È¤Î·ë²Ì¤Ï¡¢¥Ñ¥é¥á¡¼¥¿¡¼¿ô1750²¯¤ÎGPT-3¤ËɤŨ¤·¤¿¤ÈÊó¹ð¤µ¤ì¤Æ¤¤¤Þ¤¹¡£

¤Þ¤¿¡¢LLaMA¤ÏñÂÎGPU¤Ç¤âÌäÂê¤Ê¤¯Æ°ºî¤¹¤ë¤³¤È¤«¤é¡¢¥³¥ó¥·¥å¡¼¥Þ¡¼¥ì¥Ù¥ë¤Î¥Ï¡¼¥É¥¦¥§¥¢´Ä¶­¤Ç¤âChatGPT¤Î¤è¤¦¤ÊÂÐÏ÷¿AI¤òÆ°¤«¤»¤ë²ÄǽÀ­¤â¼¨º¶¤µ¤ì¤Æ¤¤¤Þ¤·¤¿¡£

Meta¤¬Â絬ÌϸÀ¸ì¥â¥Ç¥ë¡ÖLLaMA¡×¤òȯɽ¡¢GPT-3¤ËɤŨ¤¹¤ëÀ­Ç½¤Ê¤¬¤éñÂΤÎGPU¤Ç¤âÆ°ºî²Äǽ - GIGAZINE



¤½¤Î¸å¡¢¥²¥ë¥¬¥Î¥Õ»á¤ÏLLaMA¤ò»È¤Ã¤¿¿äÏÀ¤òmacOS¡¦Linux¡¦Windows¤ÇÆ°ºî¤µ¤»¤ë¥×¥í¥¸¥§¥¯¥È¡Öllama.cpp¡×¤Î³«È¯¤ò¿Ê¤á¡¢M1ÅëºÜMacBook Pro¤ÇLLaMA¤òÆ°ºî¤µ¤»¤ë¤³¤È¤ËÀ®¸ù¤·¤¿¤ÈÊó¹ð¤·¤Þ¤·¤¿¡£¥²¥ë¥¬¥Î¥Õ»á¤Ë¤Ë¤è¤ë¤È¡¢LLaMA¤Î13B¥â¥Ç¥ë¤òM1ÅëºÜMac¤Ç¡¢ËèÉÃ10¥È¡¼¥¯¥ó¤Î½èÍý®ÅÙ¤ÇÆ°ºî²Äǽ¤È¤Î¤³¤È¡£

GPT-3¤Î¥é¥¤¥Ð¥ë¤È¤Ê¤ëMeta¤Î¡ÖLLaMA¡×¤òM1ÅëºÜMac¤Ç¼Â¹Ô²Äǽ¤Ë¡¢Â絬ÌϸÀ¸ì¥â¥Ç¥ë¤òÉáÄ̤ξÃÈñ¼Ô¸þ¤±¥Ï¡¼¥É¥¦¥§¥¢¤Ç¼Â¹Ô²Äǽ¤Ç¤¢¤ë¤³¤È¤¬¼¨¤µ¤ì¤ë - GIGAZINE



¤½¤ó¤ÊÃæ¡¢2023ǯ3·î31Æü¤Ë¥¿¥Ë¡¼»á¤Ïllama.cpp¤ÎC++¥½¡¼¥¹¥³¡¼¥É¤Ë¥¢¥Ã¥×¥Ç¡¼¥È¤ò²Ã¤¨¤¿¤³¤È¤òÊó¹ð¤·¤Þ¤·¤¿¡£¥¿¥Ë¡¼»á¤Ë¤è¤ë¥¢¥Ã¥×¥Ç¡¼¥È¤Î·ë²Ì¡¢LLaMA¤Î¼Â¹Ô¤ÎºÝ¤Î¥á¥â¥ê»ÈÍÑÎ̤¬ÂçÉý¤Ë¸º¾¯¤·¡¢½¾Íè¤Ï30GBɬÍפÀ¤Ã¤¿LLaMA¤Î13B¥â¥Ç¥ë¤Î¥á¥â¥ê»ÈÍÑÎ̤¬¡¢¥·¥¹¥Æ¥à¥á¥â¥ê¤Î»ÈÍÑÎ̤ò´Þ¤á¤Æ¤ï¤º¤«5.8GB¤ÇÌäÂê¤Ê¤¯Æ°ºî¤·¤Æ¤¤¤ë¤³¤È¤¬Êó¹ð¤µ¤ì¤Æ¤¤¤Þ¤¹¡£





Êó¹ð¼Ô¤Îpugzly»á¤Ï¡ÖºÇ½é¤Ï¥Ð¥°¤«¤È»×¤¤¤Þ¤·¤¿¤¬¡¢¥ì¥¹¥Ý¥ó¥¹¤ÎÉʼÁÄã²¼¤Ï´¶¤¸¤é¤ì¤Þ¤»¤ó¡£ÀèÆüllama.cpp¤ËÂ礭¤ÊÊѹ¹¤¬¤¢¤Ã¤¿¤è¤¦¤Ç¤¹¤¬¡¢¤½¤ÎÊѹ¹¤Îº¬ËÜŪ¤ÊÉôʬ¤Ï»ä¤Ë¤ÏÍý²ò¤Ç¤­¤Þ¤»¤ó¡×¤È¶Ã¤­¤ò±£¤»¤Ê¤¤Íͻҡ£

¥¿¥Ë¡¼»á¤Ë¤è¤ë¤È¡¢mmap¤ò»È¤Ã¤¿½Å¤ß¤ÎÆɤ߹þ¤ß¤òllama.cpp¤Ë¼ÂÁõ¤·¤¿¤³¤È¤Ç¡¢¼ÂºÝ¤Î¿äÏÀ¤ËɬÍפÊÉôʬ¤Î½Å¤ß¤À¤±¤¬¥æ¡¼¥¶¡¼¤Î¥á¥â¥ê¤Ë¥í¡¼¥É¤µ¤ì¤ë¤è¤¦¤Ë¤Ê¤ê¡¢½¾Íè¤è¤ê¤â¾¯¤Ê¤¤¥á¥â¥ê»ÈÍÑÎ̤¬¼Â¸½¤Ç¤­¤¿¤È¤Î¤³¤È¡£

¥¿¥Ë¡¼»á¤Ï¡Ö¤³¤ÎÊѹ¹¤Ë¤è¤ê¡¢¿äÏÀ¥³¥Þ¥ó¥É¤ÎÆɤ߹þ¤ß¤¬ºÇÂç¤Ç½¾Íè¤Î100Çܹ⮤ˤʤꡢ2Çܰʾå¤Î¥â¥Ç¥ë¤ò°ÂÄꤷ¤ÆÅëºÜ¤Ç¤­¤ë²ÄǽÀ­¤¬¤¢¤ê¤Þ¤¹¡£¤µ¤é¤Ë¡¢¿äÏÀ½èÍý¤ò¿¿ôƱ»þ¿Ê¹Ô¤µ¤»¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¡×¤È¥á¥ê¥Ã¥È¤ò¶¯Ä´¤·¤Æ¤¤¤Þ¤¹¡£

°ìÊý¤Ç¥¿¥Ë¡¼»á¤Ï¡Ö»ä¤ÎÍýÏÀ¤¬´Ö°ã¤Ã¤Æ¤¤¤Æ¡¢¤³¤ì¤¬Ã±¤Ê¤ë¥Ð¥°¤Ç¤¢¤ë²ÄǽÀ­¤â¤¢¤ê¤Þ¤¹¡£»ä¤ÏLLaMA¤Î30B¥â¥Ç¥ë¤ÎÆâÉô¹½Â¤¤ò¤è¤¯Íý²ò¤·¤Æ¤¤¤Ê¤¤¤Î¤Ç¡¢¤Ê¤¼¥á¥â¥ê»ÈÍÑÎ̤¬¾¯¤Ê¤¯¤Ê¤ë¤Î¤«¤è¤¯Ê¬¤«¤Ã¤Æ¤¤¤Þ¤»¤ó¡×¤È½Ò¤Ù¤Æ¤¤¤Þ¤¹¡£



¥Ï¥Ã¥«¡¼¥Ë¥å¡¼¥¹¤Ë¤Ï¡Ö¥á¥â¥ê»ÈÍÑÎ̤θ½¾Ý¤Ë¤è¤ëÆɤ߹þ¤ß»þ´Ö¤Î¥Ñ¥Õ¥©¡¼¥Þ¥ó¥¹¸þ¾å¤Ï¡¢llama.cpp¤Î»È¤¤¤ä¤¹¤µ¤Ë¤È¤Ã¤ÆÂ礭¤Ê¿ÊÊâ¤Ç¤¹¡£¤·¤«¤·¡¢¥¿¥Ë¡¼»á¤¬¥á¥â¥ê»ÈÍÑÎ̤θº¾¯¤ËÀ®¸ù¤·¤¿Íýͳ¤òÀâÌÀ¤¹¤ë¤Î¤Ë½½Ê¬¤ÊÀâÆÀÎϤΤ¢¤ëÍýÏÀ¤Ï¤Þ¤À¤¢¤ê¤Þ¤»¤ó¡×¤È¤·¤Æ¡¢¥æ¡¼¥¶¡¼¤ËÍî¤ÁÃ夯¤³¤È¤òµá¤á¤ë½ñ¤­¹þ¤ß¤¬»Ä¤µ¤ì¤Æ¤¤¤Þ¤¹¡£