Bendizama iiLLM zalapha ngaphakathi kweSalesforce kwaye ndingathanda ukukuxelela malunga necandelo endiliphuhliseyo ngenxa yoko. Inonxibelelwano oluqhelekileyo lwengxoxo esebenzisa iirekhodi zeSalesforce zomxholo. Isebenza ekuhlaleni kwikhompyuter yakho, ngoko ke idatha ehlaziyiweyo ayithunyelwa kuyo nayiphi na inkonzo yomntu wesithathu.
Ukuqaliswa kwe-Agentforce yeyona nto yandiphembelela ukuba ndiphuhlise icandelo. I-Agentforce isebenzisa ii-arhente - iinkqubo ezinokwenza izigqibo kwaye zenze izenzo ezahlukeneyo. Abancedisi, ngokuchaseneyo, bacwangcisa kuphela ulwazi ngokusebenzayo. Nangona ndikholelwa ukuba kuyenzeka ukwakha iarhente yendawo usebenzisa iPico LLM, kuya kuthatha umzamo omkhulu. Ngaloo ndlela, ndagqiba ekubeni ndivelise umncedisi endaweni yoko.
Iimbonakalo
Njengoko unokulindela ukuba iLLM isebenze, ivelisa iimpendulo kuso nasiphi na isihloko, njengoko iqeqeshelwe kwangaphambili kwiseti enkulu yedatha. Ngaphezu koko, iyakwazi ukusebenzisa iirekhodi zeSalesforce zomongo owongezelelweyo. Iimpawu zecandelo zezi:
- Ixhasa iimodeli ezininzi. Nayiphi na imodeli evulelekileyo evela kwiwebhusayithi yePico, efana neGemma, Llama, okanye Phi, ingasetyenziswa. Ukuphela komda apha sisixa se-RAM enayo ikhompuyutha yakho. Okukhona imodeli inobunzima kokukhona isitya i-RAM.
- Isebenza ngerekhodi enye. Xa icandelo libekwe kwiphepha lerekhodi, ngoko liyakwazi ukufikelela kwirekhodi lomxholo. Ngokomzekelo, ukuba kwiphepha leenkcukacha ze-Akhawunti, inokuvelisa impendulo ngokusekelwe kumaxabiso ayo entsimi.
- Ixhasa iirekhodi ezinxulumeneyo. Xa irekhodi ineerekhodi ezinxulumeneyo, icandelo linokubuza kwaye lidibanise kwiimpendulo.
- Iyalungiseka. Icandelo lingaqwalaselwa kubhabho, usebenzisa i-popup yoqwalaselo. Ivumela ukutshintsha iinketho zesizukulwana, ezifana nomda wokugqiba uphawu, ubushushu, kunye neP ephezulu.
Ingaba isebenza kanjani
Ukusuka kumbono womsebenzisi wokugqibela, inkqubo ithe ngqo. Ulayisha imodeli, khetha i-prompt yenkqubo, khetha iirekhodi, bhala ukukhawuleza komsebenzisi, kwaye ujonge umphumo owenziweyo.
Yintoni iPico LLM?
Ukuqhuba ii-LLMs kwi-browser ngumsebenzi odla izixhobo ngenxa yobukhulu bemodeli, iimfuno ze-bandwidth kunye neemfuno ze-RAM. Ke ngoko, iqela lePico liphuhlise ubuchule babo be-picoLLM Compression, eyenza ukuba ukusetyenziswa kwe-LLMs ekuhlaleni kusebenze ngakumbi kwiikhompyuter. Banike i-picoLLM Inference Engine, njenge-JavaScript SDK, ukuvumela abaphuhlisi bangaphambili ukuba baqhube ii-LLMs ekuhlaleni kuzo zonke iziphequluli. Ixhasa zonke iibrowser zanamhlanje ezibandakanya iChrome, iSafari, iEdge, iFirefox, kunye neOpera. Ukwazi ngakumbi malunga nendlela i-picoLLM Inference Engine esebenza ngayo, unokufunda inqaku labo .
Inxalenye yeLWC
Icandelo lisebenza njengebhulorho phakathi komsebenzisi kunye nojongano lwePicoLLM. Embindini wecandelo liphepha leVisualforce elifakwe njenge-iframe. Iphepha lilayisha i-PicoLLM SDK kwaye inxibelelana ne-LWC ivumela abokugqibela ukuba basebenzise i-SDK ngemiyalezo yeposi. Indibaniselwano yonke yezinto iphatha oku kulandelayo:
- Ilayisha imodeli. I-LWC ineqhosha elikuvumela ukuba ulayishe imodeli oyikhethileyo. Iqalisa into yongeniso lwefayile efihlwe ngaphakathi kwe iframe. Nje ukuba imodeli ilayishiwe, i-Pico SDK idala abasebenzi bewebhu, kwaye icandelo lilungele ukucubungula igalelo lomsebenzisi.
- Ukuseta inkqubo yokwazisa. Akunyanzelekanga ukuba ubhale ukukhawuleza kwenkqubo ngalo lonke ixesha, kulula ukukhetha nayiphi na irekhodi egciniweyo ye
System_Prompt__c
into. Nje ukuba iqhosha licinezelwe, libonisa i-popup enezikhokelo zenkqubo ekhoyo ongakhetha kuyo. - Ukwamkela igalelo lomsebenzisi. Kukho indawo yokubhaliweyo enokuphinda ilingane yokuqokelela igalelo lomsebenzisi. Xa iqokelelwa, ithunyelwa kwi-iframe njengomthwalo ohlawulwayo kwaye yongezwe kwimbali yencoko.
- Ukufikelela kwiirekhodi zeSalesforce. Kukho amaqhosha amabini: Khetha Imimandla kwaye Khetha iiRekhodi eziNxulumeneyo. Eyokuqala iqokelela amaxabiso entsimi erekhodi kwiphepha lerekhodi apho i-LWC ihlala khona. Okwesibini kukuvumela ukuba ukhethe into ehambelanayo kwaye ubuze iirekhodi zayo kunye namaxabiso akhethiweyo entsimi. Olu lwazi luthunyelwa kwi-iframe njengomthwalo womvuzo ngokunjalo.
- Ukutshintsha ukhetho lwesizukulwana. Ukuba uyanqweneleka, umda wethokheni yokugqiba, ubushushu, kunye neenketho eziphezulu zeP zinokutshintshwa ngeqhosha elinikezelweyo kwicandelo. Olu lwazi lukwathunyelwa njengomthwalo wokuhlawula kwi-iframe.
- Ukuvelisa isiphumo. Xa iframe ifumana umvuzo, isebenzisa iPico SDK ukusebenzisa imodeli elayishiweyo kwaye ivelise isiphumo. Ukuba ukhetho lwesizukulwana lubonelelwe, luthathelwa ingqalelo. Kwakhona, incoko yababini ihlaziywa ngalo lonke ixesha, ngoko ke iLLM iya kukhumbula imbali yayo.
- Ukunikezelwa kwemiyalezo yencoko. I-LWC iyakwazi ukunikezela ngemiyalezo ephumayo, leyo ngumsebenzisi oyinikiweyo. Imiyalezo engenayo, equlethe impendulo eveliswayo, inikezelwa ngamandla xa icandelo linento yokuthetha kumsebenzisi. Njengeziphumo ezenziweyo okanye ulwazi kunye nemiyalezo yempazamo.
Incinci ikhowudi ye-Apex
Kwicala elingasemva lezinto akukho nto inqabileyo. Ikhowudi ye-Apex yenza konke ukuphakamisa okunzima okunxulumene nokufumanisa ubudlelwane phakathi kwezinto usebenzisa i-ID yerekhodi ukusuka kwiphepha lerekhodi. Kwakhona, yenza imibuzo embalwa ye-SOQL, kwaye ngenxa yoko umsebenzi wayo wenziwa apha.
Imingeni yoPhuhliso
Abasebenzi bewebhu
Ngaphambili, bendisebenzisa isixhobo se-unpkg ukwenza ikhowudi kwimodyuli ye-node kwicandelo le-LWC. Le ndlela yakhokelela kumanyathelo oqwalaselo olongezelelweyo, kwaye yayiyindlela ekhuseleke kancinane yokwenza ukuba isebenze. Ngeli xesha, bendifuna ukwenza imodyuli ye-PicoLLM ngokuthe ngqo kwi-Salesforce kwaye kungekuphela nje kwi-Experience Cloud site, endiyenzile ngaphambili, kodwa i-interface yamava oMbane.
Ngaphantsi kwe-hood, i-PicoLLM isebenzisa abasebenzi bewebhu ukucutshungulwa okufanayo, kwaye yayiyeyona ngxaki inkulu kuba ayivumelekanga ukuba ibaqhube kwi-LWC. Ngethamsanqa, akukho mntu wenqaba ukusivumela ukuba siqhube abasebenzi bewebhu ukusuka kwiphepha le-visualforce, kwaye yayiyindlela endiyisebenzisayo.
Ndikhuphele ikhowudi ye-PicoLLM eluhlaza kwaye ndongeze njengesixhobo esingatshintshiyo kwiphepha le-visualforce. Kwi-LWC ndisebenzise iframe equlathe iphepha lokubonwayo. Unxibelelwano phakathi kwe-LWC kunye nephepha elingaphakathi kwe-iframe lindivumele ukuba ndisebenzise abasebenzi bewebhu. Eli phepha lixhokonxa ikhowudi enxulumene nePicoLLM ukusuka kumbane wewebhu.
Ukusebenzisa iirekhodi zeSalesforce zomxholo
Khuphela kwaye uncamathisele iirekhodi zeSalesforce kwifomathi ye-JSON okanye ye-CSV, uyiphose kuyo nayiphi na i-LLM ekwi-intanethi kwaye ubukele. Iya kudla iirekhodi, izisebenzise kumxholo owongezelelweyo kwaye ivelise impendulo. Kuye kwavela ukuba akukho lula xa usebenzisa iimodeli ezixinzelelweyo zokulungiswa kwendawo.
Ekuqaleni, bendibeka iirekhodi, kwifomathi ye-JSON, kanye kwi-prompt yomsebenzisi. Emva koko ndilindele ukuba into ilumke ngokwaneleyo ukwahlula i-prompt ngokwayo kumxholo owongezelelweyo endiwunikileyo. Ndisebenzise iimodeli ezahlukeneyo zobukhulu obahlukeneyo kwaye andizange ndiqonde ukuba kutheni ingasebenzisi i-JSON ukwenza iimpendulo. Ubukhulu becala ibikukwala ukuphendula ngokukhawuleza kwam okanye kwisizukulwana sedatha eyintsomi enganxulumananga nento endiyicelile ukuba iyenze. Ndaqala ukuzama iifomathi ezahlukeneyo zedatha yomxholo: usebenzisa i-CSV, usebenzisa i-JSON, usebenzisa abahluli okukhawulezayo ukwahlula ngokuthe ngqo ukuvela kumxholo - akukho nto incedileyo.
Ndiphantse ndawuyeka lo mbono kuba eyona nto iphambili ibingasebenzi. Emva kweenyanga ezimbalwa, ngequbuliso ndafumana iliza lengqondo elilula. Kuthekani ukuba ndithe ndaluhlehlisa ulandelelwano lwamacandelo akhawulezileyo? Ukusuka kukukhawuleza komsebenzisi ukuza kuqala kunye nomxholo oza okwesibini, ukuya kumxholo oza kuqala kwaye ukhawuleze okwesibini. Ndothuka ukuba iyasebenza, kwaye nayiphi na imodeli endiyisebenzisileyo yaqala ukuqonda iirekhodi zeSalesforce njengomxholo.
Ukusebenza
Ukusebenza kwecandelo kuye kwavavanywa kwaba matshini:
- I-PC ene-AMD Ryzen 9 9900X kunye ne-32GB ye-RAM (5600 MT/s).
- I-Microsoft Surface Laptop 7 inikwe amandla yi-Snapdragon X-Elite iprosesa ye-ARM ene-16 GB ye-RAM (8448 MT/s).
Imodeli yokulayisha isantya- konke malunga nememori
Elona candelo lithatha ixesha elininzi lokusebenzisa icandelo kukulayishwa kwemodeli yokuqala. Unokulindela ukuba i-9900X iphumelele ngokulula i-Snapdragon X-Elite, kodwa uya kuba ungalunganga. Okothusayo kukuba, le yokugqibela ikhawuleza. Kuba inememori ekhawulezayo, ndicinga ukuba ngokukhawuleza i-RAM yakho, imodeli ilayisha ngokukhawuleza. Nantsi imodeli yokulinganisa isantya kwitheyibhile yokulayisha kwireferensi:
Isantya sokuvelisa impendulo
Ibali elifanayo kunye nesantya sesizukulwana sokuphendula. Njengoko ndiqonda, kufuneka ube nendibaniselwano ekhawulezayo ye-CPU kunye ne-RAM ukuze ufumane esona sizukulwana sikhawulezayo sinokwenzeka. Ngenxa yokuba isizukulwana sokuphendula siyahluka ngesantya esifanayo, andizange ndiqhube iimvavanyo ezichanekileyo zesantya. Nangona kunjalo, isantya sesizukulwana sikhawuleza kakhulu, phantse ngokukhawuleza njengezinye iindlela ze-intanethi.
Kuthekani ngokusebenzisa i-GPU?
Ewe, ukusebenzisa i-GPU ukuvelisa iimpendulo kuya kusebenza ngakumbi. Ngelixa kunokwenzeka ukusebenzisa i-GPU ngePicoLLM, andikavavanyi olo lungelelwaniso ngokwam. Kukho izizathu ezimbalwa zoku. Okokuqala, ndiyakholelwa ukuba isebenzisa i-WebGPU inqaku, elingenziwanga ngokungagqibekanga kwiziphequluli ezininzi (ngaphandle kwe-Edge). Okwesibini, ifuna iigigabytes ezininzi zeVRAM ukulayisha imodeli endingenayo.
Ukuqukumbela
Ukuphuhlisa lo mncedisi kube luhambo olunomdla lokuhlola. Ukusuka ekulweni nemida yabasebenzi bewebhu ukuya ekufumaneni indima ebalulekileyo yocwangco olukhawulezileyo ekuboneleleni ngomxholo, imingeni ibisoloko ivuselela kwaye inomvuzo. Isiphumo yiNgxelo yeWebhu yoMbane enika indlela ekhethekileyo yokuxhasa amandla eeModeli zoLwimi olukhulu ngaphakathi kweSalesforce ecosystem.
Ngelixa ixesha lokuqala lokulayisha imodeli linokuthi liqwalaselwe, ngakumbi kwiimodeli ezinkulu, ukukwazi ukucubungula idatha yendawo kunika iinzuzo ezibalulekileyo ngokubhekiselele kukhuseleko lwedatha, ukuphendula, kunye neendleko ezifanelekileyo. Iimeko zokusetyenziswa ezinokubakho, ukusuka kwisizukulwana somxholo ozenzekelayo ukuya ekuboneleleni ngoncedo olukrelekrele, zikhulu kwaye zilindele ukuphononongwa.
Jonga i -GitHub repo .