teleren/devto huggingface dataset:
... Spread/Rest Operator
Published: 2023-12-16 00:18:47

The spread and rest operators are two features of JavaScript that were introduced in ES6. They can be used to simplify your code and make it more readable.

**Spread Operator**
The spread operator (...) allows you to expand an iterable datatype (such as an array or string) into its individual elements. This can be useful for a variety of tasks, such as copying arrays, merging objects, and creating new arrays from existing ones.

Here are a few examples of how to use the spread operator:
```javascript
// Copy an array
const numbers = [1, 2, 3, 4, 5];
const copy = [...numbers];
// same as copy = [1, 2, 3, 4, 5]

// Merge two objects
const obj1 = { a: 1, b: 2 };
const obj2 = { c: 3, d: 4 };
const mergedObj = { ...obj1, ...obj2 };
// same as mergedObj = {a: 1, b: 2, c: 3, d: 4}

// Create a new array from existing ones
const numbers1 = [1, 2, 3];
const numbers2 = [4, 5, 6];
const allNumbers = [...numbers1, ...numbers2];
// same as allNumbers [1, 2, 3, 4, 5, 6]
```

**Rest Operator**
The rest operator (...) allows you to collect the rest of the argument passed to a function into an array. This can be useful for mutliple tasks, such as creating functions that can accept one parameter that takes more than one argument and destructuring arrays.

Here are a few examples of how to use the rest operator:
```javascript
// Create a function that can accept a variable number of arguments
function add(...numbers) {
  let sum = 0;
  for (const number of numbers) {
    sum += number;
  }
  return sum;
}
// add(1, 2, 3, 4) becomes add([1, 2, 3, 4])

// Destructure an array
const numbers = [1, 2, 3, 4, 5];
const [first, second, ...rest] = numbers;
// same as [1, 2, [3, 4, 5]]
```

Since 2015, the use of the rest and spread operators have allowed very useful ways to manipulate data. The ability to use ... in the place of combining loops and methods saves time.
Building a prototype website
Tags: html, beginners, programming, learning
Published: 2023-12-16 00:03:12


Since this morning, I have been working on building a prototype website as a fun way of getting the hang of HTML.
I posted my code for the prototype below, the end goal is to have it display multiple videos at once. Right now, I have one embedded video embedded from one of my favorite educational YouTube channels, PBS SpaceTime. I've entered my code below, expect for an update tomorrow and a change in concept. The first version of it is just to see how to embed videos and code the bullet list in HTML files.

What I like about the website:
- It is playing the embedded video fine
- It includes a title and bullet points stating my current thoughts
- Website makes use of attributes for later organization

What I dislike:
-Too much empty space
-Very basic design overall due to lack of CSS involvement
-Needs more videos
-Needs to include hyperlink text
-Lacks background color and design scheme


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/31t1u3gn8e1jkuivpkn5.png)

```
<body>
	<h1><u>Protowebsite</u></h1>
	<div id="media">
		<h2><p></p>PBS SpaceTime Discussing the recent the concept of "Attosecond"</h2>
		<iframe src="https://www.youtube.com/embed/5e83QRGoRCo?si=PfZPSMWpSr6sZ4Bf"  width=1080 height="1200" 		>
		Video is not supported -_-
		</iframe>
	</div>
	<div id="information">
		<h2>Background</h2>
		<p> This test website was created for viewing my current skillset in terms of HTML web building.<br>
			I want to be able to create my own website after I feel this project is finished.

		</p>
	</div>
	<div id="Progress check">
		<h2>What I dislike</h2>
		<ul>
			<li>Website lacks background <strong>color and deseign</strong> scheme</li>
			<li>Very basic design overall due to <strong>no CSS involment</strong></li>
			<li><strong>A lot of empty space</strong> that needs to be filled somehow</li>
			<li>Needs <strong>more videos</strong></li>
			<li>Needs <strong>hyperlink text</strong> for subjects/nouns included in the update</li>
		</ul>
		<h2>What I like</h2>
		<ul>
			<li>Website is playing video just fine</li>
			<li>website includes titles and bullet points</li>
			<li>website shows that I know how to scale and embed youtube videos</li>\
            <li>webiste makes use of attributes for later organization</li>
		</ul>

	</div>
</body>

```
This will wrap up my first week of the DPI program and I am excited to see what's next!
Community Cheers🥂 Who Inspired You in 2023?
Tags: discuss
Published: 2023-12-16 00:00:00

---
published_at : 2023-12-16 00:00 +0000
---
Shoutout to a community member who inspired or helped you this year.
<br>
Follow the DEVteam for more discussions and online camaraderie!
{% embed https://dev.to/devteam %}
How to Understand Humans
Tags: discuss, codenewbie, beginner
Published: 2023-12-16 00:00:00

---
published_at : 2023-12-16 00:00 +0000
---
Humans are fascinating! (At least that's what our alien leaders told us before they sent us here to study them. 🛸) Any favorite books or resources you've read that that have given you valuable insights into why folks do what they do? And how does understanding what makes folks tick help you out in your daily life or professional endeavors? 
<br>
Follow the DEVteam for more discussions and online camaraderie!
{% embed https://dev.to/devteam %}
I'm developing software here.
Published: 2023-12-15 23:43:44

Hi, everyone.

Recently, it seems that I have been mentioned a little somewhere. Even though I have not posted any blog articles, my followers are gradually increasing.

I'm developing software here. Recently I'm developing <a href="https://metacpan.org/pod/SPVM">SPVM</a> modules.

<a href="https://github.com/yuki-kimoto?tab=repositories">Yuki Kimoto - Github Repositories</a>

The commits are very frequent, so you might enjoy looking at the commit histories and the diffs.
OpenContext GitHub Actions
Tags: github, githubactions, opservations, security
Published: 2023-12-15 23:44:32

OpenContext is pleased to announce the release of two GitHub Actions. We know it’s critical that we meet our customers where they are at. What better way to do this than with the GitHub Actions platform? We’re using it to integrate real-time context for code and artifacts so you know the experts working on those key parts of your technical stack. We also know that SBOM requirements add another layer of information to track. Our GitHub Action allows you to automate and record each SBOM artifact as well.

These GitHub Actions integrate seamlessly into your existing workflow. Let us reduce your toil and keep AppSec teams happy. The GitHub Actions can be used alone or in tandem, depending on your needs. They are:

- Create an [artifact YAML](https://github.com/marketplace/actions/create-artifact-yaml)

- Generate an [SBOM YAML](https://github.com/marketplace/actions/generate-sbom-yaml)

## Track release artifacts
The first GitHub Action will generate an artifact record in the OpenContext YAML format. Using this, you can:

- Automatically capture each release’s context information
- Integrate releases as part of your data lineage from code to cloud
- Prevent lengthy archeological digs and mapping projects to understand your technical stack
- Connect to other data that will show you exactly who owns what in the system

## Track SBOMs
Our second GitHub Action will create an SBOM as an artifact tied to your release. This lets you:

- Integrate SBOM files with our artifact tracking system
- Be audit-ready
- Avoid extra steps by having everything in one place

OpenContext is here to help you collect and organize the myriad pieces of data needed to solve problems, be ready for the next Log4j vulnerability, and follow security and supply chain standards. We believe the key to more effective AppSec and DevOps is guardrails that show how things work. Our GitHub Actions integrate with an automated data platform that will capture your technical stack and data lineage, while also connecting it to the people who are doing the work. These features reduce your toil so you can focus on scalability, migrations, reliability, best practices, and security.

Check out our [artifact video here](https://youtu.be/yowM8emABxc)
Give it a try! You can [sign up for our beta here](https://portal.app.opencontext.com/landing?_gl=1*wpngu4*_ga*NjI2OTcyNDg5LjE2NDE0MDgyMDQ.*_ga_SVT89JQZS8*MTY5OTM5NzE2OC4xMzIuMC4xNjk5Mzk3MTY4LjYwLjAuMA..).
I don't be what make
Tags: careerdevelopment
Published: 2023-12-15 23:43:49

I don't know where i am and what is my path. 

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/6lvp6dbevv3fp92x1s7l.jpg)

I only act for impulse, hope or ignorance. 

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/f0n7agw3cvl0vsz75s1f.jpg)

My finances is bad, my career at a standstill and i disoriented. 

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/k54wzkcp5w5dapjvjvu6.jpg)
Explorando a Interação Humano-Computador: Teoria e Aplicações Modernas
Published: 2023-12-15 23:31:18

Olá comunidade Dev.to em Português!

É com grande entusiasmo que compartilho com vocês um mergulho profundo na fascinante área de Interação Humano-Computador (IHC). Nos últimos anos, testemunhamos avanços significativos que moldaram a maneira como os usuários interagem com a tecnologia, e este post busca abordar tanto os aspectos teóricos quanto as aplicações práticas que emergiram nesse campo dinâmico.

1. Introdução à IHC e suas Evoluções Recentes

Iniciamos nosso percurso com uma visão abrangente da IHC, explorando suas raízes históricas e como ela se transformou para atender às crescentes demandas da sociedade digital. Utilizando as bases teóricas de artigos como "Designing Interactive Systems" de Benyon, D., et al., e "The Design of Everyday Things" de Don Norman, contextualizaremos as mudanças e evoluções fundamentais.

2. Desvendando a Experiência do Usuário (UX) através de Abordagens Científicas

Vamos adentrar os intricados detalhes da Experiência do Usuário (UX), examinando as contribuições da psicologia cognitiva e da ergonomia para criar interfaces mais intuitivas e agradáveis. Artigos como "The Elements of User Experience" de Jesse James Garrett e "Don't Make Me Think" de Steve Krug servirão como guias para entendermos como projetar sistemas que atendam às expectativas e necessidades dos usuários.

3. A Revolução da Realidade Aumentada (RA) e Interfaces Tangíveis

Exploraremos como a Realidade Aumentada (RA) e interfaces tangíveis estão moldando a interação entre humanos e computadores. Baseando-nos em pesquisas inovadoras, como "A Survey of Augmented Reality" de Azuma, R. T., e "Tangible Bits: Beyond Pixels" de Ishii, H., destacaremos os avanços recentes e as implicações futuras dessas tecnologias empolgantes.

4. Desafios Éticos na IHC: Rumo a uma Interação mais Responsável

Além das inovações, enfrentamos desafios éticos significativos. Com base em estudos como "Ethics in Human-Computer Interaction" de Friedman, B., et al., e "Moral Machines: Teaching Robots Right From Wrong" de Wendell Wallach e Colin Allen, discutiremos como podemos projetar sistemas interativos éticos que considerem as implicações sociais.

Aplicações Práticas: Estudos de Caso e Desenvolvimentos Recentes

Concluímos nossa jornada mergulhando em casos práticos e desenvolvimentos recentes na IHC. Utilizando estudos como "Interactive Data Visualization for the Web" de Murray, S., exploraremos como os conceitos teóricos se traduzem em aplicações do mundo real, destacando projetos inovadores e seu impacto.

Este post é mais do que uma exploração superficial da IHC; é um convite para aprofundarmos nosso entendimento sobre como a interação entre humanos e computadores molda nosso mundo digital. Espero que esse mergulho teórico e prático inspire discussões significativas e incentive a busca contínua por experiências interativas excepcionais.

Agradeço a todos por se juntarem a esta jornada intelectual.

Happy coding!

[Aline Machado Queiroz]
[https://dev.to/alineqz]
🌟 #DEVImpact2023 Reflections
Tags: devimpact2023, retrospective, 2024tech
Published: 2023-12-15 23:29:00

---
title: 🌟 #DEVImpact2023 Reflections
published: true
tags: devimpact2023, retrospective, 2024tech
---

### Proud Moments
Building a development platform with Kubernetes is a challenging task even for entire teams, however I managed to build one from scratch! And it proved to pay dividends since I was able to quickly translate great ideas into working applications!

### DEV Contributions
I loved writing articles and posting content on the platform, but I am also an avid reader! I love all the content on DEV!

### Brilliant Fails
Some of my videos and articles flopped, but deservedly so - they are kind of crap. I think I am getting better an better at creating more engaging content and there is also a lot of positive feedback to keep me going!

### Celebrate the Numbers 
My most popular post got over 1000 views!

{% embed https://dev.to/mihailtd/javascripttypescript-monorepo-setup-with-pnpm-workspaces-vite-vuejs-and-tailwindcss-nki %}

My YouTube channel has grown to almost 500 subscribers!

{% embed https://www.youtube.com/@letstalkdev %}

### Future Goals 

I think I summarized my future goals the best in this video: 

{% embed https://youtu.be/39ntJOz9D6U %}

### What Does DEV Means to You?

Thanks to all DEV members for the amazing community and quality content you post every day!
When is it right to make code less efficient?
Tags: discuss, webdev, help, codenewbie
Published: 2023-12-15 22:57:55

Hello fellow programmers! 

Today, I made my first post that is solely a discussion. In fact, you are reading it right now! 

So, I pose this question to you: **When is it right to make code less efficient?**

(e.g.

```
repeat 4 times {
action
}
```

v.s. 

```
action
action
action
action
```
)


Post your opinion in the comments below. Thanks for reading!
EVRTN - web3 stack, for everything you may need
Tags: web3, programming, webdev, tooling
Published: 2023-12-15 22:43:20

## Preamble

As a developer, aspiring to gain some web3 code knowledge, I started side project meant to teach me how to move around blockchain realm. But although there were many technologies present, none of them seemed to work well together. I made the decision to press ahead, fusing the best available technology I know into a logical structure. Here comes **EVRTN**, a fusion of Node.js, TypeScript-powered React, Ethereum, and smart contract language - Vyper. It's a unified approach to creating decentralized apps (dApps), not _just_ a stack.

## So what's in there?

### Ethereum: The backbone of blockchain

[**Ethereum**](https://ethereum.org/en/) is at the center of EVRTN and is most likely the most popular blockchain platform worldwide based on its widespread usage. In order to implement smart contracts and create dApps, Ethereum's strong ecosystem provides the flexibility and security required. It is the best choice for the core of our framework due to its broad adoption and encouraging community.

### Vyper: Secure and simple smart contracts

Moving up the stack, we have [**Vyper**](https://docs.vyperlang.org/en/stable/), which is a practical smart contract writing alternative to Solidity, which is infamous for its quirks. Because Vyper's syntax is similar to that of Python, it is easier to understand and use, which lowers the learning curve considerably. Vyper is perfectly aligned with Ethereum to enable a more safe and efficient development process by putting security and simplicity first.

### React and TypeScript: A frontend power duo

[**TypeScript**](https://www.typescriptlang.org/) and [**React**](https://react.dev/), two of the most effective and versatile frontend technologies, combine to form EVRTN's frontend team. Building dependable, scalable user interfaces with type safety and user-friendly codebase management is made possible by this combination. React and TypeScript work well together to improve the development experience and make it simpler to create responsive and dynamic dApps.

### Node.js: The backend enabler

[**Node.js**](https://nodejs.org/en) rounds out the stack. Node.js supports extra backend operations, such as masking certain backend work, leveraging secrets to connect to blockchain, or just giving simplified API, while Ethereum and Vyper handle the blockchain and smart contract features. It offers an environment that is both scalable and efficient for server-side logic, API integrations, and other uses, and it connects with the other technologies with ease.

## Postamble

So... will you give it a whip? Of course it can take anything in there, as it's flexible framework. You can build it with [Vite](https://v2.vitejs.dev/), or just [esbuild](https://esbuild.github.io/). You want your frontend to shine? There are tons of options to choose from - all of them will work here.
Day 885 : In the End...
Tags: hiphop, code, coding, lifelongdev
Published: 2023-12-15 22:39:31

_liner notes_:
- Professional : Since I knew today was not only a half day, but the last work day for me before I start my vacation. I won't be back to work till the new year. So I stayed up after getting back from the Orlando Developers holiday party and finished up a tutorial and pushed it to the repo so that my European team members could review it. In the end, that was probably a good call because when I woke up, looks like everything went through. For the rest of the day, I replied to some community questions and finished up other random tasks and tied up some loose ends. Got to a good point to end the year.

- Personal : Went to the holiday party and had a really good time. Saw people I haven't seen in a while and met a bunch of new people.

![A close up a branch with some leaves and an out of focus background of dirt path in a forest with green trees on both side in Tarnita, Romania](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/akjzscbn5aeu2mig058i.jpg)

For the other half of my day, I bought some music from Bandcamp and created the posts to put on my social media accounts. Went through a bunch of tracks and worked on a playlist for the show tomorrow. While listening to the tracks, I was doing some research for my side project. Going to finish up the prep work for the radio show and then work on the dashboard proof of concept for my side project. Not sure if I'm going into the station tomorrow, there's supposed to be some severe weather. We'll see.

This is going to be my last post till the new year. So, in advance, Happy Holidays and Happy New Year. I'll still be doing the radio show on Saturdays at https://kNOwBETTERHIPHOP.com and my study sessions most Sundays at https://untilit.works

Have a great night! Talk later.

peace piece
Dwane / conshus
https://dwane.io / https://HIPHOPandCODE.com
{% youtube QbCzkd2Xy-Q %}
[Digest] Java, Kotlin, Spring, Cloud, and More - Episode 18
Tags: digest, java, spring, cloud
Published: 2023-12-15 22:17:24

💾 [EdgeDB 4.0](https://www.edgedb.com/blog/edgedb-cloud-and-edgedb-4-0#edgedb-4): nice mix of a relational and graph databases. It even has [Java client](https://www.edgedb.com/docs/clients/java/index).

☕️ [Java, Kotlin, Scala: Insights from State of Developer Ecosystem 2023](https://vived.substack.com/p/java-kotlin-scala-insights-from-state): some entertaining statistics on programming languages and frameworks.

🌱 [Introducing Spring Modulith](https://spring.io/blog/2022/10/21/introducing-spring-modulith): spring project that lets you write better modular monolith.

🌱 [Spring Boot 3.2.0 available now](https://spring.io/blog/2023/11/23/spring-boot-3-2-0-available-now): Spring Boot 3.2 is released recently. It includes support for Virtual Threads, Coordinated Restore at Checkpoint (CRaC), and a bunch of other features and dependency updates.

🔥 [Stop deploying web application firewalls](https://www.macchaffee.com/blog/2023/wafs/): interesting post on why you should not use WAF.

Have a nice weekend!

---

*Dream your code, code your dream.*
Master LLM Hallucinations 💭
Tags: ai, opensource, devops
Published: 2023-12-15 22:12:59

Building with AI and LLMs is now a must-know for every developer. Every application is trying to integrate AI models. But hallucinations -- the phenomenon of AI models generating incorrect or unverified information -- are still an unsolved problem. 

**_"Ughh ChatGPT - I told you to NOT make stuff up!"_**

![meme](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/cslqlgqcankv6pa1zjrl.jpeg)

Andrej Karpathy shared recently his take on hallucinations on [Twitter](https://x.com/karpathy/status/1733299213503787018?s=20):

> "The LLM has no "hallucination problem". Hallucination is not a bug, it is LLM's greatest feature. The LLM Assistant has a hallucination problem, and we should fix it." 

**So how do we fix it?** 

[Chain-of-Verification (CoVe)](https://arxiv.org/pdf/2309.11495.pdf), a technique introduced by researchers at Meta, is one way. Let's dive into the high-level process of CoVe and then explore how we implemented a CoVe prompt template using AIConfig that you can use to reduce hallucinations in your LLM-powered apps. 

## The Chain-of-Verification (CoVe) Process 🔗

As documented in the white paper, the process involves 4 crucial steps:

1️⃣ **Generate Baseline:** Given a query, the Large Language Model (LLM) generates a response.
2️⃣ **Plan Verification(s):** With the query and baseline response, the system formulates a list of verification questions. These would aid in analyzing potential inaccuracies within the original response.
3️⃣ **Execute Verification(s):** Each verification question is answered, and then cross-checked against the original response to discern inconsistencies or flaws.
4️⃣ **Generate Final Response:** If inconsistencies are found, a revised response is generated, factoring in the results from the verification process.

## Integrate CoVe into your App with AIConfig💡 

We've brought the CoVe technique to life using AIConfig, streamlining the process to help reduce hallucinations in your LLM applications.

Using AIConfig, we can separate the core application logic from the model components (prompts, model routing parameters, etc.). Here's what the prompt template looks like:

1️⃣ **GPT4 + Baseline Generation prompt:** This sets the foundation by generating the initial response using GPT4.
2️⃣ **GPT4 + Verification prompt:** This prompt creates a series of verification questions based on the initial response.
3️⃣ **GPT4 + Final Response Generation prompt:** Leveraging the findings from the verification stage, this prompt generates a final, more reliable response.

🔗 AIConfig CoVE: https://github.com/lastmile-ai/aiconfig/tree/main/cookbooks/Chain-of-Verification

Want to see it action? 👀 Try out our demo in Streamlit!!

🎁 Streamlit App: https://chain-of-verification.streamlit.app/

![streamlit](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/z0ngjaoyaucpjsydqepz.png)

Are you already using AIConfig or CoVe in your projects? Feel free to share your experiences in the comments below.

Liked the post?

Show your support by starring our project on GitHub! ⭐️ https://github.com/lastmile-ai/aiconfig