import{s as mt,n as ut,o as ft}from"../chunks/scheduler.35aab934.js";import{S as pt,i as ht,e as s,s as a,c,h as dt,a as l,d as i,b as o,f as ct,g,j as r,k as gt,l as vt,m as n,n as m,t as u,o as f,p}from"../chunks/index.de17b971.js";import{C as wt}from"../chunks/CopyLLMTxtMenu.48bc5cc2.js";import{H as d,E as $t}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.8fdece89.js";function yt(qe){let h,ee,Y,te,v,ie,w,ne,$,Fe="We hope you liked exploring the unit on ethics and bias in computer vision. As we conclude this unit, let us take a look into the efforts by Hugging Face to improve ethics in society. This chapter will encourage you to explore the world of ethics and bias in AI in general, which is constantly evolving. Hugging Face’s core mission is to <em>democratize good machine learning</em>. So what is Good ML? There are some principles for Good ML.",ae,y,oe,x,Re=`<strong>1. Collaboration:</strong> Providing tools for easier collaboration with the open-source community. Some examples of these tools are:
a. <a href="https://huggingface.co/docs/hub/model-cards" rel="nofollow"><em>Model Cards</em></a> are files that accompany the models and provide information about the model, its intended uses and potential limitations (including ethical considerations), training parameters and experimental information, datasets used for training and evaluation results. This ensures that the models uploaded to the hub are transparent and open to the community.
b. <a href="https://huggingface.co/blog/eval-on-the-hub" rel="nofollow"><em>Evaluation</em></a> lets users to evaluate any model on any dataset that is openly available on the Hub without writing a single line of code. ,
c. <a href="https://huggingface.co/blog/community-update" rel="nofollow"><em>Community discussion</em></a> is important, whether you upload a model, dataset or a space or you just want to know more about them from the authors. Everyone can give feedback, flag a given Space, and improve or contribute directly to the repository via PRs.
d. <a href="https://discord.com/invite/JfAtkvEtRb" rel="nofollow"><em>Discord</em></a> group for the 🤗 community, where a wide range of channels discuss about different domains like reinforcement-learning, NLP, game development, audio, computer vision and so on.
<strong>2. Transparency:</strong> Being transparent about the intent, sources of data, model training and performance. Efforts in this direction include:
a. <a href="https://huggingface.co/blog/ethical-charter-multimodal" rel="nofollow"><em>Ethical charter for multimodal project</em></a> discusses the values of the multimodal learning group at 🤗. This is a project-specific charter.
b. <a href="https://huggingface.co/blog/us-national-ai-research-resource" rel="nofollow"><em>Work on AI policy @</em> 🤗</a> mentions the response of Hugging Face on U.S. National AI Research Resource Interim Report.
<strong>3. Responsibility:</strong> Assessing the impacts of ML models and tools, and making them more auditable and understandable even for people with less expertise on ML. Some efforts in this directions are:
a. <a href="https://huggingface.co/blog/education" rel="nofollow">🤗 <em>for Education Project</em></a> aims at educating people from all backgrounds, beginners and instructors. Various experts and team members organize meetups, conferences and workshops.<br/>
b. <a href="https://huggingface.co/spaces/huggingface/data-measurements-tool" rel="nofollow"><em>Data Measurement Tool</em></a> is an interactive interface and open-source library that lets dataset creators and users automatically calculate metrics that are meaningful and useful for responsible data development.`,se,b,le,C,Ue="As we move forward, let us now take a look into how spaces are categorized by Hugging Face. Hugging Face categorizes the spaces in 6 high levels based on the ethical aspects in Machine Learning. Hugging Face Spaces are categorized as:",re,T,ce,L,Ge="Rigorous projects pay special attention to examining failure cases, protecting privacy through security measures, and ensuring that potential users (technical and non-technical) are informed of the project’s limitations. Some examples:",ge,M,Be="<li>Projects built with models that are well-documented with Model Cards.</li> <li>Tools that provide transparency into how a model was trained and how it behaves.</li> <li>Evaluations against cutting-edge benchmarks, with results reported against disaggregated sets.</li> <li>Demonstrations of models failing across gender, skin type, ethnicity, age or other attributes.</li> <li>Techniques for mitigating issues like over-fitting and training data memorization.</li> <li>Techniques for detoxifying language models.</li>",me,H,Oe='An example space is the <a href="https://huggingface.co/spaces/society-ethics/DiffusionBiasExplorer" rel="nofollow"><strong>Diffusion Bias Explorer</strong></a> which lets the users compare three text-to-image models SD 1.4, SD 2.0 and Dall-E 2 for different prompts and how they represent different professions and adjectives.',ue,_,fe,k,Ve="Consentful technology supports the self-determination of people who use and are affected by these technologies. Some examples:",pe,S,Ne="<li>Demonstrating a commitment to acquiring data from willing, informed, and appropriately compensated sources.</li> <li>Designing systems that respect end-user autonomy, e.g. with privacy-preserving techniques.</li> <li>Avoiding extractive, chauvinist, “dark”, and otherwise “unethical” patterns of engagement.</li>",he,P,We="Some example spaces for this category are:",de,z,Qe='<li><a href="https://huggingface.co/spaces/AIML-TUDA/does-clip-know-my-face" rel="nofollow"><strong>Does CLIP Know My Face:</strong></a> this space lets you choose a model, enter your name and upload some pictures. Depending on this information, the model tries to predict your name from the images, if it predicts name correctly for multiple images there are high chances that you were part of the training data.</li> <li><a href="https://huggingface.co/spaces/RamAnanth1/photoguard" rel="nofollow"><strong>Photoguard:</strong></a> this space demonstrates an approach to safeguarding images against manipulation by ML-powered photo-editing models such as SD, through immunization of images.</li>',ve,A,we,D,Je="Socially Conscious work shows us how machine learning can support efforts toward a stronger society. Some examples:",$e,E,Ke="<li>Using machine learning as part of an effort to tackle climate change.</li> <li>Building tools to assist with medical research and practice.</li> <li>Models for text-to-speech, image captioning, and other tasks aimed at increasing accessibility.</li> <li>Creating systems for the digital humanities, such as for Indigenous language revitalization.</li>",ye,I,Xe="Some example spaces:",xe,j,Ye='<li><a href="https://huggingface.co/spaces/Geonmo/socratic-models-image-captioning-with-BLOOM" rel="nofollow"><strong>Socratic Models Image Captioning</strong></a></li> <li><a href="https://huggingface.co/spaces/nielsr/comparing-captioning-models" rel="nofollow"><strong>Comparing Image Captioning Models</strong></a></li>',be,q,Ce,F,Ze="This is work that highlights and explores techniques for making machine learning ecologically sustainable. Some examples:",Te,R,et="<li>Tracking emissions from training and running inferences on large language models.</li> <li>Quantization and distillation methods to reduce carbon footprints without sacrificing model quality.</li>",Le,U,tt='<li><a href="https://huggingface.co/spaces/adirik/efficientformer" rel="nofollow"><strong>EfficientFormer</strong></a></li> <li><a href="https://huggingface.co/spaces/Ron0420/EfficientNetV2_Deepfakes_Video_Detector" rel="nofollow"><strong>EfficientNetV2 Deepfakes Video Detector</strong></a></li>',Me,G,He,B,it="These are projects which broaden the scope of who builds and benefits in the machine learning world. Some examples:",_e,O,nt="<li>Curating diverse datasets that increase the representation of underserved groups.</li> <li>Training language models on languages that aren’t yet available on the Hugging Face Hub.</li> <li>Creating no-code and low-code frameworks that allow non-technical folk to engage with AI.</li>",ke,V,at='An example space is <a href="https://huggingface.co/spaces/microsoft/Promptist" rel="nofollow"><strong>Promptist Demo</strong></a>.',Se,N,Pe,W,ot="Some projects take a radical new approach to concepts which may have become commonplace. These projects, often rooted in critical theory, shine a light on inequities and power structures which challenge the community to rethink its relationship to technology. Some examples:",ze,Q,st="<li>Reframing AI and machine learning from Indigenous perspectives.</li> <li>Highlighting LGBTQIA2S+ marginalization in AI.</li> <li>Critiquing the harms perpetuated by AI systems.</li> <li>Discussing the role of “openness” in AI research.</li>",Ae,J,lt='An example space is <a href="https://huggingface.co/spaces/merve/dataset-worldviews" rel="nofollow"><strong>PAIR: Datasets Have Worldviews</strong></a>.',De,K,rt='Finally, if you would like to explore more about Hugging Face’s efforts, do check out the <a href="https://huggingface.co/society-ethics" rel="nofollow"><strong>Society and Ethics</strong></a> organzation on Hugging Face. Also check out the dedicated channel on <a href="https://discord.gg/hugging-face-879548962464493619" rel="nofollow"><strong>#ethics-and-society</strong></a>.',Ee,X,Ie,Z,je;return v=new wt({props:{containerStyle:"float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"}}),w=new d({props:{title:"Hugging Face’s efforts: Ethics and Society 🤗🌎",local:"hugging-faces-efforts-ethics-and-society-",headingTag:"h1"}}),y=new d({props:{title:"Democratizing Good ML 🤗",local:"democratizing-good-ml-",headingTag:"h2"}}),b=new d({props:{title:"Categories of Hugging Face Spaces",local:"categories-of-hugging-face-spaces",headingTag:"h2"}}),T=new d({props:{title:"✍️ Rigorous",local:"-rigorous",headingTag:"h3"}}),_=new d({props:{title:"🤝 Consentful",local:"-consentful",headingTag:"h3"}}),A=new d({props:{title:"👁️‍🗨️ Socially Conscious",local:"-socially-conscious",headingTag:"h3"}}),q=new d({props:{title:"🌎 Sustainable",local:"-sustainable",headingTag:"h3"}}),G=new d({props:{title:"🧑‍🤝‍🧑 Inclusive",local:"-inclusive",headingTag:"h3"}}),N=new d({props:{title:"🤔 Inquisitive",local:"-inquisitive",headingTag:"h3"}}),X=new $t({props:{source:"https://github.com/huggingface/computer-vision-course/blob/main/chapters/en/unit12/conclusion.mdx"}}),{c(){h=s("meta"),ee=a(),Y=s("p"),te=a(),c(v.$$.fragment),ie=a(),c(w.$$.fragment),ne=a(),$=s("p"),$.innerHTML=Fe,ae=a(),c(y.$$.fragment),oe=a(),x=s("p"),x.innerHTML=Re,se=a(),c(b.$$.fragment),le=a(),C=s("p"),C.textContent=Ue,re=a(),c(T.$$.fragment),ce=a(),L=s("p"),L.textContent=Ge,ge=a(),M=s("ul"),M.innerHTML=Be,me=a(),H=s("p"),H.innerHTML=Oe,ue=a(),c(_.$$.fragment),fe=a(),k=s("p"),k.textContent=Ve,pe=a(),S=s("ul"),S.innerHTML=Ne,he=a(),P=s("p"),P.textContent=We,de=a(),z=s("ol"),z.innerHTML=Qe,ve=a(),c(A.$$.fragment),we=a(),D=s("p"),D.textContent=Je,$e=a(),E=s("ul"),E.innerHTML=Ke,ye=a(),I=s("p"),I.textContent=Xe,xe=a(),j=s("ol"),j.innerHTML=Ye,be=a(),c(q.$$.fragment),Ce=a(),F=s("p"),F.textContent=Ze,Te=a(),R=s("ul"),R.innerHTML=et,Le=a(),U=s("ol"),U.innerHTML=tt,Me=a(),c(G.$$.fragment),He=a(),B=s("p"),B.textContent=it,_e=a(),O=s("ul"),O.innerHTML=nt,ke=a(),V=s("p"),V.innerHTML=at,Se=a(),c(N.$$.fragment),Pe=a(),W=s("p"),W.textContent=ot,ze=a(),Q=s("ul"),Q.innerHTML=st,Ae=a(),J=s("p"),J.innerHTML=lt,De=a(),K=s("p"),K.innerHTML=rt,Ee=a(),c(X.$$.fragment),Ie=a(),Z=s("p"),this.h()},l(e){const t=dt("svelte-u9bgzb",document.head);h=l(t,"META",{name:!0,content:!0}),t.forEach(i),ee=o(e),Y=l(e,"P",{}),ct(Y).forEach(i),te=o(e),g(v.$$.fragment,e),ie=o(e),g(w.$$.fragment,e),ne=o(e),$=l(e,"P",{"data-svelte-h":!0}),r($)!=="svelte-1efpqzw"&&($.innerHTML=Fe),ae=o(e),g(y.$$.fragment,e),oe=o(e),x=l(e,"P",{"data-svelte-h":!0}),r(x)!=="svelte-1yx93ur"&&(x.innerHTML=Re),se=o(e),g(b.$$.fragment,e),le=o(e),C=l(e,"P",{"data-svelte-h":!0}),r(C)!=="svelte-1wvga4p"&&(C.textContent=Ue),re=o(e),g(T.$$.fragment,e),ce=o(e),L=l(e,"P",{"data-svelte-h":!0}),r(L)!=="svelte-46a3g4"&&(L.textContent=Ge),ge=o(e),M=l(e,"UL",{"data-svelte-h":!0}),r(M)!=="svelte-1bni1se"&&(M.innerHTML=Be),me=o(e),H=l(e,"P",{"data-svelte-h":!0}),r(H)!=="svelte-atg9y"&&(H.innerHTML=Oe),ue=o(e),g(_.$$.fragment,e),fe=o(e),k=l(e,"P",{"data-svelte-h":!0}),r(k)!=="svelte-fioi3n"&&(k.textContent=Ve),pe=o(e),S=l(e,"UL",{"data-svelte-h":!0}),r(S)!=="svelte-3hltui"&&(S.innerHTML=Ne),he=o(e),P=l(e,"P",{"data-svelte-h":!0}),r(P)!=="svelte-i9zcru"&&(P.textContent=We),de=o(e),z=l(e,"OL",{"data-svelte-h":!0}),r(z)!=="svelte-16jekji"&&(z.innerHTML=Qe),ve=o(e),g(A.$$.fragment,e),we=o(e),D=l(e,"P",{"data-svelte-h":!0}),r(D)!=="svelte-eeobdf"&&(D.textContent=Je),$e=o(e),E=l(e,"UL",{"data-svelte-h":!0}),r(E)!=="svelte-7j1s8u"&&(E.innerHTML=Ke),ye=o(e),I=l(e,"P",{"data-svelte-h":!0}),r(I)!=="svelte-1civgnz"&&(I.textContent=Xe),xe=o(e),j=l(e,"OL",{"data-svelte-h":!0}),r(j)!=="svelte-eecl4f"&&(j.innerHTML=Ye),be=o(e),g(q.$$.fragment,e),Ce=o(e),F=l(e,"P",{"data-svelte-h":!0}),r(F)!=="svelte-1zmd9n"&&(F.textContent=Ze),Te=o(e),R=l(e,"UL",{"data-svelte-h":!0}),r(R)!=="svelte-ucq62j"&&(R.innerHTML=et),Le=o(e),U=l(e,"OL",{"data-svelte-h":!0}),r(U)!=="svelte-744dzg"&&(U.innerHTML=tt),Me=o(e),g(G.$$.fragment,e),He=o(e),B=l(e,"P",{"data-svelte-h":!0}),r(B)!=="svelte-zw6twt"&&(B.textContent=it),_e=o(e),O=l(e,"UL",{"data-svelte-h":!0}),r(O)!=="svelte-112ip57"&&(O.innerHTML=nt),ke=o(e),V=l(e,"P",{"data-svelte-h":!0}),r(V)!=="svelte-1syct0j"&&(V.innerHTML=at),Se=o(e),g(N.$$.fragment,e),Pe=o(e),W=l(e,"P",{"data-svelte-h":!0}),r(W)!=="svelte-1p66ki1"&&(W.textContent=ot),ze=o(e),Q=l(e,"UL",{"data-svelte-h":!0}),r(Q)!=="svelte-2s9fvm"&&(Q.innerHTML=st),Ae=o(e),J=l(e,"P",{"data-svelte-h":!0}),r(J)!=="svelte-s1ugqh"&&(J.innerHTML=lt),De=o(e),K=l(e,"P",{"data-svelte-h":!0}),r(K)!=="svelte-16v23z8"&&(K.innerHTML=rt),Ee=o(e),g(X.$$.fragment,e),Ie=o(e),Z=l(e,"P",{}),ct(Z).forEach(i),this.h()},h(){gt(h,"name","hf:doc:metadata"),gt(h,"content",xt)},m(e,t){vt(document.head,h),n(e,ee,t),n(e,Y,t),n(e,te,t),m(v,e,t),n(e,ie,t),m(w,e,t),n(e,ne,t),n(e,$,t),n(e,ae,t),m(y,e,t),n(e,oe,t),n(e,x,t),n(e,se,t),m(b,e,t),n(e,le,t),n(e,C,t),n(e,re,t),m(T,e,t),n(e,ce,t),n(e,L,t),n(e,ge,t),n(e,M,t),n(e,me,t),n(e,H,t),n(e,ue,t),m(_,e,t),n(e,fe,t),n(e,k,t),n(e,pe,t),n(e,S,t),n(e,he,t),n(e,P,t),n(e,de,t),n(e,z,t),n(e,ve,t),m(A,e,t),n(e,we,t),n(e,D,t),n(e,$e,t),n(e,E,t),n(e,ye,t),n(e,I,t),n(e,xe,t),n(e,j,t),n(e,be,t),m(q,e,t),n(e,Ce,t),n(e,F,t),n(e,Te,t),n(e,R,t),n(e,Le,t),n(e,U,t),n(e,Me,t),m(G,e,t),n(e,He,t),n(e,B,t),n(e,_e,t),n(e,O,t),n(e,ke,t),n(e,V,t),n(e,Se,t),m(N,e,t),n(e,Pe,t),n(e,W,t),n(e,ze,t),n(e,Q,t),n(e,Ae,t),n(e,J,t),n(e,De,t),n(e,K,t),n(e,Ee,t),m(X,e,t),n(e,Ie,t),n(e,Z,t),je=!0},p:ut,i(e){je||(u(v.$$.fragment,e),u(w.$$.fragment,e),u(y.$$.fragment,e),u(b.$$.fragment,e),u(T.$$.fragment,e),u(_.$$.fragment,e),u(A.$$.fragment,e),u(q.$$.fragment,e),u(G.$$.fragment,e),u(N.$$.fragment,e),u(X.$$.fragment,e),je=!0)},o(e){f(v.$$.fragment,e),f(w.$$.fragment,e),f(y.$$.fragment,e),f(b.$$.fragment,e),f(T.$$.fragment,e),f(_.$$.fragment,e),f(A.$$.fragment,e),f(q.$$.fragment,e),f(G.$$.fragment,e),f(N.$$.fragment,e),f(X.$$.fragment,e),je=!1},d(e){e&&(i(ee),i(Y),i(te),i(ie),i(ne),i($),i(ae),i(oe),i(x),i(se),i(le),i(C),i(re),i(ce),i(L),i(ge),i(M),i(me),i(H),i(ue),i(fe),i(k),i(pe),i(S),i(he),i(P),i(de),i(z),i(ve),i(we),i(D),i($e),i(E),i(ye),i(I),i(xe),i(j),i(be),i(Ce),i(F),i(Te),i(R),i(Le),i(U),i(Me),i(He),i(B),i(_e),i(O),i(ke),i(V),i(Se),i(Pe),i(W),i(ze),i(Q),i(Ae),i(J),i(De),i(K),i(Ee),i(Ie),i(Z)),i(h),p(v,e),p(w,e),p(y,e),p(b,e),p(T,e),p(_,e),p(A,e),p(q,e),p(G,e),p(N,e),p(X,e)}}}const xt='{"title":"Hugging Face’s efforts: Ethics and Society 🤗🌎","local":"hugging-faces-efforts-ethics-and-society-","sections":[{"title":"Democratizing Good ML 🤗","local":"democratizing-good-ml-","sections":[],"depth":2},{"title":"Categories of Hugging Face Spaces","local":"categories-of-hugging-face-spaces","sections":[{"title":"✍️ Rigorous","local":"-rigorous","sections":[],"depth":3},{"title":"🤝 Consentful","local":"-consentful","sections":[],"depth":3},{"title":"👁️‍🗨️ Socially Conscious","local":"-socially-conscious","sections":[],"depth":3},{"title":"🌎 Sustainable","local":"-sustainable","sections":[],"depth":3},{"title":"🧑‍🤝‍🧑 Inclusive","local":"-inclusive","sections":[],"depth":3},{"title":"🤔 Inquisitive","local":"-inquisitive","sections":[],"depth":3}],"depth":2}],"depth":1}';function bt(qe){return ft(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Ht extends pt{constructor(h){super(),ht(this,h,bt,yt,mt,{})}}export{Ht as component};
